@stridge/kit 0.1.0-alpha.6 → 0.1.0-alpha.61

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 (580) hide show
  1. package/README.md +22 -6
  2. package/dist/KitProvider.d.ts +40 -0
  3. package/dist/KitProvider.js +1 -1
  4. package/dist/_internal/activity/driver/index.d.ts +3 -0
  5. package/dist/_internal/activity/driver/index.js +1 -0
  6. package/dist/_internal/deposit/driver/index.d.ts +3 -3
  7. package/dist/_internal/drivers/stridge/index.d.ts +4 -2
  8. package/dist/_internal/drivers/stridge/index.js +1 -1
  9. package/dist/_internal/drivers/stridge-mock/index.d.ts +4 -2
  10. package/dist/_internal/drivers/stridge-mock/index.js +1 -1
  11. package/dist/_internal/withdraw/driver/index.d.ts +2 -2
  12. package/dist/activity/compound/index.d.ts +19 -0
  13. package/dist/activity/compound/index.js +1 -0
  14. package/dist/activity/dialog/index.d.ts +4 -0
  15. package/dist/activity/dialog/index.js +1 -0
  16. package/dist/activity/widgets/index.d.ts +5 -0
  17. package/dist/activity/widgets/index.js +1 -0
  18. package/dist/deposit/compound/index.d.ts +25 -15
  19. package/dist/deposit/compound/index.js +1 -1
  20. package/dist/deposit/dialog/index.d.ts +2 -1
  21. package/dist/deposit/widgets/index.d.ts +17 -0
  22. package/dist/deposit/widgets/index.js +1 -0
  23. package/dist/drivers/stridge/catalog.d.ts +54 -0
  24. package/dist/drivers/stridge/catalog.js +1 -0
  25. package/dist/drivers/stridge/createStridgeActivityDriver.d.ts +44 -0
  26. package/dist/drivers/stridge/createStridgeActivityDriver.js +1 -0
  27. package/dist/drivers/stridge/createStridgeDepositDriver.d.ts +10 -1
  28. package/dist/drivers/stridge/createStridgeDepositDriver.js +1 -1
  29. package/dist/drivers/stridge/createStridgeWithdrawDriver.d.ts +37 -14
  30. package/dist/drivers/stridge/createStridgeWithdrawDriver.js +1 -1
  31. package/dist/drivers/stridge/internal/ensureWalletChain.js +1 -0
  32. package/dist/drivers/stridge/internal/pollOnce.js +1 -1
  33. package/dist/drivers/stridge/internal/resolveAddEthereumChain.js +1 -0
  34. package/dist/drivers/stridge/internal/retry.js +1 -0
  35. package/dist/drivers/stridge/internal/supportedChains.js +1 -0
  36. package/dist/drivers/stridge/types.d.ts +20 -14
  37. package/dist/drivers/stridge/types.js +1 -1
  38. package/dist/drivers/stridge/wagmiSigner.js +1 -1
  39. package/dist/drivers/stridge-mock/checkoutChannel.d.ts +31 -0
  40. package/dist/drivers/stridge-mock/checkoutChannel.js +1 -0
  41. package/dist/drivers/stridge-mock/createStridgeMockActivityDriver.d.ts +44 -0
  42. package/dist/drivers/stridge-mock/createStridgeMockActivityDriver.js +1 -0
  43. package/dist/drivers/stridge-mock/createStridgeMockDriver.d.ts +30 -2
  44. package/dist/drivers/stridge-mock/createStridgeMockDriver.js +1 -1
  45. package/dist/drivers/stridge-mock/createStridgeMockWithdrawDriver.d.ts +15 -3
  46. package/dist/drivers/stridge-mock/createStridgeMockWithdrawDriver.js +1 -1
  47. package/dist/drivers/stridge-mock/fixtures.d.ts +19 -13
  48. package/dist/drivers/stridge-mock/fixtures.js +1 -1
  49. package/dist/drivers/stridge-mock/triggers.d.ts +12 -0
  50. package/dist/events/bus/createBus.d.ts +26 -0
  51. package/dist/events/bus/createBus.js +1 -0
  52. package/dist/events/bus/flowIdRegistry.d.ts +17 -0
  53. package/dist/events/bus/flowIdRegistry.js +1 -0
  54. package/dist/events/bus/index.js +1 -0
  55. package/dist/events/bus/metadata.js +1 -0
  56. package/dist/events/context.js +1 -0
  57. package/dist/events/emit/index.js +1 -0
  58. package/dist/events/emit/mapFailure.js +1 -0
  59. package/dist/events/emit/useActivityEmissions.js +1 -0
  60. package/dist/events/emit/useDepositEmissions.js +1 -0
  61. package/dist/events/emit/useKitEmitter.js +1 -0
  62. package/dist/events/emit/useWithdrawEmissions.js +1 -0
  63. package/dist/events/hooks/index.d.ts +6 -0
  64. package/dist/events/hooks/index.js +1 -0
  65. package/dist/events/hooks/useCurrentFlowId.d.ts +6 -0
  66. package/dist/events/hooks/useCurrentFlowId.js +1 -0
  67. package/dist/events/hooks/useStableHandler.js +1 -0
  68. package/dist/events/hooks/useStridgeEvent.d.ts +9 -0
  69. package/dist/events/hooks/useStridgeEvent.js +1 -0
  70. package/dist/events/hooks/useStridgeEventBus.d.ts +34 -0
  71. package/dist/events/hooks/useStridgeEventBus.js +1 -0
  72. package/dist/events/hooks/useStridgeEvents.d.ts +7 -0
  73. package/dist/events/hooks/useStridgeEvents.js +1 -0
  74. package/dist/events/hooks/useStridgeFlowEvent.d.ts +8 -0
  75. package/dist/events/hooks/useStridgeFlowEvent.js +1 -0
  76. package/dist/events/hooks/useStridgeFlowEvents.d.ts +6 -0
  77. package/dist/events/hooks/useStridgeFlowEvents.js +1 -0
  78. package/dist/events/index.d.ts +17 -0
  79. package/dist/events/index.js +1 -0
  80. package/dist/events/publish.js +1 -0
  81. package/dist/events/redact.d.ts +34 -0
  82. package/dist/events/redact.js +1 -0
  83. package/dist/events/types/activity.d.ts +53 -0
  84. package/dist/events/types/deposit.d.ts +235 -0
  85. package/dist/events/types/envelope.d.ts +145 -0
  86. package/dist/events/types/index.d.ts +32 -0
  87. package/dist/events/types/kit.d.ts +23 -0
  88. package/dist/events/types/withdraw.d.ts +150 -0
  89. package/dist/flows/activity/compound/ActivityFlow.d.ts +46 -0
  90. package/dist/flows/activity/compound/ActivityFlow.js +1 -0
  91. package/dist/flows/activity/compound/components/Boundary.d.ts +29 -0
  92. package/dist/flows/activity/compound/components/Boundary.js +1 -0
  93. package/dist/flows/activity/compound/components/Steps.d.ts +24 -0
  94. package/dist/flows/activity/compound/components/Steps.js +1 -0
  95. package/dist/flows/activity/dialog/ActivityDialog.d.ts +55 -0
  96. package/dist/flows/activity/dialog/ActivityDialog.js +1 -0
  97. package/dist/flows/activity/dialog/ActivityFlowBoundary.d.ts +1 -0
  98. package/dist/flows/activity/dialog/ActivityFlowBoundary.js +1 -0
  99. package/dist/flows/activity/driver/context.d.ts +38 -0
  100. package/dist/flows/activity/driver/context.js +1 -0
  101. package/dist/flows/activity/driver/types.d.ts +58 -0
  102. package/dist/flows/activity/orchestrator/controller.d.ts +11 -0
  103. package/dist/flows/activity/orchestrator/controller.js +1 -0
  104. package/dist/flows/activity/orchestrator/index.d.ts +4 -0
  105. package/dist/flows/activity/orchestrator/index.js +1 -0
  106. package/dist/flows/activity/orchestrator/reducer.d.ts +1 -0
  107. package/dist/flows/activity/orchestrator/reducer.js +1 -0
  108. package/dist/flows/activity/orchestrator/types.d.ts +71 -0
  109. package/dist/flows/activity/orchestrator/useActivity.d.ts +94 -0
  110. package/dist/flows/activity/orchestrator/useActivity.js +1 -0
  111. package/dist/flows/activity/widgets/ActivityDetail.d.ts +41 -0
  112. package/dist/flows/activity/widgets/ActivityDetail.js +1 -0
  113. package/dist/flows/activity/widgets/ActivityList.d.ts +38 -0
  114. package/dist/flows/activity/widgets/ActivityList.js +1 -0
  115. package/dist/flows/activity/widgets/useStandaloneActivitySource.js +1 -0
  116. package/dist/flows/deposit/dialog/DepositBootstrapErrorState.js +1 -1
  117. package/dist/flows/deposit/dialog/DepositDialog.d.ts +26 -79
  118. package/dist/flows/deposit/dialog/DepositDialog.js +1 -1
  119. package/dist/flows/deposit/dialog/WalletRequiredState.js +1 -0
  120. package/dist/flows/deposit/dialog/WalletRequiredState.styles.js +1 -0
  121. package/dist/flows/deposit/driver/payloads.d.ts +109 -5
  122. package/dist/flows/deposit/driver/transformers/balanceToBalancesPayload.d.ts +2 -0
  123. package/dist/flows/deposit/driver/transformers/balanceToBalancesPayload.js +1 -1
  124. package/dist/flows/deposit/driver/transformers/index.d.ts +1 -0
  125. package/dist/flows/deposit/driver/transformers/quoteToPayload.d.ts +2 -0
  126. package/dist/flows/deposit/driver/transformers/settlementToPayload.d.ts +25 -0
  127. package/dist/flows/deposit/driver/transformers/settlementToPayload.js +1 -1
  128. package/dist/flows/deposit/driver/transformers/startToAddressesPayload.d.ts +2 -0
  129. package/dist/flows/deposit/driver/transformers/startToAddressesPayload.js +1 -1
  130. package/dist/flows/deposit/driver/transformers/startToBrandPayload.d.ts +1 -0
  131. package/dist/flows/deposit/driver/transformers/startToTargetPayload.d.ts +2 -0
  132. package/dist/flows/deposit/driver/transformers/startToTargetPayload.js +1 -1
  133. package/dist/flows/deposit/driver/transformers/walletAddressToWalletPayload.d.ts +1 -0
  134. package/dist/flows/deposit/driver/types.d.ts +92 -5
  135. package/dist/flows/deposit/orchestrator/controller.js +1 -1
  136. package/dist/flows/deposit/orchestrator/index.d.ts +5 -0
  137. package/dist/flows/deposit/orchestrator/reducer.d.ts +1 -0
  138. package/dist/flows/deposit/orchestrator/reducer.js +1 -1
  139. package/dist/flows/deposit/orchestrator/types.d.ts +276 -12
  140. package/dist/flows/deposit/orchestrator/useDeposit.d.ts +45 -1
  141. package/dist/flows/deposit/orchestrator/useDeposit.js +1 -1
  142. package/dist/flows/deposit/shared/checkoutPopup.js +1 -0
  143. package/dist/flows/deposit/shared/onramp.js +1 -0
  144. package/dist/flows/deposit/widgets/activity/DepositActivityDetail.d.ts +40 -0
  145. package/dist/flows/deposit/widgets/activity/DepositActivityDetail.js +1 -0
  146. package/dist/flows/deposit/widgets/activity/DepositActivityList.d.ts +38 -0
  147. package/dist/flows/deposit/widgets/activity/DepositActivityList.js +1 -0
  148. package/dist/flows/deposit/widgets/activity/index.d.ts +2 -0
  149. package/dist/flows/deposit/widgets/activity/index.js +1 -0
  150. package/dist/flows/deposit/widgets/activity/useDepositActivitySource.js +1 -0
  151. package/dist/flows/deposit/widgets/amount-entry/AmountEntry.d.ts +32 -5
  152. package/dist/flows/deposit/widgets/amount-entry/AmountEntry.js +1 -1
  153. package/dist/flows/deposit/widgets/amount-entry/footerIntent.js +1 -0
  154. package/dist/flows/deposit/widgets/asset-picker/AssetPicker.d.ts +24 -4
  155. package/dist/flows/deposit/widgets/asset-picker/AssetPicker.js +1 -1
  156. package/dist/flows/deposit/widgets/confirm-deposit/ConfirmDeposit.d.ts +37 -4
  157. package/dist/flows/deposit/widgets/confirm-deposit/ConfirmDeposit.js +1 -1
  158. package/dist/flows/deposit/widgets/deposit/Deposit.d.ts +39 -4
  159. package/dist/flows/deposit/widgets/deposit/Deposit.js +1 -1
  160. package/dist/flows/deposit/widgets/deposit/compound/Deposit.d.ts +58 -1
  161. package/dist/flows/deposit/widgets/deposit/compound/Deposit.js +1 -1
  162. package/dist/flows/deposit/widgets/deposit/compound/Deposit.slots.d.ts +6 -0
  163. package/dist/flows/deposit/widgets/deposit/compound/Deposit.slots.js +1 -1
  164. package/dist/flows/deposit/widgets/deposit/compound/Deposit.styles.js +1 -1
  165. package/dist/flows/deposit/widgets/deposit/compound/components/Boundary.d.ts +29 -0
  166. package/dist/flows/deposit/widgets/deposit/compound/components/Boundary.js +1 -0
  167. package/dist/flows/deposit/widgets/deposit/compound/components/Guards.d.ts +28 -0
  168. package/dist/flows/deposit/widgets/deposit/compound/components/Guards.js +1 -0
  169. package/dist/flows/deposit/widgets/deposit/compound/components/Header.d.ts +11 -0
  170. package/dist/flows/deposit/widgets/deposit/compound/components/Header.js +1 -1
  171. package/dist/flows/deposit/widgets/deposit/compound/components/Method.d.ts +7 -0
  172. package/dist/flows/deposit/widgets/deposit/compound/components/Method.js +1 -1
  173. package/dist/flows/deposit/widgets/deposit/compound/components/MethodSection.d.ts +40 -0
  174. package/dist/flows/deposit/widgets/deposit/compound/components/MethodSection.js +1 -0
  175. package/dist/flows/deposit/widgets/deposit/compound/components/Methods.d.ts +15 -9
  176. package/dist/flows/deposit/widgets/deposit/compound/components/Methods.js +1 -1
  177. package/dist/flows/deposit/widgets/deposit/compound/components/Rail.d.ts +18 -0
  178. package/dist/flows/deposit/widgets/deposit/compound/components/Rail.js +1 -0
  179. package/dist/flows/deposit/widgets/deposit/compound/components/RailPicker.d.ts +43 -0
  180. package/dist/flows/deposit/widgets/deposit/compound/components/RailPicker.js +1 -0
  181. package/dist/flows/deposit/widgets/deposit/compound/components/Steps.d.ts +24 -0
  182. package/dist/flows/deposit/widgets/deposit/compound/components/Steps.js +1 -0
  183. package/dist/flows/deposit/widgets/deposit/compound/index.d.ts +2 -1
  184. package/dist/flows/deposit/widgets/deposit/compound/types.d.ts +106 -4
  185. package/dist/flows/deposit/widgets/deposit-status-banner/DepositStatusBanner.d.ts +41 -1
  186. package/dist/flows/deposit/widgets/deposit-status-banner/DepositStatusBanner.js +1 -1
  187. package/dist/flows/deposit/widgets/deposit-status-banner/compound/DepositStatusBanner.js +1 -1
  188. package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/Hero.js +1 -1
  189. package/dist/flows/deposit/widgets/deposit-status-banner/compound/components/PrimaryAction.js +1 -1
  190. package/dist/flows/deposit/widgets/deposit-status-banner/compound/types.d.ts +5 -5
  191. package/dist/flows/deposit/widgets/error-state/ErrorState.d.ts +39 -4
  192. package/dist/flows/deposit/widgets/error-state/ErrorState.js +1 -1
  193. package/dist/flows/deposit/widgets/onramp-amount-entry/OnrampAmountEntry.d.ts +64 -0
  194. package/dist/flows/deposit/widgets/onramp-amount-entry/OnrampAmountEntry.js +1 -0
  195. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/OnrampAmountEntry.d.ts +62 -0
  196. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/OnrampAmountEntry.js +1 -0
  197. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/OnrampAmountEntry.slots.d.ts +14 -0
  198. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/OnrampAmountEntry.slots.js +1 -0
  199. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/OnrampAmountEntry.styles.js +1 -0
  200. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/components/HeroLabel.d.ts +13 -0
  201. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/components/HeroLabel.js +1 -0
  202. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/components/ReceiveChip.d.ts +14 -0
  203. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/components/ReceiveChip.js +1 -0
  204. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/context.js +1 -0
  205. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/index.d.ts +3 -0
  206. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/index.js +1 -0
  207. package/dist/flows/deposit/widgets/onramp-amount-entry/compound/types.d.ts +29 -0
  208. package/dist/flows/deposit/widgets/onramp-amount-entry/index.d.ts +1 -0
  209. package/dist/flows/deposit/widgets/onramp-amount-entry/index.js +1 -0
  210. package/dist/flows/deposit/widgets/onramp-confirm/OnrampConfirm.d.ts +50 -0
  211. package/dist/flows/deposit/widgets/onramp-confirm/OnrampConfirm.js +1 -0
  212. package/dist/flows/deposit/widgets/onramp-confirm/compound/OnrampConfirm.d.ts +42 -0
  213. package/dist/flows/deposit/widgets/onramp-confirm/compound/OnrampConfirm.js +1 -0
  214. package/dist/flows/deposit/widgets/onramp-confirm/compound/OnrampConfirm.slots.d.ts +24 -0
  215. package/dist/flows/deposit/widgets/onramp-confirm/compound/OnrampConfirm.slots.js +1 -0
  216. package/dist/flows/deposit/widgets/onramp-confirm/compound/OnrampConfirm.styles.js +1 -0
  217. package/dist/flows/deposit/widgets/onramp-confirm/compound/components/Body.d.ts +16 -0
  218. package/dist/flows/deposit/widgets/onramp-confirm/compound/components/Body.js +1 -0
  219. package/dist/flows/deposit/widgets/onramp-confirm/compound/components/Header.d.ts +15 -0
  220. package/dist/flows/deposit/widgets/onramp-confirm/compound/components/Header.js +1 -0
  221. package/dist/flows/deposit/widgets/onramp-confirm/compound/components/Summary.d.ts +15 -0
  222. package/dist/flows/deposit/widgets/onramp-confirm/compound/components/Summary.js +1 -0
  223. package/dist/flows/deposit/widgets/onramp-confirm/compound/context.d.ts +25 -0
  224. package/dist/flows/deposit/widgets/onramp-confirm/compound/context.js +1 -0
  225. package/dist/flows/deposit/widgets/onramp-confirm/compound/index.d.ts +4 -0
  226. package/dist/flows/deposit/widgets/onramp-confirm/compound/index.js +1 -0
  227. package/dist/flows/deposit/widgets/onramp-confirm/compound/types.d.ts +62 -0
  228. package/dist/flows/deposit/widgets/onramp-confirm/index.d.ts +1 -0
  229. package/dist/flows/deposit/widgets/onramp-confirm/index.js +1 -0
  230. package/dist/flows/deposit/widgets/onramp-payment-pending/OnrampPaymentPending.d.ts +48 -0
  231. package/dist/flows/deposit/widgets/onramp-payment-pending/OnrampPaymentPending.js +1 -0
  232. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/OnrampPaymentPending.d.ts +63 -0
  233. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/OnrampPaymentPending.js +1 -0
  234. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/OnrampPaymentPending.slots.d.ts +14 -0
  235. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/OnrampPaymentPending.slots.js +1 -0
  236. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/components/ReopenButton.d.ts +11 -0
  237. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/components/ReopenButton.js +1 -0
  238. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/context.js +1 -0
  239. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/index.d.ts +2 -0
  240. package/dist/flows/deposit/widgets/onramp-payment-pending/compound/index.js +1 -0
  241. package/dist/flows/deposit/widgets/onramp-payment-pending/index.d.ts +1 -0
  242. package/dist/flows/deposit/widgets/onramp-payment-pending/index.js +1 -0
  243. package/dist/flows/deposit/widgets/processing-state/ProcessingState.d.ts +30 -4
  244. package/dist/flows/deposit/widgets/processing-state/ProcessingState.js +1 -1
  245. package/dist/flows/deposit/widgets/success-state/SuccessState.d.ts +38 -4
  246. package/dist/flows/deposit/widgets/success-state/SuccessState.js +1 -1
  247. package/dist/flows/deposit/widgets/transfer-crypto/TransferCrypto.d.ts +34 -3
  248. package/dist/flows/deposit/widgets/transfer-crypto/TransferCrypto.js +1 -1
  249. package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.d.ts +1 -1
  250. package/dist/flows/deposit/widgets/transfer-crypto/compound/TransferCrypto.styles.js +1 -1
  251. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Address.js +1 -1
  252. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Disclosure.d.ts +5 -2
  253. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Disclosure.js +1 -1
  254. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Header.d.ts +6 -0
  255. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/Header.js +1 -1
  256. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/QrCode.d.ts +4 -10
  257. package/dist/flows/deposit/widgets/transfer-crypto/compound/components/QrCode.js +1 -1
  258. package/dist/flows/deposit/widgets/transfer-crypto/compound/types.d.ts +16 -2
  259. package/dist/flows/shared/transformers/computeQuoteAttrs.d.ts +1 -0
  260. package/dist/flows/shared/transformers/index.d.ts +1 -0
  261. package/dist/flows/shared/transformers/pickRelevantSettlement.d.ts +1 -0
  262. package/dist/flows/shared/transformers/pickRelevantSettlement.js +1 -1
  263. package/dist/flows/shared/transformers/testnets.js +1 -0
  264. package/dist/flows/withdraw/bindings/WithdrawBindings.d.ts +92 -0
  265. package/dist/flows/withdraw/bindings/WithdrawBindings.js +1 -0
  266. package/dist/flows/withdraw/bindings/index.d.ts +1 -0
  267. package/dist/flows/withdraw/bindings/index.js +1 -0
  268. package/dist/flows/withdraw/dialog/WithdrawDialog.d.ts +44 -71
  269. package/dist/flows/withdraw/dialog/WithdrawDialog.js +1 -1
  270. package/dist/flows/withdraw/driver/dto.d.ts +8 -7
  271. package/dist/flows/withdraw/driver/payloads.d.ts +16 -1
  272. package/dist/flows/withdraw/driver/transformers/settlementToWithdrawalPayload.js +1 -1
  273. package/dist/flows/withdraw/driver/transformers/supportedAssetsToReceiveOptionsPayload.js +1 -1
  274. package/dist/flows/withdraw/driver/types.d.ts +77 -14
  275. package/dist/flows/withdraw/orchestrator/controller.js +1 -1
  276. package/dist/flows/withdraw/orchestrator/index.d.ts +1 -1
  277. package/dist/flows/withdraw/orchestrator/reducer.js +1 -1
  278. package/dist/flows/withdraw/orchestrator/types.d.ts +218 -35
  279. package/dist/flows/withdraw/orchestrator/useWithdraw.d.ts +36 -1
  280. package/dist/flows/withdraw/orchestrator/useWithdraw.js +1 -1
  281. package/dist/flows/withdraw/widgets/activity/WithdrawActivityDetail.d.ts +39 -0
  282. package/dist/flows/withdraw/widgets/activity/WithdrawActivityDetail.js +1 -0
  283. package/dist/flows/withdraw/widgets/activity/WithdrawActivityList.d.ts +36 -0
  284. package/dist/flows/withdraw/widgets/activity/WithdrawActivityList.js +1 -0
  285. package/dist/flows/withdraw/widgets/activity/index.d.ts +2 -0
  286. package/dist/flows/withdraw/widgets/activity/index.js +1 -0
  287. package/dist/flows/withdraw/widgets/activity/useWithdrawActivitySource.js +1 -0
  288. package/dist/flows/withdraw/widgets/withdraw/compound/Withdraw.d.ts +60 -0
  289. package/dist/flows/withdraw/widgets/withdraw/compound/Withdraw.js +1 -0
  290. package/dist/flows/withdraw/widgets/withdraw/compound/Withdraw.slots.d.ts +13 -0
  291. package/dist/flows/withdraw/widgets/withdraw/compound/Withdraw.slots.js +1 -0
  292. package/dist/flows/withdraw/widgets/withdraw/compound/components/Boundary.d.ts +29 -0
  293. package/dist/flows/withdraw/widgets/withdraw/compound/components/Boundary.js +1 -0
  294. package/dist/flows/withdraw/widgets/withdraw/compound/components/Guards.d.ts +25 -0
  295. package/dist/flows/withdraw/widgets/withdraw/compound/components/Guards.js +1 -0
  296. package/dist/flows/withdraw/widgets/withdraw/compound/components/Steps.d.ts +27 -0
  297. package/dist/flows/withdraw/widgets/withdraw/compound/components/Steps.js +1 -0
  298. package/dist/flows/withdraw/widgets/withdraw/compound/index.d.ts +3 -0
  299. package/dist/flows/withdraw/widgets/withdraw/compound/index.js +1 -0
  300. package/dist/flows/withdraw/widgets/withdraw-error/WithdrawError.d.ts +45 -2
  301. package/dist/flows/withdraw/widgets/withdraw-error/WithdrawError.js +1 -1
  302. package/dist/flows/withdraw/widgets/withdraw-form/WithdrawForm.d.ts +32 -12
  303. package/dist/flows/withdraw/widgets/withdraw-form/WithdrawForm.js +1 -1
  304. package/dist/flows/withdraw/widgets/withdraw-form/compound/WithdrawForm.js +1 -1
  305. package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Body.d.ts +7 -6
  306. package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Header.d.ts +6 -1
  307. package/dist/flows/withdraw/widgets/withdraw-form/compound/components/Header.js +1 -1
  308. package/dist/flows/withdraw/widgets/withdraw-form/compound/components/RecipientField.d.ts +7 -5
  309. package/dist/flows/withdraw/widgets/withdraw-form/compound/components/RecipientField.js +1 -1
  310. package/dist/flows/withdraw/widgets/withdraw-form/compound/types.d.ts +15 -5
  311. package/dist/flows/withdraw/widgets/withdraw-form/validation.js +1 -1
  312. package/dist/flows/withdraw/widgets/withdraw-in-progress/WithdrawInProgress.d.ts +39 -3
  313. package/dist/flows/withdraw/widgets/withdraw-in-progress/WithdrawInProgress.js +1 -1
  314. package/dist/flows/withdraw/widgets/withdraw-success/WithdrawSuccess.d.ts +46 -2
  315. package/dist/flows/withdraw/widgets/withdraw-success/WithdrawSuccess.js +1 -1
  316. package/dist/format/index.d.ts +2 -1
  317. package/dist/format/index.js +1 -1
  318. package/dist/i18n/index.d.ts +5 -4
  319. package/dist/i18n/index.js +1 -1
  320. package/dist/i18n/locales/ar.js +1 -1
  321. package/dist/i18n/locales/es.js +1 -1
  322. package/dist/i18n/locales/source-keys.d.ts +12 -0
  323. package/dist/i18n/locales/source-keys.js +0 -0
  324. package/dist/icons/index.d.ts +5 -1
  325. package/dist/icons/index.js +1 -1
  326. package/dist/index.d.ts +35 -11
  327. package/dist/index.js +1 -1
  328. package/dist/package.js +1 -1
  329. package/dist/scope/KitPortalScope.js +1 -1
  330. package/dist/scope/KitScope.d.ts +27 -1
  331. package/dist/scope/KitScope.js +1 -1
  332. package/dist/scope/context.d.ts +24 -1
  333. package/dist/scope/index.d.ts +1 -1
  334. package/dist/shared/attribution/Attribution.js +1 -0
  335. package/dist/shared/attribution/Attribution.slots.js +1 -0
  336. package/dist/shared/attribution/Attribution.styles.js +1 -0
  337. package/dist/shared/attribution/index.js +1 -0
  338. package/dist/shared/chains/index.d.ts +48 -29
  339. package/dist/shared/chains/index.js +1 -1
  340. package/dist/shared/constants/brand-intercom.js +1 -0
  341. package/dist/shared/cuer/Cuer.js +1 -1
  342. package/dist/shared/dialog/DialogShell.d.ts +21 -6
  343. package/dist/shared/dialog/DialogShell.js +1 -1
  344. package/dist/shared/dialog/Frame.js +1 -1
  345. package/dist/shared/dialog/LoadingState.js +1 -0
  346. package/dist/shared/dialog/LoadingState.styles.js +1 -0
  347. package/dist/shared/dialog/StepTransition.js +1 -1
  348. package/dist/shared/dialog/useDirectionalChevronTransform.js +1 -1
  349. package/dist/shared/driver/types.d.ts +4 -3
  350. package/dist/shared/format/formatSmartRelative.d.ts +25 -0
  351. package/dist/shared/format/formatSmartRelative.js +1 -0
  352. package/dist/shared/format/formatUsd.js +1 -1
  353. package/dist/shared/i18n/KitI18nProvider.d.ts +11 -8
  354. package/dist/shared/i18n/KitI18nProvider.js +1 -1
  355. package/dist/shared/i18n/createKitI18n.d.ts +79 -16
  356. package/dist/shared/i18n/createKitI18n.js +1 -1
  357. package/dist/shared/i18n/useLingui.d.ts +11 -3
  358. package/dist/shared/icons/ActivityIcon.d.ts +12 -0
  359. package/dist/shared/icons/ActivityIcon.js +1 -0
  360. package/dist/shared/icons/BitcoinIcon.d.ts +14 -0
  361. package/dist/shared/icons/BitcoinIcon.js +1 -0
  362. package/dist/shared/icons/CardIcon.d.ts +16 -0
  363. package/dist/shared/icons/CardIcon.js +1 -0
  364. package/dist/shared/icons/LogoIcon.d.ts +13 -0
  365. package/dist/shared/icons/LogoIcon.js +1 -0
  366. package/dist/shared/merchant-link/MerchantLink.d.ts +1 -0
  367. package/dist/shared/merchant-link/MerchantLink.js +1 -0
  368. package/dist/shared/merchant-link/MerchantLinkButton.d.ts +1 -0
  369. package/dist/shared/merchant-link/MerchantLinkButton.js +1 -0
  370. package/dist/shared/merchant-link/index.d.ts +1 -0
  371. package/dist/shared/merchant-link/index.js +1 -0
  372. package/dist/shared/merchant-link/resolveMerchantLink.js +1 -0
  373. package/dist/shared/orchestrator/activityOpenInput.d.ts +21 -0
  374. package/dist/shared/orchestrator/createActivityReducers.js +1 -0
  375. package/dist/shared/orchestrator/index.d.ts +2 -0
  376. package/dist/shared/orchestrator/index.js +1 -1
  377. package/dist/shared/orchestrator/resolveActivityEntry.d.ts +1 -0
  378. package/dist/shared/orchestrator/resolveActivityEntry.js +1 -0
  379. package/dist/shared/orchestrator/toFailure.js +1 -1
  380. package/dist/shared/orchestrator/types.d.ts +8 -0
  381. package/dist/shared/orchestrator/useOnrampSessionWatcher.js +1 -0
  382. package/dist/shared/orchestrator/useSettlementWatcher.js +1 -1
  383. package/dist/shared/presentation/index.js +1 -0
  384. package/dist/shared/presentation/types.d.ts +30 -0
  385. package/dist/shared/presentation/types.js +1 -0
  386. package/dist/shared/presentation/useResolvedSurfaceKind.js +1 -0
  387. package/dist/shared/primitives/TxHashValue/TxHashValue.js +1 -1
  388. package/dist/shared/support/SupportConfigContext.d.ts +1 -0
  389. package/dist/shared/support/SupportConfigContext.js +1 -0
  390. package/dist/shared/support/SupportLink.d.ts +1 -0
  391. package/dist/shared/support/SupportLink.js +1 -0
  392. package/dist/shared/support/SupportSpinner.d.ts +1 -0
  393. package/dist/shared/support/SupportSpinner.js +1 -0
  394. package/dist/shared/support/index.d.ts +2 -0
  395. package/dist/shared/support/index.js +1 -0
  396. package/dist/shared/support/intercom-loader.d.ts +17 -0
  397. package/dist/shared/support/intercom-loader.js +1 -0
  398. package/dist/shared/support/types.d.ts +43 -0
  399. package/dist/shared/support/useIntercomMerchantContext.d.ts +27 -0
  400. package/dist/shared/support/useIntercomMerchantContext.js +1 -0
  401. package/dist/shared/support/useIntercomShutdownOnUnmount.js +1 -0
  402. package/dist/shared/support/useMerchantContext.d.ts +1 -0
  403. package/dist/shared/support/useMerchantContext.js +1 -0
  404. package/dist/shared/support/useSupportTrigger.js +1 -0
  405. package/dist/shared/terms/TermsConfigContext.d.ts +1 -0
  406. package/dist/shared/terms/TermsConfigContext.js +1 -0
  407. package/dist/shared/terms/TermsLink.d.ts +1 -0
  408. package/dist/shared/terms/TermsLink.js +1 -0
  409. package/dist/shared/terms/index.d.ts +1 -0
  410. package/dist/shared/terms/index.js +1 -0
  411. package/dist/shared/terms/types.d.ts +43 -0
  412. package/dist/shared/ui/AdaptiveSurface/AdaptiveSurface.d.ts +52 -0
  413. package/dist/shared/ui/AdaptiveSurface/AdaptiveSurface.js +1 -0
  414. package/dist/shared/ui/AdaptiveSurface/index.d.ts +2 -0
  415. package/dist/shared/ui/AdaptiveSurface/index.js +1 -0
  416. package/dist/shared/ui/Card/Card.d.ts +12 -9
  417. package/dist/shared/ui/Card/Card.js +1 -1
  418. package/dist/shared/ui/Card/Card.styles.js +1 -1
  419. package/dist/shared/ui/Details/Details.d.ts +9 -1
  420. package/dist/shared/ui/Details/Details.styles.js +1 -1
  421. package/dist/shared/ui/Dialog/Dialog.d.ts +10 -8
  422. package/dist/shared/ui/Dialog/Dialog.js +1 -1
  423. package/dist/shared/ui/Dialog/Dialog.styles.js +1 -1
  424. package/dist/shared/ui/Drawer/Drawer.d.ts +135 -0
  425. package/dist/shared/ui/Drawer/Drawer.js +1 -0
  426. package/dist/shared/ui/Drawer/Drawer.slots.d.ts +19 -0
  427. package/dist/shared/ui/Drawer/Drawer.slots.js +1 -0
  428. package/dist/shared/ui/Drawer/Drawer.styles.js +1 -0
  429. package/dist/shared/ui/Drawer/index.d.ts +2 -0
  430. package/dist/shared/ui/Drawer/index.js +1 -0
  431. package/dist/shared/ui/Select/Select.js +1 -1
  432. package/dist/shared/ui/SelectableTile/SelectableTile.d.ts +21 -8
  433. package/dist/shared/ui/SelectableTile/SelectableTile.js +1 -1
  434. package/dist/shared/ui/Steps/Steps.d.ts +52 -0
  435. package/dist/shared/ui/Steps/Steps.js +1 -0
  436. package/dist/shared/ui/Steps/Steps.slots.d.ts +7 -0
  437. package/dist/shared/ui/Steps/Steps.slots.js +1 -0
  438. package/dist/shared/ui/Steps/Steps.styles.js +1 -0
  439. package/dist/shared/ui/Steps/index.d.ts +2 -0
  440. package/dist/shared/ui/Steps/index.js +1 -0
  441. package/dist/shared/ui/Tabs/Tabs.d.ts +79 -0
  442. package/dist/shared/ui/Tabs/Tabs.js +1 -0
  443. package/dist/shared/ui/Tabs/Tabs.slots.d.ts +11 -0
  444. package/dist/shared/ui/Tabs/Tabs.slots.js +1 -0
  445. package/dist/shared/ui/Tabs/Tabs.styles.js +1 -0
  446. package/dist/shared/ui/Tabs/index.d.ts +2 -0
  447. package/dist/shared/ui/Tabs/index.js +1 -0
  448. package/dist/shared/ui/WalletRow/WalletRow.d.ts +1 -1
  449. package/dist/shared/ui/WalletRow/WalletRow.js +1 -1
  450. package/dist/shared/ui/surfaceContext.d.ts +9 -0
  451. package/dist/shared/ui/surfaceContext.js +1 -0
  452. package/dist/shared/utils/assertNever.js +1 -0
  453. package/dist/shared/utils/logos/types.d.ts +1 -1
  454. package/dist/shared/utils/useDeepMemo.js +1 -0
  455. package/dist/shared/wallet/ConnectWalletContext.d.ts +17 -0
  456. package/dist/shared/wallet/ConnectWalletContext.js +1 -0
  457. package/dist/shared/widgets/activity/ActivityTrigger.js +1 -0
  458. package/dist/shared/widgets/activity/ActivityTrigger.styles.js +1 -0
  459. package/dist/shared/widgets/activity/adapters/settlementToWidgetProps.js +1 -0
  460. package/dist/shared/widgets/activity/compound/Activity.d.ts +95 -0
  461. package/dist/shared/widgets/activity/compound/Activity.js +1 -0
  462. package/dist/shared/widgets/activity/compound/Activity.slots.d.ts +22 -0
  463. package/dist/shared/widgets/activity/compound/Activity.slots.js +1 -0
  464. package/dist/shared/widgets/activity/compound/Activity.styles.js +1 -0
  465. package/dist/shared/widgets/activity/compound/ActivityDetail.d.ts +82 -0
  466. package/dist/shared/widgets/activity/compound/ActivityDetail.js +1 -0
  467. package/dist/shared/widgets/activity/compound/Row.slots.d.ts +21 -0
  468. package/dist/shared/widgets/activity/compound/Row.slots.js +1 -0
  469. package/dist/shared/widgets/activity/compound/Row.styles.js +1 -0
  470. package/dist/shared/widgets/activity/compound/components/ActivityHeader.d.ts +39 -0
  471. package/dist/shared/widgets/activity/compound/components/ActivityHeader.js +1 -0
  472. package/dist/shared/widgets/activity/compound/components/Empty.d.ts +15 -0
  473. package/dist/shared/widgets/activity/compound/components/Empty.js +1 -0
  474. package/dist/shared/widgets/activity/compound/components/ErrorView.d.ts +26 -0
  475. package/dist/shared/widgets/activity/compound/components/ErrorView.js +1 -0
  476. package/dist/shared/widgets/activity/compound/components/List.d.ts +23 -0
  477. package/dist/shared/widgets/activity/compound/components/List.js +1 -0
  478. package/dist/shared/widgets/activity/compound/components/Row.d.ts +51 -0
  479. package/dist/shared/widgets/activity/compound/components/Row.js +1 -0
  480. package/dist/shared/widgets/activity/compound/components/StatusPip.js +1 -0
  481. package/dist/shared/widgets/activity/compound/context.d.ts +95 -0
  482. package/dist/shared/widgets/activity/compound/context.js +1 -0
  483. package/dist/shared/widgets/activity/compound/index.d.ts +8 -0
  484. package/dist/shared/widgets/activity/compound/index.js +1 -0
  485. package/dist/shared/widgets/activity/index.js +1 -0
  486. package/dist/shared/widgets/activity/payloads.d.ts +108 -0
  487. package/dist/shared/widgets/activity/transformers/activityResponseToPayload.js +1 -0
  488. package/dist/shared/widgets/activity/transformers/resolveDirection.js +1 -0
  489. package/dist/shared/widgets/amount-entry/compound/AmountEntry.d.ts +10 -2
  490. package/dist/shared/widgets/amount-entry/compound/AmountEntry.js +1 -1
  491. package/dist/shared/widgets/amount-entry/compound/AmountEntry.slots.d.ts +6 -0
  492. package/dist/shared/widgets/amount-entry/compound/AmountEntry.slots.js +1 -1
  493. package/dist/shared/widgets/amount-entry/compound/AmountEntry.styles.js +1 -1
  494. package/dist/shared/widgets/amount-entry/compound/components/Details.d.ts +34 -0
  495. package/dist/shared/widgets/amount-entry/compound/components/Details.js +1 -0
  496. package/dist/shared/widgets/amount-entry/compound/components/Footer.d.ts +2 -1
  497. package/dist/shared/widgets/amount-entry/compound/components/Footer.js +1 -1
  498. package/dist/shared/widgets/amount-entry/compound/components/Header.d.ts +6 -1
  499. package/dist/shared/widgets/amount-entry/compound/components/Header.js +1 -1
  500. package/dist/shared/widgets/amount-entry/compound/components/Hero/Hero.js +1 -1
  501. package/dist/shared/widgets/amount-entry/compound/components/Hero/SwapBackdrop.js +1 -1
  502. package/dist/shared/widgets/amount-entry/compound/components/Notice.d.ts +7 -0
  503. package/dist/shared/widgets/amount-entry/compound/components/Notice.js +1 -0
  504. package/dist/shared/widgets/amount-entry/compound/index.d.ts +1 -1
  505. package/dist/shared/widgets/amount-entry/compound/types.d.ts +69 -3
  506. package/dist/shared/widgets/asset-picker/compound/AssetPicker.d.ts +3 -0
  507. package/dist/shared/widgets/asset-picker/compound/AssetPicker.js +1 -1
  508. package/dist/shared/widgets/asset-picker/compound/AssetPicker.slots.d.ts +2 -0
  509. package/dist/shared/widgets/asset-picker/compound/AssetPicker.slots.js +1 -1
  510. package/dist/shared/widgets/asset-picker/compound/AssetPicker.styles.js +1 -1
  511. package/dist/shared/widgets/asset-picker/compound/components/Asset.d.ts +7 -1
  512. package/dist/shared/widgets/asset-picker/compound/components/Asset.js +1 -1
  513. package/dist/shared/widgets/asset-picker/compound/components/Empty.d.ts +15 -0
  514. package/dist/shared/widgets/asset-picker/compound/components/Empty.js +1 -0
  515. package/dist/shared/widgets/asset-picker/compound/components/Header.d.ts +6 -1
  516. package/dist/shared/widgets/asset-picker/compound/components/Header.js +1 -1
  517. package/dist/shared/widgets/asset-picker/compound/types.d.ts +15 -1
  518. package/dist/shared/widgets/confirm-transfer/compound/ConfirmTransfer.styles.js +1 -1
  519. package/dist/shared/widgets/confirm-transfer/compound/components/Breakdown.js +1 -1
  520. package/dist/shared/widgets/confirm-transfer/compound/components/Disclaimer.d.ts +4 -3
  521. package/dist/shared/widgets/confirm-transfer/compound/components/Disclaimer.js +1 -1
  522. package/dist/shared/widgets/confirm-transfer/compound/components/QuoteTimer.js +1 -1
  523. package/dist/shared/widgets/error-state/compound/components/AssetValue.js +1 -1
  524. package/dist/shared/widgets/error-state/compound/components/HelpInfo.js +1 -1
  525. package/dist/shared/widgets/error-state/compound/components/MoreDetails.d.ts +1 -1
  526. package/dist/shared/widgets/error-state/compound/components/MoreDetails.js +1 -1
  527. package/dist/shared/widgets/error-state/compound/components/StatusValue.js +1 -1
  528. package/dist/shared/widgets/processing-state/compound/ProcessingState.d.ts +1 -5
  529. package/dist/shared/widgets/processing-state/compound/ProcessingState.js +1 -1
  530. package/dist/shared/widgets/processing-state/compound/ProcessingState.slots.d.ts +0 -1
  531. package/dist/shared/widgets/processing-state/compound/ProcessingState.slots.js +1 -1
  532. package/dist/shared/widgets/processing-state/compound/ProcessingState.styles.js +1 -1
  533. package/dist/shared/widgets/processing-state/compound/components/Details.d.ts +6 -1
  534. package/dist/shared/widgets/processing-state/compound/components/Details.js +1 -1
  535. package/dist/shared/widgets/processing-state/compound/components/Header.d.ts +4 -3
  536. package/dist/shared/widgets/processing-state/compound/components/Header.js +1 -1
  537. package/dist/shared/widgets/processing-state/compound/components/Hero.d.ts +14 -7
  538. package/dist/shared/widgets/processing-state/compound/components/Hero.js +1 -1
  539. package/dist/shared/widgets/processing-state/compound/components/Rows.js +1 -1
  540. package/dist/shared/widgets/processing-state/compound/components/StatusPill.js +1 -1
  541. package/dist/shared/widgets/processing-state/compound/components/splitAmount.js +1 -0
  542. package/dist/shared/widgets/processing-state/compound/index.d.ts +1 -1
  543. package/dist/shared/widgets/processing-state/compound/types.d.ts +11 -29
  544. package/dist/shared/widgets/success-state/compound/components/Actions.js +1 -1
  545. package/dist/shared/widgets/success-state/compound/components/AssetValue.js +1 -1
  546. package/dist/shared/widgets/success-state/compound/components/MoreDetails.d.ts +1 -1
  547. package/dist/shared/widgets/success-state/compound/components/MoreDetails.js +1 -1
  548. package/dist/shared/widgets/success-state/compound/components/RouteValue.js +1 -1
  549. package/dist/shared/widgets/success-state/compound/components/StatusPill.js +1 -1
  550. package/dist/shared/widgets/success-state/compound/types.d.ts +5 -5
  551. package/dist/storage/context.d.ts +9 -1
  552. package/dist/storage/context.js +1 -1
  553. package/dist/storage/index.d.ts +1 -1
  554. package/dist/stridge/StridgeProvider.d.ts +177 -35
  555. package/dist/stridge/StridgeProvider.js +1 -1
  556. package/dist/stridge/depositOwner.js +1 -0
  557. package/dist/stridge/optionalWagmi.js +1 -0
  558. package/dist/stridge/stubs.js +1 -1
  559. package/dist/styles/index.css +567 -12
  560. package/dist/types.d.ts +8 -6
  561. package/dist/ui/index.d.ts +9 -1
  562. package/dist/ui/index.js +1 -1
  563. package/dist/version.d.ts +10 -0
  564. package/dist/version.js +1 -0
  565. package/dist/withdraw/compound/index.d.ts +11 -8
  566. package/dist/withdraw/compound/index.js +1 -1
  567. package/dist/withdraw/dialog/index.d.ts +4 -1
  568. package/dist/withdraw/widgets/index.d.ts +7 -0
  569. package/dist/withdraw/widgets/index.js +1 -0
  570. package/package.json +31 -7
  571. package/dist/_internal/deposit/widgets/index.d.ts +0 -11
  572. package/dist/_internal/deposit/widgets/index.js +0 -1
  573. package/dist/_internal/withdraw/widgets/index.d.ts +0 -5
  574. package/dist/_internal/withdraw/widgets/index.js +0 -1
  575. package/dist/flows/withdraw/dialog/WithdrawDialogEventsContext.d.ts +0 -36
  576. package/dist/flows/withdraw/dialog/WithdrawDialogEventsContext.js +0 -1
  577. package/dist/shared/widgets/processing-state/compound/components/Actions.d.ts +0 -17
  578. package/dist/shared/widgets/processing-state/compound/components/Actions.js +0 -1
  579. package/dist/stridge/StridgeContext.d.ts +0 -29
  580. package/dist/stridge/StridgeContext.js +0 -1
@@ -1,7 +1,9 @@
1
+ import { Presentation } from "../shared/presentation/types.js";
1
2
  //#region src/scope/context.d.ts
2
3
  type KitRadius = "sharp" | "subtle" | "rounded" | "pill";
3
4
  type KitTheme = "dark" | "light";
4
5
  type KitDirection = "ltr" | "rtl";
6
+ type KitAttribution = "visible" | "hidden";
5
7
  /**
6
8
  * Destination token credited by the gateway flow.
7
9
  */
@@ -53,10 +55,31 @@ interface KitConfig {
53
55
  * behavior when they render outside the provider's DOM subtree.
54
56
  */
55
57
  direction?: KitDirection;
58
+ /**
59
+ * Active BCP-47 locale tag (e.g. `"en"`, `"ar"`, `"fa"`, `"ar-EG"`). Forwarded by `KitProvider`
60
+ * from `i18n.locale` and stamped onto every kit scope as `data-stridge-locale="…"` so the host
61
+ * can target script-specific styling (typically the font stack) per locale — RTL alone isn't
62
+ * fine-grained enough (Arabic and Persian are both RTL but commonly want different faces).
63
+ */
64
+ locale?: string;
56
65
  /**
57
66
  * Destination token configuration.
58
67
  */
59
68
  target?: KitTarget;
69
+ /**
70
+ * Resolved state of the "Powered by Stridge" attribution row. `"visible"` (default) lets the
71
+ * gateway frame auto-mount the brand row at the bottom of every step; `"hidden"` suppresses
72
+ * the auto-mount for white-label installs. Explicit `<Stridge.PoweredBy />` compositions
73
+ * ignore this value and always render — the contract is "set `attribution=\"hidden\"` when
74
+ * composing the brand row manually".
75
+ */
76
+ attribution?: KitAttribution;
77
+ /**
78
+ * How gateway surfaces present themselves — `"auto"` (default) renders a centred dialog on wide
79
+ * containers and a bottom-sheet drawer below the breakpoint, `"dialog"` / `"drawer"` force one.
80
+ * Read by {@link AdaptiveSurface} as the global default; a per-surface `presentation` prop wins.
81
+ */
82
+ presentation?: Presentation;
60
83
  }
