Closed (fixed)
Project:
UI Suite DSFR
Version:
1.15.2
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
24 Sep 2026 at 16:12 UTC
Updated:
9 Oct 2026 at 20:20 UTC
Jump to comment: Most recent
Since the 1.15.2 update, it is now impossible to define images styles specifically for small screens.
According to the DSFR documentation, this is what the breakpoint ui_suite_dsfr.screen-xs-max was supposed to be used for.
In my opinion it's the only "max-width" breakpoint that we need, since we use the fallback style for browsers that do not support the WEBP format (and not for the small screens).
Could we please bring it back?
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
just_like_good_vibesHello spryah,
we only recently introduced the breakpoints in the theme. what impossibility do you refer to ?
you mean there is a missing breakpoint in the ones that were introduced?
The breakpoints are mobile-first on purpose: each one starts at a DSFR width and applies to everything above it. You are right that nothing covers screens under 576px, so small screens only get the fallback image style, without multipliers.
would you tell us more about your exact case please ? Which responsive image style and mappings did you use with screen-xs-max, and was it combined with the other breakpoints or used alone?
We could add a base breakpoint with an empty media query, at the lowest weight, rather than bringing back a max-width one. It applies to all screens, so in a picture it catches everything the larger breakpoints don't, which is small screens. Used alone, it gives a plain img with srcset. It also follows DSFR, where XS is the default with no media query. Would that work for you?
Comment #3
spryahHi there!
Sorry, brain broke after reading only the second MR.
We were using our own theme breakpoint file before this one was added, then we decided to use the new ui_suite_dsfr breakpoint file and found out that a "base" option was missing.
Here's an example of how we proceed for a 16:9 image in a 792px container:
In the way we proceed, the "fallback" option should not be used for small screens as it would lead to inconsistent behaviors in older browsers. Instead, we add a "base" option for small screens, without any media query definition, and we use the "fallback" option for browsers that do not support responsive format, and by extension, the WebP format.
As opposed to previously stated, no "max-width" option should be used.
Would that work for you?
Comment #4
spryahComment #6
spryahComment #7
just_like_good_vibesThanks Soryah for proposing the code i will review and merge soon.
Comment #9
just_like_good_vibes