Skip to content

[CL-1186] - spotlight and popover fixes#20519

Open
jaasen-livefront wants to merge 2 commits intomainfrom
CL-1186
Open

[CL-1186] - spotlight and popover fixes#20519
jaasen-livefront wants to merge 2 commits intomainfrom
CL-1186

Conversation

@jaasen-livefront
Copy link
Copy Markdown
Collaborator

@jaasen-livefront jaasen-livefront commented May 6, 2026

🎟️ Tracking

https://bitwarden.atlassian.net/browse/CL-1186

📔 Objective

Fixes issues with the spotlight effect used in guided tour popovers, and adds customization inputs to bit-popover.

Light mode contrast — The spotlight overlay opacity was 0.3, too close to the nav hover color to create visible contrast. Increased to 0.55.

Resize lag — CDK's reposition scroll strategy only reacts to scroll events, so resizing the window caused the spotlight cutout to trail behind the highlighted element. Added a window resize listener in SpotlightService that immediately calls updatePosition(), cleaned up when the overlay is disposed.

Spotlight cropping — The spotlight cutout was sizing to the directive's host element, which could be wider than the visual target (e.g. a full-width nav row). Added a spotlightTargetSelector input to PopoverAnchorForDirective that accepts a CSS selector to find a child element to use as the spotlight target instead.

Viewport margin — Added a viewportMargin input to PopoverAnchorForDirective to control the minimum distance between the popover and the viewport edge (passed to CDK's withViewportMargin()).

Popover customization — Added optional panelClass, headerClass, titleClass, and contentClass inputs to bit-popover for overriding styles on specific sections without modifying the shared component defaults.

📸 Screenshots

Screenshot 2026-05-05 at 2 17 16 PM
Screen.Recording.2026-05-05.at.2.18.15.PM.mov

@jaasen-livefront jaasen-livefront requested a review from a team as a code owner May 6, 2026 00:08
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 6, 2026

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.

1 participant