import { describe, expect, it } from "vitest"; import { THOR_DISPLAYS, THOR_UI_PIXELS_PER_INCH } from "./thorDisplayProfile"; describe("Thor physical display sizing", () => { it("uses millimetres for relative panel size, with equal physical touch targets", () => { const { top, bottom } = THOR_DISPLAYS; expect(top.widthMm).toBeCloseTo(132.83, 1); expect(bottom.widthMm).toBeCloseTo(75.12, 1); expect(bottom.cssWidth / top.cssWidth).toBeCloseTo(bottom.widthMm / top.widthMm, 2); expect(bottom.deviceScaleFactor).toBeGreaterThan(top.deviceScaleFactor); for (const panel of [top, bottom]) { expect(44 * panel.deviceScaleFactor / panel.pixelsPerInch * 25.4).toBeCloseTo(44 / THOR_UI_PIXELS_PER_INCH * 25.4); } }); });