mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-27 03:57:21 +00:00
Dynannotate: Fix off-by-one error for end of annotation text
This commit is contained in:
parent
3016b3d094
commit
50d8325d4c
@ -78,7 +78,7 @@ exports.TextMap.prototype.findText = function(targetString,targetPrefix,targetSu
|
||||
if(startPos !== -1) {
|
||||
startPos += targetPrefix.length;
|
||||
var startMetadata = this.locateMetadata(startPos),
|
||||
endMetadata = this.locateMetadata(startPos + targetString.length);
|
||||
endMetadata = this.locateMetadata(startPos + targetString.length - 1);
|
||||
if(startMetadata && endMetadata) {
|
||||
return {
|
||||
startNode: startMetadata.domNode,
|
||||
|
Loading…
Reference in New Issue
Block a user