@metamask/design-system-react-native 0.26.0 → 0.28.0

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 (505) hide show
  1. package/CHANGELOG.md +38 -1
  2. package/dist/components/ActionListItem/ActionListItem.cjs +1 -1
  3. package/dist/components/ActionListItem/ActionListItem.cjs.map +1 -1
  4. package/dist/components/ActionListItem/ActionListItem.mjs +1 -1
  5. package/dist/components/ActionListItem/ActionListItem.mjs.map +1 -1
  6. package/dist/components/ActionListItem/ActionListItem.types.d.cts +1 -1
  7. package/dist/components/ActionListItem/ActionListItem.types.d.cts.map +1 -1
  8. package/dist/components/ActionListItem/ActionListItem.types.d.mts +1 -1
  9. package/dist/components/ActionListItem/ActionListItem.types.d.mts.map +1 -1
  10. package/dist/components/AvatarBase/AvatarBase.cjs +2 -2
  11. package/dist/components/AvatarBase/AvatarBase.cjs.map +1 -1
  12. package/dist/components/AvatarBase/AvatarBase.mjs +2 -2
  13. package/dist/components/AvatarBase/AvatarBase.mjs.map +1 -1
  14. package/dist/components/AvatarBase/AvatarBase.types.d.cts +1 -1
  15. package/dist/components/AvatarBase/AvatarBase.types.d.cts.map +1 -1
  16. package/dist/components/AvatarBase/AvatarBase.types.d.mts +1 -1
  17. package/dist/components/AvatarBase/AvatarBase.types.d.mts.map +1 -1
  18. package/dist/components/AvatarFavicon/AvatarFavicon.cjs +2 -2
  19. package/dist/components/AvatarFavicon/AvatarFavicon.cjs.map +1 -1
  20. package/dist/components/AvatarFavicon/AvatarFavicon.d.cts.map +1 -1
  21. package/dist/components/AvatarFavicon/AvatarFavicon.d.mts.map +1 -1
  22. package/dist/components/AvatarFavicon/AvatarFavicon.mjs +2 -2
  23. package/dist/components/AvatarFavicon/AvatarFavicon.mjs.map +1 -1
  24. package/dist/components/AvatarGroup/AvatarGroup.cjs +1 -1
  25. package/dist/components/AvatarGroup/AvatarGroup.cjs.map +1 -1
  26. package/dist/components/AvatarGroup/AvatarGroup.mjs +1 -1
  27. package/dist/components/AvatarGroup/AvatarGroup.mjs.map +1 -1
  28. package/dist/components/AvatarGroup/AvatarGroup.types.d.cts +1 -1
  29. package/dist/components/AvatarGroup/AvatarGroup.types.d.cts.map +1 -1
  30. package/dist/components/AvatarGroup/AvatarGroup.types.d.mts +1 -1
  31. package/dist/components/AvatarGroup/AvatarGroup.types.d.mts.map +1 -1
  32. package/dist/components/AvatarNetwork/AvatarNetwork.cjs +2 -2
  33. package/dist/components/AvatarNetwork/AvatarNetwork.cjs.map +1 -1
  34. package/dist/components/AvatarNetwork/AvatarNetwork.d.cts.map +1 -1
  35. package/dist/components/AvatarNetwork/AvatarNetwork.d.mts.map +1 -1
  36. package/dist/components/AvatarNetwork/AvatarNetwork.mjs +2 -2
  37. package/dist/components/AvatarNetwork/AvatarNetwork.mjs.map +1 -1
  38. package/dist/components/AvatarToken/AvatarToken.cjs +2 -2
  39. package/dist/components/AvatarToken/AvatarToken.cjs.map +1 -1
  40. package/dist/components/AvatarToken/AvatarToken.d.cts.map +1 -1
  41. package/dist/components/AvatarToken/AvatarToken.d.mts.map +1 -1
  42. package/dist/components/AvatarToken/AvatarToken.mjs +2 -2
  43. package/dist/components/AvatarToken/AvatarToken.mjs.map +1 -1
  44. package/dist/components/BadgeCount/BadgeCount.cjs +1 -1
  45. package/dist/components/BadgeCount/BadgeCount.cjs.map +1 -1
  46. package/dist/components/BadgeCount/BadgeCount.mjs +1 -1
  47. package/dist/components/BadgeCount/BadgeCount.mjs.map +1 -1
  48. package/dist/components/BadgeCount/BadgeCount.types.d.cts +1 -1
  49. package/dist/components/BadgeCount/BadgeCount.types.d.cts.map +1 -1
  50. package/dist/components/BadgeCount/BadgeCount.types.d.mts +1 -1
  51. package/dist/components/BadgeCount/BadgeCount.types.d.mts.map +1 -1
  52. package/dist/components/BadgeIcon/BadgeIcon.cjs +1 -1
  53. package/dist/components/BadgeIcon/BadgeIcon.cjs.map +1 -1
  54. package/dist/components/BadgeIcon/BadgeIcon.mjs +1 -1
  55. package/dist/components/BadgeIcon/BadgeIcon.mjs.map +1 -1
  56. package/dist/components/BadgeIcon/BadgeIcon.types.d.cts +1 -1
  57. package/dist/components/BadgeIcon/BadgeIcon.types.d.cts.map +1 -1
  58. package/dist/components/BadgeIcon/BadgeIcon.types.d.mts +1 -1
  59. package/dist/components/BadgeIcon/BadgeIcon.types.d.mts.map +1 -1
  60. package/dist/components/BadgeStatus/BadgeStatus.cjs +1 -1
  61. package/dist/components/BadgeStatus/BadgeStatus.cjs.map +1 -1
  62. package/dist/components/BadgeStatus/BadgeStatus.mjs +1 -1
  63. package/dist/components/BadgeStatus/BadgeStatus.mjs.map +1 -1
  64. package/dist/components/BadgeStatus/BadgeStatus.types.d.cts +1 -1
  65. package/dist/components/BadgeStatus/BadgeStatus.types.d.cts.map +1 -1
  66. package/dist/components/BadgeStatus/BadgeStatus.types.d.mts +1 -1
  67. package/dist/components/BadgeStatus/BadgeStatus.types.d.mts.map +1 -1
  68. package/dist/components/BadgeWrapper/BadgeWrapper.cjs +1 -1
  69. package/dist/components/BadgeWrapper/BadgeWrapper.cjs.map +1 -1
  70. package/dist/components/BadgeWrapper/BadgeWrapper.mjs +1 -1
  71. package/dist/components/BadgeWrapper/BadgeWrapper.mjs.map +1 -1
  72. package/dist/components/BadgeWrapper/BadgeWrapper.types.d.cts +1 -1
  73. package/dist/components/BadgeWrapper/BadgeWrapper.types.d.cts.map +1 -1
  74. package/dist/components/BadgeWrapper/BadgeWrapper.types.d.mts +1 -1
  75. package/dist/components/BadgeWrapper/BadgeWrapper.types.d.mts.map +1 -1
  76. package/dist/components/BannerBase/BannerBase.types.d.cts +1 -1
  77. package/dist/components/BannerBase/BannerBase.types.d.cts.map +1 -1
  78. package/dist/components/BannerBase/BannerBase.types.d.mts +1 -1
  79. package/dist/components/BannerBase/BannerBase.types.d.mts.map +1 -1
  80. package/dist/components/BottomSheet/BottomSheet.cjs +9 -6
  81. package/dist/components/BottomSheet/BottomSheet.cjs.map +1 -1
  82. package/dist/components/BottomSheet/BottomSheet.d.cts +0 -35
  83. package/dist/components/BottomSheet/BottomSheet.d.cts.map +1 -1
  84. package/dist/components/BottomSheet/BottomSheet.d.mts +0 -35
  85. package/dist/components/BottomSheet/BottomSheet.d.mts.map +1 -1
  86. package/dist/components/BottomSheet/BottomSheet.mjs +9 -6
  87. package/dist/components/BottomSheet/BottomSheet.mjs.map +1 -1
  88. package/dist/components/BottomSheetDialog/BottomSheetDialog.cjs +28 -17
  89. package/dist/components/BottomSheetDialog/BottomSheetDialog.cjs.map +1 -1
  90. package/dist/components/BottomSheetDialog/BottomSheetDialog.d.cts +0 -35
  91. package/dist/components/BottomSheetDialog/BottomSheetDialog.d.cts.map +1 -1
  92. package/dist/components/BottomSheetDialog/BottomSheetDialog.d.mts +0 -35
  93. package/dist/components/BottomSheetDialog/BottomSheetDialog.d.mts.map +1 -1
  94. package/dist/components/BottomSheetDialog/BottomSheetDialog.mjs +30 -19
  95. package/dist/components/BottomSheetDialog/BottomSheetDialog.mjs.map +1 -1
  96. package/dist/components/BottomSheetDialog/BottomSheetDialog.types.cjs.map +1 -1
  97. package/dist/components/BottomSheetDialog/BottomSheetDialog.types.d.cts +1 -9
  98. package/dist/components/BottomSheetDialog/BottomSheetDialog.types.d.cts.map +1 -1
  99. package/dist/components/BottomSheetDialog/BottomSheetDialog.types.d.mts +1 -9
  100. package/dist/components/BottomSheetDialog/BottomSheetDialog.types.d.mts.map +1 -1
  101. package/dist/components/BottomSheetDialog/BottomSheetDialog.types.mjs.map +1 -1
  102. package/dist/components/BottomSheetFooter/BottomSheetFooter.cjs +1 -1
  103. package/dist/components/BottomSheetFooter/BottomSheetFooter.cjs.map +1 -1
  104. package/dist/components/BottomSheetFooter/BottomSheetFooter.mjs +1 -1
  105. package/dist/components/BottomSheetFooter/BottomSheetFooter.mjs.map +1 -1
  106. package/dist/components/BottomSheetFooter/BottomSheetFooter.types.d.cts +1 -1
  107. package/dist/components/BottomSheetFooter/BottomSheetFooter.types.d.cts.map +1 -1
  108. package/dist/components/BottomSheetFooter/BottomSheetFooter.types.d.mts +1 -1
  109. package/dist/components/BottomSheetFooter/BottomSheetFooter.types.d.mts.map +1 -1
  110. package/dist/components/BottomSheetHeader/BottomSheetHeader.cjs +2 -6
  111. package/dist/components/BottomSheetHeader/BottomSheetHeader.cjs.map +1 -1
  112. package/dist/components/BottomSheetHeader/BottomSheetHeader.d.cts.map +1 -1
  113. package/dist/components/BottomSheetHeader/BottomSheetHeader.d.mts.map +1 -1
  114. package/dist/components/BottomSheetHeader/BottomSheetHeader.mjs +2 -6
  115. package/dist/components/BottomSheetHeader/BottomSheetHeader.mjs.map +1 -1
  116. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.cjs +0 -11
  117. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.cjs.map +1 -1
  118. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.d.cts +6 -20
  119. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.d.cts.map +1 -1
  120. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.d.mts +6 -20
  121. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.d.mts.map +1 -1
  122. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.mjs +1 -10
  123. package/dist/components/BottomSheetHeader/BottomSheetHeader.types.mjs.map +1 -1
  124. package/dist/components/BottomSheetHeader/index.cjs +1 -3
  125. package/dist/components/BottomSheetHeader/index.cjs.map +1 -1
  126. package/dist/components/BottomSheetHeader/index.d.cts +0 -1
  127. package/dist/components/BottomSheetHeader/index.d.cts.map +1 -1
  128. package/dist/components/BottomSheetHeader/index.d.mts +0 -1
  129. package/dist/components/BottomSheetHeader/index.d.mts.map +1 -1
  130. package/dist/components/BottomSheetHeader/index.mjs +0 -1
  131. package/dist/components/BottomSheetHeader/index.mjs.map +1 -1
  132. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.cjs +2 -2
  133. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.cjs.map +1 -1
  134. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.d.cts.map +1 -1
  135. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.d.mts.map +1 -1
  136. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.mjs +3 -3
  137. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.mjs.map +1 -1
  138. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.types.d.cts +1 -1
  139. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.types.d.cts.map +1 -1
  140. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.types.d.mts +1 -1
  141. package/dist/components/BottomSheetOverlay/BottomSheetOverlay.types.d.mts.map +1 -1
  142. package/dist/components/Box/Box.cjs +1 -1
  143. package/dist/components/Box/Box.cjs.map +1 -1
  144. package/dist/components/Box/Box.d.cts +1 -1
  145. package/dist/components/Box/Box.d.cts.map +1 -1
  146. package/dist/components/Box/Box.d.mts +1 -1
  147. package/dist/components/Box/Box.d.mts.map +1 -1
  148. package/dist/components/Box/Box.mjs +1 -1
  149. package/dist/components/Box/Box.mjs.map +1 -1
  150. package/dist/components/Box/Box.types.d.cts +1 -1
  151. package/dist/components/Box/Box.types.d.cts.map +1 -1
  152. package/dist/components/Box/Box.types.d.mts +1 -1
  153. package/dist/components/Box/Box.types.d.mts.map +1 -1
  154. package/dist/components/ButtonBase/ButtonBase.types.d.cts +1 -2
  155. package/dist/components/ButtonBase/ButtonBase.types.d.cts.map +1 -1
  156. package/dist/components/ButtonBase/ButtonBase.types.d.mts +1 -2
  157. package/dist/components/ButtonBase/ButtonBase.types.d.mts.map +1 -1
  158. package/dist/components/ButtonIcon/ButtonIcon.types.d.cts +1 -1
  159. package/dist/components/ButtonIcon/ButtonIcon.types.d.cts.map +1 -1
  160. package/dist/components/ButtonIcon/ButtonIcon.types.d.mts +1 -1
  161. package/dist/components/ButtonIcon/ButtonIcon.types.d.mts.map +1 -1
  162. package/dist/components/Card/Card.cjs +2 -2
  163. package/dist/components/Card/Card.cjs.map +1 -1
  164. package/dist/components/Card/Card.mjs +2 -2
  165. package/dist/components/Card/Card.mjs.map +1 -1
  166. package/dist/components/Card/Card.types.cjs.map +1 -1
  167. package/dist/components/Card/Card.types.d.cts +2 -2
  168. package/dist/components/Card/Card.types.d.cts.map +1 -1
  169. package/dist/components/Card/Card.types.d.mts +2 -2
  170. package/dist/components/Card/Card.types.d.mts.map +1 -1
  171. package/dist/components/Card/Card.types.mjs.map +1 -1
  172. package/dist/components/Checkbox/Checkbox.cjs +1 -1
  173. package/dist/components/Checkbox/Checkbox.cjs.map +1 -1
  174. package/dist/components/Checkbox/Checkbox.d.cts +1 -1
  175. package/dist/components/Checkbox/Checkbox.d.cts.map +1 -1
  176. package/dist/components/Checkbox/Checkbox.d.mts +1 -1
  177. package/dist/components/Checkbox/Checkbox.d.mts.map +1 -1
  178. package/dist/components/Checkbox/Checkbox.mjs +1 -1
  179. package/dist/components/Checkbox/Checkbox.mjs.map +1 -1
  180. package/dist/components/Checkbox/Checkbox.types.d.cts +1 -1
  181. package/dist/components/Checkbox/Checkbox.types.d.cts.map +1 -1
  182. package/dist/components/Checkbox/Checkbox.types.d.mts +1 -1
  183. package/dist/components/Checkbox/Checkbox.types.d.mts.map +1 -1
  184. package/dist/components/Content/Content.cjs +71 -0
  185. package/dist/components/Content/Content.cjs.map +1 -0
  186. package/dist/components/Content/Content.constants.cjs +9 -0
  187. package/dist/components/Content/Content.constants.cjs.map +1 -0
  188. package/dist/components/Content/Content.constants.d.cts +3 -0
  189. package/dist/components/Content/Content.constants.d.cts.map +1 -0
  190. package/dist/components/Content/Content.constants.d.mts +3 -0
  191. package/dist/components/Content/Content.constants.d.mts.map +1 -0
  192. package/dist/components/Content/Content.constants.mjs +6 -0
  193. package/dist/components/Content/Content.constants.mjs.map +1 -0
  194. package/dist/components/Content/Content.d.cts +4 -0
  195. package/dist/components/Content/Content.d.cts.map +1 -0
  196. package/dist/components/Content/Content.d.mts +4 -0
  197. package/dist/components/Content/Content.d.mts.map +1 -0
  198. package/dist/components/Content/Content.mjs +71 -0
  199. package/dist/components/Content/Content.mjs.map +1 -0
  200. package/dist/components/Content/Content.types.cjs +3 -0
  201. package/dist/components/Content/Content.types.cjs.map +1 -0
  202. package/dist/components/Content/Content.types.d.cts +31 -0
  203. package/dist/components/Content/Content.types.d.cts.map +1 -0
  204. package/dist/components/Content/Content.types.d.mts +31 -0
  205. package/dist/components/Content/Content.types.d.mts.map +1 -0
  206. package/dist/components/Content/Content.types.mjs +2 -0
  207. package/dist/components/Content/Content.types.mjs.map +1 -0
  208. package/dist/components/Content/index.cjs +8 -0
  209. package/dist/components/Content/index.cjs.map +1 -0
  210. package/dist/components/Content/index.d.cts +4 -0
  211. package/dist/components/Content/index.d.cts.map +1 -0
  212. package/dist/components/Content/index.d.mts +4 -0
  213. package/dist/components/Content/index.d.mts.map +1 -0
  214. package/dist/components/Content/index.mjs +3 -0
  215. package/dist/components/Content/index.mjs.map +1 -0
  216. package/dist/components/HeaderBase/HeaderBase.cjs +94 -73
  217. package/dist/components/HeaderBase/HeaderBase.cjs.map +1 -1
  218. package/dist/components/HeaderBase/HeaderBase.d.cts.map +1 -1
  219. package/dist/components/HeaderBase/HeaderBase.d.mts.map +1 -1
  220. package/dist/components/HeaderBase/HeaderBase.mjs +94 -73
  221. package/dist/components/HeaderBase/HeaderBase.mjs.map +1 -1
  222. package/dist/components/HeaderBase/HeaderBase.types.cjs +0 -12
  223. package/dist/components/HeaderBase/HeaderBase.types.cjs.map +1 -1
  224. package/dist/components/HeaderBase/HeaderBase.types.d.cts +12 -20
  225. package/dist/components/HeaderBase/HeaderBase.types.d.cts.map +1 -1
  226. package/dist/components/HeaderBase/HeaderBase.types.d.mts +12 -20
  227. package/dist/components/HeaderBase/HeaderBase.types.d.mts.map +1 -1
  228. package/dist/components/HeaderBase/HeaderBase.types.mjs +1 -11
  229. package/dist/components/HeaderBase/HeaderBase.types.mjs.map +1 -1
  230. package/dist/components/HeaderBase/index.cjs +1 -3
  231. package/dist/components/HeaderBase/index.cjs.map +1 -1
  232. package/dist/components/HeaderBase/index.d.cts +0 -1
  233. package/dist/components/HeaderBase/index.d.cts.map +1 -1
  234. package/dist/components/HeaderBase/index.d.mts +0 -1
  235. package/dist/components/HeaderBase/index.d.mts.map +1 -1
  236. package/dist/components/HeaderBase/index.mjs +0 -1
  237. package/dist/components/HeaderBase/index.mjs.map +1 -1
  238. package/dist/components/HeaderRoot/HeaderRoot.types.d.cts +1 -1
  239. package/dist/components/HeaderRoot/HeaderRoot.types.d.cts.map +1 -1
  240. package/dist/components/HeaderRoot/HeaderRoot.types.d.mts +1 -1
  241. package/dist/components/HeaderRoot/HeaderRoot.types.d.mts.map +1 -1
  242. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.cjs +4 -12
  243. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.cjs.map +1 -1
  244. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.d.cts +0 -8
  245. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.d.cts.map +1 -1
  246. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.d.mts +0 -8
  247. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.d.mts.map +1 -1
  248. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.mjs +3 -10
  249. package/dist/components/HeaderStandardAnimated/useHeaderStandardAnimated.mjs.map +1 -1
  250. package/dist/components/Icon/Icon.assets.cjs +2 -0
  251. package/dist/components/Icon/Icon.assets.cjs.map +1 -1
  252. package/dist/components/Icon/Icon.assets.d.cts.map +1 -1
  253. package/dist/components/Icon/Icon.assets.d.mts.map +1 -1
  254. package/dist/components/Icon/Icon.assets.mjs +2 -0
  255. package/dist/components/Icon/Icon.assets.mjs.map +1 -1
  256. package/dist/components/Icon/Icon.cjs +3 -1
  257. package/dist/components/Icon/Icon.cjs.map +1 -1
  258. package/dist/components/Icon/Icon.d.cts.map +1 -1
  259. package/dist/components/Icon/Icon.d.mts.map +1 -1
  260. package/dist/components/Icon/Icon.mjs +3 -1
  261. package/dist/components/Icon/Icon.mjs.map +1 -1
  262. package/dist/components/Icon/assets/flash-filled.svg +1 -0
  263. package/dist/components/Input/Input.cjs +1 -1
  264. package/dist/components/Input/Input.cjs.map +1 -1
  265. package/dist/components/Input/Input.d.cts +1 -2
  266. package/dist/components/Input/Input.d.cts.map +1 -1
  267. package/dist/components/Input/Input.d.mts +1 -2
  268. package/dist/components/Input/Input.d.mts.map +1 -1
  269. package/dist/components/Input/Input.mjs +1 -1
  270. package/dist/components/Input/Input.mjs.map +1 -1
  271. package/dist/components/Input/Input.types.d.cts +1 -1
  272. package/dist/components/Input/Input.types.d.cts.map +1 -1
  273. package/dist/components/Input/Input.types.d.mts +1 -1
  274. package/dist/components/Input/Input.types.d.mts.map +1 -1
  275. package/dist/components/KeyValueColumn/KeyValueColumn.types.d.cts +1 -1
  276. package/dist/components/KeyValueColumn/KeyValueColumn.types.d.cts.map +1 -1
  277. package/dist/components/KeyValueColumn/KeyValueColumn.types.d.mts +1 -1
  278. package/dist/components/KeyValueColumn/KeyValueColumn.types.d.mts.map +1 -1
  279. package/dist/components/KeyValueRow/KeyValueRow.types.d.cts +1 -1
  280. package/dist/components/KeyValueRow/KeyValueRow.types.d.cts.map +1 -1
  281. package/dist/components/KeyValueRow/KeyValueRow.types.d.mts +1 -1
  282. package/dist/components/KeyValueRow/KeyValueRow.types.d.mts.map +1 -1
  283. package/dist/components/ListItem/ListItem.cjs +1 -1
  284. package/dist/components/ListItem/ListItem.cjs.map +1 -1
  285. package/dist/components/ListItem/ListItem.mjs +1 -1
  286. package/dist/components/ListItem/ListItem.mjs.map +1 -1
  287. package/dist/components/ListItem/ListItem.types.d.cts +1 -1
  288. package/dist/components/ListItem/ListItem.types.d.cts.map +1 -1
  289. package/dist/components/ListItem/ListItem.types.d.mts +1 -1
  290. package/dist/components/ListItem/ListItem.types.d.mts.map +1 -1
  291. package/dist/components/MainActionButton/MainActionButton.types.d.cts +1 -1
  292. package/dist/components/MainActionButton/MainActionButton.types.d.cts.map +1 -1
  293. package/dist/components/MainActionButton/MainActionButton.types.d.mts +1 -1
  294. package/dist/components/MainActionButton/MainActionButton.types.d.mts.map +1 -1
  295. package/dist/components/RadioButton/RadioButton.cjs +1 -1
  296. package/dist/components/RadioButton/RadioButton.cjs.map +1 -1
  297. package/dist/components/RadioButton/RadioButton.mjs +1 -1
  298. package/dist/components/RadioButton/RadioButton.mjs.map +1 -1
  299. package/dist/components/RadioButton/RadioButton.types.d.cts +1 -2
  300. package/dist/components/RadioButton/RadioButton.types.d.cts.map +1 -1
  301. package/dist/components/RadioButton/RadioButton.types.d.mts +1 -2
  302. package/dist/components/RadioButton/RadioButton.types.d.mts.map +1 -1
  303. package/dist/components/SectionDivider/SectionDivider.d.cts +1 -1
  304. package/dist/components/SectionDivider/SectionDivider.d.cts.map +1 -1
  305. package/dist/components/SectionDivider/SectionDivider.d.mts +1 -1
  306. package/dist/components/SectionDivider/SectionDivider.d.mts.map +1 -1
  307. package/dist/components/SectionHeader/SectionHeader.cjs +47 -24
  308. package/dist/components/SectionHeader/SectionHeader.cjs.map +1 -1
  309. package/dist/components/SectionHeader/SectionHeader.d.cts +16 -13
  310. package/dist/components/SectionHeader/SectionHeader.d.cts.map +1 -1
  311. package/dist/components/SectionHeader/SectionHeader.d.mts +16 -13
  312. package/dist/components/SectionHeader/SectionHeader.d.mts.map +1 -1
  313. package/dist/components/SectionHeader/SectionHeader.mjs +48 -25
  314. package/dist/components/SectionHeader/SectionHeader.mjs.map +1 -1
  315. package/dist/components/SectionHeader/SectionHeader.types.cjs.map +1 -1
  316. package/dist/components/SectionHeader/SectionHeader.types.d.cts +16 -9
  317. package/dist/components/SectionHeader/SectionHeader.types.d.cts.map +1 -1
  318. package/dist/components/SectionHeader/SectionHeader.types.d.mts +16 -9
  319. package/dist/components/SectionHeader/SectionHeader.types.d.mts.map +1 -1
  320. package/dist/components/SectionHeader/SectionHeader.types.mjs.map +1 -1
  321. package/dist/components/SegmentGroup/SegmentGroup.cjs +5 -7
  322. package/dist/components/SegmentGroup/SegmentGroup.cjs.map +1 -1
  323. package/dist/components/SegmentGroup/SegmentGroup.d.cts.map +1 -1
  324. package/dist/components/SegmentGroup/SegmentGroup.d.mts.map +1 -1
  325. package/dist/components/SegmentGroup/SegmentGroup.mjs +6 -8
  326. package/dist/components/SegmentGroup/SegmentGroup.mjs.map +1 -1
  327. package/dist/components/SegmentGroup/SegmentGroup.types.d.cts +1 -1
  328. package/dist/components/SegmentGroup/SegmentGroup.types.d.cts.map +1 -1
  329. package/dist/components/SegmentGroup/SegmentGroup.types.d.mts +1 -1
  330. package/dist/components/SegmentGroup/SegmentGroup.types.d.mts.map +1 -1
  331. package/dist/components/SelectButton/SelectButton.cjs +1 -1
  332. package/dist/components/SelectButton/SelectButton.cjs.map +1 -1
  333. package/dist/components/SelectButton/SelectButton.mjs +2 -2
  334. package/dist/components/SelectButton/SelectButton.mjs.map +1 -1
  335. package/dist/components/SelectButton/SelectButton.types.cjs.map +1 -1
  336. package/dist/components/SelectButton/SelectButton.types.d.cts +1 -1
  337. package/dist/components/SelectButton/SelectButton.types.d.cts.map +1 -1
  338. package/dist/components/SelectButton/SelectButton.types.d.mts +1 -1
  339. package/dist/components/SelectButton/SelectButton.types.d.mts.map +1 -1
  340. package/dist/components/SelectButton/SelectButton.types.mjs.map +1 -1
  341. package/dist/components/SelectButton/index.cjs +2 -1
  342. package/dist/components/SelectButton/index.cjs.map +1 -1
  343. package/dist/components/SelectButton/index.d.cts +1 -1
  344. package/dist/components/SelectButton/index.d.cts.map +1 -1
  345. package/dist/components/SelectButton/index.d.mts +1 -1
  346. package/dist/components/SelectButton/index.d.mts.map +1 -1
  347. package/dist/components/SelectButton/index.mjs +1 -1
  348. package/dist/components/SelectButton/index.mjs.map +1 -1
  349. package/dist/components/Skeleton/Skeleton.cjs +1 -1
  350. package/dist/components/Skeleton/Skeleton.cjs.map +1 -1
  351. package/dist/components/Skeleton/Skeleton.mjs +1 -1
  352. package/dist/components/Skeleton/Skeleton.mjs.map +1 -1
  353. package/dist/components/Skeleton/Skeleton.types.d.cts +1 -1
  354. package/dist/components/Skeleton/Skeleton.types.d.cts.map +1 -1
  355. package/dist/components/Skeleton/Skeleton.types.d.mts +1 -1
  356. package/dist/components/Skeleton/Skeleton.types.d.mts.map +1 -1
  357. package/dist/components/TabEmptyState/TabEmptyState.types.d.cts +1 -1
  358. package/dist/components/TabEmptyState/TabEmptyState.types.d.cts.map +1 -1
  359. package/dist/components/TabEmptyState/TabEmptyState.types.d.mts +1 -1
  360. package/dist/components/TabEmptyState/TabEmptyState.types.d.mts.map +1 -1
  361. package/dist/components/Tag/Tag.types.d.cts +1 -1
  362. package/dist/components/Tag/Tag.types.d.cts.map +1 -1
  363. package/dist/components/Tag/Tag.types.d.mts +1 -1
  364. package/dist/components/Tag/Tag.types.d.mts.map +1 -1
  365. package/dist/components/Text/Text.cjs +1 -1
  366. package/dist/components/Text/Text.cjs.map +1 -1
  367. package/dist/components/Text/Text.mjs +1 -1
  368. package/dist/components/Text/Text.mjs.map +1 -1
  369. package/dist/components/Text/Text.types.d.cts +1 -1
  370. package/dist/components/Text/Text.types.d.cts.map +1 -1
  371. package/dist/components/Text/Text.types.d.mts +1 -1
  372. package/dist/components/Text/Text.types.d.mts.map +1 -1
  373. package/dist/components/TextArea/TextArea.cjs +4 -8
  374. package/dist/components/TextArea/TextArea.cjs.map +1 -1
  375. package/dist/components/TextArea/TextArea.d.cts +160 -161
  376. package/dist/components/TextArea/TextArea.d.cts.map +1 -1
  377. package/dist/components/TextArea/TextArea.d.mts +160 -161
  378. package/dist/components/TextArea/TextArea.d.mts.map +1 -1
  379. package/dist/components/TextArea/TextArea.mjs +4 -8
  380. package/dist/components/TextArea/TextArea.mjs.map +1 -1
  381. package/dist/components/TextArea/TextArea.types.cjs.map +1 -1
  382. package/dist/components/TextArea/TextArea.types.d.cts +12 -45
  383. package/dist/components/TextArea/TextArea.types.d.cts.map +1 -1
  384. package/dist/components/TextArea/TextArea.types.d.mts +12 -45
  385. package/dist/components/TextArea/TextArea.types.d.mts.map +1 -1
  386. package/dist/components/TextArea/TextArea.types.mjs.map +1 -1
  387. package/dist/components/TextButton/TextButton.types.d.cts +0 -1
  388. package/dist/components/TextButton/TextButton.types.d.cts.map +1 -1
  389. package/dist/components/TextButton/TextButton.types.d.mts +0 -1
  390. package/dist/components/TextButton/TextButton.types.d.mts.map +1 -1
  391. package/dist/components/TextField/TextField.cjs +1 -1
  392. package/dist/components/TextField/TextField.cjs.map +1 -1
  393. package/dist/components/TextField/TextField.d.cts +20 -16
  394. package/dist/components/TextField/TextField.d.cts.map +1 -1
  395. package/dist/components/TextField/TextField.d.mts +20 -16
  396. package/dist/components/TextField/TextField.d.mts.map +1 -1
  397. package/dist/components/TextField/TextField.mjs +1 -1
  398. package/dist/components/TextField/TextField.mjs.map +1 -1
  399. package/dist/components/TextField/TextField.types.d.cts +1 -1
  400. package/dist/components/TextField/TextField.types.d.cts.map +1 -1
  401. package/dist/components/TextField/TextField.types.d.mts +1 -1
  402. package/dist/components/TextField/TextField.types.d.mts.map +1 -1
  403. package/dist/components/TextFieldSearch/TextFieldSearch.d.cts +20 -15
  404. package/dist/components/TextFieldSearch/TextFieldSearch.d.cts.map +1 -1
  405. package/dist/components/TextFieldSearch/TextFieldSearch.d.mts +20 -15
  406. package/dist/components/TextFieldSearch/TextFieldSearch.d.mts.map +1 -1
  407. package/dist/components/TitleAlert/TitleAlert.types.d.cts +1 -1
  408. package/dist/components/TitleAlert/TitleAlert.types.d.cts.map +1 -1
  409. package/dist/components/TitleAlert/TitleAlert.types.d.mts +1 -1
  410. package/dist/components/TitleAlert/TitleAlert.types.d.mts.map +1 -1
  411. package/dist/components/TitleHub/TitleHub.types.d.cts +1 -1
  412. package/dist/components/TitleHub/TitleHub.types.d.cts.map +1 -1
  413. package/dist/components/TitleHub/TitleHub.types.d.mts +1 -1
  414. package/dist/components/TitleHub/TitleHub.types.d.mts.map +1 -1
  415. package/dist/components/TitleStandard/TitleStandard.types.d.cts +1 -1
  416. package/dist/components/TitleStandard/TitleStandard.types.d.cts.map +1 -1
  417. package/dist/components/TitleStandard/TitleStandard.types.d.mts +1 -1
  418. package/dist/components/TitleStandard/TitleStandard.types.d.mts.map +1 -1
  419. package/dist/components/TitleSubpage/TitleSubpage.types.d.cts +1 -1
  420. package/dist/components/TitleSubpage/TitleSubpage.types.d.cts.map +1 -1
  421. package/dist/components/TitleSubpage/TitleSubpage.types.d.mts +1 -1
  422. package/dist/components/TitleSubpage/TitleSubpage.types.d.mts.map +1 -1
  423. package/dist/components/Toast/Toast.types.d.cts +1 -1
  424. package/dist/components/Toast/Toast.types.d.cts.map +1 -1
  425. package/dist/components/Toast/Toast.types.d.mts +1 -1
  426. package/dist/components/Toast/Toast.types.d.mts.map +1 -1
  427. package/dist/components/Toast/Toaster.cjs +1 -1
  428. package/dist/components/Toast/Toaster.cjs.map +1 -1
  429. package/dist/components/Toast/Toaster.mjs +1 -1
  430. package/dist/components/Toast/Toaster.mjs.map +1 -1
  431. package/dist/components/index.cjs +7 -5
  432. package/dist/components/index.cjs.map +1 -1
  433. package/dist/components/index.d.cts +5 -3
  434. package/dist/components/index.d.cts.map +1 -1
  435. package/dist/components/index.d.mts +5 -3
  436. package/dist/components/index.d.mts.map +1 -1
  437. package/dist/components/index.mjs +4 -3
  438. package/dist/components/index.mjs.map +1 -1
  439. package/dist/components/temp-components/Blockies/Blockies.cjs +1 -1
  440. package/dist/components/temp-components/Blockies/Blockies.cjs.map +1 -1
  441. package/dist/components/temp-components/Blockies/Blockies.mjs +1 -1
  442. package/dist/components/temp-components/Blockies/Blockies.mjs.map +1 -1
  443. package/dist/components/temp-components/Blockies/Blockies.types.d.cts +1 -1
  444. package/dist/components/temp-components/Blockies/Blockies.types.d.cts.map +1 -1
  445. package/dist/components/temp-components/Blockies/Blockies.types.d.mts +1 -1
  446. package/dist/components/temp-components/Blockies/Blockies.types.d.mts.map +1 -1
  447. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.cjs +2 -2
  448. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.cjs.map +1 -1
  449. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.mjs +2 -2
  450. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.mjs.map +1 -1
  451. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.types.d.cts +1 -1
  452. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.types.d.cts.map +1 -1
  453. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.types.d.mts +1 -1
  454. package/dist/components/temp-components/ButtonAnimated/ButtonAnimated.types.d.mts.map +1 -1
  455. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.cjs +1 -1
  456. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.cjs.map +1 -1
  457. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.mjs +1 -1
  458. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.mjs.map +1 -1
  459. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.types.cjs.map +1 -1
  460. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.types.d.cts +2 -3
  461. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.types.d.cts.map +1 -1
  462. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.types.d.mts +2 -3
  463. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.types.d.mts.map +1 -1
  464. package/dist/components/temp-components/ImageOrSvg/ImageOrSvg.types.mjs.map +1 -1
  465. package/dist/components/temp-components/Jazzicon/Jazzicon.cjs +1 -1
  466. package/dist/components/temp-components/Jazzicon/Jazzicon.cjs.map +1 -1
  467. package/dist/components/temp-components/Jazzicon/Jazzicon.mjs +1 -1
  468. package/dist/components/temp-components/Jazzicon/Jazzicon.mjs.map +1 -1
  469. package/dist/components/temp-components/Maskicon/Maskicon.cjs +1 -1
  470. package/dist/components/temp-components/Maskicon/Maskicon.cjs.map +1 -1
  471. package/dist/components/temp-components/Maskicon/Maskicon.mjs +1 -1
  472. package/dist/components/temp-components/Maskicon/Maskicon.mjs.map +1 -1
  473. package/dist/components/temp-components/Spinner/Spinner.cjs +2 -2
  474. package/dist/components/temp-components/Spinner/Spinner.cjs.map +1 -1
  475. package/dist/components/temp-components/Spinner/Spinner.mjs +2 -2
  476. package/dist/components/temp-components/Spinner/Spinner.mjs.map +1 -1
  477. package/dist/components/temp-components/Spinner/Spinner.types.d.cts +1 -1
  478. package/dist/components/temp-components/Spinner/Spinner.types.d.cts.map +1 -1
  479. package/dist/components/temp-components/Spinner/Spinner.types.d.mts +1 -1
  480. package/dist/components/temp-components/Spinner/Spinner.types.d.mts.map +1 -1
  481. package/dist/test-utils/createRenderer.cjs +41 -0
  482. package/dist/test-utils/createRenderer.cjs.map +1 -0
  483. package/dist/test-utils/createRenderer.d.cts +4 -0
  484. package/dist/test-utils/createRenderer.d.cts.map +1 -0
  485. package/dist/test-utils/createRenderer.d.mts +4 -0
  486. package/dist/test-utils/createRenderer.d.mts.map +1 -0
  487. package/dist/test-utils/createRenderer.mjs +18 -0
  488. package/dist/test-utils/createRenderer.mjs.map +1 -0
  489. package/package.json +21 -22
  490. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.cjs +0 -15
  491. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.cjs.map +0 -1
  492. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.d.cts +0 -7
  493. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.d.cts.map +0 -1
  494. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.d.mts +0 -7
  495. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.d.mts.map +0 -1
  496. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.mjs +0 -12
  497. package/dist/components/BottomSheetHeader/BottomSheetHeader.constants.mjs.map +0 -1
  498. package/dist/components/HeaderBase/HeaderBase.constants.cjs +0 -15
  499. package/dist/components/HeaderBase/HeaderBase.constants.cjs.map +0 -1
  500. package/dist/components/HeaderBase/HeaderBase.constants.d.cts +0 -7
  501. package/dist/components/HeaderBase/HeaderBase.constants.d.cts.map +0 -1
  502. package/dist/components/HeaderBase/HeaderBase.constants.d.mts +0 -7
  503. package/dist/components/HeaderBase/HeaderBase.constants.d.mts.map +0 -1
  504. package/dist/components/HeaderBase/HeaderBase.constants.mjs +0 -12
  505. package/dist/components/HeaderBase/HeaderBase.constants.mjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetDialog.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.tsx"],"names":[],"mappings":";;;;;;AAAA,OAAO,EACL,KAAK,EACL,WAAW,EACX,QAAQ,EACT,6CAA6C;AAC9C,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,gCAAgC;;;AAEhE,OAAO,QAAO,EACZ,UAAU,EACV,WAAW,EACX,SAAS,EACT,OAAO,EACP,MAAM,EACN,mBAAmB,EACpB,cAAc;;AACf,OAAO,EAEL,IAAI,EACJ,QAAQ,EACR,oBAAoB,EACrB,8BAAqB;AACtB,OAAO,EACL,iBAAiB,EAElB,qCAAqC;AACtC,OAAO,QAAQ,EAAE,EACf,OAAO,EACP,yBAAyB,EACzB,gBAAgB,EAChB,cAAc,EACd,UAAU,EACX,gCAAgC;AACjC,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EAClB,uCAAuC;AAExC,yBAAyB;AACzB,OAAO,EACL,0CAA0C,EAC1C,0CAA0C,EAC1C,iDAAiD,EAClD,0CAAsC;AAMvC,MAAM,CAAC,MAAM,iBAAiB,GAAG,UAAU,CAIzC,CACE,EACE,QAAQ,EACR,YAAY,GAAG,KAAK,EACpB,cAAc,GAAG,IAAI,EACrB,2BAA2B,GAAG,IAAI,EAClC,OAAO,EACP,MAAM,EACN,sBAAsB,EACtB,KAAK,EACL,WAAW,EACX,GAAG,KAAK,EACT,EACD,GAAG,EACH,EAAE;I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,CACrB;MAAA,EAAE,oBAAoB,CAAC,CACxB,CAAC;AACJ,CAAC,CACF,CAAC","sourcesContent":["import {\n Theme,\n useTailwind,\n useTheme,\n} from '@metamask/design-system-twrnc-preset';\nimport { lightTheme, darkTheme } from '@metamask/design-tokens';\nimport { debounce } from 'lodash';\nimport React, {\n forwardRef,\n useCallback,\n useEffect,\n useMemo,\n useRef,\n useImperativeHandle,\n} from 'react';\nimport {\n LayoutChangeEvent,\n View,\n Platform,\n KeyboardAvoidingView,\n} from 'react-native';\nimport {\n PanGestureHandler,\n PanGestureHandlerGestureEvent,\n} from 'react-native-gesture-handler';\nimport Animated, {\n runOnJS,\n useAnimatedGestureHandler,\n useAnimatedStyle,\n useSharedValue,\n withTiming,\n} from 'react-native-reanimated';\nimport {\n useSafeAreaFrame,\n useSafeAreaInsets,\n} from 'react-native-safe-area-context';\n\n// Internal dependencies.\nimport {\n DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION,\n DEFAULT_BOTTOMSHEETDIALOG_DISMISSTHRESHOLD,\n DEFAULT_BOTTOMSHEETDIALOG_SWIPETHRESHOLD_DURATION,\n} from './BottomSheetDialog.constants';\nimport type {\n BottomSheetDialogRef,\n BottomSheetDialogProps,\n} from './BottomSheetDialog.types';\n\nexport const BottomSheetDialog = forwardRef<\n BottomSheetDialogRef,\n BottomSheetDialogProps\n>(\n (\n {\n children,\n isFullscreen = false,\n isInteractable = true,\n keyboardAvoidingViewEnabled = true,\n onClose,\n onOpen,\n panGestureHandlerProps,\n style,\n twClassName,\n ...props\n },\n ref,\n ) => {\n const tw = useTailwind();\n const currentTheme = useTheme();\n const shadowLg =\n currentTheme === Theme.Light\n ? lightTheme.shadows.size.lg\n : darkTheme.shadows.size.lg;\n\n const { top: screenTopPadding, bottom: screenBottomPadding } =\n useSafeAreaInsets();\n const { y: frameY, height: screenHeight } = useSafeAreaFrame();\n\n const maxSheetHeight = screenHeight - screenTopPadding;\n // X and Y values start on top left of the DIALOG\n // currentYOffset will be used to animate the Y position of the Dialog\n const currentYOffset = useSharedValue(screenHeight);\n const topOfDialogYValue = useSharedValue(0);\n const bottomOfDialogYValue = useSharedValue(screenHeight);\n const isMounted = useRef(false);\n\n const onOpenCB = useCallback(() => {\n onOpen?.();\n }, [onOpen]);\n const onCloseCB = useCallback(() => {\n onClose?.();\n }, [onClose]);\n\n const onCloseDialog = useCallback(\n (callback?: () => void) => {\n currentYOffset.value = withTiming(\n bottomOfDialogYValue.value,\n { duration: DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION },\n () => {\n runOnJS(onCloseCB)();\n if (callback) {\n runOnJS(callback)();\n }\n },\n );\n // Ref values do not affect deps.\n },\n [onCloseCB],\n );\n\n const gestureHandler = useAnimatedGestureHandler<\n PanGestureHandlerGestureEvent,\n { startY: number }\n >({\n onStart: (_, ctx) => {\n // Starts tracking vertical position of gesture\n ctx.startY = currentYOffset.value;\n },\n onActive: (event, ctx) => {\n const { translationY } = event;\n currentYOffset.value = ctx.startY + translationY;\n // If gesture Y value goes above the bottom of Dialog Y value(bottom of dialog),\n // which means the gesture is currently below the bottom of the dialog,\n // sets it to bottom of Dialog Y value\n if (currentYOffset.value >= bottomOfDialogYValue.value) {\n currentYOffset.value = bottomOfDialogYValue.value;\n }\n // If gesture Y value goes below the top of Dialog Y value(top of dialog),\n // which means the gesture is currently above the top of the dialog,\n // sets it to top of Dialog Y value\n if (currentYOffset.value <= topOfDialogYValue.value) {\n currentYOffset.value = topOfDialogYValue.value;\n }\n },\n onEnd: (event, ctx) => {\n const { translationY, velocityY } = event;\n // finalYOffset is used to animate the Y position of the Dialog after the gesture event\n let finalYOffset: number;\n // Measuring dismissing swipe action\n const latestOffset = ctx.startY + translationY;\n // Check if the swipe distance reach the dismiss offset threshold,\n // which is currently 60% of sheet height\n const hasReachedDismissOffset =\n latestOffset >\n bottomOfDialogYValue.value *\n DEFAULT_BOTTOMSHEETDIALOG_DISMISSTHRESHOLD;\n // Check if the gesture's vertical speed has reached the threshold to determine a swipe action\n const hasReachedSwipeThreshold =\n Math.abs(velocityY) >\n DEFAULT_BOTTOMSHEETDIALOG_SWIPETHRESHOLD_DURATION;\n const isQuickDismissing = velocityY > 0;\n\n // If user is swiping\n if (hasReachedSwipeThreshold) {\n // Quick swipe takes priority\n if (isQuickDismissing) {\n finalYOffset = bottomOfDialogYValue.value;\n } else {\n finalYOffset = topOfDialogYValue.value;\n }\n } else if (hasReachedDismissOffset) {\n finalYOffset = bottomOfDialogYValue.value;\n } else {\n finalYOffset = topOfDialogYValue.value;\n }\n\n const isDismissed = finalYOffset === bottomOfDialogYValue.value;\n\n if (isDismissed) {\n runOnJS(onCloseDialog)();\n } else {\n // Only animate dialog to a certain Y position instead\n currentYOffset.value = withTiming(finalYOffset, {\n duration: DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION,\n });\n }\n },\n });\n\n // Animate in sheet on initial render.\n const onOpenDialog = (callback?: () => void) => {\n // Starts setting the Y position of the dialog to the bottom of the dialog\n currentYOffset.value = bottomOfDialogYValue.value;\n // Animate the Y position to the top of the dialog, then call onOpenCB\n currentYOffset.value = withTiming(\n topOfDialogYValue.value,\n {\n duration: DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION,\n },\n () => {\n runOnJS(onOpenCB)();\n if (callback) {\n runOnJS(callback)();\n }\n },\n );\n };\n\n const onDebouncedCloseDialog = useMemo(\n // Prevent hide from being called multiple times. Potentially caused by taps in quick succession.\n () => debounce(onCloseDialog, 2000, { leading: true }),\n [onCloseDialog],\n );\n\n useEffect(\n () =>\n // Automatically handles animation when content changes\n // Disable for now since network switches causes the screen to hang with this on.\n // LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut);\n onDebouncedCloseDialog.cancel(),\n [children, onDebouncedCloseDialog],\n );\n\n const updateSheetHeight = (e: LayoutChangeEvent) => {\n const { height } = e.nativeEvent.layout;\n bottomOfDialogYValue.value = height;\n\n if (!isMounted.current) {\n isMounted.current = true;\n onOpenDialog();\n }\n };\n\n const animatedSheetStyle = useAnimatedStyle(() => ({\n transform: [\n {\n translateY: currentYOffset.value,\n },\n ],\n }));\n\n const sheetStyle = useMemo(\n () => [\n tw.style(\n 'bg-default rounded-t-3xl overflow-hidden border border-muted',\n twClassName,\n ),\n {\n maxHeight: maxSheetHeight,\n paddingBottom: Platform.select({\n ios: screenBottomPadding,\n macos: screenBottomPadding,\n default: screenBottomPadding + 16,\n }),\n ...(isFullscreen && { height: maxSheetHeight }),\n ...shadowLg,\n },\n style,\n ],\n\n [\n tw,\n maxSheetHeight,\n screenBottomPadding,\n isFullscreen,\n shadowLg,\n style,\n twClassName,\n ],\n );\n\n const combinedSheetStyle = useMemo(\n () => [...sheetStyle, animatedSheetStyle],\n\n [sheetStyle],\n );\n\n useImperativeHandle(ref, () => ({\n onOpenDialog,\n onCloseDialog,\n }));\n\n return (\n <KeyboardAvoidingView\n style={tw.style('absolute bottom-0 inset-x-0')}\n behavior={Platform.OS === 'ios' ? 'padding' : undefined}\n keyboardVerticalOffset={\n Platform.OS === 'ios' ? -screenBottomPadding : frameY\n }\n enabled={keyboardAvoidingViewEnabled}\n {...props}\n >\n <PanGestureHandler\n {...panGestureHandlerProps}\n enabled={isInteractable}\n onGestureEvent={gestureHandler}\n >\n <Animated.View\n onLayout={updateSheetHeight}\n style={combinedSheetStyle}\n >\n {isInteractable && (\n <View style={tw.style('self-stretch items-center p-1')}>\n <View style={tw.style('h-1 w-10 rounded-sm bg-border-muted')} />\n </View>\n )}\n {children}\n </Animated.View>\n </PanGestureHandler>\n </KeyboardAvoidingView>\n );\n },\n);\n"]}
