You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var clientX = 0;
var clientY = 0;
var _win;
var _isIframe = false;
var styleElement;
const PARENT_TAGS_TO_EXCLUDE = ["STYLE", "SCRIPT", "TITLE"];
+const rangeNodeMap = new Map();
async function expandRange(range, type) {
+ if (!rangeNodeMap.get(range)) {+ return;+ }
try {
if (type == "container" || !range.expand) {
range.setStartBefore(range.startContainer);
range.setEndAfter(range.startContainer);
range.setStart(range.startContainer, 0);
} else {
range.expand(type); // "word" or "sentence"
// await expandRangeWithSeg(range, type);
}
} catch (error) {
console.log(error);
}
}
export function getTextRange(textNode) {
var range = document.createRange();
range.setStart(textNode, 0);
range.setEnd(textNode, textNode.length);
+ rangeNodeMap.set(range, textNode);
return range;
}
export function getCharRanges(textNode) {
var ranges = [];
for (let i = 0; i < textNode.length - 1; i++) {
var range = document.createRange();
range.setStart(textNode, i);
range.setEnd(textNode, i + 1);
ranges.push(range);
+ rangeNodeMap.set(range, textNode);
}
return ranges;
}
then no more error.
No errors in incognito mode, so it seems to be a conflict with other extensions.
(I think the problem comes from Video Speed Controller...)
(and I don't know why but the error occurs in https://github.com/<organization>/<repository>/pull/<pull_request_number>/files even in incognito mode!)
If you don't need to fix this, please ignore it.
The text was updated successfully, but these errors were encountered:
There are errors in console:
or,
Screenshot
The error comes from the following source code:
MouseTooltipTranslator/src/event/mouseover.js
Lines 96 to 109 in baa4cee
I've tested with the next code: gignac-cha@21f7472
Diff
then no more error.
No errors in incognito mode, so it seems to be a conflict with other extensions.
(I think the problem comes from Video Speed Controller...)
(and I don't know why but the error occurs in
https://github.com/<organization>/<repository>/pull/<pull_request_number>/files
even in incognito mode!)If you don't need to fix this, please ignore it.
The text was updated successfully, but these errors were encountered: