fix: keep preview retry controls stationary during pointer activation

This commit is contained in:
cesnimda
2026-10-24 23:31:58 +02:00
parent e80815f8df
commit b313e20bad
8 changed files with 79 additions and 4 deletions
@@ -625,6 +625,8 @@ export default function CvBuilderEditor() {
<Paper variant="outlined" onFocusCapture={(event) => {
setMobilePane("preview");
// Moving a pointer-focused control here can cancel its pending click.
if (event.target !== scrollRef.current) return;
const pane = event.currentTarget;
requestAnimationFrame(() => {
if (pane.contains(document.activeElement)) pane.scrollIntoView?.({ block: "start", inline: "nearest" });