The module's CSS is using important! rules that ruin themes CSS.

I assume this was due to a specific theme, but it shouldn't be assuming any style.

If the CSS rules need to be there at least remove the important.

In attachment is a patch.

Comments

erikhopp’s picture

I second this. I also had to remove the "!important"s. They are unnecessary and interfere with probably most themes.

erikhopp’s picture

Version: 7.x-1.0 » 7.x-1.x-dev
Status: Patch (to be ported) » Needs review
StatusFileSize
new248 bytes

Attached is a patch which is a little less destructive than the initial one. This simply removes the '!important' declarations.

erikhopp’s picture

StatusFileSize
new1.68 KB

In order to make the dismissal of messages correct from a visual standpoint while also removing the '!important' CSS declaration, we should also close the entire dismissed .messages div, rather than simply the .pdm-message-wrapper. A patch for that is attached. the entire patch for this bug report should then include the attached patch and the 'pdm-important-css.patch' patch.

kyuubi’s picture

Hi erikhopp,

Yes I also had to redo the js to close the .messages div instead of the wrapper.

Your patch seems to work fine.

Cheers,

Duarte

Andre-B’s picture

Status: Needs review » Reviewed & tested by the community

looks good

  • erikhopp authored d915eb4 on 7.x-1.x
    Issue #2146403 by erikhopp, kyuubi, Andre-B: CSS in module is crashing...
soyarma’s picture

Status: Reviewed & tested by the community » Closed (fixed)

Thanks! Patches applied.

soyarma’s picture

I applied both the CSS and the JS, but then I realized, upon testing, that the JS closes then entire messages 'type' wrapper when any dismiss within it is clicked.

The 'messages' div is for an entire group. A group being error, warning, success, info, etc... This means that if you had 3 'success' messages in a section, clicking dismiss on any of them would hide them all, but only dismiss the one you clicked.