reflex 0.5.4a2__py3-none-any.whl → 0.5.5__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 (261) hide show
  1. reflex/.templates/apps/demo/code/demo.py +1 -0
  2. reflex/.templates/apps/demo/code/pages/__init__.py +1 -0
  3. reflex/.templates/apps/demo/code/pages/datatable.py +1 -0
  4. reflex/.templates/apps/demo/code/pages/forms.py +1 -0
  5. reflex/.templates/apps/demo/code/pages/graphing.py +1 -0
  6. reflex/.templates/apps/demo/code/pages/home.py +1 -0
  7. reflex/.templates/apps/demo/code/styles.py +1 -0
  8. reflex/.templates/apps/demo/code/webui/components/loading_icon.py +1 -8
  9. reflex/.templates/web/components/reflex/chakra_color_mode_provider.js +27 -12
  10. reflex/.templates/web/components/reflex/radix_themes_color_mode_provider.js +19 -5
  11. reflex/.templates/web/utils/state.js +73 -7
  12. reflex/__init__.py +3 -0
  13. reflex/__init__.pyi +3 -0
  14. reflex/admin.py +1 -0
  15. reflex/app.py +8 -6
  16. reflex/app_module_for_backend.py +2 -1
  17. reflex/base.py +4 -4
  18. reflex/compiler/compiler.py +4 -3
  19. reflex/compiler/templates.py +2 -0
  20. reflex/compiler/utils.py +58 -35
  21. reflex/components/__init__.py +1 -0
  22. reflex/components/base/__init__.py +1 -0
  23. reflex/components/base/app_wrap.py +1 -0
  24. reflex/components/base/fragment.py +1 -0
  25. reflex/components/base/link.py +0 -1
  26. reflex/components/base/script.py +11 -15
  27. reflex/components/base/script.pyi +1 -2
  28. reflex/components/chakra/base.py +15 -13
  29. reflex/components/chakra/base.pyi +3 -1
  30. reflex/components/chakra/datadisplay/code.py +1 -0
  31. reflex/components/chakra/datadisplay/divider.py +1 -0
  32. reflex/components/chakra/datadisplay/table.py +1 -0
  33. reflex/components/chakra/datadisplay/table.pyi +3 -0
  34. reflex/components/chakra/datadisplay/tag.py +1 -0
  35. reflex/components/chakra/disclosure/transition.py +1 -0
  36. reflex/components/chakra/feedback/circularprogress.py +1 -0
  37. reflex/components/chakra/forms/button.py +1 -0
  38. reflex/components/chakra/forms/checkbox.py +4 -13
  39. reflex/components/chakra/forms/checkbox.pyi +1 -3
  40. reflex/components/chakra/forms/colormodeswitch.py +1 -0
  41. reflex/components/chakra/forms/editable.py +13 -16
  42. reflex/components/chakra/forms/editable.pyi +1 -3
  43. reflex/components/chakra/forms/form.py +1 -0
  44. reflex/components/chakra/forms/input.py +22 -21
  45. reflex/components/chakra/forms/input.pyi +4 -4
  46. reflex/components/chakra/forms/multiselect.py +1 -0
  47. reflex/components/chakra/forms/numberinput.py +3 -12
  48. reflex/components/chakra/forms/numberinput.pyi +1 -3
  49. reflex/components/chakra/forms/pininput.py +8 -14
  50. reflex/components/chakra/forms/pininput.pyi +2 -3
  51. reflex/components/chakra/forms/radio.py +4 -13
  52. reflex/components/chakra/forms/radio.pyi +2 -3
  53. reflex/components/chakra/forms/rangeslider.py +10 -13
  54. reflex/components/chakra/forms/rangeslider.pyi +2 -3
  55. reflex/components/chakra/forms/select.py +4 -12
  56. reflex/components/chakra/forms/select.pyi +2 -3
  57. reflex/components/chakra/forms/slider.py +10 -13
  58. reflex/components/chakra/forms/slider.pyi +2 -3
  59. reflex/components/chakra/forms/switch.py +4 -13
  60. reflex/components/chakra/forms/switch.pyi +1 -3
  61. reflex/components/chakra/forms/textarea.py +16 -17
  62. reflex/components/chakra/forms/textarea.pyi +1 -3
  63. reflex/components/chakra/media/avatar.py +4 -12
  64. reflex/components/chakra/media/avatar.pyi +1 -2
  65. reflex/components/chakra/media/icon.py +1 -0
  66. reflex/components/chakra/media/image.py +7 -11
  67. reflex/components/chakra/media/image.pyi +2 -2
  68. reflex/components/chakra/navigation/link.py +8 -4
  69. reflex/components/chakra/navigation/link.pyi +2 -1
  70. reflex/components/chakra/overlay/alertdialog.py +12 -14
  71. reflex/components/chakra/overlay/alertdialog.pyi +1 -2
  72. reflex/components/chakra/overlay/drawer.py +12 -14
  73. reflex/components/chakra/overlay/drawer.pyi +1 -2
  74. reflex/components/chakra/overlay/menu.py +7 -11
  75. reflex/components/chakra/overlay/menu.pyi +2 -2
  76. reflex/components/chakra/overlay/modal.py +13 -13
  77. reflex/components/chakra/overlay/modal.pyi +2 -2
  78. reflex/components/chakra/overlay/popover.py +6 -12
  79. reflex/components/chakra/overlay/popover.pyi +1 -2
  80. reflex/components/chakra/overlay/tooltip.py +7 -13
  81. reflex/components/chakra/overlay/tooltip.pyi +1 -2
  82. reflex/components/chakra/typography/heading.py +0 -1
  83. reflex/components/chakra/typography/span.py +1 -0
  84. reflex/components/chakra/typography/text.py +1 -0
  85. reflex/components/component.py +70 -43
  86. reflex/components/core/__init__.py +1 -0
  87. reflex/components/core/banner.py +27 -24
  88. reflex/components/core/banner.pyi +6 -2
  89. reflex/components/core/client_side_routing.py +1 -0
  90. reflex/components/core/cond.py +19 -17
  91. reflex/components/core/debounce.py +4 -11
  92. reflex/components/core/debounce.pyi +1 -1
  93. reflex/components/core/foreach.py +1 -0
  94. reflex/components/core/html.py +1 -0
  95. reflex/components/core/match.py +9 -6
  96. reflex/components/core/upload.py +26 -25
  97. reflex/components/core/upload.pyi +3 -4
  98. reflex/components/datadisplay/__init__.py +1 -0
  99. reflex/components/datadisplay/code.py +27 -23
  100. reflex/components/datadisplay/code.pyi +4 -2
  101. reflex/components/datadisplay/dataeditor.py +73 -80
  102. reflex/components/datadisplay/dataeditor.pyi +52 -4
  103. reflex/components/datadisplay/logo.py +1 -0
  104. reflex/components/el/__init__.py +1 -0
  105. reflex/components/el/__init__.pyi +8 -0
  106. reflex/components/el/element.py +0 -1
  107. reflex/components/el/elements/__init__.py +5 -0
  108. reflex/components/el/elements/__init__.pyi +12 -1
  109. reflex/components/el/elements/base.py +1 -0
  110. reflex/components/el/elements/forms.py +44 -61
  111. reflex/components/el/elements/forms.pyi +4 -6
  112. reflex/components/el/elements/inline.py +1 -0
  113. reflex/components/el/elements/media.py +53 -0
  114. reflex/components/el/elements/media.pyi +428 -0
  115. reflex/components/el/elements/metadata.py +11 -0
  116. reflex/components/el/elements/metadata.pyi +80 -0
  117. reflex/components/el/elements/other.py +1 -0
  118. reflex/components/el/elements/scripts.py +1 -0
  119. reflex/components/el/elements/tables.py +1 -0
  120. reflex/components/el/elements/typography.py +1 -0
  121. reflex/components/gridjs/datatable.py +9 -6
  122. reflex/components/gridjs/datatable.pyi +4 -1
  123. reflex/components/markdown/markdown.py +36 -41
  124. reflex/components/markdown/markdown.pyi +4 -3
  125. reflex/components/media/icon.py +1 -0
  126. reflex/components/moment/moment.py +11 -17
  127. reflex/components/moment/moment.pyi +4 -3
  128. reflex/components/next/base.py +1 -0
  129. reflex/components/next/image.py +6 -11
  130. reflex/components/next/image.pyi +2 -2
  131. reflex/components/plotly/plotly.py +1 -0
  132. reflex/components/props.py +1 -0
  133. reflex/components/radix/__init__.py +1 -0
  134. reflex/components/radix/primitives/__init__.py +1 -0
  135. reflex/components/radix/primitives/accordion.py +7 -15
  136. reflex/components/radix/primitives/accordion.pyi +7 -4
  137. reflex/components/radix/primitives/base.py +1 -0
  138. reflex/components/radix/primitives/drawer.py +17 -27
  139. reflex/components/radix/primitives/drawer.pyi +2 -4
  140. reflex/components/radix/primitives/form.py +4 -12
  141. reflex/components/radix/primitives/form.pyi +2 -3
  142. reflex/components/radix/primitives/slider.py +6 -11
  143. reflex/components/radix/primitives/slider.pyi +2 -2
  144. reflex/components/radix/themes/__init__.py +1 -0
  145. reflex/components/radix/themes/base.py +3 -3
  146. reflex/components/radix/themes/base.pyi +3 -2
  147. reflex/components/radix/themes/color_mode.py +31 -2
  148. reflex/components/radix/themes/color_mode.pyi +10 -1
  149. reflex/components/radix/themes/components/__init__.py +1 -0
  150. reflex/components/radix/themes/components/alert_dialog.py +13 -24
  151. reflex/components/radix/themes/components/alert_dialog.pyi +2 -4
  152. reflex/components/radix/themes/components/aspect_ratio.py +1 -0
  153. reflex/components/radix/themes/components/card.py +1 -0
  154. reflex/components/radix/themes/components/checkbox.py +6 -22
  155. reflex/components/radix/themes/components/checkbox.pyi +2 -4
  156. reflex/components/radix/themes/components/checkbox_group.py +15 -3
  157. reflex/components/radix/themes/components/checkbox_group.pyi +10 -2
  158. reflex/components/radix/themes/components/context_menu.py +29 -38
  159. reflex/components/radix/themes/components/context_menu.pyi +2 -5
  160. reflex/components/radix/themes/components/dialog.py +18 -26
  161. reflex/components/radix/themes/components/dialog.pyi +2 -4
  162. reflex/components/radix/themes/components/dropdown_menu.py +32 -57
  163. reflex/components/radix/themes/components/dropdown_menu.pyi +2 -7
  164. reflex/components/radix/themes/components/hover_card.py +5 -12
  165. reflex/components/radix/themes/components/hover_card.pyi +2 -3
  166. reflex/components/radix/themes/components/icon_button.py +1 -0
  167. reflex/components/radix/themes/components/icon_button.pyi +1 -0
  168. reflex/components/radix/themes/components/inset.py +1 -0
  169. reflex/components/radix/themes/components/popover.py +22 -27
  170. reflex/components/radix/themes/components/popover.pyi +2 -4
  171. reflex/components/radix/themes/components/radio_group.py +25 -17
  172. reflex/components/radix/themes/components/radio_group.pyi +2 -3
  173. reflex/components/radix/themes/components/scroll_area.py +1 -0
  174. reflex/components/radix/themes/components/segmented_control.py +18 -5
  175. reflex/components/radix/themes/components/segmented_control.pyi +16 -7
  176. reflex/components/radix/themes/components/select.py +13 -23
  177. reflex/components/radix/themes/components/select.pyi +1 -4
  178. reflex/components/radix/themes/components/separator.py +1 -0
  179. reflex/components/radix/themes/components/slider.py +7 -12
  180. reflex/components/radix/themes/components/slider.pyi +2 -3
  181. reflex/components/radix/themes/components/switch.py +5 -12
  182. reflex/components/radix/themes/components/switch.pyi +2 -3
  183. reflex/components/radix/themes/components/table.py +1 -0
  184. reflex/components/radix/themes/components/tabs.py +4 -11
  185. reflex/components/radix/themes/components/tabs.pyi +2 -2
  186. reflex/components/radix/themes/components/text_area.py +19 -18
  187. reflex/components/radix/themes/components/text_area.pyi +2 -3
  188. reflex/components/radix/themes/components/text_field.py +19 -18
  189. reflex/components/radix/themes/components/text_field.pyi +3 -3
  190. reflex/components/radix/themes/components/tooltip.py +10 -13
  191. reflex/components/radix/themes/components/tooltip.pyi +2 -3
  192. reflex/components/radix/themes/layout/__init__.py +1 -0
  193. reflex/components/radix/themes/layout/box.py +1 -0
  194. reflex/components/radix/themes/layout/container.py +1 -0
  195. reflex/components/radix/themes/layout/list.py +1 -0
  196. reflex/components/radix/themes/layout/list.pyi +1 -0
  197. reflex/components/radix/themes/layout/section.py +1 -0
  198. reflex/components/radix/themes/typography/__init__.py +1 -0
  199. reflex/components/radix/themes/typography/base.py +1 -0
  200. reflex/components/radix/themes/typography/blockquote.py +1 -0
  201. reflex/components/radix/themes/typography/code.py +1 -0
  202. reflex/components/radix/themes/typography/heading.py +1 -0
  203. reflex/components/radix/themes/typography/link.py +8 -3
  204. reflex/components/radix/themes/typography/link.pyi +2 -1
  205. reflex/components/react_player/audio.py +1 -0
  206. reflex/components/react_player/audio.pyi +48 -0
  207. reflex/components/react_player/react_player.py +49 -0
  208. reflex/components/react_player/react_player.pyi +49 -0
  209. reflex/components/react_player/video.py +1 -0
  210. reflex/components/react_player/video.pyi +48 -0
  211. reflex/components/recharts/__init__.py +1 -0
  212. reflex/components/recharts/cartesian.py +264 -74
  213. reflex/components/recharts/cartesian.pyi +573 -58
  214. reflex/components/recharts/charts.py +68 -78
  215. reflex/components/recharts/charts.pyi +373 -156
  216. reflex/components/recharts/general.py +52 -20
  217. reflex/components/recharts/general.pyi +52 -6
  218. reflex/components/recharts/polar.py +30 -18
  219. reflex/components/recharts/polar.pyi +66 -5
  220. reflex/components/recharts/recharts.py +5 -3
  221. reflex/components/recharts/recharts.pyi +2 -1
  222. reflex/components/sonner/toast.py +2 -2
  223. reflex/components/sonner/toast.pyi +1 -1
  224. reflex/components/suneditor/editor.py +39 -26
  225. reflex/components/suneditor/editor.pyi +4 -4
  226. reflex/components/tags/iter_tag.py +1 -0
  227. reflex/constants/__init__.py +3 -2
  228. reflex/constants/base.py +20 -21
  229. reflex/constants/compiler.py +3 -1
  230. reflex/constants/config.py +1 -0
  231. reflex/constants/event.py +1 -0
  232. reflex/constants/installer.py +3 -2
  233. reflex/constants/style.py +2 -8
  234. reflex/event.py +36 -6
  235. reflex/experimental/assets.py +1 -0
  236. reflex/experimental/client_state.py +9 -3
  237. reflex/experimental/hooks.py +1 -0
  238. reflex/experimental/misc.py +12 -3
  239. reflex/middleware/hydrate_middleware.py +1 -0
  240. reflex/middleware/middleware.py +1 -0
  241. reflex/state.py +38 -1
  242. reflex/style.py +67 -20
  243. reflex/testing.py +6 -2
  244. reflex/utils/build.py +76 -72
  245. reflex/utils/compat.py +5 -0
  246. reflex/utils/exec.py +17 -9
  247. reflex/utils/export.py +13 -9
  248. reflex/utils/imports.py +34 -5
  249. reflex/utils/lazy_loader.py +1 -0
  250. reflex/utils/path_ops.py +39 -33
  251. reflex/utils/prerequisites.py +38 -29
  252. reflex/utils/processes.py +1 -1
  253. reflex/utils/serializers.py +3 -6
  254. reflex/utils/watch.py +3 -1
  255. reflex/vars.py +26 -10
  256. reflex/vars.pyi +3 -3
  257. {reflex-0.5.4a2.dist-info → reflex-0.5.5.dist-info}/METADATA +3 -3
  258. {reflex-0.5.4a2.dist-info → reflex-0.5.5.dist-info}/RECORD +261 -261
  259. {reflex-0.5.4a2.dist-info → reflex-0.5.5.dist-info}/LICENSE +0 -0
  260. {reflex-0.5.4a2.dist-info → reflex-0.5.5.dist-info}/WHEEL +0 -0
  261. {reflex-0.5.4a2.dist-info → reflex-0.5.5.dist-info}/entry_points.txt +0 -0
