bikebrigade / dispatch

Bike Brigade's dispatching software! 🚴
https://bikebrigade.ca
Apache License 2.0
74 stars 9 forks source link

Flash on mobile obscures menu bar until closed #346

Closed teesloane closed 4 months ago

teesloane commented 5 months ago

CleanShot 2024-04-26 at 13 07 56@2x

We should use some JS to dismiss flashes after a certain amount of time.

teesloane commented 5 months ago

I have not come up with a solution for this yet, but I did find this library, which might be nice to explore.

teesloane commented 4 months ago

I started looking into the library posted above (Flashy). It required quite a bit of configuration and customization, to the point where I was asking myself if there was an easier way about this. I think there are some options, mainly, we move mobile flash to the bottom of the screen on mobile, perhaps with some margin — making it easier to close with your thumb.

We can also try setting up an on_mount hook that sets up a handle info to remove flashes, provided we send a message to the self pid, telling the flash to close after N seconds. See this post for details.