* web: Fix Safari Arrow keys in HTML export and webapp\n\n- Remap Arrow key events with KeyboardEvent.location === 3 (numpad) to location: 0 on WebKit in capture phase\n- Prevent page scrolling on Arrow keys while canvas is focused\n- Ensure canvas is focusable (tabindex=0) and focused on start\n\nThis addresses Safari/WebKit misclassification of physical Arrow keys so games receive directional input correctly.
* Add missing semicolon
* Update index.html
* Update index.html
This commit refactor & fix various problems in HTML builds:
- Build emscripten script as ES6 module, so that it doesn't pollute the
global namespace and can be easier to import to SPA projects
(vue, react,...).
- Change `SDL_EMSCRIPTEN_KEYBOARD_ELEMENT` to the canvas element so that
emscripten won't block all keyboard input to the rest of the
webpage (fixing the problem that make typing comment content on
tic80.com is not possible after starting the game)
- Add tabindex to canvas element so that canvas can be focused (and
unfocused) and capture the keyboard input properly.
- Refactor html template of html, html export stub and webapp
build to be more minimal, and add a simple "play" icon instead of
"click to play" text
- Small changes to html build directories in github action's script