Expand my Community achievements bar.

SOLVED

What is the best way to add more properties to the page component?

Avatar

Level 4

Hello all,

I've a requirement where I have to add more properties to the existing page component. I've tried these two ways:

- Overlay the page component and add more properties in tab_basic (this worked)

- Inherit the page component (giving in slingResourceSuperType) and copy and paste the dialog node and add more properties (this did not work)

Are there any other options to do it? Basically I want to have more options in the basic tab rather than just 3 which has been given. I have added the pic also here for more clarity. Thanks!dialog.JPG

1 Accepted Solution

Avatar

Correct answer by
Level 7

Should not copy paste whole dialog. That defeats the purpose of resource merger. Here is a link that does similar to what you are doing GitHub - Adobe-Marketing-Cloud/aem-authoring-extension-page-dialog​ .

But still its strange that copying the dialog doesnt work. Could you add details exactly what doesnt work? Does the dialog not open or it still shows old fields?

View solution in original post

6 Replies

Avatar

Level 10

When you overlayed the page component - where you able to see the new tabs?

Avatar

Correct answer by
Level 7

Should not copy paste whole dialog. That defeats the purpose of resource merger. Here is a link that does similar to what you are doing GitHub - Adobe-Marketing-Cloud/aem-authoring-extension-page-dialog​ .

But still its strange that copying the dialog doesnt work. Could you add details exactly what doesnt work? Does the dialog not open or it still shows old fields?

Avatar

Level 4

The dialog doesn't open when i click on page properties

Avatar

Level 4

Yes I was able to see that new properties. OVerlaying works fine but I'm wondering if its the right practice or not.

Avatar

Level 7

I think there would be some JS error.. Possible that the dialog got copied under incorrect node.. Can verify the hierarchy of your new component? If there is a sample package that you can share, that will be great... Could you also check browser console and share JS error, if you see any?

P.S. overlaying(that works for you) is better practice. So your work is accomplished but it would be good to find out root cause of this issue.

Avatar

Level 4

There was no js error in console actually. Wonder why. But I'm going with overlaying approach. Thank you.