@ton/appkit-react 0.0.1 → 0.0.2
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/esm/components/block/block.js +7 -0
- package/dist/esm/components/block/block.js.map +1 -0
- package/dist/{components → esm/components}/block/block.module.css +1 -1
- package/dist/esm/components/block/block.stories.js +27 -0
- package/dist/esm/components/block/block.stories.js.map +1 -0
- package/dist/esm/components/block/index.js +9 -0
- package/dist/esm/components/block/index.js.map +1 -0
- package/dist/esm/components/button/button.js +7 -0
- package/dist/esm/components/button/button.js.map +1 -0
- package/dist/{components → esm/components}/button/button.module.css +7 -2
- package/dist/esm/components/button/button.stories.js +30 -0
- package/dist/esm/components/button/button.stories.js.map +1 -0
- package/dist/esm/components/button/index.js +9 -0
- package/dist/esm/components/button/index.js.map +1 -0
- package/dist/esm/components/circle-icon/circle-icon.js +8 -0
- package/dist/esm/components/circle-icon/circle-icon.js.map +1 -0
- package/dist/esm/components/circle-icon/circle-icon.module.css +32 -0
- package/dist/esm/components/circle-icon/circle-icon.stories.js +56 -0
- package/dist/esm/components/circle-icon/circle-icon.stories.js.map +1 -0
- package/dist/esm/components/circle-icon/index.js +9 -0
- package/dist/esm/components/circle-icon/index.js.map +1 -0
- package/dist/esm/components/ton-icon/index.js +9 -0
- package/dist/esm/components/ton-icon/index.js.map +1 -0
- package/dist/esm/components/ton-icon/ton-icon.js +8 -0
- package/dist/esm/components/ton-icon/ton-icon.js.map +1 -0
- package/dist/esm/components/ton-icon/ton-icon.stories.js +56 -0
- package/dist/esm/components/ton-icon/ton-icon.stories.js.map +1 -0
- package/dist/esm/features/balances/components/balance-badge/balance-badge.js +33 -0
- package/dist/esm/features/balances/components/balance-badge/balance-badge.js.map +1 -0
- package/dist/{features → esm/features}/balances/components/balance-badge/balance-badge.module.css +3 -1
- package/dist/esm/features/balances/components/balance-badge/balance-badge.stories.js +23 -0
- package/dist/esm/features/balances/components/balance-badge/balance-badge.stories.js.map +1 -0
- package/dist/esm/features/balances/components/balance-badge/index.js +9 -0
- package/dist/esm/features/balances/components/balance-badge/index.js.map +1 -0
- package/dist/esm/features/balances/components/currency-item/currency-item.js +8 -0
- package/dist/esm/features/balances/components/currency-item/currency-item.js.map +1 -0
- package/dist/esm/features/balances/components/currency-item/currency-item.module.css +80 -0
- package/dist/esm/features/balances/components/currency-item/currency-item.stories.js +61 -0
- package/dist/esm/features/balances/components/currency-item/currency-item.stories.js.map +1 -0
- package/dist/esm/features/balances/components/currency-item/index.js +9 -0
- package/dist/esm/features/balances/components/currency-item/index.js.map +1 -0
- package/dist/esm/features/balances/components/send-jetton-button/index.js +9 -0
- package/dist/esm/features/balances/components/send-jetton-button/index.js.map +1 -0
- package/dist/esm/features/balances/components/send-jetton-button/send-jetton-button.js +43 -0
- package/dist/esm/features/balances/components/send-jetton-button/send-jetton-button.js.map +1 -0
- package/dist/esm/features/balances/components/send-jetton-button/send-jetton-button.stories.js +41 -0
- package/dist/esm/features/balances/components/send-jetton-button/send-jetton-button.stories.js.map +1 -0
- package/dist/esm/features/balances/components/send-ton-button/index.js +9 -0
- package/dist/esm/features/balances/components/send-ton-button/index.js.map +1 -0
- package/dist/esm/features/balances/components/send-ton-button/send-ton-button.js +26 -0
- package/dist/esm/features/balances/components/send-ton-button/send-ton-button.js.map +1 -0
- package/dist/esm/features/balances/components/send-ton-button/send-ton-button.stories.js +36 -0
- package/dist/esm/features/balances/components/send-ton-button/send-ton-button.stories.js.map +1 -0
- package/dist/esm/features/balances/hooks/use-balance-by-address.js +18 -0
- package/dist/esm/features/balances/hooks/use-balance-by-address.js.map +1 -0
- package/dist/esm/features/balances/hooks/use-balance.js +17 -0
- package/dist/esm/features/balances/hooks/use-balance.js.map +1 -0
- package/dist/esm/features/balances/index.js +14 -0
- package/dist/esm/features/balances/index.js.map +1 -0
- package/dist/esm/features/jettons/hooks/use-jetton-balance-by-address.js +18 -0
- package/dist/esm/features/jettons/hooks/use-jetton-balance-by-address.js.map +1 -0
- package/dist/esm/features/jettons/hooks/use-jetton-info.js +18 -0
- package/dist/esm/features/jettons/hooks/use-jetton-info.js.map +1 -0
- package/dist/esm/features/jettons/hooks/use-jetton-wallet-address.js +18 -0
- package/dist/esm/features/jettons/hooks/use-jetton-wallet-address.js.map +1 -0
- package/dist/esm/features/jettons/hooks/use-jettons-by-address.js +18 -0
- package/dist/esm/features/jettons/hooks/use-jettons-by-address.js.map +1 -0
- package/dist/esm/features/jettons/hooks/use-jettons.js +17 -0
- package/dist/esm/features/jettons/hooks/use-jettons.js.map +1 -0
- package/dist/esm/features/jettons/hooks/use-transfer-jetton.js +16 -0
- package/dist/esm/features/jettons/hooks/use-transfer-jetton.js.map +1 -0
- package/dist/esm/features/jettons/index.js +14 -0
- package/dist/esm/features/jettons/index.js.map +1 -0
- package/dist/esm/features/network/hooks/use-network.js +17 -0
- package/dist/esm/features/network/hooks/use-network.js.map +1 -0
- package/dist/esm/features/network/hooks/use-networks.js +24 -0
- package/dist/esm/features/network/hooks/use-networks.js.map +1 -0
- package/dist/esm/features/network/index.js +11 -0
- package/dist/esm/features/network/index.js.map +1 -0
- package/dist/esm/features/nft/components/nft-item/index.js +9 -0
- package/dist/esm/features/nft/components/nft-item/index.js.map +1 -0
- package/dist/esm/features/nft/components/nft-item/nft-item.js +15 -0
- package/dist/esm/features/nft/components/nft-item/nft-item.js.map +1 -0
- package/dist/esm/features/nft/components/nft-item/nft-item.module.css +74 -0
- package/dist/esm/features/nft/components/nft-item/nft-item.stories.js +52 -0
- package/dist/esm/features/nft/components/nft-item/nft-item.stories.js.map +1 -0
- package/dist/esm/features/nft/hooks/use-nft.js +18 -0
- package/dist/esm/features/nft/hooks/use-nft.js.map +1 -0
- package/dist/esm/features/nft/hooks/use-nfts-by-address.js +18 -0
- package/dist/esm/features/nft/hooks/use-nfts-by-address.js.map +1 -0
- package/dist/esm/features/nft/hooks/use-nfts.js +17 -0
- package/dist/esm/features/nft/hooks/use-nfts.js.map +1 -0
- package/dist/esm/features/nft/hooks/use-transfer-nft.js +16 -0
- package/dist/esm/features/nft/hooks/use-transfer-nft.js.map +1 -0
- package/dist/esm/features/nft/index.js +13 -0
- package/dist/esm/features/nft/index.js.map +1 -0
- package/dist/esm/features/signing/hooks/use-sign-binary.js +27 -0
- package/dist/esm/features/signing/hooks/use-sign-binary.js.map +1 -0
- package/dist/esm/features/signing/hooks/use-sign-cell.js +28 -0
- package/dist/esm/features/signing/hooks/use-sign-cell.js.map +1 -0
- package/dist/esm/features/signing/hooks/use-sign-text.js +27 -0
- package/dist/esm/features/signing/hooks/use-sign-text.js.map +1 -0
- package/dist/esm/features/signing/index.js +11 -0
- package/dist/esm/features/signing/index.js.map +1 -0
- package/dist/esm/features/swap/hooks/use-build-swap-transaction.js +16 -0
- package/dist/esm/features/swap/hooks/use-build-swap-transaction.js.map +1 -0
- package/dist/esm/features/swap/hooks/use-swap-quote.js +16 -0
- package/dist/esm/features/swap/hooks/use-swap-quote.js.map +1 -0
- package/dist/esm/features/swap/index.js +10 -0
- package/dist/esm/features/swap/index.js.map +1 -0
- package/dist/esm/features/transaction/components/transaction/index.js +9 -0
- package/dist/esm/features/transaction/components/transaction/index.js.map +1 -0
- package/dist/esm/features/transaction/components/transaction/transaction.js +41 -0
- package/dist/esm/features/transaction/components/transaction/transaction.js.map +1 -0
- package/dist/esm/features/transaction/components/transaction/transaction.stories.js +47 -0
- package/dist/esm/features/transaction/components/transaction/transaction.stories.js.map +1 -0
- package/dist/esm/features/transaction/components/transaction-provider/index.js +9 -0
- package/dist/esm/features/transaction/components/transaction-provider/index.js.map +1 -0
- package/dist/esm/features/transaction/components/transaction-provider/transaction-provider.js +64 -0
- package/dist/esm/features/transaction/components/transaction-provider/transaction-provider.js.map +1 -0
- package/dist/esm/features/transaction/hooks/use-send-transaction.js +16 -0
- package/dist/esm/features/transaction/hooks/use-send-transaction.js.map +1 -0
- package/dist/esm/features/transaction/hooks/use-transfer-ton.js +16 -0
- package/dist/esm/features/transaction/hooks/use-transfer-ton.js.map +1 -0
- package/dist/esm/features/transaction/index.js +11 -0
- package/dist/esm/features/transaction/index.js.map +1 -0
- package/dist/esm/features/wallets/components/connect-button/index.js +9 -0
- package/dist/esm/features/wallets/components/connect-button/index.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-address.js +17 -0
- package/dist/esm/features/wallets/hooks/use-address.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-connect.js +15 -0
- package/dist/esm/features/wallets/hooks/use-connect.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-connected-wallets.js +21 -0
- package/dist/esm/features/wallets/hooks/use-connected-wallets.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-connector-by-id.js +21 -0
- package/dist/esm/features/wallets/hooks/use-connector-by-id.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-connectors.js +21 -0
- package/dist/esm/features/wallets/hooks/use-connectors.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-disconnect.js +16 -0
- package/dist/esm/features/wallets/hooks/use-disconnect.js.map +1 -0
- package/dist/esm/features/wallets/hooks/use-selected-wallet.js +28 -0
- package/dist/esm/features/wallets/hooks/use-selected-wallet.js.map +1 -0
- package/dist/esm/features/wallets/index.js +16 -0
- package/dist/esm/features/wallets/index.js.map +1 -0
- package/dist/esm/hooks/use-app-kit-theme.js +17 -0
- package/dist/esm/hooks/use-app-kit-theme.js.map +1 -0
- package/dist/esm/hooks/use-app-kit.js +17 -0
- package/dist/esm/hooks/use-app-kit.js.map +1 -0
- package/dist/esm/hooks/use-i18n.js +17 -0
- package/dist/esm/hooks/use-i18n.js.map +1 -0
- package/dist/esm/index.js +26 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/libs/i18n.js +14 -0
- package/dist/esm/libs/i18n.js.map +1 -0
- package/dist/esm/libs/query.js +18 -0
- package/dist/esm/libs/query.js.map +1 -0
- package/dist/esm/locales/en.js +32 -0
- package/dist/esm/locales/en.js.map +1 -0
- package/dist/esm/providers/app-kit-provider.js +9 -0
- package/dist/esm/providers/app-kit-provider.js.map +1 -0
- package/dist/esm/providers/i18n-provider.js +51 -0
- package/dist/esm/providers/i18n-provider.js.map +1 -0
- package/dist/{styles → esm/styles}/index.css +26 -11
- package/dist/{styles → esm/styles}/typography.module.css +14 -1
- package/dist/esm/tonconnect/tonconnect-bridge.js +27 -0
- package/dist/esm/tonconnect/tonconnect-bridge.js.map +1 -0
- package/dist/esm/tsconfig.build.tsbuildinfo +1 -0
- package/dist/types/components/block/block.d.ts.map +1 -0
- package/dist/types/components/block/block.stories.d.ts.map +1 -0
- package/dist/types/components/block/index.d.ts.map +1 -0
- package/dist/types/components/button/button.d.ts.map +1 -0
- package/dist/types/components/button/button.stories.d.ts.map +1 -0
- package/dist/types/components/button/index.d.ts.map +1 -0
- package/dist/types/components/circle-icon/circle-icon.d.ts.map +1 -0
- package/dist/types/components/circle-icon/circle-icon.stories.d.ts.map +1 -0
- package/dist/types/components/circle-icon/index.d.ts.map +1 -0
- package/dist/types/components/ton-icon/index.d.ts.map +1 -0
- package/dist/types/components/ton-icon/ton-icon.d.ts.map +1 -0
- package/dist/types/components/ton-icon/ton-icon.stories.d.ts.map +1 -0
- package/dist/types/features/balances/components/balance-badge/balance-badge.d.ts.map +1 -0
- package/dist/types/features/balances/components/balance-badge/balance-badge.stories.d.ts.map +1 -0
- package/dist/types/features/balances/components/balance-badge/index.d.ts.map +1 -0
- package/dist/types/features/balances/components/currency-item/currency-item.d.ts.map +1 -0
- package/dist/types/features/balances/components/currency-item/currency-item.stories.d.ts.map +1 -0
- package/dist/types/features/balances/components/currency-item/index.d.ts.map +1 -0
- package/dist/types/features/balances/components/send-jetton-button/index.d.ts.map +1 -0
- package/dist/types/features/balances/components/send-jetton-button/send-jetton-button.d.ts.map +1 -0
- package/dist/types/features/balances/components/send-jetton-button/send-jetton-button.stories.d.ts.map +1 -0
- package/dist/types/features/balances/components/send-ton-button/index.d.ts.map +1 -0
- package/dist/types/features/balances/components/send-ton-button/send-ton-button.d.ts.map +1 -0
- package/dist/types/features/balances/components/send-ton-button/send-ton-button.stories.d.ts.map +1 -0
- package/dist/types/features/balances/hooks/use-balance-by-address.d.ts.map +1 -0
- package/dist/types/features/balances/hooks/use-balance.d.ts.map +1 -0
- package/dist/types/features/balances/index.d.ts.map +1 -0
- package/dist/types/features/jettons/hooks/use-jetton-balance-by-address.d.ts.map +1 -0
- package/dist/types/features/jettons/hooks/use-jetton-info.d.ts.map +1 -0
- package/dist/types/features/jettons/hooks/use-jetton-wallet-address.d.ts.map +1 -0
- package/dist/types/features/jettons/hooks/use-jettons-by-address.d.ts.map +1 -0
- package/dist/types/features/jettons/hooks/use-jettons.d.ts.map +1 -0
- package/dist/types/features/jettons/hooks/use-transfer-jetton.d.ts.map +1 -0
- package/dist/types/features/jettons/index.d.ts.map +1 -0
- package/dist/types/features/network/hooks/use-network.d.ts.map +1 -0
- package/dist/types/features/network/hooks/use-networks.d.ts.map +1 -0
- package/dist/types/features/network/index.d.ts.map +1 -0
- package/dist/types/features/nft/components/nft-item/index.d.ts.map +1 -0
- package/dist/types/features/nft/components/nft-item/nft-item.d.ts.map +1 -0
- package/dist/types/features/nft/components/nft-item/nft-item.stories.d.ts.map +1 -0
- package/dist/types/features/nft/hooks/use-nft.d.ts.map +1 -0
- package/dist/types/features/nft/hooks/use-nfts-by-address.d.ts.map +1 -0
- package/dist/types/features/nft/hooks/use-nfts.d.ts.map +1 -0
- package/dist/types/features/nft/hooks/use-transfer-nft.d.ts.map +1 -0
- package/dist/types/features/nft/index.d.ts.map +1 -0
- package/dist/types/features/signing/hooks/use-sign-binary.d.ts.map +1 -0
- package/dist/types/features/signing/hooks/use-sign-cell.d.ts.map +1 -0
- package/dist/types/features/signing/hooks/use-sign-text.d.ts.map +1 -0
- package/dist/types/features/signing/index.d.ts.map +1 -0
- package/dist/types/features/swap/hooks/use-build-swap-transaction.d.ts.map +1 -0
- package/dist/types/features/swap/hooks/use-swap-quote.d.ts.map +1 -0
- package/dist/types/features/swap/index.d.ts.map +1 -0
- package/dist/types/features/transaction/components/transaction/index.d.ts.map +1 -0
- package/dist/types/features/transaction/components/transaction/transaction.d.ts.map +1 -0
- package/dist/types/features/transaction/components/transaction/transaction.stories.d.ts.map +1 -0
- package/dist/types/features/transaction/components/transaction-provider/index.d.ts.map +1 -0
- package/dist/types/features/transaction/components/transaction-provider/transaction-provider.d.ts.map +1 -0
- package/dist/types/features/transaction/hooks/use-send-transaction.d.ts.map +1 -0
- package/dist/types/features/transaction/hooks/use-transfer-ton.d.ts.map +1 -0
- package/dist/types/features/transaction/index.d.ts.map +1 -0
- package/dist/types/features/wallets/components/connect-button/index.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-address.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-connect.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-connected-wallets.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-connector-by-id.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-connectors.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-disconnect.d.ts.map +1 -0
- package/dist/types/features/wallets/hooks/use-selected-wallet.d.ts.map +1 -0
- package/dist/types/features/wallets/index.d.ts.map +1 -0
- package/dist/types/hooks/use-app-kit-theme.d.ts.map +1 -0
- package/dist/types/hooks/use-app-kit.d.ts.map +1 -0
- package/dist/types/hooks/use-i18n.d.ts.map +1 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/libs/i18n.d.ts.map +1 -0
- package/dist/types/libs/query.d.ts.map +1 -0
- package/dist/types/locales/en.d.ts.map +1 -0
- package/dist/types/providers/app-kit-provider.d.ts.map +1 -0
- package/dist/types/providers/i18n-provider.d.ts.map +1 -0
- package/dist/types/tonconnect/tonconnect-bridge.d.ts.map +1 -0
- package/package.json +18 -11
- package/src/components/block/block.tsx +20 -0
- package/src/components/block/index.ts +9 -0
- package/src/components/button/button.tsx +16 -0
- package/src/components/button/index.ts +9 -0
- package/src/components/circle-icon/circle-icon.tsx +34 -0
- package/src/components/circle-icon/index.ts +9 -0
- package/src/components/ton-icon/index.ts +9 -0
- package/src/components/ton-icon/ton-icon.tsx +46 -0
- package/src/features/balances/components/balance-badge/balance-badge.tsx +47 -0
- package/src/features/balances/components/balance-badge/index.ts +9 -0
- package/src/features/balances/components/currency-item/currency-item.tsx +59 -0
- package/src/features/balances/components/currency-item/index.ts +9 -0
- package/src/features/balances/components/send-jetton-button/index.ts +9 -0
- package/src/features/balances/components/send-jetton-button/send-jetton-button.tsx +76 -0
- package/src/features/balances/components/send-ton-button/index.ts +9 -0
- package/src/features/balances/components/send-ton-button/send-ton-button.tsx +44 -0
- package/src/features/balances/hooks/use-balance-by-address.ts +33 -0
- package/src/features/balances/hooks/use-balance.ts +28 -0
- package/{dist/features/balances/index.mjs → src/features/balances/index.ts} +9 -2
- package/src/features/jettons/hooks/use-jetton-balance-by-address.ts +37 -0
- package/src/features/jettons/hooks/use-jetton-info.ts +32 -0
- package/src/features/jettons/hooks/use-jetton-wallet-address.ts +37 -0
- package/src/features/jettons/hooks/use-jettons-by-address.ts +33 -0
- package/src/features/jettons/hooks/use-jettons.ts +28 -0
- package/src/features/jettons/hooks/use-transfer-jetton.ts +44 -0
- package/{dist/features/jettons/index.mjs → src/features/jettons/index.ts} +8 -2
- package/src/features/network/hooks/use-network.ts +23 -0
- package/src/features/network/hooks/use-networks.ts +35 -0
- package/src/features/network/index.ts +11 -0
- package/src/features/nft/components/nft-item/index.ts +9 -0
- package/src/features/nft/components/nft-item/nft-item.tsx +57 -0
- package/src/features/nft/hooks/use-nft.ts +29 -0
- package/src/features/nft/hooks/use-nfts-by-address.ts +29 -0
- package/src/features/nft/hooks/use-nfts.ts +28 -0
- package/src/features/nft/hooks/use-transfer-nft.ts +44 -0
- package/{dist/features/nft/index.mjs → src/features/nft/index.ts} +9 -2
- package/src/features/signing/hooks/use-sign-binary.ts +43 -0
- package/src/features/signing/hooks/use-sign-cell.ts +44 -0
- package/src/features/signing/hooks/use-sign-text.ts +43 -0
- package/src/features/signing/index.ts +11 -0
- package/src/features/swap/hooks/use-build-swap-transaction.ts +38 -0
- package/src/features/swap/hooks/use-swap-quote.ts +31 -0
- package/src/features/swap/index.ts +10 -0
- package/src/features/transaction/components/transaction/index.ts +10 -0
- package/src/features/transaction/components/transaction/transaction.tsx +105 -0
- package/src/features/transaction/components/transaction-provider/index.ts +10 -0
- package/src/features/transaction/components/transaction-provider/transaction-provider.tsx +114 -0
- package/src/features/transaction/hooks/use-send-transaction.ts +44 -0
- package/src/features/transaction/hooks/use-transfer-ton.ts +44 -0
- package/src/features/transaction/index.ts +12 -0
- package/src/features/wallets/components/connect-button/index.ts +9 -0
- package/src/features/wallets/hooks/use-address.ts +22 -0
- package/src/features/wallets/hooks/use-connect.ts +37 -0
- package/src/features/wallets/hooks/use-connected-wallets.ts +32 -0
- package/src/features/wallets/hooks/use-connector-by-id.ts +30 -0
- package/src/features/wallets/hooks/use-connectors.ts +32 -0
- package/src/features/wallets/hooks/use-disconnect.ts +39 -0
- package/src/features/wallets/hooks/use-selected-wallet.ts +44 -0
- package/{dist/features/wallets/index.mjs → src/features/wallets/index.ts} +10 -2
- package/src/global.d.ts +12 -0
- package/src/hooks/use-app-kit-theme.ts +22 -0
- package/src/hooks/use-app-kit.ts +21 -0
- package/src/hooks/use-i18n.ts +21 -0
- package/{dist/index.mjs → src/index.ts} +11 -2
- package/src/libs/i18n.ts +20 -0
- package/src/libs/query.ts +69 -0
- package/src/locales/en.ts +35 -0
- package/src/providers/app-kit-provider.tsx +30 -0
- package/src/providers/i18n-provider.tsx +83 -0
- package/src/tonconnect/tonconnect-bridge.tsx +39 -0
- package/dist/components/block/block.d.ts.map +0 -1
- package/dist/components/block/block.js +0 -18
- package/dist/components/block/block.js.map +0 -1
- package/dist/components/block/block.mjs +0 -11
- package/dist/components/block/block.mjs.map +0 -1
- package/dist/components/block/block.module.css.map +0 -1
- package/dist/components/block/block.stories.d.ts.map +0 -1
- package/dist/components/block/block.stories.js +0 -45
- package/dist/components/block/block.stories.js.map +0 -1
- package/dist/components/block/block.stories.mjs +0 -39
- package/dist/components/block/block.stories.mjs.map +0 -1
- package/dist/components/block/index.d.ts.map +0 -1
- package/dist/components/block/index.js +0 -14
- package/dist/components/block/index.js.map +0 -1
- package/dist/components/block/index.mjs +0 -3
- package/dist/components/block/index.mjs.map +0 -1
- package/dist/components/button/button.d.ts.map +0 -1
- package/dist/components/button/button.js +0 -18
- package/dist/components/button/button.js.map +0 -1
- package/dist/components/button/button.mjs +0 -11
- package/dist/components/button/button.mjs.map +0 -1
- package/dist/components/button/button.module.css.map +0 -1
- package/dist/components/button/button.stories.d.ts.map +0 -1
- package/dist/components/button/button.stories.js +0 -53
- package/dist/components/button/button.stories.js.map +0 -1
- package/dist/components/button/button.stories.mjs +0 -46
- package/dist/components/button/button.stories.mjs.map +0 -1
- package/dist/components/button/index.d.ts.map +0 -1
- package/dist/components/button/index.js +0 -12
- package/dist/components/button/index.js.map +0 -1
- package/dist/components/button/index.mjs +0 -3
- package/dist/components/button/index.mjs.map +0 -1
- package/dist/components/circle-icon/circle-icon.d.ts.map +0 -1
- package/dist/components/circle-icon/circle-icon.js +0 -22
- package/dist/components/circle-icon/circle-icon.js.map +0 -1
- package/dist/components/circle-icon/circle-icon.mjs +0 -15
- package/dist/components/circle-icon/circle-icon.mjs.map +0 -1
- package/dist/components/circle-icon/circle-icon.module.css +0 -31
- package/dist/components/circle-icon/circle-icon.module.css.map +0 -1
- package/dist/components/circle-icon/circle-icon.stories.d.ts.map +0 -1
- package/dist/components/circle-icon/circle-icon.stories.js +0 -62
- package/dist/components/circle-icon/circle-icon.stories.js.map +0 -1
- package/dist/components/circle-icon/circle-icon.stories.mjs +0 -53
- package/dist/components/circle-icon/circle-icon.stories.mjs.map +0 -1
- package/dist/components/circle-icon/index.d.ts.map +0 -1
- package/dist/components/circle-icon/index.js +0 -14
- package/dist/components/circle-icon/index.js.map +0 -1
- package/dist/components/circle-icon/index.mjs +0 -3
- package/dist/components/circle-icon/index.mjs.map +0 -1
- package/dist/components/ton-icon/index.d.ts.map +0 -1
- package/dist/components/ton-icon/index.js +0 -16
- package/dist/components/ton-icon/index.js.map +0 -1
- package/dist/components/ton-icon/index.mjs +0 -3
- package/dist/components/ton-icon/index.mjs.map +0 -1
- package/dist/components/ton-icon/ton-icon.d.ts.map +0 -1
- package/dist/components/ton-icon/ton-icon.js +0 -39
- package/dist/components/ton-icon/ton-icon.js.map +0 -1
- package/dist/components/ton-icon/ton-icon.mjs +0 -36
- package/dist/components/ton-icon/ton-icon.mjs.map +0 -1
- package/dist/components/ton-icon/ton-icon.stories.d.ts.map +0 -1
- package/dist/components/ton-icon/ton-icon.stories.js +0 -71
- package/dist/components/ton-icon/ton-icon.stories.js.map +0 -1
- package/dist/components/ton-icon/ton-icon.stories.mjs +0 -60
- package/dist/components/ton-icon/ton-icon.stories.mjs.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.d.ts.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.js +0 -41
- package/dist/features/balances/components/balance-badge/balance-badge.js.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.mjs +0 -34
- package/dist/features/balances/components/balance-badge/balance-badge.mjs.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.module.css.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.stories.d.ts.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.stories.js +0 -59
- package/dist/features/balances/components/balance-badge/balance-badge.stories.js.map +0 -1
- package/dist/features/balances/components/balance-badge/balance-badge.stories.mjs +0 -51
- package/dist/features/balances/components/balance-badge/balance-badge.stories.mjs.map +0 -1
- package/dist/features/balances/components/balance-badge/index.d.ts.map +0 -1
- package/dist/features/balances/components/balance-badge/index.js +0 -12
- package/dist/features/balances/components/balance-badge/index.js.map +0 -1
- package/dist/features/balances/components/balance-badge/index.mjs +0 -3
- package/dist/features/balances/components/balance-badge/index.mjs.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.d.ts.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.js +0 -44
- package/dist/features/balances/components/currency-item/currency-item.js.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.mjs +0 -37
- package/dist/features/balances/components/currency-item/currency-item.mjs.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.module.css +0 -69
- package/dist/features/balances/components/currency-item/currency-item.module.css.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.stories.d.ts.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.stories.js +0 -89
- package/dist/features/balances/components/currency-item/currency-item.stories.js.map +0 -1
- package/dist/features/balances/components/currency-item/currency-item.stories.mjs +0 -79
- package/dist/features/balances/components/currency-item/currency-item.stories.mjs.map +0 -1
- package/dist/features/balances/components/currency-item/index.d.ts.map +0 -1
- package/dist/features/balances/components/currency-item/index.js +0 -14
- package/dist/features/balances/components/currency-item/index.js.map +0 -1
- package/dist/features/balances/components/currency-item/index.mjs +0 -3
- package/dist/features/balances/components/currency-item/index.mjs.map +0 -1
- package/dist/features/balances/components/send-jetton-button/index.d.ts.map +0 -1
- package/dist/features/balances/components/send-jetton-button/index.js +0 -14
- package/dist/features/balances/components/send-jetton-button/index.js.map +0 -1
- package/dist/features/balances/components/send-jetton-button/index.mjs +0 -3
- package/dist/features/balances/components/send-jetton-button/index.mjs.map +0 -1
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.d.ts.map +0 -1
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.js +0 -56
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.js.map +0 -1
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.mjs +0 -54
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.mjs.map +0 -1
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.stories.d.ts.map +0 -1
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.stories.js +0 -58
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.stories.js.map +0 -1
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.stories.mjs +0 -49
- package/dist/features/balances/components/send-jetton-button/send-jetton-button.stories.mjs.map +0 -1
- package/dist/features/balances/components/send-ton-button/index.d.ts.map +0 -1
- package/dist/features/balances/components/send-ton-button/index.js +0 -14
- package/dist/features/balances/components/send-ton-button/index.js.map +0 -1
- package/dist/features/balances/components/send-ton-button/index.mjs +0 -3
- package/dist/features/balances/components/send-ton-button/index.mjs.map +0 -1
- package/dist/features/balances/components/send-ton-button/send-ton-button.d.ts.map +0 -1
- package/dist/features/balances/components/send-ton-button/send-ton-button.js +0 -33
- package/dist/features/balances/components/send-ton-button/send-ton-button.js.map +0 -1
- package/dist/features/balances/components/send-ton-button/send-ton-button.mjs +0 -31
- package/dist/features/balances/components/send-ton-button/send-ton-button.mjs.map +0 -1
- package/dist/features/balances/components/send-ton-button/send-ton-button.stories.d.ts.map +0 -1
- package/dist/features/balances/components/send-ton-button/send-ton-button.stories.js +0 -52
- package/dist/features/balances/components/send-ton-button/send-ton-button.stories.js.map +0 -1
- package/dist/features/balances/components/send-ton-button/send-ton-button.stories.mjs +0 -44
- package/dist/features/balances/components/send-ton-button/send-ton-button.stories.mjs.map +0 -1
- package/dist/features/balances/hooks/use-balance-by-address.d.ts.map +0 -1
- package/dist/features/balances/hooks/use-balance-by-address.js +0 -14
- package/dist/features/balances/hooks/use-balance-by-address.js.map +0 -1
- package/dist/features/balances/hooks/use-balance-by-address.mjs +0 -12
- package/dist/features/balances/hooks/use-balance-by-address.mjs.map +0 -1
- package/dist/features/balances/hooks/use-balance.d.ts.map +0 -1
- package/dist/features/balances/hooks/use-balance.js +0 -13
- package/dist/features/balances/hooks/use-balance.js.map +0 -1
- package/dist/features/balances/hooks/use-balance.mjs +0 -11
- package/dist/features/balances/hooks/use-balance.mjs.map +0 -1
- package/dist/features/balances/index.d.ts.map +0 -1
- package/dist/features/balances/index.js +0 -49
- package/dist/features/balances/index.js.map +0 -1
- package/dist/features/balances/index.mjs.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-balance-by-address.d.ts.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-balance-by-address.js +0 -14
- package/dist/features/jettons/hooks/use-jetton-balance-by-address.js.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-balance-by-address.mjs +0 -12
- package/dist/features/jettons/hooks/use-jetton-balance-by-address.mjs.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-info.d.ts.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-info.js +0 -14
- package/dist/features/jettons/hooks/use-jetton-info.js.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-info.mjs +0 -12
- package/dist/features/jettons/hooks/use-jetton-info.mjs.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-wallet-address.d.ts.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-wallet-address.js +0 -14
- package/dist/features/jettons/hooks/use-jetton-wallet-address.js.map +0 -1
- package/dist/features/jettons/hooks/use-jetton-wallet-address.mjs +0 -12
- package/dist/features/jettons/hooks/use-jetton-wallet-address.mjs.map +0 -1
- package/dist/features/jettons/hooks/use-jettons-by-address.d.ts.map +0 -1
- package/dist/features/jettons/hooks/use-jettons-by-address.js +0 -14
- package/dist/features/jettons/hooks/use-jettons-by-address.js.map +0 -1
- package/dist/features/jettons/hooks/use-jettons-by-address.mjs +0 -12
- package/dist/features/jettons/hooks/use-jettons-by-address.mjs.map +0 -1
- package/dist/features/jettons/hooks/use-jettons.d.ts.map +0 -1
- package/dist/features/jettons/hooks/use-jettons.js +0 -13
- package/dist/features/jettons/hooks/use-jettons.js.map +0 -1
- package/dist/features/jettons/hooks/use-jettons.mjs +0 -11
- package/dist/features/jettons/hooks/use-jettons.mjs.map +0 -1
- package/dist/features/jettons/hooks/use-transfer-jetton.d.ts.map +0 -1
- package/dist/features/jettons/hooks/use-transfer-jetton.js +0 -14
- package/dist/features/jettons/hooks/use-transfer-jetton.js.map +0 -1
- package/dist/features/jettons/hooks/use-transfer-jetton.mjs +0 -12
- package/dist/features/jettons/hooks/use-transfer-jetton.mjs.map +0 -1
- package/dist/features/jettons/index.d.ts.map +0 -1
- package/dist/features/jettons/index.js +0 -49
- package/dist/features/jettons/index.js.map +0 -1
- package/dist/features/jettons/index.mjs.map +0 -1
- package/dist/features/network/hooks/use-network.d.ts.map +0 -1
- package/dist/features/network/hooks/use-network.js +0 -13
- package/dist/features/network/hooks/use-network.js.map +0 -1
- package/dist/features/network/hooks/use-network.mjs +0 -11
- package/dist/features/network/hooks/use-network.mjs.map +0 -1
- package/dist/features/network/hooks/use-networks.d.ts.map +0 -1
- package/dist/features/network/hooks/use-networks.js +0 -23
- package/dist/features/network/hooks/use-networks.js.map +0 -1
- package/dist/features/network/hooks/use-networks.mjs +0 -21
- package/dist/features/network/hooks/use-networks.mjs.map +0 -1
- package/dist/features/network/index.d.ts.map +0 -1
- package/dist/features/network/index.js +0 -17
- package/dist/features/network/index.js.map +0 -1
- package/dist/features/network/index.mjs +0 -4
- package/dist/features/network/index.mjs.map +0 -1
- package/dist/features/nft/components/nft-item/index.d.ts.map +0 -1
- package/dist/features/nft/components/nft-item/index.js +0 -14
- package/dist/features/nft/components/nft-item/index.js.map +0 -1
- package/dist/features/nft/components/nft-item/index.mjs +0 -3
- package/dist/features/nft/components/nft-item/index.mjs.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.d.ts.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.js +0 -43
- package/dist/features/nft/components/nft-item/nft-item.js.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.mjs +0 -36
- package/dist/features/nft/components/nft-item/nft-item.mjs.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.module.css +0 -65
- package/dist/features/nft/components/nft-item/nft-item.module.css.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.stories.d.ts.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.stories.js +0 -124
- package/dist/features/nft/components/nft-item/nft-item.stories.js.map +0 -1
- package/dist/features/nft/components/nft-item/nft-item.stories.mjs +0 -110
- package/dist/features/nft/components/nft-item/nft-item.stories.mjs.map +0 -1
- package/dist/features/nft/hooks/use-nft.d.ts.map +0 -1
- package/dist/features/nft/hooks/use-nft.js +0 -14
- package/dist/features/nft/hooks/use-nft.js.map +0 -1
- package/dist/features/nft/hooks/use-nft.mjs +0 -12
- package/dist/features/nft/hooks/use-nft.mjs.map +0 -1
- package/dist/features/nft/hooks/use-nfts-by-address.d.ts.map +0 -1
- package/dist/features/nft/hooks/use-nfts-by-address.js +0 -14
- package/dist/features/nft/hooks/use-nfts-by-address.js.map +0 -1
- package/dist/features/nft/hooks/use-nfts-by-address.mjs +0 -12
- package/dist/features/nft/hooks/use-nfts-by-address.mjs.map +0 -1
- package/dist/features/nft/hooks/use-nfts.d.ts.map +0 -1
- package/dist/features/nft/hooks/use-nfts.js +0 -13
- package/dist/features/nft/hooks/use-nfts.js.map +0 -1
- package/dist/features/nft/hooks/use-nfts.mjs +0 -11
- package/dist/features/nft/hooks/use-nfts.mjs.map +0 -1
- package/dist/features/nft/hooks/use-transfer-nft.d.ts.map +0 -1
- package/dist/features/nft/hooks/use-transfer-nft.js +0 -14
- package/dist/features/nft/hooks/use-transfer-nft.js.map +0 -1
- package/dist/features/nft/hooks/use-transfer-nft.mjs +0 -12
- package/dist/features/nft/hooks/use-transfer-nft.mjs.map +0 -1
- package/dist/features/nft/index.d.ts.map +0 -1
- package/dist/features/nft/index.js +0 -42
- package/dist/features/nft/index.js.map +0 -1
- package/dist/features/nft/index.mjs.map +0 -1
- package/dist/features/signing/hooks/use-sign-binary.d.ts.map +0 -1
- package/dist/features/signing/hooks/use-sign-binary.js +0 -14
- package/dist/features/signing/hooks/use-sign-binary.js.map +0 -1
- package/dist/features/signing/hooks/use-sign-binary.mjs +0 -12
- package/dist/features/signing/hooks/use-sign-binary.mjs.map +0 -1
- package/dist/features/signing/hooks/use-sign-cell.d.ts.map +0 -1
- package/dist/features/signing/hooks/use-sign-cell.js +0 -14
- package/dist/features/signing/hooks/use-sign-cell.js.map +0 -1
- package/dist/features/signing/hooks/use-sign-cell.mjs +0 -12
- package/dist/features/signing/hooks/use-sign-cell.mjs.map +0 -1
- package/dist/features/signing/hooks/use-sign-text.d.ts.map +0 -1
- package/dist/features/signing/hooks/use-sign-text.js +0 -14
- package/dist/features/signing/hooks/use-sign-text.js.map +0 -1
- package/dist/features/signing/hooks/use-sign-text.mjs +0 -12
- package/dist/features/signing/hooks/use-sign-text.mjs.map +0 -1
- package/dist/features/signing/index.d.ts.map +0 -1
- package/dist/features/signing/index.js +0 -28
- package/dist/features/signing/index.js.map +0 -1
- package/dist/features/signing/index.mjs +0 -5
- package/dist/features/signing/index.mjs.map +0 -1
- package/dist/features/swap/hooks/use-build-swap-transaction.d.ts.map +0 -1
- package/dist/features/swap/hooks/use-build-swap-transaction.js +0 -14
- package/dist/features/swap/hooks/use-build-swap-transaction.js.map +0 -1
- package/dist/features/swap/hooks/use-build-swap-transaction.mjs +0 -12
- package/dist/features/swap/hooks/use-build-swap-transaction.mjs.map +0 -1
- package/dist/features/swap/hooks/use-swap-quote.d.ts.map +0 -1
- package/dist/features/swap/hooks/use-swap-quote.js +0 -14
- package/dist/features/swap/hooks/use-swap-quote.js.map +0 -1
- package/dist/features/swap/hooks/use-swap-quote.mjs +0 -12
- package/dist/features/swap/hooks/use-swap-quote.mjs.map +0 -1
- package/dist/features/swap/index.d.ts.map +0 -1
- package/dist/features/swap/index.js +0 -21
- package/dist/features/swap/index.js.map +0 -1
- package/dist/features/swap/index.mjs +0 -4
- package/dist/features/swap/index.mjs.map +0 -1
- package/dist/features/transaction/components/transaction/index.d.ts.map +0 -1
- package/dist/features/transaction/components/transaction/index.js +0 -12
- package/dist/features/transaction/components/transaction/index.js.map +0 -1
- package/dist/features/transaction/components/transaction/index.mjs +0 -3
- package/dist/features/transaction/components/transaction/index.mjs.map +0 -1
- package/dist/features/transaction/components/transaction/transaction.d.ts.map +0 -1
- package/dist/features/transaction/components/transaction/transaction.js +0 -49
- package/dist/features/transaction/components/transaction/transaction.js.map +0 -1
- package/dist/features/transaction/components/transaction/transaction.mjs +0 -47
- package/dist/features/transaction/components/transaction/transaction.mjs.map +0 -1
- package/dist/features/transaction/components/transaction/transaction.stories.d.ts.map +0 -1
- package/dist/features/transaction/components/transaction/transaction.stories.js +0 -64
- package/dist/features/transaction/components/transaction/transaction.stories.js.map +0 -1
- package/dist/features/transaction/components/transaction/transaction.stories.mjs +0 -54
- package/dist/features/transaction/components/transaction/transaction.stories.mjs.map +0 -1
- package/dist/features/transaction/components/transaction-provider/index.d.ts.map +0 -1
- package/dist/features/transaction/components/transaction-provider/index.js +0 -20
- package/dist/features/transaction/components/transaction-provider/index.js.map +0 -1
- package/dist/features/transaction/components/transaction-provider/index.mjs +0 -3
- package/dist/features/transaction/components/transaction-provider/index.mjs.map +0 -1
- package/dist/features/transaction/components/transaction-provider/transaction-provider.d.ts.map +0 -1
- package/dist/features/transaction/components/transaction-provider/transaction-provider.js +0 -76
- package/dist/features/transaction/components/transaction-provider/transaction-provider.js.map +0 -1
- package/dist/features/transaction/components/transaction-provider/transaction-provider.mjs +0 -72
- package/dist/features/transaction/components/transaction-provider/transaction-provider.mjs.map +0 -1
- package/dist/features/transaction/hooks/use-send-transaction.d.ts.map +0 -1
- package/dist/features/transaction/hooks/use-send-transaction.js +0 -14
- package/dist/features/transaction/hooks/use-send-transaction.js.map +0 -1
- package/dist/features/transaction/hooks/use-send-transaction.mjs +0 -12
- package/dist/features/transaction/hooks/use-send-transaction.mjs.map +0 -1
- package/dist/features/transaction/hooks/use-transfer-ton.d.ts.map +0 -1
- package/dist/features/transaction/hooks/use-transfer-ton.js +0 -14
- package/dist/features/transaction/hooks/use-transfer-ton.js.map +0 -1
- package/dist/features/transaction/hooks/use-transfer-ton.mjs +0 -12
- package/dist/features/transaction/hooks/use-transfer-ton.mjs.map +0 -1
- package/dist/features/transaction/index.d.ts.map +0 -1
- package/dist/features/transaction/index.js +0 -28
- package/dist/features/transaction/index.js.map +0 -1
- package/dist/features/transaction/index.mjs +0 -5
- package/dist/features/transaction/index.mjs.map +0 -1
- package/dist/features/wallets/components/connect-button/index.d.ts.map +0 -1
- package/dist/features/wallets/components/connect-button/index.js +0 -12
- package/dist/features/wallets/components/connect-button/index.js.map +0 -1
- package/dist/features/wallets/components/connect-button/index.mjs +0 -3
- package/dist/features/wallets/components/connect-button/index.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-address.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-address.js +0 -13
- package/dist/features/wallets/hooks/use-address.js.map +0 -1
- package/dist/features/wallets/hooks/use-address.mjs +0 -11
- package/dist/features/wallets/hooks/use-address.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-connect.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-connect.js +0 -14
- package/dist/features/wallets/hooks/use-connect.js.map +0 -1
- package/dist/features/wallets/hooks/use-connect.mjs +0 -12
- package/dist/features/wallets/hooks/use-connect.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-connected-wallets.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-connected-wallets.js +0 -23
- package/dist/features/wallets/hooks/use-connected-wallets.js.map +0 -1
- package/dist/features/wallets/hooks/use-connected-wallets.mjs +0 -21
- package/dist/features/wallets/hooks/use-connected-wallets.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-connector-by-id.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-connector-by-id.js +0 -23
- package/dist/features/wallets/hooks/use-connector-by-id.js.map +0 -1
- package/dist/features/wallets/hooks/use-connector-by-id.mjs +0 -21
- package/dist/features/wallets/hooks/use-connector-by-id.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-connectors.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-connectors.js +0 -23
- package/dist/features/wallets/hooks/use-connectors.js.map +0 -1
- package/dist/features/wallets/hooks/use-connectors.mjs +0 -21
- package/dist/features/wallets/hooks/use-connectors.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-disconnect.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-disconnect.js +0 -14
- package/dist/features/wallets/hooks/use-disconnect.js.map +0 -1
- package/dist/features/wallets/hooks/use-disconnect.mjs +0 -12
- package/dist/features/wallets/hooks/use-disconnect.mjs.map +0 -1
- package/dist/features/wallets/hooks/use-selected-wallet.d.ts.map +0 -1
- package/dist/features/wallets/hooks/use-selected-wallet.js +0 -30
- package/dist/features/wallets/hooks/use-selected-wallet.js.map +0 -1
- package/dist/features/wallets/hooks/use-selected-wallet.mjs +0 -28
- package/dist/features/wallets/hooks/use-selected-wallet.mjs.map +0 -1
- package/dist/features/wallets/index.d.ts.map +0 -1
- package/dist/features/wallets/index.js +0 -63
- package/dist/features/wallets/index.js.map +0 -1
- package/dist/features/wallets/index.mjs.map +0 -1
- package/dist/global.d.js +0 -4
- package/dist/global.d.js.map +0 -1
- package/dist/global.d.mjs +0 -3
- package/dist/global.d.mjs.map +0 -1
- package/dist/hooks/use-app-kit-theme.d.ts.map +0 -1
- package/dist/hooks/use-app-kit-theme.js +0 -16
- package/dist/hooks/use-app-kit-theme.js.map +0 -1
- package/dist/hooks/use-app-kit-theme.mjs +0 -14
- package/dist/hooks/use-app-kit-theme.mjs.map +0 -1
- package/dist/hooks/use-app-kit.d.ts.map +0 -1
- package/dist/hooks/use-app-kit.js +0 -16
- package/dist/hooks/use-app-kit.js.map +0 -1
- package/dist/hooks/use-app-kit.mjs +0 -14
- package/dist/hooks/use-app-kit.mjs.map +0 -1
- package/dist/hooks/use-i18n.d.ts.map +0 -1
- package/dist/hooks/use-i18n.js +0 -16
- package/dist/hooks/use-i18n.js.map +0 -1
- package/dist/hooks/use-i18n.mjs +0 -14
- package/dist/hooks/use-i18n.mjs.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -123
- package/dist/index.js.map +0 -1
- package/dist/index.mjs.map +0 -1
- package/dist/libs/i18n.d.ts.map +0 -1
- package/dist/libs/i18n.js +0 -22
- package/dist/libs/i18n.js.map +0 -1
- package/dist/libs/i18n.mjs +0 -11
- package/dist/libs/i18n.mjs.map +0 -1
- package/dist/libs/query.d.ts.map +0 -1
- package/dist/libs/query.js +0 -20
- package/dist/libs/query.js.map +0 -1
- package/dist/libs/query.mjs +0 -15
- package/dist/libs/query.mjs.map +0 -1
- package/dist/locales/en.d.ts.map +0 -1
- package/dist/locales/en.js +0 -30
- package/dist/locales/en.js.map +0 -1
- package/dist/locales/en.mjs +0 -28
- package/dist/locales/en.mjs.map +0 -1
- package/dist/providers/app-kit-provider.d.ts.map +0 -1
- package/dist/providers/app-kit-provider.js +0 -16
- package/dist/providers/app-kit-provider.js.map +0 -1
- package/dist/providers/app-kit-provider.mjs +0 -13
- package/dist/providers/app-kit-provider.mjs.map +0 -1
- package/dist/providers/i18n-provider.d.ts.map +0 -1
- package/dist/providers/i18n-provider.js +0 -55
- package/dist/providers/i18n-provider.js.map +0 -1
- package/dist/providers/i18n-provider.mjs +0 -52
- package/dist/providers/i18n-provider.mjs.map +0 -1
- package/dist/styles/index.css.map +0 -1
- package/dist/styles/typography.module.css.map +0 -1
- package/dist/tonconnect/tonconnect-bridge.d.ts.map +0 -1
- package/dist/tonconnect/tonconnect-bridge.js +0 -23
- package/dist/tonconnect/tonconnect-bridge.js.map +0 -1
- package/dist/tonconnect/tonconnect-bridge.mjs +0 -21
- package/dist/tonconnect/tonconnect-bridge.mjs.map +0 -1
- /package/dist/{components → types/components}/block/block.d.ts +0 -0
- /package/dist/{components → types/components}/block/block.stories.d.ts +0 -0
- /package/dist/{components → types/components}/block/index.d.ts +0 -0
- /package/dist/{components → types/components}/button/button.d.ts +0 -0
- /package/dist/{components → types/components}/button/button.stories.d.ts +0 -0
- /package/dist/{components → types/components}/button/index.d.ts +0 -0
- /package/dist/{components → types/components}/circle-icon/circle-icon.d.ts +0 -0
- /package/dist/{components → types/components}/circle-icon/circle-icon.stories.d.ts +0 -0
- /package/dist/{components → types/components}/circle-icon/index.d.ts +0 -0
- /package/dist/{components → types/components}/ton-icon/index.d.ts +0 -0
- /package/dist/{components → types/components}/ton-icon/ton-icon.d.ts +0 -0
- /package/dist/{components → types/components}/ton-icon/ton-icon.stories.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/balance-badge/balance-badge.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/balance-badge/balance-badge.stories.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/balance-badge/index.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/currency-item/currency-item.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/currency-item/currency-item.stories.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/currency-item/index.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/send-jetton-button/index.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/send-jetton-button/send-jetton-button.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/send-jetton-button/send-jetton-button.stories.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/send-ton-button/index.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/send-ton-button/send-ton-button.d.ts +0 -0
- /package/dist/{features → types/features}/balances/components/send-ton-button/send-ton-button.stories.d.ts +0 -0
- /package/dist/{features → types/features}/balances/hooks/use-balance-by-address.d.ts +0 -0
- /package/dist/{features → types/features}/balances/hooks/use-balance.d.ts +0 -0
- /package/dist/{features → types/features}/balances/index.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/hooks/use-jetton-balance-by-address.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/hooks/use-jetton-info.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/hooks/use-jetton-wallet-address.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/hooks/use-jettons-by-address.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/hooks/use-jettons.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/hooks/use-transfer-jetton.d.ts +0 -0
- /package/dist/{features → types/features}/jettons/index.d.ts +0 -0
- /package/dist/{features → types/features}/network/hooks/use-network.d.ts +0 -0
- /package/dist/{features → types/features}/network/hooks/use-networks.d.ts +0 -0
- /package/dist/{features → types/features}/network/index.d.ts +0 -0
- /package/dist/{features → types/features}/nft/components/nft-item/index.d.ts +0 -0
- /package/dist/{features → types/features}/nft/components/nft-item/nft-item.d.ts +0 -0
- /package/dist/{features → types/features}/nft/components/nft-item/nft-item.stories.d.ts +0 -0
- /package/dist/{features → types/features}/nft/hooks/use-nft.d.ts +0 -0
- /package/dist/{features → types/features}/nft/hooks/use-nfts-by-address.d.ts +0 -0
- /package/dist/{features → types/features}/nft/hooks/use-nfts.d.ts +0 -0
- /package/dist/{features → types/features}/nft/hooks/use-transfer-nft.d.ts +0 -0
- /package/dist/{features → types/features}/nft/index.d.ts +0 -0
- /package/dist/{features → types/features}/signing/hooks/use-sign-binary.d.ts +0 -0
- /package/dist/{features → types/features}/signing/hooks/use-sign-cell.d.ts +0 -0
- /package/dist/{features → types/features}/signing/hooks/use-sign-text.d.ts +0 -0
- /package/dist/{features → types/features}/signing/index.d.ts +0 -0
- /package/dist/{features → types/features}/swap/hooks/use-build-swap-transaction.d.ts +0 -0
- /package/dist/{features → types/features}/swap/hooks/use-swap-quote.d.ts +0 -0
- /package/dist/{features → types/features}/swap/index.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/components/transaction/index.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/components/transaction/transaction.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/components/transaction/transaction.stories.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/components/transaction-provider/index.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/components/transaction-provider/transaction-provider.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/hooks/use-send-transaction.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/hooks/use-transfer-ton.d.ts +0 -0
- /package/dist/{features → types/features}/transaction/index.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/components/connect-button/index.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-address.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-connect.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-connected-wallets.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-connector-by-id.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-connectors.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-disconnect.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/hooks/use-selected-wallet.d.ts +0 -0
- /package/dist/{features → types/features}/wallets/index.d.ts +0 -0
- /package/dist/{hooks → types/hooks}/use-app-kit-theme.d.ts +0 -0
- /package/dist/{hooks → types/hooks}/use-app-kit.d.ts +0 -0
- /package/dist/{hooks → types/hooks}/use-i18n.d.ts +0 -0
- /package/dist/{index.d.ts → types/index.d.ts} +0 -0
- /package/dist/{libs → types/libs}/i18n.d.ts +0 -0
- /package/dist/{libs → types/libs}/query.d.ts +0 -0
- /package/dist/{locales → types/locales}/en.d.ts +0 -0
- /package/dist/{providers → types/providers}/app-kit-provider.d.ts +0 -0
- /package/dist/{providers → types/providers}/i18n-provider.d.ts +0 -0
- /package/dist/{tonconnect → types/tonconnect}/tonconnect-bridge.d.ts +0 -0
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import type { NFT } from '@ton/appkit';
|
|
10
|
+
import { useMemo, useState } from 'react';
|
|
11
|
+
import type { FC, ComponentProps } from 'react';
|
|
12
|
+
import { getFormattedNftInfo } from '@ton/appkit';
|
|
13
|
+
import clsx from 'clsx';
|
|
14
|
+
|
|
15
|
+
import { useI18n } from '../../../../hooks/use-i18n';
|
|
16
|
+
import styles from './nft-item.module.css';
|
|
17
|
+
|
|
18
|
+
const PlaceholderIcon: FC = () => (
|
|
19
|
+
<svg className={styles.placeholderIcon} fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
20
|
+
<path
|
|
21
|
+
strokeLinecap="round"
|
|
22
|
+
strokeLinejoin="round"
|
|
23
|
+
strokeWidth={2}
|
|
24
|
+
d="M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"
|
|
25
|
+
/>
|
|
26
|
+
</svg>
|
|
27
|
+
);
|
|
28
|
+
|
|
29
|
+
export interface NftItemProps extends ComponentProps<'button'> {
|
|
30
|
+
nft: NFT;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export const NftItem: FC<NftItemProps> = ({ nft, className, ...props }) => {
|
|
34
|
+
const { t } = useI18n();
|
|
35
|
+
const { name, collectionName, image, isOnSale } = useMemo(() => getFormattedNftInfo(nft), [nft]);
|
|
36
|
+
const [imageError, setImageError] = useState(false);
|
|
37
|
+
|
|
38
|
+
const showImage = image && !imageError;
|
|
39
|
+
|
|
40
|
+
return (
|
|
41
|
+
<button className={clsx(styles.nftItem, className)} {...props}>
|
|
42
|
+
<div className={styles.imageWrapper}>
|
|
43
|
+
{showImage ? (
|
|
44
|
+
<img src={image} alt={name} className={styles.image} onError={() => setImageError(true)} />
|
|
45
|
+
) : (
|
|
46
|
+
<PlaceholderIcon />
|
|
47
|
+
)}
|
|
48
|
+
{isOnSale && <span className={styles.saleBadge}>{t('nft.onSale')}</span>}
|
|
49
|
+
</div>
|
|
50
|
+
|
|
51
|
+
<div className={styles.info}>
|
|
52
|
+
<h4 className={styles.name}>{name}</h4>
|
|
53
|
+
<p className={styles.collectionName}>{collectionName}</p>
|
|
54
|
+
</div>
|
|
55
|
+
</button>
|
|
56
|
+
);
|
|
57
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { getNftQueryOptions } from '@ton/appkit/queries';
|
|
10
|
+
import type { GetNftData, GetNftErrorType, GetNftQueryConfig } from '@ton/appkit/queries';
|
|
11
|
+
|
|
12
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
13
|
+
import { useQuery } from '../../../libs/query';
|
|
14
|
+
import type { UseQueryReturnType } from '../../../libs/query';
|
|
15
|
+
|
|
16
|
+
export type UseNftParameters<selectData = GetNftData> = GetNftQueryConfig<selectData>;
|
|
17
|
+
|
|
18
|
+
export type UseNftReturnType<selectData = GetNftData> = UseQueryReturnType<selectData, GetNftErrorType>;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Hook to get a single NFT
|
|
22
|
+
*/
|
|
23
|
+
export const useNft = <selectData = GetNftData>(
|
|
24
|
+
parameters: UseNftParameters<selectData> = {},
|
|
25
|
+
): UseNftReturnType<selectData> => {
|
|
26
|
+
const appKit = useAppKit();
|
|
27
|
+
|
|
28
|
+
return useQuery(getNftQueryOptions(appKit, parameters));
|
|
29
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { getNFTsQueryOptions } from '@ton/appkit/queries';
|
|
10
|
+
import type { GetNFTsData, GetNFTsErrorType, GetNFTsQueryConfig } from '@ton/appkit/queries';
|
|
11
|
+
|
|
12
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
13
|
+
import { useQuery } from '../../../libs/query';
|
|
14
|
+
import type { UseQueryReturnType } from '../../../libs/query';
|
|
15
|
+
|
|
16
|
+
export type UseNFTsByAddressParameters<selectData = GetNFTsData> = GetNFTsQueryConfig<selectData>;
|
|
17
|
+
|
|
18
|
+
export type UseNFTsByAddressReturnType<selectData = GetNFTsData> = UseQueryReturnType<selectData, GetNFTsErrorType>;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Hook to get NFTs
|
|
22
|
+
*/
|
|
23
|
+
export const useNFTsByAddress = <selectData = GetNFTsData>(
|
|
24
|
+
parameters: UseNFTsByAddressParameters<selectData> = {},
|
|
25
|
+
): UseNFTsByAddressReturnType<selectData> => {
|
|
26
|
+
const appKit = useAppKit();
|
|
27
|
+
|
|
28
|
+
return useQuery(getNFTsQueryOptions(appKit, parameters));
|
|
29
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import type { GetNFTsData } from '@ton/appkit/queries';
|
|
10
|
+
|
|
11
|
+
import { useAddress } from '../../wallets/hooks/use-address';
|
|
12
|
+
import { useNFTsByAddress } from './use-nfts-by-address';
|
|
13
|
+
import type { UseNFTsByAddressParameters, UseNFTsByAddressReturnType } from './use-nfts-by-address';
|
|
14
|
+
|
|
15
|
+
export type UseNFTsParameters<selectData = GetNFTsData> = UseNFTsByAddressParameters<selectData>;
|
|
16
|
+
|
|
17
|
+
export type UseNFTsReturnType<selectData = GetNFTsData> = UseNFTsByAddressReturnType<selectData>;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Hook to get NFTs of the selected wallet
|
|
21
|
+
*/
|
|
22
|
+
export const useNfts = <selectData = GetNFTsData>(
|
|
23
|
+
parameters: UseNFTsParameters<selectData> = {},
|
|
24
|
+
): UseNFTsReturnType<selectData> => {
|
|
25
|
+
const address = useAddress();
|
|
26
|
+
|
|
27
|
+
return useNFTsByAddress({ ...parameters, address });
|
|
28
|
+
};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
'use client';
|
|
10
|
+
|
|
11
|
+
import type { MutateFunction, MutateOptions } from '@tanstack/react-query';
|
|
12
|
+
import type {
|
|
13
|
+
TransferNftData,
|
|
14
|
+
TransferNftErrorType,
|
|
15
|
+
TransferNftOptions,
|
|
16
|
+
TransferNftVariables,
|
|
17
|
+
} from '@ton/appkit/queries';
|
|
18
|
+
import { transferNftMutationOptions } from '@ton/appkit/queries';
|
|
19
|
+
|
|
20
|
+
import { useMutation } from '../../../libs/query';
|
|
21
|
+
import type { UseMutationReturnType } from '../../../libs/query';
|
|
22
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
23
|
+
|
|
24
|
+
export type UseTransferNftParameters<context = unknown> = TransferNftOptions<context>;
|
|
25
|
+
|
|
26
|
+
export type UseTransferNftReturnType<context = unknown> = UseMutationReturnType<
|
|
27
|
+
TransferNftData,
|
|
28
|
+
TransferNftErrorType,
|
|
29
|
+
TransferNftVariables,
|
|
30
|
+
context,
|
|
31
|
+
(
|
|
32
|
+
variables: TransferNftVariables,
|
|
33
|
+
options?: MutateOptions<TransferNftData, TransferNftErrorType, TransferNftVariables, context>,
|
|
34
|
+
) => void,
|
|
35
|
+
MutateFunction<TransferNftData, TransferNftErrorType, TransferNftVariables, context>
|
|
36
|
+
>;
|
|
37
|
+
|
|
38
|
+
export const useTransferNft = <context = unknown>(
|
|
39
|
+
parameters: UseTransferNftParameters<context> = {},
|
|
40
|
+
): UseTransferNftReturnType<context> => {
|
|
41
|
+
const appKit = useAppKit();
|
|
42
|
+
|
|
43
|
+
return useMutation(transferNftMutationOptions(appKit, parameters));
|
|
44
|
+
};
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
1
9
|
export * from './components/nft-item';
|
|
10
|
+
|
|
2
11
|
export * from './hooks/use-nfts';
|
|
3
12
|
export * from './hooks/use-nft';
|
|
4
13
|
export * from './hooks/use-nfts-by-address';
|
|
5
14
|
export * from './hooks/use-transfer-nft';
|
|
6
|
-
//# sourceMappingURL=index.mjs.map
|
|
7
|
-
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import type { UseMutationResult } from '@tanstack/react-query';
|
|
10
|
+
import { signBinaryMutationOptions } from '@ton/appkit/queries';
|
|
11
|
+
import type { SignBinaryData, SignBinaryErrorType, SignBinaryOptions, SignBinaryVariables } from '@ton/appkit/queries';
|
|
12
|
+
|
|
13
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
14
|
+
import { useMutation } from '../../../libs/query';
|
|
15
|
+
|
|
16
|
+
export type UseSignBinaryParameters<context = unknown> = SignBinaryOptions<context>;
|
|
17
|
+
|
|
18
|
+
export type UseSignBinaryReturnType<context = unknown> = UseMutationResult<
|
|
19
|
+
SignBinaryData,
|
|
20
|
+
SignBinaryErrorType,
|
|
21
|
+
SignBinaryVariables,
|
|
22
|
+
context
|
|
23
|
+
>;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Hook to sign binary data with the connected wallet.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* ```tsx
|
|
30
|
+
* const { mutate: signBinary, isPending } = useSignBinary();
|
|
31
|
+
*
|
|
32
|
+
* const handleSign = () => {
|
|
33
|
+
* signBinary({ bytes: btoa("binary data") });
|
|
34
|
+
* };
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
export const useSignBinary = <context = unknown>(
|
|
38
|
+
parameters?: UseSignBinaryParameters<context>,
|
|
39
|
+
): UseSignBinaryReturnType<context> => {
|
|
40
|
+
const appKit = useAppKit();
|
|
41
|
+
|
|
42
|
+
return useMutation(signBinaryMutationOptions(appKit, parameters));
|
|
43
|
+
};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import type { UseMutationResult } from '@tanstack/react-query';
|
|
10
|
+
import { signCellMutationOptions } from '@ton/appkit/queries';
|
|
11
|
+
import type { SignCellData, SignCellErrorType, SignCellOptions, SignCellVariables } from '@ton/appkit/queries';
|
|
12
|
+
|
|
13
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
14
|
+
import { useMutation } from '../../../libs/query';
|
|
15
|
+
|
|
16
|
+
export type UseSignCellParameters<context = unknown> = SignCellOptions<context>;
|
|
17
|
+
|
|
18
|
+
export type UseSignCellReturnType<context = unknown> = UseMutationResult<
|
|
19
|
+
SignCellData,
|
|
20
|
+
SignCellErrorType,
|
|
21
|
+
SignCellVariables,
|
|
22
|
+
context
|
|
23
|
+
>;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Hook to sign TON Cell data with the connected wallet.
|
|
27
|
+
* Used for on-chain signature verification.
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* ```tsx
|
|
31
|
+
* const { mutate: signCell, isPending } = useSignCell();
|
|
32
|
+
*
|
|
33
|
+
* const handleSign = () => {
|
|
34
|
+
* signCell({ cell: bocBase64, schema: "transfer#abc amount:uint64 = Transfer" });
|
|
35
|
+
* };
|
|
36
|
+
* ```
|
|
37
|
+
*/
|
|
38
|
+
export const useSignCell = <context = unknown>(
|
|
39
|
+
parameters?: UseSignCellParameters<context>,
|
|
40
|
+
): UseSignCellReturnType<context> => {
|
|
41
|
+
const appKit = useAppKit();
|
|
42
|
+
|
|
43
|
+
return useMutation(signCellMutationOptions(appKit, parameters));
|
|
44
|
+
};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import type { UseMutationResult } from '@tanstack/react-query';
|
|
10
|
+
import { signTextMutationOptions } from '@ton/appkit/queries';
|
|
11
|
+
import type { SignTextData, SignTextErrorType, SignTextOptions, SignTextVariables } from '@ton/appkit/queries';
|
|
12
|
+
|
|
13
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
14
|
+
import { useMutation } from '../../../libs/query';
|
|
15
|
+
|
|
16
|
+
export type UseSignTextParameters<context = unknown> = SignTextOptions<context>;
|
|
17
|
+
|
|
18
|
+
export type UseSignTextReturnType<context = unknown> = UseMutationResult<
|
|
19
|
+
SignTextData,
|
|
20
|
+
SignTextErrorType,
|
|
21
|
+
SignTextVariables,
|
|
22
|
+
context
|
|
23
|
+
>;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Hook to sign text messages with the connected wallet.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* ```tsx
|
|
30
|
+
* const { mutate: signText, isPending } = useSignText();
|
|
31
|
+
*
|
|
32
|
+
* const handleSign = () => {
|
|
33
|
+
* signText({ text: "Hello World" });
|
|
34
|
+
* };
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
export const useSignText = <context = unknown>(
|
|
38
|
+
parameters: UseSignTextParameters<context> = {},
|
|
39
|
+
): UseSignTextReturnType<context> => {
|
|
40
|
+
const appKit = useAppKit();
|
|
41
|
+
|
|
42
|
+
return useMutation(signTextMutationOptions(appKit, parameters));
|
|
43
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
export * from './hooks/use-sign-text';
|
|
10
|
+
export * from './hooks/use-sign-binary';
|
|
11
|
+
export * from './hooks/use-sign-cell';
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
'use client';
|
|
10
|
+
|
|
11
|
+
import type { UseMutationResult } from '@tanstack/react-query';
|
|
12
|
+
import { buildSwapTransactionMutationOptions } from '@ton/appkit/queries';
|
|
13
|
+
import type {
|
|
14
|
+
BuildSwapTransactionData,
|
|
15
|
+
BuildSwapTransactionErrorType,
|
|
16
|
+
BuildSwapTransactionMutationOptions,
|
|
17
|
+
BuildSwapTransactionVariables,
|
|
18
|
+
} from '@ton/appkit/queries';
|
|
19
|
+
|
|
20
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
21
|
+
import { useMutation } from '../../../libs/query';
|
|
22
|
+
|
|
23
|
+
export type UseBuildSwapTransactionParameters<context = unknown> = BuildSwapTransactionMutationOptions<context>;
|
|
24
|
+
|
|
25
|
+
export type UseBuildSwapTransactionReturnType<context = unknown> = UseMutationResult<
|
|
26
|
+
BuildSwapTransactionData,
|
|
27
|
+
BuildSwapTransactionErrorType,
|
|
28
|
+
BuildSwapTransactionVariables,
|
|
29
|
+
context
|
|
30
|
+
>;
|
|
31
|
+
|
|
32
|
+
export const useBuildSwapTransaction = <context = unknown>(
|
|
33
|
+
parameters?: UseBuildSwapTransactionParameters<context>,
|
|
34
|
+
): UseBuildSwapTransactionReturnType<context> => {
|
|
35
|
+
const appKit = useAppKit();
|
|
36
|
+
|
|
37
|
+
return useMutation(buildSwapTransactionMutationOptions(appKit, parameters));
|
|
38
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
'use client';
|
|
10
|
+
|
|
11
|
+
import { getSwapQuoteQueryOptions } from '@ton/appkit/queries';
|
|
12
|
+
import type { GetSwapQuoteData, GetSwapQuoteErrorType, GetSwapQuoteQueryConfig } from '@ton/appkit/queries';
|
|
13
|
+
|
|
14
|
+
import { useAppKit } from '../../../hooks/use-app-kit';
|
|
15
|
+
import { useQuery } from '../../../libs/query';
|
|
16
|
+
import type { UseQueryReturnType } from '../../../libs/query';
|
|
17
|
+
|
|
18
|
+
export type UseSwapQuoteParameters<selectData = GetSwapQuoteData> = GetSwapQuoteQueryConfig<selectData>;
|
|
19
|
+
|
|
20
|
+
export type UseSwapQuoteReturnType<selectData = GetSwapQuoteData> = UseQueryReturnType<
|
|
21
|
+
selectData,
|
|
22
|
+
GetSwapQuoteErrorType
|
|
23
|
+
>;
|
|
24
|
+
|
|
25
|
+
export const useSwapQuote = <selectData = GetSwapQuoteData>(
|
|
26
|
+
parameters: UseSwapQuoteParameters<selectData> = {},
|
|
27
|
+
): UseSwapQuoteReturnType<selectData> => {
|
|
28
|
+
const appKit = useAppKit();
|
|
29
|
+
|
|
30
|
+
return useQuery(getSwapQuoteQueryOptions(appKit, parameters));
|
|
31
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
export * from './hooks/use-swap-quote';
|
|
10
|
+
export * from './hooks/use-build-swap-transaction';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
export { Transaction } from './transaction';
|
|
10
|
+
export type { TransactionProps, TransactionRenderProps } from './transaction';
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { useCallback, useMemo } from 'react';
|
|
10
|
+
import type { FC, ReactNode, ComponentProps } from 'react';
|
|
11
|
+
import type { SendTransactionParameters, SendTransactionReturnType } from '@ton/appkit';
|
|
12
|
+
|
|
13
|
+
import { TransactionProvider, useTransactionContext } from '../transaction-provider';
|
|
14
|
+
import { useI18n } from '../../../../hooks/use-i18n';
|
|
15
|
+
import { Button } from '../../../../components/button';
|
|
16
|
+
|
|
17
|
+
export interface TransactionRenderProps {
|
|
18
|
+
isLoading: boolean;
|
|
19
|
+
onSubmit: () => void;
|
|
20
|
+
disabled: boolean;
|
|
21
|
+
text: ReactNode;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export type TransactionRequest =
|
|
25
|
+
| SendTransactionParameters
|
|
26
|
+
| Promise<SendTransactionParameters>
|
|
27
|
+
| (() => SendTransactionParameters)
|
|
28
|
+
| (() => Promise<SendTransactionParameters>);
|
|
29
|
+
|
|
30
|
+
export interface TransactionProps extends Omit<ComponentProps<'button'>, 'children' | 'onError'> {
|
|
31
|
+
/** The transaction request parameters */
|
|
32
|
+
request: TransactionRequest;
|
|
33
|
+
/** Callback when an error occurs */
|
|
34
|
+
onError?: (error: Error) => void;
|
|
35
|
+
/** Callback when the transaction is successful */
|
|
36
|
+
onSuccess?: (response: SendTransactionReturnType) => void;
|
|
37
|
+
/** Custom button text */
|
|
38
|
+
text?: ReactNode;
|
|
39
|
+
/** Custom render function */
|
|
40
|
+
children?: (props: TransactionRenderProps) => ReactNode;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
interface TransactionContentProps extends Omit<ComponentProps<'button'>, 'children'> {
|
|
44
|
+
text?: ReactNode;
|
|
45
|
+
children?: (props: TransactionRenderProps) => ReactNode;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
const TransactionContent: FC<TransactionContentProps> = ({ text, children, ...props }) => {
|
|
49
|
+
const { isLoading, onSubmit, disabled } = useTransactionContext();
|
|
50
|
+
const { t } = useI18n();
|
|
51
|
+
|
|
52
|
+
const isDisabled = disabled || isLoading;
|
|
53
|
+
|
|
54
|
+
const handleSubmit = useCallback(() => {
|
|
55
|
+
if (!isDisabled) {
|
|
56
|
+
onSubmit();
|
|
57
|
+
}
|
|
58
|
+
}, [isDisabled, onSubmit]);
|
|
59
|
+
|
|
60
|
+
const buttonText = useMemo(() => {
|
|
61
|
+
if (isLoading) {
|
|
62
|
+
return t('transaction.processing');
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
return text ?? t('transaction.sendTransaction');
|
|
66
|
+
}, [isLoading, text, t]);
|
|
67
|
+
|
|
68
|
+
if (children) {
|
|
69
|
+
return (
|
|
70
|
+
<>
|
|
71
|
+
{children({
|
|
72
|
+
isLoading,
|
|
73
|
+
onSubmit: handleSubmit,
|
|
74
|
+
disabled: isDisabled,
|
|
75
|
+
text: buttonText,
|
|
76
|
+
})}
|
|
77
|
+
</>
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
return (
|
|
82
|
+
<Button onClick={handleSubmit} disabled={isDisabled} {...props}>
|
|
83
|
+
{buttonText}
|
|
84
|
+
</Button>
|
|
85
|
+
);
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
export const Transaction: FC<TransactionProps> = ({
|
|
89
|
+
request,
|
|
90
|
+
children,
|
|
91
|
+
className,
|
|
92
|
+
onError,
|
|
93
|
+
onSuccess,
|
|
94
|
+
disabled = false,
|
|
95
|
+
text,
|
|
96
|
+
...props
|
|
97
|
+
}) => {
|
|
98
|
+
return (
|
|
99
|
+
<TransactionProvider request={request} onError={onError} onSuccess={onSuccess} disabled={disabled}>
|
|
100
|
+
<TransactionContent className={className} text={text} {...props}>
|
|
101
|
+
{children}
|
|
102
|
+
</TransactionContent>
|
|
103
|
+
</TransactionProvider>
|
|
104
|
+
);
|
|
105
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
export { TransactionProvider, useTransactionContext, TransactionContext } from './transaction-provider';
|
|
10
|
+
export type { TransactionContextType } from './transaction-provider';
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) TonTech.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { createContext, useCallback, useContext, useMemo, useState } from 'react';
|
|
10
|
+
import type { FC, PropsWithChildren } from 'react';
|
|
11
|
+
import type { SendTransactionReturnType } from '@ton/appkit';
|
|
12
|
+
|
|
13
|
+
import { useSendTransaction } from '../../hooks/use-send-transaction';
|
|
14
|
+
import type { TransactionRequest } from '../transaction/transaction';
|
|
15
|
+
|
|
16
|
+
export interface TransactionContextType {
|
|
17
|
+
/** Function to submit the transaction */
|
|
18
|
+
onSubmit: () => void;
|
|
19
|
+
/** Whether the transaction is currently loading */
|
|
20
|
+
isLoading: boolean;
|
|
21
|
+
/** The error object if the transaction failed */
|
|
22
|
+
error?: Error | null;
|
|
23
|
+
/** The receipt of the successful transaction */
|
|
24
|
+
receipt?: SendTransactionReturnType | null;
|
|
25
|
+
/** Disable the button/interaction */
|
|
26
|
+
disabled?: boolean;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export const TransactionContext = createContext<TransactionContextType>({
|
|
30
|
+
onSubmit: () => {
|
|
31
|
+
throw new Error('onSubmit is not defined');
|
|
32
|
+
},
|
|
33
|
+
isLoading: false,
|
|
34
|
+
});
|
|
35
|
+
|
|
36
|
+
export function useTransactionContext() {
|
|
37
|
+
const context = useContext(TransactionContext);
|
|
38
|
+
|
|
39
|
+
return context;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export interface TransactionProviderProps extends PropsWithChildren {
|
|
43
|
+
/** The transaction request parameters */
|
|
44
|
+
request: TransactionRequest;
|
|
45
|
+
/** Callback when an error occurs */
|
|
46
|
+
onError?: (error: Error) => void;
|
|
47
|
+
/** Callback when the transaction is successful */
|
|
48
|
+
onSuccess?: (response: SendTransactionReturnType) => void;
|
|
49
|
+
/** Disable the button/interaction */
|
|
50
|
+
disabled?: boolean;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export const TransactionProvider: FC<TransactionProviderProps> = ({
|
|
54
|
+
children,
|
|
55
|
+
request,
|
|
56
|
+
onError,
|
|
57
|
+
onSuccess,
|
|
58
|
+
disabled = false,
|
|
59
|
+
}) => {
|
|
60
|
+
const [receipt, setReceipt] = useState<SendTransactionReturnType | null>(null);
|
|
61
|
+
const [isPreparing, setIsPreparing] = useState(false);
|
|
62
|
+
|
|
63
|
+
const {
|
|
64
|
+
mutateAsync: sendTransaction,
|
|
65
|
+
isPending,
|
|
66
|
+
error: mutationError,
|
|
67
|
+
} = useSendTransaction({
|
|
68
|
+
mutation: {
|
|
69
|
+
onSuccess: (data) => {
|
|
70
|
+
setReceipt(data);
|
|
71
|
+
onSuccess?.(data);
|
|
72
|
+
},
|
|
73
|
+
onError: (err) => {
|
|
74
|
+
onError?.(err);
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
});
|
|
78
|
+
|
|
79
|
+
const handleSubmit = useCallback(async () => {
|
|
80
|
+
if (disabled || isPreparing || isPending) {
|
|
81
|
+
return;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
setIsPreparing(true);
|
|
85
|
+
|
|
86
|
+
try {
|
|
87
|
+
const transactionRequest = typeof request === 'function' ? await request() : await request;
|
|
88
|
+
|
|
89
|
+
if (!transactionRequest) {
|
|
90
|
+
return;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
await sendTransaction(transactionRequest);
|
|
94
|
+
} catch (e) {
|
|
95
|
+
const error = e instanceof Error ? e : new Error(String(e));
|
|
96
|
+
onError?.(error);
|
|
97
|
+
} finally {
|
|
98
|
+
setIsPreparing(false);
|
|
99
|
+
}
|
|
100
|
+
}, [sendTransaction, request, disabled, isPreparing, isPending, onError]);
|
|
101
|
+
|
|
102
|
+
const value = useMemo(
|
|
103
|
+
() => ({
|
|
104
|
+
error: mutationError,
|
|
105
|
+
isLoading: isPreparing || isPending,
|
|
106
|
+
onSubmit: handleSubmit,
|
|
107
|
+
receipt,
|
|
108
|
+
disabled,
|
|
109
|
+
}),
|
|
110
|
+
[mutationError, isPreparing, isPending, handleSubmit, receipt, disabled],
|
|
111
|
+
);
|
|
112
|
+
|
|
113
|
+
return <TransactionContext.Provider value={value}>{children}</TransactionContext.Provider>;
|
|
114
|
+
};
|