Safe browser 'prompt' support

I am trying to use the simplemde editor in the safe browser. ( I’ll push a safe:// enabled fork to my github as soon at I have it working )

Unfortunately, simplemde uses the ‘prompt’ method to display an interactive popup so the user can select a link, image, etc, and it seems this is not supported by electron

Funny, while unsupported too, alert and confirm do work.

Pinging maybe @joshuef , I suppose I can get out of this with more tinkering and duct tape, but, are there plans by maidsafe to bundle something with the new browser as a workaround ?

All these popups are quite handy for web app developers, and it would be nice to have them ‘natively’

.

2 Likes

I hit this with one of the RemoteStorage apps I was porting, and fixed it by providing a new version of those functions.

The code isn’t on github yet, but it is live on SN (don’t have the link to hand just now).

I modified an existing nodejs ‘prompt’ library to work client side I think.

3 Likes

Here’s a relevant issue from the Beaker Browser repo: https://github.com/beakerbrowser/beaker/issues/399

They ended up implementing their own prompt modal via this PR.

I’m just mentioning this here in case it might be useful :slightly_smiling_face:

5 Likes

Aha, nice find @frabrunelle

Yeh, this shouldn’t be to bad to get in @nice. The new browser will have some more unified UI, so hopefully should be a matter of patching the functionality as @happybeing suggests and wiring it up.

:+1:

1 Like