Skip to content

Conversation

lucasoares
Copy link

@lucasoares lucasoares commented Sep 25, 2025

Fixes #2492

This is a draft PR initially generated with Copilot and then reworked manually.

I'm not familiar with the jsonforms codebase and don't have much time right now to dive deeply into it. I did a bit of work on top of what Copilot generated, but I didn’t spend too much time polishing it. The goal was mainly to provide a working version of additionalProperties rendering with the Material renderer.

Everything appears to be working: adding and removing data inside both the object and its arrays. That said, this was mostly an experiment to see if Copilot could handle the issue (I may end up using this version in a fork). For this to be production-ready, it will likely need to be redone properly using this as a reference. Since I have 0 context of jsonforms code, I couldn’t provide more detailed instructions for further development.

Schema example:

"propertiesArrayOfValuesByKey": {
  "type": "object",
  "title": "Array of Values by Key",
  "additionalProperties": {
    "type": "array",
    "items": {
      "type": "string"
    },
    "title": "Item"
  }
}

Rendered form:

image

All actions are working: you can add and remove data inside both the object and the arrays.

Copilot AI and others added 4 commits September 24, 2025 18:17
…lated imports

- Deleted the additional-properties-material example file and its associated code.
- Updated the additional-properties example to include new properties for handling arrays of values by key.
- Removed import references to additional-properties-material in index files.
- Enhanced MaterialAdditionalPropertiesRenderer to support dynamic titles and improved rendering logic for additional properties.
- Modified MaterialObjectRenderer to conditionally skip JsonFormsDispatch when only additional properties are present, improving rendering efficiency.
Copy link

netlify bot commented Sep 25, 2025

Deploy Preview for jsonforms-examples ready!

Name Link
🔨 Latest commit c2d5fb1
🔍 Latest deploy log https://app.netlify.com/projects/jsonforms-examples/deploys/68d495471b8c2c0008481c6c
😎 Deploy Preview https://deploy-preview-2494--jsonforms-examples.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@CLAassistant
Copy link

CLAassistant commented Sep 25, 2025

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ lucasoares
❌ Copilot
You have signed the CLA already but the status is still pending? Let us recheck it.

@lucas-koehler
Copy link
Contributor

@lucasoares Thanks a lot for your proposal!
Before we can consider any contribution, the CLA needs to be signed.
That said, we unfortunately don’t have the capacity to complete partially implemented community PRs.
If you’re able to provide a (mostly) complete implementation, we’d be happy to review it and provide feedback.

@lucasoares
Copy link
Author

@lucasoares Thanks a lot for your proposal! Before we can consider any contribution, the CLA needs to be signed. That said, we unfortunately don’t have the capacity to complete partially implemented community PRs. If you’re able to provide a (mostly) complete implementation, we’d be happy to review it and provide feedback.

The code is essentially complete. it’s not a partial implementation for what I proposed to do. It represents the full feature, including basic tests and comprehensive examples that confirm it's working as intended.

When I mentioned it was an experiment, I meant that I'm not fully familiar with the JSONForms code structure and conventions so I had to use the copilot for the initial version, and I didn't have enough time to study them in detail to ensure full alignment. That said, the implementation works and I'm currently using it in my own product.

Regarding the CLA, I can't sign it on behalf of Copilot, but I have rebased the branch and signed it myself if you'd like to move forward with the PR.

I'm happy to make any adjustments needed to align the code with the JSONForms codebase and style guidelines.

@lucas-koehler
Copy link
Contributor

@lucasoares I see that is fine then. I think I misunderstood. The CLA is still shown as incomplete though. I think you need to open a new PR with a squashed commit that is authored by you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support additionalProperties in React Material renderer set

4 participants