Skip to content

Commit

Permalink
minor refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
arausly committed Oct 29, 2024
1 parent 34b8941 commit e72807e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/AutoSuggestion/extensions/markText.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,12 @@ export const markText = (config: marksConfig) => {
title: config.title ?? "",
},
});
const rangeStop = Math.min(config.to, docLength);
const stopRange = Math.min(config.to, docLength);
config.view.dispatch({
effects: addMarks.of([strikeMark.range(config.from, rangeStop)] as any),
effects: addMarks.of([strikeMark.range(config.from, stopRange)] as any),
});

return { from: config.from, to: rangeStop };
return { from: config.from, to: stopRange };
};

export const removeMarkFromText = (config: marksConfig) => {
Expand Down

0 comments on commit e72807e

Please sign in to comment.