Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
f838f24
Initial commit with some changes already:
maxschulz-COL Oct 23, 2025
0463bc7
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 23, 2025
2b67e42
Some notes
maxschulz-COL Oct 23, 2025
052f67f
New breakthrough with type
maxschulz-COL Oct 23, 2025
c169712
Type does not fix wrong validation
maxschulz-COL Oct 27, 2025
e227e99
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 27, 2025
7587ae5
Write proper tests
maxschulz-COL Oct 27, 2025
1c3bab0
Clean up app.py
maxschulz-COL Oct 27, 2025
bb426a8
Merge branch 'mm_latest' of github.com:mckinsey/vizro into mm_latest
maxschulz-COL Oct 27, 2025
be72ff0
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 27, 2025
3dc8dff
Refactor type handling in VizroBaseModel to respect custom component …
maxschulz-COL Oct 27, 2025
535e814
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 27, 2025
02d71c8
First addition of MM
maxschulz-COL Oct 28, 2025
93d1d12
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 28, 2025
0b8f25a
Build in the tree mechanism
maxschulz-COL Oct 28, 2025
7fff354
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 28, 2025
745ceb5
Add in private attribute to check if it gets lost on copy
maxschulz-COL Oct 28, 2025
54ccf3f
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 28, 2025
bcd4cea
Some notes
maxschulz-COL Oct 29, 2025
a0408ca
Add basic tree tests
maxschulz-COL Oct 29, 2025
1524ed1
Fix the issue of model copying
maxschulz-COL Oct 29, 2025
cd95f51
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 29, 2025
8a7dc2f
Add proper tests to check idempotency
maxschulz-COL Oct 29, 2025
80e09fc
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 29, 2025
19ca1f6
Clean-up
maxschulz-COL Oct 29, 2025
cbab0e9
Merge branch 'mm_latest' of github.com:mckinsey/vizro into mm_latest
maxschulz-COL Oct 29, 2025
d2df87a
Check for private attribute loosing and JSON schema
maxschulz-COL Oct 29, 2025
1a1ba96
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 29, 2025
e2b23bd
Summarize Fake Vizro creation
maxschulz-COL Oct 29, 2025
558db74
Merge branch 'mm_latest' of github.com:mckinsey/vizro into mm_latest
maxschulz-COL Oct 29, 2025
706d226
Initial ideas for CLAUDE.md
maxschulz-COL Oct 30, 2025
ff9f8b7
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 30, 2025
520884e
Building in the Forward Reference issue
maxschulz-COL Oct 30, 2025
08bcc8d
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 30, 2025
c62fcb4
Update TODOs
maxschulz-COL Oct 30, 2025
0712576
Merge branch 'main' into mm_latest
maxschulz-COL Oct 30, 2025
a5c3fbf
Additional notes
maxschulz-COL Oct 30, 2025
dff25a8
Build in forward refs further
maxschulz-COL Oct 30, 2025
77ef0a0
First work on cicular dep issue
maxschulz-COL Oct 30, 2025
c8ce772
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 30, 2025
8c848e5
Remove guidance file to get them from main
maxschulz-COL Oct 30, 2025
aa02376
Merge branch 'main' into mm_latest
maxschulz-COL Oct 30, 2025
c37ca44
Todo
maxschulz-COL Oct 30, 2025
b049825
Remove __pydantic_init_subclass__ to get around circular dependency i…
maxschulz-COL Oct 31, 2025
0d66612
First "working" dashboard
maxschulz-COL Oct 31, 2025
f5e391a
Make all Vizro models fields into a discriminated unions
maxschulz-COL Oct 31, 2025
fdd1d3b
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 31, 2025
e21a8c9
Move everything to typing
maxschulz-COL Oct 31, 2025
38771ff
Merge branch 'mm_latest' of github.com:mckinsey/vizro into mm_latest
maxschulz-COL Oct 31, 2025
2da8b33
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 31, 2025
661ac0d
Custom components work without add_type!
maxschulz-COL Oct 31, 2025
7e8f230
Dashboard successfully validates
maxschulz-COL Oct 31, 2025
f784a97
Dashboard renders although not fully functional
maxschulz-COL Oct 31, 2025
d92fd1f
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Oct 31, 2025
2820792
ToDos
maxschulz-COL Oct 31, 2025
12e9411
Merge branch 'mm_latest' of github.com:mckinsey/vizro into mm_latest
maxschulz-COL Oct 31, 2025
51e3181
Merge branch 'main' into mm_latest
maxschulz-COL Nov 3, 2025
52fe528
Check for custom component in tree
maxschulz-COL Nov 3, 2025
ca76bc6
Add custom components also to tree
maxschulz-COL Nov 3, 2025
c612d91
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Nov 3, 2025
b69ca54
Add models to tree in FIlter model
maxschulz-COL Nov 3, 2025
2042782
Add remaining later built components
maxschulz-COL Nov 4, 2025
0916173
Merge branch 'main' into mm_latest
maxschulz-COL Nov 4, 2025
fb5804f
Updated models.py list
maxschulz-COL Nov 4, 2025
b46dbc5
Working on current container bug
maxschulz-COL Nov 4, 2025
ad94f03
Add container to scratch app
maxschulz-COL Dec 3, 2025
fa3a013
Comment out container addition
maxschulz-COL Dec 9, 2025
947c2e8
Merge branch 'main' into mm_latest
maxschulz-COL Dec 10, 2025
9a04cae
Merge now works!!
maxschulz-COL Dec 10, 2025
ee2f39e
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Dec 10, 2025
81e31ec
Add some test for Container problem
maxschulz-COL Dec 10, 2025
a35a5e7
Merge branch 'mm_latest' of github.com:mckinsey/vizro into mm_latest
maxschulz-COL Dec 10, 2025
a6ae7db
Revert linting bug
maxschulz-COL Dec 10, 2025
ef598a0
Next plan for MM
maxschulz-COL Dec 11, 2025
735b98c
First time dev dashboard starting!
maxschulz-COL Dec 15, 2025
3e6f1a8
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Dec 15, 2025
b26658d
Merge branch 'main' into mm_latest
maxschulz-COL Dec 15, 2025
d3c9e83
Fixing ID and pre_build creation
maxschulz-COL Dec 16, 2025
d031d48
Private attr saving works
maxschulz-COL Dec 19, 2025
5618659
Remove models dict completely
maxschulz-COL Dec 19, 2025
6ac3152
Move the tree building to the build method
maxschulz-COL Dec 19, 2025
92b13d5
Commit outstanding ToDos
maxschulz-COL Dec 19, 2025
5fbc0a8
Some notes getting back
maxschulz-COL Jan 14, 2026
b56f6ed
Merge branch 'main' into mm_latest
maxschulz-COL Jan 14, 2026
2661f79
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Jan 14, 2026
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
15 changes: 8 additions & 7 deletions vizro-core/examples/dev/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -995,7 +995,7 @@ def my_custom_table(data_frame=None, chosen_columns: list[str] | None = None):
class TooltipNonCrossRangeSlider(vm.RangeSlider):
"""Custom numeric multi-selector `TooltipNonCrossRangeSlider`."""

