Unit A · On the network
What we are making: the same data as Session 4, on a page that somebody would actually want to look at. No new hardware.
Your page works and it is unreadable. Black text on white, default size, no layout. On a phone it renders as a tiny desktop site and nobody can read the number that matters.
This is worth a session because from here to May, the page is the product. Nobody at the exhibition will read your C++. They will look at the page for four seconds and decide whether your project works.
That single line is the difference between a page that is usable on a phone and one that is not. It tells the browser: this page was designed for the width of this screen, do not pretend to be a desktop.
Put all the styling in one function. Then every page you serve for the rest of the year gets it for free.
display:block with real padding turns a link into a thumb-sized button. A control you cannot hit while holding a ladder is not a control.system-ui means 'whatever this device's own interface font is'. It looks native on every phone and costs nothing to download — which matters when the page is served by a board with no internet connection.A stranger should get four things in four seconds. Everything else belongs on a second page.
| Element | Why | Example |
|---|---|---|
| The number | Biggest thing on the page, readable from a metre away | 23 |
| Its unit | Next to it, smaller. A number with no unit is not information | cm |
| Its age | Small, always present. This is what makes the page trustworthy | updated 2 s ago |
| One action | If there is something to do, one obvious control. Not five | Silence alarm |
One number, one unit, one age, one action. That is the whole design.
pageHead() and rebuild your Session 4 page using it.In this session