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(explore): Convert buttons into context menu #81219

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

narsaynorath
Copy link
Member

Convert the buttons for alerts and add to dashboards into a context menu. Shifts over a bunch of the code for both the alerts and dashboards buttons into a context menu component that's specific for explore charts.

I needed to extract the logic for getting the sort option to a helper function I could use in my callback. This is because visualizes is a list of items and we map over it for charts, meaning I can't use a hook to reference the correct chart at the point of instantiation, it needs to be used in a callback that's defined during that mapping.

Screen.Recording.2024-11-22.at.5.18.40.PM.mov

@narsaynorath narsaynorath requested a review from a team as a code owner November 22, 2024 22:24
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Nov 22, 2024
Copy link

codecov bot commented Nov 22, 2024

Bundle Report

Changes will increase total bundle size by 22.27kB (0.07%) ⬆️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
app-webpack-bundle-array-push 31.99MB 22.27kB (0.07%) ⬆️

Copy link

codecov bot commented Nov 22, 2024

Codecov Report

Attention: Patch coverage is 69.23077% with 16 lines in your changes missing coverage. Please review.

✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
.../app/views/explore/components/chartContextMenu.tsx 0.00% 14 Missing ⚠️
static/app/views/explore/hooks/useSorts.tsx 80.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #81219      +/-   ##
==========================================
+ Coverage   80.33%   80.36%   +0.02%     
==========================================
  Files        7225     7221       -4     
  Lines      320212   320137      -75     
  Branches    20781    20780       -1     
==========================================
+ Hits       257257   257288      +31     
+ Misses      62561    62455     -106     
  Partials      394      394              

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

Successfully merging this pull request may close these issues.

1 participant