@huma-finance/widgets 0.0.73-beta.924 → 0.0.73-beta.939

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 (264) hide show
  1. package/.env.example +3 -3
  2. package/{.eslintrc.js → .eslintrc.cjs} +1 -2
  3. package/.prettierrc.json +16 -0
  4. package/API.md +1 -1
  5. package/dist/index.js +220452 -11018
  6. package/dist/src/components/ApolloWrapper.d.ts +4 -0
  7. package/dist/src/components/ApproveAllowanceModal.d.ts +13 -0
  8. package/dist/src/components/ApproveAllowanceModalV2.d.ts +14 -0
  9. package/dist/src/components/BottomButton.d.ts +9 -0
  10. package/dist/src/components/ChainSupportProvider.d.ts +2 -0
  11. package/dist/src/components/ChooseAmountModal.d.ts +23 -0
  12. package/dist/src/components/ConfirmTransferModal.d.ts +19 -0
  13. package/dist/src/components/CreditLine/approve/1-ApproveAllowance.d.ts +9 -0
  14. package/dist/src/components/CreditLine/approve/2-Success.d.ts +8 -0
  15. package/dist/src/components/CreditLine/approve/index.d.ts +20 -0
  16. package/dist/src/components/CreditLine/autoPaybackV2/1-ApproveAllowance.d.ts +8 -0
  17. package/dist/src/components/CreditLine/autoPaybackV2/2-Success.d.ts +6 -0
  18. package/dist/src/components/CreditLine/autoPaybackV2/index.d.ts +15 -0
  19. package/dist/src/components/CreditLine/borrow/1-Evaluation.d.ts +8 -0
  20. package/dist/src/components/CreditLine/borrow/2-ChooseAmount.d.ts +8 -0
  21. package/dist/src/components/CreditLine/borrow/3-ApproveAllowance.d.ts +7 -0
  22. package/dist/src/components/CreditLine/borrow/4-Transfer.d.ts +7 -0
  23. package/dist/src/components/CreditLine/borrow/5-Success.d.ts +10 -0
  24. package/dist/src/components/CreditLine/borrow/6-Notifications.d.ts +6 -0
  25. package/dist/src/components/CreditLine/borrow/index.d.ts +19 -0
  26. package/dist/src/components/CreditLine/borrowV2/1-ChooseAmount.d.ts +9 -0
  27. package/dist/src/components/CreditLine/borrowV2/2-ApproveAllowance.d.ts +8 -0
  28. package/dist/src/components/CreditLine/borrowV2/3-Transfer.d.ts +7 -0
  29. package/dist/src/components/CreditLine/borrowV2/4-Success.d.ts +10 -0
  30. package/dist/src/components/CreditLine/borrowV2/5-Notifications.d.ts +6 -0
  31. package/dist/src/components/CreditLine/borrowV2/index.d.ts +15 -0
  32. package/dist/src/components/CreditLine/payment/1-ChooseAmount.d.ts +9 -0
  33. package/dist/src/components/CreditLine/payment/2-ApproveAllowance.d.ts +7 -0
  34. package/dist/src/components/CreditLine/payment/3-Transfer.d.ts +7 -0
  35. package/dist/src/components/CreditLine/payment/4-Success.d.ts +8 -0
  36. package/dist/src/components/CreditLine/payment/index.d.ts +17 -0
  37. package/dist/src/components/CreditLine/paymentV2/1-ChooseAmount.d.ts +11 -0
  38. package/dist/src/components/CreditLine/paymentV2/2-ApproveAllowance.d.ts +8 -0
  39. package/dist/src/components/CreditLine/paymentV2/3-Transfer.d.ts +8 -0
  40. package/dist/src/components/CreditLine/paymentV2/4-Success.d.ts +8 -0
  41. package/dist/src/components/CreditLine/paymentV2/index.d.ts +15 -0
  42. package/dist/src/components/CreditLine/solanaBorrow/1-ChooseAmount.d.ts +9 -0
  43. package/dist/src/components/CreditLine/solanaBorrow/2-Transfer.d.ts +7 -0
  44. package/dist/src/components/CreditLine/solanaBorrow/3-Done.d.ts +10 -0
  45. package/dist/src/components/CreditLine/solanaBorrow/index.d.ts +17 -0
  46. package/dist/src/components/CreditLine/solanaPayment/1-ChooseAmount.d.ts +9 -0
  47. package/dist/src/components/CreditLine/solanaPayment/2-Transfer.d.ts +7 -0
  48. package/dist/src/components/CreditLine/solanaPayment/3-Done.d.ts +8 -0
  49. package/dist/src/components/CreditLine/solanaPayment/index.d.ts +14 -0
  50. package/dist/src/components/CreditLine/supplyFLC/1-ApproveAllowance.d.ts +10 -0
  51. package/dist/src/components/CreditLine/supplyFLC/2-Transfer.d.ts +10 -0
  52. package/dist/src/components/CreditLine/supplyFLC/3-Success.d.ts +10 -0
  53. package/dist/src/components/CreditLine/supplyFLC/index.d.ts +15 -0
  54. package/dist/src/components/ErrorModal.d.ts +12 -0
  55. package/dist/src/components/HumaLoading.d.ts +7 -0
  56. package/dist/src/components/HumaSnackBar.d.ts +10 -0
  57. package/dist/src/components/InputAmountModal.d.ts +18 -0
  58. package/dist/src/components/InvoiceFactoring/borrow/1-Evaluation.d.ts +8 -0
  59. package/dist/src/components/InvoiceFactoring/borrow/2-ChooseAmount.d.ts +8 -0
  60. package/dist/src/components/InvoiceFactoring/borrow/3-ConfirmTransfer.d.ts +2 -0
  61. package/dist/src/components/InvoiceFactoring/borrow/4-ApproveNFT.d.ts +8 -0
  62. package/dist/src/components/InvoiceFactoring/borrow/5-Transfer.d.ts +8 -0
  63. package/dist/src/components/InvoiceFactoring/borrow/6-Success.d.ts +6 -0
  64. package/dist/src/components/InvoiceFactoring/borrow/index.d.ts +20 -0
  65. package/dist/src/components/InvoiceFactoring/payment/1-ChooseAmount.d.ts +8 -0
  66. package/dist/src/components/InvoiceFactoring/payment/2-ApproveAllowance.d.ts +7 -0
  67. package/dist/src/components/InvoiceFactoring/payment/3-Transfer.d.ts +7 -0
  68. package/dist/src/components/InvoiceFactoring/payment/4-Success.d.ts +8 -0
  69. package/dist/src/components/InvoiceFactoring/payment/index.d.ts +17 -0
  70. package/dist/src/components/Lend/addRedemptionV2/1-ChooseTranche.d.ts +8 -0
  71. package/dist/src/components/Lend/addRedemptionV2/2-ChooseAmount.d.ts +10 -0
  72. package/dist/src/components/Lend/addRedemptionV2/3-Transfer.d.ts +10 -0
  73. package/dist/src/components/Lend/addRedemptionV2/4-Done.d.ts +6 -0
  74. package/dist/src/components/Lend/addRedemptionV2/index.d.ts +23 -0
  75. package/dist/src/components/Lend/cancelRedemptionV2 /1-Transfer.d.ts +10 -0
  76. package/dist/src/components/Lend/cancelRedemptionV2 /2-Done.d.ts +10 -0
  77. package/dist/src/components/Lend/cancelRedemptionV2 /index.d.ts +22 -0
  78. package/dist/src/components/Lend/components/ApproveLenderBase.d.ts +14 -0
  79. package/dist/src/components/Lend/components/PersonaEvaluation.d.ts +17 -0
  80. package/dist/src/components/Lend/components/SecuritizeEvaluation.d.ts +8 -0
  81. package/dist/src/components/Lend/solanaAddRedemption/1-ChooseTranche.d.ts +8 -0
  82. package/dist/src/components/Lend/solanaAddRedemption/2-ChooseAmount.d.ts +11 -0
  83. package/dist/src/components/Lend/solanaAddRedemption/3-Transfer.d.ts +8 -0
  84. package/dist/src/components/Lend/solanaAddRedemption/4-Done.d.ts +8 -0
  85. package/dist/src/components/Lend/solanaAddRedemption/index.d.ts +19 -0
  86. package/dist/src/components/Lend/solanaCancelRedemption/1-ChooseTranche.d.ts +8 -0
  87. package/dist/src/components/Lend/solanaCancelRedemption/2-Transfer.d.ts +11 -0
  88. package/dist/src/components/Lend/solanaCancelRedemption/3-Done.d.ts +11 -0
  89. package/dist/src/components/Lend/solanaCancelRedemption/index.d.ts +16 -0
  90. package/dist/src/components/Lend/solanaEnableAutoRedemption/1-ApproveAllowance.d.ts +7 -0
  91. package/dist/src/components/Lend/solanaEnableAutoRedemption/2-Transfer.d.ts +9 -0
  92. package/dist/src/components/Lend/solanaEnableAutoRedemption/3-Success.d.ts +10 -0
  93. package/dist/src/components/Lend/solanaEnableAutoRedemption/index.d.ts +18 -0
  94. package/dist/src/components/Lend/solanaSupply/1-Evaluation.d.ts +12 -0
  95. package/dist/src/components/Lend/solanaSupply/2-ApproveLender.d.ts +10 -0
  96. package/dist/src/components/Lend/solanaSupply/3-ChooseTranche.d.ts +9 -0
  97. package/dist/src/components/Lend/solanaSupply/4-ChooseAmount.d.ts +13 -0
  98. package/dist/src/components/Lend/solanaSupply/5-ApproveAllowance.d.ts +7 -0
  99. package/dist/src/components/Lend/solanaSupply/6-Transfer.d.ts +11 -0
  100. package/dist/src/components/Lend/solanaSupply/7-Success.d.ts +12 -0
  101. package/dist/src/components/Lend/solanaSupply/8-PointsEarned.d.ts +11 -0
  102. package/dist/src/components/Lend/solanaSupply/index.d.ts +24 -0
  103. package/dist/src/components/Lend/solanaWithdraw/1-ConfirmTransfer.d.ts +9 -0
  104. package/dist/src/components/Lend/solanaWithdraw/2-Transfer.d.ts +9 -0
  105. package/dist/src/components/Lend/solanaWithdraw/3-Done.d.ts +10 -0
  106. package/dist/src/components/Lend/solanaWithdraw/index.d.ts +25 -0
  107. package/dist/src/components/Lend/stellarSupply/1-Evaluation.d.ts +4 -0
  108. package/dist/src/components/Lend/stellarSupply/2-ChooseTranche.d.ts +9 -0
  109. package/dist/src/components/Lend/stellarSupply/3-ChooseAmount.d.ts +12 -0
  110. package/dist/src/components/Lend/stellarSupply/4-Transfer.d.ts +8 -0
  111. package/dist/src/components/Lend/stellarSupply/5-Success.d.ts +10 -0
  112. package/dist/src/components/Lend/stellarSupply/index.d.ts +22 -0
  113. package/dist/src/components/Lend/supply/1-Evaluation/EvaluationEA.d.ts +8 -0
  114. package/dist/src/components/Lend/supply/1-Evaluation/EvaluationKYC.d.ts +8 -0
  115. package/dist/src/components/Lend/supply/1-Evaluation/index.d.ts +9 -0
  116. package/dist/src/components/Lend/supply/2-ChooseAmount.d.ts +11 -0
  117. package/dist/src/components/Lend/supply/3-ApproveAllowance.d.ts +7 -0
  118. package/dist/src/components/Lend/supply/4-Transfer.d.ts +7 -0
  119. package/dist/src/components/Lend/supply/5-Success.d.ts +9 -0
  120. package/dist/src/components/Lend/supply/6-Notifications.d.ts +6 -0
  121. package/dist/src/components/Lend/supply/index.d.ts +17 -0
  122. package/dist/src/components/Lend/supplyV2/1-ChooseTranche.d.ts +9 -0
  123. package/dist/src/components/Lend/supplyV2/2-Evaluation.d.ts +12 -0
  124. package/dist/src/components/Lend/supplyV2/3-ApproveLender.d.ts +10 -0
  125. package/dist/src/components/Lend/supplyV2/4-ChooseAmount.d.ts +14 -0
  126. package/dist/src/components/Lend/supplyV2/5-ApproveAllowance.d.ts +7 -0
  127. package/dist/src/components/Lend/supplyV2/6-Transfer.d.ts +11 -0
  128. package/dist/src/components/Lend/supplyV2/7-Success.d.ts +13 -0
  129. package/dist/src/components/Lend/supplyV2/8-Notifications.d.ts +8 -0
  130. package/dist/src/components/Lend/supplyV2/index.d.ts +23 -0
  131. package/dist/src/components/Lend/withdraw/1-CheckWithdrawble.d.ts +8 -0
  132. package/dist/src/components/Lend/withdraw/2-ChooseAmount.d.ts +10 -0
  133. package/dist/src/components/Lend/withdraw/3-Transfer.d.ts +7 -0
  134. package/dist/src/components/Lend/withdraw/4-Success.d.ts +8 -0
  135. package/dist/src/components/Lend/withdraw/index.d.ts +17 -0
  136. package/dist/src/components/Lend/withdrawV2/1-ConfirmTransfer.d.ts +11 -0
  137. package/dist/src/components/Lend/withdrawV2/2-Transfer.d.ts +9 -0
  138. package/dist/src/components/Lend/withdrawV2/3-Done.d.ts +10 -0
  139. package/dist/src/components/Lend/withdrawV2/index.d.ts +17 -0
  140. package/dist/src/components/LoadingModal.d.ts +9 -0
  141. package/dist/src/components/Notifi/NotifiContextWrapper.d.ts +7 -0
  142. package/dist/src/components/Notifi/NotifiSubscriptionModal.d.ts +7 -0
  143. package/dist/src/components/NumericFormatCustom.d.ts +14 -0
  144. package/dist/src/components/PointsEarned.d.ts +10 -0
  145. package/dist/src/components/ReceivableBackedCreditLine/borrow/1-ChooseAmount.d.ts +10 -0
  146. package/dist/src/components/ReceivableBackedCreditLine/borrow/2-ApproveAllowance.d.ts +8 -0
  147. package/dist/src/components/ReceivableBackedCreditLine/borrow/3-ApproveReceivable.d.ts +8 -0
  148. package/dist/src/components/ReceivableBackedCreditLine/borrow/4-Transfer.d.ts +8 -0
  149. package/dist/src/components/ReceivableBackedCreditLine/borrow/5-Success.d.ts +10 -0
  150. package/dist/src/components/ReceivableBackedCreditLine/borrow/6-Notifications.d.ts +6 -0
  151. package/dist/src/components/ReceivableBackedCreditLine/borrow/index.d.ts +17 -0
  152. package/dist/src/components/ReceivableBackedCreditLine/payment/1-ChoosePaymentType.d.ts +8 -0
  153. package/dist/src/components/ReceivableBackedCreditLine/payment/2-ChooseAmount.d.ts +12 -0
  154. package/dist/src/components/ReceivableBackedCreditLine/payment/3-ApproveAllowance.d.ts +10 -0
  155. package/dist/src/components/ReceivableBackedCreditLine/payment/4-CreateReceivable.d.ts +9 -0
  156. package/dist/src/components/ReceivableBackedCreditLine/payment/5-ApproveReceivable.d.ts +8 -0
  157. package/dist/src/components/ReceivableBackedCreditLine/payment/6-Transfer.d.ts +14 -0
  158. package/dist/src/components/ReceivableBackedCreditLine/payment/7-Success.d.ts +12 -0
  159. package/dist/src/components/ReceivableBackedCreditLine/payment/index.d.ts +21 -0
  160. package/dist/src/components/SignIn.d.ts +6 -0
  161. package/dist/src/components/SolanaErrorModal.d.ts +13 -0
  162. package/dist/src/components/SolanaTxDoneModal.d.ts +12 -0
  163. package/dist/src/components/SolanaTxSendModal.d.ts +12 -0
  164. package/dist/src/components/SolanaViewOnExplorer.d.ts +8 -0
  165. package/dist/src/components/StellarTxDoneModal.d.ts +12 -0
  166. package/dist/src/components/StellarTxSendModal.d.ts +8 -0
  167. package/dist/src/components/StellarViewOnExplorer.d.ts +8 -0
  168. package/dist/src/components/StreamFactoring/borrow/1-Evaluation.d.ts +9 -0
  169. package/dist/src/components/StreamFactoring/borrow/2-ChooseAmount.d.ts +8 -0
  170. package/dist/src/components/StreamFactoring/borrow/3-ConfirmTransfer.d.ts +2 -0
  171. package/dist/src/components/StreamFactoring/borrow/4-ApproveAllowance.d.ts +7 -0
  172. package/dist/src/components/StreamFactoring/borrow/5-Permit.d.ts +10 -0
  173. package/dist/src/components/StreamFactoring/borrow/6-Transfer.d.ts +7 -0
  174. package/dist/src/components/StreamFactoring/borrow/7-Success.d.ts +6 -0
  175. package/dist/src/components/StreamFactoring/borrow/index.d.ts +13 -0
  176. package/dist/src/components/StreamFactoring/payment/ChooseAmount.d.ts +8 -0
  177. package/dist/src/components/StreamFactoring/payment/Success.d.ts +8 -0
  178. package/dist/src/components/StreamFactoring/payment/Transfer.d.ts +7 -0
  179. package/dist/src/components/StreamFactoring/payment/index.d.ts +10 -0
  180. package/dist/src/components/SuperfluidFactoring/index.d.ts +12 -0
  181. package/dist/src/components/TxDoneModal.d.ts +9 -0
  182. package/dist/src/components/TxSendModal.d.ts +13 -0
  183. package/dist/src/components/TxSendModalV2.d.ts +13 -0
  184. package/dist/src/components/ViewOnExplorer.d.ts +6 -0
  185. package/dist/src/components/WidgetWrapper.d.ts +11 -0
  186. package/dist/src/components/WrapperModal.d.ts +8 -0
  187. package/dist/src/components/buttons/TableActionButton.d.ts +8 -0
  188. package/dist/src/components/buttons/index.d.ts +1 -0
  189. package/dist/src/components/humaModal/HumaModal.d.ts +13 -0
  190. package/dist/src/components/humaModal/HumaModalHeader.d.ts +12 -0
  191. package/dist/src/components/humaModal/index.d.ts +2 -0
  192. package/dist/src/components/icons/index.d.ts +23 -0
  193. package/dist/src/components/images/index.d.ts +3 -0
  194. package/dist/src/cosmos/CreditLineBorrow.fixture.d.ts +2 -0
  195. package/dist/src/cosmos/CreditLinePayment.fixture.d.ts +2 -0
  196. package/dist/src/cosmos/InvoiceFactoringBorrow.fixture.d.ts +2 -0
  197. package/dist/src/cosmos/InvoiceFactoringPayment.fixture.d.ts +2 -0
  198. package/dist/src/cosmos/LendSupply.fixture.d.ts +2 -0
  199. package/dist/src/cosmos/LendWithdraw.fixture.d.ts +2 -0
  200. package/dist/src/cosmos/SDKTesting.fixture.d.ts +2 -0
  201. package/dist/src/cosmos/SuperfluidFactoringBorrow.fixture.d.ts +2 -0
  202. package/dist/src/cosmos/WalletWrapper.d.ts +3 -0
  203. package/dist/src/cosmos/utils/index.d.ts +18 -0
  204. package/dist/src/hooks/useEA.d.ts +8 -0
  205. package/dist/src/hooks/useElementDimensions.d.ts +5 -0
  206. package/dist/src/hooks/useNotifi.d.ts +10 -0
  207. package/dist/src/hooks/useRedux.d.ts +6 -0
  208. package/dist/src/index.d.ts +385 -0
  209. package/dist/src/reportWebVitals.d.ts +3 -0
  210. package/dist/src/setupTests.d.ts +0 -0
  211. package/dist/src/store/index.d.ts +10 -0
  212. package/dist/src/store/widgets.reducers.d.ts +56 -0
  213. package/dist/src/store/widgets.selectors.d.ts +2 -0
  214. package/dist/src/store/widgets.store.d.ts +59 -0
  215. package/dist/src/theme/breakpoints.d.ts +5 -0
  216. package/dist/src/theme/components.d.ts +2 -0
  217. package/dist/src/theme/coreThemeConstants.d.ts +18 -0
  218. package/dist/src/theme/cssMixins.d.ts +20 -0
  219. package/dist/src/theme/hooks/useGetSizes.d.ts +12 -0
  220. package/dist/src/theme/index.d.ts +2 -0
  221. package/dist/src/theme/palette.d.ts +53 -0
  222. package/dist/src/theme/shape.d.ts +2 -0
  223. package/dist/src/theme/theme.types.d.ts +71 -0
  224. package/dist/src/theme/typography.d.ts +2 -0
  225. package/dist/vite.config.d.ts +2 -0
  226. package/package.json +21 -34
  227. package/src/components/Lend/components/ApproveLenderBase.tsx +6 -3
  228. package/src/components/Lend/components/PersonaEvaluation.tsx +5 -2
  229. package/src/components/Lend/components/SecuritizeEvaluation.tsx +5 -2
  230. package/src/components/Lend/solanaSupply/6-Transfer.tsx +1 -1
  231. package/src/components/Lend/solanaSupply/8-PointsEarned.tsx +6 -2
  232. package/src/components/Lend/supply/1-Evaluation/EvaluationKYC.tsx +5 -2
  233. package/src/components/Lend/supplyV2/2-Evaluation.tsx +2 -2
  234. package/src/components/Lend/supplyV2/3-ApproveLender.tsx +1 -1
  235. package/src/components/Lend/supplyV2/6-Transfer.tsx +1 -2
  236. package/src/components/Lend/supplyV2/index.tsx +1 -1
  237. package/src/components/Notifi/NotifiContextWrapper.tsx +3 -3
  238. package/src/components/icons/index.tsx +21 -21
  239. package/src/cosmos/InvoiceFactoringBorrow.fixture.tsx +1 -1
  240. package/src/cosmos/SuperfluidFactoringBorrow.fixture.tsx +2 -4
  241. package/src/cosmos/utils/index.ts +4 -2
  242. package/src/hooks/useEA.ts +1 -2
  243. package/src/hooks/useNotifi.ts +1 -1
  244. package/src/index.tsx +4 -7
  245. package/tsconfig.json +20 -17
  246. package/vite-env.d.ts +2 -0
  247. package/vite.config.ts +48 -0
  248. package/webpack.cosmos.js +1 -1
  249. package/.prettierrc.js +0 -16
  250. package/babel.config.js +0 -15
  251. package/config-overrides.js +0 -9
  252. package/dist/cjs/index.cjs +0 -11781
  253. package/dist/cjs/index.cjs.map +0 -1
  254. package/dist/index.d.ts +0 -758
  255. package/dist/index.js.map +0 -1
  256. package/public/favicon.ico +0 -0
  257. package/public/index.html +0 -40
  258. package/public/logo192.png +0 -0
  259. package/public/logo512.png +0 -0
  260. package/public/manifest.json +0 -25
  261. package/public/robots.txt +0 -3
  262. package/rollup.config.js +0 -81
  263. package/src/cosmos/utils/env.ts +0 -6
  264. package/src/react-app-env.d.ts +0 -1
