Skip to content

Commit

Permalink
feat: bump
Browse files Browse the repository at this point in the history
  • Loading branch information
Majorfi committed Sep 3, 2023
1 parent aefff6e commit fd2eadd
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
4 changes: 4 additions & 0 deletions contexts/useWeb3.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ const defaultState = {
isDisconnected: false,
isActive: false,
isConnecting: false,
isWalletSafe: false,
isWalletLedger: false,
hasProvider: false,
provider: undefined,
currentPartner: undefined,
Expand Down Expand Up @@ -102,6 +104,8 @@ export const Web3ContextAppWrapper = ({children, options}: {children: ReactEleme
isDisconnected,
ens: ensName || '',
isActive: isConnected && [...supportedChainsID, 1337].includes(chain?.id || -1) && isMounted(),
isWalletSafe: connector?.id === 'safe' || (connector as any)?._wallets?.[0]?.id === 'safe',
isWalletLedger: connector?.id === 'ledger' || (connector as any)?._wallets?.[0]?.id === 'ledger',
lensProtocolHandle: '',
hasProvider: !!(walletClient || publicClient),
provider: connector,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@yearn-finance/web-lib",
"version": "2.0.19",
"version": "2.0.20",
"files": [
"."
],
Expand Down
2 changes: 2 additions & 0 deletions types/contexts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ export type TWeb3Context = {
isDisconnected: boolean,
isActive: boolean
isConnecting: boolean,
isWalletSafe: boolean,
isWalletLedger: boolean,
hasProvider: boolean,
provider?: Connector,
currentPartner?: TPartnersInfo,
Expand Down

0 comments on commit fd2eadd

Please sign in to comment.