@terreno/ui 0.0.1

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.
Files changed (446) hide show
  1. package/LICENSE +203 -0
  2. package/README.md +160 -0
  3. package/dist/Accordion.d.ts +3 -0
  4. package/dist/Accordion.js +30 -0
  5. package/dist/Accordion.js.map +1 -0
  6. package/dist/ActionSheet.d.ts +169 -0
  7. package/dist/ActionSheet.js +637 -0
  8. package/dist/ActionSheet.js.map +1 -0
  9. package/dist/AddressField.d.ts +3 -0
  10. package/dist/AddressField.js +18 -0
  11. package/dist/AddressField.js.map +1 -0
  12. package/dist/Avatar.d.ts +3 -0
  13. package/dist/Avatar.js +189 -0
  14. package/dist/Avatar.js.map +1 -0
  15. package/dist/Badge.d.ts +3 -0
  16. package/dist/Badge.js +100 -0
  17. package/dist/Badge.js.map +1 -0
  18. package/dist/Banner.d.ts +4 -0
  19. package/dist/Banner.js +103 -0
  20. package/dist/Banner.js.map +1 -0
  21. package/dist/Body.d.ts +3 -0
  22. package/dist/Body.js +17 -0
  23. package/dist/Body.js.map +1 -0
  24. package/dist/BooleanField.d.ts +3 -0
  25. package/dist/BooleanField.js +89 -0
  26. package/dist/BooleanField.js.map +1 -0
  27. package/dist/Box.d.ts +3 -0
  28. package/dist/Box.js +289 -0
  29. package/dist/Box.js.map +1 -0
  30. package/dist/Button.d.ts +3 -0
  31. package/dist/Button.js +105 -0
  32. package/dist/Button.js.map +1 -0
  33. package/dist/Card.d.ts +2 -0
  34. package/dist/Card.js +18 -0
  35. package/dist/Card.js.map +1 -0
  36. package/dist/CheckBox.d.ts +3 -0
  37. package/dist/CheckBox.js +28 -0
  38. package/dist/CheckBox.js.map +1 -0
  39. package/dist/Common.d.ts +2325 -0
  40. package/dist/Common.js +47 -0
  41. package/dist/Common.js.map +1 -0
  42. package/dist/CommonIconTypes.d.ts +3 -0
  43. package/dist/CommonIconTypes.js +2 -0
  44. package/dist/CommonIconTypes.js.map +1 -0
  45. package/dist/Constants.d.ts +12685 -0
  46. package/dist/Constants.js +3310 -0
  47. package/dist/Constants.js.map +1 -0
  48. package/dist/CustomSelectField.d.ts +3 -0
  49. package/dist/CustomSelectField.js +59 -0
  50. package/dist/CustomSelectField.js.map +1 -0
  51. package/dist/DataTable.d.ts +3 -0
  52. package/dist/DataTable.js +190 -0
  53. package/dist/DataTable.js.map +1 -0
  54. package/dist/DateTimeActionSheet.d.ts +2 -0
  55. package/dist/DateTimeActionSheet.js +270 -0
  56. package/dist/DateTimeActionSheet.js.map +1 -0
  57. package/dist/DateTimeField.d.ts +3 -0
  58. package/dist/DateTimeField.js +514 -0
  59. package/dist/DateTimeField.js.map +1 -0
  60. package/dist/DateUtilities.d.ts +57 -0
  61. package/dist/DateUtilities.js +308 -0
  62. package/dist/DateUtilities.js.map +1 -0
  63. package/dist/DecimalRangeActionSheet.d.ts +6 -0
  64. package/dist/DecimalRangeActionSheet.js +45 -0
  65. package/dist/DecimalRangeActionSheet.js.map +1 -0
  66. package/dist/DismissButton.d.ts +3 -0
  67. package/dist/DismissButton.js +12 -0
  68. package/dist/DismissButton.js.map +1 -0
  69. package/dist/EmailField.d.ts +3 -0
  70. package/dist/EmailField.js +48 -0
  71. package/dist/EmailField.js.map +1 -0
  72. package/dist/EmojiSelector.d.ts +113 -0
  73. package/dist/EmojiSelector.js +322 -0
  74. package/dist/EmojiSelector.js.map +1 -0
  75. package/dist/ErrorBoundary.d.ts +19 -0
  76. package/dist/ErrorBoundary.js +30 -0
  77. package/dist/ErrorBoundary.js.map +1 -0
  78. package/dist/ErrorPage.d.ts +6 -0
  79. package/dist/ErrorPage.js +15 -0
  80. package/dist/ErrorPage.js.map +1 -0
  81. package/dist/Field.d.ts +3 -0
  82. package/dist/Field.js +80 -0
  83. package/dist/Field.js.map +1 -0
  84. package/dist/FlatList.d.ts +2 -0
  85. package/dist/FlatList.js +3 -0
  86. package/dist/FlatList.js.map +1 -0
  87. package/dist/Heading.d.ts +3 -0
  88. package/dist/Heading.js +43 -0
  89. package/dist/Heading.js.map +1 -0
  90. package/dist/HeightActionSheet.d.ts +11 -0
  91. package/dist/HeightActionSheet.js +46 -0
  92. package/dist/HeightActionSheet.js.map +1 -0
  93. package/dist/Hyperlink.d.ts +30 -0
  94. package/dist/Hyperlink.js +144 -0
  95. package/dist/Hyperlink.js.map +1 -0
  96. package/dist/Icon.d.ts +3 -0
  97. package/dist/Icon.js +15 -0
  98. package/dist/Icon.js.map +1 -0
  99. package/dist/IconButton.d.ts +3 -0
  100. package/dist/IconButton.js +111 -0
  101. package/dist/IconButton.js.map +1 -0
  102. package/dist/Image.d.ts +8 -0
  103. package/dist/Image.js +37 -0
  104. package/dist/Image.js.map +1 -0
  105. package/dist/ImageBackground.d.ts +10 -0
  106. package/dist/ImageBackground.js +9 -0
  107. package/dist/ImageBackground.js.map +1 -0
  108. package/dist/InfoModalIcon.d.ts +3 -0
  109. package/dist/InfoModalIcon.js +10 -0
  110. package/dist/InfoModalIcon.js.map +1 -0
  111. package/dist/InfoTooltipButton.d.ts +3 -0
  112. package/dist/InfoTooltipButton.js +6 -0
  113. package/dist/InfoTooltipButton.js.map +1 -0
  114. package/dist/Link.d.ts +3 -0
  115. package/dist/Link.js +10 -0
  116. package/dist/Link.js.map +1 -0
  117. package/dist/MarkdownView.d.ts +5 -0
  118. package/dist/MarkdownView.js +44 -0
  119. package/dist/MarkdownView.js.map +1 -0
  120. package/dist/MediaQuery.d.ts +4 -0
  121. package/dist/MediaQuery.js +52 -0
  122. package/dist/MediaQuery.js.map +1 -0
  123. package/dist/MobileAddressAutoComplete.d.ts +2 -0
  124. package/dist/MobileAddressAutoComplete.js +54 -0
  125. package/dist/MobileAddressAutoComplete.js.map +1 -0
  126. package/dist/Modal.d.ts +3 -0
  127. package/dist/Modal.js +127 -0
  128. package/dist/Modal.js.map +1 -0
  129. package/dist/ModalSheet.d.ts +6 -0
  130. package/dist/ModalSheet.js +42 -0
  131. package/dist/ModalSheet.js.map +1 -0
  132. package/dist/MultiselectField.d.ts +3 -0
  133. package/dist/MultiselectField.js +45 -0
  134. package/dist/MultiselectField.js.map +1 -0
  135. package/dist/NumberField.d.ts +3 -0
  136. package/dist/NumberField.js +60 -0
  137. package/dist/NumberField.js.map +1 -0
  138. package/dist/NumberPickerActionSheet.d.ts +7 -0
  139. package/dist/NumberPickerActionSheet.js +22 -0
  140. package/dist/NumberPickerActionSheet.js.map +1 -0
  141. package/dist/OpenAPIContext.d.ts +4 -0
  142. package/dist/OpenAPIContext.js +53 -0
  143. package/dist/OpenAPIContext.js.map +1 -0
  144. package/dist/Page.d.ts +7 -0
  145. package/dist/Page.js +24 -0
  146. package/dist/Page.js.map +1 -0
  147. package/dist/Pagination.d.ts +3 -0
  148. package/dist/Pagination.js +106 -0
  149. package/dist/Pagination.js.map +1 -0
  150. package/dist/PasswordField.d.ts +2 -0
  151. package/dist/PasswordField.js +6 -0
  152. package/dist/PasswordField.js.map +1 -0
  153. package/dist/Permissions.d.ts +2 -0
  154. package/dist/Permissions.js +35 -0
  155. package/dist/Permissions.js.map +1 -0
  156. package/dist/PhoneNumberField.d.ts +3 -0
  157. package/dist/PhoneNumberField.js +83 -0
  158. package/dist/PhoneNumberField.js.map +1 -0
  159. package/dist/PickerSelect.d.ts +46 -0
  160. package/dist/PickerSelect.js +306 -0
  161. package/dist/PickerSelect.js.map +1 -0
  162. package/dist/Radio.d.ts +3 -0
  163. package/dist/Radio.js +21 -0
  164. package/dist/Radio.js.map +1 -0
  165. package/dist/RadioField.d.ts +3 -0
  166. package/dist/RadioField.js +16 -0
  167. package/dist/RadioField.js.map +1 -0
  168. package/dist/ScrollView.d.ts +2 -0
  169. package/dist/ScrollView.js +3 -0
  170. package/dist/ScrollView.js.map +1 -0
  171. package/dist/SectionDivider.d.ts +2 -0
  172. package/dist/SectionDivider.js +12 -0
  173. package/dist/SectionDivider.js.map +1 -0
  174. package/dist/SegmentedControl.d.ts +3 -0
  175. package/dist/SegmentedControl.js +65 -0
  176. package/dist/SegmentedControl.js.map +1 -0
  177. package/dist/SelectBadge.d.ts +3 -0
  178. package/dist/SelectBadge.js +166 -0
  179. package/dist/SelectBadge.js.map +1 -0
  180. package/dist/SelectField.d.ts +3 -0
  181. package/dist/SelectField.js +16 -0
  182. package/dist/SelectField.js.map +1 -0
  183. package/dist/SideDrawer.d.ts +3 -0
  184. package/dist/SideDrawer.js +32 -0
  185. package/dist/SideDrawer.js.map +1 -0
  186. package/dist/Signature.d.ts +8 -0
  187. package/dist/Signature.js +21 -0
  188. package/dist/Signature.js.map +1 -0
  189. package/dist/Signature.native.d.ts +8 -0
  190. package/dist/Signature.native.js +26 -0
  191. package/dist/Signature.native.js.map +1 -0
  192. package/dist/SignatureField.d.ts +3 -0
  193. package/dist/SignatureField.js +42 -0
  194. package/dist/SignatureField.js.map +1 -0
  195. package/dist/Slider.d.ts +3 -0
  196. package/dist/Slider.js +78 -0
  197. package/dist/Slider.js.map +1 -0
  198. package/dist/Spinner.d.ts +3 -0
  199. package/dist/Spinner.js +33 -0
  200. package/dist/Spinner.js.map +1 -0
  201. package/dist/SplitPage.d.ts +2 -0
  202. package/dist/SplitPage.js +139 -0
  203. package/dist/SplitPage.js.map +1 -0
  204. package/dist/SplitPage.native.d.ts +2 -0
  205. package/dist/SplitPage.native.js +75 -0
  206. package/dist/SplitPage.native.js.map +1 -0
  207. package/dist/TapToEdit.d.ts +4 -0
  208. package/dist/TapToEdit.js +170 -0
  209. package/dist/TapToEdit.js.map +1 -0
  210. package/dist/TerrenoProvider.d.ts +6 -0
  211. package/dist/TerrenoProvider.js +10 -0
  212. package/dist/TerrenoProvider.js.map +1 -0
  213. package/dist/Text.d.ts +3 -0
  214. package/dist/Text.js +95 -0
  215. package/dist/Text.js.map +1 -0
  216. package/dist/TextArea.d.ts +3 -0
  217. package/dist/TextArea.js +6 -0
  218. package/dist/TextArea.js.map +1 -0
  219. package/dist/TextField.d.ts +3 -0
  220. package/dist/TextField.js +144 -0
  221. package/dist/TextField.js.map +1 -0
  222. package/dist/TextFieldNumberActionSheet.d.ts +7 -0
  223. package/dist/TextFieldNumberActionSheet.js +20 -0
  224. package/dist/TextFieldNumberActionSheet.js.map +1 -0
  225. package/dist/Theme.d.ts +96 -0
  226. package/dist/Theme.js +213 -0
  227. package/dist/Theme.js.map +1 -0
  228. package/dist/TimezonePicker.d.ts +11 -0
  229. package/dist/TimezonePicker.js +27 -0
  230. package/dist/TimezonePicker.js.map +1 -0
  231. package/dist/Toast.d.ts +23 -0
  232. package/dist/Toast.js +157 -0
  233. package/dist/Toast.js.map +1 -0
  234. package/dist/Tooltip.d.ts +3 -0
  235. package/dist/Tooltip.js +289 -0
  236. package/dist/Tooltip.js.map +1 -0
  237. package/dist/UnifiedAddressAutoComplete.d.ts +2 -0
  238. package/dist/UnifiedAddressAutoComplete.js +23 -0
  239. package/dist/UnifiedAddressAutoComplete.js.map +1 -0
  240. package/dist/Unifier.d.ts +43 -0
  241. package/dist/Unifier.js +154 -0
  242. package/dist/Unifier.js.map +1 -0
  243. package/dist/Utilities.d.ts +56 -0
  244. package/dist/Utilities.js +193 -0
  245. package/dist/Utilities.js.map +1 -0
  246. package/dist/WebAddressAutocomplete.d.ts +3 -0
  247. package/dist/WebAddressAutocomplete.js +61 -0
  248. package/dist/WebAddressAutocomplete.js.map +1 -0
  249. package/dist/fieldElements/FieldError.d.ts +6 -0
  250. package/dist/fieldElements/FieldError.js +9 -0
  251. package/dist/fieldElements/FieldError.js.map +1 -0
  252. package/dist/fieldElements/FieldHelperText.d.ts +6 -0
  253. package/dist/fieldElements/FieldHelperText.js +8 -0
  254. package/dist/fieldElements/FieldHelperText.js.map +1 -0
  255. package/dist/fieldElements/FieldTitle.d.ts +6 -0
  256. package/dist/fieldElements/FieldTitle.js +16 -0
  257. package/dist/fieldElements/FieldTitle.js.map +1 -0
  258. package/dist/fieldElements/index.d.ts +3 -0
  259. package/dist/fieldElements/index.js +4 -0
  260. package/dist/fieldElements/index.js.map +1 -0
  261. package/dist/icons/MobileIcon.d.ts +2 -0
  262. package/dist/icons/MobileIcon.js +18 -0
  263. package/dist/icons/MobileIcon.js.map +1 -0
  264. package/dist/icons/OfflineIcon.d.ts +2 -0
  265. package/dist/icons/OfflineIcon.js +18 -0
  266. package/dist/icons/OfflineIcon.js.map +1 -0
  267. package/dist/icons/OnlineIcon.d.ts +2 -0
  268. package/dist/icons/OnlineIcon.js +19 -0
  269. package/dist/icons/OnlineIcon.js.map +1 -0
  270. package/dist/icons/OutOfficeIcon.d.ts +2 -0
  271. package/dist/icons/OutOfficeIcon.js +18 -0
  272. package/dist/icons/OutOfficeIcon.js.map +1 -0
  273. package/dist/icons/index.d.ts +4 -0
  274. package/dist/icons/index.js +5 -0
  275. package/dist/icons/index.js.map +1 -0
  276. package/dist/index.d.ts +1328 -0
  277. package/dist/index.js +89 -0
  278. package/dist/index.js.map +1 -0
  279. package/dist/table/Table.d.ts +3 -0
  280. package/dist/table/Table.js +53 -0
  281. package/dist/table/Table.js.map +1 -0
  282. package/dist/table/TableBadge.d.ts +6 -0
  283. package/dist/table/TableBadge.js +23 -0
  284. package/dist/table/TableBadge.js.map +1 -0
  285. package/dist/table/TableBoolean.d.ts +6 -0
  286. package/dist/table/TableBoolean.js +37 -0
  287. package/dist/table/TableBoolean.js.map +1 -0
  288. package/dist/table/TableDate.d.ts +3 -0
  289. package/dist/table/TableDate.js +27 -0
  290. package/dist/table/TableDate.js.map +1 -0
  291. package/dist/table/TableHeader.d.ts +6 -0
  292. package/dist/table/TableHeader.js +10 -0
  293. package/dist/table/TableHeader.js.map +1 -0
  294. package/dist/table/TableHeaderCell.d.ts +6 -0
  295. package/dist/table/TableHeaderCell.js +54 -0
  296. package/dist/table/TableHeaderCell.js.map +1 -0
  297. package/dist/table/TableIconButton.d.ts +3 -0
  298. package/dist/table/TableIconButton.js +39 -0
  299. package/dist/table/TableIconButton.js.map +1 -0
  300. package/dist/table/TableNumber.d.ts +3 -0
  301. package/dist/table/TableNumber.js +18 -0
  302. package/dist/table/TableNumber.js.map +1 -0
  303. package/dist/table/TableRow.d.ts +6 -0
  304. package/dist/table/TableRow.js +22 -0
  305. package/dist/table/TableRow.js.map +1 -0
  306. package/dist/table/TableText.d.ts +3 -0
  307. package/dist/table/TableText.js +18 -0
  308. package/dist/table/TableText.js.map +1 -0
  309. package/dist/table/TableTitle.d.ts +3 -0
  310. package/dist/table/TableTitle.js +21 -0
  311. package/dist/table/TableTitle.js.map +1 -0
  312. package/dist/table/tableContext.d.ts +5 -0
  313. package/dist/table/tableContext.js +38 -0
  314. package/dist/table/tableContext.js.map +1 -0
  315. package/dist/useStoredState.d.ts +1 -0
  316. package/dist/useStoredState.js +49 -0
  317. package/dist/useStoredState.js.map +1 -0
  318. package/package.json +123 -0
  319. package/src/Accordion.test.tsx +104 -0
  320. package/src/Accordion.tsx +81 -0
  321. package/src/ActionSheet.tsx +881 -0
  322. package/src/AddressField.test.tsx +120 -0
  323. package/src/AddressField.tsx +122 -0
  324. package/src/Avatar.test.tsx +163 -0
  325. package/src/Avatar.tsx +298 -0
  326. package/src/Badge.test.tsx +116 -0
  327. package/src/Badge.tsx +136 -0
  328. package/src/Banner.tsx +200 -0
  329. package/src/Body.tsx +34 -0
  330. package/src/BooleanField.tsx +141 -0
  331. package/src/Box.test.tsx +662 -0
  332. package/src/Box.tsx +368 -0
  333. package/src/Button.tsx +196 -0
  334. package/src/Card.tsx +19 -0
  335. package/src/CheckBox.tsx +45 -0
  336. package/src/Common.ts +2787 -0
  337. package/src/CommonIconTypes.ts +2030 -0
  338. package/src/Constants.ts +3311 -0
  339. package/src/CustomSelectField.tsx +115 -0
  340. package/src/DataTable.tsx +674 -0
  341. package/src/DateTimeActionSheet.tsx +559 -0
  342. package/src/DateTimeField.test.tsx +393 -0
  343. package/src/DateTimeField.tsx +777 -0
  344. package/src/DateUtilities.test.ts +440 -0
  345. package/src/DateUtilities.tsx +370 -0
  346. package/src/DecimalRangeActionSheet.tsx +85 -0
  347. package/src/DismissButton.tsx +31 -0
  348. package/src/EmailField.tsx +66 -0
  349. package/src/EmojiSelector.test.tsx +61 -0
  350. package/src/EmojiSelector.tsx +510 -0
  351. package/src/ErrorBoundary.tsx +37 -0
  352. package/src/ErrorPage.tsx +41 -0
  353. package/src/Field.tsx +101 -0
  354. package/src/FlatList.tsx +2 -0
  355. package/src/Heading.tsx +66 -0
  356. package/src/HeightActionSheet.tsx +91 -0
  357. package/src/Hyperlink.tsx +179 -0
  358. package/src/Icon.tsx +36 -0
  359. package/src/IconButton.tsx +217 -0
  360. package/src/Image.tsx +51 -0
  361. package/src/ImageBackground.tsx +14 -0
  362. package/src/InfoModalIcon.tsx +42 -0
  363. package/src/InfoTooltipButton.tsx +16 -0
  364. package/src/Link.tsx +22 -0
  365. package/src/MarkdownView.tsx +67 -0
  366. package/src/MediaQuery.ts +46 -0
  367. package/src/MobileAddressAutoComplete.tsx +126 -0
  368. package/src/Modal.tsx +300 -0
  369. package/src/ModalSheet.tsx +58 -0
  370. package/src/MultiselectField.tsx +112 -0
  371. package/src/NumberField.tsx +67 -0
  372. package/src/NumberPickerActionSheet.tsx +51 -0
  373. package/src/OpenAPIContext.tsx +74 -0
  374. package/src/Page.tsx +105 -0
  375. package/src/Pagination.tsx +169 -0
  376. package/src/PasswordField.tsx +7 -0
  377. package/src/Permissions.ts +43 -0
  378. package/src/PhoneNumberField.tsx +109 -0
  379. package/src/PickerSelect.tsx +571 -0
  380. package/src/Radio.tsx +33 -0
  381. package/src/RadioField.tsx +43 -0
  382. package/src/ScrollView.tsx +2 -0
  383. package/src/SectionDivider.tsx +18 -0
  384. package/src/SegmentedControl.tsx +126 -0
  385. package/src/SelectBadge.tsx +280 -0
  386. package/src/SelectField.tsx +41 -0
  387. package/src/SideDrawer.tsx +56 -0
  388. package/src/Signature.native.tsx +57 -0
  389. package/src/Signature.tsx +44 -0
  390. package/src/SignatureField.tsx +92 -0
  391. package/src/Slider.tsx +199 -0
  392. package/src/Spinner.tsx +35 -0
  393. package/src/SplitPage.native.tsx +163 -0
  394. package/src/SplitPage.tsx +304 -0
  395. package/src/TapToEdit.tsx +292 -0
  396. package/src/TerrenoProvider.tsx +31 -0
  397. package/src/Text.tsx +123 -0
  398. package/src/TextArea.test.tsx +255 -0
  399. package/src/TextArea.tsx +8 -0
  400. package/src/TextField.test.tsx +487 -0
  401. package/src/TextField.tsx +260 -0
  402. package/src/TextFieldNumberActionSheet.tsx +46 -0
  403. package/src/Theme.tsx +248 -0
  404. package/src/TimezonePicker.tsx +45 -0
  405. package/src/Toast.tsx +234 -0
  406. package/src/Tooltip.tsx +407 -0
  407. package/src/UnifiedAddressAutoComplete.tsx +66 -0
  408. package/src/Unifier.ts +172 -0
  409. package/src/Utilities.tsx +329 -0
  410. package/src/WebAddressAutocomplete.tsx +84 -0
  411. package/src/__snapshots__/Accordion.test.tsx.snap +126 -0
  412. package/src/__snapshots__/AddressField.test.tsx.snap +1197 -0
  413. package/src/__snapshots__/Avatar.test.tsx.snap +57 -0
  414. package/src/__snapshots__/Badge.test.tsx.snap +55 -0
  415. package/src/__snapshots__/Box.test.tsx.snap +162 -0
  416. package/src/__snapshots__/EmojiSelector.test.tsx.snap +422 -0
  417. package/src/__snapshots__/TextArea.test.tsx.snap +521 -0
  418. package/src/__snapshots__/TextField.test.tsx.snap +569 -0
  419. package/src/bunSetup.ts +1235 -0
  420. package/src/fieldElements/FieldError.tsx +24 -0
  421. package/src/fieldElements/FieldHelperText.tsx +20 -0
  422. package/src/fieldElements/FieldTitle.tsx +31 -0
  423. package/src/fieldElements/index.tsx +3 -0
  424. package/src/icons/MobileIcon.tsx +40 -0
  425. package/src/icons/OfflineIcon.tsx +37 -0
  426. package/src/icons/OnlineIcon.tsx +39 -0
  427. package/src/icons/OutOfficeIcon.tsx +36 -0
  428. package/src/icons/index.ts +4 -0
  429. package/src/index.tsx +1375 -0
  430. package/src/polyfill.d.ts +11 -0
  431. package/src/table/Table.tsx +109 -0
  432. package/src/table/TableBadge.tsx +46 -0
  433. package/src/table/TableBoolean.tsx +70 -0
  434. package/src/table/TableDate.tsx +38 -0
  435. package/src/table/TableHeader.tsx +20 -0
  436. package/src/table/TableHeaderCell.tsx +94 -0
  437. package/src/table/TableIconButton.tsx +61 -0
  438. package/src/table/TableNumber.tsx +29 -0
  439. package/src/table/TableRow.tsx +67 -0
  440. package/src/table/TableText.tsx +29 -0
  441. package/src/table/TableTitle.tsx +31 -0
  442. package/src/table/tableContext.tsx +67 -0
  443. package/src/test-utils.tsx +27 -0
  444. package/src/types/react-native-swiper-flatlist.d.ts +56 -0
  445. package/src/useStoredState.test.tsx +143 -0
  446. package/src/useStoredState.ts +56 -0
