@metamask-previews/design-system-react-native 0.0.0-preview.6fee845 → 0.0.0-preview.8561168

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 (371) hide show
  1. package/dist/components/AvatarAccount/AvatarAccount.constants.d.ts +3 -0
  2. package/dist/components/AvatarAccount/AvatarAccount.constants.d.ts.map +1 -0
  3. package/dist/components/AvatarAccount/AvatarAccount.constants.js +12 -0
  4. package/dist/components/AvatarAccount/AvatarAccount.constants.js.map +1 -0
  5. package/dist/components/AvatarAccount/AvatarAccount.d.ts +5 -0
  6. package/dist/components/AvatarAccount/AvatarAccount.d.ts.map +1 -0
  7. package/dist/components/AvatarAccount/AvatarAccount.js +29 -0
  8. package/dist/components/AvatarAccount/AvatarAccount.js.map +1 -0
  9. package/dist/components/AvatarAccount/AvatarAccount.types.d.ts +20 -0
  10. package/dist/components/AvatarAccount/AvatarAccount.types.d.ts.map +1 -0
  11. package/dist/components/AvatarAccount/AvatarAccount.types.js +9 -0
  12. package/dist/components/AvatarAccount/AvatarAccount.types.js.map +1 -0
  13. package/dist/components/AvatarAccount/index.d.ts +5 -0
  14. package/dist/components/AvatarAccount/index.d.ts.map +1 -0
  15. package/dist/components/AvatarAccount/index.js +13 -0
  16. package/dist/components/AvatarAccount/index.js.map +1 -0
  17. package/dist/components/AvatarFavicon/AvatarFavicon.constants.d.ts +3 -0
  18. package/dist/components/AvatarFavicon/AvatarFavicon.constants.d.ts.map +1 -0
  19. package/dist/components/AvatarFavicon/AvatarFavicon.constants.js +12 -0
  20. package/dist/components/AvatarFavicon/AvatarFavicon.constants.js.map +1 -0
  21. package/dist/components/AvatarFavicon/AvatarFavicon.d.ts +5 -0
  22. package/dist/components/AvatarFavicon/AvatarFavicon.d.ts.map +1 -0
  23. package/dist/components/AvatarFavicon/AvatarFavicon.js +53 -0
  24. package/dist/components/AvatarFavicon/AvatarFavicon.js.map +1 -0
  25. package/dist/components/AvatarFavicon/AvatarFavicon.types.d.ts +12 -0
  26. package/dist/components/AvatarFavicon/AvatarFavicon.types.d.ts.map +1 -0
  27. package/dist/components/AvatarFavicon/AvatarFavicon.types.js +3 -0
  28. package/dist/components/AvatarFavicon/AvatarFavicon.types.js.map +1 -0
  29. package/dist/components/AvatarFavicon/index.d.ts +4 -0
  30. package/dist/components/AvatarFavicon/index.d.ts.map +1 -0
  31. package/dist/components/AvatarFavicon/index.js +11 -0
  32. package/dist/components/AvatarFavicon/index.js.map +1 -0
  33. package/dist/components/AvatarIcon/AvatarIcon.constants.d.ts +9 -0
  34. package/dist/components/AvatarIcon/AvatarIcon.constants.d.ts.map +1 -0
  35. package/dist/components/AvatarIcon/AvatarIcon.constants.js +35 -0
  36. package/dist/components/AvatarIcon/AvatarIcon.constants.js.map +1 -0
  37. package/dist/components/AvatarIcon/AvatarIcon.d.ts +5 -0
  38. package/dist/components/AvatarIcon/AvatarIcon.d.ts.map +1 -0
  39. package/dist/components/AvatarIcon/AvatarIcon.js +49 -0
  40. package/dist/components/AvatarIcon/AvatarIcon.js.map +1 -0
  41. package/dist/components/AvatarIcon/AvatarIcon.types.d.ts +28 -0
  42. package/dist/components/AvatarIcon/AvatarIcon.types.d.ts.map +1 -0
  43. package/dist/components/AvatarIcon/AvatarIcon.types.js +12 -0
  44. package/dist/components/AvatarIcon/AvatarIcon.types.js.map +1 -0
  45. package/dist/components/AvatarIcon/AvatarIcon.utilities.d.ts +24 -0
  46. package/dist/components/AvatarIcon/AvatarIcon.utilities.d.ts.map +1 -0
  47. package/dist/components/AvatarIcon/AvatarIcon.utilities.js +30 -0
  48. package/dist/components/AvatarIcon/AvatarIcon.utilities.js.map +1 -0
  49. package/dist/components/AvatarIcon/index.d.ts +5 -0
  50. package/dist/components/AvatarIcon/index.d.ts.map +1 -0
  51. package/dist/components/AvatarIcon/index.js +13 -0
  52. package/dist/components/AvatarIcon/index.js.map +1 -0
  53. package/dist/components/AvatarNetwork/AvatarNetwork.constants.d.ts +3 -0
  54. package/dist/components/AvatarNetwork/AvatarNetwork.constants.d.ts.map +1 -0
  55. package/dist/components/AvatarNetwork/AvatarNetwork.constants.js +12 -0
  56. package/dist/components/AvatarNetwork/AvatarNetwork.constants.js.map +1 -0
  57. package/dist/components/AvatarNetwork/AvatarNetwork.d.ts +5 -0
  58. package/dist/components/AvatarNetwork/AvatarNetwork.d.ts.map +1 -0
  59. package/dist/components/AvatarNetwork/AvatarNetwork.js +53 -0
  60. package/dist/components/AvatarNetwork/AvatarNetwork.js.map +1 -0
  61. package/dist/components/AvatarNetwork/AvatarNetwork.types.d.ts +12 -0
  62. package/dist/components/AvatarNetwork/AvatarNetwork.types.d.ts.map +1 -0
  63. package/dist/components/AvatarNetwork/AvatarNetwork.types.js +3 -0
  64. package/dist/components/AvatarNetwork/AvatarNetwork.types.js.map +1 -0
  65. package/dist/components/AvatarNetwork/index.d.ts +4 -0
  66. package/dist/components/AvatarNetwork/index.d.ts.map +1 -0
  67. package/dist/components/AvatarNetwork/index.js +11 -0
  68. package/dist/components/AvatarNetwork/index.js.map +1 -0
  69. package/dist/components/AvatarToken/AvatarToken.constants.d.ts +3 -0
  70. package/dist/components/AvatarToken/AvatarToken.constants.d.ts.map +1 -0
  71. package/dist/components/AvatarToken/AvatarToken.constants.js +12 -0
  72. package/dist/components/AvatarToken/AvatarToken.constants.js.map +1 -0
  73. package/dist/components/AvatarToken/AvatarToken.d.ts +5 -0
  74. package/dist/components/AvatarToken/AvatarToken.d.ts.map +1 -0
  75. package/dist/components/AvatarToken/AvatarToken.js +53 -0
  76. package/dist/components/AvatarToken/AvatarToken.js.map +1 -0
  77. package/dist/components/AvatarToken/AvatarToken.types.d.ts +12 -0
  78. package/dist/components/AvatarToken/AvatarToken.types.d.ts.map +1 -0
  79. package/dist/components/AvatarToken/AvatarToken.types.js +3 -0
  80. package/dist/components/AvatarToken/AvatarToken.types.js.map +1 -0
  81. package/dist/components/AvatarToken/index.d.ts +4 -0
  82. package/dist/components/AvatarToken/index.d.ts.map +1 -0
  83. package/dist/components/AvatarToken/index.js +11 -0
  84. package/dist/components/AvatarToken/index.js.map +1 -0
  85. package/dist/components/Button/Button.constants.d.ts +2 -0
  86. package/dist/components/Button/Button.constants.d.ts.map +1 -0
  87. package/dist/components/Button/Button.constants.js +7 -0
  88. package/dist/components/Button/Button.constants.js.map +1 -0
  89. package/dist/components/Button/Button.d.ts +5 -0
  90. package/dist/components/Button/Button.d.ts.map +1 -0
  91. package/dist/components/Button/Button.js +25 -0
  92. package/dist/components/Button/Button.js.map +1 -0
  93. package/dist/components/Button/Button.types.d.ts +23 -0
  94. package/dist/components/Button/Button.types.d.ts.map +1 -0
  95. package/dist/components/Button/Button.types.js +15 -0
  96. package/dist/components/Button/Button.types.js.map +1 -0
  97. package/dist/components/Button/index.d.ts +4 -0
  98. package/dist/components/Button/index.d.ts.map +1 -0
  99. package/dist/components/Button/index.js +12 -0
  100. package/dist/components/Button/index.js.map +1 -0
  101. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.constants.d.ts +3 -0
  102. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.constants.d.ts.map +1 -0
  103. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.constants.js +29 -0
  104. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.constants.js.map +1 -0
  105. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.d.ts +5 -0
  106. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.d.ts.map +1 -0
  107. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.js +97 -0
  108. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.js.map +1 -0
  109. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.types.d.ts +17 -0
  110. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.types.d.ts.map +1 -0
  111. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.types.js +3 -0
  112. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.types.js.map +1 -0
  113. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.utilities.d.ts +78 -0
  114. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.utilities.d.ts.map +1 -0
  115. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.utilities.js +122 -0
  116. package/dist/components/Button/variants/ButtonPrimary/ButtonPrimary.utilities.js.map +1 -0
  117. package/dist/components/Button/variants/ButtonPrimary/index.d.ts +4 -0
  118. package/dist/components/Button/variants/ButtonPrimary/index.d.ts.map +1 -0
  119. package/dist/components/Button/variants/ButtonPrimary/index.js +11 -0
  120. package/dist/components/Button/variants/ButtonPrimary/index.js.map +1 -0
  121. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.constants.d.ts +3 -0
  122. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.constants.d.ts.map +1 -0
  123. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.constants.js +29 -0
  124. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.constants.js.map +1 -0
  125. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.d.ts +5 -0
  126. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.d.ts.map +1 -0
  127. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.js +90 -0
  128. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.js.map +1 -0
  129. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.types.d.ts +17 -0
  130. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.types.d.ts.map +1 -0
  131. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.types.js +3 -0
  132. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.types.js.map +1 -0
  133. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.utilities.d.ts +90 -0
  134. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.utilities.d.ts.map +1 -0
  135. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.utilities.js +145 -0
  136. package/dist/components/Button/variants/ButtonSecondary/ButtonSecondary.utilities.js.map +1 -0
  137. package/dist/components/Button/variants/ButtonSecondary/index.d.ts +4 -0
  138. package/dist/components/Button/variants/ButtonSecondary/index.d.ts.map +1 -0
  139. package/dist/components/Button/variants/ButtonSecondary/index.js +11 -0
  140. package/dist/components/Button/variants/ButtonSecondary/index.js.map +1 -0
  141. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.constants.d.ts +3 -0
  142. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.constants.d.ts.map +1 -0
  143. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.constants.js +29 -0
  144. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.constants.js.map +1 -0
  145. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.d.ts +5 -0
  146. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.d.ts.map +1 -0
  147. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.js +90 -0
  148. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.js.map +1 -0
  149. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.types.d.ts +17 -0
  150. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.types.d.ts.map +1 -0
  151. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.types.js +3 -0
  152. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.types.js.map +1 -0
  153. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.utilities.d.ts +88 -0
  154. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.utilities.d.ts.map +1 -0
  155. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.utilities.js +147 -0
  156. package/dist/components/Button/variants/ButtonTertiary/ButtonTertiary.utilities.js.map +1 -0
  157. package/dist/components/Button/variants/ButtonTertiary/index.d.ts +4 -0
  158. package/dist/components/Button/variants/ButtonTertiary/index.d.ts.map +1 -0
  159. package/dist/components/Button/variants/ButtonTertiary/index.js +11 -0
  160. package/dist/components/Button/variants/ButtonTertiary/index.js.map +1 -0
  161. package/dist/components/ButtonIcon/ButtonIcon.constants.d.ts +6 -0
  162. package/dist/components/ButtonIcon/ButtonIcon.constants.d.ts.map +1 -0
  163. package/dist/components/ButtonIcon/ButtonIcon.constants.js +20 -0
  164. package/dist/components/ButtonIcon/ButtonIcon.constants.js.map +1 -0
  165. package/dist/components/ButtonIcon/ButtonIcon.d.ts +5 -0
  166. package/dist/components/ButtonIcon/ButtonIcon.d.ts.map +1 -0
  167. package/dist/components/ButtonIcon/ButtonIcon.js +72 -0
  168. package/dist/components/ButtonIcon/ButtonIcon.js.map +1 -0
  169. package/dist/components/ButtonIcon/ButtonIcon.types.d.ts +60 -0
  170. package/dist/components/ButtonIcon/ButtonIcon.types.d.ts.map +1 -0
  171. package/dist/components/ButtonIcon/ButtonIcon.types.js +19 -0
  172. package/dist/components/ButtonIcon/ButtonIcon.types.js.map +1 -0
  173. package/dist/components/ButtonIcon/ButtonIcon.utilities.d.ts +55 -0
  174. package/dist/components/ButtonIcon/ButtonIcon.utilities.d.ts.map +1 -0
  175. package/dist/components/ButtonIcon/ButtonIcon.utilities.js +73 -0
  176. package/dist/components/ButtonIcon/ButtonIcon.utilities.js.map +1 -0
  177. package/dist/components/ButtonIcon/index.d.ts +4 -0
  178. package/dist/components/ButtonIcon/index.d.ts.map +1 -0
  179. package/dist/components/ButtonIcon/index.js +11 -0
  180. package/dist/components/ButtonIcon/index.js.map +1 -0
  181. package/dist/components/Icon/Icon.assets.d.ts +6 -0
  182. package/dist/components/Icon/Icon.assets.d.ts.map +1 -0
  183. package/dist/components/Icon/Icon.assets.js +324 -0
  184. package/dist/components/Icon/Icon.assets.js.map +1 -0
  185. package/dist/components/Icon/Icon.constants.d.ts +7 -0
  186. package/dist/components/Icon/Icon.constants.d.ts.map +1 -0
  187. package/dist/components/Icon/Icon.constants.js +15 -0
  188. package/dist/components/Icon/Icon.constants.js.map +1 -0
  189. package/dist/components/Icon/Icon.d.ts +5 -0
  190. package/dist/components/Icon/Icon.d.ts.map +1 -0
  191. package/dist/components/Icon/Icon.js +45 -0
  192. package/dist/components/Icon/Icon.js.map +1 -0
  193. package/dist/components/Icon/Icon.types.d.ts +254 -0
  194. package/dist/components/Icon/Icon.types.d.ts.map +1 -0
  195. package/dist/components/Icon/Icon.types.js +229 -0
  196. package/dist/components/Icon/Icon.types.js.map +1 -0
  197. package/dist/components/Icon/Icon.utilities.d.ts +22 -0
  198. package/dist/components/Icon/Icon.utilities.d.ts.map +1 -0
  199. package/dist/components/Icon/Icon.utilities.js +31 -0
  200. package/dist/components/Icon/Icon.utilities.js.map +1 -0
  201. package/dist/components/Icon/index.d.ts +4 -0
  202. package/dist/components/Icon/index.d.ts.map +1 -0
  203. package/dist/components/Icon/index.js +13 -0
  204. package/dist/components/Icon/index.js.map +1 -0
  205. package/dist/components/Text/Text.constants.d.ts +9 -0
  206. package/dist/components/Text/Text.constants.d.ts.map +1 -0
  207. package/dist/components/Text/Text.constants.js +21 -0
  208. package/dist/components/Text/Text.constants.js.map +1 -0
  209. package/dist/components/Text/Text.d.ts +5 -0
  210. package/dist/components/Text/Text.d.ts.map +1 -0
  211. package/dist/components/Text/Text.js +26 -0
  212. package/dist/components/Text/Text.js.map +1 -0
  213. package/dist/components/Text/Text.types.d.ts +110 -0
  214. package/dist/components/Text/Text.types.d.ts.map +1 -0
  215. package/dist/components/Text/Text.types.js +89 -0
  216. package/dist/components/Text/Text.types.js.map +1 -0
  217. package/dist/components/Text/Text.utilities.d.ts +30 -0
  218. package/dist/components/Text/Text.utilities.d.ts.map +1 -0
  219. package/dist/components/Text/Text.utilities.js +45 -0
  220. package/dist/components/Text/Text.utilities.js.map +1 -0
  221. package/dist/components/Text/index.d.ts +4 -0
  222. package/dist/components/Text/index.d.ts.map +1 -0
  223. package/dist/components/Text/index.js +14 -0
  224. package/dist/components/Text/index.js.map +1 -0
  225. package/dist/components/TextButton/TextButton.constants.d.ts +3 -0
  226. package/dist/components/TextButton/TextButton.constants.d.ts.map +1 -0
  227. package/dist/components/TextButton/TextButton.constants.js +29 -0
  228. package/dist/components/TextButton/TextButton.constants.js.map +1 -0
  229. package/dist/components/TextButton/TextButton.d.ts +5 -0
  230. package/dist/components/TextButton/TextButton.d.ts.map +1 -0
  231. package/dist/components/TextButton/TextButton.js +187 -0
  232. package/dist/components/TextButton/TextButton.js.map +1 -0
  233. package/dist/components/TextButton/TextButton.types.d.ts +73 -0
  234. package/dist/components/TextButton/TextButton.types.d.ts.map +1 -0
  235. package/dist/components/TextButton/TextButton.types.js +3 -0
  236. package/dist/components/TextButton/TextButton.types.js.map +1 -0
  237. package/dist/components/TextButton/TextButton.utilities.d.ts +55 -0
  238. package/dist/components/TextButton/TextButton.utilities.d.ts.map +1 -0
  239. package/dist/components/TextButton/TextButton.utilities.js +77 -0
  240. package/dist/components/TextButton/TextButton.utilities.js.map +1 -0
  241. package/dist/components/TextButton/index.d.ts +3 -0
  242. package/dist/components/TextButton/index.d.ts.map +1 -0
  243. package/dist/components/TextButton/index.js +9 -0
  244. package/dist/components/TextButton/index.js.map +1 -0
  245. package/dist/index.d.ts +108 -1
  246. package/dist/index.d.ts.map +1 -0
  247. package/dist/index.js +70 -1
  248. package/dist/index.js.map +1 -0
  249. package/dist/primitives/AvatarBase/AvatarBase.constants.d.ts +5 -0
  250. package/dist/primitives/AvatarBase/AvatarBase.constants.d.ts.map +1 -0
  251. package/dist/primitives/AvatarBase/AvatarBase.constants.js +25 -0
  252. package/dist/primitives/AvatarBase/AvatarBase.constants.js.map +1 -0
  253. package/dist/primitives/AvatarBase/AvatarBase.d.ts +5 -0
  254. package/dist/primitives/AvatarBase/AvatarBase.d.ts.map +1 -0
  255. package/dist/primitives/AvatarBase/AvatarBase.js +52 -0
  256. package/dist/primitives/AvatarBase/AvatarBase.js.map +1 -0
  257. package/dist/primitives/AvatarBase/AvatarBase.types.d.ts +49 -0
  258. package/dist/primitives/AvatarBase/AvatarBase.types.d.ts.map +1 -0
  259. package/dist/primitives/AvatarBase/AvatarBase.types.js +3 -0
  260. package/dist/primitives/AvatarBase/AvatarBase.types.js.map +1 -0
  261. package/dist/primitives/AvatarBase/AvatarBase.utilities.d.ts +26 -0
  262. package/dist/primitives/AvatarBase/AvatarBase.utilities.d.ts.map +1 -0
  263. package/dist/primitives/AvatarBase/AvatarBase.utilities.js +43 -0
  264. package/dist/primitives/AvatarBase/AvatarBase.utilities.js.map +1 -0
  265. package/dist/primitives/AvatarBase/index.d.ts +4 -0
  266. package/dist/primitives/AvatarBase/index.d.ts.map +1 -0
  267. package/dist/primitives/AvatarBase/index.js +11 -0
  268. package/dist/primitives/AvatarBase/index.js.map +1 -0
  269. package/dist/primitives/Blockies/Blockies.d.ts +5 -0
  270. package/dist/primitives/Blockies/Blockies.d.ts.map +1 -0
  271. package/dist/primitives/Blockies/Blockies.js +15 -0
  272. package/dist/primitives/Blockies/Blockies.js.map +1 -0
  273. package/dist/primitives/Blockies/Blockies.types.d.ts +15 -0
  274. package/dist/primitives/Blockies/Blockies.types.d.ts.map +1 -0
  275. package/dist/primitives/Blockies/Blockies.types.js +3 -0
  276. package/dist/primitives/Blockies/Blockies.types.js.map +1 -0
  277. package/dist/primitives/Blockies/index.d.ts +3 -0
  278. package/dist/primitives/Blockies/index.d.ts.map +1 -0
  279. package/dist/primitives/Blockies/index.js +9 -0
  280. package/dist/primitives/Blockies/index.js.map +1 -0
  281. package/dist/primitives/ButtonAnimated/ButtonAnimated.d.ts +5 -0
  282. package/dist/primitives/ButtonAnimated/ButtonAnimated.d.ts.map +1 -0
  283. package/dist/primitives/ButtonAnimated/ButtonAnimated.js +58 -0
  284. package/dist/primitives/ButtonAnimated/ButtonAnimated.js.map +1 -0
  285. package/dist/primitives/ButtonAnimated/ButtonAnimated.types.d.ts +6 -0
  286. package/dist/primitives/ButtonAnimated/ButtonAnimated.types.d.ts.map +1 -0
  287. package/dist/primitives/ButtonAnimated/ButtonAnimated.types.js +3 -0
  288. package/dist/primitives/ButtonAnimated/ButtonAnimated.types.js.map +1 -0
  289. package/dist/primitives/ButtonAnimated/index.d.ts +3 -0
  290. package/dist/primitives/ButtonAnimated/index.d.ts.map +1 -0
  291. package/dist/primitives/ButtonAnimated/index.js +9 -0
  292. package/dist/primitives/ButtonAnimated/index.js.map +1 -0
  293. package/dist/primitives/ButtonBase/ButtonBase.constants.d.ts +3 -0
  294. package/dist/primitives/ButtonBase/ButtonBase.constants.d.ts.map +1 -0
  295. package/dist/primitives/ButtonBase/ButtonBase.constants.js +32 -0
  296. package/dist/primitives/ButtonBase/ButtonBase.constants.js.map +1 -0
  297. package/dist/primitives/ButtonBase/ButtonBase.d.ts +5 -0
  298. package/dist/primitives/ButtonBase/ButtonBase.d.ts.map +1 -0
  299. package/dist/primitives/ButtonBase/ButtonBase.js +84 -0
  300. package/dist/primitives/ButtonBase/ButtonBase.js.map +1 -0
  301. package/dist/primitives/ButtonBase/ButtonBase.types.d.ts +93 -0
  302. package/dist/primitives/ButtonBase/ButtonBase.types.d.ts.map +1 -0
  303. package/dist/primitives/ButtonBase/ButtonBase.types.js +19 -0
  304. package/dist/primitives/ButtonBase/ButtonBase.types.js.map +1 -0
  305. package/dist/primitives/ButtonBase/ButtonBase.utilities.d.ts +28 -0
  306. package/dist/primitives/ButtonBase/ButtonBase.utilities.d.ts.map +1 -0
  307. package/dist/primitives/ButtonBase/ButtonBase.utilities.js +41 -0
  308. package/dist/primitives/ButtonBase/ButtonBase.utilities.js.map +1 -0
  309. package/dist/primitives/ButtonBase/index.d.ts +4 -0
  310. package/dist/primitives/ButtonBase/index.d.ts.map +1 -0
  311. package/dist/primitives/ButtonBase/index.js +11 -0
  312. package/dist/primitives/ButtonBase/index.js.map +1 -0
  313. package/dist/primitives/ImageOrSvg/ImageOrSvg.d.ts +5 -0
  314. package/dist/primitives/ImageOrSvg/ImageOrSvg.d.ts.map +1 -0
  315. package/dist/primitives/ImageOrSvg/ImageOrSvg.js +76 -0
  316. package/dist/primitives/ImageOrSvg/ImageOrSvg.js.map +1 -0
  317. package/dist/primitives/ImageOrSvg/ImageOrSvg.types.d.ts +64 -0
  318. package/dist/primitives/ImageOrSvg/ImageOrSvg.types.d.ts.map +1 -0
  319. package/dist/primitives/ImageOrSvg/ImageOrSvg.types.js +3 -0
  320. package/dist/primitives/ImageOrSvg/ImageOrSvg.types.js.map +1 -0
  321. package/dist/primitives/ImageOrSvg/index.d.ts +3 -0
  322. package/dist/primitives/ImageOrSvg/index.d.ts.map +1 -0
  323. package/dist/primitives/ImageOrSvg/index.js +9 -0
  324. package/dist/primitives/ImageOrSvg/index.js.map +1 -0
  325. package/dist/primitives/Jazzicon/Jazzicon.d.ts +5 -0
  326. package/dist/primitives/Jazzicon/Jazzicon.d.ts.map +1 -0
  327. package/dist/primitives/Jazzicon/Jazzicon.js +14 -0
  328. package/dist/primitives/Jazzicon/Jazzicon.js.map +1 -0
  329. package/dist/primitives/Jazzicon/Jazzicon.types.d.ts +11 -0
  330. package/dist/primitives/Jazzicon/Jazzicon.types.d.ts.map +1 -0
  331. package/dist/primitives/Jazzicon/Jazzicon.types.js +3 -0
  332. package/dist/primitives/Jazzicon/Jazzicon.types.js.map +1 -0
  333. package/dist/primitives/Jazzicon/index.d.ts +3 -0
  334. package/dist/primitives/Jazzicon/index.d.ts.map +1 -0
  335. package/dist/primitives/Jazzicon/index.js +9 -0
  336. package/dist/primitives/Jazzicon/index.js.map +1 -0
  337. package/dist/primitives/TextOrChildren/TextOrChildren.d.ts +5 -0
  338. package/dist/primitives/TextOrChildren/TextOrChildren.d.ts.map +1 -0
  339. package/dist/primitives/TextOrChildren/TextOrChildren.js +15 -0
  340. package/dist/primitives/TextOrChildren/TextOrChildren.js.map +1 -0
  341. package/dist/primitives/TextOrChildren/TextOrChildren.types.d.ts +15 -0
  342. package/dist/primitives/TextOrChildren/TextOrChildren.types.d.ts.map +1 -0
  343. package/dist/primitives/TextOrChildren/TextOrChildren.types.js +3 -0
  344. package/dist/primitives/TextOrChildren/TextOrChildren.types.js.map +1 -0
  345. package/dist/primitives/TextOrChildren/index.d.ts +3 -0
  346. package/dist/primitives/TextOrChildren/index.d.ts.map +1 -0
  347. package/dist/primitives/TextOrChildren/index.js +9 -0
  348. package/dist/primitives/TextOrChildren/index.js.map +1 -0
  349. package/dist/shared/enums.d.ts +46 -0
  350. package/dist/shared/enums.d.ts.map +1 -0
  351. package/dist/shared/enums.js +44 -0
  352. package/dist/shared/enums.js.map +1 -0
  353. package/dist/temp-components/Spinner/Spinner.constants.d.ts +3 -0
  354. package/dist/temp-components/Spinner/Spinner.constants.d.ts.map +1 -0
  355. package/dist/temp-components/Spinner/Spinner.constants.js +21 -0
  356. package/dist/temp-components/Spinner/Spinner.constants.js.map +1 -0
  357. package/dist/temp-components/Spinner/Spinner.d.ts +5 -0
  358. package/dist/temp-components/Spinner/Spinner.d.ts.map +1 -0
  359. package/dist/temp-components/Spinner/Spinner.js +68 -0
  360. package/dist/temp-components/Spinner/Spinner.js.map +1 -0
  361. package/dist/temp-components/Spinner/Spinner.types.d.ts +30 -0
  362. package/dist/temp-components/Spinner/Spinner.types.d.ts.map +1 -0
  363. package/dist/temp-components/Spinner/Spinner.types.js +3 -0
  364. package/dist/temp-components/Spinner/Spinner.types.js.map +1 -0
  365. package/dist/temp-components/Spinner/index.d.ts +3 -0
  366. package/dist/temp-components/Spinner/index.d.ts.map +1 -0
  367. package/dist/temp-components/Spinner/index.js +9 -0
  368. package/dist/temp-components/Spinner/index.js.map +1 -0
  369. package/package.json +29 -14
  370. package/dist/components/Button.d.ts +0 -6
  371. package/dist/components/Button.js +0 -8
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextButton.js","sourceRoot":"","sources":["../../../src/components/TextButton/TextButton.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iEAAiE;AACjE,8FAA4E;AAC5E,+CAAiD;AAEjD,+CAAoC;AAGpC,4EAAoD;AAEpD,mDAA2B;AAC3B,wDAAgC;AAEhC,iEA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EAAE,CAAA,MAAM,eAAe,KAAK,CAAC,CACxC;gBAAA,CAAC,mBAAI,CACH,KAAK,CAAC,CAAC,EAAE,CAAA;sBACL,qBAAqB;;0BAEjB,aAAa;0BACb,kBAAkB;yBACnB,eAAe,UAAU,mBAAmB,KAAK,CAAC,CAEzD;kBAAA,CAAC,cAAI,CAAC,IAAI,CAAC,CAAC,gBAAgB,CAAC,CAAC,IAAI,iBAAiB,CAAC,EACtD;gBAAA,EAAE,mBAAI,CACR;cAAA,EAAE,mBAAI,CAAC,CACR,CAAC,CAAC,CAAC,CACF,YAAY,CACb,CACH;UAAA,GAAG,CACJ,CACH;MAAA,EAAE,cAAI,CACN;MAAA,CAAC,gBAAgB,IAAI,CAAC,cAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAA,QAAQ,CAAC,CAAE,CAAA,EAAE,cAAI,CAAC,CACxD;IAAA,EAAE,cAAI,CAAC,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,kBAAe,UAAU,CAAC","sourcesContent":["/* eslint-disable @typescript-eslint/prefer-nullish-coalescing */\nimport { useTailwind } from '@metamask-previews/design-system-twrnc-preset';\nimport React, { useMemo, useState } from 'react';\nimport type { GestureResponderEvent } from 'react-native';\nimport { View } from 'react-native';\n\nimport type { SpinnerProps } from '../../temp-components/Spinner';\nimport Spinner from '../../temp-components/Spinner';\nimport type { IconProps, IconColor } from '../Icon';\nimport Icon from '../Icon';\nimport Text from '../Text/Text';\nimport type { TextProps } from '../Text/Text.types';\nimport { DEFAULT_TEXTBUTTON_PROPS } from './TextButton.constants';\nimport type { TextButtonProps } from './TextButton.types';\nimport {\n generateTextButtonContainerClassNames,\n generateTextButtonTextClassNames,\n} from './TextButton.utilities';\n\nconst TextButton = ({\n children,\n textProps,\n isLoading = DEFAULT_TEXTBUTTON_PROPS.isLoading,\n loadingText,\n spinnerProps,\n startIconName,\n startIconProps,\n startAccessory,\n endIconName,\n endIconProps,\n endAccessory,\n isDisabled = DEFAULT_TEXTBUTTON_PROPS.isDisabled,\n isInverse = DEFAULT_TEXTBUTTON_PROPS.isInverse,\n onPress,\n onPressIn,\n onPressOut,\n onLongPress,\n twClassName,\n accessibilityRole,\n accessibilityLabel,\n style,\n ...props\n}: TextButtonProps) => {\n const [isPressed, setIsPressed] = useState(false);\n const tw = useTailwind();\n\n // Styling calculation for state changes\n const twContainerClassNames = useMemo(() => {\n return generateTextButtonContainerClassNames({\n isPressed,\n isLoading,\n isDisabled,\n twClassName,\n });\n }, [isPressed, isLoading, isDisabled, twClassName]);\n\n const twTextClassNames = useMemo(() => {\n return generateTextButtonTextClassNames({\n isPressed,\n isInverse,\n isLoading,\n });\n }, [isPressed, isInverse, isLoading]);\n\n // Merging default settings for Icons with passed in props\n const finalStartIconProps: Partial<IconProps> = {\n ...DEFAULT_TEXTBUTTON_PROPS.startIconProps,\n ...startIconProps,\n twClassName: `${twTextClassNames} ${startIconProps?.twClassName ?? ''}`,\n };\n const finalStartIconName = startIconName ?? startIconProps?.name;\n\n const finalEndIconProps: Partial<IconProps> = {\n ...DEFAULT_TEXTBUTTON_PROPS.endIconProps,\n ...endIconProps,\n twClassName: `${twTextClassNames} ${endIconProps?.twClassName ?? ''}`,\n };\n const finalEndIconName = endIconName ?? endIconProps?.name;\n\n const finalTextProps: Omit<Partial<TextProps>, 'children'> = {\n ...DEFAULT_TEXTBUTTON_PROPS.textProps,\n ...textProps,\n twClassName: `${twTextClassNames} ${textProps?.twClassName ?? ''}`,\n };\n\n // Merging spinner settings for Icons with passed in props\n const finalSpinnerProps: SpinnerProps = {\n ...DEFAULT_TEXTBUTTON_PROPS.spinnerProps,\n loadingText,\n color: twTextClassNames as IconColor,\n loadingTextProps: {\n twClassName: `${twTextClassNames} mt-[2.5px]`,\n },\n ...spinnerProps,\n };\n const onPressHandler = (event: GestureResponderEvent) => {\n if (!isDisabled && !isLoading) {\n onPress?.(event);\n }\n };\n\n const onPressInHandler = (event: GestureResponderEvent) => {\n if (!isDisabled && !isLoading) {\n setIsPressed(true);\n onPressIn?.(event);\n }\n };\n\n const onPressOutHandler = (event: GestureResponderEvent) => {\n if (!isDisabled && !isLoading) {\n setIsPressed(false);\n onPressOut?.(event);\n }\n };\n\n const onLongPressHandler = (event: GestureResponderEvent) => {\n if (!isDisabled && !isLoading) {\n onLongPress?.(event);\n }\n };\n\n /**\n * Design Requirements\n * TextButton needs to be able to be placed inline with other Texts along with\n * accompanying icons.\n *\n * Limitations\n * React Native renders Texts and components nested inside Texts very differently.\n * In order to fulfil design requirements\n * - TextButton needs to be built using Text wrapping the component to ensure\n * when placed in line with other Texts, it can be properly displayed inline\n * with other Texts.\n * - Due to React Native Texts calculating the layout of nested components\n * differently, there needs to be a few styling hacks applied below\n */\n\n // Get the line height of the text, which is also the height of the component\n const finalVariant = finalTextProps.variant;\n const { lineHeight } = tw`text-${finalVariant as string}`;\n const componentHeight = Number(lineHeight);\n\n // Due to React Native rendering Views slightly above Texts, any non-texts\n // need to be moved down\n const nonTextOffSet = 2.5;\n\n // Get the final sizes of Icons to help with manual alignments\n const finalStartIconSize = finalStartIconProps.size;\n const finalEndIconSize = finalEndIconProps.size;\n\n // Offsets to vertically center the Icon\n const finalStartIconOffset =\n (Number(lineHeight) - Number(finalStartIconSize)) / 2;\n const finalEndIconOffset =\n (Number(lineHeight) - Number(finalEndIconSize)) / 2;\n\n /**\n * Due to Texts restricting nested components to manipulating layout with\n * margins/paddings, we needed to add Nested Views in order to properly add\n * additional margins/paddings. However, this causes the Text component to\n * somehow not include the Icons as part of the calculation for displaying\n * a change in background color onPress. Because of that, we need to mimic\n * the behavior on the Icon wrappers by baking the margins into the Icon\n * wrappers in order to display the background change properly\n */\n const marginsBetweenIconAndText = 4;\n const startIconWrapperWidth =\n Number(finalStartIconSize) + marginsBetweenIconAndText;\n const endIconWrapperWidth =\n Number(finalEndIconSize) + marginsBetweenIconAndText;\n\n return (\n <Text>\n {finalStartIconName && <Text style={tw`hidden`}> </Text>}\n {isLoading && (\n <View style={tw`${twContainerClassNames}`}>\n <Spinner {...finalSpinnerProps} />\n </View>\n )}\n <Text\n onPress={onPressHandler}\n onPressIn={onPressInHandler}\n onPressOut={onPressOutHandler}\n onLongPress={onLongPressHandler}\n accessible\n accessibilityRole=\"button\"\n accessibilityLabel={accessibilityLabel}\n style={[tw`${twContainerClassNames}`, style]}\n testID=\"text-button\"\n suppressHighlighting\n {...props}\n >\n {!isLoading && (\n <>\n {finalStartIconName ? (\n // This additional View is needed, otherwise things are rendered\n // VERY funkily\n <View style={tw`h-[${componentHeight}px]`}>\n <View\n style={tw`\n ${twContainerClassNames} \n items-start mt-[${nonTextOffSet}px] \n pt-[${finalStartIconOffset}px] \n h-[${componentHeight}px] \n w-[${startIconWrapperWidth}px]\n `}\n >\n <Icon name={finalStartIconName} {...finalStartIconProps} />\n </View>\n </View>\n ) : (\n startAccessory\n )}\n <Text {...finalTextProps}>{children}</Text>\n {finalEndIconName ? (\n // This additional View is needed, otherwise things are rendered\n // VERY funkily\n <View style={tw`h-[${componentHeight}px]`}>\n <View\n style={tw`\n ${twContainerClassNames} \n items-end \n mt-[${nonTextOffSet}px] \n pt-[${finalEndIconOffset}px] \n h-[${componentHeight}px] w-[${endIconWrapperWidth}px]`}\n >\n <Icon name={finalEndIconName} {...finalEndIconProps} />\n </View>\n </View>\n ) : (\n endAccessory\n )}\n </>\n )}\n </Text>\n {finalEndIconName && <Text style={tw`hidden`}> </Text>}\n </Text>\n );\n};\n\nexport default TextButton;\n"]}
@@ -0,0 +1,73 @@
1
+ import type { PressableProps, StyleProp, ViewStyle } from 'react-native';
2
+ import type { TextProps } from 'src/components/Text/Text.types';
3
+ import type { SpinnerProps } from '../../temp-components/Spinner';
4
+ import type { IconProps, IconName } from '../Icon';
5
+ /**
6
+ * TextButton component props.
7
+ */
8
+ export type TextButtonProps = {
9
+ /**
10
+ * Required prop for the content to be rendered within the TextButton
11
+ */
12
+ children: string;
13
+ /**
14
+ * Optional props to be passed to the Text component when children is a string
15
+ */
16
+ textProps?: Omit<Partial<TextProps>, 'children'>;
17
+ /**
18
+ * Optional prop that when true, shows a loading spinner
19
+ * @default false
20
+ */
21
+ isLoading?: boolean;
22
+ /**
23
+ * Optional prop for text to display when button is in loading state
24
+ */
25
+ loadingText?: string;
26
+ /**
27
+ * Optional prop to pass additional properties to the end icon
28
+ */
29
+ spinnerProps?: Partial<SpinnerProps>;
30
+ /**
31
+ * Optional prop to specify an icon to show at the start of the button
32
+ */
33
+ startIconName?: IconName;
34
+ /**
35
+ * Optional prop to pass additional properties to the start icon
36
+ */
37
+ startIconProps?: Partial<IconProps>;
38
+ /**
39
+ * Optional prop for a custom element to show at the start of the button
40
+ */
41
+ startAccessory?: React.ReactNode;
42
+ /**
43
+ * Optional prop to specify an icon to show at the end of the button
44
+ */
45
+ endIconName?: IconName;
46
+ /**
47
+ * Optional prop to pass additional properties to the end icon
48
+ */
49
+ endIconProps?: Partial<IconProps>;
50
+ /**
51
+ * Optional prop for a custom element to show at the end of the button
52
+ */
53
+ endAccessory?: React.ReactNode;
54
+ /**
55
+ * Optional prop that when true, disables the button
56
+ * @default false
57
+ */
58
+ isDisabled?: boolean;
59
+ /**
60
+ * Optional prop to show the inverse state of the button, which is reserved for buttons on colored backgrounds.
61
+ * @default false
62
+ */
63
+ isInverse?: boolean;
64
+ /**
65
+ * Optional prop to add twrnc overriding classNames.
66
+ */
67
+ twClassName?: string;
68
+ /**
69
+ * Optional prop to control the style.
70
+ */
71
+ style?: StyleProp<ViewStyle>;
72
+ } & Omit<PressableProps, 'disabled'>;
73
+ //# sourceMappingURL=TextButton.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextButton.types.d.ts","sourceRoot":"","sources":["../../../src/components/TextButton/TextButton.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAEhE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAEnD;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,SAAS,CAAC,EAAE,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,EAAE,UAAU,CAAC,CAAC;IACjD;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC;IACrC;;OAEG;IACH,aAAa,CAAC,EAAE,QAAQ,CAAC;IACzB;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC;IACpC;;OAEG;IACH,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACjC;;OAEG;IACH,WAAW,CAAC,EAAE,QAAQ,CAAC;IACvB;;OAEG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC;IAClC;;OAEG;IACH,YAAY,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC/B;;;OAGG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAC9B,GAAG,IAAI,CAAC,cAAc,EAAE,UAAU,CAAC,CAAC"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=TextButton.types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextButton.types.js","sourceRoot":"","sources":["../../../src/components/TextButton/TextButton.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { PressableProps, StyleProp, ViewStyle } from 'react-native';\nimport type { TextProps } from 'src/components/Text/Text.types';\n\nimport type { SpinnerProps } from '../../temp-components/Spinner';\nimport type { IconProps, IconName } from '../Icon';\n\n/**\n * TextButton component props.\n */\nexport type TextButtonProps = {\n /**\n * Required prop for the content to be rendered within the TextButton\n */\n children: string;\n /**\n * Optional props to be passed to the Text component when children is a string\n */\n textProps?: Omit<Partial<TextProps>, 'children'>;\n /**\n * Optional prop that when true, shows a loading spinner\n * @default false\n */\n isLoading?: boolean;\n /**\n * Optional prop for text to display when button is in loading state\n */\n loadingText?: string;\n /**\n * Optional prop to pass additional properties to the end icon\n */\n spinnerProps?: Partial<SpinnerProps>;\n /**\n * Optional prop to specify an icon to show at the start of the button\n */\n startIconName?: IconName;\n /**\n * Optional prop to pass additional properties to the start icon\n */\n startIconProps?: Partial<IconProps>;\n /**\n * Optional prop for a custom element to show at the start of the button\n */\n startAccessory?: React.ReactNode;\n /**\n * Optional prop to specify an icon to show at the end of the button\n */\n endIconName?: IconName;\n /**\n * Optional prop to pass additional properties to the end icon\n */\n endIconProps?: Partial<IconProps>;\n /**\n * Optional prop for a custom element to show at the end of the button\n */\n endAccessory?: React.ReactNode;\n /**\n * Optional prop that when true, disables the button\n * @default false\n */\n isDisabled?: boolean;\n /**\n * Optional prop to show the inverse state of the button, which is reserved for buttons on colored backgrounds.\n * @default false\n */\n isInverse?: boolean;\n /**\n * Optional prop to add twrnc overriding classNames.\n */\n twClassName?: string;\n /**\n * Optional prop to control the style.\n */\n style?: StyleProp<ViewStyle>;\n} & Omit<PressableProps, 'disabled'>;\n"]}
@@ -0,0 +1,55 @@
1
+ import type { TextButtonProps } from './TextButton.types';
2
+ /**
3
+ * Generates a Tailwind class name for the text button container based on its state and optional additional classes.
4
+ *
5
+ * This function computes the appropriate background class name for a text button's container, considering its
6
+ * `isPressed` and `isLoading` states. Additional Tailwind class names can also be appended using the `twClassName` parameter.
7
+ *
8
+ * @param isPressed - Indicates whether the button is currently being pressed.
9
+ * @param isLoading - Indicates whether the button is in a loading state.
10
+ * @param isDisabled - Indicates whether the button is in a disabled state.
11
+ * @param twClassName - Additional Tailwind class names for customization.
12
+ * @returns A combined string of Tailwind class names for the container's background styling.
13
+ *
14
+ * Example:
15
+ * ```
16
+ * const classNames = generateTextButtonContainerClassNames({
17
+ * isPressed: true,
18
+ * isLoading: false,
19
+ * twClassName: 'rounded-full',
20
+ * });
21
+ *
22
+ * console.log(classNames);
23
+ * // Output: "bg-background-pressed rounded-full"
24
+ * ```
25
+ */
26
+ export declare const generateTextButtonContainerClassNames: ({ isPressed, isLoading, isDisabled, twClassName, }: Partial<TextButtonProps> & {
27
+ isPressed?: boolean | undefined;
28
+ }) => string;
29
+ /**
30
+ * Generates a Tailwind class name for the text button's text based on its state.
31
+ *
32
+ * This function computes the appropriate text color and style class names for a text button,
33
+ * considering its `isPressed`, `isInverse`, and `isLoading` states.
34
+ *
35
+ * @param isPressed - Indicates whether the button is currently being pressed.
36
+ * @param isInverse - Indicates whether the button is using an "inverse" theme.
37
+ * @param isLoading - Indicates whether the button is in a loading state.
38
+ * @returns A combined string of Tailwind class names for the text's color and style.
39
+ *
40
+ * Example:
41
+ * ```
42
+ * const classNames = generateTextButtonTextClassNames({
43
+ * isPressed: true,
44
+ * isInverse: false,
45
+ * isLoading: false,
46
+ * });
47
+ *
48
+ * console.log(classNames);
49
+ * // Output: "text-primary-defaultPressed underline"
50
+ * ```
51
+ */
52
+ export declare const generateTextButtonTextClassNames: ({ isPressed, isInverse, isLoading, }: Partial<TextButtonProps> & {
53
+ isPressed?: boolean | undefined;
54
+ }) => string;
55
+ //# sourceMappingURL=TextButton.utilities.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextButton.utilities.d.ts","sourceRoot":"","sources":["../../../src/components/TextButton/TextButton.utilities.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAE1D;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,eAAO,MAAM,qCAAqC;;MAO9C,MAQH,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,gCAAgC;;MAMzC,MAeH,CAAC"}
@@ -0,0 +1,77 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.generateTextButtonTextClassNames = exports.generateTextButtonContainerClassNames = void 0;
4
+ /**
5
+ * Generates a Tailwind class name for the text button container based on its state and optional additional classes.
6
+ *
7
+ * This function computes the appropriate background class name for a text button's container, considering its
8
+ * `isPressed` and `isLoading` states. Additional Tailwind class names can also be appended using the `twClassName` parameter.
9
+ *
10
+ * @param isPressed - Indicates whether the button is currently being pressed.
11
+ * @param isLoading - Indicates whether the button is in a loading state.
12
+ * @param isDisabled - Indicates whether the button is in a disabled state.
13
+ * @param twClassName - Additional Tailwind class names for customization.
14
+ * @returns A combined string of Tailwind class names for the container's background styling.
15
+ *
16
+ * Example:
17
+ * ```
18
+ * const classNames = generateTextButtonContainerClassNames({
19
+ * isPressed: true,
20
+ * isLoading: false,
21
+ * twClassName: 'rounded-full',
22
+ * });
23
+ *
24
+ * console.log(classNames);
25
+ * // Output: "bg-background-pressed rounded-full"
26
+ * ```
27
+ */
28
+ const generateTextButtonContainerClassNames = ({ isPressed = false, isLoading = false, isDisabled = false, twClassName = '', }) => {
29
+ const isPressedOrLoading = isPressed || isLoading;
30
+ const backgroundStyle = isPressedOrLoading
31
+ ? 'bg-background-pressed'
32
+ : 'bg-transparent';
33
+ const opacityStyle = `opacity-${isDisabled ? 50 : 100}`;
34
+ return `${backgroundStyle} ${opacityStyle} ${twClassName}`;
35
+ };
36
+ exports.generateTextButtonContainerClassNames = generateTextButtonContainerClassNames;
37
+ /**
38
+ * Generates a Tailwind class name for the text button's text based on its state.
39
+ *
40
+ * This function computes the appropriate text color and style class names for a text button,
41
+ * considering its `isPressed`, `isInverse`, and `isLoading` states.
42
+ *
43
+ * @param isPressed - Indicates whether the button is currently being pressed.
44
+ * @param isInverse - Indicates whether the button is using an "inverse" theme.
45
+ * @param isLoading - Indicates whether the button is in a loading state.
46
+ * @returns A combined string of Tailwind class names for the text's color and style.
47
+ *
48
+ * Example:
49
+ * ```
50
+ * const classNames = generateTextButtonTextClassNames({
51
+ * isPressed: true,
52
+ * isInverse: false,
53
+ * isLoading: false,
54
+ * });
55
+ *
56
+ * console.log(classNames);
57
+ * // Output: "text-primary-defaultPressed underline"
58
+ * ```
59
+ */
60
+ const generateTextButtonTextClassNames = ({ isPressed = false, isInverse = false, isLoading = false, }) => {
61
+ let textColor, textStyle;
62
+ // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
63
+ const isPressedOrLoading = isPressed || isLoading;
64
+ if (isInverse) {
65
+ textColor = 'text-primary-inverse';
66
+ textStyle = 'underline';
67
+ }
68
+ else {
69
+ textColor = isPressedOrLoading
70
+ ? 'text-primary-defaultPressed'
71
+ : 'text-primary-default';
72
+ textStyle = isPressedOrLoading ? 'underline' : 'no-underline';
73
+ }
74
+ return `${textColor} ${textStyle}`;
75
+ };
76
+ exports.generateTextButtonTextClassNames = generateTextButtonTextClassNames;
77
+ //# sourceMappingURL=TextButton.utilities.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TextButton.utilities.js","sourceRoot":"","sources":["../../../src/components/TextButton/TextButton.utilities.ts"],"names":[],"mappings":";;;AAIA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACI,MAAM,qCAAqC,GAAG,CAAC,EACpD,SAAS,GAAG,KAAK,EACjB,SAAS,GAAG,KAAK,EACjB,UAAU,GAAG,KAAK,EAClB,WAAW,GAAG,EAAE,GAGjB,EAAU,EAAE;IACX,MAAM,kBAAkB,GAAG,SAAS,IAAI,SAAS,CAAC;IAClD,MAAM,eAAe,GAAG,kBAAkB;QACxC,CAAC,CAAC,uBAAuB;QACzB,CAAC,CAAC,gBAAgB,CAAC;IACrB,MAAM,YAAY,GAAG,WAAW,UAAU,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC;IAExD,OAAO,GAAG,eAAe,IAAI,YAAY,IAAI,WAAW,EAAE,CAAC;AAC7D,CAAC,CAAC;AAfW,QAAA,qCAAqC,yCAehD;AAEF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACI,MAAM,gCAAgC,GAAG,CAAC,EAC/C,SAAS,GAAG,KAAK,EACjB,SAAS,GAAG,KAAK,EACjB,SAAS,GAAG,KAAK,GAGlB,EAAU,EAAE;IACX,IAAI,SAAS,EAAE,SAAS,CAAC;IACzB,wEAAwE;IACxE,MAAM,kBAAkB,GAAG,SAAS,IAAI,SAAS,CAAC;IAClD,IAAI,SAAS,EAAE;QACb,SAAS,GAAG,sBAAsB,CAAC;QACnC,SAAS,GAAG,WAAW,CAAC;KACzB;SAAM;QACL,SAAS,GAAG,kBAAkB;YAC5B,CAAC,CAAC,6BAA6B;YAC/B,CAAC,CAAC,sBAAsB,CAAC;QAC3B,SAAS,GAAG,kBAAkB,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,cAAc,CAAC;KAC/D;IAED,OAAO,GAAG,SAAS,IAAI,SAAS,EAAE,CAAC;AACrC,CAAC,CAAC;AArBW,QAAA,gCAAgC,oCAqB3C","sourcesContent":["/* eslint-disable jsdoc/check-param-names */\n/* eslint-disable jsdoc/require-param */\nimport type { TextButtonProps } from './TextButton.types';\n\n/**\n * Generates a Tailwind class name for the text button container based on its state and optional additional classes.\n *\n * This function computes the appropriate background class name for a text button's container, considering its\n * `isPressed` and `isLoading` states. Additional Tailwind class names can also be appended using the `twClassName` parameter.\n *\n * @param isPressed - Indicates whether the button is currently being pressed.\n * @param isLoading - Indicates whether the button is in a loading state.\n * @param isDisabled - Indicates whether the button is in a disabled state.\n * @param twClassName - Additional Tailwind class names for customization.\n * @returns A combined string of Tailwind class names for the container's background styling.\n *\n * Example:\n * ```\n * const classNames = generateTextButtonContainerClassNames({\n * isPressed: true,\n * isLoading: false,\n * twClassName: 'rounded-full',\n * });\n *\n * console.log(classNames);\n * // Output: \"bg-background-pressed rounded-full\"\n * ```\n */\nexport const generateTextButtonContainerClassNames = ({\n isPressed = false,\n isLoading = false,\n isDisabled = false,\n twClassName = '',\n}: Partial<TextButtonProps> & {\n isPressed?: boolean;\n}): string => {\n const isPressedOrLoading = isPressed || isLoading;\n const backgroundStyle = isPressedOrLoading\n ? 'bg-background-pressed'\n : 'bg-transparent';\n const opacityStyle = `opacity-${isDisabled ? 50 : 100}`;\n\n return `${backgroundStyle} ${opacityStyle} ${twClassName}`;\n};\n\n/**\n * Generates a Tailwind class name for the text button's text based on its state.\n *\n * This function computes the appropriate text color and style class names for a text button,\n * considering its `isPressed`, `isInverse`, and `isLoading` states.\n *\n * @param isPressed - Indicates whether the button is currently being pressed.\n * @param isInverse - Indicates whether the button is using an \"inverse\" theme.\n * @param isLoading - Indicates whether the button is in a loading state.\n * @returns A combined string of Tailwind class names for the text's color and style.\n *\n * Example:\n * ```\n * const classNames = generateTextButtonTextClassNames({\n * isPressed: true,\n * isInverse: false,\n * isLoading: false,\n * });\n *\n * console.log(classNames);\n * // Output: \"text-primary-defaultPressed underline\"\n * ```\n */\nexport const generateTextButtonTextClassNames = ({\n isPressed = false,\n isInverse = false,\n isLoading = false,\n}: Partial<TextButtonProps> & {\n isPressed?: boolean;\n}): string => {\n let textColor, textStyle;\n // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing\n const isPressedOrLoading = isPressed || isLoading;\n if (isInverse) {\n textColor = 'text-primary-inverse';\n textStyle = 'underline';\n } else {\n textColor = isPressedOrLoading\n ? 'text-primary-defaultPressed'\n : 'text-primary-default';\n textStyle = isPressedOrLoading ? 'underline' : 'no-underline';\n }\n\n return `${textColor} ${textStyle}`;\n};\n"]}
@@ -0,0 +1,3 @@
1
+ export { default } from './TextButton';
2
+ export type { TextButtonProps } from './TextButton.types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/TextButton/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,YAAY,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC"}
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.default = void 0;
7
+ var TextButton_1 = require("./TextButton");
8
+ Object.defineProperty(exports, "default", { enumerable: true, get: function () { return __importDefault(TextButton_1).default; } });
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/TextButton/index.ts"],"names":[],"mappings":";;;;;;AAAA,2CAAuC;AAA9B,sHAAA,OAAO,OAAA","sourcesContent":["export { default } from './TextButton';\nexport type { TextButtonProps } from './TextButton.types';\n"]}
package/dist/index.d.ts CHANGED
@@ -1 +1,108 @@
1
- export { default as Button } from './components/Button';
1
+ export declare const AvatarAccount: import("react").ForwardRefExoticComponent<{
2
+ address: string;
3
+ variant?: import("./components/AvatarAccount").AvatarAccountVariant | undefined;
4
+ } & Omit<import("./primitives/AvatarBase").AvatarBaseProps, "children" | "fallbackTextProps" | "fallbackText"> & import("react").RefAttributes<any>>;
5
+ export { AvatarAccountProps, AvatarAccountVariant, AvatarAccountSize, } from './components/AvatarAccount';
6
+ export declare const AvatarBase: import("react").ForwardRefExoticComponent<{
7
+ children?: import("react").ReactNode;
8
+ size?: import("./shared/enums").AvatarSize | undefined;
9
+ shape?: import("./shared/enums").AvatarShape | undefined;
10
+ fallbackText?: string | undefined;
11
+ fallbackTextProps?: Omit<import("./components/Text").TextProps, "children"> | undefined;
12
+ twClassName?: string | undefined;
13
+ style?: import("react-native").StyleProp<import("react-native").ViewStyle>;
14
+ } & import("react-native").ViewProps & import("react").RefAttributes<any>>;
15
+ export { AvatarBaseProps, AvatarBaseSize } from './primitives/AvatarBase';
16
+ export declare const AvatarFavicon: import("react").ForwardRefExoticComponent<{
17
+ name?: string | undefined;
18
+ } & Omit<import("./primitives/AvatarBase").AvatarBaseProps, "children"> & import("./primitives/ImageOrSvg").ImageOrSvgProps & import("react").RefAttributes<any>>;
19
+ export { AvatarFaviconProps, AvatarFaviconSize, } from './components/AvatarFavicon';
20
+ export declare const AvatarIcon: import("react").ForwardRefExoticComponent<{
21
+ severity?: import("./components/AvatarIcon").AvatarIconSeverity | undefined;
22
+ iconName: import("./components/Icon").IconName;
23
+ iconProps?: Omit<import("./components/Icon").IconProps, "name"> | undefined;
24
+ } & Omit<import("./primitives/AvatarBase").AvatarBaseProps, "children" | "fallbackTextProps" | "fallbackText"> & import("react").RefAttributes<any>>;
25
+ export { AvatarIconProps, AvatarIconSeverity, AvatarIconSize, } from './components/AvatarIcon';
26
+ export declare const AvatarNetwork: import("react").ForwardRefExoticComponent<{
27
+ name?: string | undefined;
28
+ } & Omit<import("./primitives/AvatarBase").AvatarBaseProps, "children"> & import("./primitives/ImageOrSvg").ImageOrSvgProps & import("react").RefAttributes<any>>;
29
+ export { AvatarNetworkProps, AvatarNetworkSize, } from './components/AvatarNetwork';
30
+ export declare const AvatarToken: import("react").ForwardRefExoticComponent<{
31
+ name?: string | undefined;
32
+ } & Omit<import("./primitives/AvatarBase").AvatarBaseProps, "children"> & import("./primitives/ImageOrSvg").ImageOrSvgProps & import("react").RefAttributes<any>>;
33
+ export { AvatarTokenProps, AvatarTokenSize } from './components/AvatarToken';
34
+ export declare const Blockies: ({ address, size, ...imageProps }: import("./primitives/Blockies").BlockiesProps) => import("react").JSX.Element;
35
+ export { BlockiesProps } from './primitives/Blockies';
36
+ export declare const ButtonAnimated: import("react").ForwardRefExoticComponent<import("react-native").PressableProps & import("react").RefAttributes<any>>;
37
+ export { ButtonAnimatedProps } from './primitives/ButtonAnimated';
38
+ export declare const ButtonBase: import("react").ForwardRefExoticComponent<{
39
+ children: import("react").ReactNode;
40
+ textProps?: Omit<Partial<import("./components/Text").TextProps>, "children"> | undefined;
41
+ size?: import("./primitives/ButtonBase").ButtonBaseSize | undefined;
42
+ isLoading?: boolean | undefined;
43
+ loadingText?: string | undefined;
44
+ spinnerProps?: Partial<import("./temp-components/Spinner").SpinnerProps> | undefined;
45
+ startIconName?: import("./components/Icon").IconName | undefined;
46
+ startIconProps?: Partial<import("./components/Icon").IconProps> | undefined;
47
+ startAccessory?: import("react").ReactNode;
48
+ endIconName?: import("./components/Icon").IconName | undefined;
49
+ endIconProps?: Partial<import("./components/Icon").IconProps> | undefined;
50
+ endAccessory?: import("react").ReactNode;
51
+ isDisabled?: boolean | undefined;
52
+ isFullWidth?: boolean | undefined;
53
+ twClassName?: string | undefined;
54
+ style?: import("react-native").StyleProp<import("react-native").ViewStyle>;
55
+ } & import("react-native").PressableProps & import("react").RefAttributes<any>>;
56
+ export { ButtonBaseProps, ButtonBaseSize } from './primitives/ButtonBase';
57
+ export declare const Button: import("react").ForwardRefExoticComponent<import("./components/Button").ButtonProps & import("react").RefAttributes<any>>;
58
+ export { ButtonProps, ButtonSize, ButtonVariant } from './components/Button';
59
+ export declare const ButtonIcon: import("react").ForwardRefExoticComponent<{
60
+ size?: import("./components/ButtonIcon").ButtonIconSize | undefined;
61
+ iconName: import("./components/Icon").IconName;
62
+ iconProps?: Partial<import("./components/Icon").IconProps> | undefined;
63
+ isDisabled?: boolean | undefined;
64
+ isInverse?: boolean | undefined;
65
+ isFloating?: boolean | undefined;
66
+ twClassName?: string | undefined;
67
+ style?: import("react-native").StyleProp<import("react-native").ViewStyle>;
68
+ } & Omit<import("react-native").PressableProps, "children"> & import("react").RefAttributes<any>>;
69
+ export { ButtonIconProps, ButtonIconSize } from './components/ButtonIcon';
70
+ export declare const Icon: import("react").ForwardRefExoticComponent<{
71
+ name: import("./components/Icon").IconName;
72
+ size?: import("./components/Icon").IconSize | undefined;
73
+ color?: import("./components/Icon").IconColor | undefined;
74
+ twClassName?: string | undefined;
75
+ } & import("react-native").ViewProps & import("react").RefAttributes<any>>;
76
+ export { IconColor, IconName, IconProps, IconSize } from './components/Icon';
77
+ export declare const Jazzicon: ({ testID, ...props }: import("./primitives/Jazzicon").JazziconProps) => import("react").JSX.Element;
78
+ export { JazziconProps } from './primitives/Jazzicon';
79
+ export declare const TextButton: import("react").ForwardRefExoticComponent<{
80
+ children: string;
81
+ textProps?: Omit<Partial<import("./components/Text").TextProps>, "children"> | undefined;
82
+ isLoading?: boolean | undefined;
83
+ loadingText?: string | undefined;
84
+ spinnerProps?: Partial<import("./temp-components/Spinner").SpinnerProps> | undefined;
85
+ startIconName?: import("./components/Icon").IconName | undefined;
86
+ startIconProps?: Partial<import("./components/Icon").IconProps> | undefined;
87
+ startAccessory?: import("react").ReactNode;
88
+ endIconName?: import("./components/Icon").IconName | undefined;
89
+ endIconProps?: Partial<import("./components/Icon").IconProps> | undefined;
90
+ endAccessory?: import("react").ReactNode;
91
+ isDisabled?: boolean | undefined;
92
+ isInverse?: boolean | undefined;
93
+ twClassName?: string | undefined;
94
+ style?: import("react-native").StyleProp<import("react-native").ViewStyle>;
95
+ } & Omit<import("react-native").PressableProps, "disabled"> & import("react").RefAttributes<any>>;
96
+ export { TextButtonProps } from './components/TextButton';
97
+ export declare const Text: import("react").ForwardRefExoticComponent<{
98
+ variant?: import("./components/Text").TextVariant | undefined;
99
+ children: import("react").ReactNode;
100
+ color?: import("./components/Text").TextColor | undefined;
101
+ fontWeight?: import("./components/Text").FontWeight | undefined;
102
+ fontStyle?: import("./components/Text").FontStyle | undefined;
103
+ twClassName?: string | undefined;
104
+ } & import("react-native").TextProps & import("react").RefAttributes<any>>;
105
+ export { FontWeight, FontStyle, TextColor, TextProps, TextVariant, } from './components/Text';
106
+ export declare const TextOrChildren: import("react").ForwardRefExoticComponent<import("./primitives/TextOrChildren").TextOrChildrenProps & import("react").RefAttributes<any>>;
107
+ export { TextOrChildrenProps } from './primitives/TextOrChildren/';
108
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,aAAa;;;oJAA4C,CAAC;AACvE,OAAO,EACL,kBAAkB,EAClB,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,4BAA4B,CAAC;AAGpC,eAAO,MAAM,UAAU;;;;;;;;0EAAyC,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG1E,eAAO,MAAM,aAAa;;iKAA4C,CAAC;AACvE,OAAO,EACL,kBAAkB,EAClB,iBAAiB,GAClB,MAAM,4BAA4B,CAAC;AAGpC,eAAO,MAAM,UAAU;;;;oJAAyC,CAAC;AACjE,OAAO,EACL,eAAe,EACf,kBAAkB,EAClB,cAAc,GACf,MAAM,yBAAyB,CAAC;AAGjC,eAAO,MAAM,aAAa;;iKAA4C,CAAC;AACvE,OAAO,EACL,kBAAkB,EAClB,iBAAiB,GAClB,MAAM,4BAA4B,CAAC;AAGpC,eAAO,MAAM,WAAW;;iKAA0C,CAAC;AACnE,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAG7E,eAAO,MAAM,QAAQ,kHAAoB,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAGtD,eAAO,MAAM,cAAc,uHAA6C,CAAC;AACzE,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AAGlE,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;+EAAyC,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG1E,eAAO,MAAM,MAAM,2HAAqC,CAAC;AACzD,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAG7E,eAAO,MAAM,UAAU;;;;;;;;;iGAAyC,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG1E,eAAO,MAAM,IAAI;;;;;0EAAmC,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAG7E,eAAO,MAAM,QAAQ,sGAAoB,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAGtD,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;iGAAyC,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAG1D,eAAO,MAAM,IAAI;;;;;;;0EAAmC,CAAC;AACrD,OAAO,EACL,UAAU,EACV,SAAS,EACT,SAAS,EACT,SAAS,EACT,WAAW,GACZ,MAAM,mBAAmB,CAAC;AAG3B,eAAO,MAAM,cAAc,2IAA6C,CAAC;AACzE,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC"}
package/dist/index.js CHANGED
@@ -1 +1,70 @@
1
- export { default as Button } from './components/Button';
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.TextOrChildren = exports.TextVariant = exports.TextColor = exports.FontStyle = exports.FontWeight = exports.Text = exports.TextButton = exports.Jazzicon = exports.IconSize = exports.IconName = exports.IconColor = exports.Icon = exports.ButtonIconSize = exports.ButtonIcon = exports.ButtonVariant = exports.ButtonSize = exports.Button = exports.ButtonBaseSize = exports.ButtonBase = exports.ButtonAnimated = exports.Blockies = exports.AvatarTokenSize = exports.AvatarToken = exports.AvatarNetworkSize = exports.AvatarNetwork = exports.AvatarIconSize = exports.AvatarIconSeverity = exports.AvatarIcon = exports.AvatarFaviconSize = exports.AvatarFavicon = exports.AvatarBaseSize = exports.AvatarBase = exports.AvatarAccountSize = exports.AvatarAccountVariant = exports.AvatarAccount = void 0;
7
+ const design_system_twrnc_preset_1 = require("@metamask-previews/design-system-twrnc-preset");
8
+ const AvatarAccount_1 = __importDefault(require("./components/AvatarAccount"));
9
+ exports.AvatarAccount = (0, design_system_twrnc_preset_1.withThemeProvider)(AvatarAccount_1.default);
10
+ var AvatarAccount_2 = require("./components/AvatarAccount");
11
+ Object.defineProperty(exports, "AvatarAccountVariant", { enumerable: true, get: function () { return AvatarAccount_2.AvatarAccountVariant; } });
12
+ Object.defineProperty(exports, "AvatarAccountSize", { enumerable: true, get: function () { return AvatarAccount_2.AvatarAccountSize; } });
13
+ const AvatarBase_1 = __importDefault(require("./primitives/AvatarBase"));
14
+ exports.AvatarBase = (0, design_system_twrnc_preset_1.withThemeProvider)(AvatarBase_1.default);
15
+ var AvatarBase_2 = require("./primitives/AvatarBase");
16
+ Object.defineProperty(exports, "AvatarBaseSize", { enumerable: true, get: function () { return AvatarBase_2.AvatarBaseSize; } });
17
+ const AvatarFavicon_1 = __importDefault(require("./components/AvatarFavicon"));
18
+ exports.AvatarFavicon = (0, design_system_twrnc_preset_1.withThemeProvider)(AvatarFavicon_1.default);
19
+ var AvatarFavicon_2 = require("./components/AvatarFavicon");
20
+ Object.defineProperty(exports, "AvatarFaviconSize", { enumerable: true, get: function () { return AvatarFavicon_2.AvatarFaviconSize; } });
21
+ const AvatarIcon_1 = __importDefault(require("./components/AvatarIcon"));
22
+ exports.AvatarIcon = (0, design_system_twrnc_preset_1.withThemeProvider)(AvatarIcon_1.default);
23
+ var AvatarIcon_2 = require("./components/AvatarIcon");
24
+ Object.defineProperty(exports, "AvatarIconSeverity", { enumerable: true, get: function () { return AvatarIcon_2.AvatarIconSeverity; } });
25
+ Object.defineProperty(exports, "AvatarIconSize", { enumerable: true, get: function () { return AvatarIcon_2.AvatarIconSize; } });
26
+ const AvatarNetwork_1 = __importDefault(require("./components/AvatarNetwork"));
27
+ exports.AvatarNetwork = (0, design_system_twrnc_preset_1.withThemeProvider)(AvatarNetwork_1.default);
28
+ var AvatarNetwork_2 = require("./components/AvatarNetwork");
29
+ Object.defineProperty(exports, "AvatarNetworkSize", { enumerable: true, get: function () { return AvatarNetwork_2.AvatarNetworkSize; } });
30
+ const AvatarToken_1 = __importDefault(require("./components/AvatarToken"));
31
+ exports.AvatarToken = (0, design_system_twrnc_preset_1.withThemeProvider)(AvatarToken_1.default);
32
+ var AvatarToken_2 = require("./components/AvatarToken");
33
+ Object.defineProperty(exports, "AvatarTokenSize", { enumerable: true, get: function () { return AvatarToken_2.AvatarTokenSize; } });
34
+ const Blockies_1 = __importDefault(require("./primitives/Blockies"));
35
+ exports.Blockies = Blockies_1.default;
36
+ const ButtonAnimated_1 = __importDefault(require("./primitives/ButtonAnimated"));
37
+ exports.ButtonAnimated = (0, design_system_twrnc_preset_1.withThemeProvider)(ButtonAnimated_1.default);
38
+ const ButtonBase_1 = __importDefault(require("./primitives/ButtonBase"));
39
+ exports.ButtonBase = (0, design_system_twrnc_preset_1.withThemeProvider)(ButtonBase_1.default);
40
+ var ButtonBase_2 = require("./primitives/ButtonBase");
41
+ Object.defineProperty(exports, "ButtonBaseSize", { enumerable: true, get: function () { return ButtonBase_2.ButtonBaseSize; } });
42
+ const Button_1 = __importDefault(require("./components/Button"));
43
+ exports.Button = (0, design_system_twrnc_preset_1.withThemeProvider)(Button_1.default);
44
+ var Button_2 = require("./components/Button");
45
+ Object.defineProperty(exports, "ButtonSize", { enumerable: true, get: function () { return Button_2.ButtonSize; } });
46
+ Object.defineProperty(exports, "ButtonVariant", { enumerable: true, get: function () { return Button_2.ButtonVariant; } });
47
+ const ButtonIcon_1 = __importDefault(require("./components/ButtonIcon"));
48
+ exports.ButtonIcon = (0, design_system_twrnc_preset_1.withThemeProvider)(ButtonIcon_1.default);
49
+ var ButtonIcon_2 = require("./components/ButtonIcon");
50
+ Object.defineProperty(exports, "ButtonIconSize", { enumerable: true, get: function () { return ButtonIcon_2.ButtonIconSize; } });
51
+ const Icon_1 = __importDefault(require("./components/Icon"));
52
+ exports.Icon = (0, design_system_twrnc_preset_1.withThemeProvider)(Icon_1.default);
53
+ var Icon_2 = require("./components/Icon");
54
+ Object.defineProperty(exports, "IconColor", { enumerable: true, get: function () { return Icon_2.IconColor; } });
55
+ Object.defineProperty(exports, "IconName", { enumerable: true, get: function () { return Icon_2.IconName; } });
56
+ Object.defineProperty(exports, "IconSize", { enumerable: true, get: function () { return Icon_2.IconSize; } });
57
+ const Jazzicon_1 = __importDefault(require("./primitives/Jazzicon"));
58
+ exports.Jazzicon = Jazzicon_1.default;
59
+ const TextButton_1 = __importDefault(require("./components/TextButton"));
60
+ exports.TextButton = (0, design_system_twrnc_preset_1.withThemeProvider)(TextButton_1.default);
61
+ const Text_1 = __importDefault(require("./components/Text"));
62
+ exports.Text = (0, design_system_twrnc_preset_1.withThemeProvider)(Text_1.default);
63
+ var Text_2 = require("./components/Text");
64
+ Object.defineProperty(exports, "FontWeight", { enumerable: true, get: function () { return Text_2.FontWeight; } });
65
+ Object.defineProperty(exports, "FontStyle", { enumerable: true, get: function () { return Text_2.FontStyle; } });
66
+ Object.defineProperty(exports, "TextColor", { enumerable: true, get: function () { return Text_2.TextColor; } });
67
+ Object.defineProperty(exports, "TextVariant", { enumerable: true, get: function () { return Text_2.TextVariant; } });
68
+ const TextOrChildren_1 = __importDefault(require("./primitives/TextOrChildren"));
69
+ exports.TextOrChildren = (0, design_system_twrnc_preset_1.withThemeProvider)(TextOrChildren_1.default);
70
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;AAAA,8FAAkF;AAElF,+EAAgE;AACnD,QAAA,aAAa,GAAG,IAAA,8CAAiB,EAAC,uBAAsB,CAAC,CAAC;AACvE,4DAIoC;AAFlC,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jC,QAAA,IAAI,GAAG,IAAA,8CAAiB,EAAC,cAAa,CAAC,CAAC;AACrD,0CAA6E;AAApE,iGAAA,SAAS,OAAA;AAAE,gGAAA,QAAQ,OAAA;AAAa,gGAAA,QAAQ,OAAA;AAEjD,qEAAsD;AACzC,QAAA,QAAQ,GAAG,kBAAiB,CAAC;AAG1C,yEAA0D;AAC7C,QAAA,UAAU,GAAG,IAAA,8CAAiB,EAAC,oBAAmB,CAAC,CAAC;AAGjE,6DAA8C;AACjC,QAAA,IAAI,GAAG,IAAA,8CAAiB,EAAC,cAAa,CAAC,CAAC;AACrD,0CAM2B;AALzB,kGAAA,UAAU,OAAA;AACV,iGAAA,SAAS,OAAA;AACT,iGAAA,SAAS,OAAA;AAET,mGAAA,WAAW,OAAA;AAGb,iFAAkE;AACrD,QAAA,cAAc,GAAG,IAAA,8CAAiB,EAAC,wBAAuB,CAAC,CAAC","sourcesContent":["import { withThemeProvider } from '@metamask-previews/design-system-twrnc-preset';\n\nimport AvatarAccountComponent from './components/AvatarAccount';\nexport const AvatarAccount = withThemeProvider(AvatarAccountComponent);\nexport {\n AvatarAccountProps,\n AvatarAccountVariant,\n AvatarAccountSize,\n} from './components/AvatarAccount';\n\nimport AvatarBaseComponent from './primitives/AvatarBase';\nexport const AvatarBase = withThemeProvider(AvatarBaseComponent);\nexport { AvatarBaseProps, AvatarBaseSize } from './primitives/AvatarBase';\n\nimport AvatarFaviconComponent from './components/AvatarFavicon';\nexport const AvatarFavicon = withThemeProvider(AvatarFaviconComponent);\nexport {\n AvatarFaviconProps,\n AvatarFaviconSize,\n} from './components/AvatarFavicon';\n\nimport AvatarIconComponent from './components/AvatarIcon';\nexport const AvatarIcon = withThemeProvider(AvatarIconComponent);\nexport {\n AvatarIconProps,\n AvatarIconSeverity,\n AvatarIconSize,\n} from './components/AvatarIcon';\n\nimport AvatarNetworkComponent from './components/AvatarNetwork';\nexport const AvatarNetwork = withThemeProvider(AvatarNetworkComponent);\nexport {\n AvatarNetworkProps,\n AvatarNetworkSize,\n} from './components/AvatarNetwork';\n\nimport AvatarTokenComponent from './components/AvatarToken';\nexport const AvatarToken = withThemeProvider(AvatarTokenComponent);\nexport { AvatarTokenProps, AvatarTokenSize } from './components/AvatarToken';\n\nimport BlockiesComponent from './primitives/Blockies';\nexport const Blockies = BlockiesComponent;\nexport { BlockiesProps } from './primitives/Blockies';\n\nimport ButtonAnimatedComponent from './primitives/ButtonAnimated';\nexport const ButtonAnimated = withThemeProvider(ButtonAnimatedComponent);\nexport { ButtonAnimatedProps } from './primitives/ButtonAnimated';\n\nimport ButtonBaseComponent from './primitives/ButtonBase';\nexport const ButtonBase = withThemeProvider(ButtonBaseComponent);\nexport { ButtonBaseProps, ButtonBaseSize } from './primitives/ButtonBase';\n\nimport ButtonComponent from './components/Button';\nexport const Button = withThemeProvider(ButtonComponent);\nexport { ButtonProps, ButtonSize, ButtonVariant } from './components/Button';\n\nimport ButtonIconComponent from './components/ButtonIcon';\nexport const ButtonIcon = withThemeProvider(ButtonIconComponent);\nexport { ButtonIconProps, ButtonIconSize } from './components/ButtonIcon';\n\nimport IconComponent from './components/Icon';\nexport const Icon = withThemeProvider(IconComponent);\nexport { IconColor, IconName, IconProps, IconSize } from './components/Icon';\n\nimport JazziconComponent from './primitives/Jazzicon';\nexport const Jazzicon = JazziconComponent;\nexport { JazziconProps } from './primitives/Jazzicon';\n\nimport TextButtonComponent from './components/TextButton';\nexport const TextButton = withThemeProvider(TextButtonComponent);\nexport { TextButtonProps } from './components/TextButton';\n\nimport TextComponent from './components/Text';\nexport const Text = withThemeProvider(TextComponent);\nexport {\n FontWeight,\n FontStyle,\n TextColor,\n TextProps,\n TextVariant,\n} from './components/Text';\n\nimport TextOrChildrenComponent from './primitives/TextOrChildren';\nexport const TextOrChildren = withThemeProvider(TextOrChildrenComponent);\nexport { TextOrChildrenProps } from './primitives/TextOrChildren/';\n"]}
@@ -0,0 +1,5 @@
1
+ import type { AvatarBaseProps } from './AvatarBase.types';
2
+ import { AvatarBaseSize } from '../../shared/enums';
3
+ export declare const TWCLASSMAP_AVATARBASE_SIZE_SHAPE: Record<AvatarBaseSize, string>;
4
+ export declare const DEFAULT_AVATARBASE_PROPS: Required<Pick<AvatarBaseProps, 'size' | 'shape' | 'fallbackTextProps'>>;
5
+ //# sourceMappingURL=AvatarBase.constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AvatarBase.constants.d.ts","sourceRoot":"","sources":["../../../src/primitives/AvatarBase/AvatarBase.constants.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAE1D,OAAO,EAAE,cAAc,EAAmB,MAAM,oBAAoB,CAAC;AAGrE,eAAO,MAAM,gCAAgC,EAAE,MAAM,CAAC,cAAc,EAAE,MAAM,CAOzE,CAAC;AAGJ,eAAO,MAAM,wBAAwB,EAAE,QAAQ,CAC7C,IAAI,CAAC,eAAe,EAAE,MAAM,GAAG,OAAO,GAAG,mBAAmB,CAAC,CAU9D,CAAC"}
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DEFAULT_AVATARBASE_PROPS = exports.TWCLASSMAP_AVATARBASE_SIZE_SHAPE = void 0;
4
+ const Text_1 = require("../../components/Text");
5
+ const enums_1 = require("../../shared/enums");
6
+ // Mappings
7
+ exports.TWCLASSMAP_AVATARBASE_SIZE_SHAPE = {
8
+ [enums_1.AvatarBaseSize.Xs]: 'rounded-sm',
9
+ [enums_1.AvatarBaseSize.Sm]: 'rounded-md',
10
+ [enums_1.AvatarBaseSize.Md]: 'rounded-lg',
11
+ [enums_1.AvatarBaseSize.Lg]: 'rounded-[10px]',
12
+ [enums_1.AvatarBaseSize.Xl]: 'rounded-xl',
13
+ };
14
+ // Defaults
15
+ exports.DEFAULT_AVATARBASE_PROPS = {
16
+ size: enums_1.AvatarBaseSize.Md,
17
+ shape: enums_1.AvatarBaseShape.Circle,
18
+ fallbackTextProps: {
19
+ color: Text_1.TextColor.TextMuted,
20
+ variant: Text_1.TextVariant.BodySm,
21
+ fontWeight: Text_1.FontWeight.Medium,
22
+ twClassName: 'uppercase',
23
+ },
24
+ };
25
+ //# sourceMappingURL=AvatarBase.constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AvatarBase.constants.js","sourceRoot":"","sources":["../../../src/primitives/AvatarBase/AvatarBase.constants.ts"],"names":[],"mappings":";;;AACA,gDAA2E;AAC3E,8CAAqE;AAErE,WAAW;AACE,QAAA,gCAAgC,GAC3C;IACE,CAAC,sBAAc,CAAC,EAAE,CAAC,EAAE,YAAY;IACjC,CAAC,sBAAc,CAAC,EAAE,CAAC,EAAE,YAAY;IACjC,CAAC,sBAAc,CAAC,EAAE,CAAC,EAAE,YAAY;IACjC,CAAC,sBAAc,CAAC,EAAE,CAAC,EAAE,gBAAgB;IACrC,CAAC,sBAAc,CAAC,EAAE,CAAC,EAAE,YAAY;CAClC,CAAC;AAEJ,WAAW;AACE,QAAA,wBAAwB,GAEjC;IACF,IAAI,EAAE,sBAAc,CAAC,EAAE;IACvB,KAAK,EAAE,uBAAe,CAAC,MAAM;IAC7B,iBAAiB,EAAE;QACjB,KAAK,EAAE,gBAAS,CAAC,SAAS;QAC1B,OAAO,EAAE,kBAAW,CAAC,MAAM;QAC3B,UAAU,EAAE,iBAAU,CAAC,MAAM;QAC7B,WAAW,EAAE,WAAW;KACzB;CACF,CAAC","sourcesContent":["import type { AvatarBaseProps } from './AvatarBase.types';\nimport { TextColor, TextVariant, FontWeight } from '../../components/Text';\nimport { AvatarBaseSize, AvatarBaseShape } from '../../shared/enums';\n\n// Mappings\nexport const TWCLASSMAP_AVATARBASE_SIZE_SHAPE: Record<AvatarBaseSize, string> =\n {\n [AvatarBaseSize.Xs]: 'rounded-sm',\n [AvatarBaseSize.Sm]: 'rounded-md',\n [AvatarBaseSize.Md]: 'rounded-lg',\n [AvatarBaseSize.Lg]: 'rounded-[10px]',\n [AvatarBaseSize.Xl]: 'rounded-xl',\n };\n\n// Defaults\nexport const DEFAULT_AVATARBASE_PROPS: Required<\n Pick<AvatarBaseProps, 'size' | 'shape' | 'fallbackTextProps'>\n> = {\n size: AvatarBaseSize.Md,\n shape: AvatarBaseShape.Circle,\n fallbackTextProps: {\n color: TextColor.TextMuted,\n variant: TextVariant.BodySm,\n fontWeight: FontWeight.Medium,\n twClassName: 'uppercase',\n },\n};\n"]}
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import type { AvatarBaseProps } from './AvatarBase.types';
3
+ declare const AvatarBase: ({ children, size, shape, fallbackText, fallbackTextProps, twClassName, style, ...props }: AvatarBaseProps) => React.JSX.Element;
4
+ export default AvatarBase;
5
+ //# sourceMappingURL=AvatarBase.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AvatarBase.d.ts","sourceRoot":"","sources":["../../../src/primitives/AvatarBase/AvatarBase.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAKvC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAG1D,QAAA,MAAM,UAAU,6FASb,eAAe,sBAwBjB,CAAC;AAEF,eAAe,UAAU,CAAC"}
@@ -0,0 +1,52 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ var __importDefault = (this && this.__importDefault) || function (mod) {
26
+ return (mod && mod.__esModule) ? mod : { "default": mod };
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ /* eslint-disable @typescript-eslint/prefer-nullish-coalescing */
30
+ const design_system_twrnc_preset_1 = require("@metamask-previews/design-system-twrnc-preset");
31
+ const react_1 = __importStar(require("react"));
32
+ const react_native_1 = require("react-native");
33
+ const Text_1 = __importDefault(require("../../components/Text"));
34
+ const AvatarBase_constants_1 = require("./AvatarBase.constants");
35
+ const AvatarBase_utilities_1 = require("./AvatarBase.utilities");
36
+ const AvatarBase = ({ children, size = AvatarBase_constants_1.DEFAULT_AVATARBASE_PROPS.size, shape = AvatarBase_constants_1.DEFAULT_AVATARBASE_PROPS.shape, fallbackText, fallbackTextProps, twClassName = '', style, ...props }) => {
37
+ const tw = (0, design_system_twrnc_preset_1.useTailwind)();
38
+ const twContainerClassNames = (0, react_1.useMemo)(() => {
39
+ return (0, AvatarBase_utilities_1.generateAvatarBaseContainerClassNames)({
40
+ size,
41
+ shape,
42
+ twClassName,
43
+ });
44
+ }, [size, shape, twClassName]);
45
+ return (<react_native_1.View style={[tw `${twContainerClassNames}`, style]} {...props}>
46
+ {fallbackText ? (<Text_1.default {...AvatarBase_constants_1.DEFAULT_AVATARBASE_PROPS.fallbackTextProps} {...fallbackTextProps}>
47
+ {fallbackText}
48
+ </Text_1.default>) : (children)}
49
+ </react_native_1.View>);
50
+ };
51
+ exports.default = AvatarBase;
52
+ //# sourceMappingURL=AvatarBase.js.map