@@ -9,6 +9,7 @@ from reflex.event import EventChain, EventHandler, EventSpec
9
9
  from reflex.style import Style
10
10
  from typing import Any, Union
11
11
  from reflex import Component
12
+ from reflex.constants.colors import Color
12
13
  from reflex.vars import Var as Var
13
14
  from .base import BaseHTML
14
15
 
@@ -1953,6 +1954,430 @@ class Svg(BaseHTML):
1953
1954
  """
1954
1955
  ...
1955
1956
 
1957
+ class Defs(BaseHTML):
1958
+ @overload
1959
+ @classmethod
1960
+ def create( # type: ignore
1961
+ cls,
1962
+ *children,
1963
+ access_key: Optional[
1964
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1965
+ ] = None,
1966
+ auto_capitalize: Optional[
1967
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1968
+ ] = None,
1969
+ content_editable: Optional[
1970
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1971
+ ] = None,
1972
+ context_menu: Optional[
1973
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1974
+ ] = None,
1975
+ dir: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
1976
+ draggable: Optional[
1977
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1978
+ ] = None,
1979
+ enter_key_hint: Optional[
1980
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1981
+ ] = None,
1982
+ hidden: Optional[
1983
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1984
+ ] = None,
1985
+ input_mode: Optional[
1986
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1987
+ ] = None,
1988
+ item_prop: Optional[
1989
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1990
+ ] = None,
1991
+ lang: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
1992
+ role: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
1993
+ slot: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
1994
+ spell_check: Optional[
1995
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1996
+ ] = None,
1997
+ tab_index: Optional[
1998
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
1999
+ ] = None,
2000
+ title: Optional[
2001
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2002
+ ] = None,
2003
+ style: Optional[Style] = None,
2004
+ key: Optional[Any] = None,
2005
+ id: Optional[Any] = None,
2006
+ class_name: Optional[Any] = None,
2007
+ autofocus: Optional[bool] = None,
2008
+ custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
2009
+ on_blur: Optional[
2010
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2011
+ ] = None,
2012
+ on_click: Optional[
2013
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2014
+ ] = None,
2015
+ on_context_menu: Optional[
2016
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2017
+ ] = None,
2018
+ on_double_click: Optional[
2019
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2020
+ ] = None,
2021
+ on_focus: Optional[
2022
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2023
+ ] = None,
2024
+ on_mount: Optional[
2025
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2026
+ ] = None,
2027
+ on_mouse_down: Optional[
2028
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2029
+ ] = None,
2030
+ on_mouse_enter: Optional[
2031
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2032
+ ] = None,
2033
+ on_mouse_leave: Optional[
2034
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2035
+ ] = None,
2036
+ on_mouse_move: Optional[
2037
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2038
+ ] = None,
2039
+ on_mouse_out: Optional[
2040
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2041
+ ] = None,
2042
+ on_mouse_over: Optional[
2043
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2044
+ ] = None,
2045
+ on_mouse_up: Optional[
2046
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2047
+ ] = None,
2048
+ on_scroll: Optional[
2049
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2050
+ ] = None,
2051
+ on_unmount: Optional[
2052
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2053
+ ] = None,
2054
+ **props
2055
+ ) -> "Defs":
2056
+ """Create the component.
2057
+
2058
+ Args:
2059
+ *children: The children of the component.
2060
+ access_key: Provides a hint for generating a keyboard shortcut for the current element.
2061
+ auto_capitalize: Controls whether and how text input is automatically capitalized as it is entered/edited by the user.
2062
+ content_editable: Indicates whether the element's content is editable.
2063
+ context_menu: Defines the ID of a <menu> element which will serve as the element's context menu.
2064
+ dir: Defines the text direction. Allowed values are ltr (Left-To-Right) or rtl (Right-To-Left)
2065
+ draggable: Defines whether the element can be dragged.
2066
+ enter_key_hint: Hints what media types the media element is able to play.
2067
+ hidden: Defines whether the element is hidden.
2068
+ input_mode: Defines the type of the element.
2069
+ item_prop: Defines the name of the element for metadata purposes.
2070
+ lang: Defines the language used in the element.
2071
+ role: Defines the role of the element.
2072
+ slot: Assigns a slot in a shadow DOM shadow tree to an element.
2073
+ spell_check: Defines whether the element may be checked for spelling errors.
2074
+ tab_index: Defines the position of the current element in the tabbing order.
2075
+ title: Defines a tooltip for the element.
2076
+ style: The style of the component.
2077
+ key: A unique key for the component.
2078
+ id: The id for the component.
2079
+ class_name: The class name for the component.
2080
+ autofocus: Whether the component should take the focus once the page is loaded
2081
+ custom_attrs: custom attribute
2082
+ **props: The props of the component.
2083
+
2084
+ Returns:
2085
+ The component.
2086
+ """
2087
+ ...
2088
+
2089
+ class Lineargradient(BaseHTML):
2090
+ @overload
2091
+ @classmethod
2092
+ def create( # type: ignore
2093
+ cls,
2094
+ *children,
2095
+ gradient_units: Optional[Union[Var[Union[str, bool]], Union[str, bool]]] = None,
2096
+ gradient_transform: Optional[
2097
+ Union[Var[Union[str, bool]], Union[str, bool]]
2098
+ ] = None,
2099
+ spread_method: Optional[Union[Var[Union[str, bool]], Union[str, bool]]] = None,
2100
+ x1: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2101
+ x2: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2102
+ y1: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2103
+ y2: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2104
+ access_key: Optional[
2105
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2106
+ ] = None,
2107
+ auto_capitalize: Optional[
2108
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2109
+ ] = None,
2110
+ content_editable: Optional[
2111
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2112
+ ] = None,
2113
+ context_menu: Optional[
2114
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2115
+ ] = None,
2116
+ dir: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2117
+ draggable: Optional[
2118
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2119
+ ] = None,
2120
+ enter_key_hint: Optional[
2121
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2122
+ ] = None,
2123
+ hidden: Optional[
2124
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2125
+ ] = None,
2126
+ input_mode: Optional[
2127
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2128
+ ] = None,
2129
+ item_prop: Optional[
2130
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2131
+ ] = None,
2132
+ lang: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2133
+ role: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2134
+ slot: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2135
+ spell_check: Optional[
2136
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2137
+ ] = None,
2138
+ tab_index: Optional[
2139
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2140
+ ] = None,
2141
+ title: Optional[
2142
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2143
+ ] = None,
2144
+ style: Optional[Style] = None,
2145
+ key: Optional[Any] = None,
2146
+ id: Optional[Any] = None,
2147
+ class_name: Optional[Any] = None,
2148
+ autofocus: Optional[bool] = None,
2149
+ custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
2150
+ on_blur: Optional[
2151
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2152
+ ] = None,
2153
+ on_click: Optional[
2154
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2155
+ ] = None,
2156
+ on_context_menu: Optional[
2157
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2158
+ ] = None,
2159
+ on_double_click: Optional[
2160
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2161
+ ] = None,
2162
+ on_focus: Optional[
2163
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2164
+ ] = None,
2165
+ on_mount: Optional[
2166
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2167
+ ] = None,
2168
+ on_mouse_down: Optional[
2169
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2170
+ ] = None,
2171
+ on_mouse_enter: Optional[
2172
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2173
+ ] = None,
2174
+ on_mouse_leave: Optional[
2175
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2176
+ ] = None,
2177
+ on_mouse_move: Optional[
2178
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2179
+ ] = None,
2180
+ on_mouse_out: Optional[
2181
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2182
+ ] = None,
2183
+ on_mouse_over: Optional[
2184
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2185
+ ] = None,
2186
+ on_mouse_up: Optional[
2187
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2188
+ ] = None,
2189
+ on_scroll: Optional[
2190
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2191
+ ] = None,
2192
+ on_unmount: Optional[
2193
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2194
+ ] = None,
2195
+ **props
2196
+ ) -> "Lineargradient":
2197
+ """Create the component.
2198
+
2199
+ Args:
2200
+ *children: The children of the component.
2201
+ gradient_units: Units for the gradient
2202
+ gradient_transform: Transform applied to the gradient
2203
+ spread_method: Method used to spread the gradient
2204
+ x1: X coordinate of the starting point of the gradient
2205
+ x2: X coordinate of the ending point of the gradient
2206
+ y1: Y coordinate of the starting point of the gradient
2207
+ y2: Y coordinate of the ending point of the gradient
2208
+ access_key: Provides a hint for generating a keyboard shortcut for the current element.
2209
+ auto_capitalize: Controls whether and how text input is automatically capitalized as it is entered/edited by the user.
2210
+ content_editable: Indicates whether the element's content is editable.
2211
+ context_menu: Defines the ID of a <menu> element which will serve as the element's context menu.
2212
+ dir: Defines the text direction. Allowed values are ltr (Left-To-Right) or rtl (Right-To-Left)
2213
+ draggable: Defines whether the element can be dragged.
2214
+ enter_key_hint: Hints what media types the media element is able to play.
2215
+ hidden: Defines whether the element is hidden.
2216
+ input_mode: Defines the type of the element.
2217
+ item_prop: Defines the name of the element for metadata purposes.
2218
+ lang: Defines the language used in the element.
2219
+ role: Defines the role of the element.
2220
+ slot: Assigns a slot in a shadow DOM shadow tree to an element.
2221
+ spell_check: Defines whether the element may be checked for spelling errors.
2222
+ tab_index: Defines the position of the current element in the tabbing order.
2223
+ title: Defines a tooltip for the element.
2224
+ style: The style of the component.
2225
+ key: A unique key for the component.
2226
+ id: The id for the component.
2227
+ class_name: The class name for the component.
2228
+ autofocus: Whether the component should take the focus once the page is loaded
2229
+ custom_attrs: custom attribute
2230
+ **props: The props of the component.
2231
+
2232
+ Returns:
2233
+ The component.
2234
+ """
2235
+ ...
2236
+
2237
+ class Stop(BaseHTML):
2238
+ @overload
2239
+ @classmethod
2240
+ def create( # type: ignore
2241
+ cls,
2242
+ *children,
2243
+ offset: Optional[
2244
+ Union[Var[Union[str, float, int]], Union[str, float, int]]
2245
+ ] = None,
2246
+ stop_color: Optional[
2247
+ Union[Var[Union[str, Color, bool]], Union[str, Color, bool]]
2248
+ ] = None,
2249
+ stop_opacity: Optional[
2250
+ Union[Var[Union[str, float, int, bool]], Union[str, float, int, bool]]
2251
+ ] = None,
2252
+ access_key: Optional[
2253
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2254
+ ] = None,
2255
+ auto_capitalize: Optional[
2256
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2257
+ ] = None,
2258
+ content_editable: Optional[
2259
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2260
+ ] = None,
2261
+ context_menu: Optional[
2262
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2263
+ ] = None,
2264
+ dir: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2265
+ draggable: Optional[
2266
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2267
+ ] = None,
2268
+ enter_key_hint: Optional[
2269
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2270
+ ] = None,
2271
+ hidden: Optional[
2272
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2273
+ ] = None,
2274
+ input_mode: Optional[
2275
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2276
+ ] = None,
2277
+ item_prop: Optional[
2278
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2279
+ ] = None,
2280
+ lang: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2281
+ role: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2282
+ slot: Optional[Union[Var[Union[str, int, bool]], Union[str, int, bool]]] = None,
2283
+ spell_check: Optional[
2284
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2285
+ ] = None,
2286
+ tab_index: Optional[
2287
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2288
+ ] = None,
2289
+ title: Optional[
2290
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
2291
+ ] = None,
2292
+ style: Optional[Style] = None,
2293
+ key: Optional[Any] = None,
2294
+ id: Optional[Any] = None,
2295
+ class_name: Optional[Any] = None,
2296
+ autofocus: Optional[bool] = None,
2297
+ custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
2298
+ on_blur: Optional[
2299
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2300
+ ] = None,
2301
+ on_click: Optional[
2302
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2303
+ ] = None,
2304
+ on_context_menu: Optional[
2305
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2306
+ ] = None,
2307
+ on_double_click: Optional[
2308
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2309
+ ] = None,
2310
+ on_focus: Optional[
2311
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2312
+ ] = None,
2313
+ on_mount: Optional[
2314
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2315
+ ] = None,
2316
+ on_mouse_down: Optional[
2317
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2318
+ ] = None,
2319
+ on_mouse_enter: Optional[
2320
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2321
+ ] = None,
2322
+ on_mouse_leave: Optional[
2323
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2324
+ ] = None,
2325
+ on_mouse_move: Optional[
2326
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2327
+ ] = None,
2328
+ on_mouse_out: Optional[
2329
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2330
+ ] = None,
2331
+ on_mouse_over: Optional[
2332
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2333
+ ] = None,
2334
+ on_mouse_up: Optional[
2335
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2336
+ ] = None,
2337
+ on_scroll: Optional[
2338
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2339
+ ] = None,
2340
+ on_unmount: Optional[
2341
+ Union[EventHandler, EventSpec, list, function, BaseVar]
2342
+ ] = None,
2343
+ **props
2344
+ ) -> "Stop":
2345
+ """Create the component.
2346
+
2347
+ Args:
2348
+ *children: The children of the component.
2349
+ offset: Offset of the gradient stop
2350
+ stop_color: Color of the gradient stop
2351
+ stop_opacity: Opacity of the gradient stop
2352
+ access_key: Provides a hint for generating a keyboard shortcut for the current element.
2353
+ auto_capitalize: Controls whether and how text input is automatically capitalized as it is entered/edited by the user.
2354
+ content_editable: Indicates whether the element's content is editable.
2355
+ context_menu: Defines the ID of a <menu> element which will serve as the element's context menu.
2356
+ dir: Defines the text direction. Allowed values are ltr (Left-To-Right) or rtl (Right-To-Left)
2357
+ draggable: Defines whether the element can be dragged.
2358
+ enter_key_hint: Hints what media types the media element is able to play.
2359
+ hidden: Defines whether the element is hidden.
2360
+ input_mode: Defines the type of the element.
2361
+ item_prop: Defines the name of the element for metadata purposes.
2362
+ lang: Defines the language used in the element.
2363
+ role: Defines the role of the element.
2364
+ slot: Assigns a slot in a shadow DOM shadow tree to an element.
2365
+ spell_check: Defines whether the element may be checked for spelling errors.
2366
+ tab_index: Defines the position of the current element in the tabbing order.
2367
+ title: Defines a tooltip for the element.
2368
+ style: The style of the component.
2369
+ key: A unique key for the component.
2370
+ id: The id for the component.
2371
+ class_name: The class name for the component.
2372
+ autofocus: Whether the component should take the focus once the page is loaded
2373
+ custom_attrs: custom attribute
2374
+ **props: The props of the component.
2375
+
2376
+ Returns:
2377
+ The component.
2378
+ """
2379
+ ...
2380
+
1956
2381
  class Path(BaseHTML):
1957
2382
  @overload
1958
2383
  @classmethod
@@ -2100,4 +2525,7 @@ picture = Picture.create
2100
2525
  portal = Portal.create
2101
2526
  source = Source.create
2102
2527
  svg = Svg.create
2528
+ defs = Defs.create
2529
+ lineargradient = Lineargradient.create
2530
+ stop = Stop.create
2103
2531
  path = Path.create
@@ -1,4 +1,5 @@
1
1
  """Element classes. This is an auto-generated file. Do not edit. See ../generate.py."""
2
+
2
3
  from typing import Union
3
4
 
4
5
  from reflex.components.el.element import Element
@@ -55,8 +56,18 @@ class Title(Element): # noqa: E742
55
56
  tag = "title"
56
57
 
57
58
 
59
+ # Had to be named with an underscore so it doesnt conflict with reflex.style Style in pyi
60
+ class StyleEl(Element): # noqa: E742
61
+ """Display the style element."""
62
+
63
+ tag = "style"
64
+
65
+ media: Var[Union[str, int, bool]]
66
+
67
+
58
68
  base = Base.create
59
69
  head = Head.create
60
70
  link = Link.create
61
71
  meta = Meta.create
62
72
  title = Title.create
73
+ style = StyleEl.create
@@ -651,8 +651,88 @@ class Title(Element):
651
651
  """
