Problem/Motivation
For the photo gallery block, there is css in place which shows the view mode option (grid / masonry) as icons in the form display.
The css for this however relies on the class which uses the option label (added via js in block-layouts.admin.js). This js strips out some stuff (example: optional). When the optional label is translated it doesn't get stripped and the styling doesn't apply.
Steps to reproduce
- Translate the "optional" string
- Add a photo gallery block in that language
- You'll see the view mode options don't have a icon
![]()
Proposed resolution
- Update styling for photo gallery icons so it uses the correct view mode selector (.view-mode-photo-gallery_grid & .view-mode-photo-gallery_masonry) instead of the class added by js
- Is the js in https://git.drupalcode.org/project/rocketship_core/-/blob/6.2.x/js/block... still needed in the first place?
| Comment | File | Size | Author |
|---|---|---|---|
| photo-gallery-missing-layout-icons.png | 45.76 KB | rubendello |
Issue fork rocketship_core-3561192
Show commands
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 #5
l_vandamme commentedCommitted on 6.2.x and released as part of https://www.drupal.org/project/rocketship_core/releases/6.2.4
Comment #7
l_vandamme commented