Open snoopy72 opened 3 years ago
I think we should not add an additional class for that, its quite easy with the [id^="sortModal_"]
, but it could maybe make sense to allow the user to overwrite the html.
@wenzhixin @djhvscf What do you think ?
I think the our plugin should be very customizable.. So it's good to me to add a new option to the multisort extension in order to add a class to the modal.
@DustinUtecht Why ? Several automation tools cannot handle "complex" definitions like [id^="sortModal_"] When we start to open our CSS for "special" styles like that, we will lose control. In our css files we define only classes, which allows us to highly automate our processes.
@djhvscf I agree you: mote flexible and customizable components are better to implement and use for more developers.
@snoopy72 I understand you point, but i think it makes more sense to allow the user to customize the html (which includes the classes) then adding a options which changes only one part of the html. We have more then 1 extension, which means we must add X options to add X classes, in my opinion it makes more sense to allow overwrite the html. @djhvscf
I think we can add an option like modalTemplate
to support custom the HTML template.
Description
Trying to use your plugin "MultiSort", the plugin opens a modal after clicking on the button.
Unfortunately the modal is written at the end of the document and is only using the class "modal". That class is used heavily by other (foreign) components and plugins, so the layout is more or less uncontrolable:
The close button is not reachable, the width is cut etc.:
Currently, the generated modal from your BT plugin looks like this:
We could use the css method
[id^="sortModal_"] { ... }
, but that would neither matches our rules nor be easy to maintain.If you would add an extra class (f.eg. "bootstraptable" it would be much easier to define own CSS rules:
It would be perfect, if the developer could define those optional prefix/addition by option (f.eg. "multiSortModalClass").