Last active
February 18, 2025 18:25
-
-
Save 5310/2294ecaa3f23e5c1b8c2fed105a7ad13 to your computer and use it in GitHub Desktop.
Use Fira Code for code-blocks on Workflowy #userscript
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Workflowy Code to Fira Code | |
// @version 2025-02-18 | |
// @description Uses Fira Code (or the Nerd Font variant) for all inline code or code-block entries on Workflowy | |
// @author 5310 | |
// @match https://workflowy.com/ | |
// @icon https://www.google.com/s2/favicons?sz=64&domain=workflowy.com | |
// @grant none | |
// @license MIT | |
// ==/UserScript== | |
const addStyle = css => { | |
var n = document.createElement('style') | |
n.type = "text/css" | |
n.innerHTML = css | |
document.getElementsByTagName('head')[0].appendChild(n) | |
} | |
(function() { | |
'use strict'; | |
addStyle(` | |
.code-block > .name > .content, code { | |
font-family: "FiraCode Nerd Font", "Fira Code", sans-serif !important; | |
} | |
`) | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment