I’m building an embedded app using Polaris web components and noticed that in Safari, clicking on an s-clickable element causes a prominent blue focus outline to appear and persist until clicking elsewhere.
The setup:
I’m using s-clickable for expandable/collapsible section headers in a modal:
Section titleThe behavior:
- In Chrome/Firefox: No visible focus ring after mouse click
- In Safari: Blue focus outline appears after clicking and stays visible
This seems to be Safari’s default focus styling. Other browsers use :focus-visible to only show focus rings for keyboard navigation, not mouse clicks.
My question:
- Is this expected behavior for Polaris web components in Safari?
- Is there a recommended way to handle this, or should I leave it as-is for accessibility reasons?
I want to avoid hacky solutions like calling blur() after click, since that could negatively impact keyboard users and screen readers.