1
+ {"version":3,"file":"BottomSheetDialog.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.tsx"],"names":[],"mappings":";;;;;;AAAA,OAAO,EACL,KAAK,EACL,WAAW,EACX,QAAQ,EACT,6CAA6C;AAC9C,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,gCAAgC;;;AAEhE,OAAO,QAAO,E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,KAAK,CAAC,6BAA6B,CAAC,CAAC,CAC/C,QAAQ,CAAC,CAAC,QAAQ,CAAC,EAAE,KAAK,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CACxD,sBAAsB,CAAC,CACrB,QAAQ,CAAC,EAAE,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,mBAAmB,CAAC,CAAC,CAAC,MAAM,CACtD,CACD,OAAO,CAAC,CAAC,2BAA2B,CAAC,CACrC,IAAI,KAAK,CAAC,CAEV;QAAA,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC,cAAc,CAAC,CACvC;UAAA,CAAC,QAAQ,CAAC,IAAI,CACZ,QAAQ,CAAC,CAAC,iBAAiB,CAAC,CAC5B,KAAK,CAAC,CAAC,kBAAkB,CAAC,CAE1B;YAAA,CAAC,cAAc,IAAI,CACjB,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,+BAA+B,CAAC,CAAC,CACrD;gBAAA,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,qCAAqC,CAAC,CAAC,EAC/D;cAAA,EAAE,IAAI,CAAC,CACR,CACD;YAAA,CAAC,QAAQ,CACX;UAAA,EAAE,QAAQ,CAAC,IAAI,CACjB;QAAA,EAAE,eAAe,CACnB;MAAA,EAAE,oBAAoB,CAAC,CACxB,CAAC;AACJ,CAAC,CACF,CAAC","sourcesContent":["import {\n Theme,\n useTailwind,\n useTheme,\n} from '@metamask/design-system-twrnc-preset';\nimport { lightTheme, darkTheme } from '@metamask/design-tokens';\nimport { debounce } from 'lodash';\nimport React, {\n forwardRef,\n useCallback,\n useEffect,\n useMemo,\n useRef,\n useImperativeHandle,\n} from 'react';\nimport {\n LayoutChangeEvent,\n View,\n Platform,\n KeyboardAvoidingView,\n} from 'react-native';\nimport { Gesture, GestureDetector } from 'react-native-gesture-handler';\nimport Animated, {\n runOnJS,\n useAnimatedStyle,\n useSharedValue,\n withTiming,\n} from 'react-native-reanimated';\nimport {\n useSafeAreaFrame,\n useSafeAreaInsets,\n} from 'react-native-safe-area-context';\n\n// Internal dependencies.\nimport {\n DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION,\n DEFAULT_BOTTOMSHEETDIALOG_DISMISSTHRESHOLD,\n DEFAULT_BOTTOMSHEETDIALOG_SWIPETHRESHOLD_DURATION,\n} from './BottomSheetDialog.constants';\nimport type {\n BottomSheetDialogRef,\n BottomSheetDialogProps,\n} from './BottomSheetDialog.types';\n\nexport const BottomSheetDialog = forwardRef<\n BottomSheetDialogRef,\n BottomSheetDialogProps\n>(\n (\n {\n children,\n isFullscreen = false,\n isInteractable = true,\n keyboardAvoidingViewEnabled = true,\n onClose,\n onOpen,\n style,\n twClassName,\n ...props\n },\n ref,\n ) => {\n const tw = useTailwind();\n const currentTheme = useTheme();\n const shadowLg =\n currentTheme === Theme.Light\n ? lightTheme.shadows.size.lg\n : darkTheme.shadows.size.lg;\n\n const { top: screenTopPadding, bottom: screenBottomPadding } =\n useSafeAreaInsets();\n const { y: frameY, height: screenHeight } = useSafeAreaFrame();\n\n const maxSheetHeight = screenHeight - screenTopPadding;\n // X and Y values start on top left of the DIALOG\n // currentYOffset will be used to animate the Y position of the Dialog\n const currentYOffset = useSharedValue(screenHeight);\n const topOfDialogYValue = useSharedValue(0);\n const bottomOfDialogYValue = useSharedValue(screenHeight);\n const gestureStartYOffset = useSharedValue(0);\n const isMounted = useRef(false);\n\n const onOpenCB = useCallback(() => {\n onOpen?.();\n }, [onOpen]);\n const onCloseCB = useCallback(() => {\n onClose?.();\n }, [onClose]);\n\n const onCloseDialog = useCallback(\n (callback?: () => void) => {\n currentYOffset.value = withTiming(\n bottomOfDialogYValue.value,\n { duration: DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION },\n () => {\n runOnJS(onCloseCB)();\n if (callback) {\n runOnJS(callback)();\n }\n },\n );\n // Ref values do not affect deps.\n },\n [onCloseCB],\n );\n\n const gestureHandler = useMemo(() => {\n const gesture = Gesture.Pan()\n .enabled(isInteractable)\n .onStart(() => {\n // Starts tracking vertical position of gesture.\n gestureStartYOffset.value = currentYOffset.value;\n })\n .onUpdate((event) => {\n const { translationY } = event;\n currentYOffset.value = gestureStartYOffset.value + translationY;\n // If gesture Y value goes above the bottom of Dialog Y value(bottom of dialog),\n // which means the gesture is currently below the bottom of the dialog,\n // sets it to bottom of Dialog Y value\n if (currentYOffset.value >= bottomOfDialogYValue.value) {\n currentYOffset.value = bottomOfDialogYValue.value;\n }\n // If gesture Y value goes below the top of Dialog Y value(top of dialog),\n // which means the gesture is currently above the top of the dialog,\n // sets it to top of Dialog Y value\n if (currentYOffset.value <= topOfDialogYValue.value) {\n currentYOffset.value = topOfDialogYValue.value;\n }\n })\n .onEnd((event) => {\n const { translationY, velocityY } = event;\n // finalYOffset is used to animate the Y position of the Dialog after the gesture event\n let finalYOffset: number;\n // Measuring dismissing swipe action\n const latestOffset = gestureStartYOffset.value + translationY;\n // Check if the swipe distance reach the dismiss offset threshold,\n // which is currently 60% of sheet height\n const hasReachedDismissOffset =\n latestOffset >\n bottomOfDialogYValue.value *\n DEFAULT_BOTTOMSHEETDIALOG_DISMISSTHRESHOLD;\n // Check if the gesture's vertical speed has reached the threshold to determine a swipe action\n const hasReachedSwipeThreshold =\n Math.abs(velocityY) >\n DEFAULT_BOTTOMSHEETDIALOG_SWIPETHRESHOLD_DURATION;\n const isQuickDismissing = velocityY > 0;\n\n // If user is swiping\n if (hasReachedSwipeThreshold) {\n // Quick swipe takes priority\n if (isQuickDismissing) {\n finalYOffset = bottomOfDialogYValue.value;\n } else {\n finalYOffset = topOfDialogYValue.value;\n }\n } else if (hasReachedDismissOffset) {\n finalYOffset = bottomOfDialogYValue.value;\n } else {\n finalYOffset = topOfDialogYValue.value;\n }\n\n const isDismissed = finalYOffset === bottomOfDialogYValue.value;\n\n if (isDismissed) {\n runOnJS(onCloseDialog)();\n } else {\n // Only animate dialog to a certain Y position instead\n currentYOffset.value = withTiming(finalYOffset, {\n duration: DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION,\n });\n }\n });\n\n return gesture;\n }, [\n isInteractable,\n currentYOffset,\n gestureStartYOffset,\n bottomOfDialogYValue,\n topOfDialogYValue,\n onCloseDialog,\n ]);\n\n // Animate in sheet on initial render.\n const onOpenDialog = (callback?: () => void) => {\n // Starts setting the Y position of the dialog to the bottom of the dialog\n currentYOffset.value = bottomOfDialogYValue.value;\n // Animate the Y position to the top of the dialog, then call onOpenCB\n currentYOffset.value = withTiming(\n topOfDialogYValue.value,\n {\n duration: DEFAULT_BOTTOMSHEETDIALOG_DISPLAY_DURATION,\n },\n () => {\n runOnJS(onOpenCB)();\n if (callback) {\n runOnJS(callback)();\n }\n },\n );\n };\n\n const onDebouncedCloseDialog = useMemo(\n // Prevent hide from being called multiple times. Potentially caused by taps in quick succession.\n () => debounce(onCloseDialog, 2000, { leading: true }),\n [onCloseDialog],\n );\n\n useEffect(\n () =>\n // Automatically handles animation when content changes\n // Disable for now since network switches causes the screen to hang with this on.\n // LayoutAnimation.configureNext(LayoutAnimation.Presets.easeInEaseOut);\n onDebouncedCloseDialog.cancel(),\n [children, onDebouncedCloseDialog],\n );\n\n const updateSheetHeight = (e: LayoutChangeEvent) => {\n const { height } = e.nativeEvent.layout;\n bottomOfDialogYValue.value = height;\n\n if (!isMounted.current) {\n isMounted.current = true;\n onOpenDialog();\n }\n };\n\n const animatedSheetStyle = useAnimatedStyle(\n () => ({\n transform: [\n {\n translateY: currentYOffset.value,\n },\n ],\n }),\n [],\n );\n\n const sheetStyle = useMemo(\n () => [\n tw.style(\n 'bg-default rounded-t-3xl overflow-hidden border border-muted',\n twClassName,\n ),\n {\n maxHeight: maxSheetHeight,\n paddingBottom: Platform.select({\n ios: screenBottomPadding,\n macos: screenBottomPadding,\n default: screenBottomPadding + 16,\n }),\n ...(isFullscreen && { height: maxSheetHeight }),\n ...shadowLg,\n },\n style,\n ],\n\n [\n tw,\n maxSheetHeight,\n screenBottomPadding,\n isFullscreen,\n shadowLg,\n style,\n twClassName,\n ],\n );\n\n const combinedSheetStyle = useMemo(\n () => [...sheetStyle, animatedSheetStyle],\n\n [sheetStyle],\n );\n\n useImperativeHandle(ref, () => ({\n onOpenDialog,\n onCloseDialog,\n }));\n\n return (\n <KeyboardAvoidingView\n style={tw.style('absolute bottom-0 inset-x-0')}\n behavior={Platform.OS === 'ios' ? 'padding' : undefined}\n keyboardVerticalOffset={\n Platform.OS === 'ios' ? -screenBottomPadding : frameY\n }\n enabled={keyboardAvoidingViewEnabled}\n {...props}\n >\n <GestureDetector gesture={gestureHandler}>\n <Animated.View\n onLayout={updateSheetHeight}\n style={combinedSheetStyle}\n >\n {isInteractable && (\n <View style={tw.style('self-stretch items-center p-1')}>\n <View style={tw.style('h-1 w-10 rounded-sm bg-border-muted')} />\n </View>\n )}\n {children}\n </Animated.View>\n </GestureDetector>\n </KeyboardAvoidingView>\n );\n },\n);\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetDialog.types.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":"","sourcesContent":["// Third party dependencies.\nimport type { ViewProps } from 'react-native';\nimport type { PanGestureHandlerProps } from 'react-native-gesture-handler';\n\ntype BottomSheetDialogPanGestureHandlerProps = Omit<\n PanGestureHandlerProps,\n 'enabled' | 'onGestureEvent'\n>;\n\n/**\n * BottomSheetDialog component props.\n */\nexport type BottomSheetDialogProps = {\n /**\n * Optional content to display inside the dialog.\n */\n children?: React.ReactNode;\n /**\n * Optional prop to toggle full screen state of BottomSheetDialog.\n *\n * @default false\n */\n isFullscreen?: boolean;\n /**\n * Optional boolean that indicates if the sheet is swippable.\n * This affects whether or not tapping on the overlay will dismiss\n * the sheet as well, and whether the drag handle indicator is shown.\n *\n * @default true\n */\n isInteractable?: boolean;\n /**\n * Optional boolean that indicates if the KeyboardAvoidingView is enabled.\n *\n * @default true\n */\n keyboardAvoidingViewEnabled?: boolean;\n /**\n * Optional callback that gets triggered when the sheet is closed.\n */\n onClose?: (hasPendingAction?: boolean) => void;\n /**\n * Optional callback that gets triggered when the sheet is opened.\n */\n onOpen?: (hasPendingAction?: boolean) => void;\n /**\n * Optional props object passed directly to the child PanGestureHandler.\n */\n panGestureHandlerProps?: BottomSheetDialogPanGestureHandlerProps;\n /**\n * Tailwind CSS classes for the dialog container.\n */\n twClassName?: string;\n} & ViewProps;\n\n/**\n * Ref handle for imperative control of the BottomSheetDialog.\n */\nexport type BottomSheetDialogRef = {\n /**\n * Imperatively close the dialog with an optional callback after animation completes.\n */\n onCloseDialog: (callback?: () => void) => void;\n /**\n * Imperatively open the dialog with an optional callback after animation completes.\n */\n onOpenDialog: (callback?: () => void) => void;\n};\n"]}
1
+ {"version":3,"file":"BottomSheetDialog.types.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":"","sourcesContent":["// Third party dependencies.\nimport type { ViewProps } from 'react-native';\n\n/**\n * BottomSheetDialog component props.\n */\nexport type BottomSheetDialogProps = {\n /**\n * Optional content to display inside the dialog.\n */\n children?: React.ReactNode;\n /**\n * Optional prop to toggle full screen state of BottomSheetDialog.\n *\n * @default false\n */\n isFullscreen?: boolean;\n /**\n * Optional boolean that indicates if the sheet is swippable.\n * This affects whether or not tapping on the overlay will dismiss\n * the sheet as well, and whether the drag handle indicator is shown.\n *\n * @default true\n */\n isInteractable?: boolean;\n /**\n * Optional boolean that indicates if the KeyboardAvoidingView is enabled.\n *\n * @default true\n */\n keyboardAvoidingViewEnabled?: boolean;\n /**\n * Optional callback that gets triggered when the sheet is closed.\n */\n onClose?: (hasPendingAction?: boolean) => void;\n /**\n * Optional callback that gets triggered when the sheet is opened.\n */\n onOpen?: (hasPendingAction?: boolean) => void;\n /**\n * Tailwind CSS classes for the dialog container.\n */\n twClassName?: string;\n} & ViewProps;\n\n/**\n * Ref handle for imperative control of the BottomSheetDialog.\n */\nexport type BottomSheetDialogRef = {\n /**\n * Imperatively close the dialog with an optional callback after animation completes.\n */\n onCloseDialog: (callback?: () => void) => void;\n /**\n * Imperatively open the dialog with an optional callback after animation completes.\n */\n onOpenDialog: (callback?: () => void) => void;\n};\n"]}
@@ -1,7 +1,4 @@
1
- /// <reference types="react" />
2
- import type { ViewProps } from "react-native/index.js";
3
- import type { PanGestureHandlerProps } from "react-native-gesture-handler";
4
- type BottomSheetDialogPanGestureHandlerProps = Omit<PanGestureHandlerProps, 'enabled' | 'onGestureEvent'>;
1
+ import type { ViewProps } from "react-native";
5
2
  /**
6
3
  * BottomSheetDialog component props.
7
4
  */
