mirror of
https://github.com/logseq/logseq.git
synced 2026-05-16 08:52:20 +00:00
57 lines
1.8 KiB
CSS
57 lines
1.8 KiB
CSS
/* RTL (right-to-left) layout overrides for Arabic and Farsi locales.
|
|
Applied when document.documentElement has dir="rtl".
|
|
|
|
Strategy: pin all UI chrome (sidebars, header, toolbar) back to LTR so
|
|
the flex layout and sidebar positions are unaffected. Only page/note
|
|
content inherits the RTL direction. */
|
|
|
|
/* ── UI chrome: pin to LTR ──────────────────────────────────────────────── */
|
|
/* Prevents flex row-reversal in the main layout container */
|
|
[dir="rtl"] #main-container {
|
|
direction: ltr;
|
|
}
|
|
|
|
/* Left sidebar stays on the left */
|
|
[dir="rtl"] #left-sidebar,
|
|
[dir="rtl"] .left-sidebar-inner {
|
|
direction: ltr;
|
|
}
|
|
|
|
/* Right sidebar stays on the right */
|
|
[dir="rtl"] .cp__right-sidebar {
|
|
direction: ltr;
|
|
}
|
|
|
|
/* Header / toolbar */
|
|
[dir="rtl"] #head {
|
|
direction: ltr;
|
|
}
|
|
|
|
/* ── Page/note content: inherit RTL from <html> ──────────────────────────── */
|
|
/* Explicitly re-enable RTL for the main content area */
|
|
[dir="rtl"] .cp__sidebar-main-content {
|
|
direction: rtl;
|
|
}
|
|
|
|
/* ── Toast notifications: mirror icon position ───────────────────────────── */
|
|
[dir="rtl"] .ui__toaster-viewport > li.has-variant-icon {
|
|
padding-left: 1.25rem;
|
|
padding-right: 3rem;
|
|
}
|
|
|
|
[dir="rtl"] .ui__toaster-viewport > li.has-variant-icon .variant-icon {
|
|
left: auto;
|
|
right: 14px;
|
|
}
|
|
|
|
/* ── Alert: mirror icon and content padding ──────────────────────────────── */
|
|
[dir="rtl"] .ui__alert > .ui__icon {
|
|
left: auto;
|
|
right: 1rem;
|
|
}
|
|
|
|
[dir="rtl"] .ui__alert > .ui__icon ~ * {
|
|
padding-left: 0;
|
|
padding-right: 1.75rem;
|
|
}
|