base.pyi 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329
  1. """Stub file for reflex/components/el/elements/base.py"""
  2. # ------------------- DO NOT EDIT ----------------------
  3. # This file was generated by `reflex/utils/pyi_generator.py`!
  4. # ------------------------------------------------------
  5. from typing import Any, Literal, Optional, overload
  6. from reflex.components.el.element import Element
  7. from reflex.event import EventType
  8. from reflex.style import Style
  9. from reflex.vars.base import Var
  10. AutoCapitalize = Literal["off", "none", "on", "sentences", "words", "characters"]
  11. ContentEditable = Literal[True, False, "inherit", "plaintext-only"]
  12. EnterKeyHint = Literal["enter", "done", "go", "next", "previous", "search", "send"]
  13. InputMode = Literal[
  14. "none", "text", "tel", "url", "email", "numeric", "decimal", "search", "search"
  15. ]
  16. AriaRole = Literal[
  17. "alert",
  18. "alertdialog",
  19. "application",
  20. "article",
  21. "banner",
  22. "button",
  23. "cell",
  24. "checkbox",
  25. "columnheader",
  26. "combobox",
  27. "complementary",
  28. "contentinfo",
  29. "definition",
  30. "dialog",
  31. "directory",
  32. "document",
  33. "feed",
  34. "figure",
  35. "form",
  36. "grid",
  37. "gridcell",
  38. "group",
  39. "heading",
  40. "img",
  41. "link",
  42. "list",
  43. "listbox",
  44. "listitem",
  45. "log",
  46. "main",
  47. "marquee",
  48. "math",
  49. "menu",
  50. "menubar",
  51. "menuitem",
  52. "menuitemcheckbox",
  53. "menuitemradio",
  54. "navigation",
  55. "none",
  56. "note",
  57. "option",
  58. "presentation",
  59. "progressbar",
  60. "radio",
  61. "radiogroup",
  62. "region",
  63. "row",
  64. "rowgroup",
  65. "rowheader",
  66. "scrollbar",
  67. "search",
  68. "searchbox",
  69. "separator",
  70. "slider",
  71. "spinbutton",
  72. "status",
  73. "switch",
  74. "tab",
  75. "table",
  76. "tablist",
  77. "tabpanel",
  78. "term",
  79. "textbox",
  80. "timer",
  81. "toolbar",
  82. "tooltip",
  83. "tree",
  84. "treegrid",
  85. "treeitem",
  86. ]
  87. class BaseHTML(Element):
  88. @overload
  89. @classmethod
  90. def create( # type: ignore
  91. cls,
  92. *children,
  93. access_key: Var[str] | str | None = None,
  94. auto_capitalize: Literal[
  95. "characters", "none", "off", "on", "sentences", "words"
  96. ]
  97. | Var[Literal["characters", "none", "off", "on", "sentences", "words"]]
  98. | None = None,
  99. content_editable: Literal["inherit", "plaintext-only", False, True]
  100. | Var[Literal["inherit", "plaintext-only", False, True]]
  101. | None = None,
  102. context_menu: Var[str] | str | None = None,
  103. dir: Var[str] | str | None = None,
  104. draggable: Var[bool] | bool | None = None,
  105. enter_key_hint: Literal[
  106. "done", "enter", "go", "next", "previous", "search", "send"
  107. ]
  108. | Var[Literal["done", "enter", "go", "next", "previous", "search", "send"]]
  109. | None = None,
  110. hidden: Var[bool] | bool | None = None,
  111. input_mode: Literal[
  112. "decimal", "email", "none", "numeric", "search", "tel", "text", "url"
  113. ]
  114. | Var[
  115. Literal[
  116. "decimal", "email", "none", "numeric", "search", "tel", "text", "url"
  117. ]
  118. ]
  119. | None = None,
  120. item_prop: Var[str] | str | None = None,
  121. lang: Var[str] | str | None = None,
  122. role: Literal[
  123. "alert",
  124. "alertdialog",
  125. "application",
  126. "article",
  127. "banner",
  128. "button",
  129. "cell",
  130. "checkbox",
  131. "columnheader",
  132. "combobox",
  133. "complementary",
  134. "contentinfo",
  135. "definition",
  136. "dialog",
  137. "directory",
  138. "document",
  139. "feed",
  140. "figure",
  141. "form",
  142. "grid",
  143. "gridcell",
  144. "group",
  145. "heading",
  146. "img",
  147. "link",
  148. "list",
  149. "listbox",
  150. "listitem",
  151. "log",
  152. "main",
  153. "marquee",
  154. "math",
  155. "menu",
  156. "menubar",
  157. "menuitem",
  158. "menuitemcheckbox",
  159. "menuitemradio",
  160. "navigation",
  161. "none",
  162. "note",
  163. "option",
  164. "presentation",
  165. "progressbar",
  166. "radio",
  167. "radiogroup",
  168. "region",
  169. "row",
  170. "rowgroup",
  171. "rowheader",
  172. "scrollbar",
  173. "search",
  174. "searchbox",
  175. "separator",
  176. "slider",
  177. "spinbutton",
  178. "status",
  179. "switch",
  180. "tab",
  181. "table",
  182. "tablist",
  183. "tabpanel",
  184. "term",
  185. "textbox",
  186. "timer",
  187. "toolbar",
  188. "tooltip",
  189. "tree",
  190. "treegrid",
  191. "treeitem",
  192. ]
  193. | Var[
  194. Literal[
  195. "alert",
  196. "alertdialog",
  197. "application",
  198. "article",
  199. "banner",
  200. "button",
  201. "cell",
  202. "checkbox",
  203. "columnheader",
  204. "combobox",
  205. "complementary",
  206. "contentinfo",
  207. "definition",
  208. "dialog",
  209. "directory",
  210. "document",
  211. "feed",
  212. "figure",
  213. "form",
  214. "grid",
  215. "gridcell",
  216. "group",
  217. "heading",
  218. "img",
  219. "link",
  220. "list",
  221. "listbox",
  222. "listitem",
  223. "log",
  224. "main",
  225. "marquee",
  226. "math",
  227. "menu",
  228. "menubar",
  229. "menuitem",
  230. "menuitemcheckbox",
  231. "menuitemradio",
  232. "navigation",
  233. "none",
  234. "note",
  235. "option",
  236. "presentation",
  237. "progressbar",
  238. "radio",
  239. "radiogroup",
  240. "region",
  241. "row",
  242. "rowgroup",
  243. "rowheader",
  244. "scrollbar",
  245. "search",
  246. "searchbox",
  247. "separator",
  248. "slider",
  249. "spinbutton",
  250. "status",
  251. "switch",
  252. "tab",
  253. "table",
  254. "tablist",
  255. "tabpanel",
  256. "term",
  257. "textbox",
  258. "timer",
  259. "toolbar",
  260. "tooltip",
  261. "tree",
  262. "treegrid",
  263. "treeitem",
  264. ]
  265. ]
  266. | None = None,
  267. slot: Var[str] | str | None = None,
  268. spell_check: Var[bool] | bool | None = None,
  269. tab_index: Var[int] | int | None = None,
  270. title: Var[str] | str | None = None,
  271. style: Style | None = None,
  272. key: Any | None = None,
  273. id: Any | None = None,
  274. class_name: Any | None = None,
  275. autofocus: bool | None = None,
  276. custom_attrs: dict[str, Var | Any] | None = None,
  277. on_blur: Optional[EventType[()]] = None,
  278. on_click: Optional[EventType[()]] = None,
  279. on_context_menu: Optional[EventType[()]] = None,
  280. on_double_click: Optional[EventType[()]] = None,
  281. on_focus: Optional[EventType[()]] = None,
  282. on_mount: Optional[EventType[()]] = None,
  283. on_mouse_down: Optional[EventType[()]] = None,
  284. on_mouse_enter: Optional[EventType[()]] = None,
  285. on_mouse_leave: Optional[EventType[()]] = None,
  286. on_mouse_move: Optional[EventType[()]] = None,
  287. on_mouse_out: Optional[EventType[()]] = None,
  288. on_mouse_over: Optional[EventType[()]] = None,
  289. on_mouse_up: Optional[EventType[()]] = None,
  290. on_scroll: Optional[EventType[()]] = None,
  291. on_unmount: Optional[EventType[()]] = None,
  292. **props,
  293. ) -> "BaseHTML":
  294. """Create the component.
  295. Args:
  296. *children: The children of the component.
  297. access_key: Provides a hint for generating a keyboard shortcut for the current element.
  298. auto_capitalize: Controls whether and how text input is automatically capitalized as it is entered/edited by the user.
  299. content_editable: Indicates whether the element's content is editable.
  300. context_menu: Defines the ID of a <menu> element which will serve as the element's context menu.
  301. dir: Defines the text direction. Allowed values are ltr (Left-To-Right) or rtl (Right-To-Left)
  302. draggable: Defines whether the element can be dragged.
  303. enter_key_hint: Hints what media types the media element is able to play.
  304. hidden: Defines whether the element is hidden.
  305. input_mode: Defines the type of the element.
  306. item_prop: Defines the name of the element for metadata purposes.
  307. lang: Defines the language used in the element.
  308. role: Defines the role of the element.
  309. slot: Assigns a slot in a shadow DOM shadow tree to an element.
  310. spell_check: Defines whether the element may be checked for spelling errors.
  311. tab_index: Defines the position of the current element in the tabbing order.
  312. title: Defines a tooltip for the element.
  313. style: The style of the component.
  314. key: A unique key for the component.
  315. id: The id for the component.
  316. class_name: The class name for the component.
  317. autofocus: Whether the component should take the focus once the page is loaded
  318. custom_attrs: custom attribute
  319. **props: The props of the component.
  320. Returns:
  321. The component.
  322. """
  323. ...