mirror of
https://github.com/ueberdosis/tiptap.git
synced 2025-06-07 17:43:49 +08:00
docs: make all node keyboard shortcuts a table
This commit is contained in:
parent
6863626a7a
commit
a89e2eed29
@ -13,7 +13,7 @@ Funfact: We built a [keyboard shortcut learning app](https://mouseless.app), to
|
||||
Most of the core extensions register their own keyboard shortcuts. Depending on what set of extension you use, not all of the below listed keyboard shortcuts work for your editor.
|
||||
|
||||
### Essentials
|
||||
| Action | Windows/Linux | macOS |
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ------------------------ | ------------------------------- | --------------------------- |
|
||||
| Copy | `Control` `C` | `Cmd` `C` |
|
||||
| Cut | `Control` `X` | `Cmd` `X` |
|
||||
@ -24,7 +24,7 @@ Most of the core extensions register their own keyboard shortcuts. Depending on
|
||||
| Add a line break | `Shift` `Enter` | `Shift` `Enter` |
|
||||
|
||||
### Text Formatting
|
||||
| Action | Windows/Linux | macOS |
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ------------- | ------------------------------- | --------------------------- |
|
||||
| Bold | `Control` `B` | `Cmd` `B` |
|
||||
| Italicize | `Control` `I` | `Cmd` `I` |
|
||||
@ -34,7 +34,7 @@ Most of the core extensions register their own keyboard shortcuts. Depending on
|
||||
| Code | `Control` `E` | `Cmd` `E` |
|
||||
|
||||
### Paragraph Formatting
|
||||
| Action | Windows/Linux | macOS |
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ----------------------- | ------------------------------- | --------------------------- |
|
||||
| Apply normal text style | `Control` `Alt` `0` | `Cmd` `Alt` `0` |
|
||||
| Apply heading style 1 | `Control` `Alt` `1` | `Cmd` `Alt` `1` |
|
||||
@ -58,7 +58,7 @@ Most of the core extensions register their own keyboard shortcuts. Depending on
|
||||
<!--| Toggle task| `Control` `Enter` | `Cmd` `Enter` | -->
|
||||
|
||||
### Text Selection
|
||||
| Action | Windows/Linux | macOS |
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ------------------------------------------------- | ------------------------------- | --------------------------- |
|
||||
| Select all | `Control` `A` | `Cmd` `A` |
|
||||
| Extend selection one character to left | `Shift` `←` | `Shift` `←` |
|
||||
|
@ -51,7 +51,7 @@ editor.commands.unsetBlockquote()
|
||||
```
|
||||
|
||||
## Keyboard shortcuts
|
||||
| Action | Windows/Linux | macOS |
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ----------------- | ------------------------------- | --------------------------- |
|
||||
| Toggle Blockquote | `Control` `Shift` `B` | `Cmd` `Shift` `B` |
|
||||
|
||||
|
@ -28,8 +28,9 @@ This extension requires the [`ListItem`](/api/nodes/list-item) node.
|
||||
| bulletList | — | Toggle a bullet list. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows/Linux: `Control` `Shift` `8`
|
||||
* macOS: `Cmd` `Shift` `8`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ---------------- | ------------------------------- | --------------------------- |
|
||||
| toggleBulletList | `Control` `Shift` `8` | `Cmd` `Shift` `8` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-bullet-list/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-bullet-list/)
|
||||
|
@ -27,8 +27,9 @@ yarn add @tiptap/extension-code-block-lowlight
|
||||
| codeBlock | — | Wrap content in a code block. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows/Linux: `Control` `Alt` `C`
|
||||
* macOS: `Cmd` `Alt` `C`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| --------------- | ----------------------------- | ------------------------- |
|
||||
| toggleCodeBlock | `Control` `Alt` `C` | `Cmd` `Alt` `C` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-code-block-lowlight/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-code-block-lowlight/)
|
||||
|
@ -31,8 +31,9 @@ yarn add @tiptap/extension-code-block
|
||||
| codeBlock | — | Wrap content in a code block. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows/Linux: `Control` `Alt` `C`
|
||||
* macOS: `Cmd` `Alt` `C`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| --------------- | ----------------------------- | ------------------------- |
|
||||
| toggleCodeBlock | `Control` `Alt` `C` | `Cmd` `Alt` `C` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-code-block/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-code-block/)
|
||||
|
@ -25,9 +25,9 @@ yarn add @tiptap/extension-hard-break
|
||||
| setHardBreak | — | Add a line break. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* `Shift` `Enter`
|
||||
* Windows/Linux: `Control` `Enter`
|
||||
* macOS: `Cmd` `Enter`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ------------ | ---------------------------------------------- | ------------------------------------------ |
|
||||
| setHardBreak | `Shift` `Enter`<br>`Control` `Enter` | `Shift` `Enter`<br>`Cmd` `Enter` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-hard-break/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-hard-break/)
|
||||
|
@ -27,8 +27,14 @@ yarn add @tiptap/extension-heading
|
||||
| heading | level | Creates a heading node with the specified level. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows/Linux: `Control` `Alt` `1-6`
|
||||
* macOS: `Cmd` `Alt` `1-6`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| --------------------------- | ----------------------------- | ------------------------- |
|
||||
| toggleHeading({ level: 1 }) | `Control` `Alt` `1` | `Cmd` `Alt` `1` |
|
||||
| toggleHeading({ level: 2 }) | `Control` `Alt` `2` | `Cmd` `Alt` `2` |
|
||||
| toggleHeading({ level: 3 }) | `Control` `Alt` `3` | `Cmd` `Alt` `3` |
|
||||
| toggleHeading({ level: 4 }) | `Control` `Alt` `4` | `Cmd` `Alt` `4` |
|
||||
| toggleHeading({ level: 5 }) | `Control` `Alt` `5` | `Cmd` `Alt` `5` |
|
||||
| toggleHeading({ level: 6 }) | `Control` `Alt` `6` | `Cmd` `Alt` `6` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-heading/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-heading/)
|
||||
|
@ -25,9 +25,6 @@ yarn add @tiptap/extension-horizontal-rule
|
||||
| -------------- | ---------- | ------------------------- |
|
||||
| horizontalRule | — | Create a horizontal rule. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
*None*
|
||||
|
||||
## Source code
|
||||
[packages/extension-horizontal-rule/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-horizontal-rule/)
|
||||
|
||||
|
@ -21,9 +21,11 @@ This extension requires the [`BulletList`](/api/nodes/bullet-list) or [`OrderedL
|
||||
| HTMLAttributes | `Object` | `{}` | Custom HTML attributes that should be added to the rendered HTML tag. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* New list item: `Enter`
|
||||
* Sink a list item: `Tab`
|
||||
* Lift a list item: `Shift` `Tab`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| --------------- | ------------------ | ------------------ |
|
||||
| splitListItem() | `Enter` | `Enter` |
|
||||
| sinkListItem() | `Tab` | `Tab` |
|
||||
| liftListItem() | `Shift` `Tab` | `Shift` `Tab` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-list-item/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-list-item/)
|
||||
|
@ -28,8 +28,9 @@ This extension requires the [`ListItem`](/api/nodes/list-item) node.
|
||||
| orderedList | — | Toggle an ordered list. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows/Linux: `Control` `Shift` `7`
|
||||
* macOS: `Cmd` `Shift` `7`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ----------------- | ------------------------------- | --------------------------- |
|
||||
| toggleOrderedList | `Control` `Shift` `7` | `Cmd` `Shift` `7` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-ordered-list/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-ordered-list/)
|
||||
|
@ -28,8 +28,9 @@ yarn add @tiptap/extension-paragraph
|
||||
| paragraph | — | Transforms all selected nodes to paragraphs. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows & Linux: `Control` `Alt` `0`
|
||||
* macOS: `Cmd` `Alt` `0`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| -------------- | ----------------------------- | ------------------------- |
|
||||
| setParagraph() | `Control` `Alt` `0` | `Cmd` `Alt` `0` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-paragraph/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-paragraph/)
|
||||
|
@ -50,7 +50,6 @@ This extension requires the [`TableRow`](/api/nodes/table-row), [`TableHeader`](
|
||||
| goToPreviousCell | – | |
|
||||
| fixTables | – | |
|
||||
|
||||
|
||||
## Source code
|
||||
[packages/extension-table/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-table/)
|
||||
|
||||
|
@ -23,7 +23,11 @@ This extension requires the [`TaskList`](/api/nodes/task-list) node.
|
||||
| HTMLAttributes | `Object` | `{}` | Custom HTML attributes that should be added to the rendered HTML tag. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* New list item: `Enter`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| --------------- | ------------------ | ------------------ |
|
||||
| splitListItem() | `Enter` | `Enter` |
|
||||
| sinkListItem() | `Tab` | `Tab` |
|
||||
| liftListItem() | `Shift` `Tab` | `Shift` `Tab` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-task-item/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-task-item/)
|
||||
|
@ -28,8 +28,9 @@ This extension requires the [`TaskItem`](/api/nodes/task-item) extension.
|
||||
| taskList | — | Toggle a task list. |
|
||||
|
||||
## Keyboard shortcuts
|
||||
* Windows/Linux: `Control` `Shift` `9`
|
||||
* macOS: `Cmd` `Shift` `9`
|
||||
| Command | Windows/Linux | macOS |
|
||||
| ---------------- | ------------------------------- | --------------------------- |
|
||||
| toggleTaskList() | `Control` `Shift` `9` | `Cmd` `Shift` `9` |
|
||||
|
||||
## Source code
|
||||
[packages/extension-task-list/](https://github.com/ueberdosis/tiptap/blob/main/packages/extension-task-list/)
|
||||
|
Loading…
Reference in New Issue
Block a user