Skip to content

fix: resolved stale toolbox hover state - #3042

Open
Sush1271 wants to merge 1 commit into
codex-team:nextfrom
Sush1271:fix/stale-toolbox-hover
Open

Sush1271 wants to merge 1 commit into
codex-team:nextfrom
Sush1271:fix/stale-toolbox-hover

Conversation

@Sush1271

@Sush1271 Sush1271 commented Nov 3, 2026 •

Copy link
Copy Markdown

fixes #3037 — Toolbox item keeps hover highlight after selecting a block

Problem

When the desktop toolbox popover is closed, its items remain in the DOM. The browser can retain the native :hover state on an item even after the popover is hidden.

This causes a stale hover highlight to remain visible when the toolbox is reopened. The highlight comes from the item's CSS :hover rule rather than Editor.js's keyboard-focus state, so resetting the focus state alone does not resolve the issue.

Fix

Update the desktop popover handling to prevent stale hover highlights from persisting after the popover closes.

Ensure the popover item interaction state is properly reset so that reopening the toolbox does not display an outdated hover highlight.

Reproduction

  1. Open the Editor.js desktop toolbox.
  2. Hover over a toolbox item.
  3. Close the popover while the pointer is still over the item.
  4. Reopen the toolbox.

Before: The previously hovered item can retain its highlight when the popover is reopened.

After: The stale hover highlight is cleared, and toolbox items display the correct hover state.

Operating Systems:

Arch Linux , Windows 11

Browser Compatibility:

The issue was successfully reproduced in all four browsers:

Google Chrome , Mozilla , Firefox , Brave , Chromium

Screenshots

Before
editorjs

image2

After
image

Checklist

  • Build passes (vite build)
  • Cypress toolbox tests pass
  • No new type errors introduced

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Toolbox item keeps hover highlight after selecting a block

1 participant