Add base text-rendering layer to v2 theme
Apply font smoothing (antialiased / grayscale) and overflow-wrap on the document base, mirroring the root defaults Radix Themes sets. Placed in @layer base so any utility can override it. The body font is left to Tailwind's preflight, which already applies --font-sans. Signed-off-by: Émile Ré <emile@probo.com>
This commit is contained in:
@@ -94,3 +94,21 @@
|
|||||||
--font-weight-medium: 500;
|
--font-weight-medium: 500;
|
||||||
--font-weight-bold: 700;
|
--font-weight-bold: 700;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* ---------------------------------------------------------------------------
|
||||||
|
* Base text rendering
|
||||||
|
*
|
||||||
|
* Global polish mirroring Radix's root defaults. The body font itself is not
|
||||||
|
* set here: Tailwind's preflight already applies var(--font-sans) (→ Inter)
|
||||||
|
* via --default-font-family, so it inherits automatically.
|
||||||
|
* ------------------------------------------------------------------------- */
|
||||||
|
@layer base {
|
||||||
|
html {
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
-moz-osx-font-smoothing: grayscale;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
overflow-wrap: break-word;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user