@openrails/billing-ui 0.282.0 → 0.283.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 (215) hide show
  1. package/README.md +108 -364
  2. package/dist/account/format.d.ts +5 -1
  3. package/dist/admin/context.d.ts +38 -46
  4. package/dist/admin/lib/api/endpoints.d.ts +4 -4
  5. package/dist/admin/lib/api/index.d.ts +4 -4
  6. package/dist/admin/lib/api/metrics.d.ts +15 -6
  7. package/dist/admin/lib/capabilities.d.ts +2 -0
  8. package/dist/admin/lib/format.d.ts +29 -1
  9. package/dist/admin/lib/mutations.d.ts +0 -10
  10. package/dist/admin/lib/queries.d.ts +16 -10
  11. package/dist/admin/messages.d.ts +61 -20
  12. package/dist/admin/pages/catalog/price-wizard-logic.d.ts +2 -0
  13. package/dist/admin/pages/catalog/price-wizard.d.ts +1 -3
  14. package/dist/admin/pages/customers/credits.d.ts +4 -1
  15. package/dist/admin/pages/dashboard/levels.d.ts +8 -0
  16. package/dist/admin/pages/dashboard/lib.d.ts +16 -7
  17. package/dist/admin/pages/dashboard/programs.d.ts +3 -0
  18. package/dist/admin/pages/dashboard/query-builder.d.ts +20 -0
  19. package/dist/admin/pages/dashboard/range.d.ts +8 -2
  20. package/dist/admin/pages/dashboard/registry.d.ts +14 -0
  21. package/dist/admin/pages/dashboard/reports-model.d.ts +8 -4
  22. package/dist/admin/pages/dashboard/reports.d.ts +1 -1
  23. package/dist/admin/pages/dashboard/units.d.ts +5 -0
  24. package/dist/admin/pages/dashboard/use-range.d.ts +5 -1
  25. package/dist/admin/pages/dashboard/widget-editor.d.ts +7 -2
  26. package/dist/admin/pages/dashboard/widget-tile.d.ts +10 -4
  27. package/dist/admin/pages/dashboard/widget-viz.d.ts +10 -5
  28. package/dist/admin/pages/ops/signals.d.ts +4 -0
  29. package/dist/admin/pages/payments/attempts.d.ts +2 -2
  30. package/dist/admin/pages/payments/health-model.d.ts +20 -20
  31. package/dist/admin/pages/subscriptions/views.d.ts +4 -0
  32. package/dist/admin-attempts-CRkxeVfQ.js +417 -0
  33. package/dist/admin-attempts-CRkxeVfQ.js.map +1 -0
  34. package/dist/{admin-auth-CTLBqp7N.js → admin-auth-C0pBH3kp.js} +2 -2
  35. package/dist/{admin-auth-CTLBqp7N.js.map → admin-auth-C0pBH3kp.js.map} +1 -1
  36. package/dist/{admin-badge-3zABrSBc.js → admin-badge-C_-j7ANF.js} +2 -2
  37. package/dist/{admin-badge-3zABrSBc.js.map → admin-badge-C_-j7ANF.js.map} +1 -1
  38. package/dist/{admin-button-FRNl7_Yf.js → admin-button-BV5MAL2H.js} +2 -2
  39. package/dist/{admin-button-FRNl7_Yf.js.map → admin-button-BV5MAL2H.js.map} +1 -1
  40. package/dist/{admin-capabilities-uSi2Pb2h.js → admin-capabilities-B3ZfkA49.js} +21 -13
  41. package/dist/admin-capabilities-B3ZfkA49.js.map +1 -0
  42. package/dist/{admin-card-YKPGmx5w.js → admin-card-DQ61c-kV.js} +2 -2
  43. package/dist/{admin-card-YKPGmx5w.js.map → admin-card-DQ61c-kV.js.map} +1 -1
  44. package/dist/admin-catalog-DAnsClai.js +867 -0
  45. package/dist/admin-catalog-DAnsClai.js.map +1 -0
  46. package/dist/{admin-cursor-pager-BGgOOq7s.js → admin-cursor-pager-dkNj-gb6.js} +22 -22
  47. package/dist/{admin-cursor-pager-BGgOOq7s.js.map → admin-cursor-pager-dkNj-gb6.js.map} +1 -1
  48. package/dist/admin-customer-search-DDMn_5Us.js +115 -0
  49. package/dist/admin-customer-search-DDMn_5Us.js.map +1 -0
  50. package/dist/{admin-customers-DFQ75ZBi.js → admin-customers-BMaugwpg.js} +24 -25
  51. package/dist/admin-customers-BMaugwpg.js.map +1 -0
  52. package/dist/admin-dashboard-DbbfrIOq.js +510 -0
  53. package/dist/admin-dashboard-DbbfrIOq.js.map +1 -0
  54. package/dist/{admin-data-table-DyYm4h_Y.js → admin-data-table-BjA8cBsr.js} +5 -5
  55. package/dist/{admin-data-table-DyYm4h_Y.js.map → admin-data-table-BjA8cBsr.js.map} +1 -1
  56. package/dist/admin-detail-BVJcnTO-.js +1361 -0
  57. package/dist/admin-detail-BVJcnTO-.js.map +1 -0
  58. package/dist/{admin-detail-CG3kLIDS.js → admin-detail-DO9wd12I.js} +130 -107
  59. package/dist/admin-detail-DO9wd12I.js.map +1 -0
  60. package/dist/{admin-detail-SLijWf4F.js → admin-detail-M7YFYOGN.js} +211 -210
  61. package/dist/{admin-detail-SLijWf4F.js.map → admin-detail-M7YFYOGN.js.map} +1 -1
  62. package/dist/admin-detail-sOLj-K-Y.js +336 -0
  63. package/dist/{admin-detail-wttCvrxI.js.map → admin-detail-sOLj-K-Y.js.map} +1 -1
  64. package/dist/admin-detail-uZ-eR2TT.js +292 -0
  65. package/dist/{admin-detail-BytmF-e3.js.map → admin-detail-uZ-eR2TT.js.map} +1 -1
  66. package/dist/{admin-dialog-BVx92baz.js → admin-dialog-BxRcYcQM.js} +3 -3
  67. package/dist/{admin-dialog-BVx92baz.js.map → admin-dialog-BxRcYcQM.js.map} +1 -1
  68. package/dist/{admin-dropdown-menu-BV7vxYr9.js → admin-dropdown-menu-DlyaKwyU.js} +2 -2
  69. package/dist/{admin-dropdown-menu-BV7vxYr9.js.map → admin-dropdown-menu-DlyaKwyU.js.map} +1 -1
  70. package/dist/{admin-dunning-D8lAP7OA.js → admin-dunning-CDy6aMAj.js} +2 -2
  71. package/dist/{admin-dunning-D8lAP7OA.js.map → admin-dunning-CDy6aMAj.js.map} +1 -1
  72. package/dist/{admin-fact-card-CTQyFmQY.js → admin-fact-card-2DujC_r3.js} +2 -2
  73. package/dist/{admin-fact-card-CTQyFmQY.js.map → admin-fact-card-2DujC_r3.js.map} +1 -1
  74. package/dist/{admin-utils-CuwG3SAt.js → admin-format-Bc4NWK0F.js} +491 -328
  75. package/dist/admin-format-Bc4NWK0F.js.map +1 -0
  76. package/dist/{admin-health-DWpONa-7.js → admin-health-DePsyIlc.js} +217 -196
  77. package/dist/admin-health-DePsyIlc.js.map +1 -0
  78. package/dist/{admin-imports-Dsd5QmAe.js → admin-imports-BrQH3u9M.js} +85 -86
  79. package/dist/{admin-imports-Dsd5QmAe.js.map → admin-imports-BrQH3u9M.js.map} +1 -1
  80. package/dist/{admin-input-DhYEd7Yp.js → admin-input-BZ2ExV_5.js} +2 -2
  81. package/dist/{admin-input-DhYEd7Yp.js.map → admin-input-BZ2ExV_5.js.map} +1 -1
  82. package/dist/{admin-label-DwUfUVm6.js → admin-label-DecDO0oV.js} +2 -2
  83. package/dist/{admin-label-DwUfUVm6.js.map → admin-label-DecDO0oV.js.map} +1 -1
  84. package/dist/{admin-linked-table-row-CqG_aCwd.js → admin-linked-table-row-ChxhVptQ.js} +3 -3
  85. package/dist/{admin-linked-table-row-CqG_aCwd.js.map → admin-linked-table-row-ChxhVptQ.js.map} +1 -1
  86. package/dist/{admin-map-dialog-DZuPq4UA.js → admin-map-dialog-CQmGOBMw.js} +12 -12
  87. package/dist/{admin-map-dialog-DZuPq4UA.js.map → admin-map-dialog-CQmGOBMw.js.map} +1 -1
  88. package/dist/admin-metering-OXGOVQ7e.js +1716 -0
  89. package/dist/{admin-metering-kGrQIiEX.js.map → admin-metering-OXGOVQ7e.js.map} +1 -1
  90. package/dist/{admin-missing-record-CjIQEv9L.js → admin-missing-record-B_9LpSIW.js} +4 -4
  91. package/dist/{admin-missing-record-CjIQEv9L.js.map → admin-missing-record-B_9LpSIW.js.map} +1 -1
  92. package/dist/admin-ops-BTSunx1i.js +357 -0
  93. package/dist/{admin-ops-B1Gwrsq6.js.map → admin-ops-BTSunx1i.js.map} +1 -1
  94. package/dist/{admin-orders-DRpUMK7N.js → admin-orders-LqlpQVFo.js} +59 -60
  95. package/dist/{admin-orders-DRpUMK7N.js.map → admin-orders-LqlpQVFo.js.map} +1 -1
  96. package/dist/{admin-parked-uH5dSPjL.js → admin-parked-Ch6mlS5f.js} +61 -62
  97. package/dist/{admin-parked-uH5dSPjL.js.map → admin-parked-Ch6mlS5f.js.map} +1 -1
  98. package/dist/{admin-payments-DFW5O19Q.js → admin-payments-yNntF4i4.js} +42 -42
  99. package/dist/{admin-payments-DFW5O19Q.js.map → admin-payments-yNntF4i4.js.map} +1 -1
  100. package/dist/{admin-price-detail-CaUekDWP.js → admin-price-detail-DvmcYr8B.js} +131 -132
  101. package/dist/admin-price-detail-DvmcYr8B.js.map +1 -0
  102. package/dist/{admin-price-format-BrXm8J1w.js → admin-price-format-Btdg11-J.js} +2 -2
  103. package/dist/{admin-price-format-BrXm8J1w.js.map → admin-price-format-Btdg11-J.js.map} +1 -1
  104. package/dist/admin-price-wizard-EFO3nBV8.js +376 -0
  105. package/dist/admin-price-wizard-EFO3nBV8.js.map +1 -0
  106. package/dist/{admin-proposals-BuPBTbX7.js → admin-proposals-CO0LKHM8.js} +119 -120
  107. package/dist/{admin-proposals-BuPBTbX7.js.map → admin-proposals-CO0LKHM8.js.map} +1 -1
  108. package/dist/admin-provider-prices-ZjQeEV1n.js +239 -0
  109. package/dist/{admin-provider-prices-BtyrGlSd.js.map → admin-provider-prices-ZjQeEV1n.js.map} +1 -1
  110. package/dist/admin-query-builder-DedekYUU.js +252 -0
  111. package/dist/admin-query-builder-DedekYUU.js.map +1 -0
  112. package/dist/{admin-range-picker-B1C1R9Yh.js → admin-range-picker-1WGFlYYw.js} +46 -24
  113. package/dist/admin-range-picker-1WGFlYYw.js.map +1 -0
  114. package/dist/admin-records-A2R52prt.js +389 -0
  115. package/dist/{admin-records-CZ_Q1j7i.js.map → admin-records-A2R52prt.js.map} +1 -1
  116. package/dist/admin-reports-ySY9v463.js +420 -0
  117. package/dist/admin-reports-ySY9v463.js.map +1 -0
  118. package/dist/{admin-select-CCliJ9d-.js → admin-select-CgZq2j0G.js} +2 -2
  119. package/dist/{admin-select-CCliJ9d-.js.map → admin-select-CgZq2j0G.js.map} +1 -1
  120. package/dist/admin-settings-kOW1nPGB.js +1818 -0
  121. package/dist/admin-settings-kOW1nPGB.js.map +1 -0
  122. package/dist/{admin-shared-Bozlh9cy.js → admin-shared-DoBOSwkv.js} +33 -34
  123. package/dist/{admin-shared-Bozlh9cy.js.map → admin-shared-DoBOSwkv.js.map} +1 -1
  124. package/dist/admin-signals-D_iWk2r5.js +124 -0
  125. package/dist/admin-signals-D_iWk2r5.js.map +1 -0
  126. package/dist/{admin-skeleton-CKxohm-g.js → admin-skeleton-DdqwXcr4.js} +2 -2
  127. package/dist/{admin-skeleton-CKxohm-g.js.map → admin-skeleton-DdqwXcr4.js.map} +1 -1
  128. package/dist/{admin-status-badge-BhHyBG8J.js → admin-status-badge-B8rjk6QR.js} +5 -3
  129. package/dist/admin-status-badge-B8rjk6QR.js.map +1 -0
  130. package/dist/{admin-subscriptions-VwEbVACW.js → admin-subscriptions-CjYPSPs-.js} +43 -38
  131. package/dist/admin-subscriptions-CjYPSPs-.js.map +1 -0
  132. package/dist/{admin-switch-CE0N-HwZ.js → admin-switch-CyYmt8wi.js} +2 -2
  133. package/dist/{admin-switch-CE0N-HwZ.js.map → admin-switch-CyYmt8wi.js.map} +1 -1
  134. package/dist/{admin-table-Ce6xyiwJ.js → admin-table-ByPfWNq8.js} +2 -2
  135. package/dist/{admin-table-Ce6xyiwJ.js.map → admin-table-ByPfWNq8.js.map} +1 -1
  136. package/dist/admin-tabs-DKa6QljL.js +45 -0
  137. package/dist/admin-tabs-DKa6QljL.js.map +1 -0
  138. package/dist/{admin-textarea-CBAshts8.js → admin-textarea-CQg__KGc.js} +2 -2
  139. package/dist/{admin-textarea-CBAshts8.js.map → admin-textarea-CQg__KGc.js.map} +1 -1
  140. package/dist/{admin-typed-confirm-dialog-C1kHdYgH.js → admin-typed-confirm-dialog-BvAYEh3H.js} +6 -6
  141. package/dist/{admin-typed-confirm-dialog-C1kHdYgH.js.map → admin-typed-confirm-dialog-BvAYEh3H.js.map} +1 -1
  142. package/dist/admin-widget-tile-DDI3eaRy.js +290 -0
  143. package/dist/admin-widget-tile-DDI3eaRy.js.map +1 -0
  144. package/dist/admin-widget-viz-Db9CQ2Sx.js +1084 -0
  145. package/dist/admin-widget-viz-Db9CQ2Sx.js.map +1 -0
  146. package/dist/admin.css +1 -1
  147. package/dist/admin.js +660 -609
  148. package/dist/admin.js.map +1 -1
  149. package/dist/buy-button.d.ts +4 -2
  150. package/dist/cart.d.ts +4 -2
  151. package/dist/client/client.d.ts +16 -3
  152. package/dist/client/generated/error-codes.d.ts +1 -1
  153. package/dist/client/generated/routes.d.ts +296 -181
  154. package/dist/client/generated/wire.d.ts +509 -277
  155. package/dist/client/index.d.ts +1 -1
  156. package/dist/client/types.d.ts +70 -6
  157. package/dist/{client-BrURpRWz.js → client-D8qT6xjo.js} +84 -44
  158. package/dist/client-D8qT6xjo.js.map +1 -0
  159. package/dist/client.js +1 -1
  160. package/dist/components/billing-fields.d.ts +5 -3
  161. package/dist/components/platform-card-form.d.ts +3 -1
  162. package/dist/{hooks-Bbp1RWgw.js → hooks-CX09fAJA.js} +86 -60
  163. package/dist/hooks-CX09fAJA.js.map +1 -0
  164. package/dist/index.d.ts +1 -1
  165. package/dist/index.js +842 -779
  166. package/dist/index.js.map +1 -1
  167. package/dist/lib/billing-fields.d.ts +15 -0
  168. package/dist/lib/billing.d.ts +23 -5
  169. package/dist/product-list.d.ts +4 -2
  170. package/dist/react/config.d.ts +10 -2
  171. package/dist/react/index.d.ts +1 -1
  172. package/dist/react.js +1 -1
  173. package/dist/styles.css +1 -1
  174. package/dist/tokenized-card-form.d.ts +10 -2
  175. package/docs/payment-form-contract.md +6 -15
  176. package/package.json +6 -6
  177. package/dist/admin/lib/api/copilot.d.ts +0 -6
  178. package/dist/admin/pages/catalog/copilot-panel.d.ts +0 -4
  179. package/dist/admin-attempts-Cs2u-BLY.js +0 -418
  180. package/dist/admin-attempts-Cs2u-BLY.js.map +0 -1
  181. package/dist/admin-capabilities-uSi2Pb2h.js.map +0 -1
  182. package/dist/admin-catalog-DB5lr46V.js +0 -1096
  183. package/dist/admin-catalog-DB5lr46V.js.map +0 -1
  184. package/dist/admin-customers-DFQ75ZBi.js.map +0 -1
  185. package/dist/admin-dashboard-Q_4-OFsE.js +0 -461
  186. package/dist/admin-dashboard-Q_4-OFsE.js.map +0 -1
  187. package/dist/admin-detail-BytmF-e3.js +0 -293
  188. package/dist/admin-detail-CG3kLIDS.js.map +0 -1
  189. package/dist/admin-detail-RS0o4-Cq.js +0 -1351
  190. package/dist/admin-detail-RS0o4-Cq.js.map +0 -1
  191. package/dist/admin-detail-wttCvrxI.js +0 -337
  192. package/dist/admin-format-D9Ablh0P.js +0 -169
  193. package/dist/admin-format-D9Ablh0P.js.map +0 -1
  194. package/dist/admin-health-DWpONa-7.js.map +0 -1
  195. package/dist/admin-metering-kGrQIiEX.js +0 -1717
  196. package/dist/admin-ops-B1Gwrsq6.js +0 -358
  197. package/dist/admin-price-detail-CaUekDWP.js.map +0 -1
  198. package/dist/admin-price-wizard-CCejN6lZ.js +0 -355
  199. package/dist/admin-price-wizard-CCejN6lZ.js.map +0 -1
  200. package/dist/admin-provider-prices-BtyrGlSd.js +0 -240
  201. package/dist/admin-range-picker-B1C1R9Yh.js.map +0 -1
  202. package/dist/admin-records-CZ_Q1j7i.js +0 -390
  203. package/dist/admin-reports-ZDEVF7aC.js +0 -319
  204. package/dist/admin-reports-ZDEVF7aC.js.map +0 -1
  205. package/dist/admin-settings-HBiilJTI.js +0 -1818
  206. package/dist/admin-settings-HBiilJTI.js.map +0 -1
  207. package/dist/admin-status-badge-BhHyBG8J.js.map +0 -1
  208. package/dist/admin-subscriptions-VwEbVACW.js.map +0 -1
  209. package/dist/admin-tabs-BPfOyBa6.js +0 -156
  210. package/dist/admin-tabs-BPfOyBa6.js.map +0 -1
  211. package/dist/admin-utils-CuwG3SAt.js.map +0 -1
  212. package/dist/admin-widget-viz-Dd1Fjd_j.js +0 -643
  213. package/dist/admin-widget-viz-Dd1Fjd_j.js.map +0 -1
  214. package/dist/client-BrURpRWz.js.map +0 -1
  215. package/dist/hooks-Bbp1RWgw.js.map +0 -1
@@ -445,7 +445,8 @@ function E(e) {
445
445
  var D = [
446
446
  "kind",
447
447
  "owner",
448
- "category",
448
+ "outcome",
449
+ "decline_cause",
449
450
  "reason",
450
451
  "response_code",
451
452
  "card_entry",
@@ -505,6 +506,7 @@ function j(e) {
505
506
  signal: r
506
507
  }), s = (e, n) => t("/admin/product-access", {
507
508
  method: "POST",
509
+ headers: { "Idempotency-Key": crypto.randomUUID() },
508
510
  body: { items: [{
509
511
  customer_id: e,
510
512
  product_id: n.productId,
@@ -608,26 +610,19 @@ function j(e) {
608
610
  }), N = (e) => t("/catalog/prices", {
609
611
  method: "POST",
610
612
  body: e
611
- }), P = (e, n = !1, r) => t(`/catalog/prices/${encodeURIComponent(e)}`, {
612
- query: n ? { verify: !0 } : void 0,
613
- signal: r
614
- }), F = async (e) => {
615
- let n = (await t("/catalog/products", { query: { keys: e } })).data[0];
616
- if (!n) throw Error(`No product ${e}`);
617
- return n;
618
- }, I = (e, n) => t(`/catalog/prices/${encodeURIComponent(e)}`, {
613
+ }), P = (e, n = !1, r) => t(`/catalog/prices/${encodeURIComponent(e)}${n ? "/verification" : ""}`, { signal: r }), F = (e, n) => t(`/catalog/prices/${encodeURIComponent(e)}`, {
619
614
  method: "PATCH",
620
615
  body: n
621
- }), L = (e, n) => t(`/catalog/prices/${encodeURIComponent(e)}/history`, {
616
+ }), I = (e, n) => t(`/catalog/prices/${encodeURIComponent(e)}/history`, {
622
617
  query: { limit: 500 },
623
618
  signal: n
624
- }), R = (e, n) => t("/catalog/price-migrations/preview", {
619
+ }), L = (e, n) => t("/catalog/price-migrations/preview", {
625
620
  method: "POST",
626
621
  body: {
627
622
  product_key: e,
628
623
  price_key: n
629
624
  }
630
- }), z = (e, n, r, i) => t("/catalog/price-migrations", {
625
+ }), R = (e, n, r, i) => t("/catalog/price-migrations", {
631
626
  method: "POST",
632
627
  body: {
633
628
  product_key: e,
@@ -635,56 +630,56 @@ function j(e) {
635
630
  to_price_id: r,
636
631
  effective_at: i
637
632
  }
638
- }), B = (e, n, r = 20, i) => t("/catalog/price-migrations", {
633
+ }), z = (e, n, r = 20, i) => t("/catalog/price-migrations", {
639
634
  query: {
640
635
  product_key: e,
641
636
  price_key: n,
642
637
  limit: r
643
638
  },
644
639
  signal: i
645
- }), V = (e) => t(`/catalog/price-migrations/${e}/cancel`, { method: "POST" }), H = (e, n = !1) => t("/catalog/apply", {
640
+ }), B = (e) => t(`/catalog/price-migrations/${e}/cancel`, { method: "POST" }), V = (e, n = !1) => t("/catalog/apply", {
646
641
  method: "POST",
647
642
  rawBody: e,
648
643
  headers: { "Content-Type": "application/yaml" },
649
644
  ...n ? { query: { force: "true" } } : {}
650
- }), U = (e, n, r) => t("/merchant/findings", {
645
+ }), H = (e, n, r) => t("/merchant/findings", {
651
646
  query: {
652
647
  ...e,
653
648
  limit: n
654
649
  },
655
650
  signal: r
656
- }), W = (e) => t(`/merchant/findings/${e}`), G = (e, n, r) => t(`/merchant/findings/${e}/resolve`, {
651
+ }), ee = (e) => t(`/merchant/findings/${e}`), te = (e, n, r) => t(`/merchant/findings/${e}/resolve`, {
657
652
  method: "POST",
658
653
  body: {
659
654
  outcome: n,
660
655
  notes: r
661
656
  }
662
- }), K = (e, n) => t("/merchant/destructive-holds", {
657
+ }), ne = (e, n) => t("/merchant/destructive-holds", {
663
658
  query: {
664
659
  limit: 100,
665
660
  cursor: e
666
661
  },
667
662
  signal: n
668
- }), q = (e, n) => t(`/merchant/destructive-holds/${encodeURIComponent(e)}/clear`, {
663
+ }), re = (e, n) => t(`/merchant/destructive-holds/${encodeURIComponent(e)}/clear`, {
669
664
  method: "POST",
670
665
  body: { reason: n }
671
- }), ee = (e) => t("/merchant/configuration", { signal: e }), J = (e) => t("/merchant/configuration", {
666
+ }), U = (e) => t("/merchant/configuration", { signal: e }), ie = (e) => t("/merchant/configuration", {
672
667
  method: "PATCH",
673
668
  body: e
674
- }), te = (e) => t("/merchant/psps?limit=500", { signal: e }), ne = (e) => t("/merchant/custodians", { signal: e }), re = (e, n) => t(`/admin/customers/${encodeURIComponent(e)}/payment-methods/${encodeURIComponent(n)}`, { method: "DELETE" }), Y = (e, n) => t(`/merchant/custodians/${encodeURIComponent(e)}`, {
669
+ }), W = (e) => t("/merchant/psps?limit=500", { signal: e }), ae = (e) => t("/merchant/custodians", { signal: e }), oe = (e, n) => t(`/admin/customers/${encodeURIComponent(e)}/payment-methods/${encodeURIComponent(n)}`, { method: "DELETE" }), se = (e, n) => t(`/merchant/custodians/${encodeURIComponent(e)}`, {
675
670
  method: "PUT",
676
671
  body: n
677
- }), X = async (e) => (await ae(e)).rails, Z = (e) => t("/merchant/psps", {
672
+ }), G = async (e) => (await ce(e)).rails, K = (e) => t("/merchant/psps", {
678
673
  method: "POST",
679
674
  body: e
680
- }), Q = (e, n) => t(`/merchant/psps/${encodeURIComponent(e)}`, {
675
+ }), q = (e, n) => t(`/merchant/psps/${encodeURIComponent(e)}`, {
681
676
  method: "PATCH",
682
677
  body: n
683
- }), ie = (e, n) => t("/merchant/psps/routing-preview", {
678
+ }), J = (e, n) => t("/merchant/psps/routing-preview", {
684
679
  method: "POST",
685
680
  body: e,
686
681
  signal: n
687
- }), ae = (e) => t("/config", { signal: e });
682
+ }), ce = (e) => t("/config", { signal: e });
688
683
  return {
689
684
  listCustomers: n,
690
685
  getCustomer: r,
@@ -719,30 +714,29 @@ function j(e) {
719
714
  listPrices: M,
720
715
  createPrice: N,
721
716
  getPrice: P,
722
- getProductByKey: F,
723
- updatePrice: I,
724
- getPriceHistory: L,
725
- previewPriceMigration: R,
726
- createPriceMigration: z,
727
- listPriceMigrations: B,
728
- cancelPriceMigration: V,
729
- applyCatalog: H,
730
- listFindings: U,
731
- getFinding: W,
732
- resolveFinding: G,
733
- listDestructiveHolds: K,
734
- clearDestructiveHold: q,
735
- getMerchantConfiguration: ee,
736
- updateMerchantConfiguration: J,
737
- listPSPs: te,
738
- listRails: X,
739
- createPSP: Z,
740
- listCustodians: ne,
741
- putCustodian: Y,
742
- deleteCustomerPaymentMethod: re,
743
- updatePSP: Q,
744
- previewPSPRouting: ie,
745
- getConfig: ae,
717
+ updatePrice: F,
718
+ getPriceHistory: I,
719
+ previewPriceMigration: L,
720
+ createPriceMigration: R,
721
+ listPriceMigrations: z,
722
+ cancelPriceMigration: B,
723
+ applyCatalog: V,
724
+ listFindings: H,
725
+ getFinding: ee,
726
+ resolveFinding: te,
727
+ listDestructiveHolds: ne,
728
+ clearDestructiveHold: re,
729
+ getMerchantConfiguration: U,
730
+ updateMerchantConfiguration: ie,
731
+ listPSPs: W,
732
+ listRails: G,
733
+ createPSP: K,
734
+ listCustodians: ae,
735
+ putCustodian: se,
736
+ deleteCustomerPaymentMethod: oe,
737
+ updatePSP: q,
738
+ previewPSPRouting: J,
739
+ getConfig: ce,
746
740
  getAdminAccess: (e) => t("/admin/access", { signal: e }),
747
741
  updateCustomer: (e, n) => t(`/admin/customers/${e}`, {
748
742
  method: "PATCH",
@@ -761,15 +755,18 @@ function j(e) {
761
755
  };
762
756
  }
763
757
  // src/admin/lib/api/metrics.ts
764
- var M = [
758
+ var M = (e) => e === "heading" || e === "programs", N = [
759
+ "kpi",
765
760
  "stat",
766
761
  "line",
767
762
  "area",
768
763
  "bar",
769
764
  "donut",
770
- "table"
765
+ "table",
766
+ "cohort",
767
+ "funnel"
771
768
  ];
772
- function N(e) {
769
+ function P(e) {
773
770
  let { api: t } = e;
774
771
  return {
775
772
  metricsQuery: (e, n) => t("/metrics/query", {
@@ -778,20 +775,14 @@ function N(e) {
778
775
  signal: n
779
776
  }),
780
777
  getDashboard: (e) => t("/metrics/dashboard", { signal: e }),
778
+ getMetricsSchema: (e) => t("/metrics/schema", { signal: e }),
781
779
  putDashboard: (e) => t("/merchant/dashboard", {
782
780
  method: "PUT",
783
781
  body: { widgets: e }
784
- })
782
+ }),
783
+ listDisputePrograms: (e, n) => t(`/metrics/dispute-programs${e ? `?at=${encodeURIComponent(e)}` : ""}`, { signal: n })
785
784
  };
786
785
  }
787
- // src/admin/lib/api/copilot.ts
788
- function P(e) {
789
- let { api: t } = e;
790
- return { askCatalog: (e) => t("/console/catalog/ask", {
791
- method: "POST",
792
- body: { question: e }
793
- }) };
794
- }
795
786
  // src/admin/lib/api/credit-endpoints.ts
796
787
  var F = (e) => `/admin/customers/${encodeURIComponent(e)}`;
797
788
  function I(e) {
@@ -961,7 +952,6 @@ function B(e) {
961
952
  let t = j(e);
962
953
  return {
963
954
  ...t,
964
- ...N(e),
965
955
  ...P(e),
966
956
  ...I(e),
967
957
  ...L(e),
@@ -980,7 +970,7 @@ var V = {
980
970
  let n = t.charAt(0).toUpperCase() + t.slice(1);
981
971
  return /[.!?]$/.test(n) ? n : `${n}.`;
982
972
  };
983
- function U(e) {
973
+ function ee(e) {
984
974
  if (!(e instanceof x)) return { text: H(e instanceof Error && e.message ? e.message : b.errors.generic) };
985
975
  let t = e.code;
986
976
  return {
@@ -989,7 +979,7 @@ function U(e) {
989
979
  };
990
980
  }
991
981
  // src/admin/lib/toast.ts
992
- function W(e) {
982
+ function te(e) {
993
983
  let t = (t) => (n, r) => t(n, {
994
984
  ...r,
995
985
  toasterId: e
@@ -1001,7 +991,7 @@ function W(e) {
1001
991
  warning: t(u.warning)
1002
992
  });
1003
993
  }
1004
- function G(e) {
994
+ function ne(e) {
1005
995
  function t(t, n) {
1006
996
  if (t instanceof x) {
1007
997
  if (t.code === "revision_mismatch") {
@@ -1013,7 +1003,7 @@ function G(e) {
1013
1003
  return;
1014
1004
  }
1015
1005
  }
1016
- let { text: r, code: i } = U(t);
1006
+ let { text: r, code: i } = ee(t);
1017
1007
  e.error(`Couldn't ${n.charAt(0).toLowerCase()}${n.slice(1)}`, { description: i ? `${r} Code: ${i}.` : r });
1018
1008
  }
1019
1009
  function n(t) {
@@ -1025,17 +1015,17 @@ function G(e) {
1025
1015
  };
1026
1016
  }
1027
1017
  // src/admin/lib/queries.ts
1028
- function K(e) {
1018
+ function re(e) {
1029
1019
  let t = e.rows[0] ?? [];
1030
1020
  return Object.fromEntries(e.columns.map((e, n) => [e.name, t[n] ?? null]));
1031
1021
  }
1032
- async function q(e, t) {
1022
+ async function U(e, t) {
1033
1023
  return {
1034
1024
  data: await T((n) => e(n, t), t),
1035
1025
  next_cursor: null
1036
1026
  };
1037
1027
  }
1038
- var ee = (e) => ({
1028
+ var ie = (e) => ({
1039
1029
  merchant: () => e(),
1040
1030
  customers: () => [...e(), "customers"],
1041
1031
  customer: (t) => [
@@ -1074,18 +1064,18 @@ var ee = (e) => ({
1074
1064
  ops: () => [...e(), "ops"],
1075
1065
  dashboard: () => [...e(), "dashboard"],
1076
1066
  notifications: () => [...e(), "notifications"]
1077
- }), J = (e) => e ? { errorAction: e } : void 0;
1078
- function te(e, t) {
1079
- let { queryRoot: n } = e, { getCustomer: r, getMerchantConfiguration: i, getPayment: a, getPaymentAttempt: o, getPrice: c, getPriceHistory: u, getProduct: d, getRenewal: f, getSubscription: p, getUsageMeter: m, listCustomerEntitlements: h, listCustomerPaymentMethods: g, listCustomerProductAccess: _, listCustomers: v, listFindings: y, listDestructiveHolds: b, listPaymentAttempts: x, listPSPs: S, listRails: C, previewPSPRouting: w, listPayments: E, listPrices: D, listProducts: O, listRenewals: k, listPriceMigrations: A, listSubscriptionChangeOptions: j, listSubscriptions: M, listUsageMeters: N, getAdminAccess: P, getConfig: F, listWebhooks: I, getDashboard: L, metricsQuery: R } = t, z = n, B = ee(z);
1067
+ }), W = (e) => e ? { errorAction: e } : void 0;
1068
+ function ae(e, t) {
1069
+ let { queryRoot: n } = e, { getCustomer: r, getMerchantConfiguration: i, getPayment: a, getPaymentAttempt: o, getPrice: c, getPriceHistory: u, getProduct: d, getRenewal: f, getSubscription: p, getUsageMeter: m, listCustomerEntitlements: h, listCustomerPaymentMethods: g, listCustomerProductAccess: _, listCustomers: v, listFindings: y, listDestructiveHolds: b, listPaymentAttempts: x, listPSPs: S, listRails: C, previewPSPRouting: w, listPayments: E, listPrices: D, listProducts: O, listRenewals: k, listPriceMigrations: A, listSubscriptionChangeOptions: j, listSubscriptions: M, listUsageMeters: N, getAdminAccess: P, getConfig: F, listWebhooks: I, getDashboard: L, getMetricsSchema: R, metricsQuery: z, listDisputePrograms: B } = t, V = n, H = ie(V);
1080
1070
  return {
1081
- queryKeys: B,
1071
+ queryKeys: H,
1082
1072
  merchantQueryKeys: () => {
1083
- let e = z();
1084
- return ee(() => e);
1073
+ let e = V();
1074
+ return ie(() => e);
1085
1075
  },
1086
1076
  adminQueries: {
1087
1077
  customers: (e, t, n) => l({
1088
- queryKey: [...B.customers(), {
1078
+ queryKey: [...H.customers(), {
1089
1079
  search: e,
1090
1080
  limit: t,
1091
1081
  cursor: n
@@ -1095,13 +1085,13 @@ function te(e, t) {
1095
1085
  meta: { errorAction: "Load customers" }
1096
1086
  }),
1097
1087
  customer: (e) => l({
1098
- queryKey: B.customer(e),
1088
+ queryKey: H.customer(e),
1099
1089
  queryFn: ({ signal: t }) => r(e, t),
1100
1090
  enabled: !!e
1101
1091
  }),
1102
1092
  customerSubscriptions: (e, t, n) => l({
1103
1093
  queryKey: [
1104
- ...B.customer(e),
1094
+ ...H.customer(e),
1105
1095
  "subscriptions",
1106
1096
  {
1107
1097
  limit: t,
@@ -1115,7 +1105,7 @@ function te(e, t) {
1115
1105
  }),
1116
1106
  customerPayments: (e, t, n) => l({
1117
1107
  queryKey: [
1118
- ...B.customer(e),
1108
+ ...H.customer(e),
1119
1109
  "payments",
1120
1110
  {
1121
1111
  limit: t,
@@ -1132,7 +1122,7 @@ function te(e, t) {
1132
1122
  }),
1133
1123
  customerPaymentMethodsPage: (e, t, n) => l({
1134
1124
  queryKey: [
1135
- ...B.customer(e),
1125
+ ...H.customer(e),
1136
1126
  "payment-methods",
1137
1127
  {
1138
1128
  limit: t,
@@ -1149,7 +1139,7 @@ function te(e, t) {
1149
1139
  }),
1150
1140
  customerEntitlements: (e, t, n) => l({
1151
1141
  queryKey: [
1152
- ...B.customer(e),
1142
+ ...H.customer(e),
1153
1143
  "entitlements",
1154
1144
  {
1155
1145
  limit: t,
@@ -1166,7 +1156,7 @@ function te(e, t) {
1166
1156
  }),
1167
1157
  customerProductAccess: (e, t, n) => l({
1168
1158
  queryKey: [
1169
- ...B.customer(e),
1159
+ ...H.customer(e),
1170
1160
  "product-access",
1171
1161
  {
1172
1162
  limit: t,
@@ -1182,7 +1172,7 @@ function te(e, t) {
1182
1172
  meta: { errorAction: "Load product access" }
1183
1173
  }),
1184
1174
  subscriptions: (e, t, n) => l({
1185
- queryKey: [...B.subscriptions(), {
1175
+ queryKey: [...H.subscriptions(), {
1186
1176
  filters: e,
1187
1177
  limit: t,
1188
1178
  cursor: n
@@ -1192,17 +1182,17 @@ function te(e, t) {
1192
1182
  meta: { errorAction: "Load subscriptions" }
1193
1183
  }),
1194
1184
  subscription: (e) => l({
1195
- queryKey: B.subscription(e),
1185
+ queryKey: H.subscription(e),
1196
1186
  queryFn: ({ signal: t }) => p(e, t),
1197
1187
  enabled: !!e
1198
1188
  }),
1199
1189
  subscriptionChangeOptions: (e) => l({
1200
- queryKey: [...B.subscription(e), "change-options"],
1190
+ queryKey: [...H.subscription(e), "change-options"],
1201
1191
  queryFn: ({ signal: t }) => j(e, t),
1202
1192
  staleTime: 6e4
1203
1193
  }),
1204
1194
  customerPaymentMethods: (e) => l({
1205
- queryKey: [...B.customer(e ?? "unselected"), "payment-methods"],
1195
+ queryKey: [...H.customer(e ?? "unselected"), "payment-methods"],
1206
1196
  queryFn: ({ signal: t }) => T((n) => g(e, {
1207
1197
  limit: 100,
1208
1198
  cursor: n
@@ -1210,7 +1200,7 @@ function te(e, t) {
1210
1200
  enabled: !!e
1211
1201
  }),
1212
1202
  payments: (e, t, n) => l({
1213
- queryKey: [...B.payments(), {
1203
+ queryKey: [...H.payments(), {
1214
1204
  filters: e,
1215
1205
  limit: t,
1216
1206
  cursor: n
@@ -1223,12 +1213,12 @@ function te(e, t) {
1223
1213
  meta: { errorAction: "Load payments" }
1224
1214
  }),
1225
1215
  payment: (e) => l({
1226
- queryKey: B.payment(e),
1216
+ queryKey: H.payment(e),
1227
1217
  queryFn: ({ signal: t }) => a(e, t),
1228
1218
  enabled: !!e
1229
1219
  }),
1230
1220
  attempts: (e, t, n) => l({
1231
- queryKey: [...B.attempts(), {
1221
+ queryKey: [...H.attempts(), {
1232
1222
  filters: e,
1233
1223
  limit: t,
1234
1224
  cursor: n
@@ -1241,13 +1231,13 @@ function te(e, t) {
1241
1231
  meta: { errorAction: "Load payment attempts" }
1242
1232
  }),
1243
1233
  attempt: (e) => l({
1244
- queryKey: [...B.attempts(), e],
1234
+ queryKey: [...H.attempts(), e],
1245
1235
  queryFn: ({ signal: t }) => o(e, t),
1246
1236
  enabled: !!e,
1247
1237
  meta: { errorAction: "Load payment attempt" }
1248
1238
  }),
1249
1239
  cycles: (e, t, n) => l({
1250
- queryKey: [...B.cycles(), {
1240
+ queryKey: [...H.cycles(), {
1251
1241
  filters: e,
1252
1242
  limit: t,
1253
1243
  cursor: n
@@ -1260,7 +1250,7 @@ function te(e, t) {
1260
1250
  meta: { errorAction: "Load renewals" }
1261
1251
  }),
1262
1252
  cycle: (e) => l({
1263
- queryKey: [...B.cycles(), e],
1253
+ queryKey: [...H.cycles(), e],
1264
1254
  queryFn: ({ signal: t }) => f(e, t),
1265
1255
  enabled: !!e,
1266
1256
  meta: { errorAction: "Load renewal" }
@@ -1269,7 +1259,7 @@ function te(e, t) {
1269
1259
  let { limit: t = 100, cursor: n, errorAction: r } = e;
1270
1260
  return l({
1271
1261
  queryKey: [
1272
- ...B.catalog(),
1262
+ ...H.catalog(),
1273
1263
  "products",
1274
1264
  {
1275
1265
  limit: t,
@@ -1278,23 +1268,23 @@ function te(e, t) {
1278
1268
  ],
1279
1269
  queryFn: ({ signal: e }) => O(t, n, void 0, e),
1280
1270
  placeholderData: s,
1281
- meta: J(r)
1271
+ meta: W(r)
1282
1272
  });
1283
1273
  },
1284
1274
  allProducts: (e = {}) => l({
1285
1275
  queryKey: [
1286
- ...B.catalog(),
1276
+ ...H.catalog(),
1287
1277
  "products",
1288
1278
  "all"
1289
1279
  ],
1290
- queryFn: ({ signal: e }) => q((e, t) => O(500, e, void 0, t), e),
1291
- meta: J(e.errorAction)
1280
+ queryFn: ({ signal: e }) => U((e, t) => O(500, e, void 0, t), e),
1281
+ meta: W(e.errorAction)
1292
1282
  }),
1293
1283
  prices: (e = {}) => {
1294
1284
  let { productId: t, limit: n = 100, cursor: r, errorAction: i } = e;
1295
1285
  return l({
1296
1286
  queryKey: [
1297
- ...B.catalog(),
1287
+ ...H.catalog(),
1298
1288
  "prices",
1299
1289
  {
1300
1290
  productId: t,
@@ -1304,24 +1294,24 @@ function te(e, t) {
1304
1294
  ],
1305
1295
  queryFn: ({ signal: e }) => D(n, r, t, e),
1306
1296
  placeholderData: s,
1307
- meta: J(i)
1297
+ meta: W(i)
1308
1298
  });
1309
1299
  },
1310
1300
  allPrices: (e = {}) => l({
1311
1301
  queryKey: [
1312
- ...B.catalog(),
1302
+ ...H.catalog(),
1313
1303
  "prices",
1314
1304
  "all",
1315
1305
  { productId: e.productId }
1316
1306
  ],
1317
- queryFn: ({ signal: t }) => q((t, n) => D(500, t, e.productId, n), t),
1318
- meta: J(e.errorAction)
1307
+ queryFn: ({ signal: t }) => U((t, n) => D(500, t, e.productId, n), t),
1308
+ meta: W(e.errorAction)
1319
1309
  }),
1320
1310
  price: (e, t = {}) => {
1321
1311
  let { verify: n = !1, errorAction: r } = t;
1322
1312
  return l({
1323
1313
  queryKey: [
1324
- ...B.catalog(),
1314
+ ...H.catalog(),
1325
1315
  "prices",
1326
1316
  e,
1327
1317
  { verify: n }
@@ -1329,12 +1319,12 @@ function te(e, t) {
1329
1319
  queryFn: ({ signal: t }) => c(e, n, t),
1330
1320
  enabled: !!e,
1331
1321
  placeholderData: s,
1332
- meta: J(r)
1322
+ meta: W(r)
1333
1323
  });
1334
1324
  },
1335
1325
  product: (e) => l({
1336
1326
  queryKey: [
1337
- ...B.catalog(),
1327
+ ...H.catalog(),
1338
1328
  "products",
1339
1329
  e ?? "unselected"
1340
1330
  ],
@@ -1343,7 +1333,7 @@ function te(e, t) {
1343
1333
  }),
1344
1334
  priceHistory: (e) => l({
1345
1335
  queryKey: [
1346
- ...B.catalog(),
1336
+ ...H.catalog(),
1347
1337
  "prices",
1348
1338
  "history",
1349
1339
  e ?? "unselected"
@@ -1353,7 +1343,7 @@ function te(e, t) {
1353
1343
  }),
1354
1344
  priceMigrations: (e, t, n = 5) => l({
1355
1345
  queryKey: [
1356
- ...B.catalog(),
1346
+ ...H.catalog(),
1357
1347
  "price-migrations",
1358
1348
  {
1359
1349
  productKey: e,
@@ -1366,7 +1356,7 @@ function te(e, t) {
1366
1356
  }),
1367
1357
  pspRouting: (e) => l({
1368
1358
  queryKey: [
1369
- ...B.catalog(),
1359
+ ...H.catalog(),
1370
1360
  "prices",
1371
1361
  e,
1372
1362
  "routing"
@@ -1376,7 +1366,7 @@ function te(e, t) {
1376
1366
  meta: { errorAction: "Check purchase readiness" }
1377
1367
  }),
1378
1368
  usageMeters: (e = 200, t) => l({
1379
- queryKey: [...B.usageMeters(), {
1369
+ queryKey: [...H.usageMeters(), {
1380
1370
  limit: e,
1381
1371
  cursor: t
1382
1372
  }],
@@ -1385,19 +1375,19 @@ function te(e, t) {
1385
1375
  meta: { errorAction: "Load usage meters" }
1386
1376
  }),
1387
1377
  allUsageMeters: () => l({
1388
- queryKey: [...B.usageMeters(), "all"],
1389
- queryFn: ({ signal: e }) => q((e, t) => N(500, e, t), e),
1378
+ queryKey: [...H.usageMeters(), "all"],
1379
+ queryFn: ({ signal: e }) => U((e, t) => N(500, e, t), e),
1390
1380
  meta: { errorAction: "Load usage meters" }
1391
1381
  }),
1392
1382
  usageMeter: (e) => l({
1393
- queryKey: B.usageMeter(e),
1383
+ queryKey: H.usageMeter(e),
1394
1384
  queryFn: ({ signal: t }) => m(e, t),
1395
1385
  enabled: !!e,
1396
1386
  meta: { errorAction: "Load usage meter" }
1397
1387
  }),
1398
1388
  findings: (e = !0) => l({
1399
1389
  queryKey: [
1400
- ...B.ops(),
1390
+ ...H.ops(),
1401
1391
  "findings",
1402
1392
  { limit: 100 }
1403
1393
  ],
@@ -1406,48 +1396,45 @@ function te(e, t) {
1406
1396
  meta: { errorAction: "Load findings" }
1407
1397
  }),
1408
1398
  destructiveHolds: (e = !0) => l({
1409
- queryKey: [...B.ops(), "destructive-holds"],
1410
- queryFn: ({ signal: e }) => q((e, t) => b(e, t), e),
1399
+ queryKey: [...H.ops(), "destructive-holds"],
1400
+ queryFn: ({ signal: e }) => U((e, t) => b(e, t), e),
1411
1401
  enabled: e,
1412
1402
  meta: { errorAction: "Load holds" }
1413
1403
  }),
1414
1404
  findingSummary: () => l({
1415
1405
  queryKey: [
1416
- ...B.ops(),
1406
+ ...H.ops(),
1417
1407
  "findings",
1418
1408
  "summary"
1419
1409
  ],
1420
1410
  queryFn: async ({ signal: e }) => {
1421
- let t = K(await R({
1422
- measures: [
1423
- "open_findings",
1424
- "orphaned_members",
1425
- "freeloaders",
1426
- "duplicate_coverage"
1427
- ],
1411
+ let t = await z({
1412
+ measures: ["open_findings"],
1413
+ by: ["finding_group"],
1428
1414
  range: { last: "1d" }
1429
- }, e));
1415
+ }, e), n = {};
1416
+ for (let e of t.rows) n[String(e[0])] = Number(e[1] ?? 0);
1430
1417
  return {
1431
- total_open: Number(t.open_findings ?? 0),
1432
- orphaned_members: Number(t.orphaned_members ?? 0),
1433
- freeloaders: Number(t.freeloaders ?? 0),
1434
- duplicate_coverage: Number(t.duplicate_coverage ?? 0)
1418
+ total_open: Object.values(n).reduce((e, t) => e + t, 0),
1419
+ orphaned_members: n.orphaned ?? 0,
1420
+ freeloaders: n.freeloader ?? 0,
1421
+ duplicate_coverage: n.duplicate_coverage ?? 0
1435
1422
  };
1436
1423
  },
1437
1424
  meta: { errorAction: "Load the findings summary" }
1438
1425
  }),
1439
1426
  merchantConfiguration: (e) => l({
1440
- queryKey: B.settings(),
1427
+ queryKey: H.settings(),
1441
1428
  queryFn: ({ signal: e }) => i(e),
1442
- meta: J(e)
1429
+ meta: W(e)
1443
1430
  }),
1444
1431
  psps: () => l({
1445
- queryKey: [...B.settings(), "psps"],
1432
+ queryKey: [...H.settings(), "psps"],
1446
1433
  queryFn: ({ signal: e }) => S(e),
1447
1434
  meta: { errorAction: "Load PSPs" }
1448
1435
  }),
1449
1436
  rails: () => l({
1450
- queryKey: [...B.settings(), "rails"],
1437
+ queryKey: [...H.settings(), "rails"],
1451
1438
  queryFn: ({ signal: e }) => C(e),
1452
1439
  staleTime: Infinity,
1453
1440
  meta: { errorAction: "Load rails" }
@@ -1459,38 +1446,54 @@ function te(e, t) {
1459
1446
  meta: { errorAction: "Load configuration" }
1460
1447
  }),
1461
1448
  access: () => l({
1462
- queryKey: [...B.merchant(), "access"],
1449
+ queryKey: [...H.merchant(), "access"],
1463
1450
  queryFn: ({ signal: e }) => P(e),
1464
1451
  staleTime: 3e5,
1465
1452
  meta: { errorAction: "Load your access" }
1466
1453
  }),
1467
1454
  webhooks: () => l({
1468
- queryKey: [...B.alerts(), "webhooks"],
1455
+ queryKey: [...H.alerts(), "webhooks"],
1469
1456
  queryFn: ({ signal: e }) => I(e),
1470
1457
  meta: { errorAction: "Load webhooks" }
1471
1458
  }),
1472
1459
  dashboard: () => l({
1473
- queryKey: B.dashboard(),
1460
+ queryKey: H.dashboard(),
1474
1461
  queryFn: ({ signal: e }) => L(e),
1475
1462
  meta: { errorAction: "Load dashboard" }
1476
1463
  }),
1464
+ metricsSchema: (e = !0) => l({
1465
+ queryKey: [...H.dashboard(), "schema"],
1466
+ queryFn: ({ signal: e }) => R(e),
1467
+ staleTime: Infinity,
1468
+ enabled: e,
1469
+ meta: { errorAction: "Load the metrics schema" }
1470
+ }),
1477
1471
  widgetMetrics: (e) => l({
1478
1472
  queryKey: [
1479
- ...B.dashboard(),
1473
+ ...H.dashboard(),
1480
1474
  "metrics",
1481
1475
  e ?? "unselected"
1482
1476
  ],
1483
- queryFn: ({ signal: t }) => R(e, t),
1477
+ queryFn: ({ signal: t }) => z(e, t),
1484
1478
  enabled: !!e
1485
1479
  }),
1480
+ disputePrograms: (e) => l({
1481
+ queryKey: [
1482
+ ...H.dashboard(),
1483
+ "dispute-programs",
1484
+ e ?? "now"
1485
+ ],
1486
+ queryFn: ({ signal: t }) => B(e, t),
1487
+ meta: { errorAction: "Load dispute programs" }
1488
+ }),
1486
1489
  notifications: (e) => l({
1487
- queryKey: B.notifications(),
1490
+ queryKey: H.notifications(),
1488
1491
  queryFn: ({ signal: e }) => y({ status: "requires_review" }, 10, e),
1489
1492
  enabled: e
1490
1493
  }),
1491
1494
  unreadNotifications: () => l({
1492
- queryKey: [...B.notifications(), "count"],
1493
- queryFn: async ({ signal: e }) => Number(K(await R({
1495
+ queryKey: [...H.notifications(), "count"],
1496
+ queryFn: async ({ signal: e }) => Number(re(await z({
1494
1497
  measures: ["open_findings"],
1495
1498
  range: { last: "1d" },
1496
1499
  filters: { finding_status: ["requires_review"] }
@@ -1502,96 +1505,96 @@ function te(e, t) {
1502
1505
  };
1503
1506
  }
1504
1507
  // src/admin/lib/mutations.ts
1505
- var ne = 200, re = async (e) => {
1508
+ var oe = 200, se = async (e) => {
1506
1509
  let t = [], n;
1507
1510
  for (;;) {
1508
- let r = await e(ne, n);
1511
+ let r = await e(oe, n);
1509
1512
  if (t.push(...r.data), !r.next_cursor || r.data.length === 0) return t;
1510
1513
  n = r.next_cursor;
1511
1514
  }
1512
- }, Y = (e, t) => e.invalidateQueries({
1515
+ }, G = (e, t) => e.invalidateQueries({
1513
1516
  queryKey: t,
1514
1517
  exact: !0
1515
- }), X = (e, t) => () => Y(e, t), Z = (e, t) => () => e.invalidateQueries({ queryKey: t }), Q = (e, ...t) => (n) => {
1518
+ }), K = (e, t) => () => G(e, t), q = (e, t) => () => e.invalidateQueries({ queryKey: t }), J = (e, ...t) => (n) => {
1516
1519
  n instanceof x && n.code === "revision_mismatch" && Promise.all(t.map((t) => e.invalidateQueries({ queryKey: t })));
1517
1520
  };
1518
- function ie(e, t, n) {
1519
- let { selectedMerchant: r } = e, { askCatalog: i, cancelPriceMigration: a, cancelSubscription: o, changeSubscriptionPaymentMethod: s, changeSubscription: l, createPrice: u, createProduct: d, createWebhook: f, createPSP: p, deleteWebhook: m, getCustomer: h, getProductByKey: g, grantProductAccess: _, listCustomers: v, listPayments: y, listSubscriptions: b, putUsageMeterRateCard: S, updatePSP: C, putUsageMeter: w, previewPriceMigration: E, previewSubscriptionChange: D, applyCatalog: O, refundPayment: k, createPriceMigration: A, resolveFinding: j, clearDestructiveHold: M, resumeSubscription: N, revokeProductAccess: P, updateCustomer: F, updateMerchantConfiguration: I, updatePrice: L, updateProduct: R, updateWebhook: z, putDashboard: B } = t, { adminQueries: V, merchantQueryKeys: H } = n, U = (e) => (t) => {
1520
- t instanceof x && t.merchantConfigReadOnly && e.invalidateQueries({ queryKey: V.config().queryKey });
1521
- }, W = (e, t) => () => Promise.all([Y(e, [...t.alerts(), "webhooks"]), Y(e, t.settings())]);
1521
+ function ce(e, t, n) {
1522
+ let { selectedMerchant: r } = e, { cancelPriceMigration: i, cancelSubscription: a, changeSubscriptionPaymentMethod: o, changeSubscription: s, createPrice: l, createProduct: u, createWebhook: d, createPSP: f, deleteWebhook: p, getCustomer: m, grantProductAccess: h, listCustomers: g, listPayments: _, listSubscriptions: v, putUsageMeterRateCard: y, updatePSP: b, putUsageMeter: S, previewPriceMigration: C, previewSubscriptionChange: w, applyCatalog: E, refundPayment: D, createPriceMigration: O, resolveFinding: k, clearDestructiveHold: A, resumeSubscription: j, revokeProductAccess: M, updateCustomer: N, updateMerchantConfiguration: P, updatePrice: F, updateProduct: I, updateWebhook: L, putDashboard: R } = t, { adminQueries: z, merchantQueryKeys: B } = n, V = (e) => (t) => {
1523
+ t instanceof x && t.merchantConfigReadOnly && e.invalidateQueries({ queryKey: z.config().queryKey });
1524
+ }, H = (e, t) => () => Promise.all([G(e, [...t.alerts(), "webhooks"]), G(e, t.settings())]);
1522
1525
  return { adminMutations: {
1523
1526
  saveDashboard: (e) => {
1524
- let t = H().dashboard();
1527
+ let t = B().dashboard();
1525
1528
  return c({
1526
1529
  mutationKey: [...t, "save"],
1527
- mutationFn: (e) => B(e),
1530
+ mutationFn: (e) => R(e),
1528
1531
  onSuccess: (n) => e.setQueryData(t, n)
1529
1532
  });
1530
1533
  },
1531
1534
  findCustomers: () => {
1532
- let e = H().customers();
1535
+ let e = B().customers();
1533
1536
  return c({
1534
1537
  mutationKey: [...e, "find"],
1535
- mutationFn: async (e) => (await v(e, 9, "")).data
1538
+ mutationFn: async (e) => (await g(e, 9, "")).data
1536
1539
  });
1537
1540
  },
1538
1541
  exportCustomers: () => {
1539
- let e = H().customers();
1542
+ let e = B().customers();
1540
1543
  return c({
1541
1544
  mutationKey: [...e, "export"],
1542
- mutationFn: (e) => re((t, n) => v(e, t, n ?? ""))
1545
+ mutationFn: (e) => se((t, n) => g(e, t, n ?? ""))
1543
1546
  });
1544
1547
  },
1545
1548
  exportSubscriptions: () => {
1546
- let e = H().subscriptions();
1549
+ let e = B().subscriptions();
1547
1550
  return c({
1548
1551
  mutationKey: [...e, "export"],
1549
- mutationFn: (e) => re((t, n) => b(e, t, n))
1552
+ mutationFn: (e) => se((t, n) => v(e, t, n))
1550
1553
  });
1551
1554
  },
1552
1555
  exportPayments: () => {
1553
- let e = H().payments();
1556
+ let e = B().payments();
1554
1557
  return c({
1555
1558
  mutationKey: [...e, "export"],
1556
- mutationFn: (e) => T((t) => y(e, {
1557
- limit: ne,
1559
+ mutationFn: (e) => T((t) => _(e, {
1560
+ limit: oe,
1558
1561
  cursor: t
1559
1562
  }))
1560
1563
  });
1561
1564
  },
1562
1565
  resolveFinding: (e) => {
1563
- let t = H().ops();
1566
+ let t = B().ops();
1564
1567
  return c({
1565
1568
  mutationKey: [
1566
1569
  ...t,
1567
1570
  "findings",
1568
1571
  "resolve"
1569
1572
  ],
1570
- mutationFn: ({ id: e, outcome: t, notes: n }) => j(e, t, n),
1571
- onSuccess: Z(e, t)
1573
+ mutationFn: ({ id: e, outcome: t, notes: n }) => k(e, t, n),
1574
+ onSuccess: q(e, t)
1572
1575
  });
1573
1576
  },
1574
1577
  clearDestructiveHold: (e) => {
1575
- let t = H().ops();
1578
+ let t = B().ops();
1576
1579
  return c({
1577
1580
  mutationKey: [
1578
1581
  ...t,
1579
1582
  "destructive-holds",
1580
1583
  "clear"
1581
1584
  ],
1582
- mutationFn: ({ id: e, reason: t }) => M(e, t),
1583
- onSuccess: Z(e, t)
1585
+ mutationFn: ({ id: e, reason: t }) => A(e, t),
1586
+ onSuccess: q(e, t)
1584
1587
  });
1585
1588
  },
1586
1589
  refundPayment: (e, t, n, r) => {
1587
- let i = H(), a = i.payments(), o = n ? i.customer(n) : void 0, s = r ? i.subscription(r) : void 0;
1590
+ let i = B(), a = i.payments(), o = n ? i.customer(n) : void 0, s = r ? i.subscription(r) : void 0;
1588
1591
  return c({
1589
1592
  mutationKey: [
1590
1593
  ...a,
1591
1594
  t,
1592
1595
  "refund"
1593
1596
  ],
1594
- mutationFn: ({ amount: e, reason: n, revokeAccess: r }) => k(t, e, n, r),
1597
+ mutationFn: ({ amount: e, reason: n, revokeAccess: r }) => D(t, e, n, r),
1595
1598
  onSuccess: () => Promise.all([
1596
1599
  e.invalidateQueries({ queryKey: a }),
1597
1600
  ...o ? [e.invalidateQueries({ queryKey: o })] : [],
@@ -1600,43 +1603,43 @@ function ie(e, t, n) {
1600
1603
  });
1601
1604
  },
1602
1605
  cancelSubscription: (e, t, n) => {
1603
- let r = H(), i = r.subscriptions(), a = n ? r.customer(n) : void 0;
1606
+ let r = B(), i = r.subscriptions(), o = n ? r.customer(n) : void 0;
1604
1607
  return c({
1605
1608
  mutationKey: [
1606
1609
  ...i,
1607
1610
  t,
1608
1611
  "cancel"
1609
1612
  ],
1610
- mutationFn: ({ reason: e, revokeAccess: n }) => o(t, e, n),
1611
- onSuccess: () => Promise.all([e.invalidateQueries({ queryKey: i }), ...a ? [e.invalidateQueries({ queryKey: a })] : []])
1613
+ mutationFn: ({ reason: e, revokeAccess: n }) => a(t, e, n),
1614
+ onSuccess: () => Promise.all([e.invalidateQueries({ queryKey: i }), ...o ? [e.invalidateQueries({ queryKey: o })] : []])
1612
1615
  });
1613
1616
  },
1614
1617
  resumeSubscription: (e, t, n) => {
1615
- let r = H(), i = r.subscriptions(), a = n ? r.customer(n) : void 0;
1618
+ let r = B(), i = r.subscriptions(), a = n ? r.customer(n) : void 0;
1616
1619
  return c({
1617
1620
  mutationKey: [
1618
1621
  ...i,
1619
1622
  t,
1620
1623
  "resume"
1621
1624
  ],
1622
- mutationFn: () => N(t),
1625
+ mutationFn: () => j(t),
1623
1626
  onSuccess: () => Promise.all([e.invalidateQueries({ queryKey: i }), ...a ? [e.invalidateQueries({ queryKey: a })] : []])
1624
1627
  });
1625
1628
  },
1626
1629
  changeSubscriptionPaymentMethod: (e, t, n) => {
1627
- let r = H(), i = r.subscriptions(), a = n ? r.customer(n) : void 0;
1630
+ let r = B(), i = r.subscriptions(), a = n ? r.customer(n) : void 0;
1628
1631
  return c({
1629
1632
  mutationKey: [
1630
1633
  ...i,
1631
1634
  t,
1632
1635
  "payment-method"
1633
1636
  ],
1634
- mutationFn: (e) => s(t, e),
1637
+ mutationFn: (e) => o(t, e),
1635
1638
  onSuccess: () => Promise.all([e.invalidateQueries({ queryKey: i }), ...a ? [e.invalidateQueries({ queryKey: a })] : []])
1636
1639
  });
1637
1640
  },
1638
1641
  previewSubscriptionChange: (e) => {
1639
- let t = H().subscriptions();
1642
+ let t = B().subscriptions();
1640
1643
  return c({
1641
1644
  mutationKey: [
1642
1645
  ...t,
@@ -1644,18 +1647,18 @@ function ie(e, t, n) {
1644
1647
  "change",
1645
1648
  "preview"
1646
1649
  ],
1647
- mutationFn: (t) => D(e, t)
1650
+ mutationFn: (t) => w(e, t)
1648
1651
  });
1649
1652
  },
1650
1653
  changeSubscription: (e, t, n) => {
1651
- let r = H(), i = r.subscriptions(), a = n ? r.customer(n) : void 0, o = r.payments();
1654
+ let r = B(), i = r.subscriptions(), a = n ? r.customer(n) : void 0, o = r.payments();
1652
1655
  return c({
1653
1656
  mutationKey: [
1654
1657
  ...i,
1655
1658
  t,
1656
1659
  "change"
1657
1660
  ],
1658
- mutationFn: (e) => l(t, e.change, e.idempotencyKey),
1661
+ mutationFn: (e) => s(t, e.change, e.idempotencyKey),
1659
1662
  onSuccess: () => Promise.all([
1660
1663
  e.invalidateQueries({ queryKey: i }),
1661
1664
  e.invalidateQueries({ queryKey: o }),
@@ -1664,195 +1667,153 @@ function ie(e, t, n) {
1664
1667
  });
1665
1668
  },
1666
1669
  grantCustomerProductAccess: (e, t) => {
1667
- let n = H().customer(t);
1670
+ let n = B().customer(t);
1668
1671
  return c({
1669
1672
  mutationKey: [
1670
1673
  ...n,
1671
1674
  "product-access",
1672
1675
  "grant"
1673
1676
  ],
1674
- mutationFn: (e) => _(t, e),
1675
- onSuccess: Z(e, n)
1677
+ mutationFn: (e) => h(t, e),
1678
+ onSuccess: q(e, n)
1676
1679
  });
1677
1680
  },
1678
1681
  revokeCustomerProductAccess: (e, t) => {
1679
- let n = H().customer(t);
1682
+ let n = B().customer(t);
1680
1683
  return c({
1681
1684
  mutationKey: [
1682
1685
  ...n,
1683
1686
  "product-access",
1684
1687
  "revoke"
1685
1688
  ],
1686
- mutationFn: ({ grantId: e, reason: t }) => P(e, t),
1687
- onSuccess: Z(e, n)
1688
- });
1689
- },
1690
- askCatalogCopilot: () => {
1691
- let e = H();
1692
- return c({
1693
- mutationKey: [
1694
- ...e.catalog(),
1695
- "copilot",
1696
- "ask"
1697
- ],
1698
- mutationFn: (e) => i(e)
1699
- });
1700
- },
1701
- loadCatalogPriceDraft: () => {
1702
- let e = H();
1703
- return c({
1704
- mutationKey: [
1705
- ...e.catalog(),
1706
- "copilot",
1707
- "load-price-draft"
1708
- ],
1709
- mutationFn: async ({ productKey: e, priceKey: t }) => {
1710
- let n = await g(e), r = n.prices.find((e) => e.key === t);
1711
- if (!r) throw Error(`No live price ${e}/${t}`);
1712
- return {
1713
- price: r,
1714
- productName: n.display_name,
1715
- productKey: n.key
1716
- };
1717
- }
1718
- });
1719
- },
1720
- createCatalogDraftPrice: (e) => {
1721
- let t = H();
1722
- return c({
1723
- mutationKey: [
1724
- ...t.catalog(),
1725
- "copilot",
1726
- "create-price"
1727
- ],
1728
- mutationFn: (e) => u(e),
1729
- onSuccess: Z(e, t.catalog())
1689
+ mutationFn: ({ grantId: e, reason: t }) => M(e, t),
1690
+ onSuccess: q(e, n)
1730
1691
  });
1731
1692
  },
1732
1693
  applyCatalog: (e) => {
1733
- let t = H();
1694
+ let t = B();
1734
1695
  return c({
1735
1696
  mutationKey: [...t.catalog(), "apply"],
1736
- mutationFn: ({ document: e, force: t }) => O(e, t),
1737
- onSuccess: Z(e, t.catalog())
1697
+ mutationFn: ({ document: e, force: t }) => E(e, t),
1698
+ onSuccess: q(e, t.catalog())
1738
1699
  });
1739
1700
  },
1740
1701
  createProduct: (e) => {
1741
- let t = H();
1702
+ let t = B();
1742
1703
  return c({
1743
1704
  mutationKey: [
1744
1705
  ...t.catalog(),
1745
1706
  "products",
1746
1707
  "create"
1747
1708
  ],
1748
- mutationFn: (e) => d(e),
1749
- onSuccess: Z(e, t.catalog())
1709
+ mutationFn: (e) => u(e),
1710
+ onSuccess: q(e, t.catalog())
1750
1711
  });
1751
1712
  },
1752
1713
  updateProduct: (e) => {
1753
- let t = H();
1714
+ let t = B();
1754
1715
  return c({
1755
1716
  mutationKey: [
1756
1717
  ...t.catalog(),
1757
1718
  "products",
1758
1719
  "update"
1759
1720
  ],
1760
- mutationFn: ({ id: e, product: t }) => R(e, t),
1761
- onSuccess: Z(e, t.catalog()),
1762
- onError: Q(e, t.catalog())
1721
+ mutationFn: ({ id: e, product: t }) => I(e, t),
1722
+ onSuccess: q(e, t.catalog()),
1723
+ onError: J(e, t.catalog())
1763
1724
  });
1764
1725
  },
1765
1726
  setProductActive: (e) => {
1766
- let t = H();
1727
+ let t = B();
1767
1728
  return c({
1768
1729
  mutationKey: [
1769
1730
  ...t.catalog(),
1770
1731
  "products",
1771
1732
  "set-active"
1772
1733
  ],
1773
- mutationFn: ({ id: e, active: t, revision: n }) => R(e, {
1734
+ mutationFn: ({ id: e, active: t, revision: n }) => I(e, {
1774
1735
  archived: !t,
1775
1736
  expected_revision: n
1776
1737
  }),
1777
- onSuccess: Z(e, t.catalog()),
1778
- onError: Q(e, t.catalog())
1738
+ onSuccess: q(e, t.catalog()),
1739
+ onError: J(e, t.catalog())
1779
1740
  });
1780
1741
  },
1781
1742
  createPrice: (e) => {
1782
- let t = H();
1743
+ let t = B();
1783
1744
  return c({
1784
1745
  mutationKey: [
1785
1746
  ...t.catalog(),
1786
1747
  "prices",
1787
1748
  "create"
1788
1749
  ],
1789
- mutationFn: (e) => u(e),
1790
- onSuccess: Z(e, t.catalog())
1750
+ mutationFn: (e) => l(e),
1751
+ onSuccess: q(e, t.catalog())
1791
1752
  });
1792
1753
  },
1793
1754
  setPriceActive: (e) => {
1794
- let t = H();
1755
+ let t = B();
1795
1756
  return c({
1796
1757
  mutationKey: [
1797
1758
  ...t.catalog(),
1798
1759
  "prices",
1799
1760
  "set-active"
1800
1761
  ],
1801
- mutationFn: ({ id: e, active: t, revision: n }) => L(e, {
1762
+ mutationFn: ({ id: e, active: t, revision: n }) => F(e, {
1802
1763
  archived: !t,
1803
1764
  expected_revision: n
1804
1765
  }),
1805
- onSuccess: Z(e, t.catalog()),
1806
- onError: Q(e, t.catalog())
1766
+ onSuccess: q(e, t.catalog()),
1767
+ onError: J(e, t.catalog())
1807
1768
  });
1808
1769
  },
1809
1770
  putUsageMeter: (e) => {
1810
- let t = H(), n = t.usageMeters();
1771
+ let t = B(), n = t.usageMeters();
1811
1772
  return c({
1812
1773
  mutationKey: [...n, "put"],
1813
- mutationFn: ({ key: e, meter: t }) => w(e, t),
1774
+ mutationFn: ({ key: e, meter: t }) => S(e, t),
1814
1775
  onSuccess: (r, { key: i }) => Promise.all([e.invalidateQueries({ queryKey: n }), e.invalidateQueries({ queryKey: t.usageMeter(i) })]),
1815
- onError: Q(e, n)
1776
+ onError: J(e, n)
1816
1777
  });
1817
1778
  },
1818
1779
  putDefaultUsageRateCard: (e) => {
1819
- let t = H(), n = t.usageMeters();
1780
+ let t = B(), n = t.usageMeters();
1820
1781
  return c({
1821
1782
  mutationKey: [
1822
1783
  ...n,
1823
1784
  "rate-card",
1824
1785
  "put"
1825
1786
  ],
1826
- mutationFn: ({ meter: e, rateCard: t }) => S(e, t),
1787
+ mutationFn: ({ meter: e, rateCard: t }) => y(e, t),
1827
1788
  onSuccess: (r, { meter: i }) => Promise.all([e.invalidateQueries({ queryKey: n }), e.invalidateQueries({ queryKey: t.usageMeter(i.key) })]),
1828
- onError: Q(e, n)
1789
+ onError: J(e, n)
1829
1790
  });
1830
1791
  },
1831
1792
  deleteDefaultUsageRateCard: (e) => {
1832
- let t = H(), n = t.usageMeters();
1793
+ let t = B(), n = t.usageMeters();
1833
1794
  return c({
1834
1795
  mutationKey: [
1835
1796
  ...n,
1836
1797
  "rate-card",
1837
1798
  "delete"
1838
1799
  ],
1839
- mutationFn: (e) => S(e, null),
1800
+ mutationFn: (e) => y(e, null),
1840
1801
  onSuccess: (r, i) => Promise.all([e.invalidateQueries({ queryKey: n }), e.invalidateQueries({ queryKey: t.usageMeter(i.key) })])
1841
1802
  });
1842
1803
  },
1843
1804
  previewPriceChange: () => {
1844
- let e = H();
1805
+ let e = B();
1845
1806
  return c({
1846
1807
  mutationKey: [
1847
1808
  ...e.catalog(),
1848
1809
  "prices",
1849
1810
  "preview-change"
1850
1811
  ],
1851
- mutationFn: ({ productKey: e, priceKey: t }) => E(e, t)
1812
+ mutationFn: ({ productKey: e, priceKey: t }) => C(e, t)
1852
1813
  });
1853
1814
  },
1854
1815
  changePrice: (e) => {
1855
- let t = H();
1816
+ let t = B();
1856
1817
  return c({
1857
1818
  mutationKey: [
1858
1819
  ...t.catalog(),
@@ -1860,35 +1821,35 @@ function ie(e, t, n) {
1860
1821
  "change"
1861
1822
  ],
1862
1823
  mutationFn: async ({ price: e, migration: t }) => {
1863
- let n = await u(e);
1864
- return t && await A(t.productKey, t.priceKey, n.id, t.effectiveAt), n;
1824
+ let n = await l(e);
1825
+ return t && await O(t.productKey, t.priceKey, n.id, t.effectiveAt), n;
1865
1826
  },
1866
- onSettled: Z(e, t.catalog())
1827
+ onSettled: q(e, t.catalog())
1867
1828
  });
1868
1829
  },
1869
1830
  cancelPriceMigration: (e) => {
1870
- let t = H();
1831
+ let t = B();
1871
1832
  return c({
1872
1833
  mutationKey: [
1873
1834
  ...t.catalog(),
1874
1835
  "price-migrations",
1875
1836
  "cancel"
1876
1837
  ],
1877
- mutationFn: (e) => a(e),
1878
- onSuccess: Z(e, t.catalog())
1838
+ mutationFn: (e) => i(e),
1839
+ onSuccess: q(e, t.catalog())
1879
1840
  });
1880
1841
  },
1881
1842
  updateMerchantConfiguration: (e) => {
1882
- let t = H();
1843
+ let t = B();
1883
1844
  return c({
1884
1845
  mutationKey: [...t.settings(), "update"],
1885
- mutationFn: (e) => I(e),
1886
- onSettled: X(e, t.settings()),
1887
- onError: U(e)
1846
+ mutationFn: (e) => P(e),
1847
+ onSettled: K(e, t.settings()),
1848
+ onError: V(e)
1888
1849
  });
1889
1850
  },
1890
1851
  createPSP: (e) => {
1891
- let t = r(), n = H();
1852
+ let t = r(), n = B();
1892
1853
  return c({
1893
1854
  mutationKey: [
1894
1855
  ...n.settings(),
@@ -1899,14 +1860,14 @@ function ie(e, t, n) {
1899
1860
  gcTime: 0,
1900
1861
  mutationFn: (e) => {
1901
1862
  if (r() !== t) throw Error("Merchant changed; reopen this form before saving");
1902
- return p(e);
1863
+ return f(e);
1903
1864
  },
1904
- onSettled: X(e, [...n.settings(), "psps"]),
1905
- onError: U(e)
1865
+ onSettled: K(e, [...n.settings(), "psps"]),
1866
+ onError: V(e)
1906
1867
  });
1907
1868
  },
1908
1869
  updatePSP: (e) => {
1909
- let t = r(), n = H();
1870
+ let t = r(), n = B();
1910
1871
  return c({
1911
1872
  mutationKey: [
1912
1873
  ...n.settings(),
@@ -1917,28 +1878,28 @@ function ie(e, t, n) {
1917
1878
  gcTime: 0,
1918
1879
  mutationFn: ({ id: e, psp: n }) => {
1919
1880
  if (r() !== t) throw Error("Merchant changed; reopen this form before saving");
1920
- return C(e, n);
1881
+ return b(e, n);
1921
1882
  },
1922
- onSettled: X(e, [...n.settings(), "psps"]),
1923
- onError: U(e)
1883
+ onSettled: K(e, [...n.settings(), "psps"]),
1884
+ onError: V(e)
1924
1885
  });
1925
1886
  },
1926
1887
  setCreditLimit: () => {
1927
- let e = H();
1888
+ let e = B();
1928
1889
  return c({
1929
1890
  mutationKey: [
1930
1891
  ...e.settings(),
1931
1892
  "customer-controls",
1932
1893
  "credit-limit"
1933
1894
  ],
1934
- mutationFn: ({ customerId: e, currency: t, amount: n }) => F(e, { credit_limits: [{
1895
+ mutationFn: ({ customerId: e, currency: t, amount: n }) => N(e, { credit_limits: [{
1935
1896
  currency: t,
1936
1897
  amount: n
1937
1898
  }] })
1938
1899
  });
1939
1900
  },
1940
1901
  lookupCustomerControls: () => {
1941
- let e = H();
1902
+ let e = B();
1942
1903
  return c({
1943
1904
  mutationKey: [
1944
1905
  ...e.settings(),
@@ -1946,7 +1907,7 @@ function ie(e, t, n) {
1946
1907
  "lookup"
1947
1908
  ],
1948
1909
  mutationFn: async ({ customerId: e, currency: t }) => {
1949
- let { settings: n } = await h(e).catch((e) => {
1910
+ let { settings: n } = await m(e).catch((e) => {
1950
1911
  throw e instanceof x && e.status === 404 ? Error("No customer has this ID") : e;
1951
1912
  }), r = t.toUpperCase();
1952
1913
  return {
@@ -1958,48 +1919,48 @@ function ie(e, t, n) {
1958
1919
  });
1959
1920
  },
1960
1921
  createWebhook: (e) => {
1961
- let t = H();
1922
+ let t = B();
1962
1923
  return c({
1963
1924
  mutationKey: [
1964
1925
  ...t.alerts(),
1965
1926
  "webhooks",
1966
1927
  "create"
1967
1928
  ],
1968
- mutationFn: (e) => f(e),
1969
- onSuccess: W(e, t),
1970
- onError: U(e)
1929
+ mutationFn: (e) => d(e),
1930
+ onSuccess: H(e, t),
1931
+ onError: V(e)
1971
1932
  });
1972
1933
  },
1973
1934
  updateWebhook: (e) => {
1974
- let t = H();
1935
+ let t = B();
1975
1936
  return c({
1976
1937
  mutationKey: [
1977
1938
  ...t.alerts(),
1978
1939
  "webhooks",
1979
1940
  "update"
1980
1941
  ],
1981
- mutationFn: ({ id: e, webhook: t }) => z(e, t),
1982
- onSuccess: W(e, t),
1983
- onError: U(e)
1942
+ mutationFn: ({ id: e, webhook: t }) => L(e, t),
1943
+ onSuccess: H(e, t),
1944
+ onError: V(e)
1984
1945
  });
1985
1946
  },
1986
1947
  deleteWebhook: (e) => {
1987
- let t = H();
1948
+ let t = B();
1988
1949
  return c({
1989
1950
  mutationKey: [
1990
1951
  ...t.alerts(),
1991
1952
  "webhooks",
1992
1953
  "delete"
1993
1954
  ],
1994
- mutationFn: (e) => m(e),
1995
- onSuccess: W(e, t),
1996
- onError: U(e)
1955
+ mutationFn: (e) => p(e),
1956
+ onSuccess: H(e, t),
1957
+ onError: V(e)
1997
1958
  });
1998
1959
  }
1999
1960
  } };
2000
1961
  }
2001
1962
  // src/admin/lib/credit-queries.ts
2002
- function ae(e, t) {
1963
+ function le(e, t) {
2003
1964
  let { selectedMerchant: n } = e, r = (t, n) => [
2004
1965
  ...e.queryRoot(t),
2005
1966
  "customers",
@@ -2047,7 +2008,7 @@ function ae(e, t) {
2047
2008
  };
2048
2009
  }
2049
2010
  // src/admin/lib/order-queries.ts
2050
- function oe(e, t, n) {
2011
+ function ue(e, t, n) {
2051
2012
  let { queryRoot: r } = e, { queryKeys: i } = n, a = t, o = t, u = {
2052
2013
  root: () => [...r(), "orders"],
2053
2014
  detail: (e) => [...u.root(), e],
@@ -2125,7 +2086,7 @@ function oe(e, t, n) {
2125
2086
  };
2126
2087
  }
2127
2088
  // src/admin/lib/import-queries.ts
2128
- var se = (e) => e === "pulling" || e === "applying", ce = 2e3, le = (e) => ({
2089
+ var de = (e) => e === "pulling" || e === "applying", fe = 2e3, pe = (e) => ({
2129
2090
  imports: () => [...e(), "psp-imports"],
2130
2091
  import: (t) => [
2131
2092
  ...e(),
@@ -2138,10 +2099,10 @@ var se = (e) => e === "pulling" || e === "applying", ce = 2e3, le = (e) => ({
2138
2099
  catalog: () => [...e(), "catalog"],
2139
2100
  ops: () => [...e(), "ops"]
2140
2101
  });
2141
- function ue(e, t) {
2142
- let { queryRoot: n } = e, r = le(n), i = () => {
2102
+ function me(e, t) {
2103
+ let { queryRoot: n } = e, r = pe(n), i = () => {
2143
2104
  let e = n();
2144
- return le(() => e);
2105
+ return pe(() => e);
2145
2106
  };
2146
2107
  return {
2147
2108
  importKeys: r,
@@ -2159,7 +2120,7 @@ function ue(e, t) {
2159
2120
  cursor: i
2160
2121
  }, r),
2161
2122
  placeholderData: s,
2162
- refetchInterval: (e) => e.state.data?.data.some((e) => se(e.status)) ? ce : !1,
2123
+ refetchInterval: (e) => e.state.data?.data.some((e) => de(e.status)) ? fe : !1,
2163
2124
  meta: { errorAction: "Load PSP imports" }
2164
2125
  }),
2165
2126
  latest: (e) => l({
@@ -2175,7 +2136,7 @@ function ue(e, t) {
2175
2136
  queryKey: r.import(e),
2176
2137
  queryFn: ({ signal: n }) => t.getPSPImport(e, n),
2177
2138
  enabled: !!e,
2178
- refetchInterval: (e) => se(e.state.data?.status) ? ce : !1,
2139
+ refetchInterval: (e) => de(e.state.data?.status) ? fe : !1,
2179
2140
  meta: { errorAction: "Load PSP import" }
2180
2141
  }),
2181
2142
  records: (e, n, i, a, o) => l({
@@ -2314,29 +2275,29 @@ function ue(e, t) {
2314
2275
  };
2315
2276
  }
2316
2277
  // src/admin/context.tsx
2317
- function de(e) {
2318
- let t = E(e), n = B(t), r = te(t, n), i = W(e.namespace);
2278
+ function he(e) {
2279
+ let t = E(e), n = B(t), r = ae(t, n), i = te(e.namespace);
2319
2280
  return {
2320
2281
  toast: i,
2321
- ...G(i),
2282
+ ...ne(i),
2322
2283
  ...t,
2323
2284
  ...n,
2324
2285
  ...r,
2325
- ...ie(t, n, r),
2326
- ...ae(t, n),
2327
- ...oe(t, n, r),
2328
- ...ue(t, n)
2286
+ ...ce(t, n, r),
2287
+ ...le(t, n),
2288
+ ...ue(t, n, r),
2289
+ ...me(t, n)
2329
2290
  };
2330
2291
  }
2331
- var fe = e(null);
2332
- function pe() {
2333
- let e = n(fe);
2292
+ var ge = e(null);
2293
+ function _e() {
2294
+ let e = n(ge);
2334
2295
  if (!e) throw Error("BillingAdmin context is missing");
2335
2296
  return e;
2336
2297
  }
2337
- var me = () => pe().services, he = e(null), ge = (e) => (window.addEventListener("popstate", e), () => window.removeEventListener("popstate", e)), _e = () => window.location.pathname + window.location.search;
2338
- function ve({ basePath: e = "/", navigation: n, children: r }) {
2339
- let s = o(ge, _e, () => e), c = e.replace(/\/$/, ""), l = new URL(s, "http://billing.local"), u = n?.pathname ?? l.pathname, f = n?.search ?? l.search, p = u === c ? "/" : u.startsWith(c + "/") ? u.slice(c.length) : "/", [m, h] = a(() => /* @__PURE__ */ new Map()), g = t((e) => {
2298
+ var ve = () => _e().services, ye = e(null), be = (e) => (window.addEventListener("popstate", e), () => window.removeEventListener("popstate", e)), xe = () => window.location.pathname + window.location.search;
2299
+ function Se({ basePath: e = "/", navigation: n, children: r }) {
2300
+ let s = o(be, xe, () => e), c = e.replace(/\/$/, ""), l = new URL(s, "http://billing.local"), u = n?.pathname ?? l.pathname, f = n?.search ?? l.search, p = u === c ? "/" : u.startsWith(c + "/") ? u.slice(c.length) : "/", [m, h] = a(() => /* @__PURE__ */ new Map()), g = t((e) => {
2340
2301
  if (/^(?:[a-z][a-z\d+.-]*:|\/\/)/i.test(e)) return e;
2341
2302
  let t = new URL(e, "http://billing.local" + p + f);
2342
2303
  return c + t.pathname + t.search + t.hash;
@@ -2369,26 +2330,26 @@ function ve({ basePath: e = "/", navigation: n, children: r }) {
2369
2330
  n,
2370
2331
  m
2371
2332
  ]);
2372
- return /* @__PURE__ */ d(he.Provider, {
2333
+ return /* @__PURE__ */ d(ye.Provider, {
2373
2334
  value: v,
2374
2335
  children: r
2375
2336
  });
2376
2337
  }
2377
- function $() {
2378
- let e = n(he);
2338
+ function Y() {
2339
+ let e = n(ye);
2379
2340
  if (!e) throw Error("BillingAdmin router is missing");
2380
2341
  return e;
2381
2342
  }
2382
- var ye = () => $().location, be = () => $().navigate, xe = () => $().params;
2383
- function Se() {
2384
- let { location: e, navigate: t } = $();
2343
+ var Ce = () => Y().location, we = () => Y().navigate, Te = () => Y().params;
2344
+ function Ee() {
2345
+ let { location: e, navigate: t } = Y();
2385
2346
  return [i(() => new URLSearchParams(e.search), [e.search]), (n, r) => {
2386
2347
  let i = new URLSearchParams(n).toString();
2387
2348
  t(e.pathname + (i ? "?" + i : ""), r);
2388
2349
  }];
2389
2350
  }
2390
- function Ce({ to: e, onClick: t, ...n }) {
2391
- let { href: r, navigate: i } = $();
2351
+ function De({ to: e, onClick: t, ...n }) {
2352
+ let { href: r, navigate: i } = Y();
2392
2353
  return /* @__PURE__ */ d("a", {
2393
2354
  ...n,
2394
2355
  href: r(e),
@@ -2397,17 +2358,17 @@ function Ce({ to: e, onClick: t, ...n }) {
2397
2358
  }
2398
2359
  });
2399
2360
  }
2400
- function we({ to: e, replace: t }) {
2401
- let n = be();
2361
+ function Oe({ to: e, replace: t }) {
2362
+ let n = we();
2402
2363
  return r(() => n(e, { replace: t }), [
2403
2364
  n,
2404
2365
  e,
2405
2366
  t
2406
2367
  ]), null;
2407
2368
  }
2408
- function Te({ params: e, children: t }) {
2409
- let n = $();
2410
- return /* @__PURE__ */ d(he.Provider, {
2369
+ function ke({ params: e, children: t }) {
2370
+ let n = Y();
2371
+ return /* @__PURE__ */ d(ye.Provider, {
2411
2372
  value: {
2412
2373
  ...n,
2413
2374
  params: e
@@ -2416,9 +2377,211 @@ function Te({ params: e, children: t }) {
2416
2377
  });
2417
2378
  }
2418
2379
  // src/admin/lib/utils.ts
2419
- function Ee(...e) {
2380
+ function Ae(...e) {
2420
2381
  return p(f(e));
2421
2382
  }
2422
- export { k as C, m as D, g as E, h as O, A as S, E as T, U as _, Te as a, D as b, xe as c, de as d, pe as f, G as g, W as h, we as i, Se as l, se as m, ve as n, ye as o, me as p, Ce as r, be as s, Ee as t, fe as u, B as v, x as w, O as x, M as y };
2383
+ // src/lib/card-brands.ts
2384
+ var je = {
2385
+ visa: "visa",
2386
+ mastercard: "mastercard",
2387
+ mc: "mastercard",
2388
+ master: "mastercard",
2389
+ amex: "amex",
2390
+ americanexpress: "amex",
2391
+ "american express": "amex"
2392
+ }, Me = {
2393
+ visa: "Visa",
2394
+ mastercard: "Mastercard",
2395
+ amex: "Amex",
2396
+ discover: "Discover",
2397
+ jcb: "JCB",
2398
+ diners: "Diners Club",
2399
+ unionpay: "UnionPay"
2400
+ };
2401
+ function Ne(e) {
2402
+ let t = e?.trim();
2403
+ if (!t) return;
2404
+ let n = t.toLowerCase().replace(/[^a-z]/g, "");
2405
+ return Me[Pe(t) ?? n] ?? t[0].toUpperCase() + t.slice(1).toLowerCase();
2406
+ }
2407
+ function Pe(e) {
2408
+ let t = e?.trim().toLowerCase().replace(/[^a-z ]/g, "");
2409
+ return t ? je[t] : void 0;
2410
+ }
2411
+ // src/client/generated/currencies.ts
2412
+ var X = {
2413
+ AED: 6,
2414
+ AUD: 6,
2415
+ BRL: 6,
2416
+ CAD: 6,
2417
+ CHF: 6,
2418
+ CNY: 6,
2419
+ CZK: 6,
2420
+ DKK: 6,
2421
+ EUR: 6,
2422
+ GBP: 6,
2423
+ HKD: 6,
2424
+ ILS: 6,
2425
+ INR: 6,
2426
+ JPY: 4,
2427
+ KRW: 4,
2428
+ MXN: 6,
2429
+ MYR: 6,
2430
+ NOK: 6,
2431
+ NZD: 6,
2432
+ PHP: 6,
2433
+ PLN: 6,
2434
+ PYUSD: 6,
2435
+ SAR: 6,
2436
+ SEK: 6,
2437
+ SGD: 6,
2438
+ SOL: 9,
2439
+ THB: 6,
2440
+ TRY: 6,
2441
+ USD: 6,
2442
+ USD1: 6,
2443
+ USDC: 6,
2444
+ USDG: 6,
2445
+ USDT: 6,
2446
+ ZAR: 6
2447
+ }, Fe = -(1n << 63n), Ie = (1n << 63n) - 1n, Le = (() => {
2448
+ try {
2449
+ return new Intl.NumberFormat("en", { useGrouping: !1 }).format("9007199254740993") === "9007199254740993";
2450
+ } catch {
2451
+ return !1;
2452
+ }
2453
+ })(), Re = 10n ** 15n;
2454
+ function Z(e) {
2455
+ let t = e.trim().toUpperCase();
2456
+ return Object.hasOwn(X, t) ? X[t] : void 0;
2457
+ }
2458
+ var ze = Object.keys(X);
2459
+ function Q(e) {
2460
+ return Number.isInteger(e) && e >= 0 && e <= 18;
2461
+ }
2462
+ function Be(e) {
2463
+ if (typeof e == "number") return Number.isSafeInteger(e) ? BigInt(e) : null;
2464
+ if (!/^-?\d{1,19}$/.test(e)) return null;
2465
+ let t = BigInt(e);
2466
+ return t < Fe || t > Ie ? null : t;
2467
+ }
2468
+ function Ve(e, t) {
2469
+ let n = Be(e);
2470
+ return n === null || !Q(t) ? null : He(n, t);
2471
+ }
2472
+ function He(e, t) {
2473
+ let n = e < 0n ? -e : e, r = 10n ** BigInt(t), i = (n % r).toString().padStart(t, "0").replace(/0+$/, "");
2474
+ return `${e < 0n ? "-" : ""}${n / r}${i ? `.${i}` : ""}`;
2475
+ }
2476
+ function $(e, t, n, r = n) {
2477
+ let i = Be(e);
2478
+ if (i === null || !Q(n)) return `${t} amount exceeds the exact display range`;
2479
+ if (!Le && (i >= Re || i <= -Re)) return `${t} amount exceeds this browser's exact display range`;
2480
+ let a = He(i, n), o = t.trim().toUpperCase();
2481
+ return /^[A-Z]{3}$/.test(o) ? new Intl.NumberFormat(void 0, {
2482
+ style: "currency",
2483
+ currency: o,
2484
+ maximumFractionDigits: r
2485
+ }).format(a) : `${new Intl.NumberFormat(void 0, { maximumFractionDigits: r }).format(a)} ${t}`;
2486
+ }
2487
+ function Ue(e) {
2488
+ return Object.fromEntries((e ?? []).map((e) => [e.code.toUpperCase(), {
2489
+ scale: e.scale,
2490
+ name: e.name || e.code
2491
+ }]));
2492
+ }
2493
+ function We(e, t, n = {}) {
2494
+ let r = n[t.trim().toUpperCase()];
2495
+ if (r) {
2496
+ let n = Be(e);
2497
+ return n === null || !Q(r.scale) ? `${t} amount exceeds the exact display range` : `${new Intl.NumberFormat(void 0, {
2498
+ minimumFractionDigits: r.scale,
2499
+ maximumFractionDigits: r.scale
2500
+ }).format(He(n, r.scale))} ${r.name}`;
2501
+ }
2502
+ let i = Z(t);
2503
+ if (i === void 0) return Ge(e, t);
2504
+ let a = t.trim().toUpperCase(), o = Intl.supportedValuesOf("currency").includes(a) ? new Intl.NumberFormat(void 0, {
2505
+ style: "currency",
2506
+ currency: a
2507
+ }).resolvedOptions().maximumFractionDigits : 4;
2508
+ return $(e, t, i, Math.min(o, i));
2509
+ }
2510
+ function Ge(e, t) {
2511
+ let n = Z(t);
2512
+ return n === void 0 ? `Amount in unregistered currency ${t || "(none)"}` : $(e, t, n);
2513
+ }
2514
+ function Ke(e) {
2515
+ return Object.fromEntries(e.flatMap((e) => e.unit ? [[e.currency.toUpperCase(), e.unit.scale]] : []));
2516
+ }
2517
+ function qe(e) {
2518
+ return Object.fromEntries((e ?? []).map((e) => [e.code.toUpperCase(), e.scale]));
2519
+ }
2520
+ function Je(e, t, n) {
2521
+ let r = n[t.trim().toUpperCase()];
2522
+ return r === void 0 ? Ge(e, t) : $(e, t, r);
2523
+ }
2524
+ function Ye(e, t) {
2525
+ return t.unit ? $(e, t.currency, t.unit.scale) : Ge(e, t.currency);
2526
+ }
2527
+ function Xe(e, t) {
2528
+ if (!Q(t)) return null;
2529
+ let n = /^([+-]?)(\d*)(?:\.(\d*))?$/.exec(e.trim());
2530
+ if (!n || !n[2] && !n[3] || (n[3]?.length ?? 0) > t) return null;
2531
+ let r = BigInt(n[2] || "0") * 10n ** BigInt(t) + BigInt((n[3] || "").padEnd(t, "0") || "0"), i = n[1] === "-" ? -r : r;
2532
+ return i < Fe || i > Ie ? null : i.toString();
2533
+ }
2534
+ function Ze(e, t) {
2535
+ let n = Z(t);
2536
+ return n === void 0 ? null : Xe(e, n);
2537
+ }
2538
+ function Qe(e, t) {
2539
+ let n = Z(t);
2540
+ return e === void 0 || n === void 0 || typeof e == "number" && !Number.isSafeInteger(e) ? "" : Ve(e, n) ?? "";
2541
+ }
2542
+ function $e(e) {
2543
+ if (!e) return "—";
2544
+ let t = new Date(e);
2545
+ return Number.isNaN(t.getTime()) ? "—" : t.toLocaleString(void 0, {
2546
+ dateStyle: "medium",
2547
+ timeStyle: "short"
2548
+ });
2549
+ }
2550
+ function et(e) {
2551
+ return e?.last4 ? `${Ne(e.brand) ?? "Card"} ••••${e.last4}` : "—";
2552
+ }
2553
+ function tt(e) {
2554
+ return `${e?.exp_month ?? "??"}/${e?.exp_year ?? "????"}`;
2555
+ }
2556
+ function nt(e, t = 8) {
2557
+ return e.length > t ? `${e.slice(0, t)}…` : e;
2558
+ }
2559
+ function rt(e) {
2560
+ return e.contact?.name || e.contact?.email || nt(e.id, 13);
2561
+ }
2562
+ function it(e) {
2563
+ return rt({
2564
+ id: e.customer_id,
2565
+ contact: e.customer_contact ?? null
2566
+ });
2567
+ }
2568
+ function at(e) {
2569
+ if (!e) return "";
2570
+ let t = new Date(e).getTime();
2571
+ if (Number.isNaN(t)) return "";
2572
+ let n = Math.round((Date.now() - t) / 1e3);
2573
+ if (n < 45) return "just now";
2574
+ if (n < 90) return "1m";
2575
+ let r = Math.round(n / 60);
2576
+ if (r < 60) return `${r}m`;
2577
+ let i = Math.round(r / 60);
2578
+ if (i < 24) return `${i}h`;
2579
+ let a = Math.round(i / 24);
2580
+ return a < 7 ? `${a}d` : new Date(t).toLocaleDateString(void 0, {
2581
+ month: "short",
2582
+ day: "numeric"
2583
+ });
2584
+ }
2585
+ export { Ee as A, N as B, Se as C, Ce as D, ke as E, de as F, k as G, D as H, te as I, g as J, x as K, ne as L, he as M, _e as N, we as O, ve as P, ee as R, Ae as S, Oe as T, O as U, M as V, A as W, h as X, m as Y, ze as _, Ye as a, Ve as b, $e as c, We as d, Ue as f, nt as g, it as h, qe as i, ge as j, Te as k, Ge as l, Qe as m, Z as n, et as o, Ze as p, E as q, rt as r, tt as s, Xe as t, Je as u, at as v, De as w, X as x, Ke as y, B as z };
2423
2586
 
2424
- //# sourceMappingURL=admin-utils-CuwG3SAt.js.map
2587
+ //# sourceMappingURL=admin-format-Bc4NWK0F.js.map