Skip to content

Commit 2d68ecf

Browse files
committed
add a comment
1 parent 3a969f4 commit 2d68ecf

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

docs/src/BrandingCssVarsProvider.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,8 @@ export default function BrandingCssVarsProvider(props: {
151151
}
152152
}, []);
153153
useEnhancedEffect(() => {
154+
// This is required to ensure that the layer order is declared first in the head
155+
// because when the direction is RTL on the client, emotion reinserts the RTL styles back to the top of the insertion point.
154156
if (direction === 'rtl') {
155157
const head = document.querySelector('head');
156158
if (head) {

0 commit comments

Comments
 (0)