@@ -0,0 +1,71 @@
1
+ import { Theme as MUITheme, PaletteColorOptions } from '@mui/material/styles';
2
+ import { cssMixins } from './cssMixins';
3
+ declare module '@mui/material/styles/createPalette' {
4
+ interface TypeText {
5
+ quaternary: string;
6
+ tertiary: string;
7
+ }
8
+ }
9
+ declare module '@mui/material/styles' {
10
+ interface Theme {
11
+ cssMixins: typeof cssMixins;
12
+ }
13
+ interface ThemeOptions {
14
+ cssMixins: typeof cssMixins;
15
+ }
16
+ interface PaletteColor {
17
+ superDark?: string;
18
+ superLight?: string;
19
+ }
20
+ interface SimplePaletteColorOptions {
21
+ contrastText?: string;
22
+ dark?: string;
23
+ faded?: string;
24
+ light?: string;
25
+ main: string;
26
+ superDark?: string;
27
+ superLight?: string;
28
+ }
29
+ interface Palette {
30
+ alert: SimplePaletteColorOptions;
31
+ default: SimplePaletteColorOptions;
32
+ }
33
+ interface PaletteOptions {
34
+ alert?: PaletteColorOptions;
35
+ default?: PaletteColorOptions;
36
+ }
37
+ interface TypographyVariants {
38
+ body2Small: React.CSSProperties;
39
+ h3Large: React.CSSProperties;
40
+ labsSmall: React.CSSProperties;
41
+ nav: React.CSSProperties;
42
+ navSub: React.CSSProperties;
43
+ }
44
+ interface TypographyVariantsOptions {
45
+ body2Small: React.CSSProperties;
46
+ h3Large: React.CSSProperties;
47
+ labsSmall: React.CSSProperties;
48
+ nav: React.CSSProperties;
49
+ navSub: React.CSSProperties;
50
+ }
51
+ }
52
+ declare module '@mui/material/Typography' {
53
+ interface TypographyPropsVariantOverrides {
54
+ body2Small: true;
55
+ h3Large: true;
56
+ labsSmall: true;
57
+ nav: true;
58
+ navSub: true;
59
+ sceneHeader: true;
60
+ }
61
+ }
62
+ declare module '@mui/material/Button' {
63
+ interface ButtonPropsColorOverrides {
64
+ alert: PaletteColorOptions | true;
65
+ default: PaletteColorOptions | true;
66
+ }
67
+ }
68
+ declare module '@emotion/react' {
69
+ interface Theme extends MUITheme {
70
+ }
71
+ }
@@ -0,0 +1,2 @@
1
+ import { ThemeOptions } from '@mui/material';
2
+ export declare const typography: ThemeOptions['typography'];
@@ -0,0 +1,2 @@
1
+ declare const _default: import('vite').UserConfig;
2
+ export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@huma-finance/widgets",
3
- "version": "0.0.73-beta.924+29122ba",
3
+ "version": "0.0.73-beta.939+8b148f9",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -8,16 +8,10 @@
8
8
  "type": "git",
