move quote formatting out of react component

This commit is contained in:
Bruno Windels 2019-09-04 12:40:03 +02:00
parent b72d1a78ec
commit b35a3531bb
5 changed files with 55 additions and 57 deletions

View file

@ -23,4 +23,8 @@ export default class DocumentOffset {
asPosition(model) {
return model.positionForOffset(this.offset, this.atNodeEnd);
}
add(delta, atNodeEnd = false) {
return new DocumentOffset(this.offset + delta, atNodeEnd);
}
}