This is great! I have a note in my ideas list for an infinitely expanding public canvas. At what point does it expand the current bounds?
8192 became the arbitrary magic number for everything, so every 8192 seconds it expands by 8x8. It was 2x2 but progress was too slow, would take a year before reaching the upper bounds of 8192x8192px.
Your "viewport.onwheel = function wheel" is backwards for zooming in and out. Pushing the wheel forward should zoom in.
Yeah non-functioning mouse wheel on this machine, scaling of the value is also most likely way off :-(
Should be more reasonable now, scaling by * -0.1 but it could use more cross browser normalization...