61
84
  /**
62
85
  * Reads the active {@link KitConfig} from the nearest provider. Returns `{}` when no provider is
@@ -64,4 +87,4 @@ interface KitConfig {
64
87
  */
65
88
  declare function useKitConfig(): KitConfig;
66
89
  //#endregion
67
- export { KitConfig, KitDirection, KitRadius, KitTarget, KitTheme, useKitConfig };
90
+ export { KitAttribution, KitConfig, KitDirection, KitRadius, KitTarget, KitTheme, useKitConfig };
@@ -1,3 +1,3 @@
1
- import { KitConfig, KitDirection, KitRadius, KitTarget, KitTheme, useKitConfig } from "./context.js";
1
+ import { KitAttribution, KitConfig, KitDirection, KitRadius, KitTarget, KitTheme, useKitConfig } from "./context.js";
2
2
  import { KitPortalScope } from "./KitPortalScope.js";
3
3
  import { KitScope } from "./KitScope.js";
@@ -0,0 +1 @@
1
+ "use client";import{useLingui as e}from"../i18n/useLingui.js";import"../../i18n/index.js";import{joinClassNames as t}from"../utils/joinClassNames.js";import{LogoIcon as n}from"../icons/LogoIcon.js";import"../../icons/index.js";import{ATTRIBUTION_SLOTS as r}from"./Attribution.slots.js";import{elementStyles as i,styles as a}from"./Attribution.styles.js";import{Fragment as o,jsx as s,jsxs as c}from"react/jsx-runtime";import*as l from"@stylexjs/stylex";function u({href:u=`https://stridge.com`,target:d=`_blank`,rel:f=`noopener noreferrer`,asStatic:p,className:m,style:h}){let{_:g}=e(),_=l.props(a.root),v=l.props(a.link,!p&&a.anchor),y=l.props(i.prefix),b=l.props(i.mark),x=l.props(i.wordmark),S=t(_.className,m),C=_.style||h?{..._.style,...h}:void 0,w=c(o,{children:[s(`span`,{"data-stridge-slot":r.prefix,className:y.className,style:y.style,children:g({id:`g2UNkE`,message:`Powered by`})}),s(`span`,{"data-stridge-slot":r.mark,className:b.className,style:b.style,children:s(n,{"aria-hidden":!0,focusable:!1})}),s(`span`,{"data-stridge-slot":r.wordmark,className:x.className,style:x.style,children:`Stridge`})]});return s(`div`,{"data-stridge-slot":r.root,className:S,style:C,children:p?s(`span`,{className:v.className,style:v.style,children:w}):s(`a`,{href:u,target:d,rel:f,className:v.className,style:v.style,children:w})})}export{u as Attribution};
@@ -0,0 +1 @@
1
+ const e={root:`attribution`,prefix:`attribution-prefix`,mark:`attribution-mark`,wordmark:`attribution-wordmark`};export{e as ATTRIBUTION_SLOTS};
@@ -0,0 +1 @@
1
+ const e={root:{"Attribution__styles.root":`Attribution__styles.root`,"display-k1xSpc":`x78zum5`,"flexDirection-kXwgrk":`x1q0g3np`,"alignItems-kGNEyG":`x6s0dn4`,"justifyContent-kjj79g":`xl56j7k`,"paddingTop-kLKAdn":`x19ment4`,"paddingBottom-kGO01o":`xfvigk`,"paddingInline-kg3NbH":`x1ujb8i1`,$$css:`@stridge/kit:src/shared/attribution/Attribution.styles.ts:11`},link:{"Attribution__styles.link":`Attribution__styles.link`,"display-k1xSpc":`x3nfvp2`,"flexDirection-kXwgrk":`x1q0g3np`,"alignItems-kGNEyG":`x6s0dn4`,"gap-kOIVth":`x1a6yh9e`,"textDecoration-kybGjl":`x1hl2dhg`,"outline-kI3sdo":`x1a2a7pz`,"transitionProperty-k1ekBW":`xt3l3uh`,"transitionDuration-kIyJzY":`x1vhb3u9`,"transitionTimingFunction-kAMwcw":`x1xv5090`,$$css:`@stridge/kit:src/shared/attribution/Attribution.styles.ts:20`},anchor:{"Attribution__styles.anchor":`Attribution__styles.anchor`,":focus-visible_outline-k3Woio":`x1gvykhg`,":focus-visible_outlineOffset-kiEn40":`x7s97pk`,$$css:`@stridge/kit:src/shared/attribution/Attribution.styles.ts:35`}},t={prefix:{"Attribution__elementStyles.prefix":`Attribution__elementStyles.prefix`,"fontSize-kGuDYH":`x1oae1zf`,"fontWeight-k63SB2":`xxjjie5`,"lineHeight-kLWn49":`x1d3mw78`,"color-kMwMTN":`xd2gg92`,":is(a:hover, a:focus-visible) [data-stridge-slot~='attribution-prefix']_color-kKNNVu":`x1wa2jhk`,$$css:`@stridge/kit:src/shared/attribution/Attribution.styles.ts:51`},mark:{"Attribution__elementStyles.mark":`Attribution__elementStyles.mark`,"display-k1xSpc":`x3nfvp2`,"alignItems-kGNEyG":`x6s0dn4`,"color-kMwMTN":`x9irweu`,":is(a:hover, a:focus-visible) [data-stridge-slot~='attribution-mark']_color-kEC4n1":`x1perupi`,$$css:`@stridge/kit:src/shared/attribution/Attribution.styles.ts:60`},wordmark:{"Attribution__elementStyles.wordmark":`Attribution__elementStyles.wordmark`,"fontSize-kGuDYH":`x1oae1zf`,"fontWeight-k63SB2":`x1qvi77d`,"letterSpacing-kb6lSQ":`x1ixy4ik`,"lineHeight-kLWn49":`x1d3mw78`,"color-kMwMTN":`x1nxg1fm`,":is(a:hover, a:focus-visible) [data-stridge-slot~='attribution-wordmark']_color-kKiZkk":`x19k0ldo`,":is(a:hover, a:focus-visible) [data-stridge-slot~='attribution-wordmark']_textDecoration-k7BEHM":`x1l0eogd`,":is(a:hover, a:focus-visible) [data-stridge-slot~='attribution-wordmark']_textUnderlineOffset-kHPfEo":`x1diuls0`,$$css:`@stridge/kit:src/shared/attribution/Attribution.styles.ts:68`}};export{t as elementStyles,e as styles};
@@ -0,0 +1 @@
1
+ import"./Attribution.slots.js";import"./Attribution.js";
@@ -1,40 +1,59 @@
1
1
  //#region src/shared/chains/index.d.ts
