fix: move dir attribute to :root (#805)

This commit is contained in:
Ludovic Fernandez
2025-08-30 09:07:09 +01:00
committed by GitHub
parent 82e25c0b0d
commit 3abcde4f8e
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ function computeMenuTranslation(switcher, optionsElement) {
const isOnTop = switcher.dataset.location === 'top';
const isOnBottom = switcher.dataset.location === 'bottom';
const isOnBottomRight = switcher.dataset.location === 'bottom-right';
const isRTL = document.body.dir === 'rtl'
const isRTL = document.documentElement.dir === 'rtl'
// Stuck on the left side of the switcher.
let x = switcherRect.left;