9
9
  "url": "git+https://github.com/00labs/huma-js.git"
10
10
  },
11
- "types": "dist/index.d.ts",
11
+ "type": "module",
12
+ "types": "dist/src/index.d.ts",
12
13
  "main": "dist/cjs/index.cjs",
13
14
  "module": "dist/index.js",
14
- "exports": {
15
- ".": {
16
- "types": "./dist/index.d.ts",
17
- "import": "./dist/index.js",
18
- "require": "./dist/cjs/index.cjs"
19
- }
20
- },
21
15
  "dependencies": {
22
16
  "@apollo/client": "^3.7.2",
23
17
  "@coinbase/wallet-sdk": "^3.5.3",
@@ -27,11 +21,10 @@
27
21
  "@ethersproject/constants": "^5.7.0",
28
22
  "@ethersproject/contracts": "^5.7.0",
29
23
  "@ethersproject/experimental": "^5.7.0",
30
- "@ethersproject/providers": "^5.6.0",
31
24
  "@ethersproject/units": "^5.6.0",
32
- "@huma-finance/sdk": "^0.0.73-beta.924+29122ba",
33
- "@huma-finance/shared": "^0.0.73-beta.924+29122ba",
34
- "@huma-finance/web-shared": "^0.0.73-beta.924+29122ba",
25
+ "@huma-finance/sdk": "^0.0.73-beta.939+8b148f9",
26
+ "@huma-finance/shared": "^0.0.73-beta.939+8b148f9",
27
+ "@huma-finance/web-shared": "^0.0.73-beta.939+8b148f9",
35
28
  "@mui/x-date-pickers": "^5.0.7",
36
29
  "@notifi-network/notifi-frontend-client": "^1.1.2",
37
30
  "@notifi-network/notifi-react": "^1.1.2",
@@ -75,8 +68,7 @@
75
68
  },
