Skip to content

Commit

Permalink
chore: open Argent's deep link upon connecting
Browse files Browse the repository at this point in the history
  • Loading branch information
Cussone committed Jan 31, 2025
1 parent 2ea4a47 commit e89c4c1
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/connectors/argent/argentMobile/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import { isInArgentMobileAppBrowser } from "../helpers"
import type { StarknetAdapter } from "./modal/starknet/adapter"
import { ArgentX } from "../../injected/argentX"
import { getModalWallet } from "../../../helpers/mapModalWallets"
import { isMobileDevice } from "../../../helpers/navigator"

export interface ArgentMobileConnectorOptions {
dappName: string
Expand Down Expand Up @@ -99,6 +100,9 @@ export class ArgentMobileBaseConnector extends Connector {
}

async connect(_args: ConnectArgs = {}): Promise<ConnectorData> {
if (isMobileDevice()) {
window.open("https://www.argent.xyz/app", "_blank")
}
await this.ensureWallet({ onlyQRCode: _args?.onlyQRCode })

if (!this._wallet) {
Expand Down

0 comments on commit e89c4c1

Please sign in to comment.