Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Problem/Motivation
RTL styles of Vertical tabs in Seven theme has an unneeded right margin.
Checking the code in seven.libraries.yml
it seems that Seven tries to remove the inherited Vertical tabs styles, but since it is already overridden by Stable, the intention cannot achieve its purpose.
Steps to reproduce
- Install Drupal with the Standard profile.
- Enable Language module and add an RTL language (e.g. Hebrew).
- Visit
[docroot]/he/admin/structure/block/manage/bartik_breadcrumbs
and check the block visibility conditions.
Proposed resolution
Change the path of the removed CSS asset of core/drupal.vertical-tabs
.
Remaining tasks
The usuals: patch, review, commit.
User interface changes
Better RTL styles.
API changes
Nothing.
Data model changes
Nothing.
Comment | File | Size | Author |
---|---|---|---|
#3 | vertical-tabs-spacing.png | 46.95 KB | Thangaraj Moorthi |
#2 | core-seven_vertical_tabs-3055760-2.patch | 436 bytes | huzooka |
core-seven_vertical_tabs-after.png | 214.57 KB | huzooka | |
core-seven_vertical_tabs-before.png | 220.49 KB | huzooka |
Comments
Comment #2
huzookaComment #3
Thangaraj Moorthi@huzooka #2 applied your patch,
Its working fine in 8.8.0-dev
Comment #4
John Cook CreditAttribution: John Cook at Creode commentedThank you @huzooka and @thangaraj.moorthi.
It took me a while to figure out what was going on.
misc/vertical-tabs.css
sets a margin-right on the vertical tabs. (This is currently removed by seven.info.yml.)/core/themes/stable/css/core/vertical-tabs.css
also sets the right margin.Seven then inherits the vertical-tabs style from Stable, undoing what seven.info.yml was trying to do.
This patch changes the info.yml file so that the CSS from stable is removed as well, getting rid of the rogue margins.
This is the image from @thangaraj.moorthi inlined:
I've added 'Needs frontend framework manager review' for them to review, but I'm also setting this to RTBC.
Comment #6
lauriiiCommitted df568de and pushed to 8.8.x. Also cherry-picked to 8.7.x. Thanks!