We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 468e831 + f690534 commit cd988b7Copy full SHA for cd988b7
Public/js/views/expression_highlighter.js
@@ -88,7 +88,11 @@ export default class ExpressionHighlighter extends EventDispatcher {
88
const endCoords = editor.charCoords(location.endPos, "local");
89
widget.style.left = `${startCoords.left + 1}px`;
90
widget.style.top = `${startCoords.bottom - 1}px`;
91
- widget.style.width = `${endCoords.left - startCoords.left - 2}px`;
+ if (error.location.start === error.location.end) {
92
+ widget.style.width = `${editor.defaultCharWidth()}px`;
93
+ } else {
94
+ widget.style.width = `${endCoords.left - startCoords.left - 2}px`;
95
+ }
96
97
this.widgets.push(widget);
98
}
0 commit comments