mirror of
https://github.com/cudr/slate-collaborative.git
synced 2024-10-27 20:34:06 +00:00
fix: remove marks
This commit is contained in:
parent
b3ddf5dc26
commit
07a8201215
@ -10,21 +10,18 @@ const transforms = [
|
||||
[createNode('paragraph', '')],
|
||||
[
|
||||
{
|
||||
marks: [],
|
||||
offset: 0,
|
||||
path: [0, 0],
|
||||
text: 'Hello ',
|
||||
type: 'insert_text'
|
||||
},
|
||||
{
|
||||
marks: [],
|
||||
offset: 6,
|
||||
path: [0, 0],
|
||||
text: 'collaborator',
|
||||
type: 'insert_text'
|
||||
},
|
||||
{
|
||||
marks: [],
|
||||
offset: 18,
|
||||
path: [0, 0],
|
||||
text: '!',
|
||||
|
@ -8,8 +8,7 @@ const insertTextOp = ({ index, path, value }: Automerge.Diff) => () => ({
|
||||
type: 'insert_text',
|
||||
path: toSlatePath(path),
|
||||
offset: index,
|
||||
text: value,
|
||||
marks: []
|
||||
text: value
|
||||
})
|
||||
|
||||
const insertNodeOp = (
|
||||
|
@ -29,8 +29,7 @@ const removeTextOp = (op: Automerge.Diff) => (map: any, doc: Element) => {
|
||||
type: 'remove_text',
|
||||
path: slatePath,
|
||||
offset: index,
|
||||
text,
|
||||
marks: []
|
||||
text
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user