You need to be logged in to post in the forum - Log In

An active JCE Pro Subscription is required to post in the forum - Buy a Subscription

Support is currently Offline

Official support hours
Monday to Friday
09:00 - 17:00 Europe/London (BST)

Please create a new Ticket and we will get back to you as soon as we can.

#113836 Collapsed divs not showing in editor

Posted in ‘Editor’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Latest post by IUSAB on Friday, 26 May 2023 09:47 BST

IUSAB
When adding a collapse div (bootstrap 5) then it is not possible to edit collapsed content.

<div id="collapse-3" class="card-collapse collapse">
Test
</div>

Removing class collapse shows content.

Any workaround in editor? Like "show hidden elements" function or so that I am missing?

Ryan
Add the following to your template stylesheet:

.mceContentBody .collapse {
    display: inherit;
}

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

IUSAB
Didn't work. The style does not affect the collapse even though i added a custom stylesheet as last stylesheet both in admin template and in frontend template and also in JCE custom style template global configuration.

.mceContentBody .collapse, .mceContentBody .collapse:not(.show) {
display: inherit !important;
}

does nothing and when inspecting element with class collapse in backend then

.collapse:not(.show) {
display: none;
}

from

administrator/index.php?option=com_jce&task=editor.pack&type=css&slot=content& ...(hash code or something that i removed)... =1&context=22&profile_id=5

is loaded and hides the div.

Ryan
You need to clear your browser cache after making any changes to your template stylesheet.

Also, set Compress CSS to No in the Editor Global Configuration, to check the change, then you can re-enable it.

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

IUSAB
So issue was the compress CSS setting. Changed it to no and it solved the issue!

Thanks and have a good weekend!