mirror of
https://github.com/livebook-dev/livebook.git
synced 2024-11-10 09:03:02 +08:00
Fix issue with font-family detection (#157)
This commit is contained in:
parent
c6f9c54f31
commit
e1bab06168
1 changed files with 2 additions and 1 deletions
|
@ -68,7 +68,8 @@ monaco.editor.defineTheme("custom", {
|
|||
// Without this selecting text with whitespace shrinks the whitespace.
|
||||
document.fonts.addEventListener("loadingdone", (event) => {
|
||||
const jetBrainsMonoLoaded = event.fontfaces.some(
|
||||
(fontFace) => fontFace.family === "JetBrains Mono"
|
||||
// font-family may be either "JetBrains Mono" or "\"JetBrains Mono\""
|
||||
(fontFace) => fontFace.family.includes("JetBrains Mono")
|
||||
);
|
||||
|
||||
if (jetBrainsMonoLoaded) {
|
||||
|
|
Loading…
Reference in a new issue