FooSoft / yomichan

Japanese pop-up dictionary extension for Chrome and Firefox.
https://foosoft.net/projects/yomichan
Other
1.06k stars 217 forks source link

Highlighting not working on Firefox when CSS has `user-select: all` #1435

Closed doubutunomorai closed 3 years ago

doubutunomorai commented 3 years ago

Description go to any page with text that has CSS user-select: all e.g. https://jsfiddle.net/tLm2sx0v/ hover over it (using modifier key if you have one enabled) nothing happens works on chrome, only broken on firefox

Browser version Firefox 85.0.2

Yomichan version Yomichan 21.1.31.1

toasted-nutbread commented 3 years ago

Nice find, fixed in #1436. Looks like Firefox's caretPositionFromPoint behaves differently than the API Chrome uses (caretRangeFromPoint).