Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rework method spotlight effect #319

Merged
merged 1 commit into from
Oct 5, 2023

Conversation

jonathanhefner
Copy link
Member

a67ece6 changed the HTML around method permalinks, which broke the spotlight effect when navigating to a specific method. However, prior to that commit (since upgrading to Turbo v7), the spotlight effect only worked for cross-page navigation, not intra-page navigation. This commit fixes the spotlight effect for both cross-page and intra-page navigation.

Additionally, this commit changes the visual effect from a momentary flash of yellow to a persistent mark in the left margin. This ensures that effect is not missed (for example, when opening the page as a background tab), and is less jarring when using dark mode.

Before After
before-light after-light
before-dark after-dark

a67ece6 changed the HTML around method
permalinks, which broke the spotlight effect when navigating to a
specific method.  However, prior to that commit (since upgrading to
Turbo v7), the spotlight effect only worked for cross-page navigation,
not intra-page navigation.  This commit fixes the spotlight effect for
both cross-page and intra-page navigation.

Additionally, this commit changes the visual effect from a momentary
flash of yellow to a persistent mark in the left margin.  This ensures
that effect is not missed (for example, when opening the page as a
background tab), and is less jarring when using dark mode.
@jonathanhefner jonathanhefner merged commit 9dff5b1 into rails:main Oct 5, 2023
8 checks passed
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