@huma-finance/widgets 0.0.62-beta.622 → 0.0.62-beta.627
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 +430 -155
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/index.d.ts +25 -9
- package/dist/index.js +433 -159
- package/dist/index.js.map +1 -1
- package/package.json +5 -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/index.tsx +23 -8
- package/src/components/CreditLine/solanaBorrow/2-ApproveAllowance.tsx +0 -89
package/dist/index.d.ts
CHANGED
|
@@ -316,6 +316,19 @@ interface SolanaLendCancelRedemptionProps {
|
|
|
316
316
|
* @property {function():void|undefined} handleSuccess Optional function to notify that the lending pool supply action is successful.
|
|
317
317
|
*/
|
|
318
318
|
interface SolanaBorrowProps {
|
|
319
|
+
poolInfo: SolanaPoolInfo;
|
|
320
|
+
poolState: SolanaPoolState;
|
|
321
|
+
handleClose: () => void;
|
|
322
|
+
handleSuccess?: () => void;
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
/**
|
|
326
|
+
* Lend pool supply props
|
|
327
|
+
* @typedef {Object} SolanaPaymentProps
|
|
328
|
+
* @property {SolanaPoolInfo} poolInfo The metadata of the pool.
|
|
329
|
+
* @property {function():void|undefined} handleSuccess Optional function to notify that the lending pool supply action is successful.
|
|
330
|
+
*/
|
|
331
|
+
interface SolanaPaymentProps {
|
|
319
332
|
poolInfo: SolanaPoolInfo;
|
|
320
333
|
handleClose: () => void;
|
|
321
334
|
handleSuccess?: () => void;
|
|
@@ -598,8 +611,6 @@ type SolanaWidgetProps = {
|
|
|
598
611
|
/**
|
|
599
612
|
* Lend pool supply widget props for Solana pools
|
|
600
613
|
* @typedef {Object} SolanaLendSupplyWidgetProps
|
|
601
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
602
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
603
614
|
*/
|
|
604
615
|
type SolanaLendSupplyWidgetProps = SolanaLendSupplyProps & SolanaWidgetProps;
|
|
605
616
|
/**
|
|
@@ -611,8 +622,6 @@ declare function SolanaLendSupplyWidget(props: SolanaLendSupplyWidgetProps): _em
|
|
|
611
622
|
/**
|
|
612
623
|
* Lend pool supply widget props for Solana pools
|
|
613
624
|
* @typedef {Object} SolanaLendAddRedemptionWidgetProps
|
|
614
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
615
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
616
625
|
*/
|
|
617
626
|
type SolanaLendAddRedemptionWidgetProps = SolanaLendAddRedemptionProps & SolanaWidgetProps;
|
|
618
627
|
/**
|
|
@@ -624,8 +633,6 @@ declare function SolanaLendAddRedemptionWidget(props: SolanaLendAddRedemptionWid
|
|
|
624
633
|
/**
|
|
625
634
|
* Lend pool supply widget props for Solana pools
|
|
626
635
|
* @typedef {Object} SolanaLendCancelRedemptionWidgetProps
|
|
627
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
628
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
629
636
|
*/
|
|
630
637
|
type SolanaLendCancelRedemptionWidgetProps = SolanaLendCancelRedemptionProps & SolanaWidgetProps;
|
|
631
638
|
/**
|
|
@@ -637,8 +644,6 @@ declare function SolanaLendCancelRedemptionWidget(props: SolanaLendCancelRedempt
|
|
|
637
644
|
/**
|
|
638
645
|
* Lend pool supply widget props for Solana pools
|
|
639
646
|
* @typedef {Object} SolanaBorrowWidgetProps
|
|
640
|
-
* @property {SolanaLendSupplyProps} SolanaLendSupplyProps - Specific widget props
|
|
641
|
-
* @property {SolanaWidgetProps} SolanaWidgetProps - Widget general props.
|
|
642
647
|
*/
|
|
643
648
|
type SolanaBorrowWidgetProps = SolanaBorrowProps & SolanaWidgetProps;
|
|
644
649
|
/**
|
|
@@ -647,5 +652,16 @@ type SolanaBorrowWidgetProps = SolanaBorrowProps & SolanaWidgetProps;
|
|
|
647
652
|
* @param {SolanaBorrowWidgetProps} props - Widget props
|
|
648
653
|
*/
|
|
649
654
|
declare function SolanaBorrowWidget(props: SolanaBorrowWidgetProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
655
|
+
/**
|
|
656
|
+
* Lend pool supply widget props for Solana pools
|
|
657
|
+
* @typedef {Object} SolanaPaymentWidgetProps
|
|
658
|
+
*/
|
|
659
|
+
type SolanaPaymentWidgetProps = SolanaPaymentProps & SolanaWidgetProps;
|
|
660
|
+
/**
|
|
661
|
+
* Lend pool supply widget for Solana pools
|
|
662
|
+
*
|
|
663
|
+
* @param {SolanaPaymentWidgetProps} props - Widget props
|
|
664
|
+
*/
|
|
665
|
+
declare function SolanaPaymentWidget(props: SolanaPaymentWidgetProps): _emotion_react_jsx_runtime.JSX.Element;
|
|
650
666
|
|
|
651
|
-
export { AddRedemptionWidgetV2, AutoPaybackWidgetV2, CancelRedemptionWidgetV2, CreditLineApproveWidget, CreditLineBorrowWidget, CreditLineBorrowWidgetV2, CreditLinePaymentWidget, CreditLinePaymentWidgetV2, InvoiceFactoringBorrowWidget, InvoiceFactoringPaymentWidget, LendSupplyWidget, LendSupplyWidgetV2, LendWithdrawWidget, LendWithdrawWidgetV2, ReceivableBackedCreditLineBorrowWidgetV2, ReceivableBackedCreditLinePaymentWidgetV2, SolanaBorrowWidget, SolanaLendAddRedemptionWidget, SolanaLendCancelRedemptionWidget, SolanaLendSupplyWidget, SuperfluidFactoringWidget, SupplyFirstLossCoverWidget };
|
|
667
|
+
export { AddRedemptionWidgetV2, AutoPaybackWidgetV2, CancelRedemptionWidgetV2, CreditLineApproveWidget, CreditLineBorrowWidget, CreditLineBorrowWidgetV2, CreditLinePaymentWidget, CreditLinePaymentWidgetV2, InvoiceFactoringBorrowWidget, InvoiceFactoringPaymentWidget, LendSupplyWidget, LendSupplyWidgetV2, LendWithdrawWidget, LendWithdrawWidgetV2, ReceivableBackedCreditLineBorrowWidgetV2, ReceivableBackedCreditLinePaymentWidgetV2, SolanaBorrowWidget, SolanaLendAddRedemptionWidget, SolanaLendCancelRedemptionWidget, SolanaLendSupplyWidget, SolanaPaymentWidget, SuperfluidFactoringWidget, SupplyFirstLossCoverWidget };
|