mirror of
https://github.com/ueberdosis/tiptap.git
synced 2024-11-25 04:19:02 +08:00
update content
This commit is contained in:
parent
7fa5ad5db4
commit
645ec6e153
@ -17,6 +17,10 @@ const CustomDocument = Document.extend({
|
||||
content: 'taskList',
|
||||
})
|
||||
|
||||
const CustomTaskItem = TaskItem.extend({
|
||||
content: 'paragraph',
|
||||
})
|
||||
|
||||
export default {
|
||||
components: {
|
||||
EditorContent,
|
||||
@ -35,10 +39,10 @@ export default {
|
||||
Paragraph(),
|
||||
Text(),
|
||||
TaskList(),
|
||||
TaskItem(),
|
||||
CustomTaskItem(),
|
||||
],
|
||||
content: `
|
||||
<ul data-type="task_list">
|
||||
<ul data-type="taskList">
|
||||
<li data-type="taskItem" data-checked="true">A list item</li>
|
||||
<li data-type="taskItem" data-checked="false">And another one</li>
|
||||
</ul>
|
||||
|
@ -18,7 +18,7 @@ While that’s perfectly fine and does make the selected bold, you’d likely wa
|
||||
Most commands can be executed combined to one call. First of all, that’s shorter than separate function call in most cases. Here is an example to make the selected text bold:
|
||||
|
||||
```js
|
||||
editor.chain().focus().bold().run()
|
||||
editor.chain().bold().focus().run()
|
||||
```
|
||||
|
||||
The `.chain()` is required to start a new chain and the `.run()` is needed to actually execute all the commands in between. Between those two functions, this example combines to different commands.
|
||||
|
@ -1,9 +1,9 @@
|
||||
# Collaboration Cursor
|
||||
# CollaborationCursor
|
||||
This extension adds information about all connected users (like their name and a specified color), their current cursor position and their text selection (if there’s one).
|
||||
|
||||
Open this page in multiple browser windows to test it.
|
||||
|
||||
:::premium 💖 Pro Extension
|
||||
:::premium Pro Extension
|
||||
We kindly ask you to sponsor us, before using this extension in production. [Read more](/sponsor)
|
||||
:::
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Collaborative editing
|
||||
|
||||
:::premium Requires pro extensions
|
||||
:::premium Requires Pro Extensions
|
||||
We kindly ask you to sponsor us, before using this example in production. [Read more](/sponsor)
|
||||
:::
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Build your editor
|
||||
# Create your editor
|
||||
|
||||
## toc
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user