Sébastien Bouchard
Forum Replies Created
-
My custom temporary fix was to add the following code as additional CSS in the Twenty-Twenty-Five theme:
.wp-block-navigation.tw-nav-active-thick-border li.current-menu-item > a, .wp-block-navigation.tw-nav-hover-thick-border li a:hover {text-decoration-thickness:2px !important;}
That’s just a copy-paste from Twentig’s code with “!important” added at the end.
The problem comes from wp-content/themes/twentytwentyfive/style.css @ lines 21-24:
a {
text-decoration-thickness: 1px !important;
text-underline-offset: .1em;
}Forum: Fixing WordPress
In reply to: Where is custom global CSS in twentytwentyfive?On Twenty-Twenty-Five theme:
- Appearance > Editor (site editor)
- Styles > Edit styles (pencil icon)
- Click on Styles menu icon (?) > Additional CSS
There you can set custom CSS for the whole site.
Tested OK on Firefox and Chromium.
Thanks ! Merci !
Updated status: NOT RESOLVED !
I got a reply from Emilio Cobos álvarez (:emilio) on my bug report:
This is expected given how fractional pixel scales work?
(…)
At some DPIs, your viewport size could be
1023.3333px
, which causes what you’re seeing. We (and all browsers nowadays) support@media
expressions that don’t suffer from this, e.g. your example could be:@media (width < 768px) { .tw-sm-hidden { display:none !important; } } @media (width >= 768px) and (width < 1024px) { .tw-md-hidden { display:none !important; } } @media (width >= 1024px) { .tw-lg-hidden { display:none !important; } }
Which would always work.
I tested this and can confirm this seems to solve the problem ! Please check my bug report to get the full story.
I made this bug report to Mozilla and Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=1940617
I can now confirm the problem comes from Firefox (version 133.0.3 (64-bit), Snap for Ubuntu).
In order to isolate the problem from any outside interference, I did this simple test:
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<style>
@media (max-width: 767px) {
.tw-sm-hidden {
display:none !important;
}
}
@media (min-width: 768px) and (max-width: 1023px) {
.tw-md-hidden {
display:none !important;
}
}
@media (min-width: 1024px) {
.tw-lg-hidden {
display:none !important;
}
}
</style>
</head>
<body>
<h3>3 pictures sizes, one for each: desktop, tablet, mobile</h3>
<img src="https://picsum.photos/id/26/900/600" alt="" width="900" height="600" class="tw-sm-hidden tw-md-hidden">
<img src="https://picsum.photos/id/26/600/400" alt="" width="600" height="400" class="tw-sm-hidden tw-lg-hidden">
<img src="https://picsum.photos/id/26/300/200" alt="" width="300" height="200" class="tw-md-hidden tw-lg-hidden">
</body>
</html>It works fine in my Chromium browser, but not in Firefox, where all 3 pictures are displayed when the media width is at 1024px. I should make a bug report to Firefox…
Sorry, I still don’t have much time for this, as I am still in the early design process… But I am curious…
After a bit more investigation, I find the problem only occurs with Firefox (version 133.0.3 (64-bit), Snap for Ubuntu).
I am talking about this Twentig extra feature for blocks: visibility. (I checked and can now confirm ?visibilité? = visibility.)
I wasn’t talking about a specific logo. Just put any images, and set one for desktop, one for tablet, and one for mobile. For example, the image for desktop only will be:
- (off) Hide on desktop
- (on) Hide on tablet
- (on) Hide on mobile
Now, set your viewport or window width to 1024px. You can do that using the developer tools in Firefox or Chrome.
- Firefox: just press Ctrl+Shift+M. Then set the device width to 1024px.
- Chrome: press Ctrl+Shift+I to get into the developer tools, then press Ctrl+Shift+M. Then set the device width to 1024px.
BUG: At 1024px width, all images are showing. The Twentig visibility controls are just not working.
Please note that this bug can also occur when just randomly changing the window size and accidentally hitting the 1024px break point… You don’t need to have an old screen or use developer tools to run into this bug… It’s very easy to get caught up in this chaos…
- This reply was modified 1 month, 3 weeks ago by Sébastien Bouchard.
On the Twenty Twenty-Four theme, not much other plugins being used…