2
2
  /**
3
- * Chain catalog for `@stridge/kit`. Exports the `chains` namespace (EIP-155 chain ids keyed by
4
- * slug, suitable for IDE autocomplete) and a normalizer that converts any accepted form
5
- * (slug, EIP-155 number, Stridge networkId) into the wire-shape `network_id` string the gateway
6
- * expects.
3
+ * Chain-family types and recipient-address validators for `@stridge/kit`.
7
4
  *
8
- * @example
9
- * ```ts
10
- * import { chains } from "@stridge/kit";
5
+ * The kit does not ship a static chain catalog — the gateway is the single source of truth for
6
+ * which networks exist. Consumers pass the Stridge network id (read straight off
7
+ * `Gateway.assets()`) as `StridgeAsset.networkId`, and the kit forwards it to
8
+ * `gateway/start` verbatim. This module only carries the chain-*family* tag (`ChainType`) and
9
+ * the address-shape validators that depend on it.
10
+ */
11
+ /**
12
+ * Chain family a network belongs to. The kit-internal, case-stable mirror of the gateway's
13
+ * `chain_type` wire tag (`SupportedAssetDto.chain_type`):
11
14
  *
12
- * <StridgeProvider asset={{ chain: chains.bsc, symbol: "USDC" }} ... />;
13
- * <StridgeProvider asset={{ chain: 56, symbol: "USDC" }} ... />; // also valid
14
- * <StridgeProvider asset={{ chain: "bsc", symbol: "USDC" }} ... />; // also valid
15
- * <StridgeProvider asset={{ chain: "9006", symbol: "USDC" }} ... />; // also valid
16
- * ```
15
+ * - `"evm"` — every EIP-155 chain (Ethereum, BSC, Polygon, …); addresses are `0x` + 40 hex.
16
+ * - `"tron"` Tron mainnet; addresses are base58check, 34 chars, leading `T`.
17
+ * - `"unknown"` a family the kit predates. Address validation falls back to a permissive
18
+ * shape check (see {@link isValidAddressForChainType}) so a chain the backend lists before
19
+ * the kit ships explicit support is still usable rather than hard-blocked.
20
+ *
21
+ * Drivers are the source of truth: each one tags its payloads (`ReceiveChainPayload.chainType`,
22
+ * …) so widgets and headless consumers never re-derive the family from chain-id heuristics.
23
+ */
24
+ type ChainType = "evm" | "tron" | "unknown";
25
+ /**
26
+ * Normalize a raw gateway `chain_type` value (or a missing one) into a {@link ChainType}.
27
+ * Surrounding whitespace is trimmed and matching is case-insensitive; the gateway tags Tron as
28
+ * `"TVM"` (Tron Virtual Machine). Any value the kit doesn't recognize — including `undefined` —
29
+ * collapses to `"unknown"`, which keeps the address gate permissive instead of blocking the flow.
30
+ */
31
+ declare function toChainType(raw: string | null | undefined): ChainType;
32
+ /**
33
+ * Lightweight EVM-address validator. Matches `0x` followed by exactly 40 hex characters.
34
+ * Does NOT enforce the EIP-55 mixed-case checksum — the gateway lowercases before routing, and
35
+ * checksum validation would reject the all-lowercase forms wallets and explorers commonly emit.
36
+ * Input is trimmed before matching.
17
37
  */