type: Literal["other_range_slider"] = "other_range_slider"
type: Literal["custom_component"] = "custom_component"

def build(self):
"""Extend existing component by calling the super build and update properties."""
Expand All @@ -1005,14 +1005,14 @@ def build(self):
return range_slider_build_obj


vm.Filter.add_type("selector", TooltipNonCrossRangeSlider)
# vm.Filter.add_type("selector", TooltipNonCrossRangeSlider)


# 2. Create new custom component
class Jumbotron(vm.VizroBaseModel):
"""New custom component `Jumbotron`."""

type: Literal["jumbotron"] = "jumbotron"
type: Literal["custom_component"] = "custom_component"
title: str
subtitle: str
text: str
Expand All @@ -1022,7 +1022,7 @@ def build(self):
return html.Div([html.H2(self.title), html.H3(self.subtitle), html.P(self.text)])


vm.Page.add_type("components", Jumbotron)
# vm.Page.add_type("components", Jumbotron)

custom_components = vm.Page(
title="Custom Components",
Expand Down Expand Up @@ -1093,15 +1093,15 @@ def multiple_cards(data_frame: pd.DataFrame, n_rows: int | None = 1) -> html.Div


# DASHBOARD -------------------------------------------------------------------
components = [graphs, ag_grid, table, cards, figure, button, containers, tabs, tooltip]
components = [tabs, graphs, ag_grid, table, cards, figure, button, containers, tooltip]
controls = [filters, parameters, selectors, controls_in_containers]
actions = [export_data_action]
layout = [grid_layout, flex_layout]
extensions = [custom_charts, custom_tables, custom_figures, custom_components]

dashboard = vm.Dashboard(
title="Vizro Features",
pages=[home, *components, *controls, *actions, *layout, *extensions],
pages=[home, *controls, *actions, *layout, *extensions, *components],
navigation=vm.Navigation(
nav_selector=vm.NavBar(
items=[
Expand Down Expand Up @@ -1140,6 +1140,7 @@ def multiple_cards(data_frame: pd.DataFrame, n_rows: int | None = 1) -> html.Div

if __name__ == "__main__":
# Move app definition outside of __main__ block for the HF demo to work
print("================ STARTING TREE BUILDING ==================")
app = Vizro().build(dashboard)
app.dash.layout.children.append(
dbc.NavLink(
Expand All @@ -1149,4 +1150,4 @@ def multiple_cards(data_frame: pd.DataFrame, n_rows: int | None = 1) -> html.Div
class_name="anchor-container",
)
)
app.run()
app.run(debug=False)
158 changes: 158 additions & 0 deletions vizro-core/examples/dev/notebook/example.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": null,
"id": "2a4a1132",
"metadata": {},
"outputs": [],
"source": [
"import vizro.models as vm\n",
"from vizro import Vizro"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "125bf3e0",
"metadata": {},
"outputs": [],
"source": [
"card = vm.Card(\n",
" id=\"card_1\",\n",
" text=\"Card 1\",\n",
")\n",
"\n",
"card2 = vm.Card(\n",
" id=\"card_2\",\n",
" text=\"Card 2\",\n",
")\n",
"\n",
"page = vm.Page(\n",
" # id=\"page_1\",\n",
" title=\"Page 1\",\n",
" components=[card, card2],\n",
")\n",
"\n",
"dashboard = vm.Dashboard(\n",
" id=\"dashboard_1\",\n",
" title=\"Dashboard 1\",\n",
" pages=[page],\n",
")"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "b3c5f8eb",
"metadata": {},
"outputs": [],
"source": [
"from dash._callback_context import context_value\n",
"\n",
"context_value.set({})\n",
"\n",
"dashboard = vm.Dashboard.model_validate(dashboard, context={\"build_tree\": True})\n",
"app = Vizro().build(dashboard)\n",
"\n",
"# TODO: Make this work!\n",
"app.run(debug=False)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "115a8176",
"metadata": {},
"outputs": [],
"source": [
"dashboard._tree.print(repr=\"{node.kind} -> {node.data.type} (id={node.data.id})\")"
]
},
{
"cell_type": "markdown",
"id": "a13a7ee5",
"metadata": {},
"source": [
"It seems that a second dashboard is not yet possible, due to path collision"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "5835c587",
"metadata": {},
"outputs": [],
"source": [
"card = vm.Card(\n",
" id=\"card_1\",\n",
" text=\"Card 1 asdf\",\n",
")\n",
"\n",
"card2 = vm.Card(\n",
" id=\"card_2\",\n",
" text=\"Card 2 asdf\",\n",
")\n",
"\n",
"page = vm.Page(\n",
" # id=\"page_1\",\n",
" title=\"Page 1 qwer\",\n",
" components=[card, card2],\n",
")\n",
"\n",
"dashboard = vm.Dashboard(\n",
" id=\"dashboard_1\",\n",
" title=\"Dashboard 1 asdf\",\n",
" pages=[page],\n",
")"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "3e47f325",
"metadata": {},
"outputs": [],
"source": [
"from dash._callback_context import context_value\n",
"\n",
"context_value.set({})\n",
"\n",
"dashboard = vm.Dashboard.model_validate(dashboard, context={\"build_tree\": True})\n",
"app = Vizro().build(dashboard)\n",
"\n",
"# TODO: Make this work!\n",
"app.run(debug=False, port=8055)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "bb9f29f9",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "vizro",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.13.9"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
Loading
Loading