Hammerspoon is a small macOS automation tool. You can write Lua code blocks that can handle keyboard events and more. Firefox used to have a File > Email Link menu that you could assign a shortcut in macOS keyboard shortcuts. One fine day Firefox or macOS moved this under File