@huma-finance/widgets 0.0.62-beta.624 → 0.0.62-beta.630
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.
- package/API.md +34 -26
- package/dist/cjs/index.cjs +742 -1110
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/index.d.ts +33 -9
- package/dist/index.js +997 -1343
- package/dist/index.js.map +1 -1
- package/package.json +12 -5
- package/src/components/CreditLine/paymentV2/1-ChooseAmount.tsx +1 -0
- package/src/components/CreditLine/solanaBorrow/1-ChooseAmount.tsx +2 -21
- package/src/components/CreditLine/solanaBorrow/2-Transfer.tsx +159 -0
- package/src/components/CreditLine/solanaBorrow/3-Done.tsx +38 -0
- package/src/components/CreditLine/solanaBorrow/index.tsx +19 -25
- package/src/components/CreditLine/solanaPayment/1-ChooseAmount.tsx +75 -0
- package/src/components/CreditLine/solanaPayment/2-Transfer.tsx +92 -0
- package/src/components/CreditLine/solanaPayment/3-Done.tsx +59 -0
- package/src/components/CreditLine/solanaPayment/index.tsx +83 -0
- package/src/components/InputAmountModal.tsx +1 -0
- package/src/components/Lend/addRedemptionV2/2-ChooseAmount.tsx +6 -1
- package/src/components/Lend/solanaCancelRedemption/index.tsx +11 -1
- package/src/components/Lend/solanaSupply/5-Success.tsx +10 -8
- package/src/components/Lend/supplyV2/6-Success.tsx +10 -8
- package/src/components/Lend/supplyV2/7-Notifications.tsx +6 -1
- package/src/components/Notifi/NotifiContextWrapper.tsx +57 -0
- package/src/components/Notifi/NotifiSubscriptionModal.tsx +118 -113
- package/src/components/SuperfluidFactoring/index.tsx +12 -46
- package/src/hooks/useNotifi.ts +28 -17
- package/src/index.tsx +31 -9
- package/src/theme/coreThemeConstants.ts +1 -1
- package/src/components/Activity.tsx +0 -128
- package/src/components/CreditLine/solanaBorrow/2-ApproveAllowance.tsx +0 -89
- package/src/components/Factoring/FactoredList.tsx +0 -143
- package/src/components/Factoring/UpcomingList.tsx +0 -90
- package/src/components/Factoring/index.ts +0 -2
- package/src/components/HumaTable.tsx +0 -203
- package/src/components/SuperfluidFactoring/SuperfluidFactoredList.tsx +0 -69
- package/src/components/SuperfluidFactoring/SuperfluidUpcomingList.tsx +0 -169
package/dist/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ import { Provider } from '@web3-react/types';
|
|
|
4
4
|
import { POOL_NAME, POOL_TYPE, TrancheType, IdentityVerificationStatusV2, SolanaPoolInfo } from '@huma-finance/shared';
|
|
5
5
|
import { BigNumberish, BigNumber } from 'ethers';
|
|
6
6
|
import { SolanaPoolState } from '@huma-finance/web-shared';
|
|
7
|
+
import React from 'react';
|
|
7
8
|
|
|
8
9
|
/**
|
|
9
10
|
* Credit line pool approve allowance props
|
|
@@ -304,6 +305,7 @@ interface SolanaLendAddRedemptionProps {
|
|
|
304
305
|
*/
|
|
305
306
|
interface SolanaLendCancelRedemptionProps {
|
|
306
307
|
poolInfo: SolanaPoolInfo;
|
|
308
|
+
tranche?: TrancheType;
|
|
307
309
|
handleClose: () => void;
|
|
308
310
|
handleSuccess?: () => void;
|
|
309
311
|
}
|
|
@@ -317,10 +319,29 @@ interface SolanaLendCancelRedemptionProps {
|
|
|
317
319
|
*/
|
|
318
320
|
interface SolanaBorrowProps {
|
|
319
321
|
poolInfo: SolanaPoolInfo;
|
|
322
|
+
poolState: SolanaPoolState;
|
|
320
323
|
handleClose: () => void;
|
|
321
324
|
handleSuccess?: () => void;
|
|
322
325
|
}
|
|
323
326
|
|
|
327
|
+
/**
|
|
328
|
+
* Lend pool supply props
|
|
329
|
+
* @typedef {Object} SolanaPaymentProps
|
|
330
|
+
* @property {SolanaPoolInfo} poolInfo The metadata of the pool.
|
|
331
|
+
* @property {function():void|undefined} handleSuccess Optional function to notify that the lending pool supply action is successful.
|
|
332
|
+
*/
|
|
333
|
+
interface SolanaPaymentProps {
|
|
334
|
+
poolInfo: SolanaPoolInfo;
|
|
335
|
+
handleClose: () => void;
|
|
336
|
+
handleSuccess?: () => void;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
type Props = {
|
|
340
|
+
chainId: number | undefined;
|
|
341
|
+
children?: any;
|
|
342
|
+
};
|
|
343
|
+
declare function NotifiContextWrapper({ chainId, children, }: Props): React.ReactElement | null;
|
|
344
|
+
|
|
324
345
|
/**
|
|
325
346
|
* Mapping of your JSON-RPC connections indexed by chainId
|
|
326
347
|
* @typedef {Object} JsonRpcConnectionMap
|
|
@@ -598,8 +619,6 @@ type SolanaWidgetProps = {
|
|
|
598
619
|
/**
|
|
599
620
|
* Lend pool supply widget props for Solana pools
|
|
600
621
|
* @typedef {Object} SolanaLendSupplyWidgetProps
|
|
601
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
602
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
603
622
|
*/
|
|
604
623
|
type SolanaLendSupplyWidgetProps = SolanaLendSupplyProps & SolanaWidgetProps;
|
|
605
624
|
/**
|
|
@@ -611,8 +630,6 @@ declare function SolanaLendSupplyWidget(props: SolanaLendSupplyWidgetProps): _em
|
|
|
611
630
|
/**
|
|
612
631
|
* Lend pool supply widget props for Solana pools
|
|
613
632
|
* @typedef {Object} SolanaLendAddRedemptionWidgetProps
|
|
614
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
615
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
616
633
|
*/
|
|
617
634
|
type SolanaLendAddRedemptionWidgetProps = SolanaLendAddRedemptionProps & SolanaWidgetProps;
|
|
618
635
|
/**
|
|
@@ -624,8 +641,6 @@ declare function SolanaLendAddRedemptionWidget(props: SolanaLendAddRedemptionWid
|
|
|
624
641
|
/**
|
|
625
642
|
* Lend pool supply widget props for Solana pools
|
|
626
643
|
* @typedef {Object} SolanaLendCancelRedemptionWidgetProps
|
|
627
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
628
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
629
644
|
*/
|
|
630
645
|
type SolanaLendCancelRedemptionWidgetProps = SolanaLendCancelRedemptionProps & SolanaWidgetProps;
|
|
631
646
|
/**
|
|
@@ -637,8 +652,6 @@ declare function SolanaLendCancelRedemptionWidget(props: SolanaLendCancelRedempt
|
|
|
637
652
|
/**
|
|
638
653
|
* Lend pool supply widget props for Solana pools
|
|
639
654
|
* @typedef {Object} SolanaBorrowWidgetProps
|
|
640
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
641
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
642
655
|
*/
|
|
643
656
|
type SolanaBorrowWidgetProps = SolanaBorrowProps & SolanaWidgetProps;
|
|
644
657
|
/**
|
|
@@ -647,5 +660,16 @@ type SolanaBorrowWidgetProps = SolanaBorrowProps & SolanaWidgetProps;
|
|
|
647
660
|
* @param {SolanaBorrowWidgetProps} props - Widget props
|
|
648
661
|
*/
|
|
649
662
|
declare function SolanaBorrowWidget(props: SolanaBorrowWidgetProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
663
|
+
/**
|
|
664
|
+
* Lend pool supply widget props for Solana pools
|
|
665
|
+
* @typedef {Object} SolanaPaymentWidgetProps
|
|
666
|
+
*/
|
|
667
|
+
type SolanaPaymentWidgetProps = SolanaPaymentProps & SolanaWidgetProps;
|
|
668
|
+
/**
|
|
669
|
+
* Lend pool supply widget for Solana pools
|
|
670
|
+
*
|
|
671
|
+
* @param {SolanaPaymentWidgetProps} props - Widget props
|
|
672
|
+
*/
|
|
673
|
+
declare function SolanaPaymentWidget(props: SolanaPaymentWidgetProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
650
674
|
|
|
651
|
-
export { AddRedemptionWidgetV2, AutoPaybackWidgetV2, CancelRedemptionWidgetV2, CreditLineApproveWidget, CreditLineBorrowWidget, CreditLineBorrowWidgetV2, CreditLinePaymentWidget, CreditLinePaymentWidgetV2, InvoiceFactoringBorrowWidget, InvoiceFactoringPaymentWidget, LendSupplyWidget, LendSupplyWidgetV2, LendWithdrawWidget, LendWithdrawWidgetV2, ReceivableBackedCreditLineBorrowWidgetV2, ReceivableBackedCreditLinePaymentWidgetV2, SolanaBorrowWidget, SolanaLendAddRedemptionWidget, SolanaLendCancelRedemptionWidget, SolanaLendSupplyWidget, SuperfluidFactoringWidget, SupplyFirstLossCoverWidget };
|
|
675
|
+
export { AddRedemptionWidgetV2, AutoPaybackWidgetV2, CancelRedemptionWidgetV2, CreditLineApproveWidget, CreditLineBorrowWidget, CreditLineBorrowWidgetV2, CreditLinePaymentWidget, CreditLinePaymentWidgetV2, InvoiceFactoringBorrowWidget, InvoiceFactoringPaymentWidget, LendSupplyWidget, LendSupplyWidgetV2, LendWithdrawWidget, LendWithdrawWidgetV2, NotifiContextWrapper, ReceivableBackedCreditLineBorrowWidgetV2, ReceivableBackedCreditLinePaymentWidgetV2, SolanaBorrowWidget, SolanaLendAddRedemptionWidget, SolanaLendCancelRedemptionWidget, SolanaLendSupplyWidget, SolanaPaymentWidget, SuperfluidFactoringWidget, SupplyFirstLossCoverWidget };
|