Providing some but not all uischema

Hi All,

I have a project where the only ui schema I provide is for the top level object in my schema where I want it to use a listWithDetail rather than the standard array handler. I.e. my ui schema is:

{
    "type": "ListWithDetail",
    "scope": "#/properties/solutionFactoryConfiguration/properties/rtengVi/properties/resolvedEntities",
    "options": {
        "labelRef": "#/items/properties/name"
    }
}

My question is: is it possible to also specify a piece of UI schema for an property/object/array much deeper into my schema I.e. something like:

{
    "type": "ListWithDetail",
    "scope": "#/properties/solutionFactoryConfiguration/properties/rtengVi/properties/resolvedEntities",
    "options": {
        "labelRef": "#/items/properties/name"
    },
    "elements": [
        {
            "type": "Control",
            "scope": "#/properties/solutionFactoryConfiguration/properties/rtengVi/properties/resolvedEntities/items/properties/elements/items/properties/name",
            "label": "SOME TEST LABEL"
        }
    ]
}

Where here i’m trying to modify the label on one of the properties of an object that is a level or two below the top level object which i’m configuring the ListWithDetails for. I should add that both the resolvedEntity object and element object both have multiple other properties that are not name.

Thanks all!
James

Hi @james-morris,

Yes this is supported via the uischemas registry which can be handed over via a prop to the root JSON Forms component. The registry is tester based, similar to the renderers and cells and is queried whenever a detail UI Schema is rendered. With it you should be able to solve your use case.

1 Like