76
69
  "scripts": {
77
70
  "start": "tsc -w",
78
- "prebuild": "tsc -p tsconfig.build.json",
79
- "build": "rollup -c",
71
+ "build": "vite build",
80
72
  "cosmos": "cosmos",
81
73
  "prettier": "prettier --write \"src/**/*.{js,ts,tsx,graphql}\"",
82
74
  "lint": "eslint --max-warnings=0 \"src/**/*.{js,ts,tsx,graphql}\"",
@@ -114,15 +106,6 @@
114
106
  "@babel/preset-react": "^7.14.5",
115
107
  "@emotion/babel-plugin": "^11.10.2",
116
108
  "@emotion/babel-preset-css-prop": "^11.2.0",
117
- "@rollup/plugin-babel": "^6.0.3",
118
- "@rollup/plugin-commonjs": "^24.0.1",
119
- "@rollup/plugin-image": "^3.0.2",
120
- "@rollup/plugin-inject": "^5.0.3",
121
- "@rollup/plugin-json": "^6.0.0",
122
- "@rollup/plugin-node-resolve": "^15.0.1",
123
- "@rollup/plugin-typescript": "^11.0.0",
124
- "@rollup/plugin-url": "^8.0.1",
125
- "@svgr/rollup": "^6.5.1",
126
109
  "@svgr/webpack": "^6.5.1",
127
110
  "@testing-library/cypress": "^9.0.0",
128
111
  "@testing-library/jest-dom": "^5.16.5",
@@ -165,12 +148,6 @@
165
148
  "path-browserify": "^1.0.1",
166
149
  "prettier": "^2.7.1",
167
150
  "react-cosmos": "^5.7.2",
168
- "rollup-plugin-dts": "^5.2.0",
169
- "rollup-plugin-node-externals": "^5.1.2",
170
- "rollup-plugin-peer-deps-external": "^2.2.4",
171
- "rollup-plugin-polyfill-node": "^0.12.0",
172
- "rollup-plugin-postcss": "^4.0.2",
173
- "rollup-plugin-scss": "^4.0.0",
174
151
  "sass": "^1.77.6",
175
152
  "stream-browserify": "^3.0.0",
176
153
  "typechain": "^8.1.0",
@@ -181,6 +158,7 @@
181
158
  "@coral-xyz/anchor": "^0.30.1",
182
159
  "@emotion/react": "^11.5.0",
183
160
  "@emotion/styled": "^11.3.0",
161
+ "@ethersproject/providers": "5.7.2",
184
162
  "@huma-finance/soroban-tranche-vault": "0.0.18",
185
163
  "@mui/icons-material": "^5.3.0",
186
164
  "@mui/material": "^5.0.6",
@@ -188,18 +166,27 @@
188
166
  "@mui/system": "^5.0.6",
189
167
  "@mui/x-date-pickers": "^5.0.7",
190
168
  "@solana/spl-token": "^0.4.8",
191
- "@solana/wallet-adapter-base": "^0.9.23",
192
- "@solana/wallet-adapter-react": "^0.15.35",
169
+ "@solana/wallet-adapter-base": "0.9.23",
170
+ "@solana/wallet-adapter-react": "0.15.35",
193
171
  "@solana/web3.js": "^1.95.3",
194
172
  "@soroban-react/core": "^9.3.0",
173
+ "@vitejs/plugin-react": "4.3.4",
174
+ "arweave": "^1.10.0",
175
+ "bs58": "6.0.0",
195
176
  "ethers": "^5.6.1",
196
177
  "react": ">=16.8.0",
197
178
  "react-dom": ">=16.8.0",
198
179
  "react-redux": ">=7.2.2",
199
- "redux": ">=4.1.2"
180
+ "redux": ">=4.1.2",
181
+ "vite": "6.0.11",
182
+ "vite-plugin-commonjs": "0.10.4",
183
+ "vite-plugin-dts": "4.5.0",
184
+ "vite-plugin-node-polyfills": "0.23.0",
185
+ "vite-plugin-svgr": "4.3.0",
186
+ "vite-tsconfig-paths": "5.1.4"
200
187
  },