38
+ declare function isValidEvmAddress(value: string): boolean;
18
39
  /**
19
- * EIP-155 chain ids for the chains Stridge's gateway routes to. Keyed by lowercase slug for
20
- * IDE autocomplete; the value is a plain number so consumers can pass `chains.bsc` directly to
21
- * any prop that accepts a chain id.
40
+ * Lightweight Tron-address validator. Matches the base58check mainnet shape: a leading `T`
41
+ * followed by 33 base58 characters (34 total). Does NOT verify the trailing checksum bytes
42
+ * that needs a base58check decode the kit deliberately keeps out of the bundle; the gateway
43
+ * performs the authoritative check. Input is trimmed before matching.
22
44
  */
23
- declare const chains: {
24
- readonly ethereum: 1;
25
- readonly bsc: 56;
26
- readonly polygon: 137;
27
- readonly arbitrum: 42161;
28
- readonly base: 8453;
29
- };
30
- type ChainSlug = keyof typeof chains;
45
+ declare function isValidTronAddress(value: string): boolean;
31
46
  /**
32
- * The accepted shape of a `chain` field on kit configuration props. Any of:
47
+ * Validate a recipient address against the chain family it's being sent to the chain-type-aware
48
+ * gate the withdraw form and headless integrators share. Pass the `chainType` the driver tagged
49
+ * onto the receive-chain payload.
50
+ *
51
+ * - `"evm"` / `"tron"` — checked against the family's real address shape.
52
+ * - `"unknown"` — a family the kit predates: accepts any whitespace-free token of at least 8
53
+ * characters, so a backend-listed chain still works before the kit ships a dedicated matcher.
33
54
  *
34
- * - `number` EIP-155 chain id (`56`, `137`).
35
- * - `string` — chain slug (`"bsc"`), the matching EIP-155 id as text (`"56"`), or a Stridge
36
- * `network_id` (`"9006"`). The kit normalizes via {@link normalizeChainToNetworkId}.
55
+ * Empty / whitespace-only input is always rejected. Trim is handled internally.
37
56
  */
38
- type ChainInput = string | number;
57
+ declare function isValidAddressForChainType(value: string, chainType: ChainType): boolean;
39
58
  //#endregion
40
- export { ChainInput, ChainSlug, chains };
59
+ export { ChainType, isValidAddressForChainType, isValidEvmAddress, isValidTronAddress, toChainType };
@@ -1 +1 @@
1
- const e={ethereum:1,bsc:56,polygon:137,arbitrum:42161,base:8453},t={ethereum:`60`,bsc:`9006`,polygon:`966`,arbitrum:`9001`,base:`8453`},n={1:`60`,56:`9006`,137:`966`,42161:`9001`,8453:`8453`};function r(e){if(typeof e==`number`)return n[e]??String(e);let r=e.toLowerCase();return r in t?t[r]:/^\d+$/.test(e)?n[Number(e)]??e:e}export{e as chains,r as normalizeChainToNetworkId};
1
+ function e(e){switch(e?.trim().toUpperCase()){case`EVM`:return`evm`;case`TVM`:return`tron`;default:return`unknown`}}const t=/^0x[0-9a-fA-F]{40}$/,n=/^T[1-9A-HJ-NP-Za-km-z]{33}$/;function r(e){return t.test(e.trim())}function i(e){return n.test(e.trim())}function a(e,r){let i=e.trim();if(i.length===0)return!1;switch(r){case`evm`:return t.test(i);case`tron`:return n.test(i);default:return/^\S{8,}$/.test(i)}}export{a as isValidAddressForChainType,r as isValidEvmAddress,i as isValidTronAddress,e as toChainType};
@@ -0,0 +1 @@
1
+ const e={appId:`ii7w0vsj`};export{e as BRAND_INTERCOM};
@@ -1 +1 @@
1
- import{create as e}from"./QrCode.js";import*as t from"react";import{Fragment as n,jsx as r,jsxs as i}from"react/jsx-runtime";function a(e){let{arena:t,...n}=e;return i(a.Root,{...n,children:[r(a.Finder,{}),r(a.Cells,{}),t&&r(a.Arena,{children:typeof t==`string`?r(`img`,{alt:`Arena`,src:t,style:{borderRadius:1,height:`100%`,objectFit:`cover`,width:`100%`}}):t})]})}(function(a){let o=a.Context=t.createContext(null);function s(n){let{children:a,size:s=`100%`,value:c,version:l,errorCorrection:u,...d}=n,f=t.useMemo(()=>(t.Children.map(a,e=>!t.isValidElement(e)||typeof e.type==`string`?null:`displayName`in e.type&&e.type.displayName===`Arena`?!0:null)??[]).some(Boolean),[a]),p=t.useMemo(()=>{let t=u;return f&&u===`low`&&(t=`medium`),e(c,{errorCorrection:t,version:l})},[c,f,u,l]),m=p.edgeLength*1,h=p.finderLength*1/2,g=f?Math.floor(m/4):0,_=t.useMemo(()=>({arenaSize:g,cellSize:1,edgeSize:m,qrcode:p,finderSize:h}),[g,m,p,h]);return r(o.Provider,{value:_,children:i(`svg`,{...d,width:s,height:s,viewBox:`0 0 ${m} ${m}`,xmlns:`http://www.w3.org/2000/svg`,children:[r(`title`,{children:`QR Code`}),a]})})}a.Root=s,(function(e){e.displayName=`Root`})(s||=a.Root||={});function c(e){let{className:a,fill:s,innerClassName:c,radius:l=.25}=e,{cellSize:u,edgeSize:d,finderSize:f}=t.useContext(o);function p({position:e}){let t=f-(f-u)-u/2;e===`top-right`&&(t=d-f-(f-u)-u/2);let o=f-(f-u)-u/2;e===`bottom-left`&&(o=d-f-(f-u)-u/2);let p=f-u*1.5;e===`top-right`&&(p=d-f-u*1.5);let m=f-u*1.5;return e===`bottom-left`&&(m=d-f-u*1.5),i(n,{children:[r(`rect`,{className:a,stroke:s??`currentColor`,fill:`transparent`,x:t,y:o,width:u+(f-u)*2,height:u+(f-u)*2,rx:2*l*(f-u),ry:2*l*(f-u),strokeWidth:u}),r(`rect`,{className:c,fill:s??`currentColor`,x:p,y:m,width:u*3,height:u*3,rx:2*l*u,ry:2*l*u})]})}return i(n,{children:[r(p,{position:`top-left`}),r(p,{position:`top-right`}),r(p,{position:`bottom-left`})]})}a.Finder=c,(function(e){e.displayName=`Finder`})(c||=a.Finder||={});function l(e){let{className:n,fill:i=`currentColor`,inset:a=!0,radius:s=1}=e,{arenaSize:c,cellSize:l,qrcode:u}=t.useContext(o),{edgeLength:d,finderLength:f}=u;return r(`path`,{className:n,d:t.useMemo(()=>{let e=``;for(let t=0;t<u.grid.length;t++){let n=u.grid[t];if(n)for(let r=0;r<n.length;r++){if(!n[r])continue;let i=d/2-c/2,o=i+c;if(t>=i&&t<=o&&r>=i&&r<=o)continue;let u=t<f&&r<f,p=t<f&&r>=d-f,m=t>=d-f&&r<f;if(u||p||m)continue;let h=(l-(a?l*.1:0)*2)/2,g=r*l+l/2,_=t*l+l/2,v=g-h,y=g+h,b=_-h,x=_+h,S=s*h;e+=[`M ${v+S},${b}`,`L ${y-S},${b}`,`A ${S},${S} 0 0,1 ${y},${b+S}`,`L ${y},${x-S}`,`A ${S},${S} 0 0,1 ${y-S},${x}`,`L ${v+S},${x}`,`A ${S},${S} 0 0,1 ${v},${x-S}`,`L ${v},${b+S}`,`A ${S},${S} 0 0,1 ${v+S},${b}`,`z`].join(` `)}}return e},[c,l,d,f,u.grid,a,s]),fill:i})}a.Cells=l,(function(e){e.displayName=`Cells`})(l||=a.Cells||={});function u(e){let{children:n}=e,{arenaSize:i,cellSize:a,edgeSize:s}=t.useContext(o),c=Math.ceil(s/2-i/2),l=i+i%2;return r(`foreignObject`,{x:c,y:c,width:l,height:l,children:r(`div`,{style:{alignItems:`center`,display:`flex`,fontSize:1,justifyContent:`center`,height:`100%`,overflow:`hidden`,width:`100%`,padding:a/2,boxSizing:`border-box`},children:n})})}a.Arena=u,(function(e){e.displayName=`Arena`})(u||=a.Arena||={})})(a||={});export{a as Cuer};
1
+ import{create as e}from"./QrCode.js";import*as t from"react";import{Fragment as n,jsx as r,jsxs as i}from"react/jsx-runtime";const a=e=>Math.max(0,Math.min(1,e));function o(e){let{arena:t,...n}=e;return i(o.Root,{...n,children:[r(o.Finder,{}),r(o.Cells,{}),t&&r(o.Arena,{href:t})]})}(function(o){let s=o.Context=t.createContext(null);function c(n){let{children:a,size:o=`100%`,value:c,version:l,errorCorrection:u,...d}=n,f=t.useMemo(()=>(t.Children.map(a,e=>!t.isValidElement(e)||typeof e.type==`string`?null:`displayName`in e.type&&e.type.displayName===`Arena`?!0:null)??[]).some(Boolean),[a]),p=t.useMemo(()=>{let t=u;return f&&u===`low`&&(t=`medium`),e(c,{errorCorrection:t,version:l})},[c,f,u,l]),m=p.edgeLength*1,h=p.finderLength*1/2,g=f?Math.floor(m/4):0,_=(m-g)/2,v=t.useMemo(()=>({arenaSize:g,arenaStart:_,cellSize:1,edgeSize:m,qrcode:p,finderSize:h}),[g,_,m,p,h]);return r(s.Provider,{value:v,children:i(`svg`,{...d,width:o,height:o,viewBox:`0 0 ${m} ${m}`,xmlns:`http://www.w3.org/2000/svg`,children:[r(`title`,{children:`QR Code`}),a]})})}o.Root=c,(function(e){e.displayName=`Root`})(c||=o.Root||={});function l(e){let{className:o,fill:c,innerClassName:l,radius:u=.25,stroke:d}=e,{cellSize:f,edgeSize:p,finderSize:m}=t.useContext(s),h=a(u);function g({position:e}){let t=m-(m-f)-f/2;e===`top-right`&&(t=p-m-(m-f)-f/2);let a=m-(m-f)-f/2;e===`bottom-left`&&(a=p-m-(m-f)-f/2);let s=m-f*1.5;e===`top-right`&&(s=p-m-f*1.5);let u=m-f*1.5;return e===`bottom-left`&&(u=p-m-f*1.5),i(n,{children:[r(`rect`,{className:o,stroke:d??c??`currentColor`,fill:`transparent`,x:t,y:a,width:f+(m-f)*2,height:f+(m-f)*2,rx:2*h*(m-f),ry:2*h*(m-f),strokeWidth:f}),r(`rect`,{className:l,fill:c??`currentColor`,x:s,y:u,width:f*3,height:f*3,rx:2*h*f,ry:2*h*f})]})}return i(n,{children:[r(g,{position:`top-left`}),r(g,{position:`top-right`}),r(g,{position:`bottom-left`})]})}o.Finder=l,(function(e){e.displayName=`Finder`})(l||=o.Finder||={});function u(e){let{className:n,fill:i=`currentColor`,inset:o=!0,radius:c=1}=e,{arenaSize:l,arenaStart:u,cellSize:d,qrcode:f}=t.useContext(s),{edgeLength:p,finderLength:m}=f,h=a(c);return r(`path`,{className:n,d:t.useMemo(()=>{let e=``,t=u+l;for(let n=0;n<f.grid.length;n++){let r=f.grid[n];if(r)for(let i=0;i<r.length;i++){if(!r[i])continue;if(l>0){let e=(i+.5)*d,r=(n+.5)*d;if(e>=u&&e<=t&&r>=u&&r<=t)continue}let a=n<m&&i<m,s=n<m&&i>=p-m,c=n>=p-m&&i<m;if(a||s||c)continue;let f=(d-(o?d*.1:0)*2)/2,g=i*d+d/2,_=n*d+d/2,v=g-f,y=g+f,b=_-f,x=_+f,S=h*f;e+=[`M ${v+S},${b}`,`L ${y-S},${b}`,`A ${S},${S} 0 0,1 ${y},${b+S}`,`L ${y},${x-S}`,`A ${S},${S} 0 0,1 ${y-S},${x}`,`L ${v+S},${x}`,`A ${S},${S} 0 0,1 ${v},${x-S}`,`L ${v},${b+S}`,`A ${S},${S} 0 0,1 ${v+S},${b}`,`z`].join(` `)}}return e},[l,u,d,p,m,f.grid,o,h]),fill:i})}o.Cells=u,(function(e){e.displayName=`Cells`})(u||=o.Cells||={});function d(e){let{href:n,preserveAspectRatio:i=`xMidYMid meet`,...a}=e,{arenaSize:o,arenaStart:c,cellSize:l}=t.useContext(s),u=l/2,d=c+u,f=o-u*2;return r(`image`,{href:n,...a,x:d,y:d,width:f,height:f,preserveAspectRatio:i})}o.Arena=d,(function(e){e.displayName=`Arena`})(d||=o.Arena||={})})(o||={});export{o as Cuer};
@@ -1,3 +1,4 @@
1
+ import { Presentation } from "../presentation/types.js";
1
2
  import { ReactElement, ReactNode } from "react";
