transition.pyi 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528
  1. """Stub file for reflex/components/disclosure/transition.py"""
  2. # ------------------- DO NOT EDIT ----------------------
  3. # This file was generated by `scripts/pyi_generator.py`!
  4. # ------------------------------------------------------
  5. from typing import Any, Dict, Literal, Optional, Union, overload
  6. from reflex.vars import Var, BaseVar, ComputedVar
  7. from reflex.event import EventChain, EventHandler, EventSpec
  8. from reflex.style import Style
  9. from typing import Union
  10. from reflex.components.libs.chakra import ChakraComponent
  11. from reflex.vars import Var
  12. class Transition(ChakraComponent):
  13. @overload
  14. @classmethod
  15. def create( # type: ignore
  16. cls,
  17. *children,
  18. in_: Optional[Union[Var[bool], bool]] = None,
  19. unmount_on_exit: Optional[Union[Var[bool], bool]] = None,
  20. style: Optional[Style] = None,
  21. key: Optional[Any] = None,
  22. id: Optional[Any] = None,
  23. class_name: Optional[Any] = None,
  24. autofocus: Optional[bool] = None,
  25. custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
  26. on_blur: Optional[
  27. Union[EventHandler, EventSpec, list, function, BaseVar]
  28. ] = None,
  29. on_click: Optional[
  30. Union[EventHandler, EventSpec, list, function, BaseVar]
  31. ] = None,
  32. on_context_menu: Optional[
  33. Union[EventHandler, EventSpec, list, function, BaseVar]
  34. ] = None,
  35. on_double_click: Optional[
  36. Union[EventHandler, EventSpec, list, function, BaseVar]
  37. ] = None,
  38. on_focus: Optional[
  39. Union[EventHandler, EventSpec, list, function, BaseVar]
  40. ] = None,
  41. on_mount: Optional[
  42. Union[EventHandler, EventSpec, list, function, BaseVar]
  43. ] = None,
  44. on_mouse_down: Optional[
  45. Union[EventHandler, EventSpec, list, function, BaseVar]
  46. ] = None,
  47. on_mouse_enter: Optional[
  48. Union[EventHandler, EventSpec, list, function, BaseVar]
  49. ] = None,
  50. on_mouse_leave: Optional[
  51. Union[EventHandler, EventSpec, list, function, BaseVar]
  52. ] = None,
  53. on_mouse_move: Optional[
  54. Union[EventHandler, EventSpec, list, function, BaseVar]
  55. ] = None,
  56. on_mouse_out: Optional[
  57. Union[EventHandler, EventSpec, list, function, BaseVar]
  58. ] = None,
  59. on_mouse_over: Optional[
  60. Union[EventHandler, EventSpec, list, function, BaseVar]
  61. ] = None,
  62. on_mouse_up: Optional[
  63. Union[EventHandler, EventSpec, list, function, BaseVar]
  64. ] = None,
  65. on_scroll: Optional[
  66. Union[EventHandler, EventSpec, list, function, BaseVar]
  67. ] = None,
  68. on_unmount: Optional[
  69. Union[EventHandler, EventSpec, list, function, BaseVar]
  70. ] = None,
  71. **props
  72. ) -> "Transition":
  73. """Create the component.
  74. Args:
  75. *children: The children of the component.
  76. in_: Show the component; triggers when enter or exit states
  77. unmount_on_exit: If true, the element will unmount when `in={false}` and animation is done
  78. style: The style of the component.
  79. key: A unique key for the component.
  80. id: The id for the component.
  81. class_name: The class name for the component.
  82. autofocus: Whether the component should take the focus once the page is loaded
  83. custom_attrs: custom attribute
  84. **props: The props of the component.
  85. Returns:
  86. The component.
  87. Raises:
  88. TypeError: If an invalid child is passed.
  89. """
  90. ...
  91. class Fade(Transition):
  92. @overload
  93. @classmethod
  94. def create( # type: ignore
  95. cls,
  96. *children,
  97. in_: Optional[Union[Var[bool], bool]] = None,
  98. unmount_on_exit: Optional[Union[Var[bool], bool]] = None,
  99. style: Optional[Style] = None,
  100. key: Optional[Any] = None,
  101. id: Optional[Any] = None,
  102. class_name: Optional[Any] = None,
  103. autofocus: Optional[bool] = None,
  104. custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
  105. on_blur: Optional[
  106. Union[EventHandler, EventSpec, list, function, BaseVar]
  107. ] = None,
  108. on_click: Optional[
  109. Union[EventHandler, EventSpec, list, function, BaseVar]
  110. ] = None,
  111. on_context_menu: Optional[
  112. Union[EventHandler, EventSpec, list, function, BaseVar]
  113. ] = None,
  114. on_double_click: Optional[
  115. Union[EventHandler, EventSpec, list, function, BaseVar]
  116. ] = None,
  117. on_focus: Optional[
  118. Union[EventHandler, EventSpec, list, function, BaseVar]
  119. ] = None,
  120. on_mount: Optional[
  121. Union[EventHandler, EventSpec, list, function, BaseVar]
  122. ] = None,
  123. on_mouse_down: Optional[
  124. Union[EventHandler, EventSpec, list, function, BaseVar]
  125. ] = None,
  126. on_mouse_enter: Optional[
  127. Union[EventHandler, EventSpec, list, function, BaseVar]
  128. ] = None,
  129. on_mouse_leave: Optional[
  130. Union[EventHandler, EventSpec, list, function, BaseVar]
  131. ] = None,
  132. on_mouse_move: Optional[
  133. Union[EventHandler, EventSpec, list, function, BaseVar]
  134. ] = None,
  135. on_mouse_out: Optional[
  136. Union[EventHandler, EventSpec, list, function, BaseVar]
  137. ] = None,
  138. on_mouse_over: Optional[
  139. Union[EventHandler, EventSpec, list, function, BaseVar]
  140. ] = None,
  141. on_mouse_up: Optional[
  142. Union[EventHandler, EventSpec, list, function, BaseVar]
  143. ] = None,
  144. on_scroll: Optional[
  145. Union[EventHandler, EventSpec, list, function, BaseVar]
  146. ] = None,
  147. on_unmount: Optional[
  148. Union[EventHandler, EventSpec, list, function, BaseVar]
  149. ] = None,
  150. **props
  151. ) -> "Fade":
  152. """Create the component.
  153. Args:
  154. *children: The children of the component.
  155. in_: Show the component; triggers when enter or exit states
  156. unmount_on_exit: If true, the element will unmount when `in={false}` and animation is done
  157. style: The style of the component.
  158. key: A unique key for the component.
  159. id: The id for the component.
  160. class_name: The class name for the component.
  161. autofocus: Whether the component should take the focus once the page is loaded
  162. custom_attrs: custom attribute
  163. **props: The props of the component.
  164. Returns:
  165. The component.
  166. Raises:
  167. TypeError: If an invalid child is passed.
  168. """
  169. ...
  170. class ScaleFade(Transition):
  171. @overload
  172. @classmethod
  173. def create( # type: ignore
  174. cls,
  175. *children,
  176. initial_scale: Optional[Union[Var[float], float]] = None,
  177. reverse: Optional[Union[Var[bool], bool]] = None,
  178. in_: Optional[Union[Var[bool], bool]] = None,
  179. unmount_on_exit: Optional[Union[Var[bool], bool]] = None,
  180. style: Optional[Style] = None,
  181. key: Optional[Any] = None,
  182. id: Optional[Any] = None,
  183. class_name: Optional[Any] = None,
  184. autofocus: Optional[bool] = None,
  185. custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
  186. on_blur: Optional[
  187. Union[EventHandler, EventSpec, list, function, BaseVar]
  188. ] = None,
  189. on_click: Optional[
  190. Union[EventHandler, EventSpec, list, function, BaseVar]
  191. ] = None,
  192. on_context_menu: Optional[
  193. Union[EventHandler, EventSpec, list, function, BaseVar]
  194. ] = None,
  195. on_double_click: Optional[
  196. Union[EventHandler, EventSpec, list, function, BaseVar]
  197. ] = None,
  198. on_focus: Optional[
  199. Union[EventHandler, EventSpec, list, function, BaseVar]
  200. ] = None,
  201. on_mount: Optional[
  202. Union[EventHandler, EventSpec, list, function, BaseVar]
  203. ] = None,
  204. on_mouse_down: Optional[
  205. Union[EventHandler, EventSpec, list, function, BaseVar]
  206. ] = None,
  207. on_mouse_enter: Optional[
  208. Union[EventHandler, EventSpec, list, function, BaseVar]
  209. ] = None,
  210. on_mouse_leave: Optional[
  211. Union[EventHandler, EventSpec, list, function, BaseVar]
  212. ] = None,
  213. on_mouse_move: Optional[
  214. Union[EventHandler, EventSpec, list, function, BaseVar]
  215. ] = None,
  216. on_mouse_out: Optional[
  217. Union[EventHandler, EventSpec, list, function, BaseVar]
  218. ] = None,
  219. on_mouse_over: Optional[
  220. Union[EventHandler, EventSpec, list, function, BaseVar]
  221. ] = None,
  222. on_mouse_up: Optional[
  223. Union[EventHandler, EventSpec, list, function, BaseVar]
  224. ] = None,
  225. on_scroll: Optional[
  226. Union[EventHandler, EventSpec, list, function, BaseVar]
  227. ] = None,
  228. on_unmount: Optional[
  229. Union[EventHandler, EventSpec, list, function, BaseVar]
  230. ] = None,
  231. **props
  232. ) -> "ScaleFade":
  233. """Create the component.
  234. Args:
  235. *children: The children of the component.
  236. initial_scale: The initial scale of the element
  237. reverse: If true, the element will transition back to exit state
  238. in_: Show the component; triggers when enter or exit states
  239. unmount_on_exit: If true, the element will unmount when `in={false}` and animation is done
  240. style: The style of the component.
  241. key: A unique key for the component.
  242. id: The id for the component.
  243. class_name: The class name for the component.
  244. autofocus: Whether the component should take the focus once the page is loaded
  245. custom_attrs: custom attribute
  246. **props: The props of the component.
  247. Returns:
  248. The component.
  249. Raises:
  250. TypeError: If an invalid child is passed.
  251. """
  252. ...
  253. class Slide(Transition):
  254. @overload
  255. @classmethod
  256. def create( # type: ignore
  257. cls,
  258. *children,
  259. direction: Optional[Union[Var[str], str]] = None,
  260. in_: Optional[Union[Var[bool], bool]] = None,
  261. unmount_on_exit: Optional[Union[Var[bool], bool]] = None,
  262. style: Optional[Style] = None,
  263. key: Optional[Any] = None,
  264. id: Optional[Any] = None,
  265. class_name: Optional[Any] = None,
  266. autofocus: Optional[bool] = None,
  267. custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
  268. on_blur: Optional[
  269. Union[EventHandler, EventSpec, list, function, BaseVar]
  270. ] = None,
  271. on_click: Optional[
  272. Union[EventHandler, EventSpec, list, function, BaseVar]
  273. ] = None,
  274. on_context_menu: Optional[
  275. Union[EventHandler, EventSpec, list, function, BaseVar]
  276. ] = None,
  277. on_double_click: Optional[
  278. Union[EventHandler, EventSpec, list, function, BaseVar]
  279. ] = None,
  280. on_focus: Optional[
  281. Union[EventHandler, EventSpec, list, function, BaseVar]
  282. ] = None,
  283. on_mount: Optional[
  284. Union[EventHandler, EventSpec, list, function, BaseVar]
  285. ] = None,
  286. on_mouse_down: Optional[
  287. Union[EventHandler, EventSpec, list, function, BaseVar]
  288. ] = None,
  289. on_mouse_enter: Optional[
  290. Union[EventHandler, EventSpec, list, function, BaseVar]
  291. ] = None,
  292. on_mouse_leave: Optional[
  293. Union[EventHandler, EventSpec, list, function, BaseVar]
  294. ] = None,
  295. on_mouse_move: Optional[
  296. Union[EventHandler, EventSpec, list, function, BaseVar]
  297. ] = None,
  298. on_mouse_out: Optional[
  299. Union[EventHandler, EventSpec, list, function, BaseVar]
  300. ] = None,
  301. on_mouse_over: Optional[
  302. Union[EventHandler, EventSpec, list, function, BaseVar]
  303. ] = None,
  304. on_mouse_up: Optional[
  305. Union[EventHandler, EventSpec, list, function, BaseVar]
  306. ] = None,
  307. on_scroll: Optional[
  308. Union[EventHandler, EventSpec, list, function, BaseVar]
  309. ] = None,
  310. on_unmount: Optional[
  311. Union[EventHandler, EventSpec, list, function, BaseVar]
  312. ] = None,
  313. **props
  314. ) -> "Slide":
  315. """Create the component.
  316. Args:
  317. *children: The children of the component.
  318. direction: The direction to slide from
  319. in_: Show the component; triggers when enter or exit states
  320. unmount_on_exit: If true, the element will unmount when `in={false}` and animation is done
  321. style: The style of the component.
  322. key: A unique key for the component.
  323. id: The id for the component.
  324. class_name: The class name for the component.
  325. autofocus: Whether the component should take the focus once the page is loaded
  326. custom_attrs: custom attribute
  327. **props: The props of the component.
  328. Returns:
  329. The component.
  330. Raises:
  331. TypeError: If an invalid child is passed.
  332. """
  333. ...
  334. class SlideFade(Transition):
  335. @overload
  336. @classmethod
  337. def create( # type: ignore
  338. cls,
  339. *children,
  340. offsetX: Optional[Union[Var[Union[str, int]], Union[str, int]]] = None,
  341. offsetY: Optional[Union[Var[Union[str, int]], Union[str, int]]] = None,
  342. reverse: Optional[Union[Var[bool], bool]] = None,
  343. in_: Optional[Union[Var[bool], bool]] = None,
  344. unmount_on_exit: Optional[Union[Var[bool], bool]] = None,
  345. style: Optional[Style] = None,
  346. key: Optional[Any] = None,
  347. id: Optional[Any] = None,
  348. class_name: Optional[Any] = None,
  349. autofocus: Optional[bool] = None,
  350. custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
  351. on_blur: Optional[
  352. Union[EventHandler, EventSpec, list, function, BaseVar]
  353. ] = None,
  354. on_click: Optional[
  355. Union[EventHandler, EventSpec, list, function, BaseVar]
  356. ] = None,
  357. on_context_menu: Optional[
  358. Union[EventHandler, EventSpec, list, function, BaseVar]
  359. ] = None,
  360. on_double_click: Optional[
  361. Union[EventHandler, EventSpec, list, function, BaseVar]
  362. ] = None,
  363. on_focus: Optional[
  364. Union[EventHandler, EventSpec, list, function, BaseVar]
  365. ] = None,
  366. on_mount: Optional[
  367. Union[EventHandler, EventSpec, list, function, BaseVar]
  368. ] = None,
  369. on_mouse_down: Optional[
  370. Union[EventHandler, EventSpec, list, function, BaseVar]
  371. ] = None,
  372. on_mouse_enter: Optional[
  373. Union[EventHandler, EventSpec, list, function, BaseVar]
  374. ] = None,
  375. on_mouse_leave: Optional[
  376. Union[EventHandler, EventSpec, list, function, BaseVar]
  377. ] = None,
  378. on_mouse_move: Optional[
  379. Union[EventHandler, EventSpec, list, function, BaseVar]
  380. ] = None,
  381. on_mouse_out: Optional[
  382. Union[EventHandler, EventSpec, list, function, BaseVar]
  383. ] = None,
  384. on_mouse_over: Optional[
  385. Union[EventHandler, EventSpec, list, function, BaseVar]
  386. ] = None,
  387. on_mouse_up: Optional[
  388. Union[EventHandler, EventSpec, list, function, BaseVar]
  389. ] = None,
  390. on_scroll: Optional[
  391. Union[EventHandler, EventSpec, list, function, BaseVar]
  392. ] = None,
  393. on_unmount: Optional[
  394. Union[EventHandler, EventSpec, list, function, BaseVar]
  395. ] = None,
  396. **props
  397. ) -> "SlideFade":
  398. """Create the component.
  399. Args:
  400. *children: The children of the component.
  401. offsetX: The offset on the horizontal or x axis
  402. offsetY: The offset on the vertical or y axis
  403. reverse: If true, the element will be transitioned back to the offset when it leaves. Otherwise, it'll only fade out
  404. in_: Show the component; triggers when enter or exit states
  405. unmount_on_exit: If true, the element will unmount when `in={false}` and animation is done
  406. style: The style of the component.
  407. key: A unique key for the component.
  408. id: The id for the component.
  409. class_name: The class name for the component.
  410. autofocus: Whether the component should take the focus once the page is loaded
  411. custom_attrs: custom attribute
  412. **props: The props of the component.
  413. Returns:
  414. The component.
  415. Raises:
  416. TypeError: If an invalid child is passed.
  417. """
  418. ...
  419. class Collapse(Transition):
  420. @overload
  421. @classmethod
  422. def create( # type: ignore
  423. cls,
  424. *children,
  425. animateOpacity: Optional[Union[Var[bool], bool]] = None,
  426. endingHeight: Optional[Union[Var[str], str]] = None,
  427. startingHeight: Optional[Union[Var[Union[str, int]], Union[str, int]]] = None,
  428. in_: Optional[Union[Var[bool], bool]] = None,
  429. unmount_on_exit: Optional[Union[Var[bool], bool]] = None,
  430. style: Optional[Style] = None,
  431. key: Optional[Any] = None,
  432. id: Optional[Any] = None,
  433. class_name: Optional[Any] = None,
  434. autofocus: Optional[bool] = None,
  435. custom_attrs: Optional[Dict[str, Union[Var, str]]] = None,
  436. on_blur: Optional[
  437. Union[EventHandler, EventSpec, list, function, BaseVar]
  438. ] = None,
  439. on_click: Optional[
  440. Union[EventHandler, EventSpec, list, function, BaseVar]
  441. ] = None,
  442. on_context_menu: Optional[
  443. Union[EventHandler, EventSpec, list, function, BaseVar]
  444. ] = None,
  445. on_double_click: Optional[
  446. Union[EventHandler, EventSpec, list, function, BaseVar]
  447. ] = None,
  448. on_focus: Optional[
  449. Union[EventHandler, EventSpec, list, function, BaseVar]
  450. ] = None,
  451. on_mount: Optional[
  452. Union[EventHandler, EventSpec, list, function, BaseVar]
  453. ] = None,
  454. on_mouse_down: Optional[
  455. Union[EventHandler, EventSpec, list, function, BaseVar]
  456. ] = None,
  457. on_mouse_enter: Optional[
  458. Union[EventHandler, EventSpec, list, function, BaseVar]
  459. ] = None,
  460. on_mouse_leave: Optional[
  461. Union[EventHandler, EventSpec, list, function, BaseVar]
  462. ] = None,
  463. on_mouse_move: Optional[
  464. Union[EventHandler, EventSpec, list, function, BaseVar]
  465. ] = None,
  466. on_mouse_out: Optional[
  467. Union[EventHandler, EventSpec, list, function, BaseVar]
  468. ] = None,
  469. on_mouse_over: Optional[
  470. Union[EventHandler, EventSpec, list, function, BaseVar]
  471. ] = None,
  472. on_mouse_up: Optional[
  473. Union[EventHandler, EventSpec, list, function, BaseVar]
  474. ] = None,
  475. on_scroll: Optional[
  476. Union[EventHandler, EventSpec, list, function, BaseVar]
  477. ] = None,
  478. on_unmount: Optional[
  479. Union[EventHandler, EventSpec, list, function, BaseVar]
  480. ] = None,
  481. **props
  482. ) -> "Collapse":
  483. """Create the component.
  484. Args:
  485. *children: The children of the component.
  486. animateOpacity: If true, the opacity of the content will be animated
  487. endingHeight: The height you want the content in its expanded state.
  488. startingHeight: The height you want the content in its collapsed state.
  489. in_: Show the component; triggers when enter or exit states
  490. unmount_on_exit: If true, the element will unmount when `in={false}` and animation is done
  491. style: The style of the component.
  492. key: A unique key for the component.
  493. id: The id for the component.
  494. class_name: The class name for the component.
  495. autofocus: Whether the component should take the focus once the page is loaded
  496. custom_attrs: custom attribute
  497. **props: The props of the component.
  498. Returns:
  499. The component.
  500. Raises:
  501. TypeError: If an invalid child is passed.
  502. """
  503. ...