Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit 2023 [19th to 23rd March, Las Vegas and Virtual] | Complete AEM Session & Lab list
SOLVED

AEM cloud - custom node/property hide in the dialog

Avatar

Level 4

Hi Team,

I need to hide a few custom nodes in the dialog. sling:hideResource is not working since the fields are custom. Could someone suggest how to hide few fields & set default values to send it in the json please?

 

Thank you

1 Accepted Solution

Avatar

Level 4

Hi All,

Thank you all for the replies. I tried few approaches that has mentioned in the comments above but no luck.

I tried to add granite:class hide. It worked for me as expected.

 

Hope this would help for others.

 

Thank you!

9 Replies

Avatar

Level 3

If you search for "aem dialog show hide" you will find a lot of examples on the web. One of them that looks a bit old though but might still be working is this one:

 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager-blogs/show-hide-cq-dialog-...

Avatar

Level 4

Hi @Christoph_Walte 

it's not show/hide, i want to hide fields in the dialog.

ex: hidden boolean true 

but its not working on cloud.

 

Any other recommendations please?

Avatar

Level 4

Hi @Christoph_Walte 

I want to hide b & c fields while opening the dialog.

 

Lakshmi9_0-1677664898292.png

tried hidden but no luck. Disable is working but it's not my requirement. 

Kindly suggest if any

Avatar

Community Advisor

try adding below if you are using coral3 

granite:hidden=true

The HTML hidden attribute.

 

 

https://developer.adobe.com/experience-manager/reference-materials/6-5/granite-ui/api/jcr_root/libs/... 

 

or try adding granite:class="hide"

Avatar

Community Advisor

Hi @Lakshmi9 

 

You can write custom JS to hide the dialog field you want.

 

Hope it helps!

Thanks,
Kiran Vedantam.

Avatar

Level 4

Hi All,

Thank you all for the replies. I tried few approaches that has mentioned in the comments above but no luck.

I tried to add granite:class hide. It worked for me as expected.

 

Hope this would help for others.

 

Thank you!