Merge branch 'main' of github.com:ueberdosis/tiptap-next

This commit is contained in:
Hans Pagel
2021-01-29 15:15:41 +01:00
102 changed files with 587 additions and 118 deletions

View File

@@ -77,9 +77,6 @@ export default {
Highlight,
TaskList,
CustomTaskItem,
Collaboration.configure({
document: ydoc,
}),
CollaborationCursor.configure({
provider: this.provider,
user: this.currentUser,
@@ -87,6 +84,9 @@ export default {
this.users = users
},
}),
Collaboration.configure({
document: ydoc,
}),
],
})

View File

@@ -70,7 +70,9 @@
</template>
<script>
import { Editor, EditorContent, defaultExtensions } from '@tiptap/vue-starter-kit'
import {
Editor, EditorContent, defaultExtensions, Extension,
} from '@tiptap/vue-starter-kit'
export default {
components: {

View File

@@ -33,9 +33,6 @@ export default {
Document,
Paragraph,
Text,
Collaboration.configure({
document: ydoc,
}),
CollaborationCursor.configure({
provider: this.provider,
user: {
@@ -43,6 +40,9 @@ export default {
color: '#f783ac',
},
}),
Collaboration.configure({
document: ydoc,
}),
],
})
},

View File

@@ -121,6 +121,6 @@ context('/demos/Nodes/TaskList', () => {
cy.get('.ProseMirror')
.find('li:nth-child(2)')
.should('contain', 'List Item 2')
.should('have.attr', 'data-checked', 'true')
.should('have.attr', 'data-checked', 'false')
})
})

View File

@@ -155,16 +155,16 @@ const provider = new WebsocketProvider('ws://127.0.0.1:1234', 'example-document'
const editor = new Editor({
extensions: [
// …
Collaboration.configure({
document: ydoc,
}),
// Register the collaboration cursor extension
CollaborationCursor.configure({
provider: provider,
name: 'Cyndi Lauper',
color: '#f783ac',
}),
Collaboration.configure({
document: ydoc,
}),
// …
],
})
```