Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

Adding preview option in cq:dialog

Avatar

Level 6

Is it possible to add a session in cq:dialog which renders whatever data is supplied in the fields and previews it out in real time. In the simplest of scenarios, I need to add two numbers and when I enter both the numbers the cq:dialog should preview it's output as 4. There should be two sessions in the the cq:dialog, like two columns, the left one to enter value to the fields and the right to display the rendered output. How to achieve this? Is it possible to?

1 Accepted Solution

Avatar

Correct answer by
Level 5

No it can't be possible through Touch UI dialog. Also, as per the spec​​ Sightly does not support operations inside expressions. You would need to create a helper use-object (using either JavaScript or Java) that would provide the test threshold/reference value.

View solution in original post

2 Replies

Avatar

Correct answer by
Level 5

No it can't be possible through Touch UI dialog. Also, as per the spec​​ Sightly does not support operations inside expressions. You would need to create a helper use-object (using either JavaScript or Java) that would provide the test threshold/reference value.

Avatar

Community Advisor

Hi jezwn​,

  • use extraclientlib property to add your dialog specific clientlibs.
  • write your logic in clientlib js.

Take a reference from this GitHub - Adobe-Marketing-Cloud/aem-authoring-dialog-fields-customization: Sample for customizing fie...

Usually we write JS for fields validations in a dialog.However I never came across such kind of requirements but it should be achievable using above steps.

Regards,

Arpit Varshney