Adding CSS class to parsys | Community
Skip to main content
Level 2
August 12, 2016

Adding CSS class to parsys

  • August 12, 2016
  • 1 reply
  • 3546 views

Hello,

 

I am using AEM 6.2 and including my parsys as a resourceType:

 <div class="customCSSClass" data-sly-resource="${'marginCol' @ resourceType='wcm/foundation/components/parsys'}"></div>

I would like to add a customCSSClass on every component that is added to the parsys. Essentially, I want to create the following markup when a component is added to the parsys:

<div class="customCSSClass">

<!-- component code -->

</div>

Is there a possible way to achieve this?

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

1 reply

Level 2
May 31, 2017

Try this :

<div data-sly-resource="${'marginCol' @ resourceType='wcm/foundation/components/parsys', decorationTagName='div',

cssClassName='customCssClass'}"></div>