Skip to main content
Mar 25, 2025 8:10 AM UTC
Solved

Replace image field in the Universal Editor

Hello, I want to replace or substitute a UE field with a React component through extensions.

 

 The field is the one that says *Image which I want to replace.

In my extensions project I have the following code.

 I've tried different data types like Image, image, media, and multi, but I haven't been able to replace that field.

Could you tell me which data type is right for it?

 

 

FelixDeAccepted solution
Adobe Employee
Mar 26, 2025 9:48 AM UTC

Hi Ricardo,

 

To be able to provide an alternative field renderer in Universal Editor, the field "component" property in the "component-models.json" must match the "dataType" property in the "getRenderers" call. With the code above all field with "component": "image", "media" and "richtext" should get the alternative render.

 

What is the definition of your field in "component-models.json"?

 

Thanks.

3 replies

FelixDeAdobe EmployeeAccepted solution
Adobe Employee
Mar 26, 2025 9:48 AM UTC

Hi Ricardo,

 

To be able to provide an alternative field renderer in Universal Editor, the field "component" property in the "component-models.json" must match the "dataType" property in the "getRenderers" call. With the code above all field with "component": "image", "media" and "richtext" should get the alternative render.

 

What is the definition of your field in "component-models.json"?

 

Thanks.

Translate
Mar 28, 2025 7:02 AM UTC

we have a component-definition.json and we have this data

 

 and in de model from aem is this:

 

 

Translate
Adobe Employee
Apr 3, 2025 2:26 PM UTC

Thank you for confirming. I see that you are using a Headless setup and currently the extensibility API is not ready to be able to pin point a particular field in Headless context. A fix is currently being worked on and while we don't have an estimated date for delivery/release.

 

In the Headless context, Universal Editor is using the information returned by the `/details` call to decide the type of the field. The extension will then match this value to the what you put in the `dataType`. If you were to do that then the Extension custom field would then be rendered over all field of that type.

Translate