Skip to content

Instantly share code, notes, and snippets.

@bittner
Created February 28, 2019 22:50
Show Gist options
  • Save bittner/f3e2804e06c663510e939ca569ee483e to your computer and use it in GitHub Desktop.
Save bittner/f3e2804e06c663510e939ca569ee483e to your computer and use it in GitHub Desktop.
Keyboard keys markup in MarkDown

Ctrl + Alt + Space

@matschaffer
Copy link

hot

@void32
Copy link

void32 commented Dec 14, 2021

Awesome!

@HighHarmonics
Copy link

👍

@X3VI
Copy link

X3VI commented Apr 16, 2022

Thank you so much haha

@hsuanxyz
Copy link

hsuanxyz commented Apr 26, 2022

Hi, I made a tool to capture shortcuts and generate kbd tags. Kbd Generator

image

@padupe
Copy link

padupe commented May 22, 2022

Very Good!

@benwaffle
Copy link

Doesn't seem to work on mac, just use <kbd>key</kbd>

@aaryaniitd
Copy link

Thanks! Didn't expect it to be this simple.

@benkoshy
Copy link

benkoshy commented Jul 25, 2022

The Markdown to make it work:

image

<kbd> Ctrl </kbd> +  <kbd> Alt </kbd>  + <kbd> Del </kbd>

The Result:

Ctrl + Alt + Del

@twisted-nematic57
Copy link

Hi, I made a tool to capture shortcuts and generate kbd tags. Kbd Generator

image

Why thank you kind sir/ma'm.

@sloanlance
Copy link

sloanlance commented Oct 17, 2022

The official syntax for representing keyboard keys, <kbd>…</kbd>, using HTML elements, produces output similar to Markdown syntax for code and commands, `…`. Similar, but not exactly the same.

HTML Markdown
<kbd>Keyname</kbd> `Keyname`
Keyname Keyname
Light background,
with a thin, dark border.
Darker background,
without a border

@s0urce-c0de
Copy link

How do you make the text look like that for Windows shortcuts/keyboard keys?

⊞ Win+Tab ↹

<kbd>&#8862; Win</kbd>+<kbd>Tab &#8633;</kbd>

@Polda18
Copy link

Polda18 commented Nov 10, 2023

Hi, I made a tool to capture shortcuts and generate kbd tags. Kbd Generator

image

This is a great site. Sadly it can't detect Ctrl+Alt+Del on Windows, because that key combination obviously brings up system screen, and every other app can't therefore intercept it.

@twisted-nematic57
Copy link

@Polda18 well you could just do something like Ctrl-Alt-A instead and then replace A with Del

@Polda18
Copy link

Polda18 commented Nov 10, 2023

True. It's easy enough.

@macx
Copy link

macx commented Mar 31, 2024

Wow, @hsuanxyz for the Generator. Found this super useful for authoring my texts and documentations. I also recommended my students on https://hawk-gt1191.de/assets/#typografie.

@Polda18
Copy link

Polda18 commented Apr 21, 2024

The only downside I see with this tool is that it only returns Mac binding, not Windows/Linux binding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment