Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Collapse" and "Grids" conflict #106

Open
dolandemort opened this issue Oct 27, 2019 · 3 comments
Open

"Collapse" and "Grids" conflict #106

dolandemort opened this issue Oct 27, 2019 · 3 comments

Comments

@dolandemort
Copy link

dolandemort commented Oct 27, 2019

I have identified some kind of conflict between Collapse and Grids. The following example should allow you to replicate the issue.

===== Collapse =====
<button block="true" collapse="collapse_example">Click Me</button>

<collapse id="collapse_example" collapsed="true">
<well>
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident.
</well>
</collapse>

===== Grid =====
<grid>
<col sm="6">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</col>

<col sm="6">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</col>
</grid>

When I make a test page with the above, the Collapse button doesn't work, and you can see a plaintext "</collapse>" on its own line below the Well.

When I attempt to generate a preview of the above, I receive the error: Bootstrap Wrapper - Column Unknown attribute collapsed.

I have discovered that if you rearrange the above to make the Grid section come before the Collapse section, the issue disappears.

@dolandemort
Copy link
Author

dolandemort commented Oct 27, 2019

Upon further testing, I have discovered that even if you enclose the Grid section in a DokuWiki code block, the issue still persists. This plugin appears to be parsing things inside DokuWiki code blocks.

The following should replicate the issue I have just described.

===== Collapse =====
<button block="true" collapse="collapse_example">Click Me</button>

<collapse id="collapse_example" collapsed="true">
<well>
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident.
</well>
</collapse>

===== Grid =====
<code xml>
<grid>
<col sm="6">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</col>

<col sm="6">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</col>
</grid>
</code>

@mrtpcet
Copy link

mrtpcet commented Apr 13, 2020

I have the same issue and I find a short-term solution :
just add another <collapse> in front of your collapse section, before button shortcode = it's works.

In your example, it looks like this :

===== Collapse =====
<collapse>

<button block="true" collapse="collapse_example">Click Me</button>

<collapse id="collapse_example" collapsed="true">
<well>
Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident.
</well>
</collapse>

===== Grid =====
<grid>
<col sm="6">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</col>

<col sm="6">
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</col>
</grid>

@dolandemort
Copy link
Author

Thanks for taking the time to share your work around.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants