mascara icon indicating copy to clipboard operation
mascara copied to clipboard

How to distinguish between locked and no account ?

Open digitaldonkey opened this issue 6 years ago • 5 comments

The common way to check if a account is unlocked in Metamask is a async call to this.web3.eth.getAccounts() and then check if accounts[0] is set.

In Mascara this works fine too. But I son't see how to differentiate between a existing, locked account and a user who never created an account at wallet.metamask.io.

So I can't decide if I should ask the interacting user to unlock or create an account. If the popup is loaded, it becomes clear, but it would be great if I can differentiate between unlock you account and create a new account at the button triggering the popup.

digitaldonkey avatar Mar 28 '18 13:03 digitaldonkey

I will also need a different popup size depending on that, as the Signup dialogue requires more space than the TX signing dialogue.

It might be also good if the follow fox would be responsive and only initialized at a window size > 700px.

image

digitaldonkey avatar Mar 28 '18 13:03 digitaldonkey

@digitaldonkey Did you find solution to this issue? I am also in the same situation

pranay01 avatar May 22 '18 14:05 pranay01

@pranay01 I prototyped something, which might help a little, but this is not yet solved. https://github.com/digitaldonkey/mascara_wrapper

digitaldonkey avatar May 24 '18 05:05 digitaldonkey