Skip to content

Commit

Permalink
Merge pull request #3 from argentlabs/update-starknetkit
Browse files Browse the repository at this point in the history
chore: update starknetkit
  • Loading branch information
bluecco authored Nov 6, 2024
2 parents dcc4387 + af1ff07 commit 5904c0c
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"react": "19.0.0-rc-02c0e824-20241028",
"react-dom": "19.0.0-rc-02c0e824-20241028",
"starknet": "^6.11.0",
"starknetkit": "^2.3.3"
"starknetkit": "^2.4.0"
},
"devDependencies": {
"@commitlint/cli": "^19.5.0",
Expand Down
10 changes: 5 additions & 5 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions src/connectors/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ import {
isInArgentMobileAppBrowser,
ArgentMobileConnector,
} from "starknetkit/argentMobile"
/* import {
import {
BraavosMobileConnector,
isInBraavosMobileAppBrowser,
} from "starknetkit/braavosMobile" */
} from "starknetkit/braavosMobile"
import { InjectedConnector } from "starknetkit/injected"
import { WebWalletConnector } from "starknetkit/webwallet"

/* const isMobileDevice = () => {
const isMobileDevice = () => {
if (typeof window === "undefined") {
return false
}
Expand All @@ -28,7 +28,7 @@ import { WebWalletConnector } from "starknetkit/webwallet"
// Combine checks: Must match user agent AND (touch support OR small screen)
return isMobileUA && (hasTouchSupport || isSmallScreen)
}
*/

export const availableConnectors = () => {
if (isInArgentMobileAppBrowser()) {
return [
Expand All @@ -42,9 +42,9 @@ export const availableConnectors = () => {
]
}

/* if (isInBraavosMobileAppBrowser()) {
if (isInBraavosMobileAppBrowser()) {
return [BraavosMobileConnector.init({})]
} */
}

return [
new InjectedConnector({ options: { id: "argentX" } }),
Expand All @@ -56,7 +56,7 @@ export const availableConnectors = () => {
chainId: CHAIN_ID,
},
}),
/* isMobileDevice() ? BraavosMobileConnector.init({}) : null, */
isMobileDevice() ? BraavosMobileConnector.init({}) : null,
new WebWalletConnector({ url: ARGENT_WEBWALLET_URL }),
].filter((connector) => connector !== null)
}
Expand Down

0 comments on commit 5904c0c

Please sign in to comment.