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

add sunburst to pie chart #47208

Merged
merged 19 commits into from
Oct 2, 2024
Merged

add sunburst to pie chart #47208

merged 19 commits into from
Oct 2, 2024

Conversation

EmmadUsmani
Copy link
Contributor

@EmmadUsmani EmmadUsmani commented Aug 25, 2024

Closes #47209
Closes #8563

Description

Adds a sunburst feature to the pie chart, using up to three dimension columns.

How to verify

  1. Create a question with three dimensions, one metric, see example below
Screenshot 2024-09-26 at 2 48 39 PM
  1. Visualize as pie chart, should have automatically select dimension and metric columns

Demo

Screenshot 2024-09-26 at 2 49 14 PM

Checklist

  • Tests have been added/updated to cover changes in this PR

Copy link
Contributor Author

EmmadUsmani commented Aug 25, 2024

Copy link
Contributor

github-actions bot commented Aug 25, 2024

Codenotify: Notifying subscribers in CODENOTIFY files for diff 3fd1708...9e345cc.

Notify File(s)
@alxnddr frontend/src/metabase/visualizations/components/ChartTooltip/EChartsTooltip/EChartsTooltip.tsx
frontend/src/metabase/visualizations/components/settings/ChartSettingColorPicker/ChartSettingColorPicker.tsx
frontend/src/metabase/visualizations/components/settings/ChartSettingOrderedItems/ChartSettingOrderedItems.tsx
frontend/src/metabase/visualizations/components/settings/ChartSettingSeriesOrder.tsx
frontend/src/metabase/visualizations/components/settings/ColumnItem/ColumnItem.tsx
frontend/src/metabase/visualizations/echarts/pie/constants.ts
frontend/src/metabase/visualizations/echarts/pie/format.ts
frontend/src/metabase/visualizations/echarts/pie/model/index.ts
frontend/src/metabase/visualizations/echarts/pie/model/types.ts
frontend/src/metabase/visualizations/echarts/pie/option.ts
frontend/src/metabase/visualizations/echarts/pie/tooltip.tsx
frontend/src/metabase/visualizations/echarts/pie/types.ts
frontend/src/metabase/visualizations/echarts/pie/util/colors.ts
frontend/src/metabase/visualizations/echarts/pie/util/index.ts
frontend/src/metabase/visualizations/echarts/tooltip/index.tsx
frontend/src/metabase/visualizations/shared/settings/pie.ts
frontend/src/metabase/visualizations/types/hover.ts
frontend/src/metabase/visualizations/visualizations/PieChart/DimensionsWidget.modules.css
frontend/src/metabase/visualizations/visualizations/PieChart/DimensionsWidget.tsx
frontend/src/metabase/visualizations/visualizations/PieChart/PieChart.tsx
frontend/src/metabase/visualizations/visualizations/PieChart/PieRowsPicker.tsx
frontend/src/metabase/visualizations/visualizations/PieChart/chart-definition.ts
frontend/src/metabase/visualizations/visualizations/PieChart/use-chart-events.ts
@ranquild frontend/src/metabase/lib/colors/palette.ts

@EmmadUsmani EmmadUsmani added the no-backport Do not backport this PR to any branch label Aug 26, 2024 — with Graphite App
@EmmadUsmani EmmadUsmani force-pushed the add-sunburst-to-pie-chart branch 3 times, most recently from 2975803 to ba41e36 Compare August 26, 2024 17:36
@EmmadUsmani EmmadUsmani force-pushed the allow-re-ordering-and-re-naming-pie-chart-slices branch from f939832 to 580040d Compare August 26, 2024 17:54
@EmmadUsmani EmmadUsmani force-pushed the add-sunburst-to-pie-chart branch 6 times, most recently from 636e4a7 to c96508b Compare August 29, 2024 00:58
Base automatically changed from allow-re-ordering-and-re-naming-pie-chart-slices to master August 29, 2024 15:57
@EmmadUsmani EmmadUsmani force-pushed the add-sunburst-to-pie-chart branch 2 times, most recently from 85a6bd7 to b678811 Compare September 5, 2024 21:02
@EmmadUsmani EmmadUsmani force-pushed the add-sunburst-to-pie-chart branch 2 times, most recently from a6a4a16 to 3050ac7 Compare September 23, 2024 20:37
@EmmadUsmani EmmadUsmani added the PR-Env See https://www.notion.so/metabase/Ephemeral-PR-Environments-c74a3710c87a460dbf4fc0007a001458 label Sep 23, 2024
Copy link
Member

@alxnddr alxnddr left a comment

Choose a reason for hiding this comment

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

Went through it another time, works great.
Can you please add a bit more specs around the click behavior? Can be done separately

@EmmadUsmani
Copy link
Contributor Author

@alxnddr Thanks, yeah I can try to do that. Are there any specific cases you'd like to test regarding click behavior?

@EmmadUsmani EmmadUsmani enabled auto-merge (squash) October 2, 2024 19:58
@alxnddr
Copy link
Member

alxnddr commented Oct 2, 2024

Are there any specific cases you'd like to test regarding click behavior?

@EmmadUsmani it would be great to verify that clicks on circles on all levels pass correct data for example when interpolating URLs or setting dashboard filter values

Copy link
Contributor

github-actions bot commented Oct 2, 2024

👋 Deploying a preview environment for commit 9e345cc.
✅ Preview:
https://pr47208.coredev.metabase.com
🗒️ login instructions

@EmmadUsmani EmmadUsmani merged commit 61e610b into master Oct 2, 2024
126 checks passed
@EmmadUsmani EmmadUsmani deleted the add-sunburst-to-pie-chart branch October 2, 2024 22:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-backport Do not backport this PR to any branch PR-Env See https://www.notion.so/metabase/Ephemeral-PR-Environments-c74a3710c87a460dbf4fc0007a001458 .Team/DashViz Dashboard and Viz team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Epic] Multi-dimensional / Sunburst Pie chart Multiple breakout pie chart
4 participants