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

[POC] Add chart gallery dashboard #559

Merged
merged 131 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from 117 commits
Commits
Show all changes
131 commits
Select commit Hold shift + click to select a range
639dac7
Add compendium and rework bar chart
huong-li-nguyen Jun 25, 2024
3f90c1d
Add POC
huong-li-nguyen Jul 1, 2024
ae73db3
Add intermediate layout
huong-li-nguyen Jul 1, 2024
04041de
Add optimised layout
huong-li-nguyen Jul 1, 2024
29ef5ad
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 1, 2024
ee1af13
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 1, 2024
8e3a95c
Add homepage structure
huong-li-nguyen Jul 2, 2024
bb8481d
Revert changes in demo app
huong-li-nguyen Jul 2, 2024
52fb3a3
Lint
huong-li-nguyen Jul 2, 2024
42dd5bc
Add card and flex-box
huong-li-nguyen Jul 2, 2024
d3621af
Tidy
huong-li-nguyen Jul 2, 2024
b5d73a3
Add chart images and create landing pages
huong-li-nguyen Jul 2, 2024
781c8a1
Replace `HtmlIntro` with vizro-way of doing cards
huong-li-nguyen Jul 3, 2024
b6a8af7
Change code highlighting colors
huong-li-nguyen Jul 3, 2024
4cf8721
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 3, 2024
5d322fa
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 3, 2024
d475bb6
Fix styling
huong-li-nguyen Jul 3, 2024
698f5e6
Add line chart
huong-li-nguyen Jul 3, 2024
234dc2f
Change to Markdown
huong-li-nguyen Jul 3, 2024
839573f
Merge branch 'demo/chart-gallery' of https://github.com/mckinsey/vizr…
huong-li-nguyen Jul 3, 2024
acabab9
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 3, 2024
5a207a8
Add scatter chart
huong-li-nguyen Jul 5, 2024
6faa89e
Tidy
huong-li-nguyen Jul 5, 2024
23a46a2
Lint
huong-li-nguyen Jul 5, 2024
90e8f2f
Remove fixed card height and width
huong-li-nguyen Jul 5, 2024
d5c0574
Add pie chart and tidy files
huong-li-nguyen Jul 5, 2024
718a748
Add donut chart
huong-li-nguyen Jul 5, 2024
cd1ff04
Add more charts and tidy
huong-li-nguyen Jul 5, 2024
3cfa78a
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 8, 2024
639fc56
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 8, 2024
53b81d2
Lint
huong-li-nguyen Jul 8, 2024
77251fd
Sort alphabetically
huong-li-nguyen Jul 8, 2024
8865f5d
Convert to navigation cards
huong-li-nguyen Jul 8, 2024
071ee58
Replace icons and change order
huong-li-nguyen Jul 8, 2024
f927d28
Fix bug and apply new icons
huong-li-nguyen Jul 8, 2024
5296ab0
Merge branch 'demo/chart-gallery' of https://github.com/mckinsey/vizr…
huong-li-nguyen Jul 8, 2024
b65b7af
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 8, 2024
cb34493
Tidy
huong-li-nguyen Jul 8, 2024
e139a11
Move to different folder
huong-li-nguyen Jul 8, 2024
3bc5d71
Revert changes in _dev
huong-li-nguyen Jul 8, 2024
48f9138
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 8, 2024
7a51e4a
Move custom CSS to static where relevant
huong-li-nguyen Jul 8, 2024
adc4402
Merge branch 'demo/chart-gallery' of https://github.com/mckinsey/vizr…
huong-li-nguyen Jul 8, 2024
a41cd08
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 8, 2024
70aa336
Rename and tidy
huong-li-nguyen Jul 8, 2024
7d77b76
Tidy and lint
huong-li-nguyen Jul 8, 2024
90aad7a
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 12, 2024
60944ba
Refactor pages
huong-li-nguyen Jul 12, 2024
e2acac1
Fix IDs
huong-li-nguyen Jul 12, 2024
4e8b237
Introduce helper function to tidy chart title
huong-li-nguyen Jul 12, 2024
7214d1c
Rename folder
huong-li-nguyen Jul 12, 2024
6af05b8
Fix tests
huong-li-nguyen Jul 12, 2024
a4956cd
Update test_examples.py
huong-li-nguyen Jul 12, 2024
0c89251
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 15, 2024
165086e
Tidy chart code
huong-li-nguyen Jul 15, 2024
94a7479
Tidy donut and pie code example
huong-li-nguyen Jul 15, 2024
22b8642
Tidy box and violin code
huong-li-nguyen Jul 15, 2024
931fa58
Add treemap
huong-li-nguyen Jul 15, 2024
167d3bf
Lint
huong-li-nguyen Jul 15, 2024
ee9d999
Add butterfly chart
huong-li-nguyen Jul 15, 2024
8cb2e3f
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 15, 2024
7badf90
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 15, 2024
2d262eb
Rename folder
huong-li-nguyen Jul 15, 2024
0a7ba67
Add choropleth chart
huong-li-nguyen Jul 15, 2024
1da246d
Add sankey chart
huong-li-nguyen Jul 15, 2024
88d7a95
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 15, 2024
846a4fd
Lint
huong-li-nguyen Jul 15, 2024
ed742e6
Fix typo
huong-li-nguyen Jul 15, 2024
3940c45
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 15, 2024
cbcff26
Fix mapping of charts to categories
huong-li-nguyen Jul 16, 2024
83c28b6
Fix CSS
huong-li-nguyen Jul 16, 2024
16032dd
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 16, 2024
13c7fcb
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 16, 2024
3c2d263
Rename folder
huong-li-nguyen Jul 16, 2024
c6d9c2c
Merge branch 'demo/chart-gallery' of https://github.com/mckinsey/vizr…
huong-li-nguyen Jul 16, 2024
1972303
Reshuffle functions and helpers
huong-li-nguyen Jul 17, 2024
9733b79
Lint
huong-li-nguyen Jul 17, 2024
2eaf143
Lint some moreLint
huong-li-nguyen Jul 17, 2024
cf8490c
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 17, 2024
4704719
Add license and credits
huong-li-nguyen Jul 17, 2024
a720697
Update README
huong-li-nguyen Jul 17, 2024
5a0e5f4
Remove factory function for line
huong-li-nguyen Jul 17, 2024
1d304ce
Lint
huong-li-nguyen Jul 17, 2024
7760749
Tidy some more
huong-li-nguyen Jul 17, 2024
adc5015
Add more information
huong-li-nguyen Jul 17, 2024
aa9931a
Amend python path using fixture
antonymilne Jul 19, 2024
4e6388f
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 19, 2024
4fb139f
Merge branch 'demo/chart-gallery' of https://github.com/mckinsey/vizr…
huong-li-nguyen Jul 19, 2024
8f5c0a3
Fix sys.modules
antonymilne Jul 19, 2024
30ddb15
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 19, 2024
5a60dc2
Fix sys.modules
antonymilne Jul 19, 2024
998553f
Fix sys.modules
antonymilne Jul 19, 2024
0180c07
Quick PR comments
huong-li-nguyen Jul 23, 2024
123dbb5
Implement uncollapsed codeclipboard
huong-li-nguyen Jul 23, 2024
e016a04
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 23, 2024
5d64ec6
Add docstrings
huong-li-nguyen Jul 23, 2024
0f0df51
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 23, 2024
f563b81
PR comments
huong-li-nguyen Jul 23, 2024
3370d47
Lint
huong-li-nguyen Jul 23, 2024
00e08ce
Remove tab_container in favour of chart_groups
antonymilne Jul 23, 2024
5c7d149
- Move non-repeated charts from chart_pages to separate pges files
antonymilne Jul 24, 2024
254e597
Move repeated chart factories to pages
antonymilne Jul 24, 2024
5c7ad8e
Remove duplicated svgs
antonymilne Jul 24, 2024
8e37dac
Make page paths hierarchical
antonymilne Jul 24, 2024
3e65dc2
Move _page_utils, split out charts from components
antonymilne Jul 24, 2024
da88ea5
Remove DATA_DICT lookup in favour of directly using variables
antonymilne Jul 25, 2024
63da5d9
Tidy and lint
antonymilne Jul 25, 2024
0a4e243
- Make separate environment for examples with black as requirement
antonymilne Jul 25, 2024
d0c6b39
Fix scroll conflicts
huong-li-nguyen Jul 25, 2024
4df4e35
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 25, 2024
2036943
Fix README
huong-li-nguyen Jul 25, 2024
6116092
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 25, 2024
75e8def
Remove chart gallery from integration tests
antonymilne Jul 25, 2024
77f7ea7
Minor corrections
antonymilne Jul 25, 2024
b28deae
Change opacity of incomplete pages to 0.3
antonymilne Jul 25, 2024
7987dad
Final TODOs
antonymilne Jul 25, 2024
deccb7c
Merge branch 'main' into demo/chart-gallery
antonymilne Jul 25, 2024
b8c676a
Final final TODOs
antonymilne Jul 25, 2024
345a2fb
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 29, 2024
592f09d
PR comments Part 1
huong-li-nguyen Jul 29, 2024
3831e03
PR comments 2
huong-li-nguyen Jul 29, 2024
301c496
Add missing svgs
huong-li-nguyen Jul 29, 2024
d26681b
Fix svgs and table
huong-li-nguyen Jul 29, 2024
8fb4bfd
Create different examples for bar / column
huong-li-nguyen Jul 29, 2024
de19cfc
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 29, 2024
2cdd316
Merge branch 'main' into demo/chart-gallery
huong-li-nguyen Jul 29, 2024
075c52e
Update code example and add TODO
huong-li-nguyen Jul 29, 2024
c8619db
Fix CSS in code
huong-li-nguyen Jul 29, 2024
bffb4e8
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jul 29, 2024
f02ce50
Lint
huong-li-nguyen Jul 29, 2024
d52909f
Merge branch 'demo/chart-gallery' of https://github.com/mckinsey/vizr…
huong-li-nguyen Jul 29, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ target-version = ["py38"]
[tool.codespell]
builtin = "clear,rare,en-GB_to_en-US"
ignore-words-list = "grey,ned,sav"
skip = "*.min.css.map,*.min.css,.vale/*"
skip = "*.min.css.map,*.min.css,.vale/*, *assets/*"

