-
Notifications
You must be signed in to change notification settings - Fork 14
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
chore: remove global styles #3554
Conversation
This reverts commit 1334b7a.
🦋 Changeset detectedLatest commit: c8bd686 The changes in this PR will be included in the next version bump. This PR includes changesets to release 17 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@@ -24,7 +24,7 @@ body { | |||
} | |||
|
|||
.docs-story > :first-child { | |||
font-family: var(--bs-body-font-family); | |||
font-family: var(--post-core-font-family-frutiger); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should never use the core tokens somewhere!
Please use the --post-body-font-family
here.
Maybe also use the tokens.get()
function together with the $post-body
map.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The value of --post-body-font-family
is Swiss Post Sans v005
. Should we use Swiss Post Sans v005
or Frutiger Neue For Post
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have implemented your suggestion and will check the correct font-family in the https://github.com/orgs/swisspost/projects/3/views/17?pane=issue&itemId=78602494
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's use the token --post-body-font-family
as is and rename the font name in the @font-face
definition in the font.scss
file to match the new name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fonts.scss file should be adapted like this:
@forward './../variables/options';
@use './../variables/options';
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 900;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Blk.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Blk.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 900;
font-style: italic;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BlkIt.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BlkIt.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 700;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Bold.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Bold.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 700;
font-style: italic;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BdIt.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BdIt.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 400;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Rg.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Rg.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 400;
font-style: italic;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-It.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-It.woff') format('woff');
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fonts are renamed.
// fixes for color in buttons | ||
@use './../mixins/color' as mx-color; | ||
@use './../variables/animation'; | ||
@use './../variables/color'; | ||
|
||
body { | ||
@include type.font-smoothing(); | ||
@include mx-color.colored-background(color.$white); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would say we should remove this temporary button fix now, so we don't have to remember it later (when we implement the new button styles).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is removed.
@@ -24,7 +24,7 @@ body { | |||
} | |||
|
|||
.docs-story > :first-child { | |||
font-family: var(--bs-body-font-family); | |||
font-family: var(--post-core-font-family-frutiger); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's use the token --post-body-font-family
as is and rename the font name in the @font-face
definition in the font.scss
file to match the new name.
@@ -24,7 +24,7 @@ body { | |||
} | |||
|
|||
.docs-story > :first-child { | |||
font-family: var(--bs-body-font-family); | |||
font-family: var(--post-core-font-family-frutiger); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fonts.scss file should be adapted like this:
@forward './../variables/options';
@use './../variables/options';
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 900;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Blk.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Blk.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 900;
font-style: italic;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BlkIt.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BlkIt.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 700;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Bold.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Bold.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 700;
font-style: italic;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BdIt.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-BdIt.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 400;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Rg.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-Rg.woff') format('woff');
}
@font-face {
font-display: swap;
font-family: 'Swiss Post Sans v005';
font-weight: 400;
font-style: italic;
src:
url('#{options.$font-base-path}/FrutigerNeueforPostW05-It.woff2') format('woff2'),
url('#{options.$font-base-path}/FrutigerNeueforPostW05-It.woff') format('woff');
}
Quality Gate passedIssues Measures |
Removed:
A separate ticket is created to fix the broken styles: https://github.com/orgs/swisspost/projects/3/views/12?pane=issue&itemId=80363901