Are you enjoying the extensions? Did you like the support? Help others decide.

Leave a review

file CSS' selectors specificity

More
6 years 11 months ago #4954 by imma
CSS' selectors specificity was created by imma
It seems that Firefox and Chrome are not evaluating the same way CSS' selectors specificity. So this is the result for a .newsextra font-size:

Chromium Version 63.0.3239.84 (Developer Build) built on Debian 9.3, running on Debian 9.3 (64-bit)
font-size: 11.2px;
0.8em #lnee_399 .newsextra css-133ea-30927.css:54
medium  #lnee_399 ul.latestnews-items li  css-133ea-30927.css:54
0 .lnee ul.latestnews-items  css-133ea-30927.css:24
14px  body  css-dd404-11003.css:6
10px  html  css-dd404-11003.css:6

Firefox ESR 52.5.2 (64-bit)
font-size: 12.8px;
: css-133ea-30927.css:54;
: #lnee_399 ul.latestnews-items li  medium;
: css-133ea-30927.css:54;
: #lnee_399 .newsextra  0.8em;
: css-133ea-30927.css:24;
: .lnee ul.latestnews-items 0px;
: css-ee29c-11003.css:6;
: body  14px;
: css-ee29c-11003.css:6;
: html  10px;

Do you think you could contrive a more specific selector for the font-size taken from module settings? And maybe you could warn the developers who are going out of the way, too.

Please Log in or Create an account to join the conversation.

More
6 years 11 months ago #4956 by syw
Replied by syw on topic CSS' selectors specificity
Hello!

The font-size: medium is used when using 0 as the font size reference of the text (in the layout tab).
As a quick fix to your issue, give it a value similar to the font-size your template uses or a value that suits you most.
I will re-visit this and avoid using 'medium', as it is different from browser to browser unexpectedly.

Olivier.

Please Log in or Create an account to join the conversation.

More
6 years 11 months ago #4958 by imma
Replied by imma on topic CSS' selectors specificity
Anyway, as you can see, in Firefox the selector
#lnee_399 ul.latestnews-items li
has precedence over
#lnee_399 .newsextra
So, in that browser, my setting (module > Layout > Font Size: 80 %) will be overridden by the first selector, no matter how the font-size value is expressed.
Anyway, this is not actually a big problem for us. Just noticed it, and I guess it's not new.
Happy new year.

Please Log in or Create an account to join the conversation.

More
6 years 11 months ago #4959 by syw
Replied by syw on topic CSS' selectors specificity
I see what you mean.

This will be fixed in the next release.

Happy New Year to you as well!

Olivier.
The following user(s) said Thank You: imma

Please Log in or Create an account to join the conversation.