reflex 0.6.8a1__py3-none-any.whl → 0.7.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of reflex might be problematic. Click here for more details.
- reflex/.templates/jinja/custom_components/pyproject.toml.jinja2 +1 -1
- reflex/.templates/jinja/web/pages/_app.js.jinja2 +7 -7
- reflex/.templates/jinja/web/pages/utils.js.jinja2 +3 -3
- reflex/.templates/web/components/reflex/radix_themes_color_mode_provider.js +1 -4
- reflex/.templates/web/utils/state.js +65 -36
- reflex/__init__.py +4 -17
- reflex/__init__.pyi +1 -2
- reflex/app.py +286 -135
- reflex/app_mixins/lifespan.py +9 -9
- reflex/app_mixins/middleware.py +6 -6
- reflex/app_module_for_backend.py +3 -7
- reflex/base.py +7 -7
- reflex/compiler/compiler.py +8 -0
- reflex/compiler/utils.py +57 -18
- reflex/components/base/app_wrap.pyi +16 -16
- reflex/components/base/bare.py +1 -1
- reflex/components/base/body.pyi +16 -16
- reflex/components/base/document.pyi +76 -76
- reflex/components/base/error_boundary.py +2 -1
- reflex/components/base/error_boundary.pyi +19 -22
- reflex/components/base/fragment.pyi +16 -16
- reflex/components/base/head.pyi +31 -31
- reflex/components/base/link.pyi +31 -31
- reflex/components/base/meta.py +2 -2
- reflex/components/base/meta.pyi +61 -61
- reflex/components/base/script.pyi +19 -19
- reflex/components/base/strict_mode.py +10 -0
- reflex/components/base/strict_mode.pyi +57 -0
- reflex/components/component.py +38 -77
- reflex/components/core/banner.py +159 -4
- reflex/components/core/banner.pyi +162 -76
- reflex/components/core/breakpoints.py +3 -1
- reflex/components/core/client_side_routing.py +1 -1
- reflex/components/core/client_side_routing.pyi +32 -32
- reflex/components/core/clipboard.pyi +17 -20
- reflex/components/core/cond.py +9 -10
- reflex/components/core/debounce.py +1 -1
- reflex/components/core/debounce.pyi +17 -17
- reflex/components/core/foreach.py +28 -3
- reflex/components/core/html.py +1 -1
- reflex/components/core/html.pyi +16 -16
- reflex/components/core/match.py +5 -5
- reflex/components/core/sticky.py +134 -0
- reflex/components/core/sticky.pyi +449 -0
- reflex/components/core/upload.py +2 -2
- reflex/components/core/upload.pyi +80 -88
- reflex/components/datadisplay/code.py +5 -14
- reflex/components/datadisplay/code.pyi +31 -31
- reflex/components/datadisplay/dataeditor.py +7 -4
- reflex/components/datadisplay/dataeditor.pyi +40 -54
- reflex/components/datadisplay/logo.py +13 -8
- reflex/components/datadisplay/shiki_code_block.py +14 -9
- reflex/components/datadisplay/shiki_code_block.pyi +46 -46
- reflex/components/dynamic.py +22 -3
- reflex/components/el/constants/reflex.py +1 -1
- reflex/components/el/element.py +1 -1
- reflex/components/el/element.pyi +16 -16
- reflex/components/el/elements/base.pyi +16 -16
- reflex/components/el/elements/forms.py +4 -4
- reflex/components/el/elements/forms.pyi +224 -258
- reflex/components/el/elements/inline.pyi +421 -421
- reflex/components/el/elements/media.pyi +376 -376
- reflex/components/el/elements/metadata.pyi +91 -91
- reflex/components/el/elements/other.pyi +106 -106
- reflex/components/el/elements/scripts.pyi +46 -46
- reflex/components/el/elements/sectioning.pyi +226 -226
- reflex/components/el/elements/tables.pyi +151 -151
- reflex/components/el/elements/typography.pyi +226 -226
- reflex/components/gridjs/datatable.pyi +31 -31
- reflex/components/lucide/icon.py +46 -8
- reflex/components/lucide/icon.pyi +85 -31
- reflex/components/markdown/markdown.py +10 -8
- reflex/components/markdown/markdown.pyi +16 -16
- reflex/components/moment/moment.py +2 -2
- reflex/components/moment/moment.pyi +17 -19
- reflex/components/next/base.pyi +16 -16
- reflex/components/next/image.py +16 -4
- reflex/components/next/image.pyi +22 -20
- reflex/components/next/link.py +1 -1
- reflex/components/next/link.pyi +16 -16
- reflex/components/next/video.pyi +16 -16
- reflex/components/plotly/__init__.py +29 -2
- reflex/components/plotly/plotly.py +240 -5
- reflex/components/plotly/plotly.pyi +799 -44
- reflex/components/props.py +3 -3
- reflex/components/radix/__init__.pyi +1 -1
- reflex/components/radix/primitives/accordion.py +9 -5
- reflex/components/radix/primitives/accordion.pyi +110 -108
- reflex/components/radix/primitives/base.pyi +31 -31
- reflex/components/radix/primitives/drawer.py +5 -2
- reflex/components/radix/primitives/drawer.pyi +179 -187
- reflex/components/radix/primitives/form.pyi +160 -172
- reflex/components/radix/primitives/progress.py +1 -1
- reflex/components/radix/primitives/progress.pyi +76 -76
- reflex/components/radix/primitives/slider.py +1 -1
- reflex/components/radix/primitives/slider.pyi +78 -82
- reflex/components/radix/themes/base.pyi +121 -121
- reflex/components/radix/themes/color_mode.py +11 -9
- reflex/components/radix/themes/color_mode.pyi +47 -49
- reflex/components/radix/themes/components/alert_dialog.py +3 -0
- reflex/components/radix/themes/components/alert_dialog.pyi +110 -112
- reflex/components/radix/themes/components/aspect_ratio.pyi +16 -16
- reflex/components/radix/themes/components/avatar.pyi +16 -16
- reflex/components/radix/themes/components/badge.pyi +16 -16
- reflex/components/radix/themes/components/button.pyi +16 -16
- reflex/components/radix/themes/components/callout.pyi +76 -76
- reflex/components/radix/themes/components/card.py +1 -1
- reflex/components/radix/themes/components/card.pyi +17 -17
- reflex/components/radix/themes/components/checkbox.pyi +49 -55
- reflex/components/radix/themes/components/checkbox_cards.pyi +31 -31
- reflex/components/radix/themes/components/checkbox_group.pyi +31 -31
- reflex/components/radix/themes/components/context_menu.py +5 -0
- reflex/components/radix/themes/components/context_menu.pyi +149 -155
- reflex/components/radix/themes/components/data_list.pyi +61 -61
- reflex/components/radix/themes/components/dialog.py +3 -0
- reflex/components/radix/themes/components/dialog.pyi +113 -117
- reflex/components/radix/themes/components/dropdown_menu.py +5 -0
- reflex/components/radix/themes/components/dropdown_menu.pyi +133 -137
- reflex/components/radix/themes/components/hover_card.py +3 -0
- reflex/components/radix/themes/components/hover_card.pyi +63 -67
- reflex/components/radix/themes/components/icon_button.py +2 -2
- reflex/components/radix/themes/components/icon_button.pyi +17 -16
- reflex/components/radix/themes/components/inset.pyi +16 -16
- reflex/components/radix/themes/components/popover.py +3 -0
- reflex/components/radix/themes/components/popover.pyi +68 -70
- reflex/components/radix/themes/components/progress.pyi +16 -16
- reflex/components/radix/themes/components/radio.pyi +16 -16
- reflex/components/radix/themes/components/radio_cards.py +2 -0
- reflex/components/radix/themes/components/radio_cards.pyi +32 -34
- reflex/components/radix/themes/components/radio_group.py +1 -1
- reflex/components/radix/themes/components/radio_group.pyi +62 -64
- reflex/components/radix/themes/components/scroll_area.pyi +16 -16
- reflex/components/radix/themes/components/segmented_control.pyi +32 -35
- reflex/components/radix/themes/components/select.py +4 -0
- reflex/components/radix/themes/components/select.pyi +145 -157
- reflex/components/radix/themes/components/separator.pyi +16 -16
- reflex/components/radix/themes/components/skeleton.py +3 -0
- reflex/components/radix/themes/components/skeleton.pyi +16 -16
- reflex/components/radix/themes/components/slider.pyi +22 -28
- reflex/components/radix/themes/components/spinner.pyi +16 -16
- reflex/components/radix/themes/components/switch.pyi +17 -19
- reflex/components/radix/themes/components/table.pyi +106 -106
- reflex/components/radix/themes/components/tabs.py +3 -0
- reflex/components/radix/themes/components/tabs.pyi +78 -82
- reflex/components/radix/themes/components/text_area.py +12 -0
- reflex/components/radix/themes/components/text_area.pyi +21 -33
- reflex/components/radix/themes/components/text_field.py +1 -1
- reflex/components/radix/themes/components/text_field.pyi +52 -80
- reflex/components/radix/themes/components/tooltip.py +6 -1
- reflex/components/radix/themes/components/tooltip.pyi +20 -21
- reflex/components/radix/themes/layout/__init__.pyi +1 -1
- reflex/components/radix/themes/layout/base.pyi +16 -16
- reflex/components/radix/themes/layout/box.pyi +16 -16
- reflex/components/radix/themes/layout/center.pyi +16 -16
- reflex/components/radix/themes/layout/container.pyi +16 -16
- reflex/components/radix/themes/layout/flex.pyi +16 -16
- reflex/components/radix/themes/layout/grid.pyi +16 -16
- reflex/components/radix/themes/layout/list.py +2 -2
- reflex/components/radix/themes/layout/list.pyi +76 -76
- reflex/components/radix/themes/layout/section.pyi +16 -16
- reflex/components/radix/themes/layout/spacer.pyi +16 -16
- reflex/components/radix/themes/layout/stack.py +2 -2
- reflex/components/radix/themes/layout/stack.pyi +46 -46
- reflex/components/radix/themes/typography/blockquote.pyi +16 -16
- reflex/components/radix/themes/typography/code.pyi +16 -16
- reflex/components/radix/themes/typography/heading.pyi +16 -16
- reflex/components/radix/themes/typography/link.py +1 -1
- reflex/components/radix/themes/typography/link.pyi +16 -16
- reflex/components/radix/themes/typography/text.py +2 -2
- reflex/components/radix/themes/typography/text.pyi +106 -106
- reflex/components/react_player/audio.pyi +33 -39
- reflex/components/react_player/react_player.py +1 -1
- reflex/components/react_player/react_player.pyi +32 -38
- reflex/components/react_player/video.pyi +33 -39
- reflex/components/recharts/__init__.py +2 -0
- reflex/components/recharts/__init__.pyi +2 -0
- reflex/components/recharts/cartesian.pyi +282 -282
- reflex/components/recharts/charts.py +15 -15
- reflex/components/recharts/charts.pyi +164 -164
- reflex/components/recharts/general.py +19 -4
- reflex/components/recharts/general.pyi +132 -81
- reflex/components/recharts/polar.py +2 -2
- reflex/components/recharts/polar.pyi +55 -55
- reflex/components/recharts/recharts.py +4 -4
- reflex/components/recharts/recharts.pyi +31 -31
- reflex/components/sonner/toast.py +15 -13
- reflex/components/sonner/toast.pyi +22 -22
- reflex/components/suneditor/editor.py +6 -4
- reflex/components/suneditor/editor.pyi +26 -40
- reflex/components/tags/iter_tag.py +3 -3
- reflex/components/tags/tag.py +25 -3
- reflex/config.py +48 -20
- reflex/constants/__init__.py +1 -0
- reflex/constants/base.py +4 -1
- reflex/constants/compiler.py +5 -2
- reflex/constants/config.py +8 -1
- reflex/constants/installer.py +9 -9
- reflex/constants/style.py +1 -1
- reflex/custom_components/custom_components.py +18 -10
- reflex/event.py +228 -233
- reflex/experimental/__init__.py +19 -11
- reflex/experimental/client_state.py +53 -28
- reflex/experimental/hooks.py +5 -5
- reflex/experimental/layout.py +8 -5
- reflex/experimental/layout.pyi +79 -83
- reflex/experimental/misc.py +3 -3
- reflex/istate/wrappers.py +1 -1
- reflex/middleware/hydrate_middleware.py +2 -2
- reflex/model.py +11 -6
- reflex/page.py +5 -5
- reflex/reflex.py +104 -26
- reflex/route.py +1 -1
- reflex/state.py +358 -401
- reflex/style.py +27 -3
- reflex/testing.py +34 -39
- reflex/utils/build.py +6 -2
- reflex/utils/codespaces.py +1 -4
- reflex/utils/compat.py +6 -5
- reflex/utils/console.py +71 -21
- reflex/utils/exceptions.py +89 -26
- reflex/utils/exec.py +69 -74
- reflex/utils/export.py +6 -1
- reflex/utils/format.py +8 -40
- reflex/utils/imports.py +5 -2
- reflex/utils/lazy_loader.py +7 -1
- reflex/utils/path_ops.py +74 -14
- reflex/utils/prerequisites.py +345 -68
- reflex/utils/processes.py +45 -32
- reflex/utils/pyi_generator.py +39 -33
- reflex/utils/registry.py +4 -4
- reflex/utils/serializers.py +1 -1
- reflex/utils/telemetry.py +5 -4
- reflex/utils/types.py +42 -18
- reflex/vars/base.py +695 -330
- reflex/vars/datetime.py +6 -7
- reflex/vars/dep_tracking.py +344 -0
- reflex/vars/function.py +11 -5
- reflex/vars/number.py +31 -43
- reflex/vars/object.py +74 -64
- reflex/vars/sequence.py +79 -67
- {reflex-0.6.8a1.dist-info → reflex-0.7.0.dist-info}/METADATA +7 -10
- reflex-0.7.0.dist-info/RECORD +401 -0
- {reflex-0.6.8a1.dist-info → reflex-0.7.0.dist-info}/WHEEL +1 -1
- reflex/experimental/assets.py +0 -37
- reflex/proxy.py +0 -119
- reflex-0.6.8a1.dist-info/RECORD +0 -398
- {reflex-0.6.8a1.dist-info → reflex-0.7.0.dist-info}/LICENSE +0 -0
- {reflex-0.6.8a1.dist-info → reflex-0.7.0.dist-info}/entry_points.txt +0 -0
|
@@ -25,10 +25,10 @@ class ChartBase(RechartsCharts):
|
|
|
25
25
|
"""A component that wraps a Recharts charts."""
|
|
26
26
|
|
|
27
27
|
# The width of chart container. String or Integer
|
|
28
|
-
width: Var[Union[str, int]] = "100%"
|
|
28
|
+
width: Var[Union[str, int]] = Var.create("100%")
|
|
29
29
|
|
|
30
30
|
# The height of chart container.
|
|
31
|
-
height: Var[Union[str, int]] = "100%"
|
|
31
|
+
height: Var[Union[str, int]] = Var.create("100%")
|
|
32
32
|
|
|
33
33
|
# The customized event handler of click on the component in this chart
|
|
34
34
|
on_click: EventHandler[no_args_event_spec]
|
|
@@ -69,7 +69,7 @@ class ChartBase(RechartsCharts):
|
|
|
69
69
|
)
|
|
70
70
|
|
|
71
71
|
@classmethod
|
|
72
|
-
def create(cls, *children, **props) -> Component:
|
|
72
|
+
def create(cls, *children: Any, **props: Any) -> Component:
|
|
73
73
|
"""Create a chart component.
|
|
74
74
|
|
|
75
75
|
Args:
|
|
@@ -84,19 +84,19 @@ class ChartBase(RechartsCharts):
|
|
|
84
84
|
cls._ensure_valid_dimension("width", width)
|
|
85
85
|
cls._ensure_valid_dimension("height", height)
|
|
86
86
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
dim_props["min_width"] = 200
|
|
94
|
-
if height is None:
|
|
95
|
-
dim_props["min_height"] = 100
|
|
87
|
+
# Ensure that the min_height and min_width are set to prevent the chart from collapsing.
|
|
88
|
+
# We are using small values so that height and width can still be used over min_height and min_width.
|
|
89
|
+
# Without this, sometimes the chart will not be visible. Causing confusion to the user.
|
|
90
|
+
# With this, the user will see a small chart and can adjust the height and width and can figure out that the issue is with the size.
|
|
91
|
+
min_height = props.pop("min_height", 10)
|
|
92
|
+
min_width = props.pop("min_width", 10)
|
|
96
93
|
|
|
97
94
|
return ResponsiveContainer.create(
|
|
98
95
|
super().create(*children, **props),
|
|
99
|
-
|
|
96
|
+
width=width if width is not None else "100%",
|
|
97
|
+
height=height if height is not None else "100%",
|
|
98
|
+
min_width=min_width,
|
|
99
|
+
min_height=min_height,
|
|
100
100
|
)
|
|
101
101
|
|
|
102
102
|
|
|
@@ -458,10 +458,10 @@ class Treemap(RechartsCharts):
|
|
|
458
458
|
alias = "RechartsTreemap"
|
|
459
459
|
|
|
460
460
|
# The width of chart container. String or Integer. Default: "100%"
|
|
461
|
-
width: Var[Union[str, int]] = "100%"
|
|
461
|
+
width: Var[Union[str, int]] = Var.create("100%")
|
|
462
462
|
|
|
463
463
|
# The height of chart container. String or Integer. Default: "100%"
|
|
464
|
-
height: Var[Union[str, int]] = "100%"
|
|
464
|
+
height: Var[Union[str, int]] = Var.create("100%")
|
|
465
465
|
|
|
466
466
|
# data of treemap. Array
|
|
467
467
|
data: Var[List[Dict[str, Any]]]
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
from typing import Any, Dict, List, Literal, Optional, Union, overload
|
|
7
7
|
|
|
8
8
|
from reflex.constants.colors import Color
|
|
9
|
-
from reflex.event import
|
|
9
|
+
from reflex.event import EventType
|
|
10
10
|
from reflex.style import Style
|
|
11
11
|
from reflex.vars.base import Var
|
|
12
12
|
|
|
@@ -26,21 +26,21 @@ class ChartBase(RechartsCharts):
|
|
|
26
26
|
class_name: Optional[Any] = None,
|
|
27
27
|
autofocus: Optional[bool] = None,
|
|
28
28
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
29
|
-
on_blur: Optional[EventType[
|
|
30
|
-
on_click: Optional[EventType[
|
|
31
|
-
on_context_menu: Optional[EventType[
|
|
32
|
-
on_double_click: Optional[EventType[
|
|
33
|
-
on_focus: Optional[EventType[
|
|
34
|
-
on_mount: Optional[EventType[
|
|
35
|
-
on_mouse_down: Optional[EventType[
|
|
36
|
-
on_mouse_enter: Optional[EventType[
|
|
37
|
-
on_mouse_leave: Optional[EventType[
|
|
38
|
-
on_mouse_move: Optional[EventType[
|
|
39
|
-
on_mouse_out: Optional[EventType[
|
|
40
|
-
on_mouse_over: Optional[EventType[
|
|
41
|
-
on_mouse_up: Optional[EventType[
|
|
42
|
-
on_scroll: Optional[EventType[
|
|
43
|
-
on_unmount: Optional[EventType[
|
|
29
|
+
on_blur: Optional[EventType[()]] = None,
|
|
30
|
+
on_click: Optional[EventType[()]] = None,
|
|
31
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
32
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
33
|
+
on_focus: Optional[EventType[()]] = None,
|
|
34
|
+
on_mount: Optional[EventType[()]] = None,
|
|
35
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
36
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
37
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
38
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
39
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
40
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
41
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
42
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
43
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
44
44
|
**props,
|
|
45
45
|
) -> "ChartBase":
|
|
46
46
|
"""Create a chart component.
|
|
@@ -98,21 +98,21 @@ class CategoricalChartBase(ChartBase):
|
|
|
98
98
|
class_name: Optional[Any] = None,
|
|
99
99
|
autofocus: Optional[bool] = None,
|
|
100
100
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
101
|
-
on_blur: Optional[EventType[
|
|
102
|
-
on_click: Optional[EventType[
|
|
103
|
-
on_context_menu: Optional[EventType[
|
|
104
|
-
on_double_click: Optional[EventType[
|
|
105
|
-
on_focus: Optional[EventType[
|
|
106
|
-
on_mount: Optional[EventType[
|
|
107
|
-
on_mouse_down: Optional[EventType[
|
|
108
|
-
on_mouse_enter: Optional[EventType[
|
|
109
|
-
on_mouse_leave: Optional[EventType[
|
|
110
|
-
on_mouse_move: Optional[EventType[
|
|
111
|
-
on_mouse_out: Optional[EventType[
|
|
112
|
-
on_mouse_over: Optional[EventType[
|
|
113
|
-
on_mouse_up: Optional[EventType[
|
|
114
|
-
on_scroll: Optional[EventType[
|
|
115
|
-
on_unmount: Optional[EventType[
|
|
101
|
+
on_blur: Optional[EventType[()]] = None,
|
|
102
|
+
on_click: Optional[EventType[()]] = None,
|
|
103
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
104
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
105
|
+
on_focus: Optional[EventType[()]] = None,
|
|
106
|
+
on_mount: Optional[EventType[()]] = None,
|
|
107
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
108
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
109
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
110
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
111
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
112
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
113
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
114
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
115
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
116
116
|
**props,
|
|
117
117
|
) -> "CategoricalChartBase":
|
|
118
118
|
"""Create a chart component.
|
|
@@ -183,21 +183,21 @@ class AreaChart(CategoricalChartBase):
|
|
|
183
183
|
class_name: Optional[Any] = None,
|
|
184
184
|
autofocus: Optional[bool] = None,
|
|
185
185
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
186
|
-
on_blur: Optional[EventType[
|
|
187
|
-
on_click: Optional[EventType[
|
|
188
|
-
on_context_menu: Optional[EventType[
|
|
189
|
-
on_double_click: Optional[EventType[
|
|
190
|
-
on_focus: Optional[EventType[
|
|
191
|
-
on_mount: Optional[EventType[
|
|
192
|
-
on_mouse_down: Optional[EventType[
|
|
193
|
-
on_mouse_enter: Optional[EventType[
|
|
194
|
-
on_mouse_leave: Optional[EventType[
|
|
195
|
-
on_mouse_move: Optional[EventType[
|
|
196
|
-
on_mouse_out: Optional[EventType[
|
|
197
|
-
on_mouse_over: Optional[EventType[
|
|
198
|
-
on_mouse_up: Optional[EventType[
|
|
199
|
-
on_scroll: Optional[EventType[
|
|
200
|
-
on_unmount: Optional[EventType[
|
|
186
|
+
on_blur: Optional[EventType[()]] = None,
|
|
187
|
+
on_click: Optional[EventType[()]] = None,
|
|
188
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
189
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
190
|
+
on_focus: Optional[EventType[()]] = None,
|
|
191
|
+
on_mount: Optional[EventType[()]] = None,
|
|
192
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
193
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
194
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
195
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
196
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
197
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
198
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
199
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
200
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
201
201
|
**props,
|
|
202
202
|
) -> "AreaChart":
|
|
203
203
|
"""Create a chart component.
|
|
@@ -267,21 +267,21 @@ class BarChart(CategoricalChartBase):
|
|
|
267
267
|
class_name: Optional[Any] = None,
|
|
268
268
|
autofocus: Optional[bool] = None,
|
|
269
269
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
270
|
-
on_blur: Optional[EventType[
|
|
271
|
-
on_click: Optional[EventType[
|
|
272
|
-
on_context_menu: Optional[EventType[
|
|
273
|
-
on_double_click: Optional[EventType[
|
|
274
|
-
on_focus: Optional[EventType[
|
|
275
|
-
on_mount: Optional[EventType[
|
|
276
|
-
on_mouse_down: Optional[EventType[
|
|
277
|
-
on_mouse_enter: Optional[EventType[
|
|
278
|
-
on_mouse_leave: Optional[EventType[
|
|
279
|
-
on_mouse_move: Optional[EventType[
|
|
280
|
-
on_mouse_out: Optional[EventType[
|
|
281
|
-
on_mouse_over: Optional[EventType[
|
|
282
|
-
on_mouse_up: Optional[EventType[
|
|
283
|
-
on_scroll: Optional[EventType[
|
|
284
|
-
on_unmount: Optional[EventType[
|
|
270
|
+
on_blur: Optional[EventType[()]] = None,
|
|
271
|
+
on_click: Optional[EventType[()]] = None,
|
|
272
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
273
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
274
|
+
on_focus: Optional[EventType[()]] = None,
|
|
275
|
+
on_mount: Optional[EventType[()]] = None,
|
|
276
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
277
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
278
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
279
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
280
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
281
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
282
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
283
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
284
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
285
285
|
**props,
|
|
286
286
|
) -> "BarChart":
|
|
287
287
|
"""Create a chart component.
|
|
@@ -350,21 +350,21 @@ class LineChart(CategoricalChartBase):
|
|
|
350
350
|
class_name: Optional[Any] = None,
|
|
351
351
|
autofocus: Optional[bool] = None,
|
|
352
352
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
353
|
-
on_blur: Optional[EventType[
|
|
354
|
-
on_click: Optional[EventType[
|
|
355
|
-
on_context_menu: Optional[EventType[
|
|
356
|
-
on_double_click: Optional[EventType[
|
|
357
|
-
on_focus: Optional[EventType[
|
|
358
|
-
on_mount: Optional[EventType[
|
|
359
|
-
on_mouse_down: Optional[EventType[
|
|
360
|
-
on_mouse_enter: Optional[EventType[
|
|
361
|
-
on_mouse_leave: Optional[EventType[
|
|
362
|
-
on_mouse_move: Optional[EventType[
|
|
363
|
-
on_mouse_out: Optional[EventType[
|
|
364
|
-
on_mouse_over: Optional[EventType[
|
|
365
|
-
on_mouse_up: Optional[EventType[
|
|
366
|
-
on_scroll: Optional[EventType[
|
|
367
|
-
on_unmount: Optional[EventType[
|
|
353
|
+
on_blur: Optional[EventType[()]] = None,
|
|
354
|
+
on_click: Optional[EventType[()]] = None,
|
|
355
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
356
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
357
|
+
on_focus: Optional[EventType[()]] = None,
|
|
358
|
+
on_mount: Optional[EventType[()]] = None,
|
|
359
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
360
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
361
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
362
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
363
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
364
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
365
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
366
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
367
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
368
368
|
**props,
|
|
369
369
|
) -> "LineChart":
|
|
370
370
|
"""Create a chart component.
|
|
@@ -439,21 +439,21 @@ class ComposedChart(CategoricalChartBase):
|
|
|
439
439
|
class_name: Optional[Any] = None,
|
|
440
440
|
autofocus: Optional[bool] = None,
|
|
441
441
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
442
|
-
on_blur: Optional[EventType[
|
|
443
|
-
on_click: Optional[EventType[
|
|
444
|
-
on_context_menu: Optional[EventType[
|
|
445
|
-
on_double_click: Optional[EventType[
|
|
446
|
-
on_focus: Optional[EventType[
|
|
447
|
-
on_mount: Optional[EventType[
|
|
448
|
-
on_mouse_down: Optional[EventType[
|
|
449
|
-
on_mouse_enter: Optional[EventType[
|
|
450
|
-
on_mouse_leave: Optional[EventType[
|
|
451
|
-
on_mouse_move: Optional[EventType[
|
|
452
|
-
on_mouse_out: Optional[EventType[
|
|
453
|
-
on_mouse_over: Optional[EventType[
|
|
454
|
-
on_mouse_up: Optional[EventType[
|
|
455
|
-
on_scroll: Optional[EventType[
|
|
456
|
-
on_unmount: Optional[EventType[
|
|
442
|
+
on_blur: Optional[EventType[()]] = None,
|
|
443
|
+
on_click: Optional[EventType[()]] = None,
|
|
444
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
445
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
446
|
+
on_focus: Optional[EventType[()]] = None,
|
|
447
|
+
on_mount: Optional[EventType[()]] = None,
|
|
448
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
449
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
450
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
451
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
452
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
453
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
454
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
455
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
456
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
457
457
|
**props,
|
|
458
458
|
) -> "ComposedChart":
|
|
459
459
|
"""Create a chart component.
|
|
@@ -505,21 +505,21 @@ class PieChart(ChartBase):
|
|
|
505
505
|
class_name: Optional[Any] = None,
|
|
506
506
|
autofocus: Optional[bool] = None,
|
|
507
507
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
508
|
-
on_blur: Optional[EventType[
|
|
509
|
-
on_click: Optional[EventType[
|
|
510
|
-
on_context_menu: Optional[EventType[
|
|
511
|
-
on_double_click: Optional[EventType[
|
|
512
|
-
on_focus: Optional[EventType[
|
|
513
|
-
on_mount: Optional[EventType[
|
|
514
|
-
on_mouse_down: Optional[EventType[
|
|
515
|
-
on_mouse_enter: Optional[EventType[
|
|
516
|
-
on_mouse_leave: Optional[EventType[
|
|
517
|
-
on_mouse_move: Optional[EventType[
|
|
518
|
-
on_mouse_out: Optional[EventType[
|
|
519
|
-
on_mouse_over: Optional[EventType[
|
|
520
|
-
on_mouse_up: Optional[EventType[
|
|
521
|
-
on_scroll: Optional[EventType[
|
|
522
|
-
on_unmount: Optional[EventType[
|
|
508
|
+
on_blur: Optional[EventType[()]] = None,
|
|
509
|
+
on_click: Optional[EventType[()]] = None,
|
|
510
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
511
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
512
|
+
on_focus: Optional[EventType[()]] = None,
|
|
513
|
+
on_mount: Optional[EventType[()]] = None,
|
|
514
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
515
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
516
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
517
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
518
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
519
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
520
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
521
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
522
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
523
523
|
**props,
|
|
524
524
|
) -> "PieChart":
|
|
525
525
|
"""Create a chart component.
|
|
@@ -573,9 +573,9 @@ class RadarChart(ChartBase):
|
|
|
573
573
|
class_name: Optional[Any] = None,
|
|
574
574
|
autofocus: Optional[bool] = None,
|
|
575
575
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
576
|
-
on_click: Optional[EventType[
|
|
577
|
-
on_mouse_enter: Optional[EventType[
|
|
578
|
-
on_mouse_leave: Optional[EventType[
|
|
576
|
+
on_click: Optional[EventType[()]] = None,
|
|
577
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
578
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
579
579
|
**props,
|
|
580
580
|
) -> "RadarChart":
|
|
581
581
|
"""Create a chart component.
|
|
@@ -633,21 +633,21 @@ class RadialBarChart(ChartBase):
|
|
|
633
633
|
class_name: Optional[Any] = None,
|
|
634
634
|
autofocus: Optional[bool] = None,
|
|
635
635
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
636
|
-
on_blur: Optional[EventType[
|
|
637
|
-
on_click: Optional[EventType[
|
|
638
|
-
on_context_menu: Optional[EventType[
|
|
639
|
-
on_double_click: Optional[EventType[
|
|
640
|
-
on_focus: Optional[EventType[
|
|
641
|
-
on_mount: Optional[EventType[
|
|
642
|
-
on_mouse_down: Optional[EventType[
|
|
643
|
-
on_mouse_enter: Optional[EventType[
|
|
644
|
-
on_mouse_leave: Optional[EventType[
|
|
645
|
-
on_mouse_move: Optional[EventType[
|
|
646
|
-
on_mouse_out: Optional[EventType[
|
|
647
|
-
on_mouse_over: Optional[EventType[
|
|
648
|
-
on_mouse_up: Optional[EventType[
|
|
649
|
-
on_scroll: Optional[EventType[
|
|
650
|
-
on_unmount: Optional[EventType[
|
|
636
|
+
on_blur: Optional[EventType[()]] = None,
|
|
637
|
+
on_click: Optional[EventType[()]] = None,
|
|
638
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
639
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
640
|
+
on_focus: Optional[EventType[()]] = None,
|
|
641
|
+
on_mount: Optional[EventType[()]] = None,
|
|
642
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
643
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
644
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
645
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
646
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
647
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
648
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
649
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
650
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
651
651
|
**props,
|
|
652
652
|
) -> "RadialBarChart":
|
|
653
653
|
"""Create a chart component.
|
|
@@ -700,14 +700,14 @@ class ScatterChart(ChartBase):
|
|
|
700
700
|
class_name: Optional[Any] = None,
|
|
701
701
|
autofocus: Optional[bool] = None,
|
|
702
702
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
703
|
-
on_click: Optional[EventType[
|
|
704
|
-
on_mouse_down: Optional[EventType[
|
|
705
|
-
on_mouse_enter: Optional[EventType[
|
|
706
|
-
on_mouse_leave: Optional[EventType[
|
|
707
|
-
on_mouse_move: Optional[EventType[
|
|
708
|
-
on_mouse_out: Optional[EventType[
|
|
709
|
-
on_mouse_over: Optional[EventType[
|
|
710
|
-
on_mouse_up: Optional[EventType[
|
|
703
|
+
on_click: Optional[EventType[()]] = None,
|
|
704
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
705
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
706
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
707
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
708
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
709
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
710
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
711
711
|
**props,
|
|
712
712
|
) -> "ScatterChart":
|
|
713
713
|
"""Create a chart component.
|
|
@@ -751,21 +751,21 @@ class FunnelChart(ChartBase):
|
|
|
751
751
|
class_name: Optional[Any] = None,
|
|
752
752
|
autofocus: Optional[bool] = None,
|
|
753
753
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
754
|
-
on_blur: Optional[EventType[
|
|
755
|
-
on_click: Optional[EventType[
|
|
756
|
-
on_context_menu: Optional[EventType[
|
|
757
|
-
on_double_click: Optional[EventType[
|
|
758
|
-
on_focus: Optional[EventType[
|
|
759
|
-
on_mount: Optional[EventType[
|
|
760
|
-
on_mouse_down: Optional[EventType[
|
|
761
|
-
on_mouse_enter: Optional[EventType[
|
|
762
|
-
on_mouse_leave: Optional[EventType[
|
|
763
|
-
on_mouse_move: Optional[EventType[
|
|
764
|
-
on_mouse_out: Optional[EventType[
|
|
765
|
-
on_mouse_over: Optional[EventType[
|
|
766
|
-
on_mouse_up: Optional[EventType[
|
|
767
|
-
on_scroll: Optional[EventType[
|
|
768
|
-
on_unmount: Optional[EventType[
|
|
754
|
+
on_blur: Optional[EventType[()]] = None,
|
|
755
|
+
on_click: Optional[EventType[()]] = None,
|
|
756
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
757
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
758
|
+
on_focus: Optional[EventType[()]] = None,
|
|
759
|
+
on_mount: Optional[EventType[()]] = None,
|
|
760
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
761
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
762
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
763
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
764
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
765
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
766
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
767
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
768
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
769
769
|
**props,
|
|
770
770
|
) -> "FunnelChart":
|
|
771
771
|
"""Create a chart component.
|
|
@@ -821,23 +821,23 @@ class Treemap(RechartsCharts):
|
|
|
821
821
|
class_name: Optional[Any] = None,
|
|
822
822
|
autofocus: Optional[bool] = None,
|
|
823
823
|
custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
|
|
824
|
-
on_animation_end: Optional[EventType[
|
|
825
|
-
on_animation_start: Optional[EventType[
|
|
826
|
-
on_blur: Optional[EventType[
|
|
827
|
-
on_click: Optional[EventType[
|
|
828
|
-
on_context_menu: Optional[EventType[
|
|
829
|
-
on_double_click: Optional[EventType[
|
|
830
|
-
on_focus: Optional[EventType[
|
|
831
|
-
on_mount: Optional[EventType[
|
|
832
|
-
on_mouse_down: Optional[EventType[
|
|
833
|
-
on_mouse_enter: Optional[EventType[
|
|
834
|
-
on_mouse_leave: Optional[EventType[
|
|
835
|
-
on_mouse_move: Optional[EventType[
|
|
836
|
-
on_mouse_out: Optional[EventType[
|
|
837
|
-
on_mouse_over: Optional[EventType[
|
|
838
|
-
on_mouse_up: Optional[EventType[
|
|
839
|
-
on_scroll: Optional[EventType[
|
|
840
|
-
on_unmount: Optional[EventType[
|
|
824
|
+
on_animation_end: Optional[EventType[()]] = None,
|
|
825
|
+
on_animation_start: Optional[EventType[()]] = None,
|
|
826
|
+
on_blur: Optional[EventType[()]] = None,
|
|
827
|
+
on_click: Optional[EventType[()]] = None,
|
|
828
|
+
on_context_menu: Optional[EventType[()]] = None,
|
|
829
|
+
on_double_click: Optional[EventType[()]] = None,
|
|
830
|
+
on_focus: Optional[EventType[()]] = None,
|
|
831
|
+
on_mount: Optional[EventType[()]] = None,
|
|
832
|
+
on_mouse_down: Optional[EventType[()]] = None,
|
|
833
|
+
on_mouse_enter: Optional[EventType[()]] = None,
|
|
834
|
+
on_mouse_leave: Optional[EventType[()]] = None,
|
|
835
|
+
on_mouse_move: Optional[EventType[()]] = None,
|
|
836
|
+
on_mouse_out: Optional[EventType[()]] = None,
|
|
837
|
+
on_mouse_over: Optional[EventType[()]] = None,
|
|
838
|
+
on_mouse_up: Optional[EventType[()]] = None,
|
|
839
|
+
on_scroll: Optional[EventType[()]] = None,
|
|
840
|
+
on_unmount: Optional[EventType[()]] = None,
|
|
841
841
|
**props,
|
|
842
842
|
) -> "Treemap":
|
|
843
843
|
"""Create a chart component.
|
|
@@ -36,11 +36,11 @@ class ResponsiveContainer(Recharts, MemoizationLeaf):
|
|
|
36
36
|
# The height of chart container. Can be a number or string. Default: "100%"
|
|
37
37
|
height: Var[Union[int, str]]
|
|
38
38
|
|
|
39
|
-
# The minimum width of chart container. Number
|
|
40
|
-
min_width: Var[int]
|
|
39
|
+
# The minimum width of chart container. Number or string.
|
|
40
|
+
min_width: Var[Union[int, str]]
|
|
41
41
|
|
|
42
|
-
# The minimum height of chart container. Number
|
|
43
|
-
min_height: Var[int]
|
|
42
|
+
# The minimum height of chart container. Number or string.
|
|
43
|
+
min_height: Var[Union[int, str]]
|
|
44
44
|
|
|
45
45
|
# If specified a positive number, debounced function will be used to handle the resize event. Default: 0
|
|
46
46
|
debounce: Var[int]
|
|
@@ -242,8 +242,23 @@ class LabelList(Recharts):
|
|
|
242
242
|
stroke: Var[Union[str, Color]] = LiteralVar.create("none")
|
|
243
243
|
|
|
244
244
|
|
|
245
|
+
class Cell(Recharts):
|
|
246
|
+
"""A Cell component in Recharts."""
|
|
247
|
+
|
|
248
|
+
tag = "Cell"
|
|
249
|
+
|
|
250
|
+
alias = "RechartsCell"
|
|
251
|
+
|
|
252
|
+
# The presentation attribute of a rectangle in bar or a sector in pie.
|
|
253
|
+
fill: Var[str | Color]
|
|
254
|
+
|
|
255
|
+
# The presentation attribute of a rectangle in bar or a sector in pie.
|
|
256
|
+
stroke: Var[str | Color]
|
|
257
|
+
|
|
258
|
+
|
|
245
259
|
responsive_container = ResponsiveContainer.create
|
|
246
260
|
legend = Legend.create
|
|
247
261
|
graphing_tooltip = GraphingTooltip.create
|
|
248
262
|
label = Label.create
|
|
249
263
|
label_list = LabelList.create
|
|
264
|
+
cell = Cell.create
|