MetaMask / MetaMask/metamask-sdk

[Bug]: The size of qrcode is too small to scan when use SDK's connectAndSign

Open
#1,144 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
338
Forks
260
PR merge metrics
No merged PRs in 30d

Description

### SDK

Web

### Provide environment information

The SDK runnig in the chrome on desktop. To import MetaMask SDK into my pure JavaScript dapp to connectAndSign with the MetaMask. There is no browser extension in the chrome, so the qrcode dialog popup. But the size of qrcode is too small to scan.

### MetaMask SDK Version

v0.30.1 and v0.30.2

### MetaMask Mobile app Version

v7.33.0(1460)

### What browser are you using? (if relevant)

Google Chrome Version 131.0.6778.71

### How are you deploying your application? (if relevant)

_No response_

### Describe the Bug

The size of qrcode is too small to scan when use SDK's connectAndSign. The following are popup dialog and html info.

![mm-wrong](https://github.com/user-attachments/assets/fed79c41-d9c5-4f7f-b814-a5ecc8264049)
![mm-wrong-svg](https://github.com/user-attachments/assets/224eab2c-1268-4c1f-a0fe-eb25160cd34a)

### Expected Behavior

The expected size of qrcode when use SDK's connect rather than connectAndSign. The following are popup dialog and html info.

![mm-right](https://github.com/user-attachments/assets/e87622d7-850d-4432-905e-55d431724d25)
![mm-right-svg](https://github.com/user-attachments/assets/f58f332c-1597-444c-9f53-f21e00c27424)

### Link to reproduction - Issues with a link to complete (but minimal) reproduction code will be addressed faster

_No response_

### To Reproduce

```
async function connet() {
const sdk = new MetaMaskSDK.MetaMaskSDK({
dappMetadata: {
name: "MetaMask Oauth",
},
redirectUri: window.location.href,
logging: {
sdk: true,
level: 'debug',
},
enableAutomaticQr: true,
checkInstallationImmediately: true,
useDeeplink: true,
});
const siweMessage = "wants you to sign in with your";
const sign = await sdk.connectAndSign({ msg: siweMessage });
}
```

Contributor guide

Open the contributing guide

Research direction

Start with the SDK web flows for connect and connectAndSign, using the supplied Chrome snippet and screenshots to compare their QR dialog rendering. Reproduce with the listed SDK and MetaMask Mobile versions, then verify that connectAndSign displays a QR code at the expected size and that it can be scanned.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend, web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.