@@ -38,10 +35,6 @@ export type BottomSheetDialogProps = {
38
35
  * Optional callback that gets triggered when the sheet is opened.
39
36
  */
40
37
  onOpen?: (hasPendingAction?: boolean) => void;
41
- /**
42
- * Optional props object passed directly to the child PanGestureHandler.
43
- */
44
- panGestureHandlerProps?: BottomSheetDialogPanGestureHandlerProps;
45
38
  /**
46
39
  * Tailwind CSS classes for the dialog container.
47
40
  */
@@ -60,5 +53,4 @@ export type BottomSheetDialogRef = {
60
53
  */
61
54
  onOpenDialog: (callback?: () => void) => void;
62
55
  };
63
- export {};
64
56
  //# sourceMappingURL=BottomSheetDialog.types.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetDialog.types.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,SAAS,EAAE,8BAAqB;AAC9C,OAAO,KAAK,EAAE,sBAAsB,EAAE,qCAAqC;AAE3E,KAAK,uCAAuC,GAAG,IAAI,CACjD,sBAAsB,EACtB,SAAS,GAAG,gBAAgB,CAC7B,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;OAEG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B;;;;OAIG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;;;OAIG;IACH,2BAA2B,CAAC,EAAE,OAAO,CAAC;IACtC;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC9C;;OAEG;IACH,sBAAsB,CAAC,EAAE,uCAAuC,CAAC;IACjE;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC;AAEd;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC;;OAEG;IACH,aAAa,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,YAAY,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;CAC/C,CAAC"}
1
+ {"version":3,"file":"BottomSheetDialog.types.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,qBAAqB;AAE9C;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;OAEG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B;;;;OAIG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;;;OAIG;IACH,2BAA2B,CAAC,EAAE,OAAO,CAAC;IACtC;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC9C;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC;AAEd;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC;;OAEG;IACH,aAAa,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,YAAY,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;CAC/C,CAAC"}
@@ -1,7 +1,4 @@
1
- /// <reference types="react" />
2
- import type { ViewProps } from "react-native/index.js";
3
- import type { PanGestureHandlerProps } from "react-native-gesture-handler";
4
- type BottomSheetDialogPanGestureHandlerProps = Omit<PanGestureHandlerProps, 'enabled' | 'onGestureEvent'>;
1
+ import type { ViewProps } from "react-native";
5
2
  /**
6
3
  * BottomSheetDialog component props.
7
4
  */
@@ -38,10 +35,6 @@ export type BottomSheetDialogProps = {
38
35
  * Optional callback that gets triggered when the sheet is opened.
39
36
  */
40
37
  onOpen?: (hasPendingAction?: boolean) => void;
41
- /**
42
- * Optional props object passed directly to the child PanGestureHandler.
43
- */
44
- panGestureHandlerProps?: BottomSheetDialogPanGestureHandlerProps;
45
38
  /**
46
39
  * Tailwind CSS classes for the dialog container.
47
40
  */
@@ -60,5 +53,4 @@ export type BottomSheetDialogRef = {
60
53
  */
61
54
  onOpenDialog: (callback?: () => void) => void;
62
55
  };
63
- export {};
64
56
  //# sourceMappingURL=BottomSheetDialog.types.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetDialog.types.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":";AACA,OAAO,KAAK,EAAE,SAAS,EAAE,8BAAqB;AAC9C,OAAO,KAAK,EAAE,sBAAsB,EAAE,qCAAqC;AAE3E,KAAK,uCAAuC,GAAG,IAAI,CACjD,sBAAsB,EACtB,SAAS,GAAG,gBAAgB,CAC7B,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;OAEG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B;;;;OAIG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;;;OAIG;IACH,2BAA2B,CAAC,EAAE,OAAO,CAAC;IACtC;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC9C;;OAEG;IACH,sBAAsB,CAAC,EAAE,uCAAuC,CAAC;IACjE;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC;AAEd;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC;;OAEG;IACH,aAAa,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,YAAY,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;CAC/C,CAAC"}
1
+ {"version":3,"file":"BottomSheetDialog.types.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,qBAAqB;AAE9C;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;OAEG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B;;;;OAIG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB;;;;;;OAMG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;;;OAIG;IACH,2BAA2B,CAAC,EAAE,OAAO,CAAC;IACtC;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,gBAAgB,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC;IAC9C;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC;AAEd;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC;;OAEG;IACH,aAAa,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,YAAY,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;CAC/C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetDialog.types.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":"","sourcesContent":["// Third party dependencies.\nimport type { ViewProps } from 'react-native';\nimport type { PanGestureHandlerProps } from 'react-native-gesture-handler';\n\ntype BottomSheetDialogPanGestureHandlerProps = Omit<\n PanGestureHandlerProps,\n 'enabled' | 'onGestureEvent'\n>;\n\n/**\n * BottomSheetDialog component props.\n */\nexport type BottomSheetDialogProps = {\n /**\n * Optional content to display inside the dialog.\n */\n children?: React.ReactNode;\n /**\n * Optional prop to toggle full screen state of BottomSheetDialog.\n *\n * @default false\n */\n isFullscreen?: boolean;\n /**\n * Optional boolean that indicates if the sheet is swippable.\n * This affects whether or not tapping on the overlay will dismiss\n * the sheet as well, and whether the drag handle indicator is shown.\n *\n * @default true\n */\n isInteractable?: boolean;\n /**\n * Optional boolean that indicates if the KeyboardAvoidingView is enabled.\n *\n * @default true\n */\n keyboardAvoidingViewEnabled?: boolean;\n /**\n * Optional callback that gets triggered when the sheet is closed.\n */\n onClose?: (hasPendingAction?: boolean) => void;\n /**\n * Optional callback that gets triggered when the sheet is opened.\n */\n onOpen?: (hasPendingAction?: boolean) => void;\n /**\n * Optional props object passed directly to the child PanGestureHandler.\n */\n panGestureHandlerProps?: BottomSheetDialogPanGestureHandlerProps;\n /**\n * Tailwind CSS classes for the dialog container.\n */\n twClassName?: string;\n} & ViewProps;\n\n/**\n * Ref handle for imperative control of the BottomSheetDialog.\n */\nexport type BottomSheetDialogRef = {\n /**\n * Imperatively close the dialog with an optional callback after animation completes.\n */\n onCloseDialog: (callback?: () => void) => void;\n /**\n * Imperatively open the dialog with an optional callback after animation completes.\n */\n onOpenDialog: (callback?: () => void) => void;\n};\n"]}
1
+ {"version":3,"file":"BottomSheetDialog.types.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetDialog/BottomSheetDialog.types.ts"],"names":[],"mappings":"","sourcesContent":["// Third party dependencies.\nimport type { ViewProps } from 'react-native';\n\n/**\n * BottomSheetDialog component props.\n */\nexport type BottomSheetDialogProps = {\n /**\n * Optional content to display inside the dialog.\n */\n children?: React.ReactNode;\n /**\n * Optional prop to toggle full screen state of BottomSheetDialog.\n *\n * @default false\n */\n isFullscreen?: boolean;\n /**\n * Optional boolean that indicates if the sheet is swippable.\n * This affects whether or not tapping on the overlay will dismiss\n * the sheet as well, and whether the drag handle indicator is shown.\n *\n * @default true\n */\n isInteractable?: boolean;\n /**\n * Optional boolean that indicates if the KeyboardAvoidingView is enabled.\n *\n * @default true\n */\n keyboardAvoidingViewEnabled?: boolean;\n /**\n * Optional callback that gets triggered when the sheet is closed.\n */\n onClose?: (hasPendingAction?: boolean) => void;\n /**\n * Optional callback that gets triggered when the sheet is opened.\n */\n onOpen?: (hasPendingAction?: boolean) => void;\n /**\n * Tailwind CSS classes for the dialog container.\n */\n twClassName?: string;\n} & ViewProps;\n\n/**\n * Ref handle for imperative control of the BottomSheetDialog.\n */\nexport type BottomSheetDialogRef = {\n /**\n * Imperatively close the dialog with an optional callback after animation completes.\n */\n onCloseDialog: (callback?: () => void) => void;\n /**\n * Imperatively open the dialog with an optional callback after animation completes.\n */\n onOpenDialog: (callback?: () => void) => void;\n};\n"]}
@@ -7,7 +7,7 @@ exports.BottomSheetFooter = void 0;
7
7
  // Third party dependencies.
8
8
  const design_system_twrnc_preset_1 = require("@metamask/design-system-twrnc-preset");
9
9
  const react_1 = __importDefault(require("react"));
10
- const react_native_1 = require("react-native/index.js");
10
+ const react_native_1 = require("react-native");
11
11
  // External dependencies.
12
12
  const Button_1 = require("../Button/index.cjs");
13
13
  const BottomSheetFooter_types_1 = require("./BottomSheetFooter.types.cjs");
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetFooter.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,qFAAmE;AACnE,kDAA0B;AAC1B,wDAAoC;AAEpC,yBAAyB;AACzB,gDAAkD;AAIlD,2EAA6D;AAEtD,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,WAAW,EACX,gBAAgB,GAAG,0CAAgB,CAAC,UAAU,EAC9C,kBAAkB,EAClB,oBAAoB,EACpB,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,EAAE,GAAG,IAAA,wCAAW,GAAE,CAAC;IACzB,MAAM,YAAY,GAAG,gBAAgB,KAAK,0CAAgB,CAAC,UAAU,CAAC;IACtE,MAAM,eAAe,GAAG,YAAY,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,cAAc,CAAC;IACjE,MAAM,QAAQ,GAAG,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC;IAChD,MAAM,cAAc,GAClB,OAAO,CAAC,kBAAkB,CAAC,IAAI,OAAO,CAAC,oBAAoB,CAAC,CAAC;IAE/D,IAAI,CAAC,kBAAkB,IAAI,CAAC,oBAAoB,EAAE;QAChD,OAAO,IAAI,CAAC;KACb;IAED,OAAO,CACL,CAAC,mBAAI,CACH,KAAK,CAAC,CAAC;YACL,EAAE,CAAC,KAAK,CACN,YAAY,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,UAAU,EACtC,WAAW,EACX,WAAW,CACZ;YACD,KAAK;SACN,CAAC,CACF,IAAI,KAAK,CAAC,CAEV;MAAA,CAAC,oBAAoB,IAAI,CACvB,CAAC,eAAM,CACL,IAAI,oBAAoB,CAAC,CACzB,OAAO,CAAC,CAAC,sBAAa,CAAC,SAAS,CAAC,CACjC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,eAAe,CAAC,EAAE,oBAAoB,CAAC,KAAK,CAAC,CAAC,EAC/D,CACH,CACD;MAAA,CAAC,kBAAkB,IAAI,CACrB,CAAC,eAAM,CACL,IAAI,kBAAkB,CAAC,CACvB,OAAO,CAAC,CAAC,sBAAa,CAAC,OAAO,CAAC,CAC/B,KAAK,CAAC,CAAC;gBACL,EAAE,CAAC,KAAK,CAAC,eAAe,EAAE,cAAc,IAAI,QAAQ,CAAC;gBACrD,kBAAkB,CAAC,KAAK;aACzB,CAAC,EACF,CACH,CACH;IAAA,EAAE,mBAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAlDW,QAAA,iBAAiB,qBAkD5B","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\nimport { View } from 'react-native';\n\n// External dependencies.\nimport { Button, ButtonVariant } from '../Button';\n\n// Internal dependencies.\nimport type { BottomSheetFooterProps } from './BottomSheetFooter.types';\nimport { ButtonsAlignment } from './BottomSheetFooter.types';\n\nexport const BottomSheetFooter: React.FC<BottomSheetFooterProps> = ({\n style,\n twClassName,\n buttonsAlignment = ButtonsAlignment.Horizontal,\n primaryButtonProps,\n secondaryButtonProps,\n ...props\n}) => {\n const tw = useTailwind();\n const isHorizontal = buttonsAlignment === ButtonsAlignment.Horizontal;\n const buttonBaseClass = isHorizontal ? 'flex-1' : 'self-stretch';\n const gapClass = isHorizontal ? 'ml-4' : 'mt-4';\n const hasBothButtons =\n Boolean(primaryButtonProps) && Boolean(secondaryButtonProps);\n\n if (!primaryButtonProps && !secondaryButtonProps) {\n return null;\n }\n\n return (\n <View\n style={[\n tw.style(\n isHorizontal ? 'flex-row' : 'flex-col',\n 'px-2 py-1',\n twClassName,\n ),\n style,\n ]}\n {...props}\n >\n {secondaryButtonProps && (\n <Button\n {...secondaryButtonProps}\n variant={ButtonVariant.Secondary}\n style={[tw.style(buttonBaseClass), secondaryButtonProps.style]}\n />\n )}\n {primaryButtonProps && (\n <Button\n {...primaryButtonProps}\n variant={ButtonVariant.Primary}\n style={[\n tw.style(buttonBaseClass, hasBothButtons && gapClass),\n primaryButtonProps.style,\n ]}\n />\n )}\n </View>\n );\n};\n"]}
1
+ {"version":3,"file":"BottomSheetFooter.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,qFAAmE;AACnE,kDAA0B;AAC1B,+CAAoC;AAEpC,yBAAyB;AACzB,gDAAkD;AAIlD,2EAA6D;AAEtD,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,WAAW,EACX,gBAAgB,GAAG,0CAAgB,CAAC,UAAU,EAC9C,kBAAkB,EAClB,oBAAoB,EACpB,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,EAAE,GAAG,IAAA,wCAAW,GAAE,CAAC;IACzB,MAAM,YAAY,GAAG,gBAAgB,KAAK,0CAAgB,CAAC,UAAU,CAAC;IACtE,MAAM,eAAe,GAAG,YAAY,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,cAAc,CAAC;IACjE,MAAM,QAAQ,GAAG,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC;IAChD,MAAM,cAAc,GAClB,OAAO,CAAC,kBAAkB,CAAC,IAAI,OAAO,CAAC,oBAAoB,CAAC,CAAC;IAE/D,IAAI,CAAC,kBAAkB,IAAI,CAAC,oBAAoB,EAAE;QAChD,OAAO,IAAI,CAAC;KACb;IAED,OAAO,CACL,CAAC,mBAAI,CACH,KAAK,CAAC,CAAC;YACL,EAAE,CAAC,KAAK,CACN,YAAY,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,UAAU,EACtC,WAAW,EACX,WAAW,CACZ;YACD,KAAK;SACN,CAAC,CACF,IAAI,KAAK,CAAC,CAEV;MAAA,CAAC,oBAAoB,IAAI,CACvB,CAAC,eAAM,CACL,IAAI,oBAAoB,CAAC,CACzB,OAAO,CAAC,CAAC,sBAAa,CAAC,SAAS,CAAC,CACjC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,eAAe,CAAC,EAAE,oBAAoB,CAAC,KAAK,CAAC,CAAC,EAC/D,CACH,CACD;MAAA,CAAC,kBAAkB,IAAI,CACrB,CAAC,eAAM,CACL,IAAI,kBAAkB,CAAC,CACvB,OAAO,CAAC,CAAC,sBAAa,CAAC,OAAO,CAAC,CAC/B,KAAK,CAAC,CAAC;gBACL,EAAE,CAAC,KAAK,CAAC,eAAe,EAAE,cAAc,IAAI,QAAQ,CAAC;gBACrD,kBAAkB,CAAC,KAAK;aACzB,CAAC,EACF,CACH,CACH;IAAA,EAAE,mBAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAlDW,QAAA,iBAAiB,qBAkD5B","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\nimport { View } from 'react-native';\n\n// External dependencies.\nimport { Button, ButtonVariant } from '../Button';\n\n// Internal dependencies.\nimport type { BottomSheetFooterProps } from './BottomSheetFooter.types';\nimport { ButtonsAlignment } from './BottomSheetFooter.types';\n\nexport const BottomSheetFooter: React.FC<BottomSheetFooterProps> = ({\n style,\n twClassName,\n buttonsAlignment = ButtonsAlignment.Horizontal,\n primaryButtonProps,\n secondaryButtonProps,\n ...props\n}) => {\n const tw = useTailwind();\n const isHorizontal = buttonsAlignment === ButtonsAlignment.Horizontal;\n const buttonBaseClass = isHorizontal ? 'flex-1' : 'self-stretch';\n const gapClass = isHorizontal ? 'ml-4' : 'mt-4';\n const hasBothButtons =\n Boolean(primaryButtonProps) && Boolean(secondaryButtonProps);\n\n if (!primaryButtonProps && !secondaryButtonProps) {\n return null;\n }\n\n return (\n <View\n style={[\n tw.style(\n isHorizontal ? 'flex-row' : 'flex-col',\n 'px-2 py-1',\n twClassName,\n ),\n style,\n ]}\n {...props}\n >\n {secondaryButtonProps && (\n <Button\n {...secondaryButtonProps}\n variant={ButtonVariant.Secondary}\n style={[tw.style(buttonBaseClass), secondaryButtonProps.style]}\n />\n )}\n {primaryButtonProps && (\n <Button\n {...primaryButtonProps}\n variant={ButtonVariant.Primary}\n style={[\n tw.style(buttonBaseClass, hasBothButtons && gapClass),\n primaryButtonProps.style,\n ]}\n />\n )}\n </View>\n );\n};\n"]}
@@ -8,7 +8,7 @@ function $importDefault(module) {
8
8
  import { useTailwind } from "@metamask/design-system-twrnc-preset";
9
9
  import $React from "react";
10
10
  const React = $importDefault($React);
11
- import { View } from "react-native/index.js";
11
+ import { View } from "react-native";
12
12
  // External dependencies.
13
13
  import { Button, ButtonVariant } from "../Button/index.mjs";
14
14
  import { ButtonsAlignment } from "./BottomSheetFooter.types.mjs";
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetFooter.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,OAAO,EAAE,WAAW,EAAE,6CAA6C;AACnE,OAAO,MAAK,cAAc;;AAC1B,OAAO,EAAE,IAAI,EAAE,8BAAqB;AAEpC,yBAAyB;AACzB,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,4BAAkB;AAIlD,OAAO,EAAE,gBAAgB,EAAE,sCAAkC;AAE7D,MAAM,CAAC,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,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AkB,CAAC,KAAK;aACzB,CAAC,EACF,CACH,CACH;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\nimport { View } from 'react-native';\n\n// External dependencies.\nimport { Button, ButtonVariant } from '../Button';\n\n// Internal dependencies.\nimport type { BottomSheetFooterProps } from './BottomSheetFooter.types';\nimport { ButtonsAlignment } from './BottomSheetFooter.types';\n\nexport const BottomSheetFooter: React.FC<BottomSheetFooterProps> = ({\n style,\n twClassName,\n buttonsAlignment = ButtonsAlignment.Horizontal,\n primaryButtonProps,\n secondaryButtonProps,\n ...props\n}) => {\n const tw = useTailwind();\n const isHorizontal = buttonsAlignment === ButtonsAlignment.Horizontal;\n const buttonBaseClass = isHorizontal ? 'flex-1' : 'self-stretch';\n const gapClass = isHorizontal ? 'ml-4' : 'mt-4';\n const hasBothButtons =\n Boolean(primaryButtonProps) && Boolean(secondaryButtonProps);\n\n if (!primaryButtonProps && !secondaryButtonProps) {\n return null;\n }\n\n return (\n <View\n style={[\n tw.style(\n isHorizontal ? 'flex-row' : 'flex-col',\n 'px-2 py-1',\n twClassName,\n ),\n style,\n ]}\n {...props}\n >\n {secondaryButtonProps && (\n <Button\n {...secondaryButtonProps}\n variant={ButtonVariant.Secondary}\n style={[tw.style(buttonBaseClass), secondaryButtonProps.style]}\n />\n )}\n {primaryButtonProps && (\n <Button\n {...primaryButtonProps}\n variant={ButtonVariant.Primary}\n style={[\n tw.style(buttonBaseClass, hasBothButtons && gapClass),\n primaryButtonProps.style,\n ]}\n />\n )}\n </View>\n );\n};\n"]}
1
+ {"version":3,"file":"BottomSheetFooter.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,OAAO,EAAE,WAAW,EAAE,6CAA6C;AACnE,OAAO,MAAK,cAAc;;AAC1B,O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B,IAAI,CACrB,CAAC,MAAM,CACL,IAAI,kBAAkB,CAAC,CACvB,OAAO,CAAC,CAAC,aAAa,CAAC,OAAO,CAAC,CAC/B,KAAK,CAAC,CAAC;gBACL,EAAE,CAAC,KAAK,CAAC,eAAe,EAAE,cAAc,IAAI,QAAQ,CAAC;gBACrD,kBAAkB,CAAC,KAAK;aACzB,CAAC,EACF,CACH,CACH;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\nimport { View } from 'react-native';\n\n// External dependencies.\nimport { Button, ButtonVariant } from '../Button';\n\n// Internal dependencies.\nimport type { BottomSheetFooterProps } from './BottomSheetFooter.types';\nimport { ButtonsAlignment } from './BottomSheetFooter.types';\n\nexport const BottomSheetFooter: React.FC<BottomSheetFooterProps> = ({\n style,\n twClassName,\n buttonsAlignment = ButtonsAlignment.Horizontal,\n primaryButtonProps,\n secondaryButtonProps,\n ...props\n}) => {\n const tw = useTailwind();\n const isHorizontal = buttonsAlignment === ButtonsAlignment.Horizontal;\n const buttonBaseClass = isHorizontal ? 'flex-1' : 'self-stretch';\n const gapClass = isHorizontal ? 'ml-4' : 'mt-4';\n const hasBothButtons =\n Boolean(primaryButtonProps) && Boolean(secondaryButtonProps);\n\n if (!primaryButtonProps && !secondaryButtonProps) {\n return null;\n }\n\n return (\n <View\n style={[\n tw.style(\n isHorizontal ? 'flex-row' : 'flex-col',\n 'px-2 py-1',\n twClassName,\n ),\n style,\n ]}\n {...props}\n >\n {secondaryButtonProps && (\n <Button\n {...secondaryButtonProps}\n variant={ButtonVariant.Secondary}\n style={[tw.style(buttonBaseClass), secondaryButtonProps.style]}\n />\n )}\n {primaryButtonProps && (\n <Button\n {...primaryButtonProps}\n variant={ButtonVariant.Primary}\n style={[\n tw.style(buttonBaseClass, hasBothButtons && gapClass),\n primaryButtonProps.style,\n ]}\n />\n )}\n </View>\n );\n};\n"]}
@@ -1,4 +1,4 @@
1
- import type { ViewProps } from "react-native/index.js";
1
+ import type { ViewProps } from "react-native";
2
2
  import type { ButtonProps } from "../Button/Button.types.cjs";
3
3
  /**
4
4
  * Buttons alignment options for the BottomSheetFooter.
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetFooter.types.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,8BAAqB;AAG9C,OAAO,KAAK,EAAE,WAAW,EAAE,mCAA+B;AAE1D;;GAEG;AACH,oBAAY,gBAAgB;IAC1B,UAAU,eAAe;IACzB,QAAQ,aAAa;CACtB;AAED;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;AAExE;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC;;;;OAIG;IACH,kBAAkB,CAAC,EAAE,4BAA4B,CAAC;IAClD;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,4BAA4B,CAAC;IACpD;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC"}
1
+ {"version":3,"file":"BottomSheetFooter.types.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,qBAAqB;AAG9C,OAAO,KAAK,EAAE,WAAW,EAAE,mCAA+B;AAE1D;;GAEG;AACH,oBAAY,gBAAgB;IAC1B,UAAU,eAAe;IACzB,QAAQ,aAAa;CACtB;AAED;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;AAExE;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC;;;;OAIG;IACH,kBAAkB,CAAC,EAAE,4BAA4B,CAAC;IAClD;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,4BAA4B,CAAC;IACpD;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC"}
@@ -1,4 +1,4 @@
1
- import type { ViewProps } from "react-native/index.js";
1
+ import type { ViewProps } from "react-native";
2
2
  import type { ButtonProps } from "../Button/Button.types.mjs";
3
3
  /**
4
4
  * Buttons alignment options for the BottomSheetFooter.
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetFooter.types.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,8BAAqB;AAG9C,OAAO,KAAK,EAAE,WAAW,EAAE,mCAA+B;AAE1D;;GAEG;AACH,oBAAY,gBAAgB;IAC1B,UAAU,eAAe;IACzB,QAAQ,aAAa;CACtB;AAED;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;AAExE;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC;;;;OAIG;IACH,kBAAkB,CAAC,EAAE,4BAA4B,CAAC;IAClD;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,4BAA4B,CAAC;IACpD;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC"}
1
+ {"version":3,"file":"BottomSheetFooter.types.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetFooter/BottomSheetFooter.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,qBAAqB;AAG9C,OAAO,KAAK,EAAE,WAAW,EAAE,mCAA+B;AAE1D;;GAEG;AACH,oBAAY,gBAAgB;IAC1B,UAAU,eAAe;IACzB,QAAQ,aAAa;CACtB;AAED;;GAEG;AACH,MAAM,MAAM,4BAA4B,GAAG,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;AAExE;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IACpC;;;;OAIG;IACH,kBAAkB,CAAC,EAAE,4BAA4B,CAAC;IAClD;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,4BAA4B,CAAC;IACpD;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,GAAG,SAAS,CAAC"}
@@ -11,15 +11,11 @@ const react_1 = __importDefault(require("react"));
11
11
  const ButtonIcon_1 = require("../ButtonIcon/index.cjs");
12
12
  const HeaderBase_1 = require("../HeaderBase/index.cjs");
13
13
  const Icon_1 = require("../Icon/index.cjs");
14
- // Internal dependencies.
15
- const BottomSheetHeader_constants_1 = require("./BottomSheetHeader.constants.cjs");
16
- const BottomSheetHeader_types_1 = require("./BottomSheetHeader.types.cjs");
17
- const BottomSheetHeader = ({ style, twClassName, children, onBack, backButtonProps, onClose, closeButtonProps, variant = BottomSheetHeader_types_1.BottomSheetHeaderVariant.Compact, ...props }) => {
14
+ const BottomSheetHeader = ({ style, twClassName, children, onBack, backButtonProps, onClose, closeButtonProps, ...props }) => {
18
15
  const tw = (0, design_system_twrnc_preset_1.useTailwind)();
19
16
  const startAccessory = onBack ? (<ButtonIcon_1.ButtonIcon iconName={Icon_1.IconName.ArrowLeft} onPress={onBack} size={ButtonIcon_1.ButtonIconSize.Md} {...backButtonProps}/>) : undefined;
20
17
  const endAccessory = onClose ? (<ButtonIcon_1.ButtonIcon iconName={Icon_1.IconName.Close} onPress={onClose} size={ButtonIcon_1.ButtonIconSize.Md} {...closeButtonProps}/>) : undefined;
21
- const headerBaseVariant = BottomSheetHeader_constants_1.BOTTOM_SHEET_HEADER_VARIANT_MAP[variant];
22
- return (<HeaderBase_1.HeaderBase {...props} style={[tw.style('px-4', twClassName), style]} startAccessory={startAccessory} endAccessory={endAccessory} variant={headerBaseVariant}>
18
+ return (<HeaderBase_1.HeaderBase {...props} style={[tw.style('px-4', twClassName), style]} startAccessory={startAccessory} endAccessory={endAccessory}>
23
19
  {children}
24
20
  </HeaderBase_1.HeaderBase>);
25
21
  };
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,qFAAmE;AACnE,kDAA0B;AAE1B,yBAAyB;AACzB,wDAA2D;AAC3D,wDAA2C;AAC3C,4CAAmC;AAEnC,yBAAyB;AACzB,mFAAgF;AAEhF,2EAAqE;AAE9D,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,WAAW,EACX,QAAQ,EACR,MAAM,EACN,eAAe,EACf,OAAO,EACP,gBAAgB,EAChB,OAAO,GAAG,kDAAwB,CAAC,OAAO,EAC1C,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,EAAE,GAAG,IAAA,wCAAW,GAAE,CAAC;IAEzB,MAAM,cAAc,GAAG,MAAM,CAAC,CAAC,CAAC,CAC9B,CAAC,uBAAU,CACT,QAAQ,CAAC,CAAC,eAAQ,CAAC,SAAS,CAAC,CAC7B,OAAO,CAAC,CAAC,MAAM,CAAC,CAChB,IAAI,CAAC,CAAC,2BAAc,CAAC,EAAE,CAAC,CACxB,IAAI,eAAe,CAAC,EACpB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IAEd,MAAM,YAAY,GAAG,OAAO,CAAC,CAAC,CAAC,CAC7B,CAAC,uBAAU,CACT,QAAQ,CAAC,CAAC,eAAQ,CAAC,KAAK,CAAC,CACzB,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,IAAI,CAAC,CAAC,2BAAc,CAAC,EAAE,CAAC,CACxB,IAAI,gBAAgB,CAAC,EACrB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IAEd,MAAM,iBAAiB,GAAG,6DAA+B,CAAC,OAAO,CAAC,CAAC;IAEnE,OAAO,CACL,CAAC,uBAAU,CACT,IAAI,KAAK,CAAC,CACV,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,WAAW,CAAC,EAAE,KAAK,CAAC,CAAC,CAC9C,cAAc,CAAC,CAAC,cAAc,CAAC,CAC/B,YAAY,CAAC,CAAC,YAAY,CAAC,CAC3B,OAAO,CAAC,CAAC,iBAAiB,CAAC,CAE3B;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,uBAAU,CAAC,CACd,CAAC;AACJ,CAAC,CAAC;AA5CW,QAAA,iBAAiB,qBA4C5B","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\n\n// External dependencies.\nimport { ButtonIcon, ButtonIconSize } from '../ButtonIcon';\nimport { HeaderBase } from '../HeaderBase';\nimport { IconName } from '../Icon';\n\n// Internal dependencies.\nimport { BOTTOM_SHEET_HEADER_VARIANT_MAP } from './BottomSheetHeader.constants';\nimport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\nimport { BottomSheetHeaderVariant } from './BottomSheetHeader.types';\n\nexport const BottomSheetHeader: React.FC<BottomSheetHeaderProps> = ({\n style,\n twClassName,\n children,\n onBack,\n backButtonProps,\n onClose,\n closeButtonProps,\n variant = BottomSheetHeaderVariant.Compact,\n ...props\n}) => {\n const tw = useTailwind();\n\n const startAccessory = onBack ? (\n <ButtonIcon\n iconName={IconName.ArrowLeft}\n onPress={onBack}\n size={ButtonIconSize.Md}\n {...backButtonProps}\n />\n ) : undefined;\n\n const endAccessory = onClose ? (\n <ButtonIcon\n iconName={IconName.Close}\n onPress={onClose}\n size={ButtonIconSize.Md}\n {...closeButtonProps}\n />\n ) : undefined;\n\n const headerBaseVariant = BOTTOM_SHEET_HEADER_VARIANT_MAP[variant];\n\n return (\n <HeaderBase\n {...props}\n style={[tw.style('px-4', twClassName), style]}\n startAccessory={startAccessory}\n endAccessory={endAccessory}\n variant={headerBaseVariant}\n >\n {children}\n </HeaderBase>\n );\n};\n"]}
1
+ {"version":3,"file":"BottomSheetHeader.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,qFAAmE;AACnE,kDAA0B;AAE1B,yBAAyB;AACzB,wDAA2D;AAC3D,wDAA2C;AAC3C,4CAAmC;AAI5B,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,WAAW,EACX,QAAQ,EACR,MAAM,EACN,eAAe,EACf,OAAO,EACP,gBAAgB,EAChB,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,EAAE,GAAG,IAAA,wCAAW,GAAE,CAAC;IAEzB,MAAM,cAAc,GAAG,MAAM,CAAC,CAAC,CAAC,CAC9B,CAAC,uBAAU,CACT,QAAQ,CAAC,CAAC,eAAQ,CAAC,SAAS,CAAC,CAC7B,OAAO,CAAC,CAAC,MAAM,CAAC,CAChB,IAAI,CAAC,CAAC,2BAAc,CAAC,EAAE,CAAC,CACxB,IAAI,eAAe,CAAC,EACpB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IAEd,MAAM,YAAY,GAAG,OAAO,CAAC,CAAC,CAAC,CAC7B,CAAC,uBAAU,CACT,QAAQ,CAAC,CAAC,eAAQ,CAAC,KAAK,CAAC,CACzB,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,IAAI,CAAC,CAAC,2BAAc,CAAC,EAAE,CAAC,CACxB,IAAI,gBAAgB,CAAC,EACrB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IACd,OAAO,CACL,CAAC,uBAAU,CACT,IAAI,KAAK,CAAC,CACV,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,WAAW,CAAC,EAAE,KAAK,CAAC,CAAC,CAC9C,cAAc,CAAC,CAAC,cAAc,CAAC,CAC/B,YAAY,CAAC,CAAC,YAAY,CAAC,CAE3B;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,uBAAU,CAAC,CACd,CAAC;AACJ,CAAC,CAAC;AAvCW,QAAA,iBAAiB,qBAuC5B","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\n\n// External dependencies.\nimport { ButtonIcon, ButtonIconSize } from '../ButtonIcon';\nimport { HeaderBase } from '../HeaderBase';\nimport { IconName } from '../Icon';\n\nimport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\n\nexport const BottomSheetHeader: React.FC<BottomSheetHeaderProps> = ({\n style,\n twClassName,\n children,\n onBack,\n backButtonProps,\n onClose,\n closeButtonProps,\n ...props\n}) => {\n const tw = useTailwind();\n\n const startAccessory = onBack ? (\n <ButtonIcon\n iconName={IconName.ArrowLeft}\n onPress={onBack}\n size={ButtonIconSize.Md}\n {...backButtonProps}\n />\n ) : undefined;\n\n const endAccessory = onClose ? (\n <ButtonIcon\n iconName={IconName.Close}\n onPress={onClose}\n size={ButtonIconSize.Md}\n {...closeButtonProps}\n />\n ) : undefined;\n return (\n <HeaderBase\n {...props}\n style={[tw.style('px-4', twClassName), style]}\n startAccessory={startAccessory}\n endAccessory={endAccessory}\n >\n {children}\n </HeaderBase>\n );\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,cAAc;AAS1B,OAAO,KAAK,EAAE,sBAAsB,EAAE,sCAAkC;AAGxE,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CA4C9D,CAAC"}
1
+ {"version":3,"file":"BottomSheetHeader.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,cAAc;AAO1B,OAAO,KAAK,EAAE,sBAAsB,EAAE,sCAAkC;AAExE,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CAuC9D,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,cAAc;AAS1B,OAAO,KAAK,EAAE,sBAAsB,EAAE,sCAAkC;AAGxE,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CA4C9D,CAAC"}
1
+ {"version":3,"file":"BottomSheetHeader.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,cAAc;AAO1B,OAAO,KAAK,EAAE,sBAAsB,EAAE,sCAAkC;AAExE,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CAuC9D,CAAC"}
@@ -12,15 +12,11 @@ const React = $importDefault($React);
12
12
  import { ButtonIcon, ButtonIconSize } from "../ButtonIcon/index.mjs";
13
13
  import { HeaderBase } from "../HeaderBase/index.mjs";
14
14
  import { IconName } from "../Icon/index.mjs";
15
- // Internal dependencies.
16
- import { BOTTOM_SHEET_HEADER_VARIANT_MAP } from "./BottomSheetHeader.constants.mjs";
17
- import { BottomSheetHeaderVariant } from "./BottomSheetHeader.types.mjs";
18
- export const BottomSheetHeader = ({ style, twClassName, children, onBack, backButtonProps, onClose, closeButtonProps, variant = BottomSheetHeaderVariant.Compact, ...props }) => {
15
+ export const BottomSheetHeader = ({ style, twClassName, children, onBack, backButtonProps, onClose, closeButtonProps, ...props }) => {
19
16
  const tw = useTailwind();
20
17
  const startAccessory = onBack ? (<ButtonIcon iconName={IconName.ArrowLeft} onPress={onBack} size={ButtonIconSize.Md} {...backButtonProps}/>) : undefined;
21
18
  const endAccessory = onClose ? (<ButtonIcon iconName={IconName.Close} onPress={onClose} size={ButtonIconSize.Md} {...closeButtonProps}/>) : undefined;
22
- const headerBaseVariant = BOTTOM_SHEET_HEADER_VARIANT_MAP[variant];
23
- return (<HeaderBase {...props} style={[tw.style('px-4', twClassName), style]} startAccessory={startAccessory} endAccessory={endAccessory} variant={headerBaseVariant}>
19
+ return (<HeaderBase {...props} style={[tw.style('px-4', twClassName), style]} startAccessory={startAccessory} endAccessory={endAccessory}>
24
20
  {children}
25
21
  </HeaderBase>);
26
22
  };
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,OAAO,EAAE,WAAW,EAAE,6CAA6C;AACnE,OAAO,MAAK,cAAc;;AAE1B,yBAAyB;AACzB,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,gCAAsB;AAC3D,OAAO,EAAE,UAAU,EAAE,gCAAsB;AAC3C,OAAO,EAAE,QAAQ,EAAE,0BAAgB;AAEnC,yBAAyB;AACzB,OAAO,EAAE,+BAA+B,EAAE,0CAAsC;AAEhF,OAAO,EAAE,wBAAwB,EAAE,sCAAkC;AAErE,MAAM,CAAC,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,WAAW,EACX,QAAQ,EACR,MAAM,EACN,eAAe,EACf,OAAO,EACP,gBAAgB,EAChB,OAAO,GAAG,wBAAwB,CAAC,OAAO,EAC1C,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,EAAE,GAAG,WAAW,EAAE,CAAC;IAEzB,MAAM,cAAc,GAAG,MAAM,CAAC,CAAC,CAAC,CAC9B,CAAC,UAAU,CACT,QAAQ,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,CAC7B,OAAO,CAAC,CAAC,MAAM,CAAC,CAChB,IAAI,CAAC,CAAC,cAAc,CAAC,EAAE,CAAC,CACxB,IAAI,eAAe,CAAC,EACpB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IAEd,MAAM,YAAY,GAAG,OAAO,CAAC,CAAC,CAAC,CAC7B,CAAC,UAAU,CACT,QAAQ,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CACzB,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,IAAI,CAAC,CAAC,cAAc,CAAC,EAAE,CAAC,CACxB,IAAI,gBAAgB,CAAC,EACrB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IAEd,MAAM,iBAAiB,GAAG,+BAA+B,CAAC,OAAO,CAAC,CAAC;IAEnE,OAAO,CACL,CAAC,UAAU,CACT,IAAI,KAAK,CAAC,CACV,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,WAAW,CAAC,EAAE,KAAK,CAAC,CAAC,CAC9C,cAAc,CAAC,CAAC,cAAc,CAAC,CAC/B,YAAY,CAAC,CAAC,YAAY,CAAC,CAC3B,OAAO,CAAC,CAAC,iBAAiB,CAAC,CAE3B;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,UAAU,CAAC,CACd,CAAC;AACJ,CAAC,CAAC","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\n\n// External dependencies.\nimport { ButtonIcon, ButtonIconSize } from '../ButtonIcon';\nimport { HeaderBase } from '../HeaderBase';\nimport { IconName } from '../Icon';\n\n// Internal dependencies.\nimport { BOTTOM_SHEET_HEADER_VARIANT_MAP } from './BottomSheetHeader.constants';\nimport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\nimport { BottomSheetHeaderVariant } from './BottomSheetHeader.types';\n\nexport const BottomSheetHeader: React.FC<BottomSheetHeaderProps> = ({\n style,\n twClassName,\n children,\n onBack,\n backButtonProps,\n onClose,\n closeButtonProps,\n variant = BottomSheetHeaderVariant.Compact,\n ...props\n}) => {\n const tw = useTailwind();\n\n const startAccessory = onBack ? (\n <ButtonIcon\n iconName={IconName.ArrowLeft}\n onPress={onBack}\n size={ButtonIconSize.Md}\n {...backButtonProps}\n />\n ) : undefined;\n\n const endAccessory = onClose ? (\n <ButtonIcon\n iconName={IconName.Close}\n onPress={onClose}\n size={ButtonIconSize.Md}\n {...closeButtonProps}\n />\n ) : undefined;\n\n const headerBaseVariant = BOTTOM_SHEET_HEADER_VARIANT_MAP[variant];\n\n return (\n <HeaderBase\n {...props}\n style={[tw.style('px-4', twClassName), style]}\n startAccessory={startAccessory}\n endAccessory={endAccessory}\n variant={headerBaseVariant}\n >\n {children}\n </HeaderBase>\n );\n};\n"]}
1
+ {"version":3,"file":"BottomSheetHeader.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.tsx"],"names":[],"mappings":";;;;;;AAAA,4BAA4B;AAC5B,OAAO,EAAE,WAAW,EAAE,6CAA6C;AACnE,OAAO,MAAK,cAAc;;AAE1B,yBAAyB;AACzB,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,gCAAsB;AAC3D,OAAO,EAAE,UAAU,EAAE,gCAAsB;AAC3C,OAAO,EAAE,QAAQ,EAAE,0BAAgB;AAInC,MAAM,CAAC,MAAM,iBAAiB,GAAqC,CAAC,EAClE,KAAK,EACL,WAAW,EACX,QAAQ,EACR,MAAM,EACN,eAAe,EACf,OAAO,EACP,gBAAgB,EAChB,GAAG,KAAK,EACT,EAAE,EAAE;IACH,MAAM,EAAE,GAAG,WAAW,EAAE,CAAC;IAEzB,MAAM,cAAc,GAAG,MAAM,CAAC,CAAC,CAAC,CAC9B,CAAC,UAAU,CACT,QAAQ,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,CAC7B,OAAO,CAAC,CAAC,MAAM,CAAC,CAChB,IAAI,CAAC,CAAC,cAAc,CAAC,EAAE,CAAC,CACxB,IAAI,eAAe,CAAC,EACpB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IAEd,MAAM,YAAY,GAAG,OAAO,CAAC,CAAC,CAAC,CAC7B,CAAC,UAAU,CACT,QAAQ,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CACzB,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,IAAI,CAAC,CAAC,cAAc,CAAC,EAAE,CAAC,CACxB,IAAI,gBAAgB,CAAC,EACrB,CACH,CAAC,CAAC,CAAC,SAAS,CAAC;IACd,OAAO,CACL,CAAC,UAAU,CACT,IAAI,KAAK,CAAC,CACV,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,MAAM,EAAE,WAAW,CAAC,EAAE,KAAK,CAAC,CAAC,CAC9C,cAAc,CAAC,CAAC,cAAc,CAAC,CAC/B,YAAY,CAAC,CAAC,YAAY,CAAC,CAE3B;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,UAAU,CAAC,CACd,CAAC;AACJ,CAAC,CAAC","sourcesContent":["// Third party dependencies.\nimport { useTailwind } from '@metamask/design-system-twrnc-preset';\nimport React from 'react';\n\n// External dependencies.\nimport { ButtonIcon, ButtonIconSize } from '../ButtonIcon';\nimport { HeaderBase } from '../HeaderBase';\nimport { IconName } from '../Icon';\n\nimport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\n\nexport const BottomSheetHeader: React.FC<BottomSheetHeaderProps> = ({\n style,\n twClassName,\n children,\n onBack,\n backButtonProps,\n onClose,\n closeButtonProps,\n ...props\n}) => {\n const tw = useTailwind();\n\n const startAccessory = onBack ? (\n <ButtonIcon\n iconName={IconName.ArrowLeft}\n onPress={onBack}\n size={ButtonIconSize.Md}\n {...backButtonProps}\n />\n ) : undefined;\n\n const endAccessory = onClose ? (\n <ButtonIcon\n iconName={IconName.Close}\n onPress={onClose}\n size={ButtonIconSize.Md}\n {...closeButtonProps}\n />\n ) : undefined;\n return (\n <HeaderBase\n {...props}\n style={[tw.style('px-4', twClassName), style]}\n startAccessory={startAccessory}\n endAccessory={endAccessory}\n >\n {children}\n </HeaderBase>\n );\n};\n"]}
@@ -1,14 +1,3 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BottomSheetHeaderVariant = void 0;
4
- /**
5
- * Variant options for BottomSheetHeader component.
6
- * - Compact: Center-aligned title with HeadingSm text (default)
7
- * - Display: Left-aligned title with HeadingLg text
8
- */
9
- var BottomSheetHeaderVariant;
10
- (function (BottomSheetHeaderVariant) {
11
- BottomSheetHeaderVariant["Display"] = "display";
12
- BottomSheetHeaderVariant["Compact"] = "compact";
13
- })(BottomSheetHeaderVariant || (exports.BottomSheetHeaderVariant = BottomSheetHeaderVariant = {}));
14
3
  //# sourceMappingURL=BottomSheetHeader.types.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.types.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":";;;AAGA;;;;GAIG;AACH,IAAY,wBAGX;AAHD,WAAY,wBAAwB;IAClC,+CAAmB,CAAA;IACnB,+CAAmB,CAAA;AACrB,CAAC,EAHW,wBAAwB,wCAAxB,wBAAwB,QAGnC","sourcesContent":["import type { ButtonIconProps } from '../ButtonIcon/ButtonIcon.types';\nimport type { HeaderBaseProps } from '../HeaderBase/HeaderBase.types';\n\n/**\n * Variant options for BottomSheetHeader component.\n * - Compact: Center-aligned title with HeadingSm text (default)\n * - Display: Left-aligned title with HeadingLg text\n */\nexport enum BottomSheetHeaderVariant {\n Display = 'display',\n Compact = 'compact',\n}\n\n/**\n * BottomSheetHeader component props.\n *\n * Extends HeaderBase's props (which extends ViewProps) to inherit standard\n * props such as `testID`, `accessibilityLabel`, and other View props.\n */\nexport type BottomSheetHeaderProps = {\n /**\n * Callback function triggered when the back button is pressed.\n * When provided, a back arrow ButtonIcon is rendered as the start accessory.\n */\n onBack?: () => void;\n /**\n * Props spread to the back ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n backButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n /**\n * Callback function triggered when the close button is pressed.\n * When provided, a close ButtonIcon is rendered as the end accessory.\n */\n onClose?: () => void;\n /**\n * Props spread to the close ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n closeButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n /**\n * Variant controlling header alignment and text size.\n * - Compact: center-aligned with HeadingSm text\n * - Display: left-aligned with HeadingLg text\n *\n * @default BottomSheetHeaderVariant.Compact\n */\n variant?: BottomSheetHeaderVariant;\n} & Omit<HeaderBaseProps, 'variant'>;\n"]}
