Problem/Motivation
Currently the subtheme's breakpoints.yml file has "screen" as the name of the group the breakpoints belong to. This can be a little confusing as groups are usually provided by themes. For example, see the screenshot for how the Responsive Image config screen lists them.

Steps to reproduce
Install theme, create subtheme, enable Responsive image module and review the list of breakpoint groups in the dropdown.
Proposed resolution
Use the subtheme name as the default breakpoint group name.
Additional breakpoint groups can be added manually.
Remaining tasks
Is it is simple as changing the "group" from screen to SUBTHEME in the yml file? I can provide a patch.
User interface changes
The sub theme's breakpoint group would now be the name of the theme.
API changes
It shouldn't affect any existing subthemes, only new ones.
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | use_subtheme_name_as_breakpoint_group-3209637-3.patch | 1.61 KB | imclean |
| bs4 breakpoint group.png | 8.51 KB | imclean |
Comments
Comment #2
imclean commentedComment #3
imclean commentedFix patch name for clarity.
Comment #4
imclean commentedThe bootstrap4 theme also uses the breakpoint group "screen" so only one group shows. Perhaps the BS4 breakpoint group should be changed to "Boostrap 4".
Comment #6
vladimirausThanks for the patch.
According to official documentation https://www.drupal.org/docs/theming-drupal/working-with-breakpoints-in-d...
it needs to be called
group: yourtheme.group1so I will update accordingly.I also setup similar task for bootstrap5 theme: https://www.drupal.org/project/bootstrap5/issues/3210540
Comment #7
vladimirausComment #8
dadderley commentedI updated the theme on one of my sites from Bootstrap4 2.1.6 to Bootstrap4 2.1.7.
I use a child theme based on Bootstrap4 2.1.4
As soon as I did the update, the site stopped generating responsive images.
I originally set up the responsive image styles using the Breakpoint group 'screen'.
After doing the update I noticed there is a new Breakpoint group called 'bootstrap4.screen'.
On the Responsive Image screen I changed the Breakpoint group from 'screen' to 'bootstrap4.screen' and it all works.
The group name in the 'bootstrap4.breakpoints.yml' was 'screen'
The group name in the 'mytheme_name.breakpoints.yml' was also 'screen'
I should have spotted that earlier.
I have changed the group name in my child theme's 'mytheme_name.breakpoints.yml' file to 'mytheme_namescreen' so it's all good now.
I understand the issue and why the changes were made to the theme breakpoint functionality.
But when updating the theme killed my site, it did cause much consternation.
Comment #9
vladimirausThanks @dadderley.
I added breaking changes note: https://www.drupal.org/project/bootstrap4/releases/2.1.7
Comment #10
dadderley commented@ VladimirAus
Thanks for your work on this theme.
I really like using it as a base theme. I am using it in 4 projects.