@xyo-network/react-connected-accounts 2.81.10 → 2.82.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/browser/classes/index.d.cts +1 -1
- package/dist/browser/classes/index.d.mts +1 -1
- package/dist/browser/classes/index.d.ts +1 -1
- package/dist/browser/components/ConnectedAccountsFlexbox.d.cts +2 -1
- package/dist/browser/components/ConnectedAccountsFlexbox.d.cts.map +1 -1
- package/dist/browser/components/ConnectedAccountsFlexbox.d.mts +2 -1
- package/dist/browser/components/ConnectedAccountsFlexbox.d.mts.map +1 -1
- package/dist/browser/components/ConnectedAccountsFlexbox.d.ts +2 -1
- package/dist/browser/components/ConnectedAccountsFlexbox.d.ts.map +1 -1
- package/dist/browser/components/index.d.cts +2 -2
- package/dist/browser/components/index.d.cts.map +1 -1
- package/dist/browser/components/index.d.mts +2 -2
- package/dist/browser/components/index.d.mts.map +1 -1
- package/dist/browser/components/index.d.ts +2 -2
- package/dist/browser/components/index.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/CheckboxFormControl.d.cts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/CheckboxFormControl.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/CheckboxFormControl.d.mts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/CheckboxFormControl.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/CheckboxFormControl.d.ts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/CheckboxFormControl.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/Dialog.d.cts +2 -1
- package/dist/browser/components/wallet/dialogs/connect/Dialog.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/Dialog.d.mts +2 -1
- package/dist/browser/components/wallet/dialogs/connect/Dialog.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/Dialog.d.ts +2 -1
- package/dist/browser/components/wallet/dialogs/connect/Dialog.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.cts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.mts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.ts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/Permissions.d.cts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/Permissions.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/Permissions.d.mts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/Permissions.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/Permissions.d.ts +1 -0
- package/dist/browser/components/wallet/dialogs/connect/Permissions.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/index.d.cts +2 -2
- package/dist/browser/components/wallet/dialogs/connect/index.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/index.d.mts +2 -2
- package/dist/browser/components/wallet/dialogs/connect/index.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/connect/index.d.ts +2 -2
- package/dist/browser/components/wallet/dialogs/connect/index.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/index.d.cts +2 -2
- package/dist/browser/components/wallet/dialogs/index.d.mts +2 -2
- package/dist/browser/components/wallet/dialogs/index.d.ts +2 -2
- package/dist/browser/components/wallet/dialogs/revoke/Dialog.d.cts +2 -1
- package/dist/browser/components/wallet/dialogs/revoke/Dialog.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/Dialog.d.mts +2 -1
- package/dist/browser/components/wallet/dialogs/revoke/Dialog.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/Dialog.d.ts +2 -1
- package/dist/browser/components/wallet/dialogs/revoke/Dialog.d.ts.map +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/index.d.cts +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/index.d.cts.map +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/index.d.mts +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/index.d.mts.map +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/index.d.ts +1 -1
- package/dist/browser/components/wallet/dialogs/revoke/index.d.ts.map +1 -1
- package/dist/browser/components/wallet/index.d.cts +2 -2
- package/dist/browser/components/wallet/index.d.mts +2 -2
- package/dist/browser/components/wallet/index.d.ts +2 -2
- package/dist/browser/components/wallet/lib/index.d.cts +2 -2
- package/dist/browser/components/wallet/lib/index.d.mts +2 -2
- package/dist/browser/components/wallet/lib/index.d.ts +2 -2
- package/dist/browser/components/wallet/table/ConnectedWalletsTable.d.cts +1 -0
- package/dist/browser/components/wallet/table/ConnectedWalletsTable.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTable.d.mts +1 -0
- package/dist/browser/components/wallet/table/ConnectedWalletsTable.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTable.d.ts +1 -0
- package/dist/browser/components/wallet/table/ConnectedWalletsTable.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTableRow.d.cts +2 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTableRow.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTableRow.d.mts +2 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTableRow.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTableRow.d.ts +2 -1
- package/dist/browser/components/wallet/table/ConnectedWalletsTableRow.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Accounts.d.cts +2 -1
- package/dist/browser/components/wallet/table/cells/Accounts.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Accounts.d.mts +2 -1
- package/dist/browser/components/wallet/table/cells/Accounts.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Accounts.d.ts +2 -1
- package/dist/browser/components/wallet/table/cells/Accounts.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Actions.d.cts +2 -1
- package/dist/browser/components/wallet/table/cells/Actions.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Actions.d.mts +2 -1
- package/dist/browser/components/wallet/table/cells/Actions.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Actions.d.ts +2 -1
- package/dist/browser/components/wallet/table/cells/Actions.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Cells.d.cts +1 -1
- package/dist/browser/components/wallet/table/cells/Cells.d.mts +1 -1
- package/dist/browser/components/wallet/table/cells/Cells.d.ts +1 -1
- package/dist/browser/components/wallet/table/cells/ChainName.d.cts +2 -1
- package/dist/browser/components/wallet/table/cells/ChainName.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/ChainName.d.mts +2 -1
- package/dist/browser/components/wallet/table/cells/ChainName.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/ChainName.d.ts +2 -1
- package/dist/browser/components/wallet/table/cells/ChainName.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/State.d.cts +2 -1
- package/dist/browser/components/wallet/table/cells/State.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/State.d.mts +2 -1
- package/dist/browser/components/wallet/table/cells/State.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/State.d.ts +2 -1
- package/dist/browser/components/wallet/table/cells/State.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Wallet.d.cts +2 -1
- package/dist/browser/components/wallet/table/cells/Wallet.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Wallet.d.mts +2 -1
- package/dist/browser/components/wallet/table/cells/Wallet.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/Wallet.d.ts +2 -1
- package/dist/browser/components/wallet/table/cells/Wallet.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/index.d.cts +6 -6
- package/dist/browser/components/wallet/table/cells/index.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/index.d.mts +6 -6
- package/dist/browser/components/wallet/table/cells/index.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/index.d.ts +6 -6
- package/dist/browser/components/wallet/table/cells/index.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/cells/lib/index.d.cts +1 -1
- package/dist/browser/components/wallet/table/cells/lib/index.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/cells/lib/index.d.mts +1 -1
- package/dist/browser/components/wallet/table/cells/lib/index.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/cells/lib/index.d.ts +1 -1
- package/dist/browser/components/wallet/table/cells/lib/index.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/hooks/index.d.cts +1 -1
- package/dist/browser/components/wallet/table/hooks/index.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/hooks/index.d.mts +1 -1
- package/dist/browser/components/wallet/table/hooks/index.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/hooks/index.d.ts +1 -1
- package/dist/browser/components/wallet/table/hooks/index.d.ts.map +1 -1
- package/dist/browser/components/wallet/table/hooks/useActiveProviderDialogState.d.cts +1 -1
- package/dist/browser/components/wallet/table/hooks/useActiveProviderDialogState.d.mts +1 -1
- package/dist/browser/components/wallet/table/hooks/useActiveProviderDialogState.d.ts +1 -1
- package/dist/browser/components/wallet/table/index.d.cts +4 -4
- package/dist/browser/components/wallet/table/index.d.cts.map +1 -1
- package/dist/browser/components/wallet/table/index.d.mts +4 -4
- package/dist/browser/components/wallet/table/index.d.mts.map +1 -1
- package/dist/browser/components/wallet/table/index.d.ts +4 -4
- package/dist/browser/components/wallet/table/index.d.ts.map +1 -1
- package/dist/browser/hooks/index.d.cts +2 -2
- package/dist/browser/hooks/index.d.cts.map +1 -1
- package/dist/browser/hooks/index.d.mts +2 -2
- package/dist/browser/hooks/index.d.mts.map +1 -1
- package/dist/browser/hooks/index.d.ts +2 -2
- package/dist/browser/hooks/index.d.ts.map +1 -1
- package/dist/browser/hooks/useDetectWallets.d.cts.map +1 -1
- package/dist/browser/hooks/useDetectWallets.d.mts.map +1 -1
- package/dist/browser/hooks/useDetectWallets.d.ts.map +1 -1
- package/dist/browser/hooks/useEnabledWallets.d.cts +1 -1
- package/dist/browser/hooks/useEnabledWallets.d.mts +1 -1
- package/dist/browser/hooks/useEnabledWallets.d.ts +1 -1
- package/dist/browser/index.cjs +339 -260
- package/dist/browser/index.cjs.map +1 -1
- package/dist/browser/index.d.cts +3 -3
- package/dist/browser/index.d.mts +3 -3
- package/dist/browser/index.d.ts +3 -3
- package/dist/browser/index.mjs +623 -0
- package/dist/browser/index.mjs.map +1 -0
- package/dist/neutral/classes/index.d.cts +1 -1
- package/dist/neutral/classes/index.d.mts +1 -1
- package/dist/neutral/classes/index.d.ts +1 -1
- package/dist/neutral/components/ConnectedAccountsFlexbox.d.cts +2 -1
- package/dist/neutral/components/ConnectedAccountsFlexbox.d.cts.map +1 -1
- package/dist/neutral/components/ConnectedAccountsFlexbox.d.mts +2 -1
- package/dist/neutral/components/ConnectedAccountsFlexbox.d.mts.map +1 -1
- package/dist/neutral/components/ConnectedAccountsFlexbox.d.ts +2 -1
- package/dist/neutral/components/ConnectedAccountsFlexbox.d.ts.map +1 -1
- package/dist/neutral/components/index.d.cts +2 -2
- package/dist/neutral/components/index.d.cts.map +1 -1
- package/dist/neutral/components/index.d.mts +2 -2
- package/dist/neutral/components/index.d.mts.map +1 -1
- package/dist/neutral/components/index.d.ts +2 -2
- package/dist/neutral/components/index.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/CheckboxFormControl.d.cts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/CheckboxFormControl.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/CheckboxFormControl.d.mts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/CheckboxFormControl.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/CheckboxFormControl.d.ts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/CheckboxFormControl.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/Dialog.d.cts +2 -1
- package/dist/neutral/components/wallet/dialogs/connect/Dialog.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/Dialog.d.mts +2 -1
- package/dist/neutral/components/wallet/dialogs/connect/Dialog.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/Dialog.d.ts +2 -1
- package/dist/neutral/components/wallet/dialogs/connect/Dialog.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.cts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.mts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.ts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/Permissions.d.cts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/Permissions.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/Permissions.d.mts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/Permissions.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/Permissions.d.ts +1 -0
- package/dist/neutral/components/wallet/dialogs/connect/Permissions.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/index.d.cts +2 -2
- package/dist/neutral/components/wallet/dialogs/connect/index.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/index.d.mts +2 -2
- package/dist/neutral/components/wallet/dialogs/connect/index.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/connect/index.d.ts +2 -2
- package/dist/neutral/components/wallet/dialogs/connect/index.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/index.d.cts +2 -2
- package/dist/neutral/components/wallet/dialogs/index.d.mts +2 -2
- package/dist/neutral/components/wallet/dialogs/index.d.ts +2 -2
- package/dist/neutral/components/wallet/dialogs/revoke/Dialog.d.cts +2 -1
- package/dist/neutral/components/wallet/dialogs/revoke/Dialog.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/Dialog.d.mts +2 -1
- package/dist/neutral/components/wallet/dialogs/revoke/Dialog.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/Dialog.d.ts +2 -1
- package/dist/neutral/components/wallet/dialogs/revoke/Dialog.d.ts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/index.d.cts +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/index.d.cts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/index.d.mts +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/index.d.mts.map +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/index.d.ts +1 -1
- package/dist/neutral/components/wallet/dialogs/revoke/index.d.ts.map +1 -1
- package/dist/neutral/components/wallet/index.d.cts +2 -2
- package/dist/neutral/components/wallet/index.d.mts +2 -2
- package/dist/neutral/components/wallet/index.d.ts +2 -2
- package/dist/neutral/components/wallet/lib/index.d.cts +2 -2
- package/dist/neutral/components/wallet/lib/index.d.mts +2 -2
- package/dist/neutral/components/wallet/lib/index.d.ts +2 -2
- package/dist/neutral/components/wallet/table/ConnectedWalletsTable.d.cts +1 -0
- package/dist/neutral/components/wallet/table/ConnectedWalletsTable.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTable.d.mts +1 -0
- package/dist/neutral/components/wallet/table/ConnectedWalletsTable.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTable.d.ts +1 -0
- package/dist/neutral/components/wallet/table/ConnectedWalletsTable.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTableRow.d.cts +2 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTableRow.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTableRow.d.mts +2 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTableRow.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTableRow.d.ts +2 -1
- package/dist/neutral/components/wallet/table/ConnectedWalletsTableRow.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Accounts.d.cts +2 -1
- package/dist/neutral/components/wallet/table/cells/Accounts.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Accounts.d.mts +2 -1
- package/dist/neutral/components/wallet/table/cells/Accounts.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Accounts.d.ts +2 -1
- package/dist/neutral/components/wallet/table/cells/Accounts.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Actions.d.cts +2 -1
- package/dist/neutral/components/wallet/table/cells/Actions.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Actions.d.mts +2 -1
- package/dist/neutral/components/wallet/table/cells/Actions.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Actions.d.ts +2 -1
- package/dist/neutral/components/wallet/table/cells/Actions.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Cells.d.cts +1 -1
- package/dist/neutral/components/wallet/table/cells/Cells.d.mts +1 -1
- package/dist/neutral/components/wallet/table/cells/Cells.d.ts +1 -1
- package/dist/neutral/components/wallet/table/cells/ChainName.d.cts +2 -1
- package/dist/neutral/components/wallet/table/cells/ChainName.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/ChainName.d.mts +2 -1
- package/dist/neutral/components/wallet/table/cells/ChainName.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/ChainName.d.ts +2 -1
- package/dist/neutral/components/wallet/table/cells/ChainName.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/State.d.cts +2 -1
- package/dist/neutral/components/wallet/table/cells/State.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/State.d.mts +2 -1
- package/dist/neutral/components/wallet/table/cells/State.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/State.d.ts +2 -1
- package/dist/neutral/components/wallet/table/cells/State.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Wallet.d.cts +2 -1
- package/dist/neutral/components/wallet/table/cells/Wallet.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Wallet.d.mts +2 -1
- package/dist/neutral/components/wallet/table/cells/Wallet.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/Wallet.d.ts +2 -1
- package/dist/neutral/components/wallet/table/cells/Wallet.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/index.d.cts +6 -6
- package/dist/neutral/components/wallet/table/cells/index.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/index.d.mts +6 -6
- package/dist/neutral/components/wallet/table/cells/index.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/index.d.ts +6 -6
- package/dist/neutral/components/wallet/table/cells/index.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/lib/index.d.cts +1 -1
- package/dist/neutral/components/wallet/table/cells/lib/index.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/lib/index.d.mts +1 -1
- package/dist/neutral/components/wallet/table/cells/lib/index.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/cells/lib/index.d.ts +1 -1
- package/dist/neutral/components/wallet/table/cells/lib/index.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/hooks/index.d.cts +1 -1
- package/dist/neutral/components/wallet/table/hooks/index.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/hooks/index.d.mts +1 -1
- package/dist/neutral/components/wallet/table/hooks/index.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/hooks/index.d.ts +1 -1
- package/dist/neutral/components/wallet/table/hooks/index.d.ts.map +1 -1
- package/dist/neutral/components/wallet/table/hooks/useActiveProviderDialogState.d.cts +1 -1
- package/dist/neutral/components/wallet/table/hooks/useActiveProviderDialogState.d.mts +1 -1
- package/dist/neutral/components/wallet/table/hooks/useActiveProviderDialogState.d.ts +1 -1
- package/dist/neutral/components/wallet/table/index.d.cts +4 -4
- package/dist/neutral/components/wallet/table/index.d.cts.map +1 -1
- package/dist/neutral/components/wallet/table/index.d.mts +4 -4
- package/dist/neutral/components/wallet/table/index.d.mts.map +1 -1
- package/dist/neutral/components/wallet/table/index.d.ts +4 -4
- package/dist/neutral/components/wallet/table/index.d.ts.map +1 -1
- package/dist/neutral/hooks/index.d.cts +2 -2
- package/dist/neutral/hooks/index.d.cts.map +1 -1
- package/dist/neutral/hooks/index.d.mts +2 -2
- package/dist/neutral/hooks/index.d.mts.map +1 -1
- package/dist/neutral/hooks/index.d.ts +2 -2
- package/dist/neutral/hooks/index.d.ts.map +1 -1
- package/dist/neutral/hooks/useDetectWallets.d.cts.map +1 -1
- package/dist/neutral/hooks/useDetectWallets.d.mts.map +1 -1
- package/dist/neutral/hooks/useDetectWallets.d.ts.map +1 -1
- package/dist/neutral/hooks/useEnabledWallets.d.cts +1 -1
- package/dist/neutral/hooks/useEnabledWallets.d.mts +1 -1
- package/dist/neutral/hooks/useEnabledWallets.d.ts +1 -1
- package/dist/neutral/index.cjs +339 -260
- package/dist/neutral/index.cjs.map +1 -1
- package/dist/neutral/index.d.cts +3 -3
- package/dist/neutral/index.d.mts +3 -3
- package/dist/neutral/index.d.ts +3 -3
- package/dist/neutral/index.mjs +623 -0
- package/dist/neutral/index.mjs.map +1 -0
- package/dist/node/classes/index.d.cts +1 -1
- package/dist/node/classes/index.d.mts +1 -1
- package/dist/node/classes/index.d.ts +1 -1
- package/dist/node/components/ConnectedAccountsFlexbox.d.cts +2 -1
- package/dist/node/components/ConnectedAccountsFlexbox.d.cts.map +1 -1
- package/dist/node/components/ConnectedAccountsFlexbox.d.mts +2 -1
- package/dist/node/components/ConnectedAccountsFlexbox.d.mts.map +1 -1
- package/dist/node/components/ConnectedAccountsFlexbox.d.ts +2 -1
- package/dist/node/components/ConnectedAccountsFlexbox.d.ts.map +1 -1
- package/dist/node/components/index.d.cts +2 -2
- package/dist/node/components/index.d.cts.map +1 -1
- package/dist/node/components/index.d.mts +2 -2
- package/dist/node/components/index.d.mts.map +1 -1
- package/dist/node/components/index.d.ts +2 -2
- package/dist/node/components/index.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/CheckboxFormControl.d.cts +1 -0
- package/dist/node/components/wallet/dialogs/connect/CheckboxFormControl.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/CheckboxFormControl.d.mts +1 -0
- package/dist/node/components/wallet/dialogs/connect/CheckboxFormControl.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/CheckboxFormControl.d.ts +1 -0
- package/dist/node/components/wallet/dialogs/connect/CheckboxFormControl.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/Dialog.d.cts +2 -1
- package/dist/node/components/wallet/dialogs/connect/Dialog.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/Dialog.d.mts +2 -1
- package/dist/node/components/wallet/dialogs/connect/Dialog.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/Dialog.d.ts +2 -1
- package/dist/node/components/wallet/dialogs/connect/Dialog.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.cts +1 -0
- package/dist/node/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.mts +1 -0
- package/dist/node/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.ts +1 -0
- package/dist/node/components/wallet/dialogs/connect/LinkedProvidersFlexbox.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/Permissions.d.cts +1 -0
- package/dist/node/components/wallet/dialogs/connect/Permissions.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/Permissions.d.mts +1 -0
- package/dist/node/components/wallet/dialogs/connect/Permissions.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/Permissions.d.ts +1 -0
- package/dist/node/components/wallet/dialogs/connect/Permissions.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/index.d.cts +2 -2
- package/dist/node/components/wallet/dialogs/connect/index.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/index.d.mts +2 -2
- package/dist/node/components/wallet/dialogs/connect/index.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/connect/index.d.ts +2 -2
- package/dist/node/components/wallet/dialogs/connect/index.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/index.d.cts +2 -2
- package/dist/node/components/wallet/dialogs/index.d.mts +2 -2
- package/dist/node/components/wallet/dialogs/index.d.ts +2 -2
- package/dist/node/components/wallet/dialogs/revoke/Dialog.d.cts +2 -1
- package/dist/node/components/wallet/dialogs/revoke/Dialog.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/revoke/Dialog.d.mts +2 -1
- package/dist/node/components/wallet/dialogs/revoke/Dialog.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/revoke/Dialog.d.ts +2 -1
- package/dist/node/components/wallet/dialogs/revoke/Dialog.d.ts.map +1 -1
- package/dist/node/components/wallet/dialogs/revoke/index.d.cts +1 -1
- package/dist/node/components/wallet/dialogs/revoke/index.d.cts.map +1 -1
- package/dist/node/components/wallet/dialogs/revoke/index.d.mts +1 -1
- package/dist/node/components/wallet/dialogs/revoke/index.d.mts.map +1 -1
- package/dist/node/components/wallet/dialogs/revoke/index.d.ts +1 -1
- package/dist/node/components/wallet/dialogs/revoke/index.d.ts.map +1 -1
- package/dist/node/components/wallet/index.d.cts +2 -2
- package/dist/node/components/wallet/index.d.mts +2 -2
- package/dist/node/components/wallet/index.d.ts +2 -2
- package/dist/node/components/wallet/lib/index.d.cts +2 -2
- package/dist/node/components/wallet/lib/index.d.mts +2 -2
- package/dist/node/components/wallet/lib/index.d.ts +2 -2
- package/dist/node/components/wallet/table/ConnectedWalletsTable.d.cts +1 -0
- package/dist/node/components/wallet/table/ConnectedWalletsTable.d.cts.map +1 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTable.d.mts +1 -0
- package/dist/node/components/wallet/table/ConnectedWalletsTable.d.mts.map +1 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTable.d.ts +1 -0
- package/dist/node/components/wallet/table/ConnectedWalletsTable.d.ts.map +1 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTableRow.d.cts +2 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTableRow.d.cts.map +1 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTableRow.d.mts +2 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTableRow.d.mts.map +1 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTableRow.d.ts +2 -1
- package/dist/node/components/wallet/table/ConnectedWalletsTableRow.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/Accounts.d.cts +2 -1
- package/dist/node/components/wallet/table/cells/Accounts.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/Accounts.d.mts +2 -1
- package/dist/node/components/wallet/table/cells/Accounts.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/Accounts.d.ts +2 -1
- package/dist/node/components/wallet/table/cells/Accounts.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/Actions.d.cts +2 -1
- package/dist/node/components/wallet/table/cells/Actions.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/Actions.d.mts +2 -1
- package/dist/node/components/wallet/table/cells/Actions.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/Actions.d.ts +2 -1
- package/dist/node/components/wallet/table/cells/Actions.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/Cells.d.cts +1 -1
- package/dist/node/components/wallet/table/cells/Cells.d.mts +1 -1
- package/dist/node/components/wallet/table/cells/Cells.d.ts +1 -1
- package/dist/node/components/wallet/table/cells/ChainName.d.cts +2 -1
- package/dist/node/components/wallet/table/cells/ChainName.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/ChainName.d.mts +2 -1
- package/dist/node/components/wallet/table/cells/ChainName.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/ChainName.d.ts +2 -1
- package/dist/node/components/wallet/table/cells/ChainName.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/State.d.cts +2 -1
- package/dist/node/components/wallet/table/cells/State.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/State.d.mts +2 -1
- package/dist/node/components/wallet/table/cells/State.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/State.d.ts +2 -1
- package/dist/node/components/wallet/table/cells/State.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/Wallet.d.cts +2 -1
- package/dist/node/components/wallet/table/cells/Wallet.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/Wallet.d.mts +2 -1
- package/dist/node/components/wallet/table/cells/Wallet.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/Wallet.d.ts +2 -1
- package/dist/node/components/wallet/table/cells/Wallet.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/index.d.cts +6 -6
- package/dist/node/components/wallet/table/cells/index.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/index.d.mts +6 -6
- package/dist/node/components/wallet/table/cells/index.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/index.d.ts +6 -6
- package/dist/node/components/wallet/table/cells/index.d.ts.map +1 -1
- package/dist/node/components/wallet/table/cells/lib/index.d.cts +1 -1
- package/dist/node/components/wallet/table/cells/lib/index.d.cts.map +1 -1
- package/dist/node/components/wallet/table/cells/lib/index.d.mts +1 -1
- package/dist/node/components/wallet/table/cells/lib/index.d.mts.map +1 -1
- package/dist/node/components/wallet/table/cells/lib/index.d.ts +1 -1
- package/dist/node/components/wallet/table/cells/lib/index.d.ts.map +1 -1
- package/dist/node/components/wallet/table/hooks/index.d.cts +1 -1
- package/dist/node/components/wallet/table/hooks/index.d.cts.map +1 -1
- package/dist/node/components/wallet/table/hooks/index.d.mts +1 -1
- package/dist/node/components/wallet/table/hooks/index.d.mts.map +1 -1
- package/dist/node/components/wallet/table/hooks/index.d.ts +1 -1
- package/dist/node/components/wallet/table/hooks/index.d.ts.map +1 -1
- package/dist/node/components/wallet/table/hooks/useActiveProviderDialogState.d.cts +1 -1
- package/dist/node/components/wallet/table/hooks/useActiveProviderDialogState.d.mts +1 -1
- package/dist/node/components/wallet/table/hooks/useActiveProviderDialogState.d.ts +1 -1
- package/dist/node/components/wallet/table/index.d.cts +4 -4
- package/dist/node/components/wallet/table/index.d.cts.map +1 -1
- package/dist/node/components/wallet/table/index.d.mts +4 -4
- package/dist/node/components/wallet/table/index.d.mts.map +1 -1
- package/dist/node/components/wallet/table/index.d.ts +4 -4
- package/dist/node/components/wallet/table/index.d.ts.map +1 -1
- package/dist/node/hooks/index.d.cts +2 -2
- package/dist/node/hooks/index.d.cts.map +1 -1
- package/dist/node/hooks/index.d.mts +2 -2
- package/dist/node/hooks/index.d.mts.map +1 -1
- package/dist/node/hooks/index.d.ts +2 -2
- package/dist/node/hooks/index.d.ts.map +1 -1
- package/dist/node/hooks/useDetectWallets.d.cts.map +1 -1
- package/dist/node/hooks/useDetectWallets.d.mts.map +1 -1
- package/dist/node/hooks/useDetectWallets.d.ts.map +1 -1
- package/dist/node/hooks/useEnabledWallets.d.cts +1 -1
- package/dist/node/hooks/useEnabledWallets.d.mts +1 -1
- package/dist/node/hooks/useEnabledWallets.d.ts +1 -1
- package/dist/node/index.cjs +346 -268
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.d.cts +3 -3
- package/dist/node/index.d.mts +3 -3
- package/dist/node/index.d.ts +3 -3
- package/dist/node/index.mjs +633 -0
- package/dist/node/index.mjs.map +1 -0
- package/package.json +11 -11
- package/src/classes/EnabledWallets.ts +1 -1
- package/src/classes/index.ts +1 -1
- package/src/components/ConnectedAccountsFlexbox.stories.tsx +2 -4
- package/src/components/ConnectedAccountsFlexbox.tsx +13 -9
- package/src/components/index.ts +2 -2
- package/src/components/wallet/dialogs/connect/CheckboxFormControl.tsx +1 -0
- package/src/components/wallet/dialogs/connect/Dialog.tsx +5 -4
- package/src/components/wallet/dialogs/connect/LinkedProvidersFlexbox.tsx +4 -3
- package/src/components/wallet/dialogs/connect/Permissions.tsx +3 -1
- package/src/components/wallet/dialogs/connect/index.ts +2 -2
- package/src/components/wallet/dialogs/index.ts +2 -2
- package/src/components/wallet/dialogs/revoke/Dialog.tsx +13 -4
- package/src/components/wallet/dialogs/revoke/index.ts +1 -1
- package/src/components/wallet/index.ts +2 -2
- package/src/components/wallet/lib/index.ts +2 -2
- package/src/components/wallet/table/ConnectedWalletsTable.tsx +6 -6
- package/src/components/wallet/table/ConnectedWalletsTableRow.tsx +3 -3
- package/src/components/wallet/table/cells/Accounts.tsx +2 -1
- package/src/components/wallet/table/cells/Actions.tsx +21 -15
- package/src/components/wallet/table/cells/Cells.tsx +6 -6
- package/src/components/wallet/table/cells/ChainName.tsx +2 -1
- package/src/components/wallet/table/cells/State.tsx +4 -3
- package/src/components/wallet/table/cells/Wallet.tsx +2 -1
- package/src/components/wallet/table/cells/index.ts +6 -6
- package/src/components/wallet/table/cells/lib/index.ts +1 -1
- package/src/components/wallet/table/hooks/index.ts +1 -1
- package/src/components/wallet/table/hooks/useActiveProviderDialogState.tsx +1 -1
- package/src/components/wallet/table/index.ts +4 -4
- package/src/hooks/index.ts +2 -2
- package/src/hooks/useDetectWallets.tsx +2 -1
- package/src/hooks/useEnabledWallets.tsx +1 -1
- package/src/index.ts +3 -3
- package/dist/browser/index.js +0 -542
- package/dist/browser/index.js.map +0 -1
- package/dist/neutral/index.js +0 -542
- package/dist/neutral/index.js.map +0 -1
- package/dist/node/index.js +0 -553
- package/dist/node/index.js.map +0 -1
package/dist/browser/index.cjs
CHANGED
@@ -5,6 +5,7 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
6
6
|
var __getProtoOf = Object.getPrototypeOf;
|
7
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
8
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
8
9
|
var __export = (target, all) => {
|
9
10
|
for (var name in all)
|
10
11
|
__defProp(target, name, { get: all[name], enumerable: true });
|
@@ -53,6 +54,9 @@ module.exports = __toCommonJS(src_exports);
|
|
53
54
|
// src/classes/EnabledWallets.ts
|
54
55
|
var DEFAULT_LOCAL_STORAGE_KEY = "XYO|EnabledWallets";
|
55
56
|
var EnabledEthWalletConnections = class {
|
57
|
+
static {
|
58
|
+
__name(this, "EnabledEthWalletConnections");
|
59
|
+
}
|
56
60
|
// control whether or not enabled/disabled preferences are persisted (i.e. in localStorage)
|
57
61
|
persistPreferences = true;
|
58
62
|
// Map of wallet names and their enabled/disabled state
|
@@ -77,23 +81,26 @@ var EnabledEthWalletConnections = class {
|
|
77
81
|
this.toggleEnabledWallet(rdns, true);
|
78
82
|
}
|
79
83
|
/**
|
80
|
-
|
81
|
-
|
84
|
+
* Given a new set of wallets, set their enabled state based off previous preferences
|
85
|
+
*/
|
82
86
|
resetWallets(wallets) {
|
83
87
|
const newWallets = {};
|
84
|
-
const addWallet = ([walletName, wallet]) => {
|
88
|
+
const addWallet = /* @__PURE__ */ __name(([walletName, wallet]) => {
|
85
89
|
newWallets[walletName] = {
|
86
90
|
// preserve the existing enabled state
|
87
91
|
enabled: walletName in this.enabledWallets ? this.enabledWallets[walletName] : true,
|
88
92
|
wallet
|
89
93
|
};
|
90
|
-
};
|
94
|
+
}, "addWallet");
|
91
95
|
Object.entries(wallets).forEach(addWallet.bind(this));
|
92
96
|
this.ethWalletsState = newWallets;
|
93
97
|
this.emitChange();
|
94
98
|
}
|
95
99
|
subscribe(listener) {
|
96
|
-
this.listeners = [
|
100
|
+
this.listeners = [
|
101
|
+
...this.listeners,
|
102
|
+
listener
|
103
|
+
];
|
97
104
|
return () => {
|
98
105
|
this.listeners = this.listeners.filter((existingListener) => existingListener !== listener);
|
99
106
|
};
|
@@ -101,7 +108,9 @@ var EnabledEthWalletConnections = class {
|
|
101
108
|
toggleEnabledWallet(rdns, enabled) {
|
102
109
|
if (rdns && this.ethWalletsState[rdns]) {
|
103
110
|
this.ethWalletsState[rdns].enabled = enabled;
|
104
|
-
this.ethWalletsState = {
|
111
|
+
this.ethWalletsState = {
|
112
|
+
...this.ethWalletsState
|
113
|
+
};
|
105
114
|
this.emitChange();
|
106
115
|
}
|
107
116
|
}
|
@@ -141,264 +150,317 @@ var EnabledEthWalletConnections = class {
|
|
141
150
|
// src/components/ConnectedAccountsFlexbox.tsx
|
142
151
|
var import_material13 = require("@mui/material");
|
143
152
|
var import_react_flexbox6 = require("@xylabs/react-flexbox");
|
144
|
-
var
|
153
|
+
var import_react16 = __toESM(require("react"), 1);
|
145
154
|
|
146
155
|
// src/hooks/useDetectWallets.tsx
|
147
156
|
var import_react_crypto = require("@xylabs/react-crypto");
|
148
157
|
var import_react = require("react");
|
149
|
-
var sortWallets = (wallets) => (
|
158
|
+
var sortWallets = /* @__PURE__ */ __name((wallets) => (
|
150
159
|
// eslint-disable-next-line unicorn/no-array-reduce
|
151
160
|
Object.values(wallets).reduce((acc, wallet) => {
|
152
161
|
wallet.allowedAccounts.length > 0 ? acc.unshift(wallet) : acc.push(wallet);
|
153
162
|
return acc;
|
154
163
|
}, [])
|
155
|
-
);
|
156
|
-
var useDetectedWallets = () => {
|
164
|
+
), "sortWallets");
|
165
|
+
var useDetectedWallets = /* @__PURE__ */ __name(() => {
|
157
166
|
const wallets = (0, import_react_crypto.useWalletDiscovery)();
|
158
167
|
const [refresh, setRefresh] = (0, import_react.useState)(0);
|
159
168
|
const [sortedWallets, setSortedWallets] = (0, import_react.useState)([]);
|
160
169
|
(0, import_react.useEffect)(() => {
|
161
170
|
setSortedWallets(sortWallets(wallets));
|
162
|
-
}, [
|
171
|
+
}, [
|
172
|
+
wallets,
|
173
|
+
refresh
|
174
|
+
]);
|
163
175
|
(0, import_react.useEffect)(() => {
|
164
|
-
const listener = () => {
|
176
|
+
const listener = /* @__PURE__ */ __name(() => {
|
165
177
|
setRefresh((refresh2) => refresh2 + 1);
|
166
|
-
};
|
178
|
+
}, "listener");
|
167
179
|
window.addEventListener(import_react_crypto.AccountsChangedEventName, listener);
|
168
180
|
return () => {
|
169
181
|
window.removeEventListener(import_react_crypto.AccountsChangedEventName, listener);
|
170
182
|
};
|
171
|
-
}, [
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
183
|
+
}, [
|
184
|
+
wallets
|
185
|
+
]);
|
186
|
+
const totalConnectedAccounts = (0, import_react.useMemo)(() => Object.values(sortedWallets).reduce((acc, wallet) => acc + wallet.allowedAccounts.length, 0), [
|
187
|
+
sortedWallets
|
188
|
+
]);
|
189
|
+
return {
|
190
|
+
sortedWallets,
|
191
|
+
totalConnectedAccounts
|
192
|
+
};
|
193
|
+
}, "useDetectedWallets");
|
178
194
|
|
179
195
|
// src/hooks/useEnabledWallets.tsx
|
180
196
|
var import_react_crypto2 = require("@xylabs/react-crypto");
|
181
197
|
var import_react2 = require("react");
|
182
198
|
var enabledEthWallets;
|
183
|
-
var useEnabledWalletsInner = (enabledWalletsRdns) => {
|
199
|
+
var useEnabledWalletsInner = /* @__PURE__ */ __name((enabledWalletsRdns) => {
|
184
200
|
const discoveredWallets = (0, import_react_crypto2.useWalletDiscovery)();
|
185
201
|
const wallets = (0, import_react2.useMemo)(() => {
|
186
202
|
if (enabledEthWallets === void 0) enabledEthWallets = new EnabledEthWalletConnections();
|
187
203
|
enabledEthWallets.resetWallets(discoveredWallets);
|
188
204
|
for (const [rdns, enabled] of Object.entries(enabledWalletsRdns ?? {})) enabledEthWallets?.toggleEnabledWallet(rdns, enabled);
|
189
205
|
return enabledEthWallets;
|
190
|
-
}, [
|
206
|
+
}, [
|
207
|
+
discoveredWallets,
|
208
|
+
enabledWalletsRdns
|
209
|
+
]);
|
191
210
|
return (0, import_react2.useSyncExternalStore)(wallets.subscribe.bind(wallets), () => wallets.wallets);
|
192
|
-
};
|
193
|
-
var useEnabledWallets = (enabledWalletsRdns) => {
|
211
|
+
}, "useEnabledWalletsInner");
|
212
|
+
var useEnabledWallets = /* @__PURE__ */ __name((enabledWalletsRdns) => {
|
194
213
|
const wallets = useEnabledWalletsInner(enabledWalletsRdns);
|
195
|
-
const enabledWallets = (0, import_react2.useMemo)(
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
);
|
214
|
+
const enabledWallets = (0, import_react2.useMemo)(() => (
|
215
|
+
// eslint-disable-next-line unicorn/no-array-reduce
|
216
|
+
Object.entries(wallets).reduce((acc, [walletName, wallet]) => {
|
217
|
+
if (wallet.enabled) acc[walletName] = wallet;
|
218
|
+
return acc;
|
219
|
+
}, {})
|
220
|
+
), [
|
221
|
+
wallets
|
222
|
+
]);
|
205
223
|
return {
|
206
224
|
disableWallet: enabledEthWallets?.disableWallet.bind(enabledEthWallets),
|
207
225
|
enableWallet: enabledEthWallets?.enableWallet.bind(enabledEthWallets),
|
208
226
|
enabledWallets,
|
209
227
|
wallets
|
210
228
|
};
|
211
|
-
};
|
229
|
+
}, "useEnabledWallets");
|
212
230
|
|
213
231
|
// src/components/wallet/dialogs/connect/CheckboxFormControl.tsx
|
214
232
|
var import_material = require("@mui/material");
|
215
|
-
var
|
216
|
-
var CheckboxFormControl = ({ onCheckChanged, ...props }) => {
|
217
|
-
return /* @__PURE__ */
|
218
|
-
/* @__PURE__ */ (
|
219
|
-
|
220
|
-
|
221
|
-
};
|
233
|
+
var import_react3 = __toESM(require("react"), 1);
|
234
|
+
var CheckboxFormControl = /* @__PURE__ */ __name(({ onCheckChanged, ...props }) => {
|
235
|
+
return /* @__PURE__ */ import_react3.default.createElement(import_material.FormControl, props, /* @__PURE__ */ import_react3.default.createElement(import_material.FormLabel, null, /* @__PURE__ */ import_react3.default.createElement(import_material.Checkbox, {
|
236
|
+
onChange: /* @__PURE__ */ __name((_, checked) => onCheckChanged?.(checked), "onChange")
|
237
|
+
}), "Do not show this again."));
|
238
|
+
}, "CheckboxFormControl");
|
222
239
|
|
223
240
|
// src/components/wallet/dialogs/connect/Dialog.tsx
|
224
241
|
var import_material4 = require("@mui/material");
|
242
|
+
var import_react6 = __toESM(require("react"), 1);
|
225
243
|
|
226
244
|
// src/components/wallet/dialogs/connect/LinkedProvidersFlexbox.tsx
|
227
245
|
var import_icons_material = require("@mui/icons-material");
|
228
246
|
var import_material2 = require("@mui/material");
|
229
247
|
var import_react_crypto3 = require("@xylabs/react-crypto");
|
230
248
|
var import_react_flexbox = require("@xylabs/react-flexbox");
|
249
|
+
var import_react4 = __toESM(require("react"), 1);
|
231
250
|
|
232
251
|
// src/img/index.ts
|
233
252
|
var import_xyo_color_logo = __toESM(require("./xyo-color-logo-LHR2SMEM.svg"), 1);
|
234
253
|
var import_xyo_color_logo_text_only = __toESM(require("./xyo-color-logo-text-only-QPAW5BSQ.svg"), 1);
|
235
254
|
|
236
255
|
// src/components/wallet/dialogs/connect/LinkedProvidersFlexbox.tsx
|
237
|
-
var
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
}
|
256
|
+
var LinkedProvidersFlexbox = /* @__PURE__ */ __name(({ icon, providerName, ...props }) => {
|
257
|
+
return /* @__PURE__ */ import_react4.default.createElement(import_react_flexbox.FlexRow, {
|
258
|
+
gap: 4,
|
259
|
+
justifyContent: "space-evenly",
|
260
|
+
...props
|
261
|
+
}, /* @__PURE__ */ import_react4.default.createElement(import_react_flexbox.FlexCol, {
|
262
|
+
gap: 0.5
|
263
|
+
}, /* @__PURE__ */ import_react4.default.createElement("img", {
|
264
|
+
alt: "XYO Logo",
|
265
|
+
src: import_xyo_color_logo.default,
|
266
|
+
style: {
|
267
|
+
height: "48px"
|
268
|
+
}
|
269
|
+
}), /* @__PURE__ */ import_react4.default.createElement(import_material2.Typography, {
|
270
|
+
variant: "subtitle1"
|
271
|
+
}, "XYO App")), /* @__PURE__ */ import_react4.default.createElement(import_icons_material.SyncAlt, {
|
272
|
+
fontSize: "large"
|
273
|
+
}), /* @__PURE__ */ import_react4.default.createElement(import_react_flexbox.FlexCol, {
|
274
|
+
gap: 0.5
|
275
|
+
}, /* @__PURE__ */ import_react4.default.createElement(import_react_crypto3.ConstrainedImage, {
|
276
|
+
constrainedValue: "48px",
|
277
|
+
src: icon,
|
278
|
+
alt: providerName,
|
279
|
+
style: {
|
280
|
+
height: "48px",
|
281
|
+
maxWidth: "48px"
|
282
|
+
}
|
283
|
+
}), /* @__PURE__ */ import_react4.default.createElement(import_material2.Typography, {
|
284
|
+
variant: "subtitle1"
|
285
|
+
}, providerName)));
|
286
|
+
}, "LinkedProvidersFlexbox");
|
251
287
|
|
252
288
|
// src/components/wallet/dialogs/connect/Permissions.tsx
|
253
289
|
var import_material3 = require("@mui/material");
|
254
290
|
var import_react_flexbox2 = require("@xylabs/react-flexbox");
|
255
|
-
var
|
256
|
-
var WalletPermissionsFlexbox = (props) => {
|
257
|
-
return /* @__PURE__ */
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
};
|
291
|
+
var import_react5 = __toESM(require("react"), 1);
|
292
|
+
var WalletPermissionsFlexbox = /* @__PURE__ */ __name((props) => {
|
293
|
+
return /* @__PURE__ */ import_react5.default.createElement(import_react_flexbox2.FlexCol, {
|
294
|
+
gap: 4,
|
295
|
+
...props
|
296
|
+
}, /* @__PURE__ */ import_react5.default.createElement(import_material3.Typography, {
|
297
|
+
fontWeight: "bold",
|
298
|
+
sx: {
|
299
|
+
textAlign: "center"
|
300
|
+
}
|
301
|
+
}, "This will allow XYO to:"), /* @__PURE__ */ import_react5.default.createElement("ul", null, /* @__PURE__ */ import_react5.default.createElement("li", null, "View your wallet account(s) and address(es)"), /* @__PURE__ */ import_react5.default.createElement("li", null, "Read-only access to browse the public blockchain(s) you select")), /* @__PURE__ */ import_react5.default.createElement(import_material3.Typography, {
|
302
|
+
variant: "subtitle1",
|
303
|
+
sx: {
|
304
|
+
textAlign: "center"
|
305
|
+
}
|
306
|
+
}, "You control what accounts to share and what blockchains to view. You can see or revoke access via your wallet's settings at anytime. View more on XYO's sovereign data philosophy", " ", /* @__PURE__ */ import_react5.default.createElement(import_material3.Link, {
|
307
|
+
href: "https://cointelegraph.com/innovation-circle/decentralization-and-sovereignty-debunking-our-approach-to-digital-sovereignty",
|
308
|
+
sx: {
|
309
|
+
fontWeight: "bold"
|
310
|
+
},
|
311
|
+
target: "_blank"
|
312
|
+
}, "here"), "."));
|
313
|
+
}, "WalletPermissionsFlexbox");
|
279
314
|
|
280
315
|
// src/components/wallet/dialogs/connect/Dialog.tsx
|
281
|
-
var
|
282
|
-
var ConnectWalletDialog = ({ activeProvider, onIgnoreConnectDialog, ...props }) => {
|
316
|
+
var ConnectWalletDialog = /* @__PURE__ */ __name(({ activeProvider, onIgnoreConnectDialog, ...props }) => {
|
283
317
|
const { icon, providerName } = activeProvider ?? {};
|
284
|
-
const onConnect = async () => {
|
318
|
+
const onConnect = /* @__PURE__ */ __name(async () => {
|
285
319
|
try {
|
286
320
|
await activeProvider?.connectWallet?.();
|
287
321
|
props.onClose?.({}, "escapeKeyDown");
|
288
322
|
} catch (e) {
|
289
323
|
console.warn(`Error connecting to wallet: ${e.message}`);
|
290
324
|
}
|
291
|
-
};
|
292
|
-
return /* @__PURE__ */
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
}
|
325
|
+
}, "onConnect");
|
326
|
+
return /* @__PURE__ */ import_react6.default.createElement(import_material4.Dialog, {
|
327
|
+
PaperProps: {
|
328
|
+
sx: {
|
329
|
+
display: "flex",
|
330
|
+
gap: 4
|
331
|
+
}
|
332
|
+
},
|
333
|
+
...props
|
334
|
+
}, /* @__PURE__ */ import_react6.default.createElement(import_material4.DialogTitle, {
|
335
|
+
sx: {
|
336
|
+
textAlign: "center"
|
337
|
+
}
|
338
|
+
}, "XYO Wants To Access The Blockchain on Your Behalf"), /* @__PURE__ */ import_react6.default.createElement(import_material4.DialogContent, {
|
339
|
+
sx: {
|
340
|
+
display: "flex",
|
341
|
+
flexDirection: "column",
|
342
|
+
gap: 4
|
343
|
+
}
|
344
|
+
}, /* @__PURE__ */ import_react6.default.createElement(LinkedProvidersFlexbox, {
|
345
|
+
icon,
|
346
|
+
providerName
|
347
|
+
}), /* @__PURE__ */ import_react6.default.createElement(WalletPermissionsFlexbox, null), /* @__PURE__ */ import_react6.default.createElement(CheckboxFormControl, {
|
348
|
+
onCheckChanged: onIgnoreConnectDialog
|
349
|
+
})), /* @__PURE__ */ import_react6.default.createElement(import_material4.DialogActions, null, /* @__PURE__ */ import_react6.default.createElement(import_material4.Button, {
|
350
|
+
variant: "outlined",
|
351
|
+
onClick: /* @__PURE__ */ __name(() => props.onClose?.({}, "escapeKeyDown"), "onClick")
|
352
|
+
}, "Close"), /* @__PURE__ */ import_react6.default.createElement(import_material4.Button, {
|
353
|
+
variant: "contained",
|
354
|
+
onClick: onConnect
|
355
|
+
}, "Connect")));
|
356
|
+
}, "ConnectWalletDialog");
|
305
357
|
|
306
358
|
// src/components/wallet/dialogs/revoke/Dialog.tsx
|
307
359
|
var import_material5 = require("@mui/material");
|
308
360
|
var import_react_crypto4 = require("@xylabs/react-crypto");
|
309
361
|
var import_react_flexbox3 = require("@xylabs/react-flexbox");
|
310
|
-
var
|
311
|
-
var RevokeWalletConnectionDialog = ({ activeProvider, ...props }) => {
|
312
|
-
return /* @__PURE__ */
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
] }),
|
329
|
-
/* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_material5.DialogActions, { children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_material5.Button, { variant: "contained", onClick: () => props.onClose?.({}, "escapeKeyDown"), children: "Close" }) })
|
330
|
-
] });
|
331
|
-
};
|
362
|
+
var import_react7 = __toESM(require("react"), 1);
|
363
|
+
var RevokeWalletConnectionDialog = /* @__PURE__ */ __name(({ activeProvider, ...props }) => {
|
364
|
+
return /* @__PURE__ */ import_react7.default.createElement(import_material5.Dialog, props, /* @__PURE__ */ import_react7.default.createElement(import_react_flexbox3.FlexRow, {
|
365
|
+
gap: 2,
|
366
|
+
justifyContent: "start",
|
367
|
+
pl: 2
|
368
|
+
}, /* @__PURE__ */ import_react7.default.createElement(import_react_crypto4.ConstrainedImage, {
|
369
|
+
src: activeProvider?.icon,
|
370
|
+
constrainedValue: "24px"
|
371
|
+
}), /* @__PURE__ */ import_react7.default.createElement(import_material5.DialogTitle, {
|
372
|
+
sx: {
|
373
|
+
pl: 0
|
374
|
+
}
|
375
|
+
}, "Revoke", activeProvider?.providerName, " ", "Access")), /* @__PURE__ */ import_react7.default.createElement(import_material5.DialogContent, null, /* @__PURE__ */ import_react7.default.createElement(import_material5.Typography, null, "Revoking access to your wallet must be done from the wallet's browser extension. Wallets grant access to specific domains please consult", " ", activeProvider?.providerName, "'s documentation on how to revoke access to this website:"), /* @__PURE__ */ import_react7.default.createElement(import_material5.Typography, null, window.location.origin)), /* @__PURE__ */ import_react7.default.createElement(import_material5.DialogActions, null, /* @__PURE__ */ import_react7.default.createElement(import_material5.Button, {
|
376
|
+
variant: "contained",
|
377
|
+
onClick: /* @__PURE__ */ __name(() => props.onClose?.({}, "escapeKeyDown"), "onClick")
|
378
|
+
}, "Close")));
|
379
|
+
}, "RevokeWalletConnectionDialog");
|
332
380
|
|
333
381
|
// src/components/wallet/table/cells/Accounts.tsx
|
334
382
|
var import_material6 = require("@mui/material");
|
335
|
-
var
|
336
|
-
var ConnectedWalletsAccountsTableCell = ({
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
{
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
) });
|
350
|
-
};
|
383
|
+
var import_react8 = __toESM(require("react"), 1);
|
384
|
+
var ConnectedWalletsAccountsTableCell = /* @__PURE__ */ __name(({ additionalAccounts, currentAccount, totalAccounts, tableCellProps }) => {
|
385
|
+
return /* @__PURE__ */ import_react8.default.createElement(import_material6.TableCell, tableCellProps, /* @__PURE__ */ import_react8.default.createElement(import_material6.Tooltip, {
|
386
|
+
sx: {
|
387
|
+
cursor: totalAccounts > 0 ? "pointer" : "auto"
|
388
|
+
},
|
389
|
+
title: [
|
390
|
+
...currentAccount ?? [],
|
391
|
+
...additionalAccounts ?? []
|
392
|
+
].map((address, index) => /* @__PURE__ */ import_react8.default.createElement("p", {
|
393
|
+
key: index
|
394
|
+
}, address))
|
395
|
+
}, /* @__PURE__ */ import_react8.default.createElement(import_material6.Typography, null, totalAccounts)));
|
396
|
+
}, "ConnectedWalletsAccountsTableCell");
|
351
397
|
|
352
398
|
// src/components/wallet/table/cells/Actions.tsx
|
353
399
|
var import_icons_material2 = require("@mui/icons-material");
|
354
400
|
var import_material7 = require("@mui/material");
|
355
401
|
var import_react_flexbox4 = require("@xylabs/react-flexbox");
|
356
|
-
var
|
357
|
-
var ConnectedWalletsActionsTableCell = ({ connected, onConnect, onRevoke, tableCellProps }) => {
|
358
|
-
return /* @__PURE__ */
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
}
|
402
|
+
var import_react9 = __toESM(require("react"), 1);
|
403
|
+
var ConnectedWalletsActionsTableCell = /* @__PURE__ */ __name(({ connected, onConnect, onRevoke, tableCellProps }) => {
|
404
|
+
return /* @__PURE__ */ import_react9.default.createElement(import_material7.TableCell, tableCellProps, /* @__PURE__ */ import_react9.default.createElement(import_react_flexbox4.FlexRow, {
|
405
|
+
gap: 2,
|
406
|
+
justifyContent: "start"
|
407
|
+
}, connected ? /* @__PURE__ */ import_react9.default.createElement(import_material7.Typography, {
|
408
|
+
sx: {
|
409
|
+
display: "inline-flex",
|
410
|
+
gap: 0.5
|
411
|
+
}
|
412
|
+
}, /* @__PURE__ */ import_react9.default.createElement(import_icons_material2.Check, null), "Connected") : /* @__PURE__ */ import_react9.default.createElement(import_material7.Button, {
|
413
|
+
variant: "contained",
|
414
|
+
onClick: onConnect
|
415
|
+
}, "Connect"), connected ? /* @__PURE__ */ import_react9.default.createElement(import_material7.IconButton, {
|
416
|
+
onClick: onRevoke
|
417
|
+
}, /* @__PURE__ */ import_react9.default.createElement(import_icons_material2.InfoOutlined, null)) : null));
|
418
|
+
}, "ConnectedWalletsActionsTableCell");
|
366
419
|
|
367
420
|
// src/components/wallet/table/cells/ChainName.tsx
|
368
421
|
var import_material8 = require("@mui/material");
|
369
|
-
var
|
370
|
-
var ConnectedWalletsChainNameTableCell = ({ chainName, tableCellProps }) => {
|
371
|
-
return /* @__PURE__ */
|
372
|
-
};
|
422
|
+
var import_react10 = __toESM(require("react"), 1);
|
423
|
+
var ConnectedWalletsChainNameTableCell = /* @__PURE__ */ __name(({ chainName, tableCellProps }) => {
|
424
|
+
return /* @__PURE__ */ import_react10.default.createElement(import_material8.TableCell, tableCellProps, chainName);
|
425
|
+
}, "ConnectedWalletsChainNameTableCell");
|
373
426
|
|
374
427
|
// src/components/wallet/table/cells/State.tsx
|
375
428
|
var import_material9 = require("@mui/material");
|
376
|
-
var
|
377
|
-
var
|
378
|
-
var ConnectedWalletState = ({ connected, walletRdns, tableCellProps }) => {
|
429
|
+
var import_react11 = __toESM(require("react"), 1);
|
430
|
+
var ConnectedWalletState = /* @__PURE__ */ __name(({ connected, walletRdns, tableCellProps }) => {
|
379
431
|
const { disableWallet, enableWallet, wallets } = useEnabledWallets();
|
380
|
-
const enabled = (0,
|
381
|
-
|
432
|
+
const enabled = (0, import_react11.useMemo)(() => walletRdns ? wallets[walletRdns].enabled : false, [
|
433
|
+
wallets,
|
434
|
+
walletRdns
|
435
|
+
]);
|
436
|
+
const handleClick = /* @__PURE__ */ __name((event) => {
|
382
437
|
const checked = event.target?.checked;
|
383
438
|
if (walletRdns) {
|
384
439
|
checked ? enableWallet?.(walletRdns) : disableWallet?.(walletRdns);
|
385
440
|
}
|
386
|
-
};
|
387
|
-
return /* @__PURE__ */
|
388
|
-
|
441
|
+
}, "handleClick");
|
442
|
+
return /* @__PURE__ */ import_react11.default.createElement(import_material9.TableCell, tableCellProps, /* @__PURE__ */ import_react11.default.createElement(import_material9.Switch, {
|
443
|
+
disabled: !connected,
|
444
|
+
checked: connected && enabled,
|
445
|
+
onChange: handleClick
|
446
|
+
}));
|
447
|
+
}, "ConnectedWalletState");
|
389
448
|
|
390
449
|
// src/components/wallet/table/cells/Wallet.tsx
|
391
450
|
var import_material10 = require("@mui/material");
|
392
451
|
var import_react_crypto5 = require("@xylabs/react-crypto");
|
393
452
|
var import_react_flexbox5 = require("@xylabs/react-flexbox");
|
394
|
-
var
|
395
|
-
var ConnectedWalletsWalletTableCell = ({ icon, walletName, tableCellProps }) => {
|
453
|
+
var import_react12 = __toESM(require("react"), 1);
|
454
|
+
var ConnectedWalletsWalletTableCell = /* @__PURE__ */ __name(({ icon, walletName, tableCellProps }) => {
|
396
455
|
const theme = (0, import_material10.useTheme)();
|
397
|
-
return /* @__PURE__ */
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
456
|
+
return /* @__PURE__ */ import_react12.default.createElement(import_material10.TableCell, tableCellProps, /* @__PURE__ */ import_react12.default.createElement(import_react_flexbox5.FlexRow, {
|
457
|
+
gap: 2,
|
458
|
+
justifyContent: "start"
|
459
|
+
}, /* @__PURE__ */ import_react12.default.createElement(import_react_crypto5.ConstrainedImage, {
|
460
|
+
constrainedValue: theme.spacing(4),
|
461
|
+
src: icon
|
462
|
+
}), walletName));
|
463
|
+
}, "ConnectedWalletsWalletTableCell");
|
402
464
|
|
403
465
|
// src/components/wallet/table/cells/Cells.tsx
|
404
466
|
var ConnectedWalletTableCells = [
|
@@ -411,7 +473,7 @@ var ConnectedWalletTableCells = [
|
|
411
473
|
|
412
474
|
// src/components/wallet/table/ConnectedWalletsTable.tsx
|
413
475
|
var import_material12 = require("@mui/material");
|
414
|
-
var
|
476
|
+
var import_react15 = __toESM(require("react"), 1);
|
415
477
|
|
416
478
|
// src/components/wallet/lib/TableHeadData.ts
|
417
479
|
var WalletsTableHeadCells = [
|
@@ -455,121 +517,138 @@ var WalletsTableHeadCells = [
|
|
455
517
|
// src/components/wallet/table/ConnectedWalletsTableRow.tsx
|
456
518
|
var import_material11 = require("@mui/material");
|
457
519
|
var import_react_crypto6 = require("@xylabs/react-crypto");
|
458
|
-
var
|
459
|
-
var
|
460
|
-
var WalletConnectionsTableRow = ({
|
461
|
-
ignoreConnectDialog,
|
462
|
-
onConnectClick,
|
463
|
-
onRevoke,
|
464
|
-
wallet,
|
465
|
-
...props
|
466
|
-
}) => {
|
520
|
+
var import_react13 = __toESM(require("react"), 1);
|
521
|
+
var WalletConnectionsTableRow = /* @__PURE__ */ __name(({ ignoreConnectDialog, onConnectClick, onRevoke, wallet, ...props }) => {
|
467
522
|
const { currentAccount: currentAccountFromWallet, additionalAccounts, chainName, connectWallet, providerInfo } = (0, import_react_crypto6.useEthWallet)(wallet);
|
468
|
-
const currentAccount = currentAccountFromWallet?.toString() ? [
|
523
|
+
const currentAccount = currentAccountFromWallet?.toString() ? [
|
524
|
+
currentAccountFromWallet.toString()
|
525
|
+
] : [];
|
469
526
|
const totalAccounts = (additionalAccounts?.length ?? 0) + (currentAccount?.length ?? 0);
|
470
527
|
const connected = !!(currentAccount?.length ?? 0 > 0);
|
471
|
-
const { icon, name, rdns } = (0,
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
528
|
+
const { icon, name, rdns } = (0, import_react13.useMemo)(() => providerInfo ?? {
|
529
|
+
icon: void 0,
|
530
|
+
name: void 0,
|
531
|
+
rdns: void 0
|
532
|
+
}, [
|
533
|
+
providerInfo
|
534
|
+
]);
|
535
|
+
const activeProvider = (0, import_react13.useMemo)(() => ({
|
536
|
+
connectWallet,
|
537
|
+
icon,
|
538
|
+
providerName: name
|
539
|
+
}), [
|
540
|
+
connectWallet,
|
541
|
+
icon,
|
542
|
+
name
|
543
|
+
]);
|
544
|
+
const onRevokeLocal = (0, import_react13.useCallback)(() => {
|
481
545
|
onRevoke?.(activeProvider);
|
482
|
-
}, [
|
483
|
-
|
546
|
+
}, [
|
547
|
+
activeProvider,
|
548
|
+
onRevoke
|
549
|
+
]);
|
550
|
+
const onConnectLocal = (0, import_react13.useCallback)(async () => {
|
484
551
|
if (ignoreConnectDialog) {
|
485
552
|
await connectWallet?.();
|
486
553
|
} else {
|
487
554
|
onConnectClick?.(activeProvider);
|
488
555
|
}
|
489
|
-
}, [
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
|
506
|
-
|
556
|
+
}, [
|
557
|
+
activeProvider,
|
558
|
+
connectWallet,
|
559
|
+
ignoreConnectDialog,
|
560
|
+
onConnectClick
|
561
|
+
]);
|
562
|
+
return /* @__PURE__ */ import_react13.default.createElement(import_material11.TableRow, props, Object.values(ConnectedWalletTableCells).map((Cell, index) => /* @__PURE__ */ import_react13.default.createElement(Cell, {
|
563
|
+
key: index,
|
564
|
+
additionalAccounts,
|
565
|
+
chainName,
|
566
|
+
connected,
|
567
|
+
currentAccount,
|
568
|
+
icon,
|
569
|
+
onConnect: onConnectLocal,
|
570
|
+
onRevoke: onRevokeLocal,
|
571
|
+
totalAccounts,
|
572
|
+
walletName: name,
|
573
|
+
walletRdns: rdns
|
574
|
+
})));
|
575
|
+
}, "WalletConnectionsTableRow");
|
507
576
|
|
508
577
|
// src/components/wallet/table/hooks/useActiveProviderDialogState.tsx
|
509
|
-
var
|
510
|
-
var useActiveProviderDialogState = (setActiveProvider) => {
|
511
|
-
const [show, setShow] = (0,
|
512
|
-
const onSetActiveProvider = (activeProvider) => {
|
578
|
+
var import_react14 = require("react");
|
579
|
+
var useActiveProviderDialogState = /* @__PURE__ */ __name((setActiveProvider) => {
|
580
|
+
const [show, setShow] = (0, import_react14.useState)(false);
|
581
|
+
const onSetActiveProvider = /* @__PURE__ */ __name((activeProvider) => {
|
513
582
|
setShow(true);
|
514
583
|
setActiveProvider(activeProvider);
|
515
|
-
};
|
516
|
-
const onClose = () => {
|
584
|
+
}, "onSetActiveProvider");
|
585
|
+
const onClose = /* @__PURE__ */ __name(() => {
|
517
586
|
setShow(false);
|
518
587
|
setActiveProvider({});
|
519
|
-
};
|
520
|
-
return [
|
521
|
-
|
588
|
+
}, "onClose");
|
589
|
+
return [
|
590
|
+
show,
|
591
|
+
onSetActiveProvider,
|
592
|
+
onClose
|
593
|
+
];
|
594
|
+
}, "useActiveProviderDialogState");
|
522
595
|
|
523
596
|
// src/components/wallet/table/ConnectedWalletsTable.tsx
|
524
|
-
var
|
525
|
-
|
526
|
-
const [activeProvider, setActiveProvider] = (0, import_react6.useState)();
|
597
|
+
var ConnectedWalletsTable = /* @__PURE__ */ __name(({ ignoreConnectDialog, onIgnoreConnectDialog, wallets, ...props }) => {
|
598
|
+
const [activeProvider, setActiveProvider] = (0, import_react15.useState)();
|
527
599
|
const [showConnect, onSetActiveProviderConnect, onConnectClose] = useActiveProviderDialogState(setActiveProvider);
|
528
600
|
const [showRevoke, onSetActiveProviderRevoke, onRevokeClose] = useActiveProviderDialogState(setActiveProvider);
|
529
|
-
return /* @__PURE__ */ (
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
-
|
550
|
-
|
551
|
-
}
|
552
|
-
)
|
553
|
-
] });
|
554
|
-
};
|
601
|
+
return /* @__PURE__ */ import_react15.default.createElement(import_react15.default.Fragment, null, /* @__PURE__ */ import_react15.default.createElement(import_material12.Table, props, /* @__PURE__ */ import_react15.default.createElement(import_material12.TableHead, null, /* @__PURE__ */ import_react15.default.createElement(import_material12.TableRow, null, WalletsTableHeadCells.map(({ disablePadding, id, label, align, width }) => /* @__PURE__ */ import_react15.default.createElement(import_material12.TableCell, {
|
602
|
+
align,
|
603
|
+
key: id,
|
604
|
+
padding: disablePadding ? "none" : "normal",
|
605
|
+
width: width ?? "auto"
|
606
|
+
}, label)))), /* @__PURE__ */ import_react15.default.createElement(import_material12.TableBody, null, (wallets ?? []).map((wallet) => /* @__PURE__ */ import_react15.default.createElement(WalletConnectionsTableRow, {
|
607
|
+
ignoreConnectDialog,
|
608
|
+
key: wallet.providerInfo?.rdns,
|
609
|
+
onConnectClick: onSetActiveProviderConnect,
|
610
|
+
onRevoke: onSetActiveProviderRevoke,
|
611
|
+
wallet
|
612
|
+
})))), /* @__PURE__ */ import_react15.default.createElement(RevokeWalletConnectionDialog, {
|
613
|
+
open: showRevoke,
|
614
|
+
onClose: onRevokeClose,
|
615
|
+
activeProvider
|
616
|
+
}), /* @__PURE__ */ import_react15.default.createElement(ConnectWalletDialog, {
|
617
|
+
activeProvider,
|
618
|
+
onClose: onConnectClose,
|
619
|
+
open: showConnect,
|
620
|
+
onIgnoreConnectDialog
|
621
|
+
}));
|
622
|
+
}, "ConnectedWalletsTable");
|
555
623
|
|
556
624
|
// src/components/ConnectedAccountsFlexbox.tsx
|
557
|
-
var
|
558
|
-
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
|
571
|
-
|
572
|
-
|
573
|
-
)
|
625
|
+
var ConnectedAccountsFlexbox = /* @__PURE__ */ (0, import_react16.forwardRef)(({ ignoreConnectDialog, onIgnoreConnectDialog, ...props }, ref) => {
|
626
|
+
const theme = (0, import_material13.useTheme)();
|
627
|
+
const { totalConnectedAccounts, sortedWallets } = useDetectedWallets();
|
628
|
+
return /* @__PURE__ */ import_react16.default.createElement(import_react_flexbox6.FlexCol, {
|
629
|
+
alignItems: "stretch",
|
630
|
+
justifyContent: "start",
|
631
|
+
gap: 2,
|
632
|
+
ref,
|
633
|
+
...props
|
634
|
+
}, /* @__PURE__ */ import_react16.default.createElement(import_react_flexbox6.FlexCol, {
|
635
|
+
alignItems: "start"
|
636
|
+
}, /* @__PURE__ */ import_react16.default.createElement(import_material13.Typography, {
|
637
|
+
variant: "h2",
|
638
|
+
sx: {
|
639
|
+
mb: 0.5
|
640
|
+
}
|
641
|
+
}, "Detected Web3 Wallets"), totalConnectedAccounts ? /* @__PURE__ */ import_react16.default.createElement(import_material13.Typography, {
|
642
|
+
variant: "subtitle1",
|
643
|
+
color: theme.palette.secondary.main,
|
644
|
+
sx: {
|
645
|
+
opacity: 0.5
|
646
|
+
}
|
647
|
+
}, "Total Connected Accounts:", " ", totalConnectedAccounts) : null), /* @__PURE__ */ import_react16.default.createElement(ConnectedWalletsTable, {
|
648
|
+
wallets: sortedWallets,
|
649
|
+
ignoreConnectDialog,
|
650
|
+
onIgnoreConnectDialog
|
651
|
+
}));
|
652
|
+
});
|
574
653
|
ConnectedAccountsFlexbox.displayName = "ConnectedAccountsFlexbox";
|
575
654
|
//# sourceMappingURL=index.cjs.map
|