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

feat(sidebar): open up broadcasts if #whats-new is the hash #38838

Merged
merged 4 commits into from Sep 15, 2022

Conversation

scefali
Copy link
Member

@scefali scefali commented Sep 14, 2022

We want to be able to send links to Sentry with the "What's new" section opened. We can do this with a hash parameter #sidebar-broadcasts.

Comment on lines 94 to 98
useEffect(() => {
if (location?.hash === '#whats-new') {
togglePanel(SidebarPanelKey.Broadcasts);
}
}, [location?.hash]);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Want to generalize it be

type SidebarHash = `#sidebar-${SidebarPanelKey}`;

and then you can parse the string and toggle whatever with #sidebar-whats-new

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@evanpurkhiser good call

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Scope: Frontend Automatically applied to PRs that change frontend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants