ashlsun / untitled-inventory-app

a text-based inventory app for your fridge
https://ashlsun.github.io/untitled-inventory-app/
2 stars 0 forks source link

Mobile users cannot cancel editing a name #15

Open ashlsun opened 4 months ago

ashlsun commented 4 months ago

gah i just tested it ... doesn't really work on my iphone! seems like tapping elsewhere either doesn't blur the input field or it was never focused in the first place!

from https://stackoverflow.com/questions/13492881/why-is-blur-event-not-fired-in-ios-safari-mobile-iphone-ipad

If an anchor has any events attached, the first tap on it in iOS causes the anchor to be put into the hover state, and focused. A tap away removes the hover state, but the link remains focused. This is by design. To properly control an application on iOS, you need to implement touch-based events and react to those instead of desktop ones.