Skip to content

Commit

Permalink
feat: use typography use case tokens in o-message
Browse files Browse the repository at this point in the history
  • Loading branch information
frshwtr committed Jan 16, 2025
1 parent 3caf962 commit f0b2fb5
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
18 changes: 16 additions & 2 deletions components/o-message/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,10 @@
$inner: index($layouts, 'inner');

.o-message {
@include oPrivateTypographySans($scale: 0);
font-family: oPrivateFoundationGet('o3-typography-use-case-body-base-font-family');
font-size: oPrivateFoundationGet('o3-typography-use-case-body-base-font-size');
font-weight: oPrivateFoundationGet('o3-typography-use-case-body-base-font-weight');
line-height: oPrivateFoundationGet('o3-typography-use-case-body-base-line-height');

.o-message__container {
@include oPrivateGridContainer($bleed: true);
Expand Down Expand Up @@ -80,12 +83,19 @@
}

.o-message__content-highlight {
@include oPrivateTypographySans($weight: 'semibold');
font-family: oPrivateFoundationGet('o3-typography-use-case-body-highlight-font-family');
font-size: oPrivateFoundationGet('o3-typography-use-case-body-highlight-font-size');
font-weight: oPrivateFoundationGet('o3-typography-use-case-body-highlight-font-weight');
line-height: oPrivateFoundationGet('o3-typography-use-case-body-highlight-line-height');
}

.o-message__content-main a,
.o-message__content-additional a {
@include oPrivateTypographyLink();
font-family: oPrivateFoundationGet('o3-typography-use-case-body-link-font-family');
font-size: oPrivateFoundationGet('o3-typography-use-case-body-link-font-size');
font-weight: oPrivateFoundationGet('o3-typography-use-case-body-link-font-weight');
line-height: oPrivateFoundationGet('o3-typography-use-case-body-link-line-height');
border-width: 1px;
text-decoration-thickness: 1px;
}
Expand All @@ -105,6 +115,10 @@

.o-message__actions__secondary {
@include oPrivateTypographyLink();
font-family: oPrivateFoundationGet('o3-typography-use-case-body-link-font-family');
font-size: oPrivateFoundationGet('o3-typography-use-case-body-link-font-size');
font-weight: oPrivateFoundationGet('o3-typography-use-case-body-link-font-weight');
line-height: oPrivateFoundationGet('o3-typography-use-case-body-link-line-height');
white-space: nowrap;
}
}
Expand Down
8 changes: 8 additions & 0 deletions components/o-message/src/scss/_mixins.scss
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,10 @@
'context': $background-color,
)
);
font-family: oPrivateFoundationGet('o3-typography-use-case-body-link-font-family');
font-size: oPrivateFoundationGet('o3-typography-use-case-body-link-font-size');
font-weight: oPrivateFoundationGet('o3-typography-use-case-body-link-font-weight');
line-height: oPrivateFoundationGet('o3-typography-use-case-body-link-line-height');
}

// action button
Expand Down Expand Up @@ -139,6 +143,10 @@
'context': $background-color,
)
);
font-family: oPrivateFoundationGet('o3-typography-use-case-body-link-font-family');
font-size: oPrivateFoundationGet('o3-typography-use-case-body-link-font-size');
font-weight: oPrivateFoundationGet('o3-typography-use-case-body-link-font-weight');
line-height: oPrivateFoundationGet('o3-typography-use-case-body-link-line-height');
}

// state icon, only for alert messages
Expand Down

0 comments on commit f0b2fb5

Please sign in to comment.