From 06ee35b7c2ce85e4d0bf1a81fc1c204b8936809a Mon Sep 17 00:00:00 2001 From: Johannes Marbach Date: Mon, 19 Aug 2024 13:22:03 +0200 Subject: [PATCH] Switch to STIX, Cambria, Noto and Dejavu for better support across platforms --- assets/scss/_variables_project.scss | 17 ++++++++--------- .../internal/newsfragments/1919.clarification | 2 +- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/assets/scss/_variables_project.scss b/assets/scss/_variables_project.scss index 0521c6eb..c2ec03c6 100644 --- a/assets/scss/_variables_project.scss +++ b/assets/scss/_variables_project.scss @@ -42,16 +42,15 @@ $td-enable-google-fonts: false; /* * The $font-family-sans-serif definition here overrides the default value set by docsy * (https://github.com/matrix-org/docsy/blob/66a4e61d2d34edc7196b9df83a7d09cd4af14b47/assets/scss/_variables.scss#L68) - * and: - * - * - Adds "Inter" to the front (making it the default) - * - Inserts "Arial Unicode MS" before "Arial" (because the former contains more mathematical glyphs) - * - * The Inter font itself is loaded via stylesheet links layouts/partials/hooks/head-end.html. */ -$font-family-sans-serif: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, - "Helvetica Neue", Arial Unicode MS, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", - "Segoe UI Symbol"; +$font-family-sans-serif: + // Add "Inter" to the front, making it the default. The font itself is loaded via stylesheet + // links in layouts/partials/hooks/head-end.html. + "Inter", + -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", + // Insert fonts suited for mathematical symbols on different platforms before "Arial" + "STIX Two Math", "Cambria Math", "Noto Sans Math", "Dejavu Sans", + Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; // Disable smooth scrolling as it makes TOC highlighting jump during the transition. $enable-smooth-scroll: false; diff --git a/changelogs/internal/newsfragments/1919.clarification b/changelogs/internal/newsfragments/1919.clarification index 8bf349ce..478404e9 100644 --- a/changelogs/internal/newsfragments/1919.clarification +++ b/changelogs/internal/newsfragments/1919.clarification @@ -1 +1 @@ -Prefer Arial Unicode MS over Arial for better support of mathematical symbols. +Use dedicated fonts for better support of mathematical symbols.