Skip to content

Commit

Permalink
fix: alter -text-font-* classes
Browse files Browse the repository at this point in the history
  • Loading branch information
ella-etch committed Feb 21, 2024
1 parent d18900f commit 00ab48f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 22 deletions.
24 changes: 3 additions & 21 deletions components/content/Text/Text.css
Original file line number Diff line number Diff line change
@@ -1,38 +1,20 @@
/* Font */

.diamond-text-font-body {
font-family: var(--diamond-font-family);
font-size: var(--diamond-font-size-base);
font-weight: var(--diamond-font-weight-base);
line-height: var(--diamond-font-line-height);
text-wrap: pretty;
}

.diamond-text-font-heading,
.diamond-text-font-h1,
.diamond-text-font-h2,
.diamond-text-font-h3,
.diamond-text-font-h4 {
.diamond-text-font-heading {
font-family: var(--diamond-font-family-heading);
font-weight: var(--diamond-font-weight-bold);
line-height: var(--diamond-font-line-height-heading);
text-wrap: balance;
}

.diamond-text-font-h1 {
font-size: var(--diamond-font-size-h1);
}

.diamond-text-font-h2 {
font-size: var(--diamond-font-size-h2);
}

.diamond-text-font-h3 {
font-size: var(--diamond-font-size-h3);
}

.diamond-text-font-h4 {
font-size: var(--diamond-font-size-h4);
}

/* Size */

.diamond-text-size-default {
Expand Down
2 changes: 1 addition & 1 deletion components/content/Text/Text.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default {
control: {
type: 'select',
},
options: ['body', 'heading', 'h1', 'h2', 'h3', 'h4'],
options: ['body', 'heading'],
description:
'Sets a combination of CSS properties to match the selected font style.',
},
Expand Down
1 change: 1 addition & 0 deletions styles/tokens/font.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
:root {
--diamond-font-family: -apple-system, system-ui, blinkmacsystemfont, roboto,
helvetica, arial, sans-serif;
--diamond-font-family-heading: var(--diamond-font-family);

--diamond-font-line-height: 1.5;
--diamond-font-line-height-sm: 1.25;
Expand Down

0 comments on commit 00ab48f

Please sign in to comment.