652
652
  ...
653
653
 
654
+ class StyleEl(Element):
655
+ @overload
656
+ @classmethod
657
+ def create( # type: ignore
658
+ cls,
659
+ *children,
660
+ media: Optional[
661
+ Union[Var[Union[str, int, bool]], Union[str, int, bool]]
662
+ ] = None,
663
+ style: Optional[Style] = None,
664
+ key: Optional[Any] = None,
665
+ id: Optional[Any] = None,
666
+ class_name: Optional[Any] = None,
667
+ autofocus: Optional[bool] = None,
668
+ custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
669
+ on_blur: Optional[
670
+ Union[EventHandler, EventSpec, list, function, BaseVar]
671
+ ] = None,
672
+ on_click: Optional[
673
+ Union[EventHandler, EventSpec, list, function, BaseVar]
674
+ ] = None,
675
+ on_context_menu: Optional[
676
+ Union[EventHandler, EventSpec, list, function, BaseVar]
677
+ ] = None,
678
+ on_double_click: Optional[
679
+ Union[EventHandler, EventSpec, list, function, BaseVar]
680
+ ] = None,
681
+ on_focus: Optional[
682
+ Union[EventHandler, EventSpec, list, function, BaseVar]
683
+ ] = None,
684
+ on_mount: Optional[
685
+ Union[EventHandler, EventSpec, list, function, BaseVar]
686
+ ] = None,
687
+ on_mouse_down: Optional[
688
+ Union[EventHandler, EventSpec, list, function, BaseVar]
689
+ ] = None,
690
+ on_mouse_enter: Optional[
691
+ Union[EventHandler, EventSpec, list, function, BaseVar]
692
+ ] = None,
693
+ on_mouse_leave: Optional[
694
+ Union[EventHandler, EventSpec, list, function, BaseVar]
695
+ ] = None,
696
+ on_mouse_move: Optional[
697
+ Union[EventHandler, EventSpec, list, function, BaseVar]
698
+ ] = None,
699
+ on_mouse_out: Optional[
700
+ Union[EventHandler, EventSpec, list, function, BaseVar]
701
+ ] = None,
702
+ on_mouse_over: Optional[
703
+ Union[EventHandler, EventSpec, list, function, BaseVar]
704
+ ] = None,
705
+ on_mouse_up: Optional[
706
+ Union[EventHandler, EventSpec, list, function, BaseVar]
707
+ ] = None,
708
+ on_scroll: Optional[
709
+ Union[EventHandler, EventSpec, list, function, BaseVar]
710
+ ] = None,
711
+ on_unmount: Optional[
712
+ Union[EventHandler, EventSpec, list, function, BaseVar]
713
+ ] = None,
714
+ **props
715
+ ) -> "StyleEl":
716
+ """Create the component.
717
+
718
+ Args:
719
+ *children: The children of the component.
720
+ style: The style of the component.
721
+ key: A unique key for the component.
722
+ id: The id for the component.
723
+ class_name: The class name for the component.
724
+ autofocus: Whether the component should take the focus once the page is loaded
725
+ custom_attrs: custom attribute
726
+ **props: The props of the component.
727
+
728
+ Returns:
729
+ The component.
730
+ """
731
+ ...
732
+
654
733
  base = Base.create