1
+ {"version":3,"file":"BottomSheetHeader.types.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ButtonIconProps } from '../ButtonIcon/ButtonIcon.types';\nimport type { HeaderBaseProps } from '../HeaderBase/HeaderBase.types';\n\n/**\n * BottomSheetHeader component props.\n *\n * Extends HeaderBase's root and title props to inherit standard props such as\n * `testID`, `accessibilityLabel`, `textProps`, and other View props.\n * Start and end accessories are controlled internally via `onBack` and\n * `onClose`, so `startAccessory`, `endAccessory`, `startButtonIconProps`,\n * and `endButtonIconProps` are not part of this API.\n */\nexport type BottomSheetHeaderProps = {\n /**\n * Callback function triggered when the back button is pressed.\n * When provided, a back arrow ButtonIcon is rendered as the start accessory.\n */\n onBack?: () => void;\n /**\n * Props spread to the back ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n backButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n /**\n * Callback function triggered when the close button is pressed.\n * When provided, a close ButtonIcon is rendered as the end accessory.\n */\n onClose?: () => void;\n /**\n * Props spread to the close ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n closeButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n} & Omit<\n HeaderBaseProps,\n | 'startAccessory'\n | 'endAccessory'\n | 'startButtonIconProps'\n | 'endButtonIconProps'\n>;\n"]}
@@ -1,19 +1,13 @@
1
1
  import type { ButtonIconProps } from "../ButtonIcon/ButtonIcon.types.cjs";
