HacklabJKL / visitors

Visitor data collector using DHCP leases
GNU General Public License v3.0
0 stars 1 forks source link

Clicking on the nickname input refreshes the page and clears the focus #21

Closed braaar closed 2 years ago

braaar commented 2 years ago

Steps to reproduce:

  1. Open https://lab.jkl.hacklab.fi:5944/visitors/
  2. Click the nickname field with the mouse (or tap it with mobile)
  3. The page refreshes, and the field is no longer focused

Note: The field can be focused with the tab key.

I suspect the issue comes from this a element which triggers whenever you click inside of it. I don't understand its purpose. Does the template element in index.html turn into an anchor?

Screenshot 2022-05-23 at 10 45 39

My computer where the issue occurs MacOS Monterey 12.0.1 Google Chrome Version 101.0.4951.64 (Official Build) (arm64)

My phone where the issue occurs Google Pixel 4a Android 12 Google Chrome Version 101.0.4951.64

Issues occured at the hacklab, connected to the hacklab wifi.

PetteriAimonen commented 2 years ago

I think the issue is missing </a> here: https://github.com/HacklabJKL/visitors/blob/master/dist/index.html#L23

zouppen commented 2 years ago

I think the issue is missing </a> here: https://github.com/HacklabJKL/visitors/blob/master/dist/index.html#L23

Fixed the tag. Please test again @braaar

braaar commented 2 years ago

I think the issue is missing </a> here: https://github.com/HacklabJKL/visitors/blob/master/dist/index.html#L23

Fixed the tag. Please test again @braaar

It's working! Thanks for the fix!