import assert from 'node:assert/strict'; import fs from 'node:fs/promises'; import path from 'node:path'; import test from 'node:test'; const root = path.resolve(import.meta.dirname, '..'); async function read(relativePath) { return fs.readFile(path.join(root, relativePath), 'utf8'); } test('bootstrap screen remains vertically scrollable on small displays', async () => { const css = await read('public/css/bootstrap.css'); const bootstrapRule = css.match(/#bootstrap-screen\s*\{([\s\S]*?)\}/)?.[1] ?? ''; const cardRule = css.match(/#bootstrap-screen\s*>\s*\.bootstrap-card\s*\{([\s\S]*?)\}/)?.[1] ?? ''; assert.match(bootstrapRule, /overflow-y:\s*auto/); assert.match(bootstrapRule, /overflow-x:\s*hidden/); assert.match(bootstrapRule, /touch-action:\s*pan-y/); assert.match(bootstrapRule, /-webkit-overflow-scrolling:\s*touch/); assert.match(bootstrapRule, /align-items:\s*safe center/); assert.match(cardRule, /box-sizing:\s*border-box/); });