benmaier / netwulf

Interactive visualization of networks based on Ulf Aslak's d3 web app.
MIT License
294 stars 26 forks source link

`Post to Python` does not close the window anymore and also does not stop the server anymore #15

Closed benmaier closed 5 years ago

ulfaslak commented 5 years ago

Noooooooooooo.....

benmaier commented 5 years ago

haha

ulfaslak commented 5 years ago

we are better than this

benmaier commented 5 years ago

it's probably the sweetalert tbh.

ulfaslak commented 5 years ago

It actually works for me :).

benmaier commented 5 years ago

great ..............

On Apr 10, 2019, at 07:17, Ulf Aslak notifications@github.com wrote:

It actually works for me :).

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/benmaier/netwulf/issues/15#issuecomment-481686720, or mute the thread https://github.com/notifications/unsubscribe-auth/AKOzvNBamJpSKhKanqTss4eneC_KFJ0gks5vfeSBgaJpZM4cm92f.

benmaier commented 5 years ago

somehow, sweetalert does weird things for me now.

On Apr 10, 2019, at 07:18, Benjamin Maier benjaminfrankmaier@gmail.com wrote:

great ..............

On Apr 10, 2019, at 07:17, Ulf Aslak <notifications@github.com mailto:notifications@github.com> wrote:

It actually works for me :).

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/benmaier/netwulf/issues/15#issuecomment-481686720, or mute the thread https://github.com/notifications/unsubscribe-auth/AKOzvNBamJpSKhKanqTss4eneC_KFJ0gks5vfeSBgaJpZM4cm92f.

benmaier commented 5 years ago

found it. You seem to have switched to sweetalert2.all.min.js in index.html? But the functions in vis.js don't seem to have changed, at least the post to python did not. They're still written for sweetalert v1. Is there any reason you changed to v2?

ulfaslak commented 5 years ago

Hmmm.. I changed this long ago. v1 is not supported (developer gone missing), so v2 is the thing people are using now. I was getting errors with v1, so I switched.

benmaier commented 5 years ago

okay... looking at the API of swal2 (https://sweetalert2.github.io/) I'm actually suprised that the code wirtten for v1 works at all, because it seems to be very different to what is demanded (e.g. Swal.fire vs swal). I agree that in the long term the alerts should be replaced by v2 alerts but could we for now go back to v1 so it works without us doing any major work? :D what do you think?

ulfaslak commented 5 years ago

Yeeeah ok you're right this is all messed up. We can switch, but I was getting errors before, so it will probably cause some errors again. For the sake of development, let's switch now, and then move to v2 later.

ulfaslak commented 5 years ago

I updated the code in https://github.com/ulfaslak/network_styling_with_d3/ to sweetalert2. netwulf works fine for me now.

benmaier commented 5 years ago

whoa, super fast! works like a charm, thanks :)

One thing: the alerts have a serif font, now. Do they have that on your machine, too?

Screen Shot 2019-04-11 at 07 53 27

I could try changing that in the CSS if you agree. I bet it's something on my computer again though haha

benmaier commented 5 years ago

saw that: https://github.com/sweetalert2/sweetalert2/issues/846

would you mind me changing the font to some sans-serif like helvetica, arial ?

ulfaslak commented 5 years ago

Yes please go ahead, not a fan of Serif (doesn't look like that on my machine though).