`find` command errors out when match is found, but outside of viewport
Closed this issue · 1 comments
natrys commented
version: 1.23.0pre6867-ff696b5c
Error Message:
# controller in excmd: TypeError: Window.getComputedStyle: Argument 1 does not implement interface Element.
Stacktrace:
controller in excmd: TypeError: Window.getComputedStyle: Argument 1 does not implement interface Element.
<anonymous> index.ts:278
r index.ts:360
scrollIntoView finding.ts:110
focus finding.ts:118
focusHighlight finding.ts:260
jumpToNextMatch finding.ts:317
jumpToMatch finding.ts:245
find4 .excmds_content.generated.ts:1299
acceptExCmd controller.ts:28
handler messaging.ts:50
onMessage messaging.ts:217
logging.ts:42:32
log logging.ts:42
acceptExCmd controller.ts:31
handler messaging.ts:50
onMessage messaging.ts:217
The relevant function makes a call out to scrollCompute
function of compute-scroll-into-view
package which was recently updated (10bb3e0) which might be relevant.
GHolk commented
I draft that PR with compute-scroll-into-view@v1.0.17.
I use a tricky way to make it compute the scroll actions for a range object.
It seem not to work in 3.1.0.