201
188
  "optionalDependencies": {
202
189
  "encoding": "^0.1.13"
203
190
  },
204
- "gitHead": "29122ba3c1f4e50917e3044f4c285d4b635e6337"
191
+ "gitHead": "8b148f9340a401b544aa2739c82bcf839301a6d0"
205
192
  }
@@ -1,7 +1,6 @@
1
1
  /* eslint-disable no-await-in-loop */
2
2
  import {
3
3
  CHAIN_TYPE,
4
- checkIsDev,
5
4
  COMMON_ERROR_MESSAGE,
6
5
  IdentityServiceV2,
7
6
  NETWORK_TYPE,
@@ -9,7 +8,7 @@ import {
9
8
  timeUtil,
10
9
  TrancheType,
11
10
  } from '@huma-finance/shared'
12
- import { useChainInfo } from '@huma-finance/web-shared'
11
+ import { useChainInfo, checkIsDev } from '@huma-finance/web-shared'
13
12
  import React, { useCallback, useEffect } from 'react'
14
13
  import { useAppDispatch } from '../../../hooks/useRedux'
15
14
  import { setError, setStep } from '../../../store/widgets.reducers'
@@ -22,7 +21,7 @@ type Props = {
22
21
  chainType: CHAIN_TYPE
23
22
  networkType: NETWORK_TYPE
24
23
  isUniTranche: boolean
25
- documentHash: string
24
+ documentHash?: string
26
25
  chainSpecificData?: Record<string, unknown>
27
26
  changeTranche: (tranche: TrancheType) => void
28
27
  }
@@ -43,6 +42,10 @@ export function ApproveLenderBase({
43
42
 
44
43
  const approveLender = useCallback(
45
44
  async (trancheVault: string) => {
45
+ if (!documentHash) {
46
+ throw new Error('No document hash provided')
47
+ }
48
+
46
49
  let tryAttempts = 2
47
50
 
48
51
  while (tryAttempts > 0) {
@@ -1,6 +1,5 @@
1
1
  import {
2
2
  CHAIN_TYPE,
3
- checkIsDev,
4
3
  CloseModalOptions,
5
4
  IdentityServiceV2,
6
5
  IdentityVerificationStatusV2,
@@ -9,7 +8,11 @@ import {
9
8
  NETWORK_TYPE,
10
9
  VerificationStatusResultV2,
11
10
  } from '@huma-finance/shared'
12
- import { AUTH_ERROR_TYPE, useAuthErrorHandling } from '@huma-finance/web-shared'
11
+ import {
12
+ AUTH_ERROR_TYPE,
13
+ useAuthErrorHandling,
14
+ checkIsDev,
15
+ } from '@huma-finance/web-shared'
13
16
  import { Box, css, useTheme } from '@mui/material'
14
17
  import Persona, { Client } from 'persona'
15
18
  import React, { useCallback, useEffect, useRef, useState } from 'react'
@@ -1,6 +1,5 @@
1
1
  import {
2
2
  CHAINS,
3
- checkIsDev,
4
3
  configUtil,
5
4
  DocSignatureStatus,
6
5
  IdentityService,
@@ -10,7 +9,11 @@ import {
10
9
  timeUtil,
11
10
  VerificationStatusResult,
12
11
  } from '@huma-finance/shared'
13
- import { useAuthErrorHandling, useParamsSearch } from '@huma-finance/web-shared'
12
+ import {
13
+ useAuthErrorHandling,
14
+ useParamsSearch,
15
+ checkIsDev,
16
+ } from '@huma-finance/web-shared'
14
17
  import { Box, css, useTheme } from '@mui/material'
15
18
  import { useWeb3React } from '@web3-react/core'
16
19
  import React, { useCallback, useEffect, useMemo, useState } from 'react'
@@ -1,6 +1,5 @@
1
1
  import {
2
2
  CampaignService,
3
- checkIsDev,
4
3
  convertToShares,
5
4
  getTokenAccounts,
6
5
  NETWORK_TYPE,
@@ -13,6 +12,7 @@ import {
13
12
  useHumaProgram,
14
13
  useLenderAccounts,
15
14
  useTrancheTokenAccounts,
15
+ checkIsDev,
16
16
  } from '@huma-finance/web-shared'
17
17
  import {
18
18
  createApproveCheckedInstruction,
@@ -1,13 +1,17 @@
1
1
  import {
2
2
  CampaignService,
3
3
  CHAIN_TYPE,
4
- checkIsDev,
5
4
  CloseModalOptions,
6
5
  formatNumber,
7
6
  isEmpty,
8
7
  NETWORK_TYPE,
9
8
  } from '@huma-finance/shared'
10
- import { SolanaPoolState, txAtom, useChainInfo } from '@huma-finance/web-shared'
9
+ import {
10
+ SolanaPoolState,
11
+ txAtom,
12
+ useChainInfo,
13
+ checkIsDev,
14
+ } from '@huma-finance/web-shared'
11
15
  import { Box, css, useTheme } from '@mui/material'
12
16
  import { useResetAtom } from 'jotai/utils'
13
17
  import React, { useCallback, useEffect, useState } from 'react'
@@ -1,6 +1,5 @@
1
1
  import {
2
2
  CHAINS,
3
- checkIsDev,
4
3
  configUtil,
5
4
  DocSignatureStatus,
6
5
  IdentityService,
@@ -8,7 +7,11 @@ import {
8
7
  timeUtil,
9
8
  VerificationStatusResult,
10
9
  } from '@huma-finance/shared'
11
- import { useAuthErrorHandling, useParamsSearch } from '@huma-finance/web-shared'
10
+ import {
11
+ useAuthErrorHandling,
12
+ useParamsSearch,
13
+ checkIsDev,
14
+ } from '@huma-finance/web-shared'
12
15
  import { Box, css, useTheme } from '@mui/material'
13
16
  import { useWeb3React } from '@web3-react/core'
14
17
  import React, { useCallback, useEffect, useMemo, useState } from 'react'
@@ -14,7 +14,7 @@ type Props = {
14
14
  poolInfo: PoolInfoV2
15
15
  networkType: NETWORK_TYPE
16
16
  campaign?: Campaign
17
- documentHash: string
17
+ documentHash?: string
18
18
  handleClose: (options?: CloseModalOptions) => void
19
19
  }
20
20
 
@@ -30,7 +30,7 @@ export function Evaluation({
30
30
  <SecuritizeEvaluation poolInfo={poolInfo} handleClose={handleClose} />
31
31
  )
32
32
  }
33
- if (poolInfo.KYC?.Persona) {
33
+ if (poolInfo.KYC?.Persona && documentHash) {
34
34
  return (
35
35
  <PersonaEvaluation
36
36
  poolInfo={poolInfo}
@@ -11,7 +11,7 @@ import { ApproveLenderBase } from '../components/ApproveLenderBase'
11
11
  type Props = {
12
12
  poolInfo: PoolInfoV2
13
13
  isUniTranche: boolean
14
- documentHash: string
14
+ documentHash?: string
15
15
  changeTranche: (tranche: TrancheType) => void
16
16
  }
17
17
 
@@ -1,11 +1,10 @@
1
1
  import {
2
2
  CampaignService,
3
- checkIsDev,
4
3
  NETWORK_TYPE,
5
4
  PoolInfoV2,
6
5
  TrancheType,
7
6
  } from '@huma-finance/shared'
8
- import { useTrancheVaultContractV2 } from '@huma-finance/web-shared'
7
+ import { useTrancheVaultContractV2, checkIsDev } from '@huma-finance/web-shared'
9
8
  import { useWeb3React } from '@web3-react/core'
10
9
  import { ethers } from 'ethers'
11
10
  import React, { useCallback } from 'react'
@@ -47,7 +47,7 @@ export interface Campaign {
47
47
  export interface LendSupplyPropsV2 {
48
48
  poolName: keyof typeof POOL_NAME
49
49
  campaign?: Campaign
50
- documentHash: string
50
+ documentHash?: string
51
51
  handleClose: (options?: CloseModalOptions) => void
52
52
  handleSuccess?: (blockNumber?: number) => void
53
53
  }
@@ -29,14 +29,14 @@ export function NotifiContextWrapper({
29
29
 
30
30
  let cardId = ''
31
31
  if (chainId === ChainEnum.Celo || chainId === ChainEnum.Alfajores) {
32
- cardId = process.env.REACT_APP_NOTIFI_CONFIG_ID_CELO ?? ''
32
+ cardId = import.meta.env.VITE_NOTIFI_CONFIG_ID_CELO ?? ''
33
33
  } else if (chainId === ChainEnum.Polygon || chainId === ChainEnum.Amoy) {
34
- cardId = process.env.REACT_APP_NOTIFI_CONFIG_ID_POLYGON ?? ''
34
+ cardId = import.meta.env.VITE_NOTIFI_CONFIG_ID_POLYGON ?? ''
35
35
  } else if (
36
36
  chainId === ChainEnum.Scroll ||
37
37
  chainId === ChainEnum.ScrollSepolia
38
38
  ) {
39
- cardId = process.env.REACT_APP_NOTIFI_CONFIG_ID_SCROLL ?? ''
39
+ cardId = import.meta.env.VITE_NOTIFI_CONFIG_ID_SCROLL ?? ''
40
40
  }
41
41
 
42
42
  if (!cardId) {
@@ -1,25 +1,25 @@
1
1
  import { SvgIconProps } from '@mui/material'
2
- import { ReactComponent as HumaLogoSvg } from './huma.svg'
3
- import { ReactComponent as HumaFullLogoSvg } from './huma-full.svg'
4
- import { ReactComponent as MetamaskSvg } from './metamask.svg'
5
- import { ReactComponent as WalletConnectSvg } from './wallet-connect.svg'
6
- import { ReactComponent as EthereumSvg } from './ethereum.svg'
7
- import { ReactComponent as PolygonSvg } from './polygon.svg'
8
- import { ReactComponent as ReceiptSvg } from './receipt.svg'
9
- import { ReactComponent as SeparatorSvg } from './separator.svg'
10
- import { ReactComponent as LoaderSvg } from './loader.svg'
11
- import { ReactComponent as SorrySvg } from './sorry.svg'
12
- import { ReactComponent as CheckSvg } from './check.svg'
13
- import { ReactComponent as CheckGreenSvg } from './check-green.svg'
14
- import { ReactComponent as CheckCircleSvg } from './check-circle.svg'
15
- import { ReactComponent as AutoPaybackSvg } from './auto-payback.svg'
16
- import { ReactComponent as ApproveLenderSvg } from './approve-lender.svg'
17
- import { ReactComponent as DonutSvg } from './donut.svg'
18
- import { ReactComponent as UsdcSvg } from './usdc.svg'
19
- import { ReactComponent as CeloSvg } from './celo.svg'
20
- import { ReactComponent as CongratulationsSvg } from './congratulations.svg'
21
- import { ReactComponent as RibbonSvg } from './ribbon.svg'
22
- import { ReactComponent as HumaPointsSvg } from './huma-points.svg'
2
+ import HumaLogoSvg from './huma.svg?react'
3
+ import HumaFullLogoSvg from './huma-full.svg?react'
4
+ import MetamaskSvg from './metamask.svg?react'
5
+ import WalletConnectSvg from './wallet-connect.svg?react'
6
+ import EthereumSvg from './ethereum.svg?react'
7
+ import PolygonSvg from './polygon.svg?react'
8
+ import ReceiptSvg from './receipt.svg?react'
9
+ import SeparatorSvg from './separator.svg?react'
10
+ import LoaderSvg from './loader.svg?react'
11
+ import SorrySvg from './sorry.svg?react'
12
+ import CheckSvg from './check.svg?react'
13
+ import CheckGreenSvg from './check-green.svg?react'
14
+ import CheckCircleSvg from './check-circle.svg?react'
15
+ import AutoPaybackSvg from './auto-payback.svg?react'
16
+ import ApproveLenderSvg from './approve-lender.svg?react'
17
+ import DonutSvg from './donut.svg?react'
18
+ import UsdcSvg from './usdc.svg?react'
19
+ import CeloSvg from './celo.svg?react'
20
+ import CongratulationsSvg from './congratulations.svg?react'
21
+ import RibbonSvg from './ribbon.svg?react'
22
+ import HumaPointsSvg from './huma-points.svg?react'
23
23
 
24
24
  export function HumaIcon(props: SvgIconProps): React.ReactElement {
25
25
  return <HumaLogoSvg {...props} />
@@ -64,7 +64,7 @@ function Fixture() {
64
64
  type='link'
65
65
  variant='contained'
66
66
  href={
67
- process.env.REACT_APP_CREATE_INVOICE_URL ??
67
+ import.meta.env.VITE_CREATE_INVOICE_URL ??
68
68
  'https://huma-request-apps-create.netlify.app/'
69
69
  }
70
70
  target='_blank'
@@ -1,11 +1,9 @@
1
+ import { JsonRpcProvider } from '@ethersproject/providers'
1
2
  import { SuperfluidFactoringWidget } from '..'
2
- import { initEnv } from './utils/env'
3
3
  import { WalletWrapper } from './WalletWrapper'
4
4
 
5
- initEnv()
6
-
7
5
  function Fixture() {
8
- return <SuperfluidFactoringWidget />
6
+ return <SuperfluidFactoringWidget provider={new JsonRpcProvider()} />
9
7
  }
10
8
 
11
9
  export default (
@@ -138,11 +138,13 @@ export const getProvider = (chainId = ChainEnum.Goerli) => {
138
138
  const rpcUrlMap: { [x: number]: { name: string; url: string } } = {
139
139
  [ChainEnum.Goerli]: {
140
140
  name: 'Goerli',
141
- url: `https://goerli.infura.io/v3/${process.env.REACT_APP_INFURA_API_KEY}`,
141
+ url: `https://goerli.infura.io/v3/${import.meta.env.VITE_INFURA_API_KEY}`,
142
142
  },
143
143
  [ChainEnum.Mumbai]: {
144
144
  name: 'Mumbai',
145
- url: `https://polygon-mumbai.g.alchemy.com/v2/${process.env.REACT_APP_ALCHEMY_API_KEY}`,
145
+ url: `https://polygon-mumbai.g.alchemy.com/v2/${
146
+ import.meta.env.VITE_ALCHEMY_API_KEY
147
+ }`,
146
148
  },
147
149
  }
148
150
  return new JsonRpcProvider(rpcUrlMap[chainId].url, {
@@ -1,12 +1,11 @@
1
1
  import {
2
- checkIsDev,
3
2
  EAPayload,
4
3
  EARejectionError,
5
4
  EARejectMessage,
6
5
  EARejectReason,
7
6
  EAService,
8
7
  } from '@huma-finance/shared'
9
- import { useAuthErrorHandling } from '@huma-finance/web-shared'
8
+ import { useAuthErrorHandling, checkIsDev } from '@huma-finance/web-shared'
10
9
  import { useWeb3React } from '@web3-react/core'
11
10
  import { useCallback } from 'react'
12
11
 
@@ -1,6 +1,5 @@
1
1
  import { useEffect, useState } from 'react'
2
2
  import {
3
- checkIsDev,
4
3
  doesChainSupportNotifi,
5
4
  getBlockchainConfigFromChain,
6
5
  } from '@huma-finance/shared'
@@ -13,6 +12,7 @@ import {
13
12
  useNotifiFrontendClientContext,
14
13
  useNotifiUserSettingContext,
15
14
  } from '@notifi-network/notifi-react'
15
+ import { checkIsDev } from '@huma-finance/web-shared'
16
16
 
17
17
  export const useDoesChainSupportNotifi = (chainId: number | undefined) => {
18
18
  const [notifiChainSupported, setNotifiChainSupported] = useState(false)
package/src/index.tsx CHANGED
@@ -1,6 +1,5 @@
1
1
  import { JsonRpcProvider } from '@ethersproject/providers'
2
2
  import { ThemeProvider } from '@mui/material'
3
- import { Provider as Eip1193Provider } from '@web3-react/types'
4
3
  import { Provider as AtomProvider } from 'jotai'
5
4
  import { useEffect, useState } from 'react'
6
5
  import { Provider as ReduxProvider } from 'react-redux'
@@ -117,13 +116,13 @@ type JsonRpcConnectionMap = {
117
116
  * @typedef {Object} WidgetProps
118
117
  * @property {desiredChainId|undefined} desiredChainId Optional desired chain id, will trigger the switch network action if different from the current chain id
119
118
  * @property {JsonRpcConnectionMap|undefined} jsonRpcUrlMap Optional mapping of your JSON-RPC connections indexed by chainId
120
- * @property {Eip1193Provider|JsonRpcProvider} provider EIP-1193 provider or JsonRpc Provider
119
+ * @property {JsonRpcProvider} provider EIP-1193 provider or JsonRpc Provider
121
120
  */
122
121
  type WidgetProps = {
123
122
  handleClose?: () => void
124
123
  desiredChainId?: number
125
124
  jsonRpcUrlMap?: JsonRpcConnectionMap
126
- provider: Eip1193Provider | JsonRpcProvider
125
+ provider: JsonRpcProvider
127
126
  }
128
127
 
129
128
  function Widget(props: WCProps<WidgetProps>) {
@@ -132,10 +131,8 @@ function Widget(props: WCProps<WidgetProps>) {
132
131
 
133
132
  useEffect(() => {
134
133
  const getChainId = async () => {
135
- if (provider instanceof JsonRpcProvider) {
136
- const network = await provider.getNetwork()
137
- setChainId(network?.chainId)
138
- }
134
+ const network = await provider.getNetwork()
135
+ setChainId(network?.chainId)
139
136
  }
140
137
  getChainId()
141
138
  }, [provider])
package/tsconfig.json CHANGED
@@ -1,35 +1,38 @@
1
1
  {
2
2
  "compilerOptions": {
3
- "target": "es5",
4
- "lib": ["dom", "dom.iterable", "esnext"],
5
- "allowJs": true,
6
- "skipLibCheck": true,
7
- "esModuleInterop": true,
8
3
  "allowSyntheticDefaultImports": true,
9
- "strict": true,
4
+ "composite": true,
5
+ "declaration": true,
6
+ "declarationDir": "dts",
7
+ "emitDeclarationOnly": true,
8
+ "esModuleInterop": true,
10
9
  "forceConsistentCasingInFileNames": true,
11
- "noFallthroughCasesInSwitch": true,
10
+ "isolatedModules": true,
11
+ "jsx": "react-jsx",
12
+ "jsxImportSource": "@emotion/react",
13
+ "lib": ["dom", "dom.iterable", "esnext"],
12
14
  "module": "esnext",
13
15
  "moduleResolution": "node",
16
+ "noFallthroughCasesInSwitch": true,
14
17
  "resolveJsonModule": true,
15
- "isolatedModules": true,
16
- "jsxImportSource": "@emotion/react",
17
- "jsx": "react-jsx",
18
- "declaration": true,
19
- "declarationDir": "dts",
20
- "emitDeclarationOnly": true,
21
- "composite": true
18
+ "skipLibCheck": true,
19
+ "strict": true,
20
+ "target": "ES2020",
21
+ "paths": {
22
+ "@huma-finance/web-shared": ["../huma-web-shared/src"],
23
+ "@huma-finance/shared": ["../huma-shared/src"]
24
+ }
22
25
  },
23
- "include": ["src/**/*", "src/**/*.json"],
26
+ "include": ["src/**/*", "src/**/*.json", "./*.ts", "./*.d.ts"],
24
27
  "references": [
25
28
  {
26
29
  "path": "../huma-shared"
27
30
  },
28
31
  {
29
- "path": "../huma-web-shared"
32
+ "path": "../huma-sdk"
30
33
  },
31
34
  {
32
- "path": "../huma-sdk"
35
+ "path": "../huma-web-shared"
33
36
  }
34
37
  ]
35
38
  }
package/vite-env.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ /// <reference types="vite/client" />
2
+ /// <reference types="vite-plugin-svgr/client" />