Expand my Community achievements bar.

SOLVED

Not able to align Parsys in Table Component

Avatar

Former Community Member

I am creating a table component with the help of rowitem component and not using the cq table component. This table component have header row and footer row included and a parsys sandwiched between them.

Like this

 <table>
        <caption>RTE</caption>
        <tbody>
            <cq:include path="rowitem" resourceType="dmp/components/foundation/rowitem"/>
            <cq:include path="tablePar" resourceType="foundation/components/parsys"/>
            <cq:include path="rowitem_0" resourceType="dmp/components/foundation/rowitem"/>
        </tbody>    
    </table>  

On dropping this table component, I got a header and footer row. and a parsys to include rows. Now the problem is the positioning of parsys. It appears above my table component and not between the header and footer row.

CQ generates the table markup beneath the parsys. Is there a way I can align this parsys in between the header and footer row. It doesnt look good while editing, and even steals the capability of editing.  

1 Accepted Solution

Avatar

Correct answer by
Level 8

Have you customized the paragraph system to be compatible with a table layout? The paragraph system assumes a div based layout and unless you have customized it your design is not going to work. One option would be to close out the table at the end of the header row, and then re open it before the footer row. That would probably get the par sys to align correctly in author mode. To make it render properly in preview/publish you'd have to iterate over the child nodes of the parsys your self and include them with the correct surrounding markup (so only include the parsys in author/design mode - otherwise include the child nodes yourself in your table component. 

View solution in original post

2 Replies

Avatar

Level 1

I have the same issue with CQ 5.6.1. Did you find a workaround for the row component.

Avatar

Correct answer by
Level 8

Have you customized the paragraph system to be compatible with a table layout? The paragraph system assumes a div based layout and unless you have customized it your design is not going to work. One option would be to close out the table at the end of the header row, and then re open it before the footer row. That would probably get the par sys to align correctly in author mode. To make it render properly in preview/publish you'd have to iterate over the child nodes of the parsys your self and include them with the correct surrounding markup (so only include the parsys in author/design mode - otherwise include the child nodes yourself in your table component.