@ezpg/app-ui 0.0.0-stage → 0.1.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 (546) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/LICENSE +20 -0
  3. package/lib/module/blocks/brand-profile-card/brand-profile-card.js +90 -0
  4. package/lib/module/blocks/brand-profile-card/brand-profile-card.js.map +1 -0
  5. package/lib/module/blocks/brand-profile-card/index.js +4 -0
  6. package/lib/module/blocks/brand-profile-card/index.js.map +1 -0
  7. package/lib/module/blocks/claim-row/claim-row.js +107 -0
  8. package/lib/module/blocks/claim-row/claim-row.js.map +1 -0
  9. package/lib/module/blocks/claim-row/index.js +4 -0
  10. package/lib/module/blocks/claim-row/index.js.map +1 -0
  11. package/lib/module/blocks/color-swatch-picker/color-swatch-picker.js +124 -0
  12. package/lib/module/blocks/color-swatch-picker/color-swatch-picker.js.map +1 -0
  13. package/lib/module/blocks/color-swatch-picker/index.js +4 -0
  14. package/lib/module/blocks/color-swatch-picker/index.js.map +1 -0
  15. package/lib/module/blocks/copy-variant-picker/copy-variant-picker.js +142 -0
  16. package/lib/module/blocks/copy-variant-picker/copy-variant-picker.js.map +1 -0
  17. package/lib/module/blocks/copy-variant-picker/index.js +4 -0
  18. package/lib/module/blocks/copy-variant-picker/index.js.map +1 -0
  19. package/lib/module/blocks/credit-wallet/credit-wallet.js +123 -0
  20. package/lib/module/blocks/credit-wallet/credit-wallet.js.map +1 -0
  21. package/lib/module/blocks/credit-wallet/index.js +4 -0
  22. package/lib/module/blocks/credit-wallet/index.js.map +1 -0
  23. package/lib/module/blocks/image-grid/image-grid.js +273 -0
  24. package/lib/module/blocks/image-grid/image-grid.js.map +1 -0
  25. package/lib/module/blocks/image-grid/index.js +4 -0
  26. package/lib/module/blocks/image-grid/index.js.map +1 -0
  27. package/lib/module/blocks/index.js +22 -0
  28. package/lib/module/blocks/index.js.map +1 -0
  29. package/lib/module/blocks/internal/card.js +41 -0
  30. package/lib/module/blocks/internal/card.js.map +1 -0
  31. package/lib/module/blocks/internal/format.js +25 -0
  32. package/lib/module/blocks/internal/format.js.map +1 -0
  33. package/lib/module/blocks/invoice-row/index.js +4 -0
  34. package/lib/module/blocks/invoice-row/index.js.map +1 -0
  35. package/lib/module/blocks/invoice-row/invoice-row.js +101 -0
  36. package/lib/module/blocks/invoice-row/invoice-row.js.map +1 -0
  37. package/lib/module/blocks/logo-candidate-grid/index.js +4 -0
  38. package/lib/module/blocks/logo-candidate-grid/index.js.map +1 -0
  39. package/lib/module/blocks/logo-candidate-grid/logo-candidate-grid.js +117 -0
  40. package/lib/module/blocks/logo-candidate-grid/logo-candidate-grid.js.map +1 -0
  41. package/lib/module/blocks/oauth-buttons/index.js +4 -0
  42. package/lib/module/blocks/oauth-buttons/index.js.map +1 -0
  43. package/lib/module/blocks/oauth-buttons/oauth-buttons.js +102 -0
  44. package/lib/module/blocks/oauth-buttons/oauth-buttons.js.map +1 -0
  45. package/lib/module/blocks/option-editor/index.js +4 -0
  46. package/lib/module/blocks/option-editor/index.js.map +1 -0
  47. package/lib/module/blocks/option-editor/option-editor.js +133 -0
  48. package/lib/module/blocks/option-editor/option-editor.js.map +1 -0
  49. package/lib/module/blocks/order-card/index.js +4 -0
  50. package/lib/module/blocks/order-card/index.js.map +1 -0
  51. package/lib/module/blocks/order-card/order-card.js +156 -0
  52. package/lib/module/blocks/order-card/order-card.js.map +1 -0
  53. package/lib/module/blocks/plan-card/index.js +4 -0
  54. package/lib/module/blocks/plan-card/index.js.map +1 -0
  55. package/lib/module/blocks/plan-card/plan-card.js +134 -0
  56. package/lib/module/blocks/plan-card/plan-card.js.map +1 -0
  57. package/lib/module/blocks/product-list-empty/index.js +4 -0
  58. package/lib/module/blocks/product-list-empty/index.js.map +1 -0
  59. package/lib/module/blocks/product-list-empty/product-list-empty.js +155 -0
  60. package/lib/module/blocks/product-list-empty/product-list-empty.js.map +1 -0
  61. package/lib/module/blocks/review-row/index.js +4 -0
  62. package/lib/module/blocks/review-row/index.js.map +1 -0
  63. package/lib/module/blocks/review-row/review-row.js +284 -0
  64. package/lib/module/blocks/review-row/review-row.js.map +1 -0
  65. package/lib/module/blocks/sales-chart/index.js +4 -0
  66. package/lib/module/blocks/sales-chart/index.js.map +1 -0
  67. package/lib/module/blocks/sales-chart/sales-chart.js +126 -0
  68. package/lib/module/blocks/sales-chart/sales-chart.js.map +1 -0
  69. package/lib/module/blocks/service-state-banner/index.js +4 -0
  70. package/lib/module/blocks/service-state-banner/index.js.map +1 -0
  71. package/lib/module/blocks/service-state-banner/service-state-banner.js +64 -0
  72. package/lib/module/blocks/service-state-banner/service-state-banner.js.map +1 -0
  73. package/lib/module/blocks/shipping-tracking-row/index.js +4 -0
  74. package/lib/module/blocks/shipping-tracking-row/index.js.map +1 -0
  75. package/lib/module/blocks/shipping-tracking-row/shipping-tracking-row.js +116 -0
  76. package/lib/module/blocks/shipping-tracking-row/shipping-tracking-row.js.map +1 -0
  77. package/lib/module/blocks/site-preview-frame/index.js +4 -0
  78. package/lib/module/blocks/site-preview-frame/index.js.map +1 -0
  79. package/lib/module/blocks/site-preview-frame/site-preview-frame.js +111 -0
  80. package/lib/module/blocks/site-preview-frame/site-preview-frame.js.map +1 -0
  81. package/lib/module/blocks/stat-card/index.js +4 -0
  82. package/lib/module/blocks/stat-card/index.js.map +1 -0
  83. package/lib/module/blocks/stat-card/stat-card.js +71 -0
  84. package/lib/module/blocks/stat-card/stat-card.js.map +1 -0
  85. package/lib/module/blocks/step-screen/index.js +4 -0
  86. package/lib/module/blocks/step-screen/index.js.map +1 -0
  87. package/lib/module/blocks/step-screen/step-screen.js +134 -0
  88. package/lib/module/blocks/step-screen/step-screen.js.map +1 -0
  89. package/lib/module/blocks/supply-item-card/index.js +4 -0
  90. package/lib/module/blocks/supply-item-card/index.js.map +1 -0
  91. package/lib/module/blocks/supply-item-card/supply-item-card.js +151 -0
  92. package/lib/module/blocks/supply-item-card/supply-item-card.js.map +1 -0
  93. package/lib/module/charts/index.js +5 -0
  94. package/lib/module/charts/index.js.map +1 -0
  95. package/lib/module/charts/line-chart.js +115 -0
  96. package/lib/module/charts/line-chart.js.map +1 -0
  97. package/lib/module/charts/scale.js +45 -0
  98. package/lib/module/charts/scale.js.map +1 -0
  99. package/lib/module/charts/sparkline.js +50 -0
  100. package/lib/module/charts/sparkline.js.map +1 -0
  101. package/lib/module/charts/summary.js +11 -0
  102. package/lib/module/charts/summary.js.map +1 -0
  103. package/lib/module/charts.js +5 -0
  104. package/lib/module/charts.js.map +1 -0
  105. package/lib/module/components/button/button.js +122 -0
  106. package/lib/module/components/button/button.js.map +1 -0
  107. package/lib/module/components/button/index.js +4 -0
  108. package/lib/module/components/button/index.js.map +1 -0
  109. package/lib/module/components/checkbox/checkbox.js +72 -0
  110. package/lib/module/components/checkbox/checkbox.js.map +1 -0
  111. package/lib/module/components/checkbox/index.js +4 -0
  112. package/lib/module/components/checkbox/index.js.map +1 -0
  113. package/lib/module/components/chip/chip.js +68 -0
  114. package/lib/module/components/chip/chip.js.map +1 -0
  115. package/lib/module/components/chip/index.js +4 -0
  116. package/lib/module/components/chip/index.js.map +1 -0
  117. package/lib/module/components/chip-group/chip-group.js +55 -0
  118. package/lib/module/components/chip-group/chip-group.js.map +1 -0
  119. package/lib/module/components/chip-group/index.js +4 -0
  120. package/lib/module/components/chip-group/index.js.map +1 -0
  121. package/lib/module/components/dialog/dialog.js +118 -0
  122. package/lib/module/components/dialog/dialog.js.map +1 -0
  123. package/lib/module/components/dialog/index.js +4 -0
  124. package/lib/module/components/dialog/index.js.map +1 -0
  125. package/lib/module/components/divider/divider.js +21 -0
  126. package/lib/module/components/divider/divider.js.map +1 -0
  127. package/lib/module/components/divider/index.js +4 -0
  128. package/lib/module/components/divider/index.js.map +1 -0
  129. package/lib/module/components/empty-state/empty-state.js +126 -0
  130. package/lib/module/components/empty-state/empty-state.js.map +1 -0
  131. package/lib/module/components/empty-state/index.js +4 -0
  132. package/lib/module/components/empty-state/index.js.map +1 -0
  133. package/lib/module/components/field/field.js +123 -0
  134. package/lib/module/components/field/field.js.map +1 -0
  135. package/lib/module/components/field/index.js +4 -0
  136. package/lib/module/components/field/index.js.map +1 -0
  137. package/lib/module/components/list-row/index.js +4 -0
  138. package/lib/module/components/list-row/index.js.map +1 -0
  139. package/lib/module/components/list-row/list-row.js +97 -0
  140. package/lib/module/components/list-row/list-row.js.map +1 -0
  141. package/lib/module/components/photo/index.js +4 -0
  142. package/lib/module/components/photo/index.js.map +1 -0
  143. package/lib/module/components/photo/photo.js +68 -0
  144. package/lib/module/components/photo/photo.js.map +1 -0
  145. package/lib/module/components/price/index.js +4 -0
  146. package/lib/module/components/price/index.js.map +1 -0
  147. package/lib/module/components/price/price.js +72 -0
  148. package/lib/module/components/price/price.js.map +1 -0
  149. package/lib/module/components/search-field/index.js +4 -0
  150. package/lib/module/components/search-field/index.js.map +1 -0
  151. package/lib/module/components/search-field/search-field.js +35 -0
  152. package/lib/module/components/search-field/search-field.js.map +1 -0
  153. package/lib/module/components/segmented-tabs/index.js +4 -0
  154. package/lib/module/components/segmented-tabs/index.js.map +1 -0
  155. package/lib/module/components/segmented-tabs/segmented-tabs.js +74 -0
  156. package/lib/module/components/segmented-tabs/segmented-tabs.js.map +1 -0
  157. package/lib/module/components/sheet/index.js +4 -0
  158. package/lib/module/components/sheet/index.js.map +1 -0
  159. package/lib/module/components/sheet/sheet.js +97 -0
  160. package/lib/module/components/sheet/sheet.js.map +1 -0
  161. package/lib/module/components/skeleton/index.js +4 -0
  162. package/lib/module/components/skeleton/index.js.map +1 -0
  163. package/lib/module/components/skeleton/skeleton.js +49 -0
  164. package/lib/module/components/skeleton/skeleton.js.map +1 -0
  165. package/lib/module/components/status-badge/index.js +4 -0
  166. package/lib/module/components/status-badge/index.js.map +1 -0
  167. package/lib/module/components/status-badge/status-badge.js +48 -0
  168. package/lib/module/components/status-badge/status-badge.js.map +1 -0
  169. package/lib/module/components/switch/index.js +4 -0
  170. package/lib/module/components/switch/index.js.map +1 -0
  171. package/lib/module/components/switch/switch.js +26 -0
  172. package/lib/module/components/switch/switch.js.map +1 -0
  173. package/lib/module/components/text/index.js +4 -0
  174. package/lib/module/components/text/index.js.map +1 -0
  175. package/lib/module/components/text/text.js +56 -0
  176. package/lib/module/components/text/text.js.map +1 -0
  177. package/lib/module/components/toast/index.js +4 -0
  178. package/lib/module/components/toast/index.js.map +1 -0
  179. package/lib/module/components/toast/toast.js +203 -0
  180. package/lib/module/components/toast/toast.js.map +1 -0
  181. package/lib/module/components/wizard-steps/index.js +4 -0
  182. package/lib/module/components/wizard-steps/index.js.map +1 -0
  183. package/lib/module/components/wizard-steps/wizard-steps.js +69 -0
  184. package/lib/module/components/wizard-steps/wizard-steps.js.map +1 -0
  185. package/lib/module/index.js +31 -0
  186. package/lib/module/index.js.map +1 -0
  187. package/lib/module/internal/glyphs.js +200 -0
  188. package/lib/module/internal/glyphs.js.map +1 -0
  189. package/lib/module/internal/icon.js +8 -0
  190. package/lib/module/internal/icon.js.map +1 -0
  191. package/lib/module/internal/overlay.js +60 -0
  192. package/lib/module/internal/overlay.js.map +1 -0
  193. package/lib/module/internal/pressable-base.js +40 -0
  194. package/lib/module/internal/pressable-base.js.map +1 -0
  195. package/lib/module/internal/use-reduced-motion.js +31 -0
  196. package/lib/module/internal/use-reduced-motion.js.map +1 -0
  197. package/lib/module/package.json +1 -0
  198. package/lib/module/sortable/index.js +6 -0
  199. package/lib/module/sortable/index.js.map +1 -0
  200. package/lib/module/sortable/move.js +11 -0
  201. package/lib/module/sortable/move.js.map +1 -0
  202. package/lib/module/sortable/sortable-grid.js +86 -0
  203. package/lib/module/sortable/sortable-grid.js.map +1 -0
  204. package/lib/module/sortable/sortable-list.js +16 -0
  205. package/lib/module/sortable/sortable-list.js.map +1 -0
  206. package/lib/module/sortable.js +6 -0
  207. package/lib/module/sortable.js.map +1 -0
  208. package/lib/module/theme/create-theme.js +56 -0
  209. package/lib/module/theme/create-theme.js.map +1 -0
  210. package/lib/module/theme/theme-provider.js +26 -0
  211. package/lib/module/theme/theme-provider.js.map +1 -0
  212. package/lib/module/theme/tokens.js +123 -0
  213. package/lib/module/theme/tokens.js.map +1 -0
  214. package/lib/module/types/index.js +4 -0
  215. package/lib/module/types/index.js.map +1 -0
  216. package/lib/module/utils/color.js +30 -0
  217. package/lib/module/utils/color.js.map +1 -0
  218. package/lib/module/utils/styles.js +22 -0
  219. package/lib/module/utils/styles.js.map +1 -0
  220. package/lib/typescript/package.json +1 -0
  221. package/lib/typescript/src/blocks/brand-profile-card/brand-profile-card.d.ts +15 -0
  222. package/lib/typescript/src/blocks/brand-profile-card/brand-profile-card.d.ts.map +1 -0
  223. package/lib/typescript/src/blocks/brand-profile-card/index.d.ts +2 -0
  224. package/lib/typescript/src/blocks/brand-profile-card/index.d.ts.map +1 -0
  225. package/lib/typescript/src/blocks/claim-row/claim-row.d.ts +22 -0
  226. package/lib/typescript/src/blocks/claim-row/claim-row.d.ts.map +1 -0
  227. package/lib/typescript/src/blocks/claim-row/index.d.ts +2 -0
  228. package/lib/typescript/src/blocks/claim-row/index.d.ts.map +1 -0
  229. package/lib/typescript/src/blocks/color-swatch-picker/color-swatch-picker.d.ts +16 -0
  230. package/lib/typescript/src/blocks/color-swatch-picker/color-swatch-picker.d.ts.map +1 -0
  231. package/lib/typescript/src/blocks/color-swatch-picker/index.d.ts +2 -0
  232. package/lib/typescript/src/blocks/color-swatch-picker/index.d.ts.map +1 -0
  233. package/lib/typescript/src/blocks/copy-variant-picker/copy-variant-picker.d.ts +22 -0
  234. package/lib/typescript/src/blocks/copy-variant-picker/copy-variant-picker.d.ts.map +1 -0
  235. package/lib/typescript/src/blocks/copy-variant-picker/index.d.ts +2 -0
  236. package/lib/typescript/src/blocks/copy-variant-picker/index.d.ts.map +1 -0
  237. package/lib/typescript/src/blocks/credit-wallet/credit-wallet.d.ts +14 -0
  238. package/lib/typescript/src/blocks/credit-wallet/credit-wallet.d.ts.map +1 -0
  239. package/lib/typescript/src/blocks/credit-wallet/index.d.ts +2 -0
  240. package/lib/typescript/src/blocks/credit-wallet/index.d.ts.map +1 -0
  241. package/lib/typescript/src/blocks/image-grid/image-grid.d.ts +24 -0
  242. package/lib/typescript/src/blocks/image-grid/image-grid.d.ts.map +1 -0
  243. package/lib/typescript/src/blocks/image-grid/index.d.ts +2 -0
  244. package/lib/typescript/src/blocks/image-grid/index.d.ts.map +1 -0
  245. package/lib/typescript/src/blocks/index.d.ts +20 -0
  246. package/lib/typescript/src/blocks/index.d.ts.map +1 -0
  247. package/lib/typescript/src/blocks/internal/card.d.ts +10 -0
  248. package/lib/typescript/src/blocks/internal/card.d.ts.map +1 -0
  249. package/lib/typescript/src/blocks/internal/format.d.ts +7 -0
  250. package/lib/typescript/src/blocks/internal/format.d.ts.map +1 -0
  251. package/lib/typescript/src/blocks/invoice-row/index.d.ts +2 -0
  252. package/lib/typescript/src/blocks/invoice-row/index.d.ts.map +1 -0
  253. package/lib/typescript/src/blocks/invoice-row/invoice-row.d.ts +22 -0
  254. package/lib/typescript/src/blocks/invoice-row/invoice-row.d.ts.map +1 -0
  255. package/lib/typescript/src/blocks/logo-candidate-grid/index.d.ts +2 -0
  256. package/lib/typescript/src/blocks/logo-candidate-grid/index.d.ts.map +1 -0
  257. package/lib/typescript/src/blocks/logo-candidate-grid/logo-candidate-grid.d.ts +17 -0
  258. package/lib/typescript/src/blocks/logo-candidate-grid/logo-candidate-grid.d.ts.map +1 -0
  259. package/lib/typescript/src/blocks/oauth-buttons/index.d.ts +2 -0
  260. package/lib/typescript/src/blocks/oauth-buttons/index.d.ts.map +1 -0
  261. package/lib/typescript/src/blocks/oauth-buttons/oauth-buttons.d.ts +20 -0
  262. package/lib/typescript/src/blocks/oauth-buttons/oauth-buttons.d.ts.map +1 -0
  263. package/lib/typescript/src/blocks/option-editor/index.d.ts +2 -0
  264. package/lib/typescript/src/blocks/option-editor/index.d.ts.map +1 -0
  265. package/lib/typescript/src/blocks/option-editor/option-editor.d.ts +20 -0
  266. package/lib/typescript/src/blocks/option-editor/option-editor.d.ts.map +1 -0
  267. package/lib/typescript/src/blocks/order-card/index.d.ts +2 -0
  268. package/lib/typescript/src/blocks/order-card/index.d.ts.map +1 -0
  269. package/lib/typescript/src/blocks/order-card/order-card.d.ts +44 -0
  270. package/lib/typescript/src/blocks/order-card/order-card.d.ts.map +1 -0
  271. package/lib/typescript/src/blocks/plan-card/index.d.ts +2 -0
  272. package/lib/typescript/src/blocks/plan-card/index.d.ts.map +1 -0
  273. package/lib/typescript/src/blocks/plan-card/plan-card.d.ts +36 -0
  274. package/lib/typescript/src/blocks/plan-card/plan-card.d.ts.map +1 -0
  275. package/lib/typescript/src/blocks/product-list-empty/index.d.ts +2 -0
  276. package/lib/typescript/src/blocks/product-list-empty/index.d.ts.map +1 -0
  277. package/lib/typescript/src/blocks/product-list-empty/product-list-empty.d.ts +21 -0
  278. package/lib/typescript/src/blocks/product-list-empty/product-list-empty.d.ts.map +1 -0
  279. package/lib/typescript/src/blocks/review-row/index.d.ts +2 -0
  280. package/lib/typescript/src/blocks/review-row/index.d.ts.map +1 -0
  281. package/lib/typescript/src/blocks/review-row/review-row.d.ts +34 -0
  282. package/lib/typescript/src/blocks/review-row/review-row.d.ts.map +1 -0
  283. package/lib/typescript/src/blocks/sales-chart/index.d.ts +2 -0
  284. package/lib/typescript/src/blocks/sales-chart/index.d.ts.map +1 -0
  285. package/lib/typescript/src/blocks/sales-chart/sales-chart.d.ts +20 -0
  286. package/lib/typescript/src/blocks/sales-chart/sales-chart.d.ts.map +1 -0
  287. package/lib/typescript/src/blocks/service-state-banner/index.d.ts +2 -0
  288. package/lib/typescript/src/blocks/service-state-banner/index.d.ts.map +1 -0
  289. package/lib/typescript/src/blocks/service-state-banner/service-state-banner.d.ts +13 -0
  290. package/lib/typescript/src/blocks/service-state-banner/service-state-banner.d.ts.map +1 -0
  291. package/lib/typescript/src/blocks/shipping-tracking-row/index.d.ts +2 -0
  292. package/lib/typescript/src/blocks/shipping-tracking-row/index.d.ts.map +1 -0
  293. package/lib/typescript/src/blocks/shipping-tracking-row/shipping-tracking-row.d.ts +12 -0
  294. package/lib/typescript/src/blocks/shipping-tracking-row/shipping-tracking-row.d.ts.map +1 -0
  295. package/lib/typescript/src/blocks/site-preview-frame/index.d.ts +2 -0
  296. package/lib/typescript/src/blocks/site-preview-frame/index.d.ts.map +1 -0
  297. package/lib/typescript/src/blocks/site-preview-frame/site-preview-frame.d.ts +18 -0
  298. package/lib/typescript/src/blocks/site-preview-frame/site-preview-frame.d.ts.map +1 -0
  299. package/lib/typescript/src/blocks/stat-card/index.d.ts +2 -0
  300. package/lib/typescript/src/blocks/stat-card/index.d.ts.map +1 -0
  301. package/lib/typescript/src/blocks/stat-card/stat-card.d.ts +17 -0
  302. package/lib/typescript/src/blocks/stat-card/stat-card.d.ts.map +1 -0
  303. package/lib/typescript/src/blocks/step-screen/index.d.ts +2 -0
  304. package/lib/typescript/src/blocks/step-screen/index.d.ts.map +1 -0
  305. package/lib/typescript/src/blocks/step-screen/step-screen.d.ts +26 -0
  306. package/lib/typescript/src/blocks/step-screen/step-screen.d.ts.map +1 -0
  307. package/lib/typescript/src/blocks/supply-item-card/index.d.ts +2 -0
  308. package/lib/typescript/src/blocks/supply-item-card/index.d.ts.map +1 -0
  309. package/lib/typescript/src/blocks/supply-item-card/supply-item-card.d.ts +30 -0
  310. package/lib/typescript/src/blocks/supply-item-card/supply-item-card.d.ts.map +1 -0
  311. package/lib/typescript/src/charts/index.d.ts +3 -0
  312. package/lib/typescript/src/charts/index.d.ts.map +1 -0
  313. package/lib/typescript/src/charts/line-chart.d.ts +21 -0
  314. package/lib/typescript/src/charts/line-chart.d.ts.map +1 -0
  315. package/lib/typescript/src/charts/scale.d.ts +13 -0
  316. package/lib/typescript/src/charts/scale.d.ts.map +1 -0
  317. package/lib/typescript/src/charts/sparkline.d.ts +15 -0
  318. package/lib/typescript/src/charts/sparkline.d.ts.map +1 -0
  319. package/lib/typescript/src/charts/summary.d.ts +3 -0
  320. package/lib/typescript/src/charts/summary.d.ts.map +1 -0
  321. package/lib/typescript/src/charts.d.ts +3 -0
  322. package/lib/typescript/src/charts.d.ts.map +1 -0
  323. package/lib/typescript/src/components/button/button.d.ts +18 -0
  324. package/lib/typescript/src/components/button/button.d.ts.map +1 -0
  325. package/lib/typescript/src/components/button/index.d.ts +2 -0
  326. package/lib/typescript/src/components/button/index.d.ts.map +1 -0
  327. package/lib/typescript/src/components/checkbox/checkbox.d.ts +8 -0
  328. package/lib/typescript/src/components/checkbox/checkbox.d.ts.map +1 -0
  329. package/lib/typescript/src/components/checkbox/index.d.ts +2 -0
  330. package/lib/typescript/src/components/checkbox/index.d.ts.map +1 -0
  331. package/lib/typescript/src/components/chip/chip.d.ts +9 -0
  332. package/lib/typescript/src/components/chip/chip.d.ts.map +1 -0
  333. package/lib/typescript/src/components/chip/index.d.ts +2 -0
  334. package/lib/typescript/src/components/chip/index.d.ts.map +1 -0
  335. package/lib/typescript/src/components/chip-group/chip-group.d.ts +27 -0
  336. package/lib/typescript/src/components/chip-group/chip-group.d.ts.map +1 -0
  337. package/lib/typescript/src/components/chip-group/index.d.ts +2 -0
  338. package/lib/typescript/src/components/chip-group/index.d.ts.map +1 -0
  339. package/lib/typescript/src/components/dialog/dialog.d.ts +20 -0
  340. package/lib/typescript/src/components/dialog/dialog.d.ts.map +1 -0
  341. package/lib/typescript/src/components/dialog/index.d.ts +2 -0
  342. package/lib/typescript/src/components/dialog/index.d.ts.map +1 -0
  343. package/lib/typescript/src/components/divider/divider.d.ts +9 -0
  344. package/lib/typescript/src/components/divider/divider.d.ts.map +1 -0
  345. package/lib/typescript/src/components/divider/index.d.ts +2 -0
  346. package/lib/typescript/src/components/divider/index.d.ts.map +1 -0
  347. package/lib/typescript/src/components/empty-state/empty-state.d.ts +26 -0
  348. package/lib/typescript/src/components/empty-state/empty-state.d.ts.map +1 -0
  349. package/lib/typescript/src/components/empty-state/index.d.ts +2 -0
  350. package/lib/typescript/src/components/empty-state/index.d.ts.map +1 -0
  351. package/lib/typescript/src/components/field/field.d.ts +15 -0
  352. package/lib/typescript/src/components/field/field.d.ts.map +1 -0
  353. package/lib/typescript/src/components/field/index.d.ts +2 -0
  354. package/lib/typescript/src/components/field/index.d.ts.map +1 -0
  355. package/lib/typescript/src/components/list-row/index.d.ts +2 -0
  356. package/lib/typescript/src/components/list-row/index.d.ts.map +1 -0
  357. package/lib/typescript/src/components/list-row/list-row.d.ts +15 -0
  358. package/lib/typescript/src/components/list-row/list-row.d.ts.map +1 -0
  359. package/lib/typescript/src/components/photo/index.d.ts +2 -0
  360. package/lib/typescript/src/components/photo/index.d.ts.map +1 -0
  361. package/lib/typescript/src/components/photo/photo.d.ts +15 -0
  362. package/lib/typescript/src/components/photo/photo.d.ts.map +1 -0
  363. package/lib/typescript/src/components/price/index.d.ts +2 -0
  364. package/lib/typescript/src/components/price/index.d.ts.map +1 -0
  365. package/lib/typescript/src/components/price/price.d.ts +15 -0
  366. package/lib/typescript/src/components/price/price.d.ts.map +1 -0
  367. package/lib/typescript/src/components/search-field/index.d.ts +2 -0
  368. package/lib/typescript/src/components/search-field/index.d.ts.map +1 -0
  369. package/lib/typescript/src/components/search-field/search-field.d.ts +9 -0
  370. package/lib/typescript/src/components/search-field/search-field.d.ts.map +1 -0
  371. package/lib/typescript/src/components/segmented-tabs/index.d.ts +2 -0
  372. package/lib/typescript/src/components/segmented-tabs/index.d.ts.map +1 -0
  373. package/lib/typescript/src/components/segmented-tabs/segmented-tabs.d.ts +14 -0
  374. package/lib/typescript/src/components/segmented-tabs/segmented-tabs.d.ts.map +1 -0
  375. package/lib/typescript/src/components/sheet/index.d.ts +2 -0
  376. package/lib/typescript/src/components/sheet/index.d.ts.map +1 -0
  377. package/lib/typescript/src/components/sheet/sheet.d.ts +17 -0
  378. package/lib/typescript/src/components/sheet/sheet.d.ts.map +1 -0
  379. package/lib/typescript/src/components/skeleton/index.d.ts +2 -0
  380. package/lib/typescript/src/components/skeleton/index.d.ts.map +1 -0
  381. package/lib/typescript/src/components/skeleton/skeleton.d.ts +13 -0
  382. package/lib/typescript/src/components/skeleton/skeleton.d.ts.map +1 -0
  383. package/lib/typescript/src/components/status-badge/index.d.ts +2 -0
  384. package/lib/typescript/src/components/status-badge/index.d.ts.map +1 -0
  385. package/lib/typescript/src/components/status-badge/status-badge.d.ts +10 -0
  386. package/lib/typescript/src/components/status-badge/status-badge.d.ts.map +1 -0
  387. package/lib/typescript/src/components/switch/index.d.ts +2 -0
  388. package/lib/typescript/src/components/switch/index.d.ts.map +1 -0
  389. package/lib/typescript/src/components/switch/switch.d.ts +9 -0
  390. package/lib/typescript/src/components/switch/switch.d.ts.map +1 -0
  391. package/lib/typescript/src/components/text/index.d.ts +2 -0
  392. package/lib/typescript/src/components/text/index.d.ts.map +1 -0
  393. package/lib/typescript/src/components/text/text.d.ts +16 -0
  394. package/lib/typescript/src/components/text/text.d.ts.map +1 -0
  395. package/lib/typescript/src/components/toast/index.d.ts +2 -0
  396. package/lib/typescript/src/components/toast/index.d.ts.map +1 -0
  397. package/lib/typescript/src/components/toast/toast.d.ts +30 -0
  398. package/lib/typescript/src/components/toast/toast.d.ts.map +1 -0
  399. package/lib/typescript/src/components/wizard-steps/index.d.ts +2 -0
  400. package/lib/typescript/src/components/wizard-steps/index.d.ts.map +1 -0
  401. package/lib/typescript/src/components/wizard-steps/wizard-steps.d.ts +11 -0
  402. package/lib/typescript/src/components/wizard-steps/wizard-steps.d.ts.map +1 -0
  403. package/lib/typescript/src/index.d.ts +31 -0
  404. package/lib/typescript/src/index.d.ts.map +1 -0
  405. package/lib/typescript/src/internal/glyphs.d.ts +12 -0
  406. package/lib/typescript/src/internal/glyphs.d.ts.map +1 -0
  407. package/lib/typescript/src/internal/icon.d.ts +9 -0
  408. package/lib/typescript/src/internal/icon.d.ts.map +1 -0
  409. package/lib/typescript/src/internal/overlay.d.ts +16 -0
  410. package/lib/typescript/src/internal/overlay.d.ts.map +1 -0
  411. package/lib/typescript/src/internal/pressable-base.d.ts +13 -0
  412. package/lib/typescript/src/internal/pressable-base.d.ts.map +1 -0
  413. package/lib/typescript/src/internal/use-reduced-motion.d.ts +3 -0
  414. package/lib/typescript/src/internal/use-reduced-motion.d.ts.map +1 -0
  415. package/lib/typescript/src/sortable/index.d.ts +4 -0
  416. package/lib/typescript/src/sortable/index.d.ts.map +1 -0
  417. package/lib/typescript/src/sortable/move.d.ts +3 -0
  418. package/lib/typescript/src/sortable/move.d.ts.map +1 -0
  419. package/lib/typescript/src/sortable/sortable-grid.d.ts +37 -0
  420. package/lib/typescript/src/sortable/sortable-grid.d.ts.map +1 -0
  421. package/lib/typescript/src/sortable/sortable-list.d.ts +5 -0
  422. package/lib/typescript/src/sortable/sortable-list.d.ts.map +1 -0
  423. package/lib/typescript/src/sortable.d.ts +4 -0
  424. package/lib/typescript/src/sortable.d.ts.map +1 -0
  425. package/lib/typescript/src/theme/create-theme.d.ts +8 -0
  426. package/lib/typescript/src/theme/create-theme.d.ts.map +1 -0
  427. package/lib/typescript/src/theme/theme-provider.d.ts +13 -0
  428. package/lib/typescript/src/theme/theme-provider.d.ts.map +1 -0
  429. package/lib/typescript/src/theme/tokens.d.ts +4 -0
  430. package/lib/typescript/src/theme/tokens.d.ts.map +1 -0
  431. package/lib/typescript/src/types/index.d.ts +90 -0
  432. package/lib/typescript/src/types/index.d.ts.map +1 -0
  433. package/lib/typescript/src/utils/color.d.ts +5 -0
  434. package/lib/typescript/src/utils/color.d.ts.map +1 -0
  435. package/lib/typescript/src/utils/styles.d.ts +13 -0
  436. package/lib/typescript/src/utils/styles.d.ts.map +1 -0
  437. package/package.json +109 -3
  438. package/src/blocks/brand-profile-card/brand-profile-card.tsx +87 -0
  439. package/src/blocks/brand-profile-card/index.ts +4 -0
  440. package/src/blocks/claim-row/claim-row.tsx +112 -0
  441. package/src/blocks/claim-row/index.ts +6 -0
  442. package/src/blocks/color-swatch-picker/color-swatch-picker.tsx +119 -0
  443. package/src/blocks/color-swatch-picker/index.ts +5 -0
  444. package/src/blocks/copy-variant-picker/copy-variant-picker.tsx +140 -0
  445. package/src/blocks/copy-variant-picker/index.ts +5 -0
  446. package/src/blocks/credit-wallet/credit-wallet.tsx +105 -0
  447. package/src/blocks/credit-wallet/index.ts +1 -0
  448. package/src/blocks/image-grid/image-grid.tsx +279 -0
  449. package/src/blocks/image-grid/index.ts +1 -0
  450. package/src/blocks/index.tsx +19 -0
  451. package/src/blocks/internal/card.tsx +42 -0
  452. package/src/blocks/internal/format.ts +22 -0
  453. package/src/blocks/invoice-row/index.ts +5 -0
  454. package/src/blocks/invoice-row/invoice-row.tsx +122 -0
  455. package/src/blocks/logo-candidate-grid/index.ts +5 -0
  456. package/src/blocks/logo-candidate-grid/logo-candidate-grid.tsx +129 -0
  457. package/src/blocks/oauth-buttons/index.ts +5 -0
  458. package/src/blocks/oauth-buttons/oauth-buttons.tsx +109 -0
  459. package/src/blocks/option-editor/index.ts +5 -0
  460. package/src/blocks/option-editor/option-editor.tsx +135 -0
  461. package/src/blocks/order-card/index.ts +11 -0
  462. package/src/blocks/order-card/order-card.tsx +184 -0
  463. package/src/blocks/plan-card/index.ts +1 -0
  464. package/src/blocks/plan-card/plan-card.tsx +147 -0
  465. package/src/blocks/product-list-empty/index.ts +5 -0
  466. package/src/blocks/product-list-empty/product-list-empty.tsx +144 -0
  467. package/src/blocks/review-row/index.ts +8 -0
  468. package/src/blocks/review-row/review-row.tsx +256 -0
  469. package/src/blocks/sales-chart/index.ts +5 -0
  470. package/src/blocks/sales-chart/sales-chart.tsx +120 -0
  471. package/src/blocks/service-state-banner/index.ts +5 -0
  472. package/src/blocks/service-state-banner/service-state-banner.tsx +66 -0
  473. package/src/blocks/shipping-tracking-row/index.ts +5 -0
  474. package/src/blocks/shipping-tracking-row/shipping-tracking-row.tsx +93 -0
  475. package/src/blocks/site-preview-frame/index.ts +5 -0
  476. package/src/blocks/site-preview-frame/site-preview-frame.tsx +121 -0
  477. package/src/blocks/stat-card/index.ts +1 -0
  478. package/src/blocks/stat-card/stat-card.tsx +77 -0
  479. package/src/blocks/step-screen/index.ts +5 -0
  480. package/src/blocks/step-screen/step-screen.tsx +137 -0
  481. package/src/blocks/supply-item-card/index.ts +6 -0
  482. package/src/blocks/supply-item-card/supply-item-card.tsx +145 -0
  483. package/src/charts/index.ts +2 -0
  484. package/src/charts/line-chart.tsx +177 -0
  485. package/src/charts/scale.ts +49 -0
  486. package/src/charts/sparkline.tsx +64 -0
  487. package/src/charts/summary.ts +11 -0
  488. package/src/charts.tsx +2 -0
  489. package/src/components/button/button.tsx +119 -0
  490. package/src/components/button/index.ts +6 -0
  491. package/src/components/checkbox/checkbox.tsx +79 -0
  492. package/src/components/checkbox/index.ts +1 -0
  493. package/src/components/chip/chip.tsx +73 -0
  494. package/src/components/chip/index.ts +1 -0
  495. package/src/components/chip-group/chip-group.tsx +86 -0
  496. package/src/components/chip-group/index.ts +5 -0
  497. package/src/components/dialog/dialog.tsx +131 -0
  498. package/src/components/dialog/index.ts +1 -0
  499. package/src/components/divider/divider.tsx +26 -0
  500. package/src/components/divider/index.ts +1 -0
  501. package/src/components/empty-state/empty-state.tsx +152 -0
  502. package/src/components/empty-state/index.ts +5 -0
  503. package/src/components/field/field.tsx +151 -0
  504. package/src/components/field/index.ts +1 -0
  505. package/src/components/list-row/index.ts +1 -0
  506. package/src/components/list-row/list-row.tsx +115 -0
  507. package/src/components/photo/index.ts +1 -0
  508. package/src/components/photo/photo.tsx +87 -0
  509. package/src/components/price/index.ts +1 -0
  510. package/src/components/price/price.tsx +84 -0
  511. package/src/components/search-field/index.ts +1 -0
  512. package/src/components/search-field/search-field.tsx +46 -0
  513. package/src/components/segmented-tabs/index.ts +5 -0
  514. package/src/components/segmented-tabs/segmented-tabs.tsx +81 -0
  515. package/src/components/sheet/index.ts +1 -0
  516. package/src/components/sheet/sheet.tsx +121 -0
  517. package/src/components/skeleton/index.ts +1 -0
  518. package/src/components/skeleton/skeleton.tsx +73 -0
  519. package/src/components/status-badge/index.ts +5 -0
  520. package/src/components/status-badge/status-badge.tsx +54 -0
  521. package/src/components/switch/index.ts +1 -0
  522. package/src/components/switch/switch.tsx +26 -0
  523. package/src/components/text/index.ts +1 -0
  524. package/src/components/text/text.tsx +54 -0
  525. package/src/components/toast/index.ts +9 -0
  526. package/src/components/toast/toast.tsx +248 -0
  527. package/src/components/wizard-steps/index.ts +1 -0
  528. package/src/components/wizard-steps/wizard-steps.tsx +54 -0
  529. package/src/index.tsx +56 -0
  530. package/src/internal/glyphs.tsx +158 -0
  531. package/src/internal/icon.tsx +10 -0
  532. package/src/internal/overlay.tsx +59 -0
  533. package/src/internal/pressable-base.tsx +55 -0
  534. package/src/internal/use-reduced-motion.ts +32 -0
  535. package/src/sortable/index.ts +8 -0
  536. package/src/sortable/move.ts +19 -0
  537. package/src/sortable/sortable-grid.tsx +97 -0
  538. package/src/sortable/sortable-list.tsx +11 -0
  539. package/src/sortable.tsx +3 -0
  540. package/src/theme/create-theme.ts +67 -0
  541. package/src/theme/theme-provider.tsx +37 -0
  542. package/src/theme/tokens.ts +91 -0
  543. package/src/types/index.ts +80 -0
  544. package/src/utils/color.ts +47 -0
  545. package/src/utils/styles.ts +30 -0
  546. package/README.md +0 -3
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+
3
+ import { Text, View } from 'react-native';
4
+ import { PressableBase } from "../../internal/pressable-base.js";
5
+ import { useTheme } from "../../theme/theme-provider.js";
6
+ import { makeStyles } from "../../utils/styles.js";
7
+ import { jsx as _jsx } from "react/jsx-runtime";
8
+ const HEIGHT = 40;
9
+ const useStyles = makeStyles(t => ({
10
+ track: {
11
+ flexDirection: 'row',
12
+ height: HEIGHT,
13
+ padding: t.space[1],
14
+ gap: t.space[1],
15
+ borderRadius: t.radius.md,
16
+ backgroundColor: t.colors.muted
17
+ },
18
+ tab: {
19
+ flex: 1,
20
+ alignItems: 'center',
21
+ justifyContent: 'center',
22
+ borderRadius: t.radius.sm
23
+ },
24
+ selected: {
25
+ backgroundColor: t.colors.background,
26
+ boxShadow: t.shadow.sm
27
+ },
28
+ label: {
29
+ fontFamily: t.fontFamily,
30
+ fontSize: 14,
31
+ lineHeight: 20,
32
+ fontWeight: '500',
33
+ color: t.colors.mutedForeground
34
+ },
35
+ selectedLabel: {
36
+ color: t.colors.foreground
37
+ }
38
+ }));
39
+ export function SegmentedTabs({
40
+ items,
41
+ value,
42
+ onValueChange,
43
+ style
44
+ }) {
45
+ const t = useTheme();
46
+ const s = useStyles();
47
+ return /*#__PURE__*/_jsx(View, {
48
+ accessibilityRole: "tablist",
49
+ style: [s.track, style],
50
+ children: items.map(item => {
51
+ const selected = item.value === value;
52
+ return /*#__PURE__*/_jsx(PressableBase, {
53
+ accessibilityRole: "tab",
54
+ accessibilityState: {
55
+ selected
56
+ },
57
+ accessibilityLabel: item.label,
58
+ touchHeight: HEIGHT,
59
+ pressedStyle: {},
60
+ onPress: () => {
61
+ if (!selected) onValueChange(item.value);
62
+ },
63
+ style: [s.tab, selected && s.selected],
64
+ children: /*#__PURE__*/_jsx(Text, {
65
+ numberOfLines: 1,
66
+ maxFontSizeMultiplier: t.maxFontScale,
67
+ style: [s.label, selected && s.selectedLabel],
68
+ children: item.label
69
+ })
70
+ }, item.value);
71
+ })
72
+ });
73
+ }
74
+ //# sourceMappingURL=segmented-tabs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Text","View","PressableBase","useTheme","makeStyles","jsx","_jsx","HEIGHT","useStyles","t","track","flexDirection","height","padding","space","gap","borderRadius","radius","md","backgroundColor","colors","muted","tab","flex","alignItems","justifyContent","sm","selected","background","boxShadow","shadow","label","fontFamily","fontSize","lineHeight","fontWeight","color","mutedForeground","selectedLabel","foreground","SegmentedTabs","items","value","onValueChange","style","s","accessibilityRole","children","map","item","accessibilityState","accessibilityLabel","touchHeight","pressedStyle","onPress","numberOfLines","maxFontSizeMultiplier","maxFontScale"],"sourceRoot":"../../../../src","sources":["components/segmented-tabs/segmented-tabs.tsx"],"mappings":";;AAAA,SAASA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C,GAAGN,QAAQ,CAAC,CAAC;EACpB,MAAM0C,CAAC,GAAGrC,SAAS,CAAC,CAAC;EACrB,oBACEF,IAAA,CAACL,IAAI;IAAC6C,iBAAiB,EAAC,SAAS;IAACF,KAAK,EAAE,CAACC,CAAC,CAACnC,KAAK,EAAEkC,KAAK,CAAE;IAAAG,QAAA,EACvDN,KAAK,CAACO,GAAG,CAAEC,IAAI,IAAK;MACnB,MAAMtB,QAAQ,GAAGsB,IAAI,CAACP,KAAK,KAAKA,KAAK;MACrC,oBACEpC,IAAA,CAACJ,aAAa;QAEZ4C,iBAAiB,EAAC,KAAK;QACvBI,kBAAkB,EAAE;UAAEvB;QAAS,CAAE;QACjCwB,kBAAkB,EAAEF,IAAI,CAAClB,KAAM;QAC/BqB,WAAW,EAAE7C,MAAO;QACpB8C,YAAY,EAAE,CAAC,CAAE;QACjBC,OAAO,EAAEA,CAAA,KAAM;UACb,IAAI,CAAC3B,QAAQ,EAAEgB,aAAa,CAACM,IAAI,CAACP,KAAK,CAAC;QAC1C,CAAE;QACFE,KAAK,EAAE,CAACC,CAAC,CAACvB,GAAG,EAAEK,QAAQ,IAAIkB,CAAC,CAAClB,QAAQ,CAAE;QAAAoB,QAAA,eAEvCzC,IAAA,CAACN,IAAI;UACHuD,aAAa,EAAE,CAAE;UACjBC,qBAAqB,EAAE/C,CAAC,CAACgD,YAAa;UACtCb,KAAK,EAAE,CAACC,CAAC,CAACd,KAAK,EAAEJ,QAAQ,IAAIkB,CAAC,CAACP,aAAa,CAAE;UAAAS,QAAA,EAE7CE,IAAI,CAAClB;QAAK,CACP;MAAC,GAjBFkB,IAAI,CAACP,KAkBG,CAAC;IAEpB,CAAC;EAAC,CACE,CAAC;AAEX","ignoreList":[]}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export { Sheet } from "./sheet.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Sheet"],"sourceRoot":"../../../../src","sources":["components/sheet/index.ts"],"mappings":";;AAAA,SAASA,KAAK,QAAyB,YAAS","ignoreList":[]}
@@ -0,0 +1,97 @@
1
+ "use strict";
2
+
3
+ import { Animated, KeyboardAvoidingView, Modal, Text, useWindowDimensions, View } from 'react-native';
4
+ import { Backdrop, useOverlayTransition } from "../../internal/overlay.js";
5
+ import { useTheme } from "../../theme/theme-provider.js";
6
+ import { makeStyles } from "../../utils/styles.js";
7
+ import { ToastHost } from "../toast/toast.js";
8
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
9
+ const useStyles = makeStyles(t => ({
10
+ root: {
11
+ flex: 1,
12
+ justifyContent: 'flex-end'
13
+ },
14
+ panel: {
15
+ maxHeight: '90%',
16
+ paddingTop: t.space[2],
17
+ paddingHorizontal: t.space[4],
18
+ gap: t.space[3],
19
+ borderTopLeftRadius: t.radius.lg,
20
+ borderTopRightRadius: t.radius.lg,
21
+ backgroundColor: t.colors.background,
22
+ boxShadow: t.shadow.md
23
+ },
24
+ handle: {
25
+ alignSelf: 'center',
26
+ width: 36,
27
+ height: 4,
28
+ borderRadius: t.radius.full,
29
+ backgroundColor: t.colors.border
30
+ },
31
+ title: {
32
+ ...t.typography.title,
33
+ fontFamily: t.fontFamily,
34
+ color: t.colors.foreground
35
+ }
36
+ }));
37
+ export function Sheet({
38
+ open,
39
+ onOpenChange,
40
+ title,
41
+ bottomInset = 0,
42
+ dismissible = true,
43
+ closeLabel = '닫기',
44
+ children,
45
+ style
46
+ }) {
47
+ const t = useTheme();
48
+ const s = useStyles();
49
+ const {
50
+ height
51
+ } = useWindowDimensions();
52
+ const {
53
+ mounted,
54
+ progress
55
+ } = useOverlayTransition(open);
56
+ const close = () => {
57
+ if (dismissible) onOpenChange(false);
58
+ };
59
+ return /*#__PURE__*/_jsxs(Modal, {
60
+ visible: mounted,
61
+ transparent: true,
62
+ animationType: "none",
63
+ statusBarTranslucent: true,
64
+ navigationBarTranslucent: true,
65
+ onRequestClose: close,
66
+ children: [/*#__PURE__*/_jsxs(KeyboardAvoidingView, {
67
+ behavior: "padding",
68
+ style: s.root,
69
+ children: [/*#__PURE__*/_jsx(Backdrop, {
70
+ progress: progress,
71
+ onPress: close,
72
+ label: closeLabel
73
+ }), /*#__PURE__*/_jsxs(Animated.View, {
74
+ accessibilityViewIsModal: true,
75
+ style: [s.panel, {
76
+ paddingBottom: t.space[4] + bottomInset
77
+ }, {
78
+ transform: [{
79
+ translateY: progress.interpolate({
80
+ inputRange: [0, 1],
81
+ outputRange: [height, 0]
82
+ })
83
+ }]
84
+ }, style],
85
+ children: [/*#__PURE__*/_jsx(View, {
86
+ style: s.handle
87
+ }), title ? /*#__PURE__*/_jsx(Text, {
88
+ accessibilityRole: "header",
89
+ maxFontSizeMultiplier: t.maxFontScale,
90
+ style: s.title,
91
+ children: title
92
+ }) : null, children]
93
+ })]
94
+ }), /*#__PURE__*/_jsx(ToastHost, {})]
95
+ });
96
+ }
97
+ //# sourceMappingURL=sheet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Animated","KeyboardAvoidingView","Modal","Text","useWindowDimensions","View","Backdrop","useOverlayTransition","useTheme","makeStyles","ToastHost","jsx","_jsx","jsxs","_jsxs","useStyles","t","root","flex","justifyContent","panel","maxHeight","paddingTop","space","paddingHorizontal","gap","borderTopLeftRadius","radius","lg","borderTopRightRadius","backgroundColor","colors","background","boxShadow","shadow","md","handle","alignSelf","width","height","borderRadius","full","border","title","typography","fontFamily","color","foreground","Sheet","open","onOpenChange","bottomInset","dismissible","closeLabel","children","style","s","mounted","progress","close","visible","transparent","animationType","statusBarTranslucent","navigationBarTranslucent","onRequestClose","behavior","onPress","label","accessibilityViewIsModal","paddingBottom","transform","translateY","interpolate","inputRange","outputRange","accessibilityRole","maxFontSizeMultiplier","maxFontScale"],"sourceRoot":"../../../../src","sources":["components/sheet/sheet.tsx"],"mappings":";;AACA,SACEA,QAAQ,EACRC,oBAAoB,EACpBC,KAAK,EACLC,IAAI,EACJC,mBAAmB,EACnBC,I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C;QAEL,CAAC,EACDgB,KAAK,CACL;QAAAD,QAAA,gBAEF1C,IAAA,CAACP,IAAI;UAACkD,KAAK,EAAEC,CAAC,CAACpB;QAAO,CAAE,CAAC,EACxBO,KAAK,gBACJ/B,IAAA,CAACT,IAAI;UACHyE,iBAAiB,EAAC,QAAQ;UAC1BC,qBAAqB,EAAE7D,CAAC,CAAC8D,YAAa;UACtCvB,KAAK,EAAEC,CAAC,CAACb,KAAM;UAAAW,QAAA,EAEdX;QAAK,CACF,CAAC,GACL,IAAI,EACPW,QAAQ;MAAA,CACI,CAAC;IAAA,CACI,CAAC,eACvB1C,IAAA,CAACF,SAAS,IAAE,CAAC;EAAA,CACR,CAAC;AAEZ","ignoreList":[]}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export { Skeleton } from "./skeleton.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Skeleton"],"sourceRoot":"../../../../src","sources":["components/skeleton/index.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAA4B,eAAY","ignoreList":[]}
@@ -0,0 +1,49 @@
1
+ "use strict";
2
+
3
+ import { useEffect, useRef } from 'react';
4
+ import { Animated } from 'react-native';
5
+ import { useNativeDriver } from "../../internal/overlay.js";
6
+ import { useReducedMotion } from "../../internal/use-reduced-motion.js";
7
+ import { useTheme } from "../../theme/theme-provider.js";
8
+ import { jsx as _jsx } from "react/jsx-runtime";
9
+ /** 불러오는 중인 자리. '동작 줄이기'가 켜져 있으면 깜빡이지 않는다 */
10
+ export function Skeleton({
11
+ width = '100%',
12
+ height = 16,
13
+ radius,
14
+ style
15
+ }) {
16
+ const t = useTheme();
17
+ const reduced = useReducedMotion();
18
+ const opacity = useRef(new Animated.Value(1)).current;
19
+ useEffect(() => {
20
+ if (reduced) {
21
+ opacity.setValue(0.7);
22
+ return;
23
+ }
24
+ const half = t.motion.duration * 4;
25
+ const loop = Animated.loop(Animated.sequence([Animated.timing(opacity, {
26
+ toValue: 0.5,
27
+ duration: half,
28
+ useNativeDriver
29
+ }), Animated.timing(opacity, {
30
+ toValue: 1,
31
+ duration: half,
32
+ useNativeDriver
33
+ })]));
34
+ loop.start();
35
+ return () => loop.stop();
36
+ }, [opacity, reduced, t.motion.duration]);
37
+ return /*#__PURE__*/_jsx(Animated.View, {
38
+ accessible: false,
39
+ importantForAccessibility: "no-hide-descendants",
40
+ style: [{
41
+ width,
42
+ height,
43
+ borderRadius: radius ?? t.radius.sm,
44
+ backgroundColor: t.colors.muted,
45
+ opacity
46
+ }, style]
47
+ });
48
+ }
49
+ //# sourceMappingURL=skeleton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["useEffect","useRef","Animated","useNativeDriver","useReducedMotion","useTheme","jsx","_jsx","Skeleton","width","height","radius","style","t","reduced","opacity","Value","current","setValue","half","motion","duration","loop","sequence","timing","toValue","start","stop","View","accessible","importantForAccessibility","borderRadius","sm","backgroundColor","colors","muted"],"sourceRoot":"../../../../src","sources":["components/skeleton/skeleton.tsx"],"mappings":";;AAAA,SAASA,SAAS,EAAEC,MAAM,QAAQ,OAAO;AACzC,SACEC,QAAQ,QAIH,cAAc;AACrB,SAASC,eAAe,QAAQ,2BAAwB;AACxD,SAASC,gBAAgB,QAAQ,sCAAmC;AACpE,SAASC,QAAQ,QAAQ,+BAA4B;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAYtD;AACA,OAAO,SAASC,QAAQA,CAAC;EACvBC,KAAK,GAAG,MAAM;EACdC,MAAM,GAAG,EAAE;EACXC,MAAM;EACNC;AACa,CAAC,EAAE;EAChB,MAAMC,CAAC,GAAGR,QAAQ,CAAC,CAAC;EACpB,MAAMS,OAAO,GAAGV,gBAAgB,CAAC,CAAC;EAClC,MAAMW,OAAO,GAAGd,MAAM,CAAC,IAAIC,QAAQ,CAACc,KAAK,CAAC,CAAC,CAAC,CAAC,CAACC,OAAO;EAErDjB,SAAS,CAAC,MAAM;IACd,IAAIc,OAAO,EAAE;MACXC,OAAO,CAACG,QAAQ,CAAC,GAAG,CAAC;MACrB;IACF;IACA,MAAMC,IAAI,GAAGN,CAAC,CAACO,MAAM,CAACC,QAAQ,GAAG,CAAC;IAClC,MAAMC,IAAI,GAAGpB,QAAQ,CAACoB,IAAI,CACxBpB,QAAQ,CAACqB,QAAQ,CAAC,CAChBrB,QAAQ,CAACsB,MAAM,CAACT,OAAO,EAAE;MACvBU,OAAO,EAAE,GAAG;MACZJ,QAAQ,EAAEF,IAAI;MACdhB;IACF,CAAC,CAAC,EACFD,QAAQ,CAACsB,MAAM,CAACT,OAAO,EAAE;MACvBU,OAAO,EAAE,CAAC;MACVJ,QAAQ,EAAEF,IAAI;MACdhB;IACF,CAAC,CAAC,CACH,CACH,CAAC;IACDmB,IAAI,CAACI,KAAK,CAAC,CAAC;IACZ,OAAO,MAAMJ,IAAI,CAACK,IAAI,CAAC,CAAC;EAC1B,CAAC,EAAE,CAACZ,OAAO,EAAED,OAAO,EAAED,CAAC,CAACO,MAAM,CAACC,QAAQ,CAAC,CAAC;EAEzC,oBACEd,IAAA,CAACL,QAAQ,CAAC0B,IAAI;IACZC,UAAU,EAAE,KAAM;IAClBC,yBAAyB,EAAC,qBAAqB;IAC/ClB,KAAK,EAAE,CACL;MACEH,KAAK;MACLC,MAAM;MACNqB,YAAY,EAAEpB,MAAM,IAAIE,CAAC,CAACF,MAAM,CAACqB,EAAE;MACnCC,eAAe,EAAEpB,CAAC,CAACqB,MAAM,CAACC,KAAK;MAC/BpB;IACF,CAAC,EACDH,KAAK;EACL,CACH,CAAC;AAEN","ignoreList":[]}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export { StatusBadge } from "./status-badge.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["StatusBadge"],"sourceRoot":"../../../../src","sources":["components/status-badge/index.ts"],"mappings":";;AAAA,SACEA,WAAW,QAGN,mBAAgB","ignoreList":[]}
@@ -0,0 +1,48 @@
1
+ "use strict";
2
+
3
+ import { Text, View } from 'react-native';
4
+ import { useTheme } from "../../theme/theme-provider.js";
5
+ import { makeStyles } from "../../utils/styles.js";
6
+ import { jsx as _jsx } from "react/jsx-runtime";
7
+ const useStyles = makeStyles(t => ({
8
+ base: {
9
+ alignSelf: 'flex-start',
10
+ paddingHorizontal: t.space[2],
11
+ paddingVertical: 2,
12
+ borderRadius: t.radius.full
13
+ },
14
+ label: {
15
+ ...t.typography.caption,
16
+ fontFamily: t.fontFamily,
17
+ fontWeight: '600'
18
+ }
19
+ }));
20
+ export function StatusBadge({
21
+ tone = 'neutral',
22
+ children,
23
+ style
24
+ }) {
25
+ const t = useTheme();
26
+ const s = useStyles();
27
+ const [bg, fg] = {
28
+ neutral: [t.colors.muted, t.colors.mutedForeground],
29
+ info: [t.colors.info, t.colors.infoForeground],
30
+ success: [t.colors.success, t.colors.successForeground],
31
+ warning: [t.colors.warning, t.colors.warningForeground],
32
+ destructive: [t.colors.destructive, t.colors.destructiveForeground]
33
+ }[tone];
34
+ return /*#__PURE__*/_jsx(View, {
35
+ style: [s.base, {
36
+ backgroundColor: bg
37
+ }, style],
38
+ children: /*#__PURE__*/_jsx(Text, {
39
+ numberOfLines: 1,
40
+ maxFontSizeMultiplier: t.maxFontScale,
41
+ style: [s.label, {
42
+ color: fg
43
+ }],
44
+ children: children
45
+ })
46
+ });
47
+ }
48
+ //# sourceMappingURL=status-badge.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Text","View","useTheme","makeStyles","jsx","_jsx","useStyles","t","base","alignSelf","paddingHorizontal","space","paddingVertical","borderRadius","radius","full","label","typography","caption","fontFamily","fontWeight","StatusBadge","tone","children","style","s","bg","fg","neutral","colors","muted","mutedForeground","info","infoForeground","success","successForeground","warning","warningForeground","destructive","destructiveForeground","backgroundColor","numberOfLines","maxFontSizeMultiplier","maxFontScale","color"],"sourceRoot":"../../../../src","sources":["components/status-badge/status-badge.tsx"],"mappings":";;AAAA,SAASA,IAAI,EAAEC,IAA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CAAC,CAACsB,MAAM,CAACU,qBAAqB;EACpE,CAAC,CAACjB,IAAI,CAAC;EACP,oBACEjB,IAAA,CAACJ,IAAI;IAACuB,KAAK,EAAE,CAACC,CAAC,CAACjB,IAAI,EAAE;MAAEgC,eAAe,EAAEd;IAAG,CAAC,EAAEF,KAAK,CAAE;IAAAD,QAAA,eACpDlB,IAAA,CAACL,IAAI;MACHyC,aAAa,EAAE,CAAE;MACjBC,qBAAqB,EAAEnC,CAAC,CAACoC,YAAa;MACtCnB,KAAK,EAAE,CAACC,CAAC,CAACT,KAAK,EAAE;QAAE4B,KAAK,EAAEjB;MAAG,CAAC,CAAE;MAAAJ,QAAA,EAE/BA;IAAQ,CACL;EAAC,CACH,CAAC;AAEX","ignoreList":[]}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export { Switch } from "./switch.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Switch"],"sourceRoot":"../../../../src","sources":["components/switch/index.ts"],"mappings":";;AAAA,SAASA,MAAM,QAA0B,aAAU","ignoreList":[]}
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+
3
+ import { Switch as RNSwitch } from 'react-native';
4
+ import { useTheme } from "../../theme/theme-provider.js";
5
+ import { jsx as _jsx } from "react/jsx-runtime";
6
+ export function Switch({
7
+ disabled,
8
+ style,
9
+ ...rest
10
+ }) {
11
+ const t = useTheme();
12
+ return /*#__PURE__*/_jsx(RNSwitch, {
13
+ trackColor: {
14
+ false: t.colors.border,
15
+ true: t.colors.primary
16
+ },
17
+ thumbColor: t.colors.background,
18
+ ios_backgroundColor: t.colors.border,
19
+ ...rest,
20
+ disabled: disabled,
21
+ style: [disabled && {
22
+ opacity: t.opacity.disabled
23
+ }, style]
24
+ });
25
+ }
26
+ //# sourceMappingURL=switch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Switch","RNSwitch","useTheme","jsx","_jsx","disabled","style","rest","t","trackColor","false","colors","border","true","primary","thumbColor","background","ios_backgroundColor","opacity"],"sourceRoot":"../../../../src","sources":["components/switch/switch.tsx"],"mappings":";;AACA,SACEA,MAAM,IAAIC,QAAQ,QAEb,cAAc;AACrB,SAASC,QAAQ,QAAQ,+BAA4B;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAQtD,OAAO,SAASJ,MAAMA,CAAC;EAAEK,QAAQ;EAAEC,KAAK;EAAE,GAAGC;AAAkB,CAAC,EAAE;EAChE,MAAMC,CAAC,GAAGN,QAAQ,CAAC,CAAC;EACpB,oBACEE,IAAA,CAACH,QAAQ;IACPQ,UAAU,EAAE;MAAEC,KAAK,EAAEF,CAAC,CAACG,MAAM,CAACC,MAAM;MAAEC,IAAI,EAAEL,CAAC,CAACG,MAAM,CAACG;IAAQ,CAAE;IAC/DC,UAAU,EAAEP,CAAC,CAACG,MAAM,CAACK,UAAW;IAChCC,mBAAmB,EAAET,CAAC,CAACG,MAAM,CAACC,MAAO;IAAA,GACjCL,IAAI;IACRF,QAAQ,EAAEA,QAAS;IACnBC,KAAK,EAAE,CAACD,QAAQ,IAAI;MAAEa,OAAO,EAAEV,CAAC,CAACU,OAAO,CAACb;IAAS,CAAC,EAAEC,KAAK;EAAE,CAC7D,CAAC;AAEN","ignoreList":[]}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export { Text } from "./text.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Text"],"sourceRoot":"../../../../src","sources":["components/text/index.ts"],"mappings":";;AAAA,SAASA,IAAI,QAAwD,WAAQ","ignoreList":[]}
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+
3
+ import { Text as RNText } from 'react-native';
4
+ import { useTheme } from "../../theme/theme-provider.js";
5
+ import { makeStyles } from "../../utils/styles.js";
6
+ import { jsx as _jsx } from "react/jsx-runtime";
7
+ const useStyles = makeStyles(t => ({
8
+ caption: t.typography.caption,
9
+ body: t.typography.body,
10
+ bodyLg: t.typography.bodyLg,
11
+ title: t.typography.title,
12
+ display: t.typography.display,
13
+ default: {
14
+ color: t.colors.foreground
15
+ },
16
+ muted: {
17
+ color: t.colors.mutedForeground
18
+ },
19
+ destructive: {
20
+ color: t.colors.destructive
21
+ },
22
+ success: {
23
+ color: t.colors.success
24
+ },
25
+ font: {
26
+ fontFamily: t.fontFamily
27
+ },
28
+ regular: {
29
+ fontWeight: '400'
30
+ },
31
+ medium: {
32
+ fontWeight: '500'
33
+ },
34
+ semibold: {
35
+ fontWeight: '600'
36
+ },
37
+ bold: {
38
+ fontWeight: '700'
39
+ }
40
+ }));
41
+ export function Text({
42
+ variant = 'body',
43
+ tone = 'default',
44
+ weight,
45
+ style,
46
+ ...rest
47
+ }) {
48
+ const t = useTheme();
49
+ const s = useStyles();
50
+ return /*#__PURE__*/_jsx(RNText, {
51
+ maxFontSizeMultiplier: t.maxFontScale,
52
+ ...rest,
53
+ style: [s.font, s[variant], s[tone], weight && s[weight], style]
54
+ });
55
+ }
56
+ //# sourceMappingURL=text.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Text","RNText","useTheme","makeStyles","jsx","_jsx","useStyles","t","caption","typography","body","bodyLg","title","display","default","color","colors","foreground","muted","mutedForeground","destructive","success","font","fontFamily","regular","fontWeight","medium","semibold","bold","variant","tone","weight","style","rest","s","maxFontSizeMultiplier","maxFontScale"],"sourceRoot":"../../../../src","sources":["components/text/text.tsx"],"mappings":";;AACA,SAASA,IAAI,IAAIC,MAAM,QAAuC,cAAc;AAE5E,SAASC,QAAQ,QAAQ,+BAA4B;AACrD,SAASC,UAAU,QAAQ,uBAAoB;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAgBhD,MAAMC,SAAS,GAAGH,UAAU,CAAEI,CAAC,KAAM;EACnCC,OAAO,EAAED,CAAC,CAACE,UAAU,CAACD,OAAO;EAC7BE,IAAI,EAAEH,CAAC,CAACE,UAAU,CAACC,IAAI;EACvBC,MAAM,EAAEJ,CAAC,CAACE,UAAU,CAACE,M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@ -0,0 +1,4 @@
1
+ "use strict";
2
+
3
+ export { ToastHost, ToastProvider, useToast } from "./toast.js";
4
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["ToastHost","ToastProvider","useToast"],"sourceRoot":"../../../../src","sources":["components/toast/index.ts"],"mappings":";;AAAA,SACEA,SAAS,EACTC,aAAa,EACbC,QAAQ,QAKH,YAAS","ignoreList":[]}
@@ -0,0 +1,203 @@
1
+ "use strict";
2
+
3
+ import { createContext, useContext, useEffect, useId, useRef, useState, useSyncExternalStore } from 'react';
4
+ import { AccessibilityInfo, Animated, Platform, Text, View } from 'react-native';
5
+ import { useNativeDriver } from "../../internal/overlay.js";
6
+ import { PressableBase } from "../../internal/pressable-base.js";
7
+ import { useReducedMotion } from "../../internal/use-reduced-motion.js";
8
+ import { useTheme } from "../../theme/theme-provider.js";
9
+ import { makeStyles } from "../../utils/styles.js";
10
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
11
+ /** Provider 하나가 가진 상태. show를 불러도 Provider 아래 화면은 다시 렌더링되지 않는다. */
12
+ function createToastStore() {
13
+ let current = null;
14
+ let timer;
15
+ let seq = 0;
16
+ let hosts = [];
17
+ const listeners = new Set();
18
+ const emit = () => listeners.forEach(l => l());
19
+ const hide = () => {
20
+ clearTimeout(timer);
21
+ current = null;
22
+ emit();
23
+ };
24
+ return {
25
+ bottomInset: 0,
26
+ subscribe(listener) {
27
+ listeners.add(listener);
28
+ return () => {
29
+ listeners.delete(listener);
30
+ };
31
+ },
32
+ getCurrent: () => current,
33
+ /** 가장 나중에 붙은 host(가장 위의 Modal)만 그린다 */
34
+ getTopHost: () => hosts[hosts.length - 1],
35
+ addHost(id) {
36
+ hosts = [...hosts, id];
37
+ emit();
38
+ return () => {
39
+ hosts = hosts.filter(h => h !== id);
40
+ emit();
41
+ };
42
+ },
43
+ show({
44
+ message,
45
+ tone = 'neutral',
46
+ duration,
47
+ action
48
+ }) {
49
+ clearTimeout(timer);
50
+ current = {
51
+ id: ++seq,
52
+ message,
53
+ tone,
54
+ action
55
+ };
56
+ timer = setTimeout(hide, duration ?? (action ? 4000 : 2500));
57
+ emit();
58
+ if (Platform.OS === 'ios') AccessibilityInfo.announceForAccessibility(message);
59
+ },
60
+ hide
61
+ };
62
+ }
63
+ const StoreContext = /*#__PURE__*/createContext(null);
64
+ export function ToastProvider({
65
+ bottomInset = 0,
66
+ children
67
+ }) {
68
+ const [store] = useState(createToastStore);
69
+ store.bottomInset = bottomInset;
70
+ useEffect(() => () => store.hide(), [store]);
71
+ return /*#__PURE__*/_jsxs(StoreContext.Provider, {
72
+ value: store,
73
+ children: [children, /*#__PURE__*/_jsx(ToastHost, {})]
74
+ });
75
+ }
76
+ export function useToast() {
77
+ const store = useContext(StoreContext);
78
+ if (!store) throw new Error('useToast must be used inside <ToastProvider>.');
79
+ return store;
80
+ }
81
+ const useStyles = makeStyles(t => ({
82
+ layer: {
83
+ position: 'absolute',
84
+ left: t.space[4],
85
+ right: t.space[4],
86
+ alignItems: 'center'
87
+ },
88
+ toast: {
89
+ flexDirection: 'row',
90
+ alignItems: 'center',
91
+ maxWidth: 480,
92
+ minHeight: 48,
93
+ paddingHorizontal: t.space[4],
94
+ paddingVertical: t.space[3],
95
+ borderRadius: t.radius.md,
96
+ boxShadow: t.shadow.md
97
+ },
98
+ withAction: {
99
+ alignSelf: 'stretch',
100
+ paddingVertical: 0,
101
+ paddingRight: t.space[2]
102
+ },
103
+ message: {
104
+ ...t.typography.body,
105
+ flexShrink: 1,
106
+ fontFamily: t.fontFamily
107
+ },
108
+ messageFill: {
109
+ flex: 1,
110
+ fontSize: 14
111
+ },
112
+ action: {
113
+ paddingHorizontal: t.space[3],
114
+ justifyContent: 'center'
115
+ },
116
+ actionLabel: {
117
+ fontFamily: t.fontFamily,
118
+ fontSize: 14,
119
+ lineHeight: 20,
120
+ fontWeight: '700'
121
+ }
122
+ }));
123
+
124
+ /**
125
+ * Toast를 그리는 자리. Provider가 하나 두고, Modal을 쓰는 컴포넌트(Sheet · Dialog)가
126
+ * Modal 안에 하나씩 더 둔다. 가장 위의 host만 그린다.
127
+ */
128
+ export function ToastHost() {
129
+ const store = useContext(StoreContext);
130
+ return store ? /*#__PURE__*/_jsx(ToastHostInner, {
131
+ store: store
132
+ }) : null;
133
+ }
134
+ function ToastHostInner({
135
+ store
136
+ }) {
137
+ const t = useTheme();
138
+ const s = useStyles();
139
+ const id = useId();
140
+ const reduced = useReducedMotion();
141
+ const opacity = useRef(new Animated.Value(0)).current;
142
+ const current = useSyncExternalStore(store.subscribe, store.getCurrent);
143
+ const isTop = useSyncExternalStore(store.subscribe, () => store.getTopHost() === id);
144
+ useEffect(() => store.addHost(id), [store, id]);
145
+ useEffect(() => {
146
+ if (!current) return;
147
+ opacity.setValue(reduced ? 1 : 0);
148
+ if (reduced) return;
149
+ const animation = Animated.timing(opacity, {
150
+ toValue: 1,
151
+ duration: t.motion.duration,
152
+ useNativeDriver
153
+ });
154
+ animation.start();
155
+ return () => animation.stop();
156
+ }, [current, opacity, reduced, t.motion.duration]);
157
+ if (!current || !isTop) return null;
158
+ const [bg, fg] = {
159
+ neutral: [t.colors.foreground, t.colors.background],
160
+ success: [t.colors.success, t.colors.successForeground],
161
+ destructive: [t.colors.destructive, t.colors.destructiveForeground]
162
+ }[current.tone];
163
+ // 어두운 바탕(light) 위에서는 밝은 파랑, 밝은 바탕(dark) 위에서는 진한 파랑
164
+ const actionColor = current.tone !== 'neutral' ? fg : t.scheme === 'light' ? '#93c5fd' : '#1d4ed8';
165
+ return /*#__PURE__*/_jsx(View, {
166
+ pointerEvents: "box-none",
167
+ style: [s.layer, {
168
+ bottom: t.space[4] + store.bottomInset
169
+ }],
170
+ children: /*#__PURE__*/_jsxs(Animated.View, {
171
+ accessibilityRole: "alert",
172
+ accessibilityLiveRegion: "polite",
173
+ style: [s.toast, !!current.action && s.withAction, {
174
+ backgroundColor: bg,
175
+ opacity
176
+ }],
177
+ children: [/*#__PURE__*/_jsx(Text, {
178
+ maxFontSizeMultiplier: t.maxFontScale,
179
+ style: [s.message, !!current.action && s.messageFill, {
180
+ color: fg
181
+ }],
182
+ children: current.message
183
+ }), current.action ? /*#__PURE__*/_jsx(PressableBase, {
184
+ accessibilityRole: "button",
185
+ accessibilityLabel: current.action.label,
186
+ touchHeight: 44,
187
+ style: s.action,
188
+ onPress: () => {
189
+ current.action?.onPress();
190
+ store.hide();
191
+ },
192
+ children: /*#__PURE__*/_jsx(Text, {
193
+ maxFontSizeMultiplier: t.maxFontScale,
194
+ style: [s.actionLabel, {
195
+ color: actionColor
196
+ }],
197
+ children: current.action.label
198
+ })
199
+ }) : null]
200
+ })
201
+ });
202
+ }
203
+ //# sourceMappingURL=toast.js.map