Skip to content
Snippets Groups Projects
Commit efb1cd8c authored by chris's avatar chris
Browse files

addmark step in whole step selection

parent b33bec33
No related branches found
No related tags found
1 merge request!118addmark step in whole step selection
...@@ -37,9 +37,11 @@ const addMarkStep = (state, tr, step, newTr, map, doc, user, date, group) => { ...@@ -37,9 +37,11 @@ const addMarkStep = (state, tr, step, newTr, map, doc, user, date, group) => {
after = [step.mark.type.name]; after = [step.mark.type.name];
} }
if (after.length || before.length) { if (after.length || before.length) {
// Math.max(step.from, pos),
// Math.min(step.to, pos + node.nodeSize),
newTr.addMark( newTr.addMark(
Math.max(step.from, pos), step.from,
Math.min(step.to, pos + node.nodeSize), step.to,
state.schema.marks.format_change.create({ state.schema.marks.format_change.create({
user: user.userId, user: user.userId,
username: user.username, username: user.username,
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment