reflex 0.7.1a4__py3-none-any.whl → 0.7.2__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.

Files changed (227) hide show
  1. reflex/.templates/jinja/web/utils/context.js.jinja2 +8 -8
  2. reflex/.templates/web/components/reflex/radix_themes_color_mode_provider.js +3 -3
  3. reflex/.templates/web/utils/state.js +18 -18
  4. reflex/admin.py +1 -2
  5. reflex/app.py +46 -49
  6. reflex/app_mixins/lifespan.py +2 -2
  7. reflex/app_mixins/middleware.py +1 -2
  8. reflex/assets.py +1 -2
  9. reflex/base.py +2 -2
  10. reflex/compiler/compiler.py +51 -16
  11. reflex/compiler/utils.py +4 -13
  12. reflex/components/base/app_wrap.pyi +7 -7
  13. reflex/components/base/bare.py +3 -3
  14. reflex/components/base/body.pyi +7 -7
  15. reflex/components/base/document.py +1 -3
  16. reflex/components/base/document.pyi +32 -32
  17. reflex/components/base/error_boundary.py +2 -4
  18. reflex/components/base/error_boundary.pyi +11 -13
  19. reflex/components/base/fragment.pyi +7 -7
  20. reflex/components/base/head.pyi +13 -13
  21. reflex/components/base/link.pyi +22 -22
  22. reflex/components/base/meta.py +5 -7
  23. reflex/components/base/meta.pyi +40 -40
  24. reflex/components/base/script.pyi +11 -14
  25. reflex/components/base/strict_mode.pyi +7 -7
  26. reflex/components/component.py +188 -113
  27. reflex/components/core/auto_scroll.py +8 -1
  28. reflex/components/core/auto_scroll.pyi +183 -210
  29. reflex/components/core/banner.py +2 -4
  30. reflex/components/core/banner.pyi +390 -444
  31. reflex/components/core/breakpoints.py +5 -5
  32. reflex/components/core/client_side_routing.pyi +14 -14
  33. reflex/components/core/clipboard.py +4 -4
  34. reflex/components/core/clipboard.pyi +12 -14
  35. reflex/components/core/cond.py +17 -25
  36. reflex/components/core/debounce.py +3 -3
  37. reflex/components/core/debounce.pyi +14 -14
  38. reflex/components/core/foreach.py +7 -2
  39. reflex/components/core/html.py +1 -3
  40. reflex/components/core/html.pyi +184 -213
  41. reflex/components/core/match.py +15 -19
  42. reflex/components/core/sticky.pyi +930 -1078
  43. reflex/components/core/upload.py +4 -4
  44. reflex/components/core/upload.pyi +62 -62
  45. reflex/components/datadisplay/code.py +6 -6
  46. reflex/components/datadisplay/code.pyi +1159 -1165
  47. reflex/components/datadisplay/dataeditor.py +49 -49
  48. reflex/components/datadisplay/dataeditor.pyi +95 -123
  49. reflex/components/datadisplay/logo.py +1 -3
  50. reflex/components/datadisplay/shiki_code_block.py +8 -10
  51. reflex/components/datadisplay/shiki_code_block.pyi +1678 -1720
  52. reflex/components/el/element.pyi +7 -7
  53. reflex/components/el/elements/base.pyi +183 -210
  54. reflex/components/el/elements/forms.py +24 -24
  55. reflex/components/el/elements/forms.pyi +2572 -2934
  56. reflex/components/el/elements/inline.py +4 -4
  57. reflex/components/el/elements/inline.pyi +5191 -5953
  58. reflex/components/el/elements/media.py +47 -47
  59. reflex/components/el/elements/media.pyi +4802 -5500
  60. reflex/components/el/elements/metadata.py +1 -3
  61. reflex/components/el/elements/metadata.pyi +782 -896
  62. reflex/components/el/elements/other.pyi +1278 -1467
  63. reflex/components/el/elements/scripts.pyi +580 -667
  64. reflex/components/el/elements/sectioning.pyi +2761 -3166
  65. reflex/components/el/elements/tables.pyi +1840 -2119
  66. reflex/components/el/elements/typography.pyi +2772 -3179
  67. reflex/components/gridjs/datatable.py +7 -7
  68. reflex/components/gridjs/datatable.pyi +19 -19
  69. reflex/components/lucide/icon.pyi +21 -21
  70. reflex/components/markdown/markdown.py +2 -2
  71. reflex/components/markdown/markdown.pyi +9 -9
  72. reflex/components/moment/moment.py +11 -12
  73. reflex/components/moment/moment.pyi +44 -47
  74. reflex/components/next/base.pyi +7 -7
  75. reflex/components/next/image.py +3 -3
  76. reflex/components/next/image.pyi +19 -21
  77. reflex/components/next/link.pyi +9 -9
  78. reflex/components/next/video.py +1 -3
  79. reflex/components/next/video.pyi +9 -9
  80. reflex/components/plotly/plotly.py +22 -45
  81. reflex/components/plotly/plotly.pyi +164 -164
  82. reflex/components/radix/primitives/accordion.py +14 -14
  83. reflex/components/radix/primitives/accordion.pyi +439 -487
  84. reflex/components/radix/primitives/base.py +1 -3
  85. reflex/components/radix/primitives/base.pyi +15 -15
  86. reflex/components/radix/primitives/drawer.py +3 -3
  87. reflex/components/radix/primitives/drawer.pyi +110 -116
  88. reflex/components/radix/primitives/form.py +1 -1
  89. reflex/components/radix/primitives/form.pyi +668 -752
  90. reflex/components/radix/primitives/progress.py +6 -6
  91. reflex/components/radix/primitives/progress.pyi +225 -243
  92. reflex/components/radix/primitives/slider.py +6 -6
  93. reflex/components/radix/primitives/slider.pyi +52 -55
  94. reflex/components/radix/themes/base.py +3 -6
  95. reflex/components/radix/themes/base.pyi +197 -303
  96. reflex/components/radix/themes/color_mode.py +5 -5
  97. reflex/components/radix/themes/color_mode.pyi +366 -436
  98. reflex/components/radix/themes/components/alert_dialog.pyi +229 -262
  99. reflex/components/radix/themes/components/aspect_ratio.py +1 -3
  100. reflex/components/radix/themes/components/aspect_ratio.pyi +8 -8
  101. reflex/components/radix/themes/components/avatar.pyi +79 -94
  102. reflex/components/radix/themes/components/badge.pyi +252 -295
  103. reflex/components/radix/themes/components/button.pyi +269 -314
  104. reflex/components/radix/themes/components/callout.py +2 -2
  105. reflex/components/radix/themes/components/callout.pyi +1116 -1290
  106. reflex/components/radix/themes/components/card.pyi +194 -229
  107. reflex/components/radix/themes/components/checkbox.pyi +243 -278
  108. reflex/components/radix/themes/components/checkbox_cards.py +3 -7
  109. reflex/components/radix/themes/components/checkbox_cards.pyi +101 -135
  110. reflex/components/radix/themes/components/checkbox_group.py +2 -2
  111. reflex/components/radix/themes/components/checkbox_group.pyi +83 -96
  112. reflex/components/radix/themes/components/context_menu.py +18 -15
  113. reflex/components/radix/themes/components/context_menu.pyi +408 -458
  114. reflex/components/radix/themes/components/data_list.pyi +122 -147
  115. reflex/components/radix/themes/components/dialog.pyi +231 -264
  116. reflex/components/radix/themes/components/dropdown_menu.py +16 -13
  117. reflex/components/radix/themes/components/dropdown_menu.pyi +223 -246
  118. reflex/components/radix/themes/components/hover_card.py +2 -2
  119. reflex/components/radix/themes/components/hover_card.pyi +237 -282
  120. reflex/components/radix/themes/components/icon_button.pyi +269 -314
  121. reflex/components/radix/themes/components/inset.py +8 -8
  122. reflex/components/radix/themes/components/inset.pyi +232 -292
  123. reflex/components/radix/themes/components/popover.py +2 -2
  124. reflex/components/radix/themes/components/popover.pyi +229 -271
  125. reflex/components/radix/themes/components/progress.pyi +80 -96
  126. reflex/components/radix/themes/components/radio.pyi +73 -86
  127. reflex/components/radix/themes/components/radio_cards.py +4 -8
  128. reflex/components/radix/themes/components/radio_cards.pyi +117 -154
  129. reflex/components/radix/themes/components/radio_group.py +3 -3
  130. reflex/components/radix/themes/components/radio_group.pyi +250 -291
  131. reflex/components/radix/themes/components/scroll_area.pyi +14 -20
  132. reflex/components/radix/themes/components/segmented_control.py +6 -6
  133. reflex/components/radix/themes/components/segmented_control.pyi +89 -108
  134. reflex/components/radix/themes/components/select.py +7 -7
  135. reflex/components/radix/themes/components/select.pyi +376 -444
  136. reflex/components/radix/themes/components/separator.pyi +79 -93
  137. reflex/components/radix/themes/components/skeleton.pyi +32 -26
  138. reflex/components/radix/themes/components/slider.py +8 -8
  139. reflex/components/radix/themes/components/slider.pyi +99 -122
  140. reflex/components/radix/themes/components/spinner.pyi +12 -19
  141. reflex/components/radix/themes/components/switch.pyi +84 -99
  142. reflex/components/radix/themes/components/table.py +9 -9
  143. reflex/components/radix/themes/components/table.pyi +1440 -1794
  144. reflex/components/radix/themes/components/tabs.py +4 -4
  145. reflex/components/radix/themes/components/tabs.pyi +120 -132
  146. reflex/components/radix/themes/components/text_area.pyi +281 -331
  147. reflex/components/radix/themes/components/text_field.py +2 -2
  148. reflex/components/radix/themes/components/text_field.pyi +639 -734
  149. reflex/components/radix/themes/components/tooltip.py +6 -6
  150. reflex/components/radix/themes/components/tooltip.pyi +34 -43
  151. reflex/components/radix/themes/layout/base.pyi +85 -182
  152. reflex/components/radix/themes/layout/box.pyi +183 -210
  153. reflex/components/radix/themes/layout/center.pyi +225 -286
  154. reflex/components/radix/themes/layout/container.pyi +191 -224
  155. reflex/components/radix/themes/layout/flex.py +2 -2
  156. reflex/components/radix/themes/layout/flex.pyi +225 -286
  157. reflex/components/radix/themes/layout/grid.py +2 -2
  158. reflex/components/radix/themes/layout/grid.pyi +245 -315
  159. reflex/components/radix/themes/layout/list.py +2 -2
  160. reflex/components/radix/themes/layout/list.pyi +712 -815
  161. reflex/components/radix/themes/layout/section.pyi +187 -221
  162. reflex/components/radix/themes/layout/spacer.pyi +225 -286
  163. reflex/components/radix/themes/layout/stack.pyi +625 -768
  164. reflex/components/radix/themes/typography/blockquote.pyi +257 -299
  165. reflex/components/radix/themes/typography/code.pyi +259 -304
  166. reflex/components/radix/themes/typography/heading.pyi +272 -324
  167. reflex/components/radix/themes/typography/link.pyi +302 -358
  168. reflex/components/radix/themes/typography/text.pyi +1669 -1945
  169. reflex/components/react_player/audio.pyi +20 -22
  170. reflex/components/react_player/react_player.pyi +19 -19
  171. reflex/components/react_player/video.pyi +20 -22
  172. reflex/components/recharts/cartesian.py +100 -97
  173. reflex/components/recharts/cartesian.pyi +891 -1007
  174. reflex/components/recharts/charts.py +42 -42
  175. reflex/components/recharts/charts.pyi +212 -249
  176. reflex/components/recharts/general.py +22 -21
  177. reflex/components/recharts/general.pyi +198 -223
  178. reflex/components/recharts/polar.py +42 -45
  179. reflex/components/recharts/polar.pyi +254 -288
  180. reflex/components/recharts/recharts.pyi +13 -13
  181. reflex/components/sonner/toast.py +20 -20
  182. reflex/components/sonner/toast.pyi +58 -61
  183. reflex/components/suneditor/editor.py +9 -9
  184. reflex/components/suneditor/editor.pyi +78 -83
  185. reflex/components/tags/cond_tag.py +2 -2
  186. reflex/components/tags/iter_tag.py +10 -14
  187. reflex/components/tags/match_tag.py +2 -2
  188. reflex/components/tags/tag.py +10 -10
  189. reflex/config.py +36 -35
  190. reflex/constants/__init__.py +56 -53
  191. reflex/custom_components/custom_components.py +6 -7
  192. reflex/event.py +38 -42
  193. reflex/experimental/client_state.py +2 -4
  194. reflex/experimental/layout.py +2 -2
  195. reflex/experimental/layout.pyi +579 -663
  196. reflex/istate/data.py +4 -5
  197. reflex/middleware/hydrate_middleware.py +2 -2
  198. reflex/middleware/middleware.py +2 -2
  199. reflex/model.py +3 -5
  200. reflex/page.py +2 -2
  201. reflex/reflex.py +9 -10
  202. reflex/state.py +77 -49
  203. reflex/style.py +11 -5
  204. reflex/testing.py +21 -24
  205. reflex/utils/console.py +1 -1
  206. reflex/utils/decorator.py +26 -1
  207. reflex/utils/exec.py +6 -11
  208. reflex/utils/export.py +2 -3
  209. reflex/utils/format.py +4 -4
  210. reflex/utils/imports.py +12 -12
  211. reflex/utils/prerequisites.py +35 -84
  212. reflex/utils/processes.py +5 -5
  213. reflex/utils/pyi_generator.py +33 -22
  214. reflex/utils/serializers.py +60 -15
  215. reflex/utils/types.py +237 -56
  216. reflex/vars/base.py +122 -72
  217. reflex/vars/datetime.py +2 -2
  218. reflex/vars/function.py +52 -55
  219. reflex/vars/number.py +59 -5
  220. reflex/vars/object.py +57 -26
  221. reflex/vars/sequence.py +983 -958
  222. {reflex-0.7.1a4.dist-info → reflex-0.7.2.dist-info}/METADATA +3 -6
  223. reflex-0.7.2.dist-info/RECORD +405 -0
  224. {reflex-0.7.1a4.dist-info → reflex-0.7.2.dist-info}/WHEEL +1 -1
  225. reflex-0.7.1a4.dist-info/RECORD +0 -405
  226. {reflex-0.7.1a4.dist-info → reflex-0.7.2.dist-info}/LICENSE +0 -0
  227. {reflex-0.7.1a4.dist-info → reflex-0.7.2.dist-info}/entry_points.txt +0 -0
@@ -2,7 +2,7 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from typing import Any, Dict, List, Union
5
+ from typing import Any, ClassVar, Sequence, Union
6
6
 
7
7
  from reflex.components.component import MemoizationLeaf
8
8
  from reflex.constants.colors import Color
@@ -31,16 +31,16 @@ class ResponsiveContainer(Recharts, MemoizationLeaf):
31
31
  aspect: Var[int]
32
32
 
33
33
  # The width of chart container. Can be a number or string. Default: "100%"
34
- width: Var[Union[int, str]]
34
+ width: Var[int | str]
35
35
 
36
36
  # The height of chart container. Can be a number or string. Default: "100%"
37
- height: Var[Union[int, str]]
37
+ height: Var[int | str]
38
38
 
39
39
  # The minimum width of chart container. Number or string.
40
- min_width: Var[Union[int, str]]
40
+ min_width: Var[int | str]
41
41
 
42
42
  # The minimum height of chart container. Number or string.
43
- min_height: Var[Union[int, str]]
43
+ min_height: Var[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]
@@ -49,13 +49,14 @@ class ResponsiveContainer(Recharts, MemoizationLeaf):
49
49
  on_resize: EventHandler[no_args_event_spec]
50
50
 
51
51
  # Valid children components
52
- _valid_children: List[str] = [
52
+ _valid_children: ClassVar[list[str]] = [
53
53
  "AreaChart",
54
54
  "BarChart",
55
55
  "LineChart",
56
56
  "PieChart",
57
57
  "RadarChart",
58
58
  "RadialBarChart",
59
+ "ResponsiveContainer",
59
60
  "ScatterChart",
60
61
  "Treemap",
61
62
  "ComposedChart",
@@ -92,7 +93,7 @@ class Legend(Recharts):
92
93
  icon_type: Var[LiteralIconType]
93
94
 
94
95
  # The source data of the content to be displayed in the legend, usually calculated internally. Default: []
95
- payload: Var[List[Dict[str, Any]]]
96
+ payload: Var[Sequence[dict[str, Any]]]
96
97
 
97
98
  # The width of chart container, usually calculated internally.
98
99
  chart_width: Var[int]
@@ -101,7 +102,7 @@ class Legend(Recharts):
101
102
  chart_height: Var[int]
102
103
 
103
104
  # The margin of chart container, usually calculated internally.
104
- margin: Var[Dict[str, Any]]
105
+ margin: Var[dict[str, Any]]
105
106
 
106
107
  # The customized event handler of click on the items in this group
107
108
  on_click: EventHandler[no_args_event_spec]
@@ -145,7 +146,7 @@ class GraphingTooltip(Recharts):
145
146
  filter_null: Var[bool]
146
147
 
147
148
  # If set false, no cursor will be drawn when tooltip is active. Default: {"strokeWidth": 1, "fill": rx.color("gray", 3)}
148
- cursor: Var[Union[Dict[str, Any], bool]] = LiteralVar.create(
149
+ cursor: Var[Union[dict[str, Any], bool]] = LiteralVar.create(
149
150
  {
150
151
  "strokeWidth": 1,
151
152
  "fill": Color("gray", 3),
@@ -153,20 +154,20 @@ class GraphingTooltip(Recharts):
153
154
  )
154
155
 
155
156
  # The box of viewing area, which has the shape of {x: someVal, y: someVal, width: someVal, height: someVal}, usually calculated internally.
156
- view_box: Var[Dict[str, Any]]
157
+ view_box: Var[dict[str, Any]]
157
158
 
158
159
  # The style of default tooltip content item which is a li element. Default: {"color": rx.color("gray", 12)}
159
- item_style: Var[Dict[str, Any]] = LiteralVar.create(
160
+ item_style: Var[dict[str, Any]] = LiteralVar.create(
160
161
  {
161
162
  "color": Color("gray", 12),
162
163
  }
163
164
  )
164
165
 
165
166
  # The style of tooltip wrapper which is a dom element. Default: {}
166
- wrapper_style: Var[Dict[str, Any]]
167
+ wrapper_style: Var[dict[str, Any]]
167
168
 
168
169
  # The style of tooltip content which is a dom element. Default: {"background": rx.color("gray", 1), "borderColor": rx.color("gray", 4), "borderRadius": "8px"}
169
- content_style: Var[Dict[str, Any]] = LiteralVar.create(
170
+ content_style: Var[dict[str, Any]] = LiteralVar.create(
170
171
  {
171
172
  "background": Color("gray", 1),
172
173
  "borderColor": Color("gray", 4),
@@ -175,19 +176,19 @@ class GraphingTooltip(Recharts):
175
176
  )
176
177
 
177
178
  # The style of default tooltip label which is a p element. Default: {"color": rx.color("gray", 11)}
178
- label_style: Var[Dict[str, Any]] = LiteralVar.create({"color": Color("gray", 11)})
179
+ label_style: Var[dict[str, Any]] = LiteralVar.create({"color": Color("gray", 11)})
179
180
 
180
181
  # This option allows the tooltip to extend beyond the viewBox of the chart itself. Default: {"x": False, "y": False}
181
- allow_escape_view_box: Var[Dict[str, bool]]
182
+ allow_escape_view_box: Var[dict[str, bool]]
182
183
 
183
184
  # If set true, the tooltip is displayed. If set false, the tooltip is hidden, usually calculated internally. Default: False
184
185
  active: Var[bool]
185
186
 
186
187
  # If this field is set, the tooltip position will be fixed and will not move anymore.
187
- position: Var[Dict[str, Any]]
188
+ position: Var[dict[str, Any]]
188
189
 
189
190
  # The coordinate of tooltip which is usually calculated internally. Default: {"x": 0, "y": 0}
190
- coordinate: Var[Dict[str, Any]]
191
+ coordinate: Var[dict[str, Any]]
191
192
 
192
193
  # If set false, animation of tooltip will be disabled. Default: True
193
194
  is_animation_active: Var[bool]
@@ -207,7 +208,7 @@ class Label(Recharts):
207
208
  alias = "RechartsLabel"
208
209
 
209
210
  # The box of viewing area, which has the shape of {x: someVal, y: someVal, width: someVal, height: someVal}, usually calculated internally.
210
- view_box: Var[Dict[str, Any]]
211
+ view_box: Var[dict[str, Any]]
211
212
 
212
213
  # The value of label, which can be specified by this props or the children of <Label />
213
214
  value: Var[str]
@@ -227,7 +228,7 @@ class LabelList(Recharts):
227
228
  alias = "RechartsLabelList"
228
229
 
229
230
  # The key of a group of label values in data.
230
- data_key: Var[Union[str, int]]
231
+ data_key: Var[str | int]
231
232
 
232
233
  # The position of each label relative to it view box. "Top" | "left" | "right" | "bottom" | "inside" | "outside" | "insideLeft" | "insideRight" | "insideTop" | "insideBottom" | "insideTopLeft" | "insideBottomLeft" | "insideTopRight" | "insideBottomRight" | "insideStart" | "insideEnd" | "end" | "center"
233
234
  position: Var[LiteralPosition]
@@ -236,10 +237,10 @@ class LabelList(Recharts):
236
237
  offset: Var[int]
237
238
 
238
239
  # The fill color of each label. Default: rx.color("gray", 10)
239
- fill: Var[Union[str, Color]] = LiteralVar.create(Color("gray", 10))
240
+ fill: Var[str | Color] = LiteralVar.create(Color("gray", 10))
240
241
 
241
242
  # The stroke color of each label. Default: "none"
242
- stroke: Var[Union[str, Color]] = LiteralVar.create("none")
243
+ stroke: Var[str | Color] = LiteralVar.create("none")
243
244
 
244
245
 
245
246
  class Cell(Recharts):
@@ -3,7 +3,7 @@
3
3
  # ------------------- DO NOT EDIT ----------------------
4
4
  # This file was generated by `reflex/utils/pyi_generator.py`!
5
5
  # ------------------------------------------------------
6
- from typing import Any, Dict, List, Literal, Optional, Union, overload
6
+ from typing import Any, Literal, Optional, Sequence, overload
7
7
 
8
8
  from reflex.components.component import MemoizationLeaf
9
9
  from reflex.constants.colors import Color
@@ -19,18 +19,18 @@ class ResponsiveContainer(Recharts, MemoizationLeaf):
19
19
  def create( # type: ignore
20
20
  cls,
21
21
  *children,
22
- aspect: Optional[Union[Var[int], int]] = None,
23
- width: Optional[Union[Var[Union[int, str]], int, str]] = None,
24
- height: Optional[Union[Var[Union[int, str]], int, str]] = None,
25
- min_width: Optional[Union[Var[Union[int, str]], int, str]] = None,
26
- min_height: Optional[Union[Var[Union[int, str]], int, str]] = None,
27
- debounce: Optional[Union[Var[int], int]] = None,
28
- style: Optional[Style] = None,
29
- key: Optional[Any] = None,
30
- id: Optional[Any] = None,
31
- class_name: Optional[Any] = None,
32
- autofocus: Optional[bool] = None,
33
- custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
22
+ aspect: Var[int] | int | None = None,
23
+ width: Var[int | str] | int | str | None = None,
24
+ height: Var[int | str] | int | str | None = None,
25
+ min_width: Var[int | str] | int | str | None = None,
26
+ min_height: Var[int | str] | int | str | None = None,
27
+ debounce: Var[int] | int | None = None,
28
+ style: Style | None = None,
29
+ key: Any | None = None,
30
+ id: Any | None = None,
31
+ class_name: Any | None = None,
32
+ autofocus: bool | None = None,
33
+ custom_attrs: dict[str, Var | Any] | None = None,
34
34
  on_blur: Optional[EventType[()]] = None,
35
35
  on_click: Optional[EventType[()]] = None,
36
36
  on_context_menu: Optional[EventType[()]] = None,
@@ -79,69 +79,55 @@ class Legend(Recharts):
79
79
  def create( # type: ignore
80
80
  cls,
81
81
  *children,
82
- width: Optional[Union[Var[int], int]] = None,
83
- height: Optional[Union[Var[int], int]] = None,
84
- layout: Optional[
85
- Union[
86
- Literal["horizontal", "vertical"],
87
- Var[Literal["horizontal", "vertical"]],
82
+ width: Var[int] | int | None = None,
83
+ height: Var[int] | int | None = None,
84
+ layout: Literal["horizontal", "vertical"]
85
+ | Var[Literal["horizontal", "vertical"]]
86
+ | None = None,
87
+ align: Literal["center", "left", "right"]
88
+ | Var[Literal["center", "left", "right"]]
89
+ | None = None,
90
+ vertical_align: Literal["bottom", "middle", "top"]
91
+ | Var[Literal["bottom", "middle", "top"]]
92
+ | None = None,
93
+ icon_size: Var[int] | int | None = None,
94
+ icon_type: Literal[
95
+ "circle",
96
+ "cross",
97
+ "diamond",
98
+ "line",
99
+ "plainline",
100
+ "rect",
101
+ "square",
102
+ "star",
103
+ "triangle",
104
+ "wye",
105
+ ]
106
+ | Var[
107
+ Literal[
108
+ "circle",
109
+ "cross",
110
+ "diamond",
111
+ "line",
112
+ "plainline",
113
+ "rect",
114
+ "square",
115
+ "star",
116
+ "triangle",
117
+ "wye",
88
118
  ]
89
- ] = None,
90
- align: Optional[
91
- Union[
92
- Literal["center", "left", "right"],
93
- Var[Literal["center", "left", "right"]],
94
- ]
95
- ] = None,
96
- vertical_align: Optional[
97
- Union[
98
- Literal["bottom", "middle", "top"],
99
- Var[Literal["bottom", "middle", "top"]],
100
- ]
101
- ] = None,
102
- icon_size: Optional[Union[Var[int], int]] = None,
103
- icon_type: Optional[
104
- Union[
105
- Literal[
106
- "circle",
107
- "cross",
108
- "diamond",
109
- "line",
110
- "plainline",
111
- "rect",
112
- "square",
113
- "star",
114
- "triangle",
115
- "wye",
116
- ],
117
- Var[
118
- Literal[
119
- "circle",
120
- "cross",
121
- "diamond",
122
- "line",
123
- "plainline",
124
- "rect",
125
- "square",
126
- "star",
127
- "triangle",
128
- "wye",
129
- ]
130
- ],
131
- ]
132
- ] = None,
133
- payload: Optional[
134
- Union[List[Dict[str, Any]], Var[List[Dict[str, Any]]]]
135
- ] = None,
136
- chart_width: Optional[Union[Var[int], int]] = None,
137
- chart_height: Optional[Union[Var[int], int]] = None,
138
- margin: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
139
- style: Optional[Style] = None,
140
- key: Optional[Any] = None,
141
- id: Optional[Any] = None,
142
- class_name: Optional[Any] = None,
143
- autofocus: Optional[bool] = None,
144
- custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
119
+ ]
120
+ | None = None,
121
+ payload: Sequence[dict[str, Any]] | Var[Sequence[dict[str, Any]]] | None = None,
122
+ chart_width: Var[int] | int | None = None,
123
+ chart_height: Var[int] | int | None = None,
124
+ margin: Var[dict[str, Any]] | dict[str, Any] | None = None,
125
+ style: Style | None = None,
126
+ key: Any | None = None,
127
+ id: Any | None = None,
128
+ class_name: Any | None = None,
129
+ autofocus: bool | None = None,
130
+ custom_attrs: dict[str, Var | Any] | None = None,
145
131
  on_blur: Optional[EventType[()]] = None,
146
132
  on_click: Optional[EventType[()]] = None,
147
133
  on_context_menu: Optional[EventType[()]] = None,
@@ -201,37 +187,32 @@ class GraphingTooltip(Recharts):
201
187
  def create( # type: ignore
202
188
  cls,
203
189
  *children,
204
- separator: Optional[Union[Var[str], str]] = None,
205
- offset: Optional[Union[Var[int], int]] = None,
206
- filter_null: Optional[Union[Var[bool], bool]] = None,
207
- cursor: Optional[
208
- Union[Dict[str, Any], Var[Union[Dict[str, Any], bool]], bool]
209
- ] = None,
210
- view_box: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
211
- item_style: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
212
- wrapper_style: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
213
- content_style: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
214
- label_style: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
215
- allow_escape_view_box: Optional[
216
- Union[Dict[str, bool], Var[Dict[str, bool]]]
217
- ] = None,
218
- active: Optional[Union[Var[bool], bool]] = None,
219
- position: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
220
- coordinate: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
221
- is_animation_active: Optional[Union[Var[bool], bool]] = None,
222
- animation_duration: Optional[Union[Var[int], int]] = None,
223
- animation_easing: Optional[
224
- Union[
225
- Literal["ease", "ease-in", "ease-in-out", "ease-out", "linear"],
226
- Var[Literal["ease", "ease-in", "ease-in-out", "ease-out", "linear"]],
227
- ]
228
- ] = None,
229
- style: Optional[Style] = None,
230
- key: Optional[Any] = None,
231
- id: Optional[Any] = None,
232
- class_name: Optional[Any] = None,
233
- autofocus: Optional[bool] = None,
234
- custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
190
+ separator: Var[str] | str | None = None,
191
+ offset: Var[int] | int | None = None,
192
+ filter_null: Var[bool] | bool | None = None,
193
+ cursor: Var[bool | dict[str, Any]] | bool | dict[str, Any] | None = None,
194
+ view_box: Var[dict[str, Any]] | dict[str, Any] | None = None,
195
+ item_style: Var[dict[str, Any]] | dict[str, Any] | None = None,
196
+ wrapper_style: Var[dict[str, Any]] | dict[str, Any] | None = None,
197
+ content_style: Var[dict[str, Any]] | dict[str, Any] | None = None,
198
+ label_style: Var[dict[str, Any]] | dict[str, Any] | None = None,
199
+ allow_escape_view_box: Var[dict[str, bool]] | dict[str, bool] | None = None,
200
+ active: Var[bool] | bool | None = None,
201
+ position: Var[dict[str, Any]] | dict[str, Any] | None = None,
202
+ coordinate: Var[dict[str, Any]] | dict[str, Any] | None = None,
203
+ is_animation_active: Var[bool] | bool | None = None,
204
+ animation_duration: Var[int] | int | None = None,
205
+ animation_easing: Literal[
206
+ "ease", "ease-in", "ease-in-out", "ease-out", "linear"
207
+ ]
208
+ | Var[Literal["ease", "ease-in", "ease-in-out", "ease-out", "linear"]]
209
+ | None = None,
210
+ style: Style | None = None,
211
+ key: Any | None = None,
212
+ id: Any | None = None,
213
+ class_name: Any | None = None,
214
+ autofocus: bool | None = None,
215
+ custom_attrs: dict[str, Var | Any] | None = None,
235
216
  on_blur: Optional[EventType[()]] = None,
236
217
  on_click: Optional[EventType[()]] = None,
237
218
  on_context_menu: Optional[EventType[()]] = None,
@@ -288,61 +269,58 @@ class Label(Recharts):
288
269
  def create( # type: ignore
289
270
  cls,
290
271
  *children,
291
- view_box: Optional[Union[Dict[str, Any], Var[Dict[str, Any]]]] = None,
292
- value: Optional[Union[Var[str], str]] = None,
293
- offset: Optional[Union[Var[int], int]] = None,
294
- position: Optional[
295
- Union[
296
- Literal[
297
- "bottom",
298
- "center",
299
- "end",
300
- "inside",
301
- "insideBottom",
302
- "insideBottomLeft",
303
- "insideBottomRight",
304
- "insideEnd",
305
- "insideLeft",
306
- "insideRight",
307
- "insideStart",
308
- "insideTop",
309
- "insideTopLeft",
310
- "insideTopRight",
311
- "left",
312
- "outside",
313
- "right",
314
- "top",
315
- ],
316
- Var[
317
- Literal[
318
- "bottom",
319
- "center",
320
- "end",
321
- "inside",
322
- "insideBottom",
323
- "insideBottomLeft",
324
- "insideBottomRight",
325
- "insideEnd",
326
- "insideLeft",
327
- "insideRight",
328
- "insideStart",
329
- "insideTop",
330
- "insideTopLeft",
331
- "insideTopRight",
332
- "left",
333
- "outside",
334
- "right",
335
- "top",
336
- ]
337
- ],
272
+ view_box: Var[dict[str, Any]] | dict[str, Any] | None = None,
273
+ value: Var[str] | str | None = None,
274
+ offset: Var[int] | int | None = None,
275
+ position: Literal[
276
+ "bottom",
277
+ "center",
278
+ "end",
279
+ "inside",
280
+ "insideBottom",
281
+ "insideBottomLeft",
282
+ "insideBottomRight",
283
+ "insideEnd",
284
+ "insideLeft",
285
+ "insideRight",
286
+ "insideStart",
287
+ "insideTop",
288
+ "insideTopLeft",
289
+ "insideTopRight",
290
+ "left",
291
+ "outside",
292
+ "right",
293
+ "top",
294
+ ]
295
+ | Var[
296
+ Literal[
297
+ "bottom",
298
+ "center",
299
+ "end",
300
+ "inside",
301
+ "insideBottom",
302
+ "insideBottomLeft",
303
+ "insideBottomRight",
304
+ "insideEnd",
305
+ "insideLeft",
306
+ "insideRight",
307
+ "insideStart",
308
+ "insideTop",
309
+ "insideTopLeft",
310
+ "insideTopRight",
311
+ "left",
312
+ "outside",
313
+ "right",
314
+ "top",
338
315
  ]
339
- ] = None,
340
- style: Optional[Style] = None,
341
- key: Optional[Any] = None,
342
- id: Optional[Any] = None,
343
- class_name: Optional[Any] = None,
344
- autofocus: Optional[bool] = None,
345
- custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
316
+ ]
317
+ | None = None,
318
+ style: Style | None = None,
319
+ key: Any | None = None,
320
+ id: Any | None = None,
321
+ class_name: Any | None = None,
322
+ autofocus: bool | None = None,
323
+ custom_attrs: dict[str, Var | Any] | None = None,
346
324
  on_blur: Optional[EventType[()]] = None,
347
325
  on_click: Optional[EventType[()]] = None,
348
326
  on_context_menu: Optional[EventType[()]] = None,
@@ -387,62 +365,59 @@ class LabelList(Recharts):
387
365
  def create( # type: ignore
388
366
  cls,
389
367
  *children,
390
- data_key: Optional[Union[Var[Union[int, str]], int, str]] = None,
391
- position: Optional[
392
- Union[
393
- Literal[
394
- "bottom",
395
- "center",
396
- "end",
397
- "inside",
398
- "insideBottom",
399
- "insideBottomLeft",
400
- "insideBottomRight",
401
- "insideEnd",
402
- "insideLeft",
403
- "insideRight",
404
- "insideStart",
405
- "insideTop",
406
- "insideTopLeft",
407
- "insideTopRight",
408
- "left",
409
- "outside",
410
- "right",
411
- "top",
412
- ],
413
- Var[
414
- Literal[
415
- "bottom",
416
- "center",
417
- "end",
418
- "inside",
419
- "insideBottom",
420
- "insideBottomLeft",
421
- "insideBottomRight",
422
- "insideEnd",
423
- "insideLeft",
424
- "insideRight",
425
- "insideStart",
426
- "insideTop",
427
- "insideTopLeft",
428
- "insideTopRight",
429
- "left",
430
- "outside",
431
- "right",
432
- "top",
433
- ]
434
- ],
368
+ data_key: Var[int | str] | int | str | None = None,
369
+ position: Literal[
370
+ "bottom",
371
+ "center",
372
+ "end",
373
+ "inside",
374
+ "insideBottom",
375
+ "insideBottomLeft",
376
+ "insideBottomRight",
377
+ "insideEnd",
378
+ "insideLeft",
379
+ "insideRight",
380
+ "insideStart",
381
+ "insideTop",
382
+ "insideTopLeft",
383
+ "insideTopRight",
384
+ "left",
385
+ "outside",
386
+ "right",
387
+ "top",
388
+ ]
389
+ | Var[
390
+ Literal[
391
+ "bottom",
392
+ "center",
393
+ "end",
394
+ "inside",
395
+ "insideBottom",
396
+ "insideBottomLeft",
397
+ "insideBottomRight",
398
+ "insideEnd",
399
+ "insideLeft",
400
+ "insideRight",
401
+ "insideStart",
402
+ "insideTop",
403
+ "insideTopLeft",
404
+ "insideTopRight",
405
+ "left",
406
+ "outside",
407
+ "right",
408
+ "top",
435
409
  ]
436
- ] = None,
437
- offset: Optional[Union[Var[int], int]] = None,
438
- fill: Optional[Union[Color, Var[Union[Color, str]], str]] = None,
439
- stroke: Optional[Union[Color, Var[Union[Color, str]], str]] = None,
440
- style: Optional[Style] = None,
441
- key: Optional[Any] = None,
442
- id: Optional[Any] = None,
443
- class_name: Optional[Any] = None,
444
- autofocus: Optional[bool] = None,
445
- custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
410
+ ]
411
+ | None = None,
412
+ offset: Var[int] | int | None = None,
413
+ fill: Color | Var[Color | str] | str | None = None,
414
+ stroke: Color | Var[Color | str] | str | None = None,
415
+ style: Style | None = None,
416
+ key: Any | None = None,
417
+ id: Any | None = None,
418
+ class_name: Any | None = None,
419
+ autofocus: bool | None = None,
420
+ custom_attrs: dict[str, Var | Any] | None = None,
446
421
  on_blur: Optional[EventType[()]] = None,
447
422
  on_click: Optional[EventType[()]] = None,
448
423
  on_context_menu: Optional[EventType[()]] = None,
@@ -488,14 +463,14 @@ class Cell(Recharts):
488
463
  def create( # type: ignore
489
464
  cls,
490
465
  *children,
491
- fill: Optional[Union[Color, Var[Union[Color, str]], str]] = None,
492
- stroke: Optional[Union[Color, Var[Union[Color, str]], str]] = None,
493
- style: Optional[Style] = None,
494
- key: Optional[Any] = None,
495
- id: Optional[Any] = None,
496
- class_name: Optional[Any] = None,
497
- autofocus: Optional[bool] = None,
498
- custom_attrs: Optional[Dict[str, Union[Var, Any]]] = None,
466
+ fill: Color | Var[Color | str] | str | None = None,
467
+ stroke: Color | Var[Color | str] | str | None = None,
468
+ style: Style | None = None,
469
+ key: Any | None = None,
470
+ id: Any | None = None,
471
+ class_name: Any | None = None,
472
+ autofocus: bool | None = None,
473
+ custom_attrs: dict[str, Var | Any] | None = None,
499
474
  on_blur: Optional[EventType[()]] = None,
500
475
  on_click: Optional[EventType[()]] = None,
501
476
  on_context_menu: Optional[EventType[()]] = None,