Skip to content
This repository was archived by the owner on Apr 28, 2025. It is now read-only.

Commit 3dbaf75

Browse files
authored
fix(market-sans): fix line-height for new font version (#2586)
1 parent ba6bd93 commit 3dbaf75

File tree

12 files changed

+37
-6
lines changed

12 files changed

+37
-6
lines changed

.changeset/tame-kings-dream.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@ebay/skin": patch
3+
---
4+
5+
fix(market-sans): fix line-height for new font version

.storybook/custom-styles.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
/* Custom Classes for Storybook */
2+
.font-large {
3+
font-size: 200%;
4+
/* line-height: var(--typography-body-line-height); */
5+
}

.storybook/preview.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
import "../src/sass/bundles/skin-full.scss";
2+
import "./custom-styles.css";

.storybook/theme.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default create({
99
appBg: "#EEF8FF",
1010

1111
// Brand assets
12-
brandTitle: "eBayUI Core",
12+
brandTitle: "Skin CSS Framework",
1313
brandUrl: "/",
1414
brandImage:
1515
"https://upload.wikimedia.org/wikipedia/commons/thumb/1/1b/EBay_logo.svg/1280px-EBay_logo.svg.png",

dist/global/global.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ body {
66
Arial,
77
sans-serif;
88
font-size: var(--font-size-default);
9+
line-height: var(--font-line-height-default);
910
-webkit-text-size-adjust: 100%;
1011
}
1112

dist/tokens/evo-core.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,11 @@
181181
--font-size-giant-2: var(--font-size-36);
182182
--font-size-giant-3: var(--font-size-46);
183183
--font-size-giant-4: var(--font-size-64);
184+
/*
185+
Ratio of 20px (base line height) / 14px (body font)
186+
This needs to be unitless for optimal scaling
187+
*/
188+
--font-line-height-250: 1.4286;
184189
--font-weight-regular: 500;
185190
--font-weight-bold: 700;
186191
--spacing-25: 2px;

dist/tokens/evo-light.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,4 +219,6 @@
219219
--motion-duration-long-1: 667ms;
220220
--motion-duration-long-2: 883ms;
221221
--motion-duration-long-3: 1000ms;
222+
/* Typography */
223+
--font-line-height-default: var(--font-line-height-250);
222224
}

docs/custom-styles.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
<style>
2-
2+
/* @TODO - these style should be copied to .storybook/custom-styles.css
3+
and this file should be removed. This file requires a storybook server
4+
restart for style changes to take effect. Custom styles within ./storybook
5+
will take effect immediately.
6+
*/
37
.carousel__list--default-demo li {
48
background-color: grey;
59
font-size: 24px;

src/sass/global/global.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ body {
77

88
font-family: $font-family-default;
99
font-size: var(--font-size-default);
10+
line-height: var(--font-line-height-default);
1011
/* stylelint-disable-next-line plugin/no-unsupported-browser-features */
1112
-webkit-text-size-adjust: 100%;
1213
}

src/sass/snackbar-dialog/stories/font-size.stories.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
export default { title: "Skin/Snackbar Dialog/Font-Size" };
22

33
export const noAction = () => `
4-
<div style="font-size: 200%">
4+
<div class="font-large">
55
<aside aria-label="Notification" aria-live="polite" aria-modal="false" class="snackbar-dialog" role="dialog">
66
<div class="snackbar-dialog__window">
77
<div class="snackbar-dialog__main">
@@ -13,7 +13,7 @@ export const noAction = () => `
1313
`;
1414

1515
export const action = () => `
16-
<div style="font-size: 200%">
16+
<div class="font-large">
1717
<aside aria-label="Notification" aria-live="polite" aria-modal="false" class="snackbar-dialog" role="dialog">
1818
<div class="snackbar-dialog__window">
1919
<div class="snackbar-dialog__main">
@@ -28,7 +28,7 @@ export const action = () => `
2828
`;
2929

3030
export const actionAndDismiss = () => `
31-
<div style="font-size: 200%">
31+
<div class="font-large">
3232
<aside aria-label="Notification" aria-live="polite" aria-modal="false" class="snackbar-dialog" role="dialog">
3333
<div class="snackbar-dialog__window">
3434
<div class="snackbar-dialog__main">
@@ -44,7 +44,7 @@ export const actionAndDismiss = () => `
4444
`;
4545

4646
export const actionsStacked = () => `
47-
<div style="font-size: 200%">
47+
<div class="font-large">
4848
<aside aria-label="Notification" aria-live="polite" aria-modal="false" class="snackbar-dialog" role="dialog">
4949
<div class="snackbar-dialog__window snackbar-dialog__window--column">
5050
<div class="snackbar-dialog__main">

0 commit comments

Comments
 (0)