@bluxcc/react 0.1.5 → 0.1.7
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/dist/assets/Icons.d.ts +1 -0
- package/dist/components/Modal/Backdrop/index.d.ts +2 -1
- package/dist/components/Modal/index.d.ts +2 -1
- package/dist/components/Transaction/History/index.d.ts +8 -6
- package/dist/components/Transaction/Summery/index.d.ts +1 -1
- package/dist/constants/index.d.ts +2 -1
- package/dist/constants/networkDetails.d.ts +8 -0
- package/dist/containers/BluxModal/content.d.ts +4 -2
- package/dist/containers/Pages/WrongNetwork/index.d.ts +3 -0
- package/dist/context/provider.d.ts +2 -2
- package/dist/context/useCheckWalletNetwork.d.ts +3 -0
- package/dist/hooks/useAccount.d.ts +1 -1
- package/dist/hooks/useBlux.d.ts +2 -1
- package/dist/hooks/useCheckProvider.d.ts +2 -0
- package/dist/hooks/useCustomNetwork.d.ts +7 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/networks.d.ts +1 -1
- package/dist/types/index.d.ts +20 -8
- package/dist/useStellar/index.d.ts +6 -2
- package/dist/useStellar/useAccount.d.ts +12 -0
- package/dist/useStellar/useBalance.d.ts +11 -6
- package/dist/useStellar/useNetwork.d.ts +2 -0
- package/dist/useStellar/useSwitchNetwork.d.ts +5 -0
- package/dist/useStellar/useTransactions.d.ts +18 -0
- package/dist/utils/formatDate.d.ts +2 -0
- package/dist/utils/getWalletNetwork.d.ts +1 -1
- package/dist/utils/network/getNetworkRpc.d.ts +4 -0
- package/dist/utils/stellar/getTransactionDetails.d.ts +2 -2
- package/dist/utils/stellar/signTransaction.d.ts +1 -1
- package/dist/utils/stellar/submitTransaction.d.ts +2 -1
- package/dist/utils/toTitleFormat.d.ts +2 -0
- package/package.json +3 -1
package/dist/assets/Icons.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
interface BackdropProps {
|
|
3
3
|
isClosing: boolean;
|
|
4
|
+
isSticky?: boolean;
|
|
4
5
|
onClose: () => void;
|
|
5
6
|
}
|
|
6
|
-
declare const ModalBackdrop: ({ isClosing, onClose }: BackdropProps) => React.JSX.Element;
|
|
7
|
+
declare const ModalBackdrop: ({ isClosing, onClose, isSticky, }: BackdropProps) => React.JSX.Element;
|
|
7
8
|
export default ModalBackdrop;
|
|
@@ -8,6 +8,7 @@ interface ModalProps {
|
|
|
8
8
|
onInfo?: () => void;
|
|
9
9
|
closeButton?: boolean;
|
|
10
10
|
title: string;
|
|
11
|
+
isSticky?: boolean;
|
|
11
12
|
}
|
|
12
|
-
declare const Modal: ({ isOpen, onClose, onBack, onInfo, children, title, icon, closeButton, }: ModalProps) => React.JSX.Element | null;
|
|
13
|
+
declare const Modal: ({ isOpen, onClose, onBack, onInfo, children, title, icon, isSticky, closeButton, }: ModalProps) => React.JSX.Element | null;
|
|
13
14
|
export default Modal;
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
amount: string;
|
|
4
|
-
date: string;
|
|
5
|
-
status: 'success' | 'failed' | string;
|
|
6
|
-
action: string;
|
|
2
|
+
export type TxDetail = {
|
|
7
3
|
hash: string;
|
|
4
|
+
date: string;
|
|
5
|
+
title: string;
|
|
6
|
+
description: string;
|
|
7
|
+
};
|
|
8
|
+
interface TransactionProps {
|
|
9
|
+
tx: TxDetail;
|
|
8
10
|
}
|
|
9
|
-
declare const _default: React.MemoExoticComponent<({
|
|
11
|
+
declare const _default: React.MemoExoticComponent<({ tx }: TransactionProps) => React.JSX.Element>;
|
|
10
12
|
export default _default;
|
|
@@ -5,5 +5,5 @@ interface SummaryProps {
|
|
|
5
5
|
estimatedFee: string;
|
|
6
6
|
action: string;
|
|
7
7
|
}
|
|
8
|
-
declare const Summary: ({ operationsCount, sender, estimatedFee, action }: SummaryProps) => React.JSX.Element;
|
|
8
|
+
declare const Summary: ({ operationsCount, sender, estimatedFee, action, }: SummaryProps) => React.JSX.Element;
|
|
9
9
|
export default Summary;
|
|
@@ -4,8 +4,10 @@ interface ModalContentProps {
|
|
|
4
4
|
showAllWallets: boolean;
|
|
5
5
|
setShowAllWallets: (show: boolean) => void;
|
|
6
6
|
}
|
|
7
|
-
|
|
7
|
+
type RouteContent = {
|
|
8
8
|
title: string;
|
|
9
|
+
isSticky?: boolean;
|
|
9
10
|
Component: React.FC<ModalContentProps>;
|
|
10
|
-
}
|
|
11
|
+
};
|
|
12
|
+
export declare const modalContent: Record<Routes, RouteContent>;
|
|
11
13
|
export {};
|
|
@@ -4,8 +4,8 @@ export declare const ProviderContext: React.Context<ContextState | null>;
|
|
|
4
4
|
type BluxProviderProps = {
|
|
5
5
|
isDemo?: boolean;
|
|
6
6
|
config: IProviderConfig;
|
|
7
|
-
children: React.ReactNode;
|
|
7
|
+
children: React.ReactNode | any;
|
|
8
8
|
};
|
|
9
|
-
export declare const BluxProvider: ({ config, isDemo, children }: BluxProviderProps) => React.JSX.Element;
|
|
9
|
+
export declare const BluxProvider: ({ config, isDemo, children, }: BluxProviderProps) => React.JSX.Element;
|
|
10
10
|
export declare const useProvider: () => ContextState;
|
|
11
11
|
export {};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ContextInterface, Routes } from "../types";
|
|
2
|
+
declare const useCheckWalletNetwork: (value: ContextInterface, setValue: React.Dispatch<React.SetStateAction<ContextInterface>>, setRoute: React.Dispatch<React.SetStateAction<Routes>>) => void;
|
|
3
|
+
export default useCheckWalletNetwork;
|
|
@@ -8,5 +8,5 @@ interface AccountHookProps {
|
|
|
8
8
|
publicKey: string;
|
|
9
9
|
passphrase: string;
|
|
10
10
|
}
|
|
11
|
-
declare const useAccount: ({ publicKey, passphrase }: AccountHookProps) => AccountHookResult;
|
|
11
|
+
declare const useAccount: ({ publicKey, passphrase, }: AccountHookProps) => AccountHookResult;
|
|
12
12
|
export default useAccount;
|
package/dist/hooks/useBlux.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { ISendTransactionOptions } from '../types';
|
|
1
2
|
export declare const useBlux: () => {
|
|
2
3
|
login: () => void;
|
|
3
4
|
logout: () => void;
|
|
4
5
|
profile: () => void;
|
|
5
|
-
sendTransaction: (xdr: string) => Promise<unknown>;
|
|
6
|
+
sendTransaction: (xdr: string, options?: ISendTransactionOptions) => Promise<unknown>;
|
|
6
7
|
user: import("../types").IUser;
|
|
7
8
|
isReady: boolean;
|
|
8
9
|
isAuthenticated: boolean;
|