Small improvements for small screens

This commit is contained in:
arne 2024-07-21 12:30:28 +02:00
commit 00fed1c95b
2 changed files with 9 additions and 6 deletions

View file

@ -8,8 +8,10 @@ import { cycle, comp, range, iterator, map, mapcat, reverse, zip, filter } from
// initial settings
// available size for a2: 420 * 594
const width_ = 420
const height_ = 594
const sqrt2 = Math.sqrt(2)
const width_ = Math.round(420 / (document.body.clientWidth > 640 ? 1 : sqrt2))
const height_ = Math.round(594 / (document.body.clientWidth > 640 ? 1 : sqrt2))
const cellSize_ = 12
const padding_ = 5 // * cellSize