From e81c218074fde95c8a079d878cf09f89f6c92d9e Mon Sep 17 00:00:00 2001 From: Lazaro Alonso Date: Sat, 31 Aug 2024 14:11:07 +0200 Subject: [PATCH] actually do no ligatures --- docs/src/.vitepress/theme/style.css | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/src/.vitepress/theme/style.css b/docs/src/.vitepress/theme/style.css index 26e8678a..57933a7e 100644 --- a/docs/src/.vitepress/theme/style.css +++ b/docs/src/.vitepress/theme/style.css @@ -30,23 +30,23 @@ https://github.com/vuejs/vitepress/blob/main/src/client/theme-default/styles/var /* Code Snippet font */ --vp-font-family-mono: JuliaMono-Regular, monospace; } -/* -Disable contextual alternates (kind of like ligatures but different) in monospace, -which turns `/>` to an up arrow and `|>` (the Julia pipe symbol) to an up arrow as well. -This is pretty bad for Julia folks reading even though copy+paste retains the same text. -*/ + /* Target elements with class 'mono' */ -.mono { - /* Disable contextual alternates */ - font-feature-settings: "calt" 0; +.mono-no-substitutions { + font-family: "JuliaMono-Light", monospace; + font-feature-settings: "calt" off; } -/* Apply monospace font to pre elements within .mono */ -.mono pre { + +/* Alternatively, you can use the following if you prefer: */ +.mono-no-substitutions-alt { font-family: "JuliaMono-Light", monospace; + font-variant-ligatures: none; } -/* Apply monospace font to code elements within .mono */ -.mono code { + +/* If you want to apply this globally to all monospace text: */ +pre, code { font-family: "JuliaMono-Light", monospace; + font-feature-settings: "calt" off; } /**