2
2
  import type { HeaderBaseProps } from "../HeaderBase/HeaderBase.types.cjs";
3
- /**
4
- * Variant options for BottomSheetHeader component.
5
- * - Compact: Center-aligned title with HeadingSm text (default)
6
- * - Display: Left-aligned title with HeadingLg text
7
- */
8
- export declare enum BottomSheetHeaderVariant {
9
- Display = "display",
10
- Compact = "compact"
11
- }
12
3
  /**
13
4
  * BottomSheetHeader component props.
14
5
  *
15
- * Extends HeaderBase's props (which extends ViewProps) to inherit standard
16
- * props such as `testID`, `accessibilityLabel`, and other View props.
6
+ * Extends HeaderBase's root and title props to inherit standard props such as
7
+ * `testID`, `accessibilityLabel`, `textProps`, and other View props.
8
+ * Start and end accessories are controlled internally via `onBack` and
9
+ * `onClose`, so `startAccessory`, `endAccessory`, `startButtonIconProps`,
10
+ * and `endButtonIconProps` are not part of this API.
17
11
  */
18
12
  export type BottomSheetHeaderProps = {
19
13
  /**
@@ -38,13 +32,5 @@ export type BottomSheetHeaderProps = {
38
32
  * Note: `iconName` and `onPress` are managed internally and excluded.
39
33
  */
40
34
  closeButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;
41
- /**
42
- * Variant controlling header alignment and text size.
43
- * - Compact: center-aligned with HeadingSm text
44
- * - Display: left-aligned with HeadingLg text
45
- *
46
- * @default BottomSheetHeaderVariant.Compact
47
- */
48
- variant?: BottomSheetHeaderVariant;
49
- } & Omit<HeaderBaseProps, 'variant'>;
35
+ } & Omit<HeaderBaseProps, 'startAccessory' | 'endAccessory' | 'startButtonIconProps' | 'endButtonIconProps'>;
50
36
  //# sourceMappingURL=BottomSheetHeader.types.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.types.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AACtE,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AAEtE;;;;GAIG;AACH,oBAAY,wBAAwB;IAClC,OAAO,YAAY;IACnB,OAAO,YAAY;CACpB;AAED;;;;;GAKG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB;;;;OAIG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;IACzE;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;IAC1E;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,wBAAwB,CAAC;CACpC,GAAG,IAAI,CAAC,eAAe,EAAE,SAAS,CAAC,CAAC"}
