keybinding

.keybinding input:{String} -> Node

Displays a keyboard shortcut or key combination. Keys are displayed with platform-appropriate symbols: on macOS, modifier keys use their native symbols (e.g. for Command, for Option).

Keys are separated by +, ,, or - delimiters.

Recognized modifier aliases:

  • Primary modifier (Ctrl/): cmd, command, meta, mod

  • Ctrl: ctrl, control

  • Alt/Option: alt, option

  • Shift: shift

Since +, ,, and - are used as delimiters, their literal key equivalents are plus, comma, and dash.

Any other key name is displayed as-is, capitalized.

Example:

Press .keybinding {Ctrl+Shift+K} to delete the line.

Press .keybinding {Cmd+C} to copy.

Press .keybinding {Ctrl+plus} to zoom in.

Return

a wrapped Keybinding node

Parameters

input

the key combination string, with keys separated by +, ,, or -

Throws

if the input does not contain any key