The discussion centers on the modal-window plugin, a Discourse extension by Alex_Rabolin designed to open modal windows from forum posts using custom HTML and CSS. The plugin allows embedding external content via <iframe> tags and styling with <label> or <span> tags.
Following a Discourse update, the plugin broke because the label tag whitelist functionality ceased to work. Alex_Rabolin sought assistance, prompting cpradio to suggest creating a specific modal-window.js.es6 file to properly register the option and whitelist the necessary tags using the new helper API. This solution restored functionality, as confirmed by Alex_Rabolin.
Later, Alex_Rabolin reported that while iframe tags worked, the label tag and custom span classes for glyphs remained broken despite attempts to update the code. Subsequently, babyfooter analyzed the issue, noting that adding helper.whiteList(['span[class]']) to support glyphs caused the iframe whitelisting to fail again. They observed that while label whitelisting previously worked independently, it no longer functions with the latest Discourse update. The thread highlights an apparent incompatibility between whitelisting span classes and iframe execution, leaving the group investigating support for these custom enhancements.
Hello, the plugin is broken recently, have you got a idea please ?
The tag iframe src= is not broken, is ready .
But the tag label for= is broken ( and i want to use span class * for glyphicon on the forum post but it’s not ready to )
What was working in first version is use of :
helper.whiteList([‘label[for]’]);
helper.whiteList([‘iframe[src]’]);
We added following instruction in order to use glyficons
helper.whiteList([‘span[class]’]);
Adding it has broke iframes whitelisting, but work with glyficons, removing it just make it work again (iframes) I think so there is an incompatibility between span whitelist and iframe execution?
About label whitelist, was working, but not dependent of other tags whitelist, it doesn’t work anymore with last discourse update.
Thank you for you help, we are trying to add some capabilities on forum, and not sure about support on custom enhancements.