2
3
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
4
 
@@ -22,18 +23,30 @@ interface DialogShellControls {
22
23
  }
23
24
  interface DialogShellProps extends DialogShellControls {
24
25
  /**
25
- * Widget JSX rendered inside `Dialog.Content`. Each widget detects
26
- * the dialog context and swaps to its bare frame, so the same
26
+ * Element the surface portals into. Defaults to `document.body`. Doubles as the measured
27
+ * containing block for `"auto"` presentation the dialog-vs-drawer breakpoint is measured
28
+ * against this element's width when supplied, else the viewport.
29
+ */
30
+ container?: HTMLElement | null;
31
+ /**
32
+ * Surface override forwarded to {@link AdaptiveSurface}. Falls back to the provider's
33
+ * `appearance.presentation`, then `"auto"`. Omit to inherit the provider default.
34
+ */
35
+ presentation?: Presentation;
36
+ /**
37
+ * Widget JSX rendered inside the surface. Each widget detects the
38
+ * surface context and swaps to its bare frame, so the same
27
39
  * composition that works inline as `Card variant="frame"` paints
28
40
  * the same surface chrome here.
29
41
  */
30
42
  children?: ReactNode;
31
43
  }
32
44
  /**
33
- * Pre-composed dialog shell for a kit widget. Wraps `Dialog.Root` +
34
- * (optional) `Dialog.Trigger` + `Dialog.Content` so consumers don't
35
- * re-stitch those three primitives every time they want to open a
36
- * widget in a modal.
45
+ * Pre-composed dialog shell for a kit widget. Wraps {@link AdaptiveSurface}
46
+ * so consumers don't re-stitch the surface primitives every time they want
47
+ * to open a widget in a modal. The surface is responsive — a centred dialog
48
+ * on wide containers, a bottom-sheet drawer below the breakpoint — and the
49
+ * widget renders its bare frame inside either via the shared surface context.
37
50
  *
38
51
  * Each widget also exposes a typed `.Dialog` form (`Deposit.Dialog`,
39
52
  * `AssetPicker.Dialog`, …) that wraps this shell and forwards the
@@ -57,6 +70,8 @@ declare function DialogShell({
57
70
  defaultOpen,
58
71
  onOpenChange,
59
72
  trigger,
73
+ container,
74
+ presentation,
60
75
  children
61
76
  }: DialogShellProps): _$react_jsx_runtime0.JSX.Element;
62
77
  //#endregion
@@ -1 +1 @@
1
- "use client";import{Dialog as e}from"../ui/Dialog/Dialog.js";import"../ui/Dialog/index.js";import{jsx as t,jsxs as n}from"react/jsx-runtime";function r({open:r,defaultOpen:i,onOpenChange:a,trigger:o,children:s}){return n(e,{open:r,defaultOpen:i,onOpenChange:a,children:[o?t(e.Trigger,{render:o}):null,t(e.Content,{children:s})]})}export{r as DialogShell};
1
+ "use client";import{AdaptiveSurface as e}from"../ui/AdaptiveSurface/AdaptiveSurface.js";import"../ui/AdaptiveSurface/index.js";import{jsx as t}from"react/jsx-runtime";function n({open:n,defaultOpen:r,onOpenChange:i,trigger:a,container:o,presentation:s,children:c}){return t(e,{open:n,defaultOpen:r,onOpenChange:i,...a?{trigger:a}:{},container:o,...s?{presentation:s}:{},children:c})}export{n as DialogShell};
@@ -1 +1 @@
1
- "use client";import{useKitConfig as e}from"../../scope/context.js";import{useIsInsideDialogContent as t}from"../ui/Dialog/Dialog.js";import"../ui/Dialog/index.js";import{Card as n}from"../ui/Card/Card.js";import"../../ui/index.js";import{jsx as r}from"react/jsx-runtime";function i({className:i,style:a,dir:o,...s}){let c=t(),{direction:l}=e(),u=o??l;if(c){let e={className:`Frame__styles.bare x78zum5 xdt5ytf x12lumcd x2lwn1j x7giv3`,"data-style-src":`@stridge/kit:src/shared/dialog/Frame.tsx:25`};return r(`div`,{...s,dir:u,className:[e.className,i].filter(Boolean).join(` `)||void 0,style:{...e.style,...a}})}return r(n,{variant:`frame`,dir:u,className:i,style:a,...s})}export{i as Frame};
1
+ "use client";import{useKitConfig as e}from"../../scope/context.js";import{useIsInsideDialogContent as t}from"../ui/Dialog/Dialog.js";import"../ui/Dialog/index.js";import{Attribution as n}from"../attribution/Attribution.js";import"../attribution/index.js";import{Card as r}from"../ui/Card/Card.js";import"../../ui/index.js";import{jsx as i,jsxs as a}from"react/jsx-runtime";function o({className:o,style:s,dir:c,children:l,...u}){let d=t(),{direction:f,attribution:p}=e(),m=c??f,h=p!==`hidden`;if(d){let e={className:`Frame__styles.bare x78zum5 xdt5ytf xkz0k9k x2lwn1j x7giv3`,"data-style-src":`@stridge/kit:src/shared/dialog/Frame.tsx:33`};return a(`div`,{...u,dir:m,className:[e.className,o].filter(Boolean).join(` `)||void 0,style:{...e.style,...s},children:[l,h?i(n,{}):null]})}return a(r,{variant:`frame`,dir:m,className:o,style:s,...u,children:[l,h?i(n,{}):null]})}export{o as Frame};
@@ -0,0 +1 @@
1
+ "use client";import{useLingui as e}from"../i18n/useLingui.js";import"../../i18n/index.js";import{styles as t}from"./LoadingState.styles.js";import{jsx as n,jsxs as r}from"react/jsx-runtime";import*as i from"@stylexjs/stylex";function a({slot:a}){let{_:o}=e();return n(`div`,{role:`status`,"aria-label":o({id:`yQE2r9`,message:`Loading`}),"data-stridge-slot":`${a}-loading`,"data-testid":`${a}-loading`,...i.props(t.root),children:r(`span`,{"aria-hidden":!0,...i.props(t.dots),children:[n(`span`,{...i.props(t.dot,t.dotDelay1)}),n(`span`,{...i.props(t.dot,t.dotDelay2)}),n(`span`,{...i.props(t.dot,t.dotDelay3)})]})})}export{a as LoadingState};
@@ -0,0 +1 @@
1
+ const e={root:{"LoadingState__styles.root":`LoadingState__styles.root`,"display-k1xSpc":`x78zum5`,"flex-kUk6DE":`x12lumcd`,"flexDirection-kXwgrk":`xdt5ytf`,"alignItems-kGNEyG":`x6s0dn4`,"justifyContent-kjj79g":`xl56j7k`,"width-kzqmXN":`xh8yej3`,"minHeight-kAzted":`x1dby22o`,"animationName-kKVMdj":`x1tj11xs`,"animationDuration-k44tkh":`x1a78uxe x1s1fvk8`,"animationTimingFunction-kyAemX":`xrkt6z0`,"animationFillMode-kWV6AL":`x1u6ievf`,$$css:`@stridge/kit:src/shared/dialog/LoadingState.styles.ts:44`},dots:{"LoadingState__styles.dots":`LoadingState__styles.dots`,"display-k1xSpc":`x3nfvp2`,"alignItems-kGNEyG":`x6s0dn4`,"gap-kOIVth":`x1jnr06f`,"lineHeight-kLWn49":`x14ju556`,$$css:`@stridge/kit:src/shared/dialog/LoadingState.styles.ts:65`},dot:{"LoadingState__styles.dot":`LoadingState__styles.dot`,"display-k1xSpc":`x1rg5ohu`,"width-kzqmXN":`x1xc55vz`,"height-kZKoxP":`xdk7pt`,"borderRadius-kaIpWk":`x16rqkct`,"backgroundColor-kWkggS":`x1lbpfnh`,"animationName-kKVMdj":`x11qdjwd`,"animationDuration-k44tkh":`x1sbju2s x80wavc`,"animationIterationCount-ko0y90":`xa4qsjk`,"animationFillMode-kWV6AL":`x1u6ievf`,$$css:`@stridge/kit:src/shared/dialog/LoadingState.styles.ts:77`},dotDelay1:{"LoadingState__styles.dotDelay1":`LoadingState__styles.dotDelay1`,"animationDelay-kKxzle":`x1uzojwf`,$$css:`@stridge/kit:src/shared/dialog/LoadingState.styles.ts:96`},dotDelay2:{"LoadingState__styles.dotDelay2":`LoadingState__styles.dotDelay2`,"animationDelay-kKxzle":`x1t83zlg`,$$css:`@stridge/kit:src/shared/dialog/LoadingState.styles.ts:99`},dotDelay3:{"LoadingState__styles.dotDelay3":`LoadingState__styles.dotDelay3`,"animationDelay-kKxzle":`x1xwhvez`,$$css:`@stridge/kit:src/shared/dialog/LoadingState.styles.ts:102`}};export{e as styles};
@@ -1 +1 @@
1
- "use client";import{useEffect as e,useLayoutEffect as t,useRef as n}from"react";import{jsx as r}from"react/jsx-runtime";import{AnimatePresence as i,motion as a}from"motion/react";const o=[.3,0,.06,1],s={enter:e=>({opacity:0,x:e>=0?16:-16,filter:`blur(6px)`}),center:{opacity:1,x:0,filter:`blur(0px)`,transition:{duration:.22,delay:.12,ease:o}},exit:e=>({opacity:0,x:e>=0?-16:16,filter:`blur(6px)`,transition:{duration:.14,ease:o}})};function c({stateKey:o,children:c}){let l=n([]),u=n(null),d=l.current,f=d[d.length-1],p=0;o!==f&&(p=d.indexOf(o)>=0?-1:1);let m=n(null),h=n(o),g=n(null),_=n(null);return e(()=>{let e=l.current;if(e[e.length-1]===o)return;let t=e.indexOf(o);l.current=t>=0?e.slice(0,t+1):[...e,o]},[o]),t(()=>{let e=u.current;if(!e)return;let t=e.getBoundingClientRect().height;if(h.current===o){m.current=t;return}let n=m.current;if(h.current=o,m.current=t,n===null||n===t)return;let r=e.style.transition;e.style.transition=`none`,e.style.height=`${n}px`,e.offsetHeight,e.style.transition=r,_.current!==null&&window.cancelAnimationFrame(_.current),_.current=window.requestAnimationFrame(()=>{_.current=null,u.current&&(u.current.style.height=`${t}px`)}),g.current!==null&&window.clearTimeout(g.current),g.current=window.setTimeout(()=>{g.current=null;let e=u.current;e&&(e.style.height=``)},320)}),e(()=>()=>{g.current!==null&&(window.clearTimeout(g.current),g.current=null),_.current!==null&&(window.cancelAnimationFrame(_.current),_.current=null)},[]),r(`div`,{ref:u,style:{position:`relative`,overflow:`hidden`,transition:`height 260ms cubic-bezier(0.3, 0, 0.06, 1)`,flex:`0 1 auto`,minHeight:0,display:`flex`,flexDirection:`column`},children:r(i,{mode:`popLayout`,custom:p,initial:!1,children:r(a.div,{custom:p,variants:s,initial:`enter`,animate:`center`,exit:`exit`,tabIndex:-1,style:{display:`flex`,flexDirection:`column`,flex:`1 1 auto`,minHeight:0,outline:`none`},children:c},o)})})}export{c as StepTransition};
1
+ "use client";import{useEffect as e,useLayoutEffect as t,useRef as n}from"react";import{jsx as r}from"react/jsx-runtime";import{AnimatePresence as i,m as a}from"motion/react";const o=[.3,0,.06,1],s={enter:e=>({opacity:0,x:e>=0?16:-16,filter:`blur(6px)`}),center:{opacity:1,x:0,filter:`blur(0px)`,transition:{duration:.22,delay:.12,ease:o}},exit:e=>({opacity:0,x:e>=0?-16:16,filter:`blur(6px)`,transition:{duration:.14,ease:o}})};function c({stateKey:o,children:c}){let l=n([]),u=n(null),d=l.current,f=d[d.length-1],p=0;o!==f&&(p=d.indexOf(o)>=0?-1:1);let m=n(null),h=n(o),g=n(null),_=n(null);return e(()=>{let e=l.current;if(e[e.length-1]===o)return;let t=e.indexOf(o);l.current=t>=0?e.slice(0,t+1):[...e,o]},[o]),t(()=>{let e=u.current;if(!e)return;let t=Array.from(e.children).find(e=>e instanceof HTMLElement&&getComputedStyle(e).position!==`absolute`),n=t?t.scrollHeight:e.getBoundingClientRect().height;if(h.current===o){m.current=n;return}let r=m.current;if(h.current=o,m.current=n,r===null||r===n||document.visibilityState===`hidden`)return;let i=e.style.transition;e.style.transition=`none`,e.style.height=`${r}px`,e.offsetHeight,e.style.transition=i,_.current!==null&&window.cancelAnimationFrame(_.current),_.current=window.requestAnimationFrame(()=>{_.current=null,u.current&&(u.current.style.height=`${n}px`)}),g.current!==null&&window.clearTimeout(g.current),g.current=window.setTimeout(()=>{g.current=null;let e=u.current;e&&(e.style.height=``)},320)}),e(()=>{let e=()=>{if(document.visibilityState!==`hidden`)return;_.current!==null&&(window.cancelAnimationFrame(_.current),_.current=null),g.current!==null&&(window.clearTimeout(g.current),g.current=null);let e=u.current;e&&(e.style.height=``)};return document.addEventListener(`visibilitychange`,e),()=>{document.removeEventListener(`visibilitychange`,e),g.current!==null&&(window.clearTimeout(g.current),g.current=null),_.current!==null&&(window.cancelAnimationFrame(_.current),_.current=null)}},[]),r(`div`,{ref:u,style:{position:`relative`,overflow:`hidden`,transition:`height 260ms cubic-bezier(0.3, 0, 0.06, 1)`,flex:`0 1 auto`,minHeight:0,display:`flex`,flexDirection:`column`},children:r(i,{mode:`popLayout`,custom:p,initial:!1,children:r(a.div,{custom:p,variants:s,initial:`enter`,animate:`center`,exit:`exit`,tabIndex:-1,style:{display:`flex`,flexDirection:`column`,flex:`1 1 auto`,minHeight:0,outline:`none`},children:c},o)})})}export{c as StepTransition};
@@ -1 +1 @@
1
- "use client";import{useKitConfig as e}from"../../scope/context.js";function t(t){let{direction:n}=e(),r=n===`rtl`;return t?r?`scaleX(-1) rotate(-90deg)`:`rotate(90deg)`:r?`scaleX(-1)`:void 0}export{t as useDirectionalChevronTransform};
1
+ "use client";function e(e){return e?`rotate(90deg)`:void 0}export{e as useDirectionalChevronTransform};
@@ -6,9 +6,10 @@
6
6
  * public `@stridge/kit/<flow>/driver` surface.
7
7
  */