655
734
  head = Head.create
656
735
  link = Link.create
657
736
  meta = Meta.create
658
737
  title = Title.create
738
+ style = StyleEl.create
@@ -1,4 +1,5 @@
1
1
  """Element classes. This is an auto-generated file. Do not edit. See ../generate.py."""
2
+
2
3
  from typing import Union
3
4
 
4
5
  from reflex.vars import Var as Var
@@ -1,4 +1,5 @@
1
1
  """Element classes. This is an auto-generated file. Do not edit. See ../generate.py."""
2
+
2
3
  from typing import Union
3
4
 
4
5
  from reflex.vars import Var as Var
@@ -1,4 +1,5 @@
1
1
  """Element classes. This is an auto-generated file. Do not edit. See ../generate.py."""
2
+
2
3
  from typing import Union
3
4
 
4
5
  from reflex.vars import Var as Var
@@ -1,4 +1,5 @@
1
1
  """Element classes. This is an auto-generated file. Do not edit. See ../generate.py."""
2
+
2
3
  from typing import Union
3
4
 
4
5
  from reflex.vars import Var as Var
@@ -6,7 +6,8 @@ from typing import Any, Dict, List, Union
6
6
 
7
7
  from reflex.components.component import Component
8
8
  from reflex.components.tags import Tag