package/src/index.tsx ADDED
@@ -0,0 +1,1375 @@
1
+ export * from "./Accordion";
2
+ export * from "./ActionSheet";
3
+ export * from "./AddressField";
4
+ export * from "./Avatar";
5
+ export * from "./Badge";
6
+ export * from "./Banner";
7
+ export * from "./Body";
8
+ export * from "./BooleanField";
9
+ export * from "./Box";
10
+ export * from "./Button";
11
+ export * from "./Card";
12
+ export * from "./CheckBox";
13
+ export * from "./Common";
14
+ export * from "./Constants";
15
+ export * from "./CustomSelectField";
16
+ export * from "./DataTable";
17
+ export * from "./DateTimeActionSheet";
18
+ export * from "./DateTimeField";
19
+ export * from "./DateUtilities";
20
+ export * from "./DecimalRangeActionSheet";
21
+ export * from "./DismissButton";
22
+ export * from "./EmailField";
23
+ export {default as EmojiSelector} from "./EmojiSelector";
24
+ export * from "./ErrorBoundary";
25
+ export * from "./ErrorPage";
26
+ export * from "./Field";
27
+ export * from "./FlatList";
28
+ export * from "./Heading";
29
+ export * from "./HeightActionSheet";
30
+ export * from "./Icon";
31
+ export * from "./IconButton";
32
+ export * from "./Image";
33
+ export * from "./ImageBackground";
34
+ export * from "./InfoModalIcon";
35
+ export * from "./InfoTooltipButton";
36
+ export * from "./Link";
37
+ export * from "./MarkdownView";
38
+ export * from "./MediaQuery";
39
+ export * from "./MobileAddressAutoComplete";
40
+ export * from "./Modal";
41
+ export * from "./ModalSheet";
42
+ export * from "./MultiselectField";
43
+ export * from "./NumberField";
44
+ export * from "./NumberPickerActionSheet";
45
+ export * from "./OpenAPIContext";
46
+ export * from "./Page";
47
+ export * from "./Pagination";
48
+ export * from "./PasswordField";
49
+ export * from "./PhoneNumberField";
50
+ export * from "./Radio";
51
+ export * from "./RadioField";
52
+ export * from "./ScrollView";
53
+ export * from "./SectionDivider";
54
+ export * from "./SegmentedControl";
55
+ export * from "./SelectBadge";
56
+ export * from "./SelectField";
57
+ export * from "./SideDrawer";
58
+ export * from "./Signature";
59
+ export * from "./SignatureField";
60
+ export * from "./Slider";
61
+ export * from "./Spinner";
62
+ export * from "./SplitPage";
63
+ export * from "./TapToEdit";
64
+ export * from "./TerrenoProvider";
65
+ export * from "./Text";
66
+ export * from "./TextArea";
67
+ export * from "./TextField";
68
+ export * from "./Theme";
69
+ export * from "./Toast";
70
+ export * from "./Tooltip";
71
+ export * from "./table/Table";
72
+ export * from "./table/Table";
73
+ export * from "./table/TableBadge";
74
+ export * from "./table/TableBoolean";
75
+ export * from "./table/TableDate";
76
+ export * from "./table/TableHeader";
77
+ export * from "./table/TableHeaderCell";
78
+ export * from "./table/TableIconButton";
79
+ export * from "./table/TableNumber";
80
+ export * from "./table/TableRow";
81
+ export * from "./table/TableText";
82
+ export * from "./table/TableTitle";
83
+ export * from "./table/tableContext";
84
+ export * from "./UnifiedAddressAutoComplete";
85
+ export * from "./Unifier";
86
+ export * from "./Utilities";
87
+ export * from "./useStoredState";
88
+ export * from "./WebAddressAutocomplete";
89
+
90
+ // export * from "./Layout";
91
+ // export * from "./Drawer";
92
+ // export * from "./Chart";
93
+
94
+ // Lifted from react-native
95
+ type ImageRequireSource = number;
96
+ interface Insets {
97
+ top?: number;
98
+ left?: number;
99
+ bottom?: number;
100
+ right?: number;
101
+ }
102
+
103
+ // Lifted from react-native-navigation
104
+ // import {Options} from "./Options";
105
+ export interface LayoutComponent<P = {}> {
106
+ /**
107
+ * Component reference id, Auto generated if empty
108
+ */
109
+ id?: string;
110
+ /**
111
+ * Name of your component
112
+ */
113
+ name: string | number;
114
+ /**
115
+ * Styling options
116
+ */
117
+ options?: Options;
118
+ /**
119
+ * Properties to pass down to the component
120
+ */
121
+ passProps?: P;
122
+ }
123
+ export interface LayoutStackChildren {
124
+ /**
125
+ * Set component
126
+ */
127
+ component?: LayoutComponent;
128
+ /**
129
+ * Set the external component
130
+ */
131
+ externalComponent?: ExternalComponent;
132
+ }
133
+ export interface LayoutStack {
134
+ /**
135
+ * Set ID of the stack so you can use Navigation.mergeOptions to
136
+ * update options
137
+ */
138
+ id?: string;
139
+ /**
140
+ * Set children screens
141
+ */
142
+ children?: LayoutStackChildren[];
143
+ /**
144
+ * Set options
145
+ */
146
+ options?: Options;
147
+ }
148
+ export interface LayoutTabsChildren {
149
+ /**
150
+ * Set stack
151
+ */
152
+ stack?: LayoutStack;
153
+ /**
154
+ * Set component
155
+ */
156
+ component?: LayoutComponent;
157
+ /**
158
+ * Set the external component
159
+ */
160
+ externalComponent?: ExternalComponent;
161
+ }
162
+ export interface LayoutBottomTabs {
163
+ /**
164
+ * Set ID of the stack so you can use Navigation.mergeOptions to
165
+ * update options
166
+ */
167
+ id?: string;
168
+ /**
169
+ * Set the children screens
170
+ */
171
+ children?: LayoutTabsChildren[];
172
+ /**
173
+ * Set the bottom tabs options
174
+ */
175
+ options?: Options;
176
+ }
177
+ export interface LayoutSideMenu {
178
+ /**
179
+ * Set ID of the stack so you can use Navigation.mergeOptions to
180
+ * update options
181
+ */
182
+ id?: string;
183
+ /**
184
+ * Set the left side bar
185
+ */
186
+ left?: LayoutStackChildren;
187
+ /**
188
+ * Set the center view
189
+ */
190
+ center: Layout;
191
+ /**
192
+ * Set the right side bar
193
+ */
194
+ right?: LayoutStackChildren;
195
+ /**
196
+ * Set the bottom tabs options
197
+ */
198
+ options?: Options;
199
+ }
200
+ export interface LayoutSplitView {
201
+ /**
202
+ * Set ID of the stack so you can use Navigation.mergeOptions to
203
+ * update options
204
+ */
205
+ id?: string;
206
+ /**
207
+ * Set master layout (the smaller screen, sidebar)
208
+ */
209
+ master?: Layout;
210
+ /**
211
+ * Set detail layout (the larger screen, flexes)
212
+ */
213
+ detail?: Layout;
214
+ /**
215
+ * Configure split view
216
+ */
217
+ options?: Options;
218
+ }
219
+ export interface LayoutTopTabs {
220
+ /**
221
+ * Set the layout's id so Navigation.mergeOptions can be used to update options
222
+ */
223
+ id?: string;
224
+ /**
225
+ * Set the children screens
226
+ */
227
+ children?: LayoutTabsChildren[];
228
+ /**
229
+ * Configure top tabs
230
+ */
231
+ options?: Options;
232
+ }
233
+ export interface LayoutRoot {
234
+ /**
235
+ * Set the root
236
+ */
237
+ root: Layout;
238
+ modals?: any;
239
+ overlays?: any;
240
+ }
241
+ export interface ExternalComponent {
242
+ /**
243
+ * Set the screen's id so Navigation.mergeOptions can be used to update options
244
+ */
245
+ id?: string;
246
+ /**
247
+ * Name of your component
248
+ */
249
+ name: string | number;
250
+ /**
251
+ * Configure component options
252
+ */
253
+ options?: Options;
254
+ /**
255
+ * Properties to pass down to the component
256
+ */
257
+ passProps?: object;
258
+ }
259
+ export interface Layout<P = {}> {
260
+ /**
261
+ * Set the component
262
+ */
263
+ component?: LayoutComponent<P>;
264
+ /**
265
+ * Set the stack
266
+ */
267
+ stack?: LayoutStack;
268
+ /**
269
+ * Set the bottom tabs
270
+ */
271
+ bottomTabs?: LayoutBottomTabs;
272
+ /**
273
+ * Set the side menu
274
+ */
275
+ sideMenu?: LayoutSideMenu;
276
+ /**
277
+ * Set the split view
278
+ */
279
+ splitView?: LayoutSplitView;
280
+ /**
281
+ * Set the top tabs
282
+ */
283
+ topTabs?: LayoutTopTabs;
284
+ /**
285
+ * Set the external component
286
+ */
287
+ externalComponent?: ExternalComponent;
288
+ }
289
+
290
+ declare type Color = string;
291
+ declare type FontFamily = string;
292
+ declare type FontWeight =
293
+ | "regular"
294
+ | "bold"
295
+ | "thin"
296
+ | "ultraLight"
297
+ | "light"
298
+ | "medium"
299
+ | "semibold"
300
+ | "heavy"
301
+ | "black";
302
+ declare type LayoutOrientation = "portrait" | "landscape";
303
+ declare type AndroidDensityNumber = number;
304
+ declare type SystemItemIcon =
305
+ | "done"
306
+ | "cancel"
307
+ | "edit"
308
+ | "save"
309
+ | "add"
310
+ | "flexibleSpace"
311
+ | "fixedSpace"
312
+ | "compose"
313
+ | "reply"
314
+ | "action"
315
+ | "organize"
316
+ | "bookmarks"
317
+ | "search"
318
+ | "refresh"
319
+ | "stop"
320
+ | "camera"
321
+ | "trash"
322
+ | "play"
323
+ | "pause"
324
+ | "rewind"
325
+ | "fastForward"
326
+ | "undo"
327
+ | "redo";
328
+ declare type Interpolation =
329
+ | "linear"
330
+ | "accelerateDecelerate"
331
+ | "decelerate"
332
+ | "accelerate"
333
+ | "decelerateAccelerate";
334
+ export interface OptionsSplitView {
335
+ /**
336
+ * Master view display mode
337
+ * @default 'auto'
338
+ */
339
+ displayMode?: "auto" | "visible" | "hidden" | "overlay";
340
+ /**
341
+ * Master view side. Leading is left. Trailing is right.
342
+ * @default 'leading'
343
+ */
344
+ primaryEdge?: "leading" | "trailing";
345
+ /**
346
+ * Set the minimum width of master view
347
+ */
348
+ minWidth?: number;
349
+ /**
350
+ * Set the maximum width of master view
351
+ */
352
+ maxWidth?: number;
353
+ }
354
+ export interface OptionsStatusBar {
355
+ /**
356
+ * Set the status bar visibility
357
+ * @default true
358
+ */
359
+ visible?: boolean;
360
+ /**
361
+ * Set the text color of the status bar
362
+ * @default 'light'
363
+ */
364
+ style?: "light" | "dark";
365
+ /**
366
+ * Set the background color of the status bar
367
+ * #### (Android specific)
368
+ */
369
+ backgroundColor?: Color;
370
+ /**
371
+ * Draw screen behind the status bar
372
+ * #### (Android specific)
373
+ */
374
+ drawBehind?: boolean;
375
+ }
376
+ export interface OptionsLayout {
377
+ fitSystemWindows?: boolean;
378
+ /**
379
+ * Set the screen background color
380
+ */
381
+ backgroundColor?: Color;
382
+ /**
383
+ * Set background color only for components, helps reduce overdraw if background color is set in
384
+ * default options. #### (Android specific)
385
+ */
386
+ componentBackgroundColor?: Color;
387
+ /**
388
+ * Set the allowed orientations
389
+ */
390
+ orientation?: LayoutOrientation[];
391
+ /**
392
+ * Layout top margin
393
+ * #### (Android specific)
394
+ */
395
+ topMargin?: number;
396
+ /**
397
+ * Set language direction.
398
+ * only works with DefaultOptions
399
+ */
400
+ direction?: "rtl" | "ltr";
401
+ }
402
+ export declare enum OptionsModalPresentationStyle {
403
+ formSheet = "formSheet",
404
+ pageSheet = "pageSheet",
405
+ overFullScreen = "overFullScreen",
406
+ overCurrentContext = "overCurrentContext",
407
+ currentContext = "currentContext",
408
+ popover = "popover",
409
+ fullScreen = "fullScreen",
410
+ none = "none",
411
+ }
412
+ export declare enum OptionsModalTransitionStyle {
413
+ coverVertical = "coverVertical",
414
+ crossDissolve = "crossDissolve",
415
+ flipHorizontal = "flipHorizontal",
416
+ partialCurl = "partialCurl",
417
+ }
418
+ export interface OptionsTopBarLargeTitle {
419
+ /**
420
+ * Enable large titles
421
+ */
422
+ visible?: boolean;
423
+ /**
424
+ * Set the font size of large title's text
425
+ */
426
+ fontSize?: number;
427
+ /**
428
+ * Set the color of large title's text
429
+ */
430
+ color?: Color;
431
+ /**
432
+ * Set the font family of large title's text
433
+ */
434
+ fontFamily?: FontFamily;
435
+ /**
436
+ * Set the font weight, ignore fontFamily and use the iOS system fonts instead
437
+ * #### (iOS specific)
438
+ */
439
+ fontWeight?: FontWeight;
440
+ }
441
+ export interface OptionsTopBarTitle {
442
+ /**
443
+ * Text to display in the title area
444
+ */
445
+ text?: string;
446
+ /**
447
+ * Font size
448
+ */
449
+ fontSize?: number;
450
+ /**
451
+ * Text color
452
+ */
453
+ color?: Color;
454
+ /**
455
+ * Title font family
456
+ *
457
+ * Make sure that the font is available
458
+ */
459
+ fontFamily?: FontFamily;
460
+ /**
461
+ * Set the font weight, ignore fontFamily and use the iOS system fonts instead
462
+ * #### (iOS specific)
463
+ */
464
+ fontWeight?: FontWeight;
465
+ /**
466
+ * Custom component as the title view
467
+ */
468
+ component?: {
469
+ /**
470
+ * Component reference id, Auto generated if empty
471
+ */
472
+ id?: string;
473
+ /**
474
+ * Name of your component
475
+ */
476
+ name: string;
477
+ /**
478
+ * Set component alignment
479
+ */
480
+ alignment?: "center" | "fill";
481
+ /**
482
+ * Properties to pass down to the component
483
+ */
484
+ passProps?: object;
485
+ };
486
+ /**
487
+ * Top Bar title height in density pixels
488
+ * #### (Android specific)
489
+ */
490
+ height?: number;
491
+ /**
492
+ * Title alignment
493
+ * #### (Android specific)
494
+ */
495
+ alignment?: "center" | "fill";
496
+ }
497
+ export interface OptionsTopBarSubtitle {
498
+ /**
499
+ * Set subtitle text
500
+ */
501
+ text?: string;
502
+ /**
503
+ * Set subtitle font size
504
+ */
505
+ fontSize?: number;
506
+ /**
507
+ * Set subtitle color
508
+ */
509
+ color?: Color;
510
+ /**
511
+ * Set subtitle font family
512
+ */
513
+ fontFamily?: FontFamily;
514
+ /**
515
+ * Set the font weight, ignore fontFamily and use the iOS system fonts instead
516
+ * #### (iOS specific)
517
+ */
518
+ fontWeight?: FontWeight;
519
+ /**
520
+ * Set subtitle alignment
521
+ */
522
+ alignment?: "center";
523
+ }
524
+ export interface OptionsTopBarBackButton {
525
+ /**
526
+ * Image to show as the back button
527
+ */
528
+ icon?: ImageRequireSource;
529
+ /**
530
+ * Whether the back button is visible or not
531
+ * @default true
532
+ */
533
+ visible?: boolean;
534
+ /**
535
+ * Set the back button title
536
+ * #### (iOS specific)
537
+ */
538
+ title?: string;
539
+ /**
540
+ * Show title or just the icon
541
+ * #### (iOS specific)
542
+ */
543
+ showTitle?: boolean;
544
+ /**
545
+ * Back button icon and text color
546
+ */
547
+ color?: Color;
548
+ /**
549
+ * Set subtitle font size
550
+ */
551
+ fontSize?: number;
552
+ /**
553
+ * Set subtitle font family
554
+ */
555
+ fontFamily?: FontFamily;
556
+ /**
557
+ * Set testID for reference in E2E tests
558
+ */
559
+ testID?: string;
560
+ }
561
+ export interface OptionsTopBarBackground {
562
+ /**
563
+ * Background color of the top bar
564
+ */
565
+ color?: Color;
566
+ /**
567
+ * Clip the top bar background to bounds if set to true.
568
+ * #### (iOS specific)
569
+ */
570
+ clipToBounds?: boolean;
571
+ /**
572
+ * Set a custom component for the Top Bar background
573
+ */
574
+ component?: {
575
+ name?: string;
576
+ /**
577
+ * Properties to pass down to the component
578
+ */
579
+ passProps?: object;
580
+ };
581
+ /**
582
+ * Allows the NavBar to be translucent (blurred)
583
+ * #### (iOS specific)
584
+ */
585
+ translucent?: boolean;
586
+ /**
587
+ * Enable background blur
588
+ * #### (iOS specific)
589
+ */
590
+ blur?: boolean;
591
+ }
592
+ export interface OptionsTopBarButton {
593
+ /**
594
+ * Button id for reference press event
595
+ */
596
+ id: string;
597
+ /**
598
+ * Set the button icon
599
+ */
600
+ icon?: ImageRequireSource;
601
+ /**
602
+ * Set the button icon insets
603
+ */
604
+ iconInsets?: IconInsets;
605
+ /**
606
+ * Set the button as a custom component
607
+ */
608
+ component?: {
609
+ /**
610
+ * Component reference id, Auto generated if empty
611
+ */
612
+ id?: string;
613
+ /**
614
+ * Name of your component
615
+ */
616
+ name: string;
617
+ /**
618
+ * Properties to pass down to the component
619
+ */
620
+ passProps?: object;
621
+ /**
622
+ * (Android only) component width
623
+ */
624
+ width?: number;
625
+ /**
626
+ * (Android only) component height
627
+ */
628
+ height?: number;
629
+ };
630
+ /**
631
+ * (iOS only) Set the button as an iOS system icon
632
+ */
633
+ systemItem?: SystemItemIcon;
634
+ /**
635
+ * Set the button text
636
+ */
637
+ text?: string;
638
+ /**
639
+ * Overrides the text that's read by the screen reader when the user interacts with the element
640
+ */
641
+ accessibilityLabel?: string;
642
+ /**
643
+ * Set the button font family
644
+ */
645
+ fontFamily?: string;
646
+ /**
647
+ * Set the font weight, ignore fontFamily and use the iOS system fonts instead
648
+ * #### (iOS specific)
649
+ */
650
+ fontWeight?: FontWeight;
651
+ /**
652
+ * Set the button enabled or disabled
653
+ * @default true
654
+ */
655
+ enabled?: boolean;
656
+ /**
657
+ * Disable icon tinting
658
+ */
659
+ disableIconTint?: boolean;
660
+ /**
661
+ * Set text color
662
+ */
663
+ color?: Color;
664
+ /**
665
+ * Set text color in disabled state
666
+ */
667
+ disabledColor?: Color;
668
+ /**
669
+ * Set testID for reference in E2E tests
670
+ */
671
+ testID?: string;
672
+ /**
673
+ * (Android only) Set showAsAction value
674
+ * @see {@link https://developer.android.com/guide/topics/resources/menu-resource|Android developer guide: Menu resource}
675
+ */
676
+ showAsAction?: "ifRoom" | "withText" | "always" | "never";
677
+ }
678
+ export interface OptionsTopBar {
679
+ /**
680
+ * Show or hide the top bar
681
+ */
682
+ visible?: boolean;
683
+ /**
684
+ * Controls whether TopBar visibility changes should be animated
685
+ */
686
+ animate?: boolean;
687
+ /**
688
+ * Top bar will hide and show based on users scroll direction
689
+ */
690
+ hideOnScroll?: boolean;
691
+ /**
692
+ * Change button colors in the top bar
693
+ */
694
+ leftButtonColor?: Color;
695
+ rightButtonColor?: Color;
696
+ leftButtonDisabledColor?: Color;
697
+ rightButtonDisabledColor?: Color;
698
+ /**
699
+ * Draw behind the navbar
700
+ */
701
+ drawBehind?: boolean;
702
+ /**
703
+ * Can be used to reference the top bar in E2E tests
704
+ */
705
+ testID?: string;
706
+ /**
707
+ * Title configuration
708
+ */
709
+ title?: OptionsTopBarTitle;
710
+ /**
711
+ * Subtitle configuration
712
+ */
713
+ subtitle?: OptionsTopBarSubtitle;
714
+ /**
715
+ * Back button configuration
716
+ */
717
+ backButton?: OptionsTopBarBackButton;
718
+ /**
719
+ * List of buttons to the left
720
+ */
721
+ leftButtons?: OptionsTopBarButton[];
722
+ /**
723
+ * List of buttons to the right
724
+ */
725
+ rightButtons?: OptionsTopBarButton[];
726
+ /**
727
+ * Background configuration
728
+ */
729
+ background?: OptionsTopBarBackground;
730
+ /**
731
+ * Control the NavBar blur style
732
+ * #### (iOS specific)
733
+ * @requires translucent: true
734
+ * @default 'default'
735
+ */
736
+ barStyle?: "default" | "black";
737
+ /**
738
+ * Disable the border on bottom of the navbar
739
+ * #### (iOS specific)
740
+ * @default false
741
+ */
742
+ noBorder?: boolean;
743
+ /**
744
+ * Show a UISearchBar in the Top Bar
745
+ * #### (iOS 11+ specific)
746
+ */
747
+ searchBar?: boolean;
748
+ /**
749
+ * Hides the UISearchBar when scrolling
750
+ * #### (iOS 11+ specific)
751
+ */
752
+ searchBarHiddenWhenScrolling?: boolean;
753
+ /**
754
+ * The placeholder value in the UISearchBar
755
+ * #### (iOS 11+ specific)
756
+ */
757
+ searchBarPlaceholder?: string;
758
+ /**
759
+ * Controls Hiding NavBar on focus UISearchBar
760
+ * #### (iOS 11+ specific)
761
+ */
762
+ hideNavBarOnFocusSearchBar?: boolean;
763
+ /**
764
+ * Control the Large Title configuration
765
+ * #### (iOS 11+ specific)
766
+ */
767
+ largeTitle?: OptionsTopBarLargeTitle;
768
+ /**
769
+ * Set the height of the navbar in dp
770
+ * #### (Android specific)
771
+ */
772
+ height?: AndroidDensityNumber;
773
+ /**
774
+ * Change the navbar border color
775
+ * #### (Android specific)
776
+ */
777
+ borderColor?: Color;
778
+ /**
779
+ * Set the border height of the navbar in dp
780
+ * #### (Android specific)
781
+ */
782
+ borderHeight?: AndroidDensityNumber;
783
+ /**
784
+ * Set the elevation of the navbar in dp
785
+ * #### (Android specific)
786
+ */
787
+ elevation?: AndroidDensityNumber;
788
+ /**
789
+ * Layout top margin
790
+ * #### (Android specific)
791
+ */
792
+ topMargin?: number;
793
+ }
794
+ export interface SharedElementTransition {
795
+ fromId: string;
796
+ toId: string;
797
+ duration?: number;
798
+ interpolation: Interpolation;
799
+ }
800
+ export interface ElementTransition {
801
+ id: string;
802
+ alpha?: AppearingElementAnimation | DisappearingElementAnimation;
803
+ translationX?: AppearingElementAnimation | DisappearingElementAnimation;
804
+ translationY?: AppearingElementAnimation | DisappearingElementAnimation;
805
+ scaleX?: AppearingElementAnimation | DisappearingElementAnimation;
806
+ scaleY?: AppearingElementAnimation | DisappearingElementAnimation;
807
+ rotationX?: AppearingElementAnimation | DisappearingElementAnimation;
808
+ rotationY?: AppearingElementAnimation | DisappearingElementAnimation;
809
+ x?: AppearingElementAnimation | DisappearingElementAnimation;
810
+ y?: AppearingElementAnimation | DisappearingElementAnimation;
811
+ }
812
+ export interface AppearingElementAnimation extends ElementAnimation {
813
+ from: number;
814
+ }
815
+ export interface DisappearingElementAnimation extends ElementAnimation {
816
+ to: number;
817
+ }
818
+ export interface ElementAnimation {
819
+ duration: number;
820
+ startDelay?: number;
821
+ interpolation: Interpolation;
822
+ }
823
+ export interface OptionsFab {
824
+ id: string;
825
+ backgroundColor?: Color;
826
+ clickColor?: Color;
827
+ rippleColor?: Color;
828
+ visible?: boolean;
829
+ icon?: ImageRequireSource;
830
+ iconColor?: Color;
831
+ alignHorizontally?: "left" | "right";
832
+ alignVertically?: "top" | "bottom";
833
+ hideOnScroll?: boolean;
834
+ size?: number;
835
+ actions?: OptionsFab[];
836
+ }
837
+ export interface OptionsBottomTabs {
838
+ /**
839
+ * Show or hide the bottom tabs
840
+ */
841
+ visible?: boolean;
842
+ /**
843
+ * Enable animations when toggling visibility
844
+ */
845
+ animate?: boolean;
846
+ /**
847
+ * Use large icons when possible, even when three tabs without titles are displayed
848
+ * #### (android specific)
849
+ * @default false
850
+ */
851
+ preferLargeIcons?: boolean;
852
+ /**
853
+ * Switch to another screen within the bottom tabs via index (starting from 0)
854
+ */
855
+ currentTabIndex?: number;
856
+ /**
857
+ * Switch to another screen within the bottom tabs via screen name
858
+ */
859
+ currentTabId?: string;
860
+ /**
861
+ * Set a testID to reference the bottom tabs
862
+ */
863
+ testID?: string;
864
+ /**
865
+ * Draw screen component under the tab bar
866
+ */
867
+ drawBehind?: boolean;
868
+ /**
869
+ * Set a background color for the bottom tabs
870
+ */
871
+ backgroundColor?: Color;
872
+ /**
873
+ * Set when tabs are attached to hierarchy consequently when the
874
+ * RootView's constructor is called.
875
+ */
876
+ tabsAttachMode?: "together" | "afterInitialTab" | "onSwitchToTab";
877
+ /**
878
+ * Control the Bottom Tabs blur style
879
+ * #### (iOS specific)
880
+ * @requires translucent: true
881
+ * @default 'default'
882
+ */
883
+ barStyle?: "default" | "black";
884
+ /**
885
+ * Allows the Bottom Tabs to be translucent (blurred)
886
+ * #### (iOS specific)
887
+ */
888
+ translucent?: boolean;
889
+ /**
890
+ * Hide the top line of the Tab Bar
891
+ * #### (iOS specific)
892
+ */
893
+ hideShadow?: boolean;
894
+ /**
895
+ * Control the text display mode below the tab icon
896
+ * #### (Android specific)
897
+ */
898
+ titleDisplayMode?: "alwaysShow" | "showWhenActive" | "alwaysHide" | "showWhenActiveForce";
899
+ /**
900
+ * Set the elevation of the Bottom Tabs in dp
901
+ * #### (Android specific)
902
+ */
903
+ elevation?: AndroidDensityNumber;
904
+ }
905
+ export interface DotIndicatorOptions {
906
+ color?: Color;
907
+ size?: number;
908
+ visible?: boolean;
909
+ }
910
+ export declare type ImageResource = string;
911
+ export interface OptionsBottomTab {
912
+ dotIndicator?: DotIndicatorOptions;
913
+ /**
914
+ * Set the text to display below the icon
915
+ */
916
+ text?: string;
917
+ /**
918
+ * Set the text in a badge that is overlayed over the component
919
+ */
920
+ badge?: string;
921
+ /**
922
+ * Set the background color of the badge that is overlayed over the component
923
+ */
924
+ badgeColor?: string;
925
+ /**
926
+ * Set a testID to reference the tab in E2E tests
927
+ */
928
+ testID?: string;
929
+ /**
930
+ * Set the tab icon
931
+ */
932
+ icon?: ImageRequireSource | ImageResource;
933
+ /**
934
+ * Set the icon tint
935
+ */
936
+ iconColor?: Color;
937
+ /**
938
+ * Set the text color
939
+ */
940
+ textColor?: Color;
941
+ /**
942
+ * Set the selected icon tint
943
+ */
944
+ selectedIconColor?: Color;
945
+ /**
946
+ * Set the selected text color
947
+ */
948
+ selectedTextColor?: Color;
949
+ /**
950
+ * Set the text font family
951
+ */
952
+ fontFamily?: FontFamily;
953
+ /**
954
+ * Set the font weight, ignore fontFamily and use the iOS system fonts instead
955
+ * #### (iOS specific)
956
+ */
957
+ fontWeight?: FontWeight;
958
+ /**
959
+ * Set the text font size
960
+ */
961
+ fontSize?: number;
962
+ /**
963
+ * Set the insets of the icon
964
+ * #### (iOS specific)
965
+ */
966
+ iconInsets?: Insets;
967
+ /**
968
+ * Set selected icon image
969
+ * #### (iOS specific)
970
+ */
971
+ selectedIcon?: ImageRequireSource;
972
+ /**
973
+ * Set true if you want to disable the icon tinting
974
+ * #### (iOS specific)
975
+ */
976
+ disableIconTint?: boolean;
977
+ /**
978
+ * Set true if you want to disable the text tinting
979
+ * #### (iOS specific)
980
+ */
981
+ disableSelectedIconTint?: boolean;
982
+ /**
983
+ * Set the font size for selected tabs
984
+ * #### (Android specific)
985
+ */
986
+ selectedFontSize?: number;
987
+ /**
988
+ * If it's set to false, pressing a tab won't select the tab
989
+ * instead it will emit a bottomTabPressedEvent
990
+ */
991
+ selectTabOnPress?: boolean;
992
+ }
993
+ export interface SideMenuSide {
994
+ /**
995
+ * Show or hide the side menu
996
+ */
997
+ visible?: boolean;
998
+ /**
999
+ * Enable or disable the side menu
1000
+ */
1001
+ enabled?: boolean;
1002
+ /**
1003
+ * Set the width of the side menu
1004
+ */
1005
+ width?: number;
1006
+ /**
1007
+ * Set the height of the side menu
1008
+ */
1009
+ height?: number;
1010
+ /**
1011
+ * Stretch sideMenu contents when opened past the width
1012
+ * #### (iOS specific)
1013
+ * @default true
1014
+ */
1015
+ shouldStretchDrawer?: boolean;
1016
+ }
1017
+ export interface OptionsSideMenu {
1018
+ /**
1019
+ * Configure the left side menu
1020
+ */
1021
+ left?: SideMenuSide;
1022
+ /**
1023
+ * Configure the right side menu
1024
+ */
1025
+ right?: SideMenuSide;
1026
+ /**
1027
+ * Configure how a user is allowed to open a drawer using gestures
1028
+ * #### (iOS specific)
1029
+ * @default 'entireScreen'
1030
+ */
1031
+ openGestureMode?: "entireScreen" | "bezel";
1032
+ }
1033
+ export interface OverlayOptions {
1034
+ /**
1035
+ * Capture touches outside of the Component View
1036
+ */
1037
+ interceptTouchOutside?: boolean;
1038
+ /**
1039
+ * Control whether this Overlay should handle Keyboard events.
1040
+ * Set this to true if your Overlay contains a TextInput.
1041
+ */
1042
+ handleKeyboardEvents?: boolean;
1043
+ }
1044
+ export interface ModalOptions {
1045
+ /**
1046
+ * Control whether this modal should be dismiss using swipe gesture when the
1047
+ * modalPresentationStyle = 'pageSheet' #### (iOS specific)
1048
+ */
1049
+ swipeToDismiss?: boolean;
1050
+ }
1051
+ export interface OptionsPreviewAction {
1052
+ /**
1053
+ * Reference ID to get callbacks from
1054
+ */
1055
+ id: string;
1056
+ /**
1057
+ * Action text
1058
+ */
1059
+ title: string;
1060
+ /**
1061
+ * Action style
1062
+ */
1063
+ style?: "default" | "selected" | "destructive";
1064
+ /**
1065
+ * Subactions that will be shown when this action is pressed.
1066
+ */
1067
+ actions?: OptionsPreviewAction[];
1068
+ }
1069
+ export interface OptionsPreview {
1070
+ /**
1071
+ * Pass a react node tag to mark a SourceRect for a specific
1072
+ * peek and pop preview element.
1073
+ */
1074
+ reactTag?: number;
1075
+ /**
1076
+ * You can set this property specify the width of the preview.
1077
+ * If the width is greater than the device width, it will be zoomed in.
1078
+ */
1079
+ width?: number;
1080
+ /**
1081
+ * Height of the preview
1082
+ */
1083
+ height?: 100;
1084
+ /**
1085
+ * You can control if the users gesture will result in pushing
1086
+ * the preview screen into the stack.
1087
+ */
1088
+ commit?: boolean;
1089
+ /**
1090
+ * List of actions that will appear underneath the preview window.
1091
+ * They can be nested for sub actions.
1092
+ */
1093
+ actions?: OptionsPreviewAction[];
1094
+ }
1095
+ export interface OptionsAnimationPropertyConfig {
1096
+ /**
1097
+ * Animate from this value, ex. 0
1098
+ */
1099
+ from?: number;
1100
+ /**
1101
+ * Animate to this value, ex. 1
1102
+ */
1103
+ to?: number;
1104
+ /**
1105
+ * Animation duration
1106
+ * @default 300
1107
+ */
1108
+ duration?: number;
1109
+ /**
1110
+ * Animation delay
1111
+ * @default 0
1112
+ */
1113
+ startDelay?: number;
1114
+ /**
1115
+ * Animation interplation
1116
+ */
1117
+ interpolation?: "accelerate" | "decelerate";
1118
+ }
1119
+ /**
1120
+ * Used to animate the actual content added to the hierarchy.
1121
+ * Content can be a React component (component) or any other layout (Stack, BottomTabs etc)
1122
+ */
1123
+ export interface ScreenAnimationOptions {
1124
+ /**
1125
+ * Animate the element over x value
1126
+ */
1127
+ x?: OptionsAnimationPropertyConfig;
1128
+ /**
1129
+ * Animate the element over y value
1130
+ */
1131
+ y?: OptionsAnimationPropertyConfig;
1132
+ /**
1133
+ * Animate the element over translateX
1134
+ */
1135
+ translationX?: OptionsAnimationPropertyConfig;
1136
+ /**
1137
+ * Animate the element over translateY
1138
+ */
1139
+ translationY?: OptionsAnimationPropertyConfig;
1140
+ /**
1141
+ * Animate the element over opacity
1142
+ */
1143
+ alpha?: OptionsAnimationPropertyConfig;
1144
+ /**
1145
+ * Animate the element over scaleX
1146
+ */
1147
+ scaleX?: OptionsAnimationPropertyConfig;
1148
+ /**
1149
+ * Animate the element over scaleY
1150
+ */
1151
+ scaleY?: OptionsAnimationPropertyConfig;
1152
+ /**
1153
+ * Animate the element over rotationX
1154
+ */
1155
+ rotationX?: OptionsAnimationPropertyConfig;
1156
+ /**
1157
+ * Animate the element over rotationY
1158
+ */
1159
+ rotationY?: OptionsAnimationPropertyConfig;
1160
+ /**
1161
+ * Animate the element over rotation
1162
+ */
1163
+ rotation?: OptionsAnimationPropertyConfig;
1164
+ /**
1165
+ * Wait for the root view to render before start animation
1166
+ */
1167
+ waitForRender?: boolean;
1168
+ /**
1169
+ * Enable or disable the animation
1170
+ * @default true
1171
+ */
1172
+ enabled?: boolean;
1173
+ }
1174
+ export interface IconInsets {
1175
+ /**
1176
+ * Configure top inset
1177
+ */
1178
+ top?: number;
1179
+ /**
1180
+ * Configure left inset
1181
+ */
1182
+ left?: number;
1183
+ /**
1184
+ * Configure bottom inset
1185
+ */
1186
+ bottom?: number;
1187
+ /**
1188
+ * Configure right inset
1189
+ */
1190
+ right?: number;
1191
+ }
1192
+ export interface ViewAnimationOptions extends ScreenAnimationOptions {
1193
+ /**
1194
+ * ID of the Top Bar we want to animate
1195
+ */
1196
+ id?: string;
1197
+ }
1198
+ /**
1199
+ * Used for describing stack commands animations.
1200
+ */
1201
+ export interface StackAnimationOptions {
1202
+ /**
1203
+ * Wait for the View to render before start animation
1204
+ */
1205
+ waitForRender?: boolean;
1206
+ /**
1207
+ * Enable or disable the animation
1208
+ * @default true
1209
+ */
1210
+ enabled?: boolean;
1211
+ /**
1212
+ * Configure animations for the top bar
1213
+ */
1214
+ topBar?: ViewAnimationOptions;
1215
+ /**
1216
+ * Configure animations for the bottom tabs
1217
+ */
1218
+ bottomTabs?: ViewAnimationOptions;
1219
+ /**
1220
+ * Configure animations for the content (Screen)
1221
+ */
1222
+ content?: ViewAnimationOptions;
1223
+ /**
1224
+ * Animations to be applied on elements which are shared between the appearing and disappearing
1225
+ * screens
1226
+ */
1227
+ sharedElementTransitions?: SharedElementTransition[];
1228
+ /**
1229
+ * Animations to be applied on views in the appearing or disappearing screens
1230
+ */
1231
+ elementTransitions?: ElementTransition[];
1232
+ }
1233
+ /**
1234
+ * Used for configuring command animations
1235
+ */
1236
+ export interface AnimationOptions {
1237
+ /**
1238
+ * Configure the setStackRoot animation
1239
+ */
1240
+ setStackRoot?: ViewAnimationOptions;
1241
+ /**
1242
+ * Configure the setRoot animation
1243
+ */
1244
+ setRoot?: ViewAnimationOptions;
1245
+ /**
1246
+ * Configure what animates when a screen is pushed
1247
+ */
1248
+ push?: StackAnimationOptions;
1249
+ /**
1250
+ * Configure what animates when a screen is popped
1251
+ */
1252
+ pop?: StackAnimationOptions;
1253
+ /**
1254
+ * Configure what animates when modal is shown
1255
+ */
1256
+ showModal?: ViewAnimationOptions;
1257
+ /**
1258
+ * Configure what animates when modal is dismissed
1259
+ */
1260
+ dismissModal?: ViewAnimationOptions;
1261
+ }
1262
+ /**
1263
+ * Configure Android's NavigationBar
1264
+ */
1265
+ export interface NavigationBarOptions {
1266
+ backgroundColor?: Color;
1267
+ visible?: boolean;
1268
+ }
1269
+ export interface Options {
1270
+ /**
1271
+ * Configure the status bar
1272
+ */
1273
+ statusBar?: OptionsStatusBar;
1274
+ /**
1275
+ * Configure the layout
1276
+ */
1277
+ layout?: OptionsLayout;
1278
+ /**
1279
+ * Configure the presentation style of the modal
1280
+ */
1281
+ modalPresentationStyle?: OptionsModalPresentationStyle;
1282
+ /**
1283
+ * Configure the transition style of the modal
1284
+ *
1285
+ * #### (Android specific)
1286
+ */
1287
+ modalTransitionStyle?: OptionsModalTransitionStyle;
1288
+ /**
1289
+ * Configure the top bar
1290
+ */
1291
+ topBar?: OptionsTopBar;
1292
+ fab?: OptionsFab;
1293
+ /**
1294
+ * Configure the bottom tabs
1295
+ */
1296
+ bottomTabs?: OptionsBottomTabs;
1297
+ /**
1298
+ * Configure the bottom tab associated to the screen
1299
+ */
1300
+ bottomTab?: OptionsBottomTab;
1301
+ /**
1302
+ * Configure the side menu
1303
+ */
1304
+ sideMenu?: OptionsSideMenu;
1305
+ /**
1306
+ * Configure the splitView controller
1307
+ */
1308
+ splitView?: OptionsSplitView;
1309
+ /**
1310
+ * Configure the overlay
1311
+ */
1312
+ overlay?: OverlayOptions;
1313
+ /**
1314
+ * Configure the modal
1315
+ */
1316
+ modal?: ModalOptions;
1317
+ /**
1318
+ * Animation used for navigation commands that modify the layout
1319
+ * hierarchy can be controlled in options.
1320
+ *
1321
+ * Animations can be modified per command and it's also possible
1322
+ * to change the default animation for each command.
1323
+ *
1324
+ * Example:
1325
+ ```js
1326
+ setRoot: {
1327
+ y: {
1328
+ from: 1000,
1329
+ to: 0,
1330
+ duration: 500,
1331
+ interpolation: 'accelerate',
1332
+ },
1333
+ alpha: {
1334
+ from: 0,
1335
+ to: 1,
1336
+ duration: 400,
1337
+ startDelay: 100,
1338
+ interpolation: 'accelerate'
1339
+ }
1340
+ }
1341
+ ```
1342
+ */
1343
+ animations?: AnimationOptions;
1344
+ /**
1345
+ * Configure Android's NavigationBar
1346
+ */
1347
+ navigationBar?: NavigationBarOptions;
1348
+ /**
1349
+ * Preview configuration for Peek and Pop
1350
+ * #### (iOS specific)
1351
+ */
1352
+ preview?: OptionsPreview;
1353
+ /**
1354
+ * Enable or disable swipe back to pop gesture
1355
+ * #### (iOS specific)
1356
+ * @default true
1357
+ */
1358
+ popGesture?: boolean;
1359
+ /**
1360
+ * Background image for the screen
1361
+ * #### (iOS specific)
1362
+ */
1363
+ backgroundImage?: ImageRequireSource;
1364
+ /**
1365
+ * Background image for the Navigation View
1366
+ * #### (iOS specific)
1367
+ */
1368
+ rootBackgroundImage?: ImageRequireSource;
1369
+ /**
1370
+ * Enable or disable automatically blurring focused input, dismissing keyboard on unmount
1371
+ * #### (Android specific)
1372
+ * @default false
1373
+ */
1374
+ blurOnUnmount?: boolean;
1375
+ }