8
8
  /**
9
- * On-chain transaction reference. Drivers return one of these from any imperative wallet action
10
- * (`submitDeposit`, `submitWithdrawal`); the orchestrator stamps it on the FSM's `tx` slot until
11
- * the matching settlement entity catches up and exposes a richer `txHash` / `txExplorerUrl` pair.
9
+ * On-chain transaction reference. The deposit driver returns one from `submitDeposit`; the
10
+ * withdraw flow's host-supplied `onSubmit` surfaces one via `actions.beginProcessing({ hash })`
11
+ * or `actions.setTxHash`. The orchestrator stamps it on the FSM's `tx` slot until the matching
12
+ * settlement entity catches up and exposes a richer `txHash` / `txExplorerUrl` pair.
12
13
  */
13
14
  interface TxRef {
14
15
  hash: string;
@@ -0,0 +1,25 @@
1
+ import { I18n } from "@lingui/core";
2
+
3
+ //#region src/shared/format/formatSmartRelative.d.ts
4
+ /**
5
+ * Smart-relative date formatter. Renders a unix-millisecond timestamp as a locale-aware string,
6
+ * cascading through five buckets:
7
+ *
8
+ * - `< 1 min`: `"Just now"` — avoids a noisy `"0 minutes ago"` reading on
9
+ * stale-while-revalidate refreshes that land microseconds after the wire stamp.
10
+ * - `< 1 hr`: `"5 minutes ago"` via `Intl.RelativeTimeFormat`.
11
+ * - `< 1 day`: `"3 hours ago"` via `Intl.RelativeTimeFormat`.
12
+ * - 1 day exact: `"Yesterday"`.
13
+ * - 2–6 days: `"3 days ago"` via `Intl.RelativeTimeFormat`.
14
+ * - `>= 7 days`: absolute date via {@link formatTimestamp}.
15
+ *
16
+ * `Intl.RelativeTimeFormat` produces locale-aware strings (e.g. `"hace 5 minutos"`,
17
+ * `"il y a 5 minutes"`, `"منذ ٥ دقائق"`) so plural-aware copy and RTL come for free.
18
+ *
19
+ * @param epochMs - The timestamp to render.
20
+ * @param now - The wall-clock anchor; pass `Date.now()` in components or a pinned value in tests.
21
+ * @param i18n - The active Lingui {@link I18n} instance — `i18n.locale` drives every formatter.
22
+ */
23
+ declare function formatSmartRelative(epochMs: number, now: number, i18n: I18n): string;
24
+ //#endregion
25
+ export { formatSmartRelative };
@@ -0,0 +1 @@
1
+ import{formatTimestamp as e}from"./formatTimestamp.js";const t=6e4,n=36e5,r=864e5,i={id:`OSBXx5`,message:`Just now`},a={id:`y_0uwd`,message:`Yesterday`};function o(o,s,c){let l=s-o;if(l<t)return c._(i);let u=new Intl.RelativeTimeFormat(c.locale,{numeric:`auto`});if(l<n){let e=Math.floor(l/t);return u.format(-e,`minute`)}if(l<r){let e=Math.floor(l/n);return u.format(-e,`hour`)}let d=Math.floor(l/r);return d===1?c._(a):d<7?u.format(-d,`day`):e(o,c)}export{o as formatSmartRelative};
@@ -1 +1 @@
1
- const e={style:`currency`,currency:`USD`,minimumFractionDigits:2,maximumFractionDigits:2};function t(t,n,r={}){let i=r.intlOptions??e,a=r.showSmallValueClamp??!0,o=new Intl.NumberFormat(n.locale,i);return a&&t>0&&t<.01?`< ${o.format(.01)}`:o.format(t)}export{t as formatUsd};
1
+ const e={minimumFractionDigits:2,maximumFractionDigits:2};function t(t,r,i={}){let a=n(i.intlOptions??e),o=i.showSmallValueClamp??!0,s=new Intl.NumberFormat(r.locale,a);return o&&t>0&&t<.01?`< $${s.format(.01)}`:`$${s.format(t)}`}function n(e){let{style:t,currency:n,currencyDisplay:r,currencySign:i,...a}=e;return a}export{t as formatUsd};
@@ -3,21 +3,24 @@ import { ReactNode } from "react";
3
3
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
4
4
 
5
5
  //#region src/shared/i18n/KitI18nProvider.d.ts
6
- interface Props extends KitI18nConfig {
7
- children: ReactNode;
8
- }
9
6
  /**
10
7
  * Mounts a per-request Lingui `I18n` instance into React context. Re-creates the instance only
11
- * when `locale` or the identity of `catalogs` changes — same render-stable pattern as the kit's
12
- * other context providers, and the SSR-safe alternative to mutating a module-level singleton.
8
+ * when `locale` or the identity of `messages` changes — same render-stable pattern as the
9
+ * kit's other context providers, and the SSR-safe alternative to mutating a module-level
10
+ * singleton.
13
11
  *
14
12
  * Used internally by `KitProvider`. Hosts don't mount this directly; they pass a single
15
- * `i18n={{ locale, catalogs }}` prop on `<KitProvider>` and the kit handles the wiring.
13
+ * `i18n={{ locale, messages }}` prop on `<KitProvider>` and the kit handles the wiring.
16
14
  */
17
15
  declare function KitI18nProvider({
18
16
  locale,
19
- catalogs,
17
+ messages,
20
18
  children
21
- }: Props): _$react_jsx_runtime0.JSX.Element;
19
+ }: KitI18nProvider.Props): _$react_jsx_runtime0.JSX.Element;
20
+ declare namespace KitI18nProvider {
21
+ interface Props extends KitI18nConfig {
22
+ children: ReactNode;
23
+ }
24
+ }
22
25
  //#endregion
23
26
  export { KitI18nProvider };
@@ -1 +1 @@
1
- "use client";import{createKitI18n as e}from"./createKitI18n.js";import{useMemo as t}from"react";import{jsx as n}from"react/jsx-runtime";import{I18nProvider as r}from"@lingui/react";function i({locale:i=`en`,catalogs:a,children:o}){return n(r,{i18n:t(()=>e({locale:i,catalogs:a}),[i,a]),children:o})}export{i as KitI18nProvider};
1
+ "use client";import{createKitI18n as e}from"./createKitI18n.js";import{useMemo as t}from"react";import{jsx as n}from"react/jsx-runtime";import{I18nProvider as r}from"@lingui/react";function i({locale:i=`en`,messages:a,children:o}){return n(r,{i18n:t(()=>e({locale:i,messages:a}),[i,a]),children:o})}export{i as KitI18nProvider};
@@ -1,33 +1,96 @@
1
+ import { SupportedLocale } from "./locales.js";
2
+ import { KitTranslatableKey } from "../../i18n/locales/source-keys.js";
1
3
  import { I18n, Messages } from "@lingui/core";
2
4
 
3
5
  //#region src/shared/i18n/createKitI18n.d.ts
4
6
  /**
5
- * Map of locale codes to message catalogs. Keyed by the locale string the host activates
6
- * (`"en"`, `"es"`, etc.). Values are plain `{ [id]: translation }` maps; ICU placeholders and
7
- * plurals are compiled at runtime by {@link compileMessage}.
7
+ * Locale codes the kit's i18n surface accepts. Autocompletes on the locales the kit ships
8
+ * catalogs for ({@link SupportedLocale} — `"en"`, `"es"`, `"ar"`) while still accepting any
9
+ * other BCP-47 tag, so hosts who add their own catalogs via `defineMessages` aren't fenced
10
+ * out of the type.
11
+ *
12
+ * The `(string & {})` intersection is the standard escape hatch for "literal union + open
13
+ * string with autocomplete": without it, TypeScript collapses `Supported | string` to plain
14
+ * `string` and the editor loses the autocomplete suggestions for the named literals.
15
+ */
16
+ type KitLocale = SupportedLocale | (string & {});
17
+ /**
18
+ * Map of locale codes to compiled message catalogs. Values are lingui `Messages` —
19
+ * content-hash-keyed `{ [id]: translation }` maps where ICU placeholders and plurals are
20
+ * compiled at runtime by {@link compileMessage}.
21
+ *
22
+ * Shipped locales (`@stridge/kit/i18n/locales/<code>`) export `Messages` directly. For hosts
23
+ * authoring their own translations, the recommended path is {@link defineMessages}, which
24
+ * takes a plain English-keyed map and emits the same hash-keyed shape — so shipped and
25
+ * host-authored translations slot into the same prop without different shapes.
8
26
  */
