Developers · Gutenberg

Keyboard Shortcuts block for WordPress

Display a keyboard shortcut reference sheet with Mac and Windows variants, categories, and rich styling.

Get Blockenberg

Free Gutenberg block in Blockenberg. The inspector controls and front-end behavior on this page come from this block’s source, not a shared stub.

Get Blockenberg

What it actually does

Display a keyboard shortcut reference sheet with Mac and Windows variants, categories, and rich styling.

Inspector panels on this block: Sheet Settings, Sections & Shortcuts. Those titles come from index.js, not from a shared template.

Behavior controls: “Platform” options: Mac only, Windows only, Both (Mac / Win).

Where to find it

Gutenberg inserter → Developers → search “Keyboard Shortcuts” (block name `blockenberg/keyboard-shortcut` in block.json). Style it in the sidebar after insert.

How to use Keyboard Shortcuts block for WordPress

  1. Install Blockenberg. Install from WordPress.org and activate the plugin.
  2. Insert the block. Edit a page, click +, search for “Keyboard Shortcuts”, insert it. Category: Developers.
  3. Configure inspector controls that exist on this block. Open Sheet Settings. Set “Sheet Settings — Title”, “Show Title”, “Platform”, “Section Heading”.
  4. Check the published page. The view script reads HTML data attributes: data-opts, data-rendered. The block editor preview may not run the same view script.

Inspector controls from this block’s code

ControlWhat the code does
Sheet Settings — TitleText field in the inspector. block.json default: Keyboard Shortcuts. Saved as `sheetTitle`.
Show TitleOn/off toggle in the inspector. On by default. Saved as `showTitle`.
PlatformSelect control; the chosen value is saved on the block. Options: Mac only; Windows only; Both (Mac / Win). block.json default: both. Saved as `platform`.
Section HeadingText field in the inspector. Saved as `sections`.
DescriptionText field in the inspector. Saved as `sections`.
Mac Keys (space-separated)Text field in the inspector. Saved as `sections`.
Win Keys (space-separated)Text field in the inspector. Saved as `sections`.
Font SizeNumeric range control in the inspector. Range 10–20. block.json default: 14. Saved as `fontSize`.
Section Heading SizeNumeric range control in the inspector. Range 9–18. block.json default: 12. Saved as `headingFontSize`.
Key Font SizeNumeric range control in the inspector. Range 9–18. block.json default: 12. Saved as `keyFontSize`.
Line Height (%)Numeric range control in the inspector. Range 120–220. block.json default: 160. Saved as `lineHeight`.
Border RadiusNumeric range control in the inspector. Range 0–24. block.json default: 12. Saved as `borderRadius`.
Key RadiusNumeric range control in the inspector. Range 2–12. block.json default: 6. Saved as `keyRadius`.
Colors — BackgroundColor control in the inspector. block.json default: #ffffff. Saved as `bgColor`.
Colors — BorderColor control in the inspector. block.json default: #e5e7eb. Saved as `borderColor`.
Colors — TitleColor control in the inspector. block.json default: #111827. Saved as `titleColor`.
Section BGColor control in the inspector. block.json default: #f8fafc. Saved as `headingBg`.
Section TextColor control in the inspector. block.json default: #374151. Saved as `headingColor`.
Section BorderColor control in the inspector. block.json default: #e5e7eb. Saved as `headingBorderColor`.
Description TextColor control in the inspector. block.json default: #374151. Saved as `descColor`.
Key BGColor control in the inspector. block.json default: #f1f5f9. Saved as `keyBg`.
Key BorderColor control in the inspector. block.json default: #cbd5e1. Saved as `keyBorderColor`.
Key TextColor control in the inspector. block.json default: #1e293b. Saved as `keyColor`.
Mac LabelColor control in the inspector. block.json default: #6366f1. Saved as `macAccentColor`.
Win LabelColor control in the inspector. block.json default: #0ea5e9. Saved as `winAccentColor`.
Row SeparatorColor control in the inspector. block.json default: #f1f5f9. Saved as `separatorColor`.

What the front-end script actually does

When this is the right block

Notes from the implementation

viewScript: this folder’s frontend.js is enqueued on the front end for this block.

FAQ

How do I add the Keyboard Shortcuts block in WordPress?

Install Blockenberg from WordPress.org, edit a page in the block editor, click +, and search for “Keyboard Shortcuts”. It sits under Developers. After insert, open Sheet Settings and set “Sheet Settings — Title”, “Show Title”, “Platform”, “Section Heading”.

What makes Keyboard Shortcuts different from other Blockenberg blocks?

Display a keyboard shortcut reference sheet with Mac and Windows variants, categories, and rich styling. Inspector labels on this block include “Sheet Settings — Title”, “Show Title”, “Platform”, “Section Heading”.

Is the Keyboard Shortcuts Gutenberg block free?

Yes. Keyboard Shortcuts ships inside Blockenberg. Get the plugin from WordPress.org — no paid add-on is required for this block.

Can I style Keyboard Shortcuts to match my theme?

Yes. Blockenberg’s shared typography and color panels apply here, plus any block-specific style controls listed on this page (panels: Sheet Settings, Sections & Shortcuts).

Related developers blocks

Get Blockenberg

Install Blockenberg from WordPress.org, then insert Keyboard Shortcuts from the Gutenberg inserter.

Get Blockenberg