RocketChat / Rocket.Chat

The communications platform that puts data protection first.
https://rocket.chat/
Other
40.47k stars 10.54k forks source link

Custom CSS is partly ignored on v3 #20601

Open jordivilar opened 3 years ago

jordivilar commented 3 years ago

Description:

It seems that the custom CSS is partly ignored from a character onwards or when the code becomes automatically minified.

Steps to reproduce:

  1. Go to "admin/layout/" and click on "Custom CSS"
  2. Paste custom unminified CSS in the text area
  3. Click on "Save changes"

Expected behavior:

The custom CSS is fully applied

Actual behavior:

The custom CSS is partly applied ignoring the last classes even using !important

Server Setup Information:

Client Setup Information

Additional context

Just to check if there was something wrong in the custom CSS I've tried to paste it directly in the browser element inspector overriding the minified source and it worked fine.

gabriel-henriq commented 3 years ago

up

TBG-FR commented 3 years ago

I think this is the same issue as #19405 Try to add a fake CSS class at the end of the file, while we're waiting for a fix

jordivilar commented 3 years ago

I think this is the same issue as #19405 Try to add a fake CSS class at the end of the file, while we're waiting for a fix

Not really. It happens wherever you put the code not only at the end of the file. In fact, adding an unuseful class to be truncated by a bug was my idea so the guy who posted that solution and I work together.

TBG-FR commented 3 years ago

Could you show us the CSS classes that seem to be ignored ?

jordivilar commented 3 years ago

They were this two:

body.dark-mode .rcx-option--focus,
body.dark-mode .rcx-option:hover {
    background: rgba(255,255,255,0.1)!important;
}

body.dark-mode .rcx-option__column .rcx-status-bullet--online {
    background: #2de0a5 !important;
}

I tell "were" because it magically works right now O_o