Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: enable hypenation for the Root component #2687

Merged
merged 1 commit into from
Dec 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/twelve-carrots-stare.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@utrecht/root-css": patch
---

Enable hypenation for the Root component.
6 changes: 6 additions & 0 deletions components/root/src/_mixin.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,18 @@
* - the root must be a "positioned ancestor", so elements that are positioned
* outside the normal document flow (`absolute`, `fixed` and `sticky`)
* are positioned relative to the root component.
* - ensure text content fits at 400% zoom by enabling hypenation.
*/
@include reset-font-smoothing;

background-color: var(--utrecht-root-background-color);
block-size: 100%;
color: var(--utrecht-root-color);
font-family: var(--utrecht-root-font-family);
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
inline-size: 100%;
overflow-block: auto;
overflow-inline: auto;
Expand All @@ -36,4 +41,5 @@
-moz-text-size-adjust: none;
-webkit-text-size-adjust: none;
text-size-adjust: none;
word-break: break-word;
}
Loading