Last active
November 15, 2024 09:17
-
-
Save ipruning/616ede0761825c01dd96fe51f242ccc1 to your computer and use it in GitHub Desktop.
surfingkeys.js
This file contains 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
api.Hints.style(` | |
font-family: 'MonoLisa Nerd Font', monospace; | |
font-size: 12px; | |
`); | |
api.mapkey('<Ctrl-d>', 'Scroll down half page', function () { | |
api.Normal.scroll('pageDown'); | |
}); | |
api.mapkey('<Ctrl-u>', 'Scroll up half page', function () { | |
api.Normal.scroll('pageUp'); | |
}); | |
api.mapkey('ym', 'Copy current page URL as Markdown link', function () { | |
api.Clipboard.write('[' + document.title + '](' + window.location.href + ')'); | |
}); | |
api.unmapAllExcept(['<Ctrl-d>', '<Ctrl-u>', 'E', 'R', 'T', 'e', 'd', 'S', 'D', 'af', 'f', 'i', 'C'], /roamresearch\.com|notion\.so|feishu\.cn|kagi\.com/i); | |
api.unmapAllExcept(['<Ctrl-d>', '<Ctrl-u>', 'E', 'R', 'T', 'e', 'd', 'S', 'D'], /github\.com/i); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment