docs: minor fixes
This commit is contained in:
@@ -237,6 +237,15 @@ new Editor({
|
|||||||
### autofocus
|
### autofocus
|
||||||
With `autofocus` you can force the cursor to jump in the editor on initialization.
|
With `autofocus` you can force the cursor to jump in the editor on initialization.
|
||||||
|
|
||||||
|
| Value | Description |
|
||||||
|
| --------- | ------------------------------------------------------ |
|
||||||
|
| `'start'` | Sets the focus to the beginning of the document. |
|
||||||
|
| `'end'` | Sets the focus to the end of the document. |
|
||||||
|
| `Number` | Sets the focus to a specific position in the document. |
|
||||||
|
| `true` | Enables autofocus. |
|
||||||
|
| `false` | Disables autofocus. |
|
||||||
|
| `null` | Disables autofocus. |
|
||||||
|
|
||||||
```js
|
```js
|
||||||
import { Editor } from '@tiptap/core'
|
import { Editor } from '@tiptap/core'
|
||||||
import StarterKit from '@tiptap/starter-kit'
|
import StarterKit from '@tiptap/starter-kit'
|
||||||
@@ -249,15 +258,6 @@ new Editor({
|
|||||||
})
|
})
|
||||||
```
|
```
|
||||||
|
|
||||||
| Value | Description |
|
|
||||||
| --------- | ------------------------------------------------------ |
|
|
||||||
| `'start'` | Sets the focus to the beginning of the document. |
|
|
||||||
| `'end'` | Sets the focus to the end of the document. |
|
|
||||||
| `Number` | Sets the focus to a specific position in the document. |
|
|
||||||
| `true` | Enables autofocus. |
|
|
||||||
| `false` | Disables autofocus. |
|
|
||||||
| `null` | Disables autofocus. |
|
|
||||||
|
|
||||||
### enableInputRules
|
### enableInputRules
|
||||||
By default, tiptap enables all [input rules](/guide/custom-extensions/#input-rules). With `enableInputRules` you can disable that.
|
By default, tiptap enables all [input rules](/guide/custom-extensions/#input-rules). With `enableInputRules` you can disable that.
|
||||||
|
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ yarn add @tiptap/extension-bubble-menu
|
|||||||
| ------------ | -------------------- | -------------- | ----------------------------------------------------------------------- |
|
| ------------ | -------------------- | -------------- | ----------------------------------------------------------------------- |
|
||||||
| element | `HTMLElement` | `null` | The DOM element that contains your menu. |
|
| element | `HTMLElement` | `null` | The DOM element that contains your menu. |
|
||||||
| tippyOptions | `Object` | `{}` | [Options for tippy.js](https://atomiks.github.io/tippyjs/v6/all-props/) |
|
| tippyOptions | `Object` | `{}` | [Options for tippy.js](https://atomiks.github.io/tippyjs/v6/all-props/) |
|
||||||
| pluginKey | `string | PluginKey` | `'bubbleMenu'` | The key for the underlying ProseMirror plugin. |
|
| pluginKey | `string \| PluginKey` | `'bubbleMenu'` | The key for the underlying ProseMirror plugin. |
|
||||||
| shouldShow | `(props) => boolean` | | Controls whether the menu should be shown or not. |
|
| shouldShow | `(props) => boolean` | | Controls whether the menu should be shown or not. |
|
||||||
|
|
||||||
## Source code
|
## Source code
|
||||||
|
|||||||
Reference in New Issue
Block a user