9
- type KitCatalogs = Partial<Record<string, Messages>>;
27
+ type KitMessages = Partial<Record<KitLocale, Messages>>;
28
+ /**
29
+ * Hash a plain English-keyed translation map into the lingui `Messages` shape, ready to drop
30
+ * into `<KitProvider i18n={{ messages: { … } }}>`. Use this whenever you want to author
31
+ * translations by hand — adding a locale the kit doesn't ship, overriding a single key on a
32
+ * shipped locale, or tweaking the source English copy.
33
+ *
34
+ * Keys are constrained to {@link KitTranslatableKey} — the literal union of every English
35
+ * source the kit actually translates. Editors autocomplete on every valid key, and typos /
36
+ * stale keys fail at compile time via excess-property checks on the object literal. The union
37
+ * is codegened from `en.po` at `pnpm i18n:compile` time.
38
+ *
39
+ * Hashing runs once per call (typically at module load), not on every render. ICU placeholders
40
+ * (`{symbol}`) and plurals (`{count, plural, one {# item} other {# items}}`) are supported in
41
+ * both keys and values; the kit's runtime compiler handles ICU on access.
42
+ *
43
+ * @example
44
+ * ```tsx
45
+ * import { messages as es } from "@stridge/kit/i18n/locales/es";
46
+ * import { defineMessages } from "@stridge/kit/i18n";
47
+ *
48
+ * const fr = defineMessages({
49
+ * Continue: "Suivant",
50
+ * "Deposit {symbol}": "Dépôt de {symbol}",
51
+ * "{count, plural, one {# item} other {# items}}":
52
+ * "{count, plural, one {# article} other {# articles}}",
53
+ * });
54
+ *
55
+ * // Add a brand-new locale:
56
+ * <KitProvider i18n={{ locale: "fr", messages: { fr } }} />;
57
+ *
58
+ * // Override one key on a shipped locale (spread to preserve the rest):
59
+ * <KitProvider i18n={{ locale: "es", messages: { es: { ...es, ...defineMessages({ Continue: "Adelante" }) } } }} />;
60
+ *
61
+ * // Override source English:
62
+ * <KitProvider i18n={{ locale: "en", messages: { en: defineMessages({ Deposit: "Top up" }) } }} />;
63
+ * ```
64
+ */
65
+ declare function defineMessages(translations: Partial<Record<KitTranslatableKey, string>>): Messages;
10
66
  /**
11
67
  * Public-facing i18n configuration. Pass the whole object to `<KitProvider i18n={…}>` —
12
- * `locale` selects the active locale, `catalogs` lists the catalogs the kit can resolve
13
- * against. Locales not present in `catalogs` fall back to the source English string per leaf.
68
+ * `locale` selects the active locale, `messages` lists the catalogs the kit can resolve
69
+ * against. Locales not present in `messages` fall back to the source English string per leaf.
14
70
  */
15
71
  interface KitI18nConfig {
16
- /** Active locale code. Defaults to `"en"`. */
17
- locale?: string;
18
72
  /**
19
- * Locale catalogs the kit can resolve against. Deep-import the locales you ship from
20
- * `@stridge/kit/i18n/locales/<code>` and pass them as a map (e.g. `{ es: esMessages }`).
21
- * Tree-shaken: locales not referenced here aren't bundled.
73
+ * Active locale code. Defaults to `"en"`. Autocompletes on shipped locales (`"en"`, `"es"`,
74
+ * `"ar"`) but accepts any other BCP-47 tag for host-supplied catalogs.
75
+ */
76
+ locale?: KitLocale;
77
+ /**
78
+ * Locale catalogs the kit can resolve against. Each value is a hash-keyed lingui
79
+ * `Messages` map — either deep-imported from `@stridge/kit/i18n/locales/<code>` (shipped
80
+ * locales: `en`, `es`, `ar`) or produced by {@link defineMessages} from a plain
81
+ * English-keyed map (host-authored locales and per-key overrides). Same-locale entries
82
+ * merge per-key — spread a shipped catalog and overlay specific keys via `defineMessages`
83
+ * to override individual phrases without touching the rest.
22
84
  */
23
- catalogs?: KitCatalogs;
85
+ messages?: KitMessages;
24
86
  }
25
87
  /**
26
88
  * Build a fresh {@link I18n} instance for one render tree (one `KitProvider` mount, one SSR
27
- * request). Loads `catalogs`, registers the runtime message compiler, and activates `locale`.
89
+ * request). Loads each entry of `messages`, registers the runtime message compiler, and
90
+ * activates `locale`.
28
91
  *
29
92
  * Per-request instances are the SSR-safe alternative to mutating a process-wide singleton. The
30
- * kit's {@link KitProvider} calls this on every render that changes `locale` or `catalogs`.
93
+ * kit's {@link KitProvider} calls this on every render that changes `locale` or `messages`.
31
94
  *
32
95
  * `setupI18n` ships its own no-op compiler in production builds; we override with the real
33
96
  * `compileMessage` so ICU placeholders (`{symbol}`) and plurals (`{count, plural, one {…}
@@ -35,7 +98,7 @@ interface KitI18nConfig {
35
98
  */
36
99
  declare function createKitI18n({
37
100
  locale,
38
- catalogs
101
+ messages
39
102
  }?: KitI18nConfig): I18n;
40
103
  //#endregion
41
- export { KitCatalogs, KitI18nConfig, createKitI18n };
104
+ export { KitI18nConfig, KitLocale, KitMessages, createKitI18n, defineMessages };
@@ -1 +1 @@
1
- import{setupI18n as e}from"@lingui/core";import{compileMessage as t}from"@lingui/message-utils/compileMessage";function n({locale:n=`en`,catalogs:r}={}){let i=e();if(i.setMessagesCompiler(t),i.load(`en`,{}),r)for(let[e,t]of Object.entries(r))t&&i.load(e,t);return i.activate(n),i}export{n as createKitI18n};
1
+ import{setupI18n as e}from"@lingui/core";import{compileMessage as t}from"@lingui/message-utils/compileMessage";import{generateMessageId as n}from"@lingui/message-utils/generateMessageId";function r(e){let t={};for(let[r,i]of Object.entries(e))!r||typeof i!=`string`||(t[n(r)]=i);return t}function i({locale:n=`en`,messages:r}={}){let i=e();if(i.setMessagesCompiler(t),i.load(`en`,{}),r)for(let[e,t]of Object.entries(r))t&&i.load(e,t);return i.activate(n),i}export{i as createKitI18n,r as defineMessages};
@@ -2,7 +2,15 @@ import { ComponentType } from "react";
2
2
  import { I18n } from "@lingui/core";
3
3
 
4
4
  //#region src/shared/i18n/useLingui.d.ts
5
- interface LinguiContextValue {
5
+ /**
6
+ * Shape of the value returned by the kit's {@link useLingui}. Mirrors Lingui's own
7
+ * `LinguiContextValue` (`{ i18n, _, defaultComponent? }`) so the macro's rewrite of `` t`…` ``
8
+ * into `_({ id, message })` calls type-checks against this surface.
9
+ *
10
+ * Exported alongside {@link useLingui} so power users wrapping the hook can name the return
11
+ * type without reaching back into Lingui internals.
12
+ */
13
+ interface KitLinguiContextValue {
6
14
  i18n: I18n;
7
15
  defaultComponent?: ComponentType<{
8
16
  id: string;
@@ -30,6 +38,6 @@ interface LinguiContextValue {
30
38
  * Callers shouldn't import this directly — they should write `import { useLingui } from
31
39
  * "@lingui/react/macro"` and let the build pipeline rewire the runtime target.
32
40
  */
33
- declare function useLingui(): LinguiContextValue;
41
+ declare function useLingui(): KitLinguiContextValue;
34
42
  //#endregion
35
- export { useLingui };
43
+ export { KitLinguiContextValue, useLingui };
@@ -0,0 +1,12 @@
1
+ import { SVGProps } from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
+
4
+ //#region src/shared/icons/ActivityIcon.d.ts
5
+ /**
6
+ * Activity glyph — clock-arrow combo. Used as the header trigger on `<DepositDialog>`
7
+ * and `<WithdrawDialog>` to open the cross-flow activity surface. Matches the kit's icon
8
+ * convention (24×24 viewBox, `currentColor` stroke, 2px stroke width).
9
+ */
10
+ declare function ActivityIcon(props: SVGProps<SVGSVGElement>): _$react_jsx_runtime0.JSX.Element;
11
+ //#endregion
12
+ export { ActivityIcon };
@@ -0,0 +1 @@
1
+ import{jsx as e,jsxs as t}from"react/jsx-runtime";function n(n){return t(`svg`,{fill:`none`,height:`24`,stroke:`currentColor`,strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:`2`,viewBox:`0 0 24 24`,width:`24`,xmlns:`http://www.w3.org/2000/svg`,...n,children:[e(`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`}),e(`path`,{d:`M3 3v5h5`}),e(`path`,{d:`M12 7v5l4 2`})]})}export{n as ActivityIcon};
@@ -0,0 +1,14 @@
1
+ import { SVGProps } from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
+
4
+ //#region src/shared/icons/BitcoinIcon.d.ts
5
+ /**
6
+ * Bitcoin coin glyph — a solid coin with the ₿ mark knocked out as negative space
7
+ * (`fillRule="evenodd"`). Used as the iconographic shorthand for the crypto payment rail in
8
+ * `Deposit.RailPicker`. Monochrome: the fill follows `currentColor`, so it tints with the
9
+ * surrounding text colour. The kit's only crypto-symbol icon; appropriate wherever a single glyph
10
+ * needs to represent "crypto" as a category (not a specific token — for that use a `TokenLogo`).
11
+ */
12
+ declare function BitcoinIcon(props: SVGProps<SVGSVGElement>): _$react_jsx_runtime0.JSX.Element;
13
+ //#endregion
14
+ export { BitcoinIcon };
@@ -0,0 +1 @@
1
+ import{jsx as e}from"react/jsx-runtime";function t(t){return e(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:24,height:24,viewBox:`0 0 500 500`,fill:`currentColor`,...t,children:e(`path`,{fillRule:`evenodd`,d:`M43.43,125.143c7.71-10.766,14.875-21.901,23.562-31.986c15.8-18.343,33.692-34.063,54.18-47.075c18.379-11.672,37.761-20.872,58.501-27.305c32.294-10.018,65.26-12.997,98.838-9.165c24.544,2.801,48.191,9.067,70.713,19.215c13.633,6.142,26.456,13.731,39.025,21.927c25.328,16.515,45.618,38.014,62.58,62.577c18.116,26.236,29.889,55.421,36.346,86.725c4.535,21.983,6.449,44.171,4.503,66.504c-2.399,27.536-8.514,54.086-19.938,79.604c-9.662,21.583-21.589,41.401-36.861,59.301c-14.94,17.511-31.788,32.831-51.149,45.461c-13.184,8.6-26.926,16.276-41.434,21.975c-24.274,9.537-49.447,15.986-75.787,17.115c-18.545,0.795-36.985,0.483-55.279-2.763c-15.713-2.788-31.049-6.858-46.063-12.496c-14.566-5.47-28.693-11.95-41.709-20.143c-18.766-11.812-35.683-26.147-50.737-42.663c-16.773-18.403-30.373-38.808-40.779-61.344c-14.7-31.835-21.929-65.401-22.359-100.425c-0.162-13.173,1.349-26.244,3.105-39.283c0.126-0.933-0.002-1.899-0.012-2.851c1.536-0.952,1.4-2.618,1.677-4.071c3.906-20.483,10.494-40.059,19.418-58.906C36.933,138.397,41.296,132.307,43.43,125.143z M325.157,254.513c6.537-3.474,12.749-5.465,17.658-9.85c18.918-16.899,23.96-56.673-6.747-75.833c-9.566-5.969-19.77-10.393-30.77-14.907c1.819-14.731,7.709-28.516,9.622-43.603c-9.076-2.249-17.578-5.234-26.425-6.193c-3.617,14.177-7.085,27.769-10.674,41.837c-6.78-2.076-13.761-1.879-20.142-5.473c2.302-14.39,7.773-27.872,9.268-42.314c-9.322-1.464-17.216-5.094-26.265-5.485c-3.563,14.209-7.011,27.958-10.586,42.215c-17.944-2.75-34.419-8.921-52.52-12.239c-3.977,8.91-5.738,18.311-7.334,28.313c5.896,1.392,11.022,2.623,16.158,3.811c12.965,2.998,16.517,10.086,13.439,21.424c-2.19,8.065-4.166,16.189-6.182,24.301c-7.245,29.16-14.432,58.333-21.72,87.482c-1.642,6.567-5.734,8.706-12.398,7.731c-6.563-0.96-12.757-3.907-19.99-3.693c-3.136,10.032-9.378,18.871-11.588,29.946c17.236,4.391,33.911,8.639,51.344,13.08c-1.312,15.208-7.614,29.125-9.476,44.441c8.739,2.095,16.965,4.066,25.544,6.123c5.653-14.044,6.957-28.803,12.226-43.33c6.351,3.265,13.397,2.317,19.612,6.427c-3.387,14.003-6.762,27.952-10.178,42.077c8.986,3.216,17.753,4.528,26.758,6.77c3.645-14.604,7.169-28.728,10.578-42.386c2.123-1.091,3.676-0.888,5.143-0.574c14.113,3.021,28.39,3.726,42.676,2.14c12.368-1.373,23.343-6.088,32.148-15.372c9.791-10.323,14.71-22.952,17.078-36.535c1.93-11.065,1.436-22.277-5.06-32.071C341.263,265.099,334.27,259.243,325.157,254.513z M223.128,312.17c17.411,4.325,34.803,8.95,53.02,5.624c9.715-1.774,17.037-6.73,19.985-16.503c2.78-9.218,1.164-17.593-5.673-24.879c-7.11-7.576-16.254-11.514-25.682-14.807c-11.264-3.934-22.683-7.508-34.99-8.48c-4.716,19.168-9.293,37.773-13.972,56.788C218.797,310.842,220.933,311.625,223.128,312.17z M284.628,231.846c9.628-1.368,17.612-7.738,19.958-16.393c2.869-10.583-0.337-19.865-8.902-26.178c-9.718-7.163-20.908-10.807-32.47-13.337c-4.307-0.943-8.544-3.454-13.756-1.759c-4.143,16.837-8.303,33.747-12.599,51.209C253.316,229.543,268.47,234.141,284.628,231.846z`})})}export{t as BitcoinIcon};
@@ -0,0 +1,16 @@
1
+ import { SVGProps } from "react";
2
+ import * as _$react_jsx_runtime0 from "react/jsx-runtime";
3
+
4
+ //#region src/shared/icons/CardIcon.d.ts
5
+ /**
6
+ * Generic credit-card outline. Used as the themed monochrome glyph for the
7
+ * onramp ("Cash") method in `Deposit.Method` and the onramp rail tab;
8
+ * brand-specific card art ships through the `DepositMethodInput.icon` override
9
+ * prop when the integrator has approval for the official mark.
10
+ *
11
+ * SVG path mirrors the `credit-card` icon from lucide (MIT) — inlined because
12
+ * `@stridge/kit` must not depend on `lucide-react`.
13
+ */
14
+ declare function CardIcon(props: SVGProps<SVGSVGElement>): _$react_jsx_runtime0.JSX.Element;
15
+ //#endregion
16
+ export { CardIcon };