From 51b17e56346c0b82ea39d40cb8f28a4067f877af Mon Sep 17 00:00:00 2001 From: "YUKI \"Piro\" Hiroshi" Date: Mon, 6 Jan 2025 16:01:08 +0900 Subject: [PATCH] Apply direction:rtl to UI on RTL environment #3689 --- webextensions/sidebar/styles/base.css | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/webextensions/sidebar/styles/base.css b/webextensions/sidebar/styles/base.css index 03f08513d..64354239b 100644 --- a/webextensions/sidebar/styles/base.css +++ b/webextensions/sidebar/styles/base.css @@ -246,6 +246,12 @@ tab-sound-button */ { overflow: hidden; } +:root.rtl #pinned-tabs-container, +:root.rtl #normal-tabs-container, +:root.rtl tab-item-substance .caption { + direction: rtl; +} + .virtual-scroll-container { /* We need to use min-height instead of height for a flexbox. */ min-height: 0px; /* this will be updated dynamically by scroll.js */ @@ -547,17 +553,19 @@ tab-item.duplicating tab-item-substance { } -:root.left tab-item tab-twisty { +:root.left tab-item tab-twisty, +:root.right.rtl tab-item tab-twisty { order: -1; } -:root.left tab-item tab-closebox { +:root.left tab-item tab-closebox, +:root.right.rtl tab-item tab-closebox { order: 10000; } -:root.right tab-item tab-twisty { +:root.right:not(.rtl) tab-item tab-twisty { order: 10000; } -:root.right tab-item tab-closebox { +:root.right:not(.rtl) tab-item tab-closebox { order: -1; }