terra-money / wallet-kit

new version of wallet-provider
7 stars 9 forks source link

Terra Station Mobile Connector Bug #17

Open Mario857 opened 1 year ago

Mario857 commented 1 year ago

Hey there. Getting the wrong/missing values returned from useConnectedWallet and useWallet when connecting over Terra Station Mobile.

Mobile:


useConnectedWallet()
{
    "addresses": {
        "phoenix-1": "..."
    }
}

Browser Extension:

useConnectedWallet()
{
    "address": "....", // This one field is not in interface.
    "addresses": {
        "akashnet-2": "...",
        "archway-1": "...",
        "axelar-dojo-1": "...",
        "carbon-1": "...",
        "cheqd-mainnet-1": "..",
        "chihuahua-1": "..",
        "comdex-1": "..",
        "cosmoshub-4": "..",
        "crescent-1": "..",
        "juno-1": "..",
        "kaiyo-1": "..",
        "mainnet-3": "..",
        "mars-1": "..",
        "migaloo-1": "..",
        "neutron-1": "..",
        "osmosis-1": "...",
        "pacific-1": "...",
        "phoenix-1": "...",
        "stafihub-1": "...",
        "stride-1": "..."
    },
    "ledger": false, // does not exist on mobile
    "name": "....", // does not exist on mobile
    "network": "mainnet" // required
}
Mario857 commented 1 year ago

useConnectedWallet should at minimum return one more field (network to be 'testnet' | 'mainnet' | 'classic') on mobile

Kayanski commented 12 months ago

I put a +1 on this issue. The connector defined in this file : https://github.com/terra-money/wallet-kit/blob/main/src/%40terra-money/terra-station-mobile/index.ts#L209 should return the fields correctly to help us identify which wallet is connected to the app !