LearnNewsExamplesServices
Frontmatter
id8621
titleInvestigation: FocusManager Stability during Atomic Moves
stateOpen
labels
discussionaitestingcore
assignees[]
createdAtJan 13, 2026, 11:08 PM
updatedAtJan 13, 2026, 11:08 PM
githubUrlhttps://github.com/neomjs/neo/issues/8621
authortobiu
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]

Investigation: FocusManager Stability during Atomic Moves

Opendiscussionaitestingcore
tobiu
tobiu commented on Jan 13, 2026, 11:08 PM

The current "atomic move" implementation for Neo.container.Base involves a remove (silent) -> insert sequence. On the main thread, this translates to an insertBefore operation. In Chromium/WebKit, this causes the moved element to lose focus temporarily.

We currently patch this in DeltaUpdates.moveNode by immediately calling focus() on the element if it was active. This results in a rapid focusout -> focusin event sequence sent to the App Worker.

Goal: Investigate if this event flicker causes unwanted side effects, particularly for:

  1. Neo.form.field.Base validation logic (often triggered on blur).
  2. Neo.manager.Focus state tracking.

Potential Solution: If side effects are found, implement a "debounce" or "flicker detection" logic in FocusManager or DeltaUpdates. For example: "If an element loses focus, but re-gains it within X ms without another element taking focus in between, treat it as a continuous focus session."

tobiu added the discussion label on Jan 13, 2026, 11:08 PM
tobiu added the ai label on Jan 13, 2026, 11:08 PM
tobiu added the testing label on Jan 13, 2026, 11:08 PM
tobiu added the core label on Jan 13, 2026, 11:08 PM