1
+ {"version":3,"file":"BottomSheetHeader.types.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AACtE,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AAEtE;;;;;;;;GAQG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB;;;;OAIG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;IACzE;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;CAC3E,GAAG,IAAI,CACN,eAAe,EACb,gBAAgB,GAChB,cAAc,GACd,sBAAsB,GACtB,oBAAoB,CACvB,CAAC"}
@@ -1,19 +1,13 @@
1
1
  import type { ButtonIconProps } from "../ButtonIcon/ButtonIcon.types.mjs";
2
2
  import type { HeaderBaseProps } from "../HeaderBase/HeaderBase.types.mjs";
3
- /**
4
- * Variant options for BottomSheetHeader component.
5
- * - Compact: Center-aligned title with HeadingSm text (default)
6
- * - Display: Left-aligned title with HeadingLg text
7
- */
8
- export declare enum BottomSheetHeaderVariant {
9
- Display = "display",
10
- Compact = "compact"
11
- }
12
3
  /**
13
4
  * BottomSheetHeader component props.
14
5
  *
15
- * Extends HeaderBase's props (which extends ViewProps) to inherit standard
16
- * props such as `testID`, `accessibilityLabel`, and other View props.
6
+ * Extends HeaderBase's root and title props to inherit standard props such as
7
+ * `testID`, `accessibilityLabel`, `textProps`, and other View props.
8
+ * Start and end accessories are controlled internally via `onBack` and
9
+ * `onClose`, so `startAccessory`, `endAccessory`, `startButtonIconProps`,
10
+ * and `endButtonIconProps` are not part of this API.
17
11
  */
