Skip to content

Comments

fix(popover-inline): prevent scrollbars from appearing in Safari#2991

Open
danielalanbates wants to merge 1 commit intocodex-team:nextfrom
danielalanbates:fix/issue-2988
Open

fix(popover-inline): prevent scrollbars from appearing in Safari#2991
danielalanbates wants to merge 1 commit intocodex-team:nextfrom
danielalanbates:fix/issue-2988

Conversation

@danielalanbates
Copy link

Fixes #2988

Summary

In Safari, the inline toolbar popover shows native scrollbars that partially cover the toolbar items. This happens because the base .ce-popover__items class sets overflow-y: auto, and Safari renders visible scrollbars even when content doesn't overflow.

Root Cause

The base popover styles (popover.css) set overflow-y: auto on .ce-popover__items to enable scrolling in dropdown popovers with many items. However, the inline toolbar already uses width: max-content on its container, meaning it grows to fit content rather than constraining to a fixed width. Scrolling is unnecessary for the inline toolbar.

Fix

Added overflow-y: visible to .ce-popover__items inside the .ce-popover--inline scope, overriding the base popover's overflow-y: auto. This follows the maintainer's suggested approach #1 from the issue: disable scrolling in the inline toolbar and let it grow based on content.

How to test

  1. Open the editor in Safari
  2. Select some text to trigger the inline toolbar
  3. Verify no scrollbars appear on the toolbar popover

This PR was created with the assistance of Claude Opus 4.6 by Anthropic. Happy to make any adjustments! Reviewed and submitted by a human.

Co-Authored-By: Claude Opus 4.6 noreply@anthropic.com

The base popover's `.ce-popover__items` has `overflow-y: auto`, which
causes Safari to render visible scrollbars on the inline toolbar. Since
the inline popover container uses `width: max-content` and grows to fit
its content, scrolling is not needed.

Override `overflow-y` to `visible` in the inline popover items to
prevent Safari from showing scrollbars.

Fixes codex-team#2988

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.

Bug: Popover inline toolbar shows scrollbars in Safari

1 participant