Do you have a sample of a shared component taking a parameters from a parent component? | Community
Skip to main content
Level 3
November 18, 2020
Question

Do you have a sample of a shared component taking a parameters from a parent component?

  • November 18, 2020
  • 1 reply
  • 934 views

I want a component that has a left side of 

Option1 (Anchor)

Option2 (anchor)

 

Right side is the form you see from the selection on the left.

 

I have this working using grid-item on the left, and on the right:

 

<div id="form" class="grid-item">
<p data-sly-test="${request.requestParameterMap['section'][0].toString == 'option1'}">
<article data-sly-resource="/content/forms/af/project/option1"></article>
</p>
<p data-sly-test="${request.requestParameterMap['section'][0].toString == 'option2'}">
<article data-sly-resource="/content/forms/af/project/option2"></article>
</p>
</div>

 

What I would like is a component on the left that can take ['option1 label", "option1 link", "option 2 label", "option2 link"]

or something similar 

 

Overall Question: Can I pass args to a component if the behaviour will likely be common?

 

Thanks

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

Mayank_Gandhi
Adobe Employee
Adobe Employee
November 24, 2020

@joellucuik I don't get the use case. Do you want to share more details or some screenshots?

Level 3
November 24, 2020

..ignore this. Replied to wrong comment