18
12
  export type BottomSheetHeaderProps = {
19
13
  /**
@@ -38,13 +32,5 @@ export type BottomSheetHeaderProps = {
38
32
  * Note: `iconName` and `onPress` are managed internally and excluded.
39
33
  */
40
34
  closeButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;
41
- /**
42
- * Variant controlling header alignment and text size.
43
- * - Compact: center-aligned with HeadingSm text
44
- * - Display: left-aligned with HeadingLg text
45
- *
46
- * @default BottomSheetHeaderVariant.Compact
47
- */
48
- variant?: BottomSheetHeaderVariant;
49
- } & Omit<HeaderBaseProps, 'variant'>;
35
+ } & Omit<HeaderBaseProps, 'startAccessory' | 'endAccessory' | 'startButtonIconProps' | 'endButtonIconProps'>;
50
36
  //# sourceMappingURL=BottomSheetHeader.types.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.types.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AACtE,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AAEtE;;;;GAIG;AACH,oBAAY,wBAAwB;IAClC,OAAO,YAAY;IACnB,OAAO,YAAY;CACpB;AAED;;;;;GAKG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB;;;;OAIG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;IACzE;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;IAC1E;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,wBAAwB,CAAC;CACpC,GAAG,IAAI,CAAC,eAAe,EAAE,SAAS,CAAC,CAAC"}
1
+ {"version":3,"file":"BottomSheetHeader.types.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AACtE,OAAO,KAAK,EAAE,eAAe,EAAE,2CAAuC;AAEtE;;;;;;;;GAQG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB;;;;OAIG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;IACzE;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;;OAIG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,eAAe,EAAE,UAAU,GAAG,SAAS,CAAC,CAAC,CAAC;CAC3E,GAAG,IAAI,CACN,eAAe,EACb,gBAAgB,GAChB,cAAc,GACd,sBAAsB,GACtB,oBAAoB,CACvB,CAAC"}
@@ -1,11 +1,2 @@
1
- /**
2
- * Variant options for BottomSheetHeader component.
3
- * - Compact: Center-aligned title with HeadingSm text (default)
4
- * - Display: Left-aligned title with HeadingLg text
5
- */
6
- export var BottomSheetHeaderVariant;
7
- (function (BottomSheetHeaderVariant) {
8
- BottomSheetHeaderVariant["Display"] = "display";
9
- BottomSheetHeaderVariant["Compact"] = "compact";
10
- })(BottomSheetHeaderVariant || (BottomSheetHeaderVariant = {}));
1
+ export {};
11
2
  //# sourceMappingURL=BottomSheetHeader.types.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheetHeader.types.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,MAAM,CAAN,IAAY,wBAGX;AAHD,WAAY,wBAAwB;IAClC,+CAAmB,CAAA;IACnB,+CAAmB,CAAA;AACrB,CAAC,EAHW,wBAAwB,KAAxB,wBAAwB,QAGnC","sourcesContent":["import type { ButtonIconProps } from '../ButtonIcon/ButtonIcon.types';\nimport type { HeaderBaseProps } from '../HeaderBase/HeaderBase.types';\n\n/**\n * Variant options for BottomSheetHeader component.\n * - Compact: Center-aligned title with HeadingSm text (default)\n * - Display: Left-aligned title with HeadingLg text\n */\nexport enum BottomSheetHeaderVariant {\n Display = 'display',\n Compact = 'compact',\n}\n\n/**\n * BottomSheetHeader component props.\n *\n * Extends HeaderBase's props (which extends ViewProps) to inherit standard\n * props such as `testID`, `accessibilityLabel`, and other View props.\n */\nexport type BottomSheetHeaderProps = {\n /**\n * Callback function triggered when the back button is pressed.\n * When provided, a back arrow ButtonIcon is rendered as the start accessory.\n */\n onBack?: () => void;\n /**\n * Props spread to the back ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n backButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n /**\n * Callback function triggered when the close button is pressed.\n * When provided, a close ButtonIcon is rendered as the end accessory.\n */\n onClose?: () => void;\n /**\n * Props spread to the close ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n closeButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n /**\n * Variant controlling header alignment and text size.\n * - Compact: center-aligned with HeadingSm text\n * - Display: left-aligned with HeadingLg text\n *\n * @default BottomSheetHeaderVariant.Compact\n */\n variant?: BottomSheetHeaderVariant;\n} & Omit<HeaderBaseProps, 'variant'>;\n"]}
1
+ {"version":3,"file":"BottomSheetHeader.types.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/BottomSheetHeader.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ButtonIconProps } from '../ButtonIcon/ButtonIcon.types';\nimport type { HeaderBaseProps } from '../HeaderBase/HeaderBase.types';\n\n/**\n * BottomSheetHeader component props.\n *\n * Extends HeaderBase's root and title props to inherit standard props such as\n * `testID`, `accessibilityLabel`, `textProps`, and other View props.\n * Start and end accessories are controlled internally via `onBack` and\n * `onClose`, so `startAccessory`, `endAccessory`, `startButtonIconProps`,\n * and `endButtonIconProps` are not part of this API.\n */\nexport type BottomSheetHeaderProps = {\n /**\n * Callback function triggered when the back button is pressed.\n * When provided, a back arrow ButtonIcon is rendered as the start accessory.\n */\n onBack?: () => void;\n /**\n * Props spread to the back ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n backButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n /**\n * Callback function triggered when the close button is pressed.\n * When provided, a close ButtonIcon is rendered as the end accessory.\n */\n onClose?: () => void;\n /**\n * Props spread to the close ButtonIcon component for additional properties\n * like `testID` or `accessibilityLabel`. Use this for testing or accessibility purposes.\n * Note: `iconName` and `onPress` are managed internally and excluded.\n */\n closeButtonProps?: Partial<Omit<ButtonIconProps, 'iconName' | 'onPress'>>;\n} & Omit<\n HeaderBaseProps,\n | 'startAccessory'\n | 'endAccessory'\n | 'startButtonIconProps'\n | 'endButtonIconProps'\n>;\n"]}
@@ -1,8 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BottomSheetHeaderVariant = exports.BottomSheetHeader = void 0;
3
+ exports.BottomSheetHeader = void 0;
4
4
  var BottomSheetHeader_1 = require("./BottomSheetHeader.cjs");
5
5
  Object.defineProperty(exports, "BottomSheetHeader", { enumerable: true, get: function () { return BottomSheetHeader_1.BottomSheetHeader; } });
6
- var BottomSheetHeader_types_1 = require("./BottomSheetHeader.types.cjs");
7
- Object.defineProperty(exports, "BottomSheetHeaderVariant", { enumerable: true, get: function () { return BottomSheetHeader_types_1.BottomSheetHeaderVariant; } });
8
6
  //# sourceMappingURL=index.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":";;;AAAA,6DAAwD;AAA/C,sHAAA,iBAAiB,OAAA;AAC1B,yEAAqE;AAA5D,mIAAA,wBAAwB,OAAA","sourcesContent":["export { BottomSheetHeader } from './BottomSheetHeader';\nexport { BottomSheetHeaderVariant } from './BottomSheetHeader.types';\nexport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\n"]}
1
+ {"version":3,"file":"index.cjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":";;;AAAA,6DAAwD;AAA/C,sHAAA,iBAAiB,OAAA","sourcesContent":["export { BottomSheetHeader } from './BottomSheetHeader';\nexport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\n"]}
@@ -1,4 +1,3 @@
1
1
  export { BottomSheetHeader } from "./BottomSheetHeader.cjs";
2
- export { BottomSheetHeaderVariant } from "./BottomSheetHeader.types.cjs";
3
2
  export type { BottomSheetHeaderProps } from "./BottomSheetHeader.types.cjs";
4
3
  //# sourceMappingURL=index.d.cts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gCAA4B;AACxD,OAAO,EAAE,wBAAwB,EAAE,sCAAkC;AACrE,YAAY,EAAE,sBAAsB,EAAE,sCAAkC"}
1
+ {"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gCAA4B;AACxD,YAAY,EAAE,sBAAsB,EAAE,sCAAkC"}
@@ -1,4 +1,3 @@
1
1
  export { BottomSheetHeader } from "./BottomSheetHeader.mjs";
2
- export { BottomSheetHeaderVariant } from "./BottomSheetHeader.types.mjs";
3
2
  export type { BottomSheetHeaderProps } from "./BottomSheetHeader.types.mjs";
4
3
  //# sourceMappingURL=index.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gCAA4B;AACxD,OAAO,EAAE,wBAAwB,EAAE,sCAAkC;AACrE,YAAY,EAAE,sBAAsB,EAAE,sCAAkC"}
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gCAA4B;AACxD,YAAY,EAAE,sBAAsB,EAAE,sCAAkC"}
@@ -1,3 +1,2 @@
1
1
  export { BottomSheetHeader } from "./BottomSheetHeader.mjs";
2
- export { BottomSheetHeaderVariant } from "./BottomSheetHeader.types.mjs";
3
2
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gCAA4B;AACxD,OAAO,EAAE,wBAAwB,EAAE,sCAAkC","sourcesContent":["export { BottomSheetHeader } from './BottomSheetHeader';\nexport { BottomSheetHeaderVariant } from './BottomSheetHeader.types';\nexport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\n"]}
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/components/BottomSheetHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,gCAA4B","sourcesContent":["export { BottomSheetHeader } from './BottomSheetHeader';\nexport type { BottomSheetHeaderProps } from './BottomSheetHeader.types';\n"]}
@@ -26,11 +26,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
26
26
  exports.BottomSheetOverlay = void 0;
27
27
  const design_system_twrnc_preset_1 = require("@metamask/design-system-twrnc-preset");
28
28
  const react_1 = __importStar(require("react"));
29
- const react_native_1 = require("react-native/index.js");
29
+ const react_native_1 = require("react-native");
30
30
  const BottomSheetOverlay_constants_1 = require("./BottomSheetOverlay.constants.cjs");
31
31
  const BottomSheetOverlay = ({ style, twClassName, onPress, touchableOpacityProps, ...props }) => {
32
32
  const tw = (0, design_system_twrnc_preset_1.useTailwind)();
33
- const opacityVal = (0, react_native_1.useAnimatedValue)(0);
33
+ const opacityVal = (0, react_1.useRef)(new react_native_1.Animated.Value(0)).current;
34
34
  (0, react_1.useEffect)(() => {
35
35
  react_native_1.Animated.timing(opacityVal, {
36
36
  toValue: 1,