Skip to content

Commit 298876a

Browse files
Core: Update default font stack (DevExpress#31083)
Co-authored-by: Roman Semenov <[email protected]>
1 parent 70635db commit 298876a

File tree

9 files changed

+13
-12
lines changed

9 files changed

+13
-12
lines changed
1.25 KB
Loading

packages/devextreme-scss/scss/widgets/fluent/_colors.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ $fluent-color-theme-modificator: null !default;
2222
* $name 10. Font family
2323
* $type text
2424
*/
25-
$base-font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, avenir next, avenir, helvetica neue, helvetica, Cantarell, Ubuntu, roboto, noto, arial, sans-serif !default; // stylelint-disable-line value-keyword-case
25+
$base-font-family: segoe ui, -apple-system, blinkmacsystemfont, avenir next, avenir, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif !default; // stylelint-disable-line value-keyword-case
2626

2727
/**
2828
* $name 30. Page background color

packages/devextreme-scss/scss/widgets/generic/_colors.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ $generic-color-postfix: null !default;
1010
* $name 10. Font family
1111
* $type text
1212
*/
13-
$base-font-family: 'Helvetica Neue', 'Segoe UI', helvetica, verdana, sans-serif !default;
13+
$base-font-family: -apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif !default;
1414

1515
/**
1616
* $name 10. Accent color

packages/devextreme-scss/scss/widgets/material/_colors.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ $material-color-theme-modificator: null !default;
1717
* $name 10. Font family
1818
* $type text
1919
*/
20-
$base-font-family: "Roboto", "RobotoFallback", "Noto Kufi Arabic", "Helvetica", "Arial", sans-serif !default;
20+
$base-font-family: roboto, -apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, noto, helvetica, arial, sans-serif !default;
2121

2222
/**
2323
* $name 20. Text color

packages/devextreme-themebuilder/tests/data/compilation-results/no-changes-css.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
export default `.dx-accordion {
2-
font-family: "Helvetica Neue","Segoe UI",helvetica,verdana,sans-serif;
2+
font-family: -apple-system,blinkmacsystemfont,avenir next,avenir,segoe ui,helvetica neue,adwaita sans,cantarell,ubuntu,roboto,noto,helvetica,arial,sans-serif;
33
color: #337ab7;
44
background-image: url(icons/icons.woff2);
55
}

packages/devextreme-themebuilder/tests/data/compilation-results/no-changes-meta.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
const meta: { [key: string]: string } = {
2-
'$base-font-family': '"Helvetica Neue", "Segoe UI", helvetica, verdana, sans-serif',
2+
'$base-font-family': "-apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif",
33
'$base-accent': '#337ab7',
44
'$accordion-title-color': '#337ab7',
55
'$accordion-item-title-opened-bg': 'transparent',

packages/devextreme-themebuilder/tests/data/scss/widgets/generic/_colors.scss

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ $base-accent: null !default;
99

1010

1111
@if $color == "light" {
12-
$base-font-family: 'Helvetica Neue','Segoe UI',helvetica,verdana,sans-serif !default;
12+
$base-font-family: -apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif !default;
13+
1314
$base-accent: #337ab7 !default;
1415
}
1516

packages/devextreme-themebuilder/tests/modules/compile-manager.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ describe('Compile manager - integration test on test sass', () => {
5151
outColorScheme: 'test-theme',
5252
}).then((result) => {
5353
expect(result.css).toBe(`.dx-swatch-test-theme .dx-accordion {
54-
font-family: "Helvetica Neue","Segoe UI",helvetica,verdana,sans-serif;
54+
font-family: -apple-system,blinkmacsystemfont,avenir next,avenir,segoe ui,helvetica neue,adwaita sans,cantarell,ubuntu,roboto,noto,helvetica,arial,sans-serif;
5555
color: #337ab7;
5656
background-image: url(icons/icons.woff2);
5757
}
@@ -69,7 +69,7 @@ describe('Compile manager - integration test on test sass', () => {
6969
assetsBasePath: 'base-path',
7070
}).then((result) => {
7171
expect(result.css).toBe(`.dx-accordion {
72-
font-family: "Helvetica Neue","Segoe UI",helvetica,verdana,sans-serif;
72+
font-family: -apple-system,blinkmacsystemfont,avenir next,avenir,segoe ui,helvetica neue,adwaita sans,cantarell,ubuntu,roboto,noto,helvetica,arial,sans-serif;
7373
color: #337ab7;
7474
background-image: url(base-path/icons/icons.woff2);
7575
}
@@ -88,7 +88,7 @@ describe('Compile manager - integration test on test sass', () => {
8888
}).then((result) => {
8989
expect(result.css).toBe('');
9090
expect(result.compiledMetadata).toEqual({
91-
'$base-font-family': '"Helvetica Neue", "Segoe UI", helvetica, verdana, sans-serif',
91+
"$base-font-family": "-apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif",
9292
'$base-accent': '#337ab7',
9393
});
9494
});
@@ -100,7 +100,7 @@ describe('Compile manager - integration test on test sass', () => {
100100
noClean: true,
101101
}).then((result) => {
102102
expect(result.css).toBe(`.dx-accordion {
103-
font-family: "Helvetica Neue", "Segoe UI", helvetica, verdana, sans-serif;
103+
font-family: -apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif;
104104
color: #337ab7;
105105
background-image: url(icons/icons.woff2);
106106
}

packages/devextreme-themebuilder/tests/modules/compiler.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const includePaths = [path.join(dataPath, 'scss', 'widgets', 'generic'), path.jo
1818
const file = path.join(dataPath, 'scss', 'bundles', 'dx.light.scss');
1919

2020
const expectedCss = ({
21-
fontFamily = '"Helvetica Neue", "Segoe UI", helvetica, verdana, sans-serif',
21+
fontFamily = '-apple-system, blinkmacsystemfont, avenir next, avenir, segoe ui, helvetica neue, adwaita sans, cantarell, ubuntu, roboto, noto, helvetica, arial, sans-serif',
2222
color = '#337ab7',
2323
bgColor = 'transparent'
2424
} = {}) => `.dx-accordion {
@@ -118,7 +118,7 @@ describe('compile', () => {
118118
// compiled css
119119
expect(data.result.css.toString()).toBe(
120120
'.dx-accordion{font-family:'
121-
+ '"Helvetica Neue","Segoe UI",helvetica,verdana,sans-serif;'
121+
+ '-apple-system,blinkmacsystemfont,avenir next,avenir,segoe ui,helvetica neue,adwaita sans,cantarell,ubuntu,roboto,noto,helvetica,arial,sans-serif;'
122122
+ 'color:#337ab7;background-image:url(icons/icons.woff2)}.dx-accordion '
123123
+ '.from-base{background-color:transparent;color:#337ab7}.extra-class{color:red}',
124124
);

0 commit comments

Comments
 (0)