9
- from reflex.utils import imports, types
9
+ from reflex.utils import types
10
+ from reflex.utils.imports import ImportDict
10
11
  from reflex.utils.serializers import serialize
11
12
  from reflex.vars import BaseVar, ComputedVar, Var
12
13
 
@@ -102,11 +103,13 @@ class DataTable(Gridjs):
102
103
  **props,
103
104
  )
104
105
 
105
- def _get_imports(self) -> imports.ImportDict:
106
- return imports.merge_imports(
107
- super()._get_imports(),
108
- {"": {imports.ImportVar(tag="gridjs/dist/theme/mermaid.css")}},
109
- )
106
+ def add_imports(self) -> ImportDict:
107
+ """Add the imports for the datatable component.
108
+
109
+ Returns:
110
+ The import dict for the component.
111
+ """
112
+ return {"": "gridjs/dist/theme/mermaid.css"}
110
113
 
111
114
  def _render(self) -> Tag:
112
115
  if isinstance(self.data, Var) and types.is_dataframe(self.data._var_type):
@@ -10,7 +10,8 @@ from reflex.style import Style
10
10
  from typing import Any, Dict, List, Union
11
11
  from reflex.components.component import Component
12
12
  from reflex.components.tags import Tag
13
- from reflex.utils import imports, types
13
+ from reflex.utils import types
14
+ from reflex.utils.imports import ImportDict
14
15
  from reflex.utils.serializers import serialize
15
16
  from reflex.vars import BaseVar, ComputedVar, Var
16
17
 
@@ -180,3 +181,5 @@ class DataTable(Gridjs):
180
181
  ValueError: If a pandas dataframe is passed in and columns are also provided.
181
182
  """
182
183
  ...
184
+
185
+ def add_imports(self) -> ImportDict: ...