[tool.mypy]
# strict checks : strict = true
Expand Down Expand Up @@ -91,3 +91,5 @@ select = [
"**/tests/**" = ["PLR2004", "S101", "TID252", "D100", "D101", "D102", "D103", "PLC1901", "RUF012"]
# Ignore import violations in all __init__.py files
"__init__.py" = ["E402", "F401"]
# Ignore missing docstrings in chart gallery examples to keep them succinct.
"vizro-core/examples/_chart-gallery/pages/examples/**" = ["D100", "D103"]
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
<!--
A new scriv changelog fragment.

Uncomment the section that is right (remove the HTML comment wrapper).
-->

<!--
### Highlights ✨

- A bullet item for the Highlights ✨ category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
<!--
### Removed

- A bullet item for the Removed category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
<!--
### Added

- A bullet item for the Added category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
<!--
### Changed

- A bullet item for the Changed category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
<!--
### Deprecated

- A bullet item for the Deprecated category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
<!--
### Fixed

- A bullet item for the Fixed category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
<!--
### Security

- A bullet item for the Security category with a link to the relevant PR at the end of your entry, e.g. Enable feature XXX ([#1](https://github.com/mckinsey/vizro/pull/1))

-->
21 changes: 21 additions & 0 deletions vizro-core/examples/_chart-gallery/LICENSE.txt
huong-li-nguyen marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2016 FT Interactive News

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
78 changes: 78 additions & 0 deletions vizro-core/examples/_chart-gallery/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
# Chart gallery dashboard

This dashboard shows a gallery of charts. It includes guidance on when to use each chart type and sample Python code
to create them using [Plotly](https://plotly.com/python/) and [Vizro](https://vizro.mckinsey.com/).

Inspired by the [FT Visual Vocabulary](https://github.com/Financial-Times/chart-doctor/blob/main/visual-vocabulary/README.md):
FT Graphics: Alan Smith, Chris Campbell, Ian Bott, Liz Faunce, Graham Parrish, Billy Ehrenberg, Paul McCallum, Martin Stabe.

## Chart types

The dashboard is still in development. Below is an overview of the chart types for which a completed page is available.

huong-li-nguyen marked this conversation as resolved.
Show resolved Hide resolved
| Chart Type | Status | Category |
| -------------------- | ------ | ------------------------ |
| Arc | ❌ | Part-to-whole |
| Area | ❌ | Time |
| Barcode | ❌ | Distribution |
| Bar | ✅ | Magnitude |
| Boxplot | ✅ | Distribution |
| Bubble | ❌ | Correlation, Magnitude |
| Bubble Map | ❌ | Spatial |
| Bubble Timeline | ❌ | Time |
| Bullet | ❌ | Magnitude |
| Butterfly | ✅ | Deviation, Distribution |
| Chord | ❌ | Flow |
| Choropleth | ✅ | Spatial |
| Column | ✅ | Magnitude, Time |
| Column-Line | ❌ | Correlation, Time |
| Cumulative Curve | ❌ | Distribution |
| Diverging Bar | ❌ | Deviation |
| Dot Map | ❌ | Spatial |
| Dot Plot | ❌ | Distribution |
| Donut | ✅ | Part-to-whole |
| Fan | ❌ | Time |
| Flow Map | ❌ | Spatial |
| Funnel | ❌ | Part-to-whole |
| Gantt | ❌ | Time |
| Heatmap | ❌ | Time |
| Heatmap-Matrix | ❌ | Correlation |
| Histogram | ❌ | Distribution |
| Line | ✅ | Time |
| Lollipop | ❌ | Ranking, Magnitude |
| Marimekko | ❌ | Magnitude, Part-to-whole |
| Ordered Bar | ✅ | Ranking |
| Ordered Bubble | ❌ | Ranking |
| Ordered Column | ✅ | Ranking |
| Parallel Coordinates | ❌ | Magnitude |
| Pictogram | ❌ | Magnitude |
| Pie | ✅ | Part-to-whole |
| Radar | ❌ | Magnitude |
| Radial | ❌ | Magnitude |
| Sankey | ✅ | Flow |
| Scatter | ✅ | Correlation |
| Scatter Matrix | ❌ | Correlation |
| Slope | ❌ | Ranking, Time |
| Sparkline | ❌ | Time |
| Stacked Bar | ❌ | Part-to-whole |
| Stacked Column | ❌ | Part-to-whole |
| Stepped Line | ❌ | Ranking |
| Surplus-Deficit-Line | ❌ | Deviation |
| Treemap | ✅ | Magnitude, Part-to-whole |
| Venn | ❌ | Part-to-whole |
| Violin | ✅ | Distribution |
| Waterfall | ❌ | Part-to-whole, Flow |

To contribute a chart, follow the steps below:

1. Place an `svg` file named after the chart type in the `assets` folder if not already available.
2. Create a new page for the chart type in `pages.py` and a code sample in `pages/examples`. Refer to existing pages for guidance.
3. Add any new datasets to `pages/_page_utils.py`.
4. Remove the page from `incomplete_pages` in the relevant `ChartGroup`(s) in `chart_groups.py`.
5. Update this `README.md` with the new chart type.

## How to run the example locally

1. If you have `hatch` set up, run the example with the command `hatch run example _chart-gallery`.
Otherwise, with a virtual Python environment activated, run `pip install -r requirements.txt` and then `python app.py`.
2. You should now be able to access the app locally via http://127.0.0.1:8050/.
108 changes: 108 additions & 0 deletions vizro-core/examples/_chart-gallery/app.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
"""App configuration for chart gallery dashboard."""

from typing import List, Union

import vizro.models as vm
from chart_groups import ALL_CHART_GROUP, CHART_GROUPS, ChartGroup, IncompletePage
from custom_components import FlexContainer, Markdown
from vizro import Vizro


def make_chart_card(page: Union[vm.Page, IncompletePage]) -> vm.Card:
"""Makes a card with svg icon, linked to the right page if page is complete.

Args:
page: page to make card for

Returns: card with svg icon, linked to the right page if page is complete.

"""
# There's one SVG per chart title, so that e.g. pages distribution-butterfly and deviation-butterfly, which both
# have title "Butterfly", correspond to butterfly.svg.
# Incomplete pages have page.path = "" so won't be linked to here.
svg_name = page.title.lower().replace(" ", "-")
return vm.Card(
text=f"""
![](assets/images/charts/{svg_name}.svg#chart-icon)

#### {page.title}
""",
href=page.path,
)


def make_homepage_container(chart_group: ChartGroup) -> vm.Container:
"""Makes a container with cards for each completed and incomplete chart in chart_group.

Args:
chart_group: group of charts to make container for.

Returns: container with cards for each chart in chart_group.

"""
# Pages are sorted in title's alphabetical order and deduplicated so that e.g. pages distribution-butterfly and
# deviation-butterfly, which both have title "Butterfly", correspond to a single card.
return vm.Container(
title=chart_group.name,
layout=vm.Layout(grid=[[0, 1, 1, 1]], col_gap="40px"),
components=[
Markdown(text=chart_group.intro_text, classname="intro-text"),
FlexContainer(
components=[
make_chart_card(page)
for page in sorted(
_remove_duplicates(chart_group.pages + chart_group.incomplete_pages),
key=lambda page: page.title,
)
],
),
],
)


def _remove_duplicates(pages: List[Union[vm.Page, IncompletePage]]) -> List[Union[vm.Page, IncompletePage]]:
# Deduplicate pages that have the same title. Using reversed means that the page that is kept is the first one
# in the dashboard. This will be the one that the card on the homepage links to.
return list({page.title: page for page in reversed(pages)}.values())


def make_navlink(chart_group: ChartGroup) -> vm.NavLink:
"""Makes a navlink with icon and links to every complete page within chart_group.

Args:
chart_group: chart_group to make a navlink for.

Returns: navlink for chart_group.

"""
# Pages are sorted in alphabetical order within each chart group.
return vm.NavLink(
label=chart_group.name,
pages={chart_group.name: [page.id for page in sorted(chart_group.pages, key=lambda page: page.title)]},
icon=chart_group.icon,
)


homepage = vm.Page(
title="Overview",
components=[
vm.Tabs(tabs=[make_homepage_container(chart_group) for chart_group in [ALL_CHART_GROUP, *CHART_GROUPS]]),
],
)


dashboard = vm.Dashboard(
# ALL_CHART_GROUP.pages has duplicated pages, e.g. both distribution-butterfly and deviation-butterfly.
pages=[homepage, *ALL_CHART_GROUP.pages],
navigation=vm.Navigation(
nav_selector=vm.NavBar(
items=[
vm.NavLink(label="Overview", pages=[homepage.id], icon="Home"),
]
+ [make_navlink(chart_group) for chart_group in CHART_GROUPS]
)
),
)

if __name__ == "__main__":
Vizro().build(dashboard).run()
9 changes: 9 additions & 0 deletions vizro-core/examples/_chart-gallery/assets/app.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
63 changes: 63 additions & 0 deletions vizro-core/examples/_chart-gallery/assets/css/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
#page-header {
padding-left: 8px;
}

#left-main {
width: 288px;
}

img[src*="#chart-icon"] {
width: 100%;
}

.code-clipboard {
font-size: 20px;
position: absolute;
right: 14px;
top: 12px;
}

.code-clipboard-container {
background: var(--surfaces-bg-card);
max-height: 500px;
overflow: auto;
padding: 1rem;
position: relative;
}

.code-clipboard-container::-webkit-scrollbar-thumb {
border-color: var(--surfaces-bg-card);
}

.flex-container .card {
height: 208px;
opacity: 0.3;
width: 176px;
}

.flex-container {
display: flex;
flex-wrap: wrap;
gap: 20px;
}

.flex-container h4 {
color: var(--text-secondary);
margin: 0;
padding-top: 12px;
text-align: center;
}

.intro-text {
border-left: 4px solid var(--text-secondary);
padding: 12px;
}

.intro-text p {
font-size: 16px;
line-height: 20px;
}

.flex-container .card-nav {
opacity: 1;
}
Binary file not shown.
25 changes: 25 additions & 0 deletions vizro-core/examples/_chart-gallery/assets/images/charts/arc.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions vizro-core/examples/_chart-gallery/assets/images/charts/bar.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading