asta-ui 0.9.2 → 0.9.4

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 (448) hide show
  1. package/css/asta.css +2 -2
  2. package/css/asta.js +248 -1
  3. package/css/components.css +722 -44
  4. package/css/runtime/core.css +5 -5
  5. package/css/runtime/data.css +2 -2
  6. package/css/runtime/modules.css +49 -0
  7. package/css/runtime/modules.js +245 -0
  8. package/css/runtime/overlays.css +22 -9
  9. package/css/src/blocks.css +3 -3
  10. package/css/src/core.css +8 -8
  11. package/css/src/data.css +3 -3
  12. package/css/src/display.css +6 -5
  13. package/css/src/forms.css +6 -6
  14. package/css/src/modules.css +616 -0
  15. package/css/src/overlays.css +3 -3
  16. package/css/tokens.css +6 -2
  17. package/dist/ai-chat.js +1 -1
  18. package/dist/avatar-group.js +2 -2
  19. package/dist/avatar.js +1 -1
  20. package/dist/base/ai-chat.js +1 -1
  21. package/dist/base/avatar-group.js +2 -2
  22. package/dist/base/avatar.js +1 -1
  23. package/dist/base/billing.d.ts +2 -0
  24. package/dist/base/billing.js +11 -0
  25. package/dist/base/bubble-wrap.js +1 -1
  26. package/dist/base/candlestick.js +1 -1
  27. package/dist/base/card-checkout.js +1 -1
  28. package/dist/base/chart-card.d.ts +2 -0
  29. package/dist/base/chart-card.js +11 -0
  30. package/dist/base/chat-thread.js +1 -1
  31. package/dist/base/checkbox.js +1 -1
  32. package/dist/base/checkout.js +3 -3
  33. package/dist/base/color-picker.js +1 -1
  34. package/dist/base/combo-lock.js +1 -1
  35. package/dist/base/combobox-aui-046.js +1 -1
  36. package/dist/base/combobox-aui-047.js +1 -1
  37. package/dist/base/combobox.js +1 -1
  38. package/dist/base/command-palette.js +1 -1
  39. package/dist/base/comments.js +2 -2
  40. package/dist/base/context-menu.js +1 -1
  41. package/dist/base/cookie-consent.d.ts +2 -0
  42. package/dist/base/cookie-consent.js +13 -0
  43. package/dist/base/countdown.d.ts +2 -0
  44. package/dist/base/countdown.js +9 -0
  45. package/dist/base/data-table.js +1 -1
  46. package/dist/base/dialog.js +1 -1
  47. package/dist/base/dropdown-menu.js +1 -1
  48. package/dist/base/field.js +1 -1
  49. package/dist/base/file-manager.d.ts +2 -0
  50. package/dist/base/file-manager.js +19 -0
  51. package/dist/base/flash-sale.d.ts +2 -0
  52. package/dist/base/flash-sale.js +7 -0
  53. package/dist/base/footer-aui-027.js +1 -1
  54. package/dist/base/footer-aui-028.js +1 -1
  55. package/dist/base/footer.js +1 -1
  56. package/dist/base/hover-card.js +1 -1
  57. package/dist/base/inbox.d.ts +2 -0
  58. package/dist/base/inbox.js +11 -0
  59. package/dist/base/inline-edit.js +1 -1
  60. package/dist/base/input-aui-029.js +1 -1
  61. package/dist/base/input-aui-030.js +1 -1
  62. package/dist/base/input-aui-031.js +1 -1
  63. package/dist/base/input-aui-032.js +1 -1
  64. package/dist/base/input-aui-033.js +1 -1
  65. package/dist/base/input-aui-034.js +1 -1
  66. package/dist/base/input.js +1 -1
  67. package/dist/base/invoice.d.ts +2 -0
  68. package/dist/base/invoice.js +10 -0
  69. package/dist/base/kanban.js +2 -2
  70. package/dist/base/menubar.d.ts +2 -0
  71. package/dist/base/menubar.js +9 -0
  72. package/dist/base/meter.d.ts +2 -0
  73. package/dist/base/meter.js +9 -0
  74. package/dist/base/morse-tap.js +1 -1
  75. package/dist/base/navbar-aui-009.js +1 -1
  76. package/dist/base/navbar-aui-011.js +1 -1
  77. package/dist/base/navbar-aui-012.js +1 -1
  78. package/dist/base/navbar-aui-013.js +1 -1
  79. package/dist/base/navbar.js +1 -1
  80. package/dist/base/notification-center.js +3 -3
  81. package/dist/base/number-input.js +1 -1
  82. package/dist/base/order-book.js +1 -1
  83. package/dist/base/otp-input-aui-041.js +1 -1
  84. package/dist/base/otp-input-aui-042.js +1 -1
  85. package/dist/base/otp-input.js +1 -1
  86. package/dist/base/password-input-aui-039.js +1 -1
  87. package/dist/base/password-input-aui-040.js +1 -1
  88. package/dist/base/password-input.js +1 -1
  89. package/dist/base/payment-received.js +1 -1
  90. package/dist/base/phone-input.d.ts +2 -0
  91. package/dist/base/phone-input.js +13 -0
  92. package/dist/base/popover.js +1 -1
  93. package/dist/base/price-alert.d.ts +2 -0
  94. package/dist/base/price-alert.js +7 -0
  95. package/dist/base/price-chart.js +1 -1
  96. package/dist/base/properties-panel.js +1 -1
  97. package/dist/base/radio-group.js +1 -1
  98. package/dist/base/select-aui-045.js +1 -1
  99. package/dist/base/select.js +1 -1
  100. package/dist/base/settings-panel.js +1 -1
  101. package/dist/base/shipment-tracker.js +1 -1
  102. package/dist/base/sidebar.js +2 -2
  103. package/dist/base/sign-in-aui-015.js +1 -1
  104. package/dist/base/sign-in-aui-016.js +1 -1
  105. package/dist/base/sign-in-aui-017.js +1 -1
  106. package/dist/base/sign-in-aui-018.js +1 -1
  107. package/dist/base/sign-in-aui-019.js +1 -1
  108. package/dist/base/sign-in-aui-020.js +1 -1
  109. package/dist/base/sign-in.js +1 -1
  110. package/dist/base/snap-grid.js +1 -1
  111. package/dist/base/sortable-list.d.ts +2 -0
  112. package/dist/base/sortable-list.js +9 -0
  113. package/dist/base/split-bill.d.ts +2 -0
  114. package/dist/base/split-bill.js +7 -0
  115. package/dist/base/stat-card.js +1 -1
  116. package/dist/base/tag-input-aui-048.js +1 -1
  117. package/dist/base/tag-input-aui-049.js +1 -1
  118. package/dist/base/tag-input.js +1 -1
  119. package/dist/base/team-members.js +3 -3
  120. package/dist/base/testimonials.d.ts +2 -0
  121. package/dist/base/testimonials.js +10 -0
  122. package/dist/base/textarea-aui-001.js +1 -1
  123. package/dist/base/textarea-aui-002.js +1 -1
  124. package/dist/base/textarea-aui-003.js +1 -1
  125. package/dist/base/textarea-aui-004.js +1 -1
  126. package/dist/base/textarea-aui-005.js +1 -1
  127. package/dist/base/textarea-aui-006.js +1 -1
  128. package/dist/base/textarea-aui-007.js +1 -1
  129. package/dist/base/textarea-aui-008.js +1 -1
  130. package/dist/base/textarea-aui-035.js +1 -1
  131. package/dist/base/textarea-aui-036.js +1 -1
  132. package/dist/base/textarea-aui-037.js +1 -1
  133. package/dist/base/textarea-aui-038.js +1 -1
  134. package/dist/base/textarea.js +1 -1
  135. package/dist/base/token-swap.js +1 -1
  136. package/dist/base/tooltip.js +1 -1
  137. package/dist/base/trade-ticket.js +1 -1
  138. package/dist/base/watchlist.d.ts +2 -0
  139. package/dist/base/watchlist.js +7 -0
  140. package/dist/base.js +166 -90
  141. package/dist/billing.d.ts +2 -0
  142. package/dist/billing.js +11 -0
  143. package/dist/bubble-wrap.js +1 -1
  144. package/dist/candlestick.js +1 -1
  145. package/dist/card-checkout.js +1 -1
  146. package/dist/chart-card.d.ts +2 -0
  147. package/dist/chart-card.js +11 -0
  148. package/dist/chat-thread.js +1 -1
  149. package/dist/checkbox.js +1 -1
  150. package/dist/checkout.js +3 -3
  151. package/dist/{chunk-7TK42PS3.js → chunk-25RCKHWV.js} +19 -4
  152. package/dist/{chunk-4L4EKC46.js → chunk-2EBWWZPS.js} +1 -1
  153. package/dist/chunk-2F5CE6ZB.js +269 -0
  154. package/dist/{chunk-SATIWCJQ.js → chunk-2LM3VHNO.js} +3 -2
  155. package/dist/{chunk-5VQV2I7C.js → chunk-2PPF4GK5.js} +9 -6
  156. package/dist/{chunk-ZRGPSYW6.js → chunk-2PQIPQGO.js} +10 -6
  157. package/dist/{chunk-HB7DFNZP.js → chunk-3PQTSFOS.js} +1 -1
  158. package/dist/{chunk-VPZP6TCT.js → chunk-3UQIYJTI.js} +7 -3
  159. package/dist/{chunk-FY6BRODJ.js → chunk-3ZFF6VC5.js} +4 -2
  160. package/dist/{chunk-V3SPSN3A.js → chunk-45KDL3JM.js} +1 -1
  161. package/dist/{chunk-EVSTTLOT.js → chunk-4SLC3EK6.js} +18 -4
  162. package/dist/{chunk-VWYHP4SB.js → chunk-4WCMPLE3.js} +13 -4
  163. package/dist/chunk-5DLY6FGD.js +160 -0
  164. package/dist/{chunk-SRGDJSW7.js → chunk-5GGS6VP5.js} +1 -0
  165. package/dist/chunk-5N2G462S.js +338 -0
  166. package/dist/{chunk-FKHNK5VC.js → chunk-6C52ZQRB.js} +2 -1
  167. package/dist/{chunk-VVAL2JZJ.js → chunk-6MPEI6V5.js} +2 -2
  168. package/dist/{chunk-HNO6EUGJ.js → chunk-6RA7LJ3K.js} +7 -1
  169. package/dist/{chunk-RRHQBGRO.js → chunk-77RFV2MG.js} +7 -2
  170. package/dist/{chunk-RIWKIBEP.js → chunk-7MBTBYTJ.js} +3 -3
  171. package/dist/{chunk-XIU7K2YE.js → chunk-ADZI4ROA.js} +1 -1
  172. package/dist/{chunk-SAJ4D3Z2.js → chunk-AMVX4DDT.js} +7 -3
  173. package/dist/{chunk-7JNO265Q.js → chunk-B4XRAVHL.js} +33 -17
  174. package/dist/{chunk-MDI73RL6.js → chunk-B7MVYR7C.js} +7 -4
  175. package/dist/{chunk-OFPZUTBI.js → chunk-BEV2X4YL.js} +2 -1
  176. package/dist/chunk-BG2W2KVE.js +200 -0
  177. package/dist/chunk-BKHH2CJA.js +146 -0
  178. package/dist/{chunk-XRVVZA2Y.js → chunk-CACW5LH3.js} +1 -1
  179. package/dist/{chunk-I2WXKWTQ.js → chunk-CBJUY4WE.js} +10 -5
  180. package/dist/{chunk-746WX2DF.js → chunk-CSTI5CTF.js} +8 -2
  181. package/dist/{chunk-3KS5EN3Q.js → chunk-D2JJSUXI.js} +1 -1
  182. package/dist/chunk-D4AYULMF.js +338 -0
  183. package/dist/{chunk-4XM6DKEO.js → chunk-DD2TBHSJ.js} +2 -1
  184. package/dist/{chunk-B5OESWCR.js → chunk-DPLH3EGO.js} +1 -1
  185. package/dist/{chunk-5TSQZY34.js → chunk-DU3CZ3K7.js} +1 -1
  186. package/dist/{chunk-YON5SU2G.js → chunk-DWA62IYV.js} +5 -2
  187. package/dist/{chunk-FUNXYRSG.js → chunk-DWZT455C.js} +24 -9
  188. package/dist/{chunk-WSTQ6WZO.js → chunk-ECGJ6D5D.js} +3 -2
  189. package/dist/{chunk-3JNUC3FU.js → chunk-EN6XBXW5.js} +1 -1
  190. package/dist/{chunk-GJ3R6IZL.js → chunk-EOZDJA7Z.js} +1 -1
  191. package/dist/{chunk-KXWC2UHE.js → chunk-FBIGYEFN.js} +6 -3
  192. package/dist/{chunk-RS3XHHDE.js → chunk-FDE3S2YK.js} +1 -1
  193. package/dist/{chunk-DRX3KRNL.js → chunk-FFRJW5O7.js} +3 -2
  194. package/dist/{chunk-UEOEWP7L.js → chunk-FIPWA5KL.js} +3 -2
  195. package/dist/chunk-FLCT7THQ.js +75 -0
  196. package/dist/{chunk-RTAHGY6P.js → chunk-FOJRZASV.js} +7 -1
  197. package/dist/{chunk-CA7YQ5BJ.js → chunk-FQ4YUKAE.js} +3 -3
  198. package/dist/{chunk-33N6SZB5.js → chunk-FXXR3FM3.js} +6 -3
  199. package/dist/{chunk-BGVAXPHD.js → chunk-G7WTEBMX.js} +21 -6
  200. package/dist/{chunk-HPVPHWDM.js → chunk-IATF2OTU.js} +1 -1
  201. package/dist/{chunk-CLCP2GFW.js → chunk-IDXERBKL.js} +3 -3
  202. package/dist/{chunk-NB7X26PY.js → chunk-IF6CWIUB.js} +1 -1
  203. package/dist/{chunk-WVIV4JBH.js → chunk-ITGWD7ZY.js} +2 -2
  204. package/dist/{chunk-2LZM435Z.js → chunk-IVCHYE55.js} +7 -1
  205. package/dist/{chunk-BH2DLHFW.js → chunk-JE2MAZGR.js} +3 -2
  206. package/dist/{chunk-W57O4RLL.js → chunk-JF4BKHFK.js} +37 -9
  207. package/dist/{chunk-QDRBMWRX.js → chunk-JLCSRNI2.js} +7 -3
  208. package/dist/{chunk-7L4YE6HM.js → chunk-JNNMKFEQ.js} +1 -1
  209. package/dist/{chunk-GDTSCUHY.js → chunk-JRD6FENH.js} +1 -1
  210. package/dist/{chunk-F5I6EK7F.js → chunk-JSS4QASL.js} +1 -1
  211. package/dist/{chunk-B5F775GP.js → chunk-JWBGI7FN.js} +1 -1
  212. package/dist/{chunk-WTNNS7AX.js → chunk-JX7V6EFT.js} +36 -9
  213. package/dist/{chunk-7SNVRPED.js → chunk-KEMC4RIF.js} +2 -1
  214. package/dist/chunk-KVARQNGF.js +123 -0
  215. package/dist/chunk-LDTCIVDX.js +146 -0
  216. package/dist/{chunk-45VUWOHQ.js → chunk-LKRE4HLZ.js} +4 -2
  217. package/dist/{chunk-ZN3W5PAI.js → chunk-LOHFV5JF.js} +1 -1
  218. package/dist/chunk-LS6CFF6X.js +80 -0
  219. package/dist/{chunk-I5NZSWDW.js → chunk-MAKFUH34.js} +33 -17
  220. package/dist/{chunk-OQU6KGVR.js → chunk-MDB4RFMV.js} +1 -1
  221. package/dist/{chunk-FDHU3RWR.js → chunk-MJJU6OLM.js} +1 -1
  222. package/dist/{chunk-PIC5ZIR3.js → chunk-MPH64VG7.js} +1 -1
  223. package/dist/{chunk-AYSC7AIC.js → chunk-MVE7RJJ6.js} +1 -1
  224. package/dist/{chunk-2SQQFICY.js → chunk-N3X4T5OR.js} +25 -8
  225. package/dist/{chunk-CNY76NHF.js → chunk-NFJDL44V.js} +7 -3
  226. package/dist/{chunk-FJGGXXTT.js → chunk-NPVUFQGC.js} +1 -1
  227. package/dist/{chunk-QSLS3ENY.js → chunk-NVLYF4UL.js} +1 -1
  228. package/dist/chunk-O626XQW2.js +165 -0
  229. package/dist/chunk-OH5VAD27.js +224 -0
  230. package/dist/{chunk-TIAKMX7U.js → chunk-OIOZQP2H.js} +1 -1
  231. package/dist/{chunk-56BEMYK3.js → chunk-OU3EEX4Y.js} +1 -1
  232. package/dist/{chunk-6AZKJUL4.js → chunk-OUIOJROO.js} +1 -1
  233. package/dist/{chunk-OLNMOTAD.js → chunk-PAXDHYBX.js} +18 -4
  234. package/dist/chunk-PIE76JKF.js +224 -0
  235. package/dist/{chunk-6B6NTRMC.js → chunk-PIXHOFUT.js} +7 -2
  236. package/dist/{chunk-FATLQKRY.js → chunk-PZ2ZUHC3.js} +3 -3
  237. package/dist/chunk-Q5A5OTLI.js +192 -0
  238. package/dist/{chunk-TXRLBMFL.js → chunk-QASSYLQQ.js} +3 -2
  239. package/dist/{chunk-TCID6NNE.js → chunk-QJXVIEB5.js} +1 -1
  240. package/dist/{chunk-K5PWBSVO.js → chunk-QWOO4V7N.js} +2 -2
  241. package/dist/chunk-RGVRHFKY.js +213 -0
  242. package/dist/{chunk-J6GK2V2C.js → chunk-RQNXELUL.js} +2 -1
  243. package/dist/{chunk-KQCXQY5K.js → chunk-RXOVKEYG.js} +2 -1
  244. package/dist/{chunk-NICNFGHT.js → chunk-S2VTHA6G.js} +2 -2
  245. package/dist/chunk-SCQ6A4ZG.js +247 -0
  246. package/dist/{chunk-EVCUN45S.js → chunk-SMZVKQKM.js} +3 -2
  247. package/dist/{chunk-GERWW3CA.js → chunk-SR4NYQWO.js} +2 -2
  248. package/dist/{chunk-DQWKBQBT.js → chunk-TAAAYFBT.js} +2 -2
  249. package/dist/{chunk-S2DJLW6B.js → chunk-TBMUSER2.js} +1 -1
  250. package/dist/chunk-TMOEFAXQ.js +165 -0
  251. package/dist/chunk-TXC6CCSA.js +75 -0
  252. package/dist/chunk-UC55XR76.js +193 -0
  253. package/dist/{chunk-5U4H2CXC.js → chunk-UJYZZSII.js} +11 -4
  254. package/dist/chunk-UOOGRGEC.js +185 -0
  255. package/dist/{chunk-ZBF2UYXP.js → chunk-USDST2TI.js} +1 -1
  256. package/dist/{chunk-W7RITVDV.js → chunk-UX6CWJT7.js} +1 -1
  257. package/dist/{chunk-U7BYEW3Y.js → chunk-UZF7SCRT.js} +13 -5
  258. package/dist/{chunk-Q7OHWQP2.js → chunk-V7JUJQNR.js} +1 -0
  259. package/dist/{chunk-WWQV7LE7.js → chunk-VNUX5LOC.js} +24 -9
  260. package/dist/{chunk-CTO36MY2.js → chunk-VS3GQ4JR.js} +2 -2
  261. package/dist/{chunk-UMDVPRJW.js → chunk-VTTXURIB.js} +1 -1
  262. package/dist/{chunk-6NNHSXFD.js → chunk-W2S6JDBM.js} +1 -1
  263. package/dist/{chunk-3XMVXIOF.js → chunk-W5M3EHJL.js} +4 -2
  264. package/dist/chunk-X2VID7XY.js +228 -0
  265. package/dist/{chunk-H7D6G3GQ.js → chunk-X4JYOCFA.js} +7 -1
  266. package/dist/{chunk-6VQTFRSP.js → chunk-XKA3LTJZ.js} +37 -9
  267. package/dist/{chunk-7GKCX4IE.js → chunk-XUZH4Y52.js} +1 -1
  268. package/dist/{chunk-UAP47MSR.js → chunk-Y4JOW2UW.js} +11 -5
  269. package/dist/{chunk-T4SOPNM5.js → chunk-YCXZ3TYF.js} +1 -1
  270. package/dist/{chunk-2KJNBHUV.js → chunk-YF3XSH54.js} +2 -1
  271. package/dist/{chunk-66OZ7CBK.js → chunk-YJAZHJY3.js} +1 -1
  272. package/dist/{chunk-4WK3F76T.js → chunk-YLILJ2FH.js} +1 -1
  273. package/dist/{chunk-FGQPCDXI.js → chunk-YNPG4WOS.js} +1 -1
  274. package/dist/chunk-YPFZXGPT.js +160 -0
  275. package/dist/{chunk-KYFZ5TTK.js → chunk-YRPLUNP4.js} +3 -1
  276. package/dist/{chunk-P3USWDWR.js → chunk-YVGC7QT7.js} +4 -2
  277. package/dist/{chunk-4ZJEAWNG.js → chunk-Z2DF2YL5.js} +4 -2
  278. package/dist/{chunk-JAQANAOP.js → chunk-ZUH7XRX7.js} +19 -4
  279. package/dist/{chunk-UWQ26LYZ.js → chunk-ZYI6J34Q.js} +2 -2
  280. package/dist/{chunk-BOJCW7Z7.js → chunk-ZZ25XSK2.js} +3 -2
  281. package/dist/color-picker.js +1 -1
  282. package/dist/combo-lock.js +1 -1
  283. package/dist/combobox-aui-046.js +1 -1
  284. package/dist/combobox-aui-047.js +1 -1
  285. package/dist/combobox.js +1 -1
  286. package/dist/command-palette.js +1 -1
  287. package/dist/comments.js +2 -2
  288. package/dist/context-menu.js +1 -1
  289. package/dist/cookie-consent.d.ts +2 -0
  290. package/dist/cookie-consent.js +13 -0
  291. package/dist/countdown.d.ts +2 -0
  292. package/dist/countdown.js +9 -0
  293. package/dist/data-table.js +1 -1
  294. package/dist/dialog.js +1 -1
  295. package/dist/dropdown-menu.js +1 -1
  296. package/dist/field.js +1 -1
  297. package/dist/file-manager.d.ts +2 -0
  298. package/dist/file-manager.js +19 -0
  299. package/dist/flash-sale.d.ts +2 -0
  300. package/dist/flash-sale.js +7 -0
  301. package/dist/footer-aui-027.js +1 -1
  302. package/dist/footer-aui-028.js +1 -1
  303. package/dist/footer.js +1 -1
  304. package/dist/hover-card.js +1 -1
  305. package/dist/inbox.d.ts +2 -0
  306. package/dist/inbox.js +11 -0
  307. package/dist/index.js +166 -90
  308. package/dist/inline-edit.js +1 -1
  309. package/dist/input-aui-029.js +1 -1
  310. package/dist/input-aui-030.js +1 -1
  311. package/dist/input-aui-031.js +1 -1
  312. package/dist/input-aui-032.js +1 -1
  313. package/dist/input-aui-033.js +1 -1
  314. package/dist/input-aui-034.js +1 -1
  315. package/dist/input.js +1 -1
  316. package/dist/invoice.d.ts +2 -0
  317. package/dist/invoice.js +10 -0
  318. package/dist/kanban.js +2 -2
  319. package/dist/menubar.d.ts +2 -0
  320. package/dist/menubar.js +9 -0
  321. package/dist/meter.d.ts +2 -0
  322. package/dist/meter.js +9 -0
  323. package/dist/morse-tap.js +1 -1
  324. package/dist/navbar-aui-009.js +1 -1
  325. package/dist/navbar-aui-011.js +1 -1
  326. package/dist/navbar-aui-012.js +1 -1
  327. package/dist/navbar-aui-013.js +1 -1
  328. package/dist/navbar.js +1 -1
  329. package/dist/notification-center.js +3 -3
  330. package/dist/number-input.js +1 -1
  331. package/dist/order-book.js +1 -1
  332. package/dist/otp-input-aui-041.js +1 -1
  333. package/dist/otp-input-aui-042.js +1 -1
  334. package/dist/otp-input.js +1 -1
  335. package/dist/password-input-aui-039.js +1 -1
  336. package/dist/password-input-aui-040.js +1 -1
  337. package/dist/password-input.js +1 -1
  338. package/dist/payment-received.js +1 -1
  339. package/dist/phone-input.d.ts +2 -0
  340. package/dist/phone-input.js +13 -0
  341. package/dist/popover.js +1 -1
  342. package/dist/price-alert.d.ts +2 -0
  343. package/dist/price-alert.js +7 -0
  344. package/dist/price-chart.js +1 -1
  345. package/dist/properties-panel.js +1 -1
  346. package/dist/radio-group.js +1 -1
  347. package/dist/select-aui-045.js +1 -1
  348. package/dist/select.js +1 -1
  349. package/dist/settings-panel.js +1 -1
  350. package/dist/shipment-tracker.js +1 -1
  351. package/dist/sidebar.js +2 -2
  352. package/dist/sign-in-aui-015.js +1 -1
  353. package/dist/sign-in-aui-016.js +1 -1
  354. package/dist/sign-in-aui-017.js +1 -1
  355. package/dist/sign-in-aui-018.js +1 -1
  356. package/dist/sign-in-aui-019.js +1 -1
  357. package/dist/sign-in-aui-020.js +1 -1
  358. package/dist/sign-in.js +1 -1
  359. package/dist/snap-grid.js +1 -1
  360. package/dist/sortable-list.d.ts +2 -0
  361. package/dist/sortable-list.js +9 -0
  362. package/dist/split-bill.d.ts +2 -0
  363. package/dist/split-bill.js +7 -0
  364. package/dist/stat-card.js +1 -1
  365. package/dist/styles.css +2 -2
  366. package/dist/tag-input-aui-048.js +1 -1
  367. package/dist/tag-input-aui-049.js +1 -1
  368. package/dist/tag-input.js +1 -1
  369. package/dist/team-members.js +3 -3
  370. package/dist/testimonials.d.ts +2 -0
  371. package/dist/testimonials.js +10 -0
  372. package/dist/textarea-aui-001.js +1 -1
  373. package/dist/textarea-aui-002.js +1 -1
  374. package/dist/textarea-aui-003.js +1 -1
  375. package/dist/textarea-aui-004.js +1 -1
  376. package/dist/textarea-aui-005.js +1 -1
  377. package/dist/textarea-aui-006.js +1 -1
  378. package/dist/textarea-aui-007.js +1 -1
  379. package/dist/textarea-aui-008.js +1 -1
  380. package/dist/textarea-aui-035.js +1 -1
  381. package/dist/textarea-aui-036.js +1 -1
  382. package/dist/textarea-aui-037.js +1 -1
  383. package/dist/textarea-aui-038.js +1 -1
  384. package/dist/textarea.js +1 -1
  385. package/dist/token-swap.js +1 -1
  386. package/dist/tooltip.js +1 -1
  387. package/dist/trade-ticket.js +1 -1
  388. package/dist/types/components/kit/base/billing.d.ts +53 -0
  389. package/dist/types/components/kit/base/cookie-consent.d.ts +37 -0
  390. package/dist/types/components/kit/base/file-manager.d.ts +41 -0
  391. package/dist/types/components/kit/base/inbox.d.ts +33 -0
  392. package/dist/types/components/kit/base/invoice.d.ts +45 -0
  393. package/dist/types/components/kit/base/testimonials.d.ts +25 -0
  394. package/dist/types/components/kit/billing.d.ts +53 -0
  395. package/dist/types/components/kit/chart-card.d.ts +43 -0
  396. package/dist/types/components/kit/cookie-consent.d.ts +37 -0
  397. package/dist/types/components/kit/countdown.d.ts +21 -0
  398. package/dist/types/components/kit/file-manager.d.ts +41 -0
  399. package/dist/types/components/kit/inbox.d.ts +33 -0
  400. package/dist/types/components/kit/invoice.d.ts +45 -0
  401. package/dist/types/components/kit/menubar.d.ts +41 -0
  402. package/dist/types/components/kit/meter.d.ts +32 -0
  403. package/dist/types/components/kit/number-input.d.ts +3 -1
  404. package/dist/types/components/kit/phone-input.d.ts +42 -0
  405. package/dist/types/components/kit/sortable-list.d.ts +25 -0
  406. package/dist/types/components/kit/tag-input.d.ts +3 -1
  407. package/dist/types/components/kit/testimonials.d.ts +25 -0
  408. package/dist/types/components/lab/blocks/FlashSale.d.ts +2 -0
  409. package/dist/types/components/lab/blocks/PriceAlert.d.ts +2 -0
  410. package/dist/types/components/lab/blocks/SplitBill.d.ts +2 -0
  411. package/dist/types/components/lab/blocks/Watchlist.d.ts +2 -0
  412. package/dist/types/packages/asta-ui/src/base/billing.d.ts +2 -0
  413. package/dist/types/packages/asta-ui/src/base/chart-card.d.ts +2 -0
  414. package/dist/types/packages/asta-ui/src/base/cookie-consent.d.ts +2 -0
  415. package/dist/types/packages/asta-ui/src/base/countdown.d.ts +2 -0
  416. package/dist/types/packages/asta-ui/src/base/file-manager.d.ts +2 -0
  417. package/dist/types/packages/asta-ui/src/base/flash-sale.d.ts +2 -0
  418. package/dist/types/packages/asta-ui/src/base/inbox.d.ts +2 -0
  419. package/dist/types/packages/asta-ui/src/base/invoice.d.ts +2 -0
  420. package/dist/types/packages/asta-ui/src/base/menubar.d.ts +2 -0
  421. package/dist/types/packages/asta-ui/src/base/meter.d.ts +2 -0
  422. package/dist/types/packages/asta-ui/src/base/phone-input.d.ts +2 -0
  423. package/dist/types/packages/asta-ui/src/base/price-alert.d.ts +2 -0
  424. package/dist/types/packages/asta-ui/src/base/sortable-list.d.ts +2 -0
  425. package/dist/types/packages/asta-ui/src/base/split-bill.d.ts +2 -0
  426. package/dist/types/packages/asta-ui/src/base/testimonials.d.ts +2 -0
  427. package/dist/types/packages/asta-ui/src/base/watchlist.d.ts +2 -0
  428. package/dist/types/packages/asta-ui/src/base.d.ts +29 -1
  429. package/dist/types/packages/asta-ui/src/billing.d.ts +2 -0
  430. package/dist/types/packages/asta-ui/src/chart-card.d.ts +2 -0
  431. package/dist/types/packages/asta-ui/src/cookie-consent.d.ts +2 -0
  432. package/dist/types/packages/asta-ui/src/countdown.d.ts +2 -0
  433. package/dist/types/packages/asta-ui/src/file-manager.d.ts +2 -0
  434. package/dist/types/packages/asta-ui/src/flash-sale.d.ts +2 -0
  435. package/dist/types/packages/asta-ui/src/inbox.d.ts +2 -0
  436. package/dist/types/packages/asta-ui/src/index.d.ts +29 -1
  437. package/dist/types/packages/asta-ui/src/invoice.d.ts +2 -0
  438. package/dist/types/packages/asta-ui/src/menubar.d.ts +2 -0
  439. package/dist/types/packages/asta-ui/src/meter.d.ts +2 -0
  440. package/dist/types/packages/asta-ui/src/phone-input.d.ts +2 -0
  441. package/dist/types/packages/asta-ui/src/price-alert.d.ts +2 -0
  442. package/dist/types/packages/asta-ui/src/sortable-list.d.ts +2 -0
  443. package/dist/types/packages/asta-ui/src/split-bill.d.ts +2 -0
  444. package/dist/types/packages/asta-ui/src/testimonials.d.ts +2 -0
  445. package/dist/types/packages/asta-ui/src/watchlist.d.ts +2 -0
  446. package/dist/watchlist.d.ts +2 -0
  447. package/dist/watchlist.js +7 -0
  448. package/package.json +1 -1
@@ -0,0 +1,80 @@
1
+ "use client";
2
+
3
+ // components/kit/meter.tsx
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
+ var cx = (...c) => c.filter(Boolean).join(" ");
6
+ var KEYFRAMES = `@keyframes asta-meter-in { from { transform: scaleX(0) } }
7
+ @keyframes asta-meter-fade { from { opacity: 0; transform: translateY(2px) } }
8
+ @media (prefers-reduced-motion: reduce) { .asta-meter-a { animation: none !important; transition: none !important } }`;
9
+ var FILLS = [
10
+ "var(--brand)",
11
+ "color-mix(in srgb, var(--brand) 55%, var(--paper))",
12
+ "color-mix(in srgb, var(--ink) 62%, var(--paper))",
13
+ "color-mix(in srgb, var(--ink) 28%, var(--paper))",
14
+ "color-mix(in srgb, var(--ink) 14%, var(--paper))"
15
+ ];
16
+ function Meter({ label, value = 0, max, segments, format = (n) => n.toLocaleString("en-US"), warnAt = 0.9, warning = "Almost at your limit", action, size = "md", legend = true, className }) {
17
+ const parts = segments?.length ? segments : [{ label, value }];
18
+ const used = parts.reduce((a, p) => a + Math.max(0, p.value), 0);
19
+ const share = max > 0 ? Math.min(1, used / max) : 0;
20
+ const warn = share >= warnAt;
21
+ const starts = parts.map((_, i) => parts.slice(0, i).reduce((a, p) => a + Math.max(0, p.value), 0) / (max || 1));
22
+ return /* @__PURE__ */ jsxs("div", { className: cx("flex w-full flex-col", size === "sm" ? "gap-2" : "gap-2.5", className), children: [
23
+ /* @__PURE__ */ jsx("style", { href: "asta-meter", precedence: "asta", children: KEYFRAMES }),
24
+ /* @__PURE__ */ jsxs("div", { className: "flex items-baseline justify-between gap-3", children: [
25
+ /* @__PURE__ */ jsx("p", { className: cx("font-medium text-ink", size === "sm" ? "text-[13px]" : "text-[14px]"), children: label }),
26
+ action
27
+ ] }),
28
+ /* @__PURE__ */ jsx(
29
+ "div",
30
+ {
31
+ role: "meter",
32
+ "aria-label": label,
33
+ "aria-valuemin": 0,
34
+ "aria-valuemax": max,
35
+ "aria-valuenow": Math.min(used, max),
36
+ "aria-valuetext": `${format(used)} of ${format(max)}${warn ? `. ${typeof warning === "string" ? warning : ""}` : ""}`,
37
+ className: cx("relative w-full overflow-hidden rounded-full bg-paper-2 shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_6%,transparent)]", size === "sm" ? "h-1.5" : "h-2.5"),
38
+ children: /* @__PURE__ */ jsx("div", { className: "asta-meter-a absolute inset-0 origin-left animate-[asta-meter-in_1s_cubic-bezier(.16,1,.3,1)_both]", children: parts.map((p, i) => {
39
+ const w = max > 0 ? Math.max(0, p.value) / max : 0;
40
+ const x = starts[i];
41
+ return /* @__PURE__ */ jsx(
42
+ "span",
43
+ {
44
+ className: "asta-meter-a absolute inset-y-0 left-0 w-full origin-left transition-[transform,background-color] duration-700 ease-[cubic-bezier(.16,1,.3,1)]",
45
+ style: { transform: `translateX(${Math.min(1, x) * 100}%) scaleX(${Math.min(w, Math.max(0, 1 - x))})`, background: warn && parts.length === 1 ? "var(--ink)" : FILLS[i % FILLS.length] }
46
+ },
47
+ p.label
48
+ );
49
+ }) })
50
+ }
51
+ ),
52
+ /* @__PURE__ */ jsxs("div", { className: cx("flex flex-wrap items-center justify-between gap-x-4 gap-y-1", size === "sm" ? "text-[12px]" : "text-[12.5px]"), children: [
53
+ /* @__PURE__ */ jsxs("p", { className: "tabular-nums text-ink-2", children: [
54
+ /* @__PURE__ */ jsx("span", { className: "font-medium text-ink", children: format(used) }),
55
+ /* @__PURE__ */ jsxs("span", { className: "text-mute", children: [
56
+ " of ",
57
+ format(max)
58
+ ] })
59
+ ] }),
60
+ warn ? /* @__PURE__ */ jsxs("p", { className: "asta-meter-a flex animate-[asta-meter-fade_.4s_cubic-bezier(.16,1,.3,1)_both] items-center gap-1.5 font-medium text-ink", children: [
61
+ /* @__PURE__ */ jsx("svg", { viewBox: "0 0 16 16", className: "h-3.5 w-3.5", fill: "none", stroke: "currentColor", strokeWidth: "1.6", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": true, children: /* @__PURE__ */ jsx("path", { d: "M8 2.5 14 13H2zM8 6.5v3M8 11.2h.01" }) }),
62
+ warning
63
+ ] }, "warn") : /* @__PURE__ */ jsxs("p", { className: "tabular-nums text-mute", children: [
64
+ Math.round(share * 100),
65
+ "% used"
66
+ ] })
67
+ ] }),
68
+ legend && segments && segments.length > 1 && /* @__PURE__ */ jsx("ul", { className: "flex flex-wrap gap-x-4 gap-y-1.5 pt-0.5", children: segments.map((p, i) => /* @__PURE__ */ jsxs("li", { className: "flex items-center gap-1.5 text-[12px] text-mute", children: [
69
+ /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "h-2 w-2 rounded-full", style: { background: FILLS[i % FILLS.length] } }),
70
+ /* @__PURE__ */ jsx("span", { className: "text-ink-2", children: p.label }),
71
+ /* @__PURE__ */ jsx("span", { className: "tabular-nums", children: format(p.value) })
72
+ ] }, p.label)) })
73
+ ] });
74
+ }
75
+ var meter_default = Meter;
76
+
77
+ export {
78
+ Meter,
79
+ meter_default
80
+ };
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import {
3
3
  Select
4
- } from "./chunk-QDRBMWRX.js";
4
+ } from "./chunk-JLCSRNI2.js";
5
5
  import {
6
6
  Button
7
7
  } from "./chunk-WSL4JGEA.js";
8
8
  import {
9
9
  Input
10
- } from "./chunk-U7BYEW3Y.js";
10
+ } from "./chunk-UZF7SCRT.js";
11
11
 
12
12
  // components/kit/base/checkout.tsx
13
13
  import { useEffect, useId, useMemo, useRef, useState } from "react";
@@ -49,20 +49,26 @@ function check(f, d) {
49
49
  case "email":
50
50
  return /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(v) ? null : "Enter an email like you@example.com.";
51
51
  case "cardNumber":
52
- return (isAmex(v) ? v.length === 15 : v.length >= 13 && v.length <= 19) ? null : "Check the card number.";
52
+ return (isAmex(v) ? v.length === 15 : v.length >= 13 && v.length <= 19) ? null : isAmex(v) ? "Enter all 15 digits on the front of the card." : "Enter the full card number from the front of the card.";
53
53
  case "cardExpiry": {
54
54
  const [m, y] = v.split("/").map(Number);
55
- if (!/^\d{2}\/\d{2}$/.test(v) || !m || m > 12) return "Use MM / YY.";
55
+ if (!/^\d{2}\/\d{2}$/.test(v) || !m || m > 12) return "Enter the expiry as MM / YY, like 08 / 29.";
56
56
  const now = /* @__PURE__ */ new Date();
57
57
  const end = new Date(2e3 + y, m, 1);
58
- return end > now ? null : "This card has expired.";
58
+ return end > now ? null : "This card has expired. Use one with a later date.";
59
59
  }
60
60
  case "cardCvc":
61
- return v.length >= 3 ? null : "3 or 4 digits, on the back.";
61
+ return v.length >= 3 ? null : "Enter the 3 or 4 digits on the back of the card.";
62
62
  default:
63
- return v ? null : "Required.";
63
+ return v ? null : REQUIRED[f] ?? "Fill in this field.";
64
64
  }
65
65
  }
66
+ var REQUIRED = {
67
+ name: "Enter your full name.",
68
+ address: "Enter your street address.",
69
+ city: "Enter your city.",
70
+ postal: "Enter your postal code."
71
+ };
66
72
  function RollChar({ c, animate, delay }) {
67
73
  const [on] = useState(animate);
68
74
  return /* @__PURE__ */ jsx("span", { className: "inline-block whitespace-pre", style: on ? { animation: `kit-co-roll .5s ${CURVE} ${delay}ms both` } : void 0, children: c });
@@ -181,7 +187,11 @@ function Checkout({
181
187
  const errors = Object.fromEntries(ORDER.map((f) => [f, check(f, d)]));
182
188
  const shown = (f) => touched[f] ? errors[f] : null;
183
189
  const locked = state !== "idle";
184
- const set = (f, v) => setD((p) => ({ ...p, [f]: v }));
190
+ const set = (f, v) => {
191
+ setD((p) => ({ ...p, [f]: v }));
192
+ const k = f;
193
+ if (ORDER.includes(k) && touched[k] && !check(k, { ...d, [f]: v })) setTouched((t) => ({ ...t, [k]: false }));
194
+ };
185
195
  const blur = (f) => setTouched((t) => ({ ...t, [f]: true }));
186
196
  const formatted = (f, fmt, max) => (e) => {
187
197
  const el = e.currentTarget;
@@ -203,13 +213,13 @@ function Checkout({
203
213
  const applyPromo = () => {
204
214
  const code = promoText.trim().toUpperCase();
205
215
  const hit = Object.entries(promoCodes).find(([k]) => k.toUpperCase() === code);
206
- if (!code) return;
216
+ if (!code) return setPromoMsg("Enter a promo code first.");
207
217
  if (hit) {
208
218
  setPromo({ code: hit[0].toUpperCase(), off: hit[1] });
209
219
  setPromoMsg(`${hit[0].toUpperCase()} applied.`);
210
220
  setPromoText("");
211
221
  setPromoOpen(false);
212
- } else setPromoMsg("That code isn't valid.");
222
+ } else setPromoMsg("That code isn't valid. Check the spelling and try again.");
213
223
  };
214
224
  const pay = async () => {
215
225
  if (locked) return;
@@ -234,6 +244,7 @@ function Checkout({
234
244
  Input,
235
245
  {
236
246
  id: id(f),
247
+ name: f,
237
248
  value: f === "cardNumber" ? fmtCard(d[f]) : f === "cardExpiry" ? fmtExpiry(digits(d[f])) : d[f],
238
249
  onChange: (e) => set(f, e.target.value),
239
250
  onBlur: () => blur(f),
@@ -270,17 +281,17 @@ function Checkout({
270
281
  pay();
271
282
  },
272
283
  children: [
273
- /* @__PURE__ */ jsx(Section, { n: 1, title: "Contact", children: /* @__PURE__ */ jsx(Labeled, { id: id("email"), label: "Email", error: shown("email"), children: input("email", { type: "email", autoComplete: "email", placeholder: "you@example.com" }) }) }),
284
+ /* @__PURE__ */ jsx(Section, { n: 1, title: "Contact", children: /* @__PURE__ */ jsx(Labeled, { id: id("email"), label: "Email", error: shown("email"), children: input("email", { type: "email", autoComplete: "email", inputMode: "email", autoCapitalize: "none", spellCheck: false, placeholder: "you@example.com" }) }) }),
274
285
  /* @__PURE__ */ jsxs(Section, { n: 2, title: "Shipping", children: [
275
286
  /* @__PURE__ */ jsx(Labeled, { id: id("name"), label: "Full name", error: shown("name"), children: input("name", { autoComplete: "name" }) }),
276
- /* @__PURE__ */ jsx(Labeled, { id: id("address"), label: "Address", error: shown("address"), children: input("address", { autoComplete: "street-address" }) }),
287
+ /* @__PURE__ */ jsx(Labeled, { id: id("address"), label: "Address", error: shown("address"), children: input("address", { autoComplete: "address-line1" }) }),
277
288
  /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 gap-3", children: [
278
289
  /* @__PURE__ */ jsx(Labeled, { id: id("city"), label: "City", error: shown("city"), children: input("city", { autoComplete: "address-level2" }) }),
279
- /* @__PURE__ */ jsx(Labeled, { id: id("postal"), label: "Postal code", error: shown("postal"), children: input("postal", { autoComplete: "postal-code", inputMode: "numeric" }) })
290
+ /* @__PURE__ */ jsx(Labeled, { id: id("postal"), label: "Postal code", error: shown("postal"), children: input("postal", { autoComplete: "postal-code", autoCapitalize: "characters" }) })
280
291
  ] }),
281
292
  /* @__PURE__ */ jsxs("div", { children: [
282
293
  /* @__PURE__ */ jsx("p", { className: "mb-1.5 text-[12.5px] text-ink-2", children: "Country" }),
283
- /* @__PURE__ */ jsx(Select, { label: "Country", options: countries, value: d.country, onChange: (v) => set("country", v), disabled: locked })
294
+ /* @__PURE__ */ jsx(Select, { label: "Country", name: "country", options: countries, value: d.country, onChange: (v) => set("country", v), disabled: locked })
284
295
  ] }),
285
296
  /* @__PURE__ */ jsx("div", { role: "radiogroup", "aria-label": "Shipping speed", className: "mt-1 grid gap-2 sm:grid-cols-2", children: shippingOptions.map((s) => {
286
297
  const on = s.id === d.shipping;
@@ -365,8 +376,13 @@ function Checkout({
365
376
  Input,
366
377
  {
367
378
  size: "sm",
379
+ name: "promo",
368
380
  "aria-label": "Promo code",
369
- placeholder: "Promo code",
381
+ "aria-describedby": promoMsg ? `${uid}-promo-msg` : void 0,
382
+ placeholder: "Enter code\u2026",
383
+ autoComplete: "off",
384
+ autoCapitalize: "characters",
385
+ spellCheck: false,
370
386
  value: promoText,
371
387
  autoFocus: true,
372
388
  disabled: locked,
@@ -382,7 +398,7 @@ function Checkout({
382
398
  }
383
399
  }
384
400
  ),
385
- /* @__PURE__ */ jsx(Button, { size: "sm", variant: "outline", onClick: applyPromo, disabled: locked || !promoText.trim(), children: "Apply" })
401
+ /* @__PURE__ */ jsx(Button, { size: "sm", variant: "outline", onClick: applyPromo, disabled: locked, children: "Apply" })
386
402
  ] }) : /* @__PURE__ */ jsx(
387
403
  "button",
388
404
  {
@@ -393,7 +409,7 @@ function Checkout({
393
409
  children: "Add a promo code"
394
410
  }
395
411
  ),
396
- /* @__PURE__ */ jsx("p", { className: "mt-1.5 min-h-4 text-[12px] text-mute", "aria-live": "polite", children: promoMsg })
412
+ /* @__PURE__ */ jsx("p", { id: `${uid}-promo-msg`, className: "mt-1.5 min-h-4 text-[12px] text-mute", "aria-live": "polite", children: promoMsg })
397
413
  ] }),
398
414
  /* @__PURE__ */ jsxs("dl", { className: "mt-3 grid gap-2", children: [
399
415
  /* @__PURE__ */ jsxs("div", { className: rowCls, children: [
@@ -43,7 +43,7 @@ function ValidatedTextarea({ label, rules, value: valueProp, defaultValue = "",
43
43
  if (value) setTouched(true);
44
44
  rest.onBlur?.(e);
45
45
  },
46
- className: "block w-full resize-none bg-transparent px-3.5 py-3 text-[14px] leading-[1.55] text-ink outline-none placeholder:text-mute"
46
+ className: "block w-full resize-none bg-transparent px-3.5 py-3 text-[16px] sm:text-[14px] leading-[1.55] text-ink outline-none placeholder:text-mute"
47
47
  }
48
48
  ) }),
49
49
  /* @__PURE__ */ jsx("div", { className: cx("grid transition-[grid-template-rows] duration-400 ease-[cubic-bezier(.16,1,.3,1)] motion-reduce:transition-none", state === "idle" ? "grid-rows-[0fr]" : "grid-rows-[1fr]"), children: /* @__PURE__ */ jsx("div", { className: "overflow-hidden", children: /* @__PURE__ */ jsx("ul", { id: `${fid}-rules`, className: "flex flex-col gap-1 pt-1", "aria-live": "polite", children: state === "success" ? /* @__PURE__ */ jsxs("li", { className: "flex items-center gap-2 text-[12.5px] text-[#30a46c]", children: [
@@ -191,7 +191,7 @@ function HoverCard({ trigger, children, open, defaultOpen = false, onOpenChange,
191
191
  "shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_10%,transparent),0_18px_44px_-16px_rgb(0_0_0/0.32),0_4px_10px_-6px_rgb(0_0_0/0.12)]",
192
192
  // An invisible bridge over the gap, so the pointer can cross from the link without the card closing.
193
193
  "before:absolute before:inset-x-0 before:h-[var(--asta-hc-gap,10px)] before:content-[''] data-[side=bottom]:before:bottom-full data-[side=top]:before:top-full",
194
- "animate-[asta-hovercard-in_.28s_cubic-bezier(.16,1,.3,1)_both] data-[state=closed]:animate-[asta-hovercard-out_.14s_ease-in_both]",
194
+ "animate-[asta-hovercard-in_.28s_cubic-bezier(.16,1,.3,1)_both] data-[state=closed]:animate-[asta-hovercard-out_.14s_cubic-bezier(.16,1,.3,1)_both]",
195
195
  "data-[state=closed]:pointer-events-none motion-reduce:![animation-duration:1ms]",
196
196
  className
197
197
  ),
@@ -45,7 +45,7 @@ function Field({ label, hint, error, required, aside, className, children }) {
45
45
  /* @__PURE__ */ jsx("style", { href: "asta-field", precedence: "asta", children: `@keyframes kit-field-in { from { opacity: 0; transform: translateY(-3px) } to { opacity: 1; transform: none } }` })
46
46
  ] });
47
47
  }
48
- var fieldInputClass = "h-10 w-full rounded-lg bg-paper px-3 text-[14px] text-ink outline-none placeholder:text-mute shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_14%,transparent)] transition-shadow duration-200 hover:shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_24%,transparent)] focus:shadow-[inset_0_0_0_1px_var(--brand),0_0_0_3px_color-mix(in_srgb,var(--brand)_18%,transparent)] aria-[invalid=true]:shadow-[inset_0_0_0_1px_#e5484d,0_0_0_3px_rgb(229_72_77/0.14)]";
48
+ var fieldInputClass = "h-10 w-full rounded-lg bg-paper px-3 text-[16px] sm:text-[14px] text-ink outline-none placeholder:text-mute shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_14%,transparent)] transition-shadow duration-200 hover:shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_24%,transparent)] focus:shadow-[inset_0_0_0_1px_var(--brand),0_0_0_3px_color-mix(in_srgb,var(--brand)_18%,transparent)] aria-[invalid=true]:shadow-[inset_0_0_0_1px_#e5484d,0_0_0_3px_rgb(229_72_77/0.14)]";
49
49
  var field_default = Field;
50
50
 
51
51
  export {
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  Avatar
4
- } from "./chunk-2LZM435Z.js";
4
+ } from "./chunk-IVCHYE55.js";
5
5
 
6
6
  // components/kit/base/sidebar.tsx
7
7
  import { useEffect, useLayoutEffect, useRef, useState } from "react";
@@ -33,7 +33,9 @@ var Spinner = () => /* @__PURE__ */ jsx(
33
33
  );
34
34
  function Field({
35
35
  label,
36
+ name,
36
37
  type,
38
+ inputMode,
37
39
  value,
38
40
  onChange,
39
41
  onBlur,
@@ -68,16 +70,20 @@ function Field({
68
70
  "input",
69
71
  {
70
72
  id,
73
+ name,
71
74
  type,
75
+ inputMode,
72
76
  value,
73
77
  autoComplete,
78
+ autoCapitalize: "none",
79
+ spellCheck: false,
74
80
  placeholder,
75
81
  onChange: (e) => onChange(e.target.value),
76
82
  onBlur,
77
83
  "aria-invalid": hasError || void 0,
78
84
  "aria-describedby": hasError ? `${id}-err` : void 0,
79
85
  className: cx(
80
- "h-11 w-full rounded-[10px] bg-paper-2 px-4 text-[14px] text-ink outline-none transition-[box-shadow,background-color] duration-300 placeholder:text-mute hover:bg-[color-mix(in_srgb,var(--ink)_6%,var(--paper-2))] focus-visible:bg-paper focus-visible:shadow-[inset_0_0_0_1px_var(--brand),0_0_0_4px_color-mix(in_srgb,var(--brand)_12%,transparent)]",
86
+ "h-11 w-full rounded-[10px] bg-paper-2 px-4 text-[16px] sm:text-[14px] text-ink outline-none transition-[box-shadow,background-color] duration-300 placeholder:text-mute hover:bg-[color-mix(in_srgb,var(--ink)_6%,var(--paper-2))] focus-visible:bg-paper focus-visible:shadow-[inset_0_0_0_1px_var(--brand),0_0_0_4px_color-mix(in_srgb,var(--brand)_12%,transparent)]",
81
87
  !!end && "pr-12",
82
88
  hasError && "shadow-[inset_0_0_0_1.5px_var(--ink)]"
83
89
  )
@@ -157,11 +163,17 @@ function SplitSignIn({
157
163
  const y = (e.clientY - r.top) / r.height - 0.5;
158
164
  img.style.transform = `scale(1.06) translate(${(-x * 14).toFixed(1)}px, ${(-y * 10).toFixed(1)}px)`;
159
165
  };
160
- const errors = {
161
- email: !email.trim() ? "Enter your email." : !validEmail(email) ? "That doesn't look like an email address." : "",
162
- password: !password ? "Enter your password." : password.length < 8 ? "Use at least 8 characters." : ""
166
+ const check = {
167
+ email: (v) => !v.trim() ? "Enter your email." : !validEmail(v) ? "Enter an email like name@company.com." : "",
168
+ password: (v) => !v ? "Enter your password." : v.length < 8 ? "Use at least 8 characters." : ""
163
169
  };
170
+ const errors = { email: check.email(email), password: check.password(password) };
164
171
  const show = (k) => touched[k] ? errors[k] : "";
172
+ const edit = (k, v) => {
173
+ if (k === "email") setEmail(v);
174
+ else setPassword(v);
175
+ if (touched[k] && !check[k](v)) setTouched((t) => ({ ...t, [k]: false }));
176
+ };
165
177
  const submit = async (e) => {
166
178
  e.preventDefault();
167
179
  if (state === "loading") return;
@@ -169,6 +181,8 @@ function SplitSignIn({
169
181
  setFormError("");
170
182
  if (errors.email || errors.password) {
171
183
  setShake((n) => n + 1);
184
+ const first2 = e.currentTarget.elements.namedItem(errors.email ? "email" : "password");
185
+ if (first2 instanceof HTMLElement) first2.focus();
172
186
  return;
173
187
  }
174
188
  setState("loading");
@@ -352,11 +366,13 @@ function SplitSignIn({
352
366
  Field,
353
367
  {
354
368
  label: "Email",
369
+ name: "email",
355
370
  type: "email",
371
+ inputMode: "email",
356
372
  autoComplete: "email",
357
- placeholder: "Enter email",
373
+ placeholder: "Enter your email\u2026",
358
374
  value: email,
359
- onChange: setEmail,
375
+ onChange: (v) => edit("email", v),
360
376
  onBlur: () => email && setTouched((t) => ({ ...t, email: true })),
361
377
  error: show("email"),
362
378
  shake
@@ -366,11 +382,12 @@ function SplitSignIn({
366
382
  Field,
367
383
  {
368
384
  label: "Password",
385
+ name: "password",
369
386
  type: reveal ? "text" : "password",
370
387
  autoComplete: "current-password",
371
- placeholder: "Enter password",
388
+ placeholder: "Enter your password\u2026",
372
389
  value: password,
373
- onChange: setPassword,
390
+ onChange: (v) => edit("password", v),
374
391
  onBlur: () => password && setTouched((t) => ({ ...t, password: true })),
375
392
  error: show("password") || formError,
376
393
  shake,
@@ -8,6 +8,7 @@ var DOWN = "var(--ink-2)";
8
8
  var LEVELS = 5;
9
9
  var TICK = 0.01;
10
10
  var EASE = "cubic-bezier(.16,1,.3,1)";
11
+ var SIDE = "shrink-0 px-3 text-[0.85em] leading-none uppercase tracking-[0.1em] text-mute";
11
12
  function seeded(s) {
12
13
  return () => {
13
14
  s = s + 1831565813 | 0;
@@ -74,15 +75,18 @@ function OrderBook() {
74
75
  return /* @__PURE__ */ jsxs("div", { className: "flex h-full w-full items-center justify-center px-5 pb-5 pt-14 [container-type:size]", children: [
75
76
  /* @__PURE__ */ jsx("style", { href: "asta-orderbook", precedence: "asta", children: `@keyframes ob-flash { from { opacity: 1 } to { opacity: 0 } }` }),
76
77
  /* @__PURE__ */ jsxs("div", { className: "flex h-full max-h-[460px] w-full max-w-[380px] flex-col gap-[3px] font-mono text-[clamp(11px,2.6cqh,15px)]", children: [
77
- [...book.asks].reverse().map((r, i) => row(r, ca[LEVELS - 1 - i], DOWN, `a${i}`, LEVELS - 1 - i)),
78
+ /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: SIDE, children: "Asks" }),
79
+ /* @__PURE__ */ jsx("div", { role: "group", "aria-label": "Asks", className: "flex min-h-0 flex-[5] flex-col gap-[3px]", children: [...book.asks].reverse().map((r, i) => row(r, ca[LEVELS - 1 - i], DOWN, `a${i}`, LEVELS - 1 - i)) }),
78
80
  /* @__PURE__ */ jsxs("div", { className: "my-1.5 flex flex-[1.6] items-center justify-between px-3", children: [
79
81
  /* @__PURE__ */ jsxs("span", { className: "flex items-center gap-2 text-[1.55em] font-medium tabular-nums tracking-[-0.02em] transition-colors duration-700", style: { color: mc, transitionTimingFunction: EASE }, children: [
80
82
  book.mid.toFixed(2),
81
- /* @__PURE__ */ jsx("span", { className: `text-[0.6em] transition-transform duration-500 ${book.dir > 0 ? "" : "rotate-180"}`, style: { transitionTimingFunction: EASE }, children: "\u25B2" })
83
+ /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: `text-[0.6em] transition-transform duration-500 ${book.dir > 0 ? "" : "rotate-180"}`, style: { transitionTimingFunction: EASE }, children: "\u25B2" }),
84
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: book.dir > 0 ? "up" : "down" })
82
85
  ] }),
83
86
  /* @__PURE__ */ jsx("span", { className: "text-[0.85em] uppercase tracking-[0.1em] text-mute", children: "mid" })
84
87
  ] }),
85
- book.bids.map((r, i) => row(r, cb[i], UP, `b${i}`, i))
88
+ /* @__PURE__ */ jsx("div", { role: "group", "aria-label": "Bids", className: "flex min-h-0 flex-[5] flex-col gap-[3px]", children: book.bids.map((r, i) => row(r, cb[i], UP, `b${i}`, i)) }),
89
+ /* @__PURE__ */ jsx("span", { "aria-hidden": true, className: SIDE, children: "Bids" })
86
90
  ] })
87
91
  ] });
88
92
  }
@@ -2,7 +2,7 @@
2
2
  import {
3
3
  avatarFill,
4
4
  initials
5
- } from "./chunk-2LZM435Z.js";
5
+ } from "./chunk-IVCHYE55.js";
6
6
 
7
7
  // components/kit/base/avatar-group.tsx
8
8
  import { useRef, useState } from "react";
@@ -23,7 +23,7 @@ var CSS = `
23
23
  .aui-011-sheet { animation: aui-011-drop .4s ${EASE} both; }
24
24
  .aui-011-vp { transform-origin: top center; }
25
25
  .aui-011-vp[data-state=open] { animation: aui-011-vp-in .26s ${EASE}; }
26
- .aui-011-vp[data-state=closed] { animation: aui-011-vp-out .16s ease-in forwards; }
26
+ .aui-011-vp[data-state=closed] { animation: aui-011-vp-out .16s cubic-bezier(.16,1,.3,1) forwards; }
27
27
  .aui-011-c[data-motion=from-start] { animation: aui-011-from-l .3s ${EASE}; }
28
28
  .aui-011-c[data-motion=from-end] { animation: aui-011-from-r .3s ${EASE}; }
29
29
  .aui-011-c[data-motion=to-start] { animation: aui-011-to-l .3s ${EASE} forwards; }
@@ -0,0 +1,165 @@
1
+ "use client";
2
+ import {
3
+ Button
4
+ } from "./chunk-ZWBJUJTR.js";
5
+
6
+ // components/kit/invoice.tsx
7
+ import { useState } from "react";
8
+ import { jsx, jsxs } from "react/jsx-runtime";
9
+ var cx = (...c) => c.filter(Boolean).join(" ");
10
+ var KEYFRAMES = `@keyframes asta-invoice-in { from { opacity: 0; transform: translateY(4px) } }
11
+ @keyframes asta-invoice-draw { from { stroke-dashoffset: 1 } }
12
+ @keyframes asta-invoice-pop { 0% { transform: scale(.6); opacity: 0 } 60% { transform: scale(1.08) } 100% { transform: none; opacity: 1 } }
13
+ @media (prefers-reduced-motion: reduce) { .asta-invoice-a { animation: none !important } }`;
14
+ var STATUS = {
15
+ draft: { label: "Draft", cls: "text-mute shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_16%,transparent)]" },
16
+ due: { label: "Due", cls: "bg-paper-2 text-ink" },
17
+ overdue: { label: "Overdue", cls: "bg-ink text-paper" },
18
+ paid: { label: "Paid", cls: "bg-[color-mix(in_srgb,var(--brand)_12%,transparent)] text-brand" }
19
+ };
20
+ function Invoice({ number, issued, due, from, to, items, taxRate = 0, discount = 0, currency = "USD", locale = "en-US", status = "due", notes, brand, onPay, onDownload, className }) {
21
+ const [state, setState] = useState(status);
22
+ const [paying, setPaying] = useState(false);
23
+ const [paidOn, setPaidOn] = useState(null);
24
+ const money = (n) => new Intl.NumberFormat(locale, { style: "currency", currency }).format(n);
25
+ const subtotal = items.reduce((a, it) => a + it.quantity * it.unitPrice, 0);
26
+ const taxed = Math.max(0, subtotal - discount);
27
+ const tax = Math.round(taxed * taxRate * 100) / 100;
28
+ const total = taxed + tax;
29
+ const paid = state === "paid";
30
+ const s = STATUS[state];
31
+ const pay = async () => {
32
+ if (!onPay || paying) return;
33
+ setPaying(true);
34
+ try {
35
+ await onPay();
36
+ setPaidOn((/* @__PURE__ */ new Date()).toLocaleDateString(locale, { month: "short", day: "numeric", year: "numeric" }));
37
+ setState("paid");
38
+ } finally {
39
+ setPaying(false);
40
+ }
41
+ };
42
+ return /* @__PURE__ */ jsxs(
43
+ "article",
44
+ {
45
+ "aria-label": `Invoice ${number}`,
46
+ className: cx("@container w-full rounded-[14px] bg-paper text-ink shadow-[inset_0_0_0_1px_color-mix(in_srgb,var(--ink)_10%,transparent),0_18px_44px_-28px_rgb(0_0_0/0.3)]", className),
47
+ children: [
48
+ /* @__PURE__ */ jsx("style", { href: "asta-invoice", precedence: "asta", children: KEYFRAMES }),
49
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-7 p-5 @min-[560px]:p-8", children: [
50
+ /* @__PURE__ */ jsxs("header", { className: "flex flex-wrap items-start justify-between gap-4", children: [
51
+ /* @__PURE__ */ jsx("div", { className: "min-w-0", children: brand ?? /* @__PURE__ */ jsx("p", { className: "text-[17px] font-semibold tracking-[-0.03em]", children: from.name }) }),
52
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-end gap-1.5 text-right", children: [
53
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
54
+ /* @__PURE__ */ jsx("h2", { className: "text-[20px] font-medium tracking-[-0.03em]", children: "Invoice" }),
55
+ /* @__PURE__ */ jsxs("span", { className: cx("asta-invoice-a inline-flex h-6 animate-[asta-invoice-pop_.45s_cubic-bezier(.16,1,.3,1)_both] items-center gap-1 rounded-md px-2 text-[11.5px] font-medium", s.cls), children: [
56
+ paid ? /* @__PURE__ */ jsx("svg", { viewBox: "0 0 16 16", className: "h-3 w-3", fill: "none", stroke: "currentColor", strokeWidth: "2.2", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": true, children: /* @__PURE__ */ jsx("path", { d: "m3.5 8.5 3 3 6-7", pathLength: 1, strokeDasharray: 1, className: "asta-invoice-a animate-[asta-invoice-draw_.5s_cubic-bezier(.16,1,.3,1)_.15s_both]" }) }) : state === "overdue" ? /* @__PURE__ */ jsx("svg", { viewBox: "0 0 16 16", className: "h-3 w-3", fill: "none", stroke: "currentColor", strokeWidth: "1.8", strokeLinecap: "round", "aria-hidden": true, children: /* @__PURE__ */ jsx("path", { d: "M8 4.5v4M8 11.2h.01" }) }) : null,
57
+ s.label
58
+ ] }, state)
59
+ ] }),
60
+ /* @__PURE__ */ jsx("p", { className: "font-mono text-[12px] text-mute", children: number })
61
+ ] })
62
+ ] }),
63
+ /* @__PURE__ */ jsxs("div", { className: "grid gap-5 text-[13px] @min-[560px]:grid-cols-[1fr_1fr_auto] @min-[560px]:gap-8", children: [
64
+ [
65
+ ["Billed to", to],
66
+ ["From", from]
67
+ ].map(([title, p]) => {
68
+ const party = p;
69
+ return /* @__PURE__ */ jsxs("div", { className: "min-w-0", children: [
70
+ /* @__PURE__ */ jsx("p", { className: "font-mono text-[10.5px] uppercase tracking-wider text-mute", children: title }),
71
+ /* @__PURE__ */ jsx("p", { className: "mt-1.5 font-medium", children: party.name }),
72
+ party.lines.map((l) => /* @__PURE__ */ jsx("p", { className: "text-mute", children: l }, l))
73
+ ] }, title);
74
+ }),
75
+ /* @__PURE__ */ jsxs("dl", { className: "grid grid-cols-2 gap-x-6 gap-y-1.5 @min-[560px]:grid-cols-1 @min-[560px]:text-right", children: [
76
+ /* @__PURE__ */ jsxs("div", { children: [
77
+ /* @__PURE__ */ jsx("dt", { className: "font-mono text-[10.5px] uppercase tracking-wider text-mute", children: "Issued" }),
78
+ /* @__PURE__ */ jsx("dd", { className: "mt-1", children: issued })
79
+ ] }),
80
+ /* @__PURE__ */ jsxs("div", { children: [
81
+ /* @__PURE__ */ jsx("dt", { className: "font-mono text-[10.5px] uppercase tracking-wider text-mute", children: paid ? "Paid" : "Due" }),
82
+ /* @__PURE__ */ jsx("dd", { className: cx("mt-1", paid && "asta-invoice-a animate-[asta-invoice-in_.4s_cubic-bezier(.16,1,.3,1)_both] text-brand"), children: paid ? paidOn ?? due : due }, paid ? "p" : "d")
83
+ ] })
84
+ ] })
85
+ ] }),
86
+ /* @__PURE__ */ jsxs("div", { children: [
87
+ /* @__PURE__ */ jsxs("div", { className: "hidden grid-cols-[1fr_56px_96px_104px] gap-4 px-1 pb-2 font-mono text-[10.5px] uppercase tracking-wider text-mute @min-[560px]:grid", "aria-hidden": true, children: [
88
+ /* @__PURE__ */ jsx("span", { children: "Item" }),
89
+ /* @__PURE__ */ jsx("span", { className: "text-right", children: "Qty" }),
90
+ /* @__PURE__ */ jsx("span", { className: "text-right", children: "Price" }),
91
+ /* @__PURE__ */ jsx("span", { className: "text-right", children: "Amount" })
92
+ ] }),
93
+ /* @__PURE__ */ jsx("ul", { className: "flex flex-col", children: items.map((it, i) => /* @__PURE__ */ jsxs(
94
+ "li",
95
+ {
96
+ className: "grid grid-cols-[1fr_auto] gap-x-4 gap-y-0.5 rounded-lg px-1 py-2.5 text-[13.5px] odd:bg-paper-2 @min-[560px]:grid-cols-[1fr_56px_96px_104px] @min-[560px]:items-center @min-[560px]:px-3",
97
+ children: [
98
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0", children: [
99
+ /* @__PURE__ */ jsx("p", { className: "font-medium", children: it.description }),
100
+ it.detail && /* @__PURE__ */ jsx("p", { className: "text-[12px] text-mute", children: it.detail }),
101
+ /* @__PURE__ */ jsxs("p", { className: "text-[12px] tabular-nums text-mute @min-[560px]:hidden", children: [
102
+ it.quantity,
103
+ " \xD7 ",
104
+ money(it.unitPrice)
105
+ ] })
106
+ ] }),
107
+ /* @__PURE__ */ jsx("span", { className: "hidden text-right tabular-nums text-ink-2 @min-[560px]:block", children: it.quantity }),
108
+ /* @__PURE__ */ jsx("span", { className: "hidden text-right tabular-nums text-ink-2 @min-[560px]:block", children: money(it.unitPrice) }),
109
+ /* @__PURE__ */ jsx("span", { className: "text-right font-medium tabular-nums", children: money(it.quantity * it.unitPrice) })
110
+ ]
111
+ },
112
+ it.description + i
113
+ )) })
114
+ ] }),
115
+ /* @__PURE__ */ jsxs("dl", { className: "ml-auto flex w-full max-w-[300px] flex-col gap-1.5 text-[13px]", children: [
116
+ /* @__PURE__ */ jsxs("div", { className: "flex justify-between gap-4", children: [
117
+ /* @__PURE__ */ jsx("dt", { className: "text-mute", children: "Subtotal" }),
118
+ /* @__PURE__ */ jsx("dd", { className: "tabular-nums", children: money(subtotal) })
119
+ ] }),
120
+ discount > 0 && /* @__PURE__ */ jsxs("div", { className: "flex justify-between gap-4", children: [
121
+ /* @__PURE__ */ jsx("dt", { className: "text-mute", children: "Discount" }),
122
+ /* @__PURE__ */ jsxs("dd", { className: "tabular-nums", children: [
123
+ "\u2212",
124
+ money(discount)
125
+ ] })
126
+ ] }),
127
+ taxRate > 0 && /* @__PURE__ */ jsxs("div", { className: "flex justify-between gap-4", children: [
128
+ /* @__PURE__ */ jsxs("dt", { className: "text-mute", children: [
129
+ "Tax (",
130
+ Math.round(taxRate * 1e3) / 10,
131
+ "%)"
132
+ ] }),
133
+ /* @__PURE__ */ jsx("dd", { className: "tabular-nums", children: money(tax) })
134
+ ] }),
135
+ /* @__PURE__ */ jsxs("div", { className: "mt-1.5 flex items-baseline justify-between gap-4 pt-1.5", children: [
136
+ /* @__PURE__ */ jsx("dt", { className: "font-medium", children: "Total" }),
137
+ /* @__PURE__ */ jsx("dd", { className: "text-[22px] font-medium tracking-[-0.03em] tabular-nums", children: money(total) })
138
+ ] }),
139
+ /* @__PURE__ */ jsxs("div", { className: "flex justify-between gap-4", children: [
140
+ /* @__PURE__ */ jsx("dt", { className: "text-mute", children: "Amount due" }),
141
+ /* @__PURE__ */ jsx("dd", { className: cx("font-medium tabular-nums", paid && "asta-invoice-a animate-[asta-invoice-in_.4s_cubic-bezier(.16,1,.3,1)_both] text-brand"), children: money(paid ? 0 : total) }, paid ? "p" : "d")
142
+ ] })
143
+ ] }),
144
+ (notes || onPay || onDownload) && /* @__PURE__ */ jsxs("footer", { className: "flex flex-col gap-4 @min-[560px]:flex-row @min-[560px]:items-end @min-[560px]:justify-between", children: [
145
+ notes ? /* @__PURE__ */ jsx("div", { className: "max-w-[360px] text-[12.5px] leading-relaxed text-mute", children: notes }) : /* @__PURE__ */ jsx("span", {}),
146
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-2 @max-[559px]:[&>*]:flex-1", children: [
147
+ onDownload && /* @__PURE__ */ jsx(Button, { variant: "outline", size: "sm", onClick: onDownload, children: "Download PDF" }),
148
+ onPay && !paid && state !== "draft" && /* @__PURE__ */ jsxs(Button, { variant: "accent", size: "sm", loading: paying, onClick: pay, children: [
149
+ "Pay ",
150
+ money(total)
151
+ ] })
152
+ ] })
153
+ ] }),
154
+ /* @__PURE__ */ jsx("p", { className: "sr-only", "aria-live": "polite", children: paid && paidOn ? `Invoice ${number} paid on ${paidOn}.` : "" })
155
+ ] })
156
+ ]
157
+ }
158
+ );
159
+ }
160
+ var invoice_default = Invoice;
161
+
162
+ export {
163
+ Invoice,
164
+ invoice_default
165
+ };