Skip to content

Record your screen, ship a demo. Free and open-source, GPU-accelerated, no watermarks, no subscriptions. Windows, macOS, Linux. Actively maintained.

fix(website): close the three holes in the score, and cut the page's asides

Etienne Lescoteaedd4563b07
diff --git a/website/src/components/Editor/index.tsx b/website/src/components/Editor/index.tsx
index b2ddbc6dd..c77f33e2c 100644
--- a/website/src/components/Editor/index.tsx
+++ b/website/src/components/Editor/index.tsx
@@ -1,13 +1,25 @@
/**
- * The page's centre of gravity: a heading, and then six viewports of editor.
+ * The page's centre of gravity: six viewports of editor, and nothing above it.
*
* It sits immediately under the hero because it is the argument. Everything
* after it is either a claim the editor cannot make on its own (the recorder,
* the encoder, captions, the agent) or a property rather than a capability
* (the licence, the privacy, the platforms).
*
- * The heading keeps the page's measure; the recreation does not, and is the one
- * block on this page that uses the whole viewport.
+ * No visible heading, as the design has it. The six beats caption themselves —
+ * "STYLE / Swap the background", and five more — so a heading above them was a
+ * lid on a box that labels itself, and the deck under it was the page
+ * explaining itself to the reader instead of showing them.
+ *
+ * Two things survive that removal, both invisible:
+ *
+ * The h2, now screen-reader-only. Without it the outline runs h1 straight to
+ * the six h3 captions, which is a skipped level, and the section's
+ * aria-labelledby has nothing to point at.
+ *
+ * The skip link, visible on focus. The band is six viewports tall; tabbing
+ * through it to reach the download link is a long way for someone who has
+ * already decided.
*/
import Heading from "@theme/Heading";
@@ -19,21 +31,13 @@ export default function Editor() {
return (
<section className={styles.section} aria-labelledby="editor-title">
<div className={styles.head}>
- {/* The band is six viewports tall. Tabbing through it to reach the
- download link is a long way to go for someone who has already
- decided. */}
<a className={styles.skip} href="#download-install">
Skip the editor — go to downloads
</a>
- <p className={styles.kicker}>the editor</p>
<Heading as="h2" id="editor-title" className={styles.title}>
- Six things you will actually do.
+ Six things you will actually do
</Heading>
- <p className={styles.deck}>
- Scroll to drive it. Nothing below is a video: it is the editor, redrawn live in your
- browser from the design tokens the app ships and the project file of one real session.
- </p>
</div>
<Recreation />
diff --git a/website/src/components/Editor/styles.module.css b/website/src/components/Editor/styles.module.css
index 19fb059e1..2e4213aec 100644
--- a/website/src/components/Editor/styles.module.css
+++ b/website/src/components/Editor/styles.module.css
@@ -1,7 +1,8 @@
/**
- * The heading keeps the page's 1096px measure. The recreation below it does not
- * — it is a direct child of the section rather than of `.head`, which is the
- * whole reason the section has no horizontal padding of its own.
+ * Nothing here is drawn any more except on focus. `.head` exists to give the
+ * skip link a positioning context and the hidden heading a home; the recreation
+ * is a sibling of it, not a child, which is why the section has no horizontal
+ * padding of its own.
*/
.section {
@@ -10,50 +11,31 @@
viewport — so a section without a background sits on the wrong grey. */
background: var(--os-bg);
color: var(--os-fg);
- /* The hero has no bottom padding of its own — it used to hand straight over
- to a plate section that supplied its own. This is that air. */
- padding: 104px 0 8px;
+ /* Down from 104px, which was the air a section heading needed. With the
+ heading gone the hero should hand over to the editor the way the design
+ has it: the demo begins as the hero leaves. */
+ padding: 24px 0 8px;
}
-/* Centred, like every other section heading on the page.
- *
- * Left-aligned it introduced a third x-origin: the hero is centred, the
- * recreation's captions sit at 5% of the full-bleed stage, and a heading on the
- * 1096px measure landed between the two — near enough to the caption 200px
- * below it to read as a failed alignment rather than a different one. Aligning
- * the heading to the caption instead is not available: the caption has to stay
- * near the left edge, or at 1920px it runs into the composite. */
.head {
position: relative;
max-width: 1096px;
margin: 0 auto;
- padding: 0 28px 34px;
- text-align: center;
-}
-
-.kicker {
- margin: 0;
- font-family: var(--ifm-font-family-monospace);
- font-size: 11px;
- letter-spacing: 0.08em;
- text-transform: uppercase;
- color: var(--os-accent);
+ padding: 0 28px;
}
+/* Read, never seen. Not `display: none`, which would take it out of the
+ accessibility tree along with the outline it is there to keep. */
.title {
- margin: 10px 0 0;
- font-size: clamp(26px, 3.2vw, 36px);
- font-weight: 700;
- letter-spacing: -0.025em;
- color: var(--os-fg-emphasis);
-}
-
-.deck {
- margin: 12px auto 0;
- max-width: 62ch;
- font-size: 14.5px;
- line-height: 1.6;
- color: var(--os-fg-2);
+ position: absolute;
+ width: 1px;
+ height: 1px;
+ margin: -1px;
+ padding: 0;
+ overflow: hidden;
+ clip-path: inset(50%);
+ white-space: nowrap;
+ border: 0;
}
/* Visible only on focus. */
@@ -82,7 +64,7 @@
@media (max-width: 600px) {
.head {
- padding: 0 18px 24px;
+ padding: 0 18px;
}
.skip {
diff --git a/website/src/components/Recreation/driver.ts b/website/src/components/Recreation/driver.ts
index 73500a706..9531614b7 100644
--- a/website/src/components/Recreation/driver.ts
+++ b/website/src/components/Recreation/driver.ts
@@ -415,8 +415,11 @@ export function attachDriver(refs: DriverRefs, cls: DriverClasses): () => void {
if (f.beat !== lastBeat) {
lastBeat = f.beat;
+ // Set, never unset. The beats tile the scene so `f.beat` is always
+ // defined, and this keeps a future gap from falling through to the
+ // stylesheet's undriven fallback — which is the closing frame, not an
+ // empty one. Teardown still clears it.
if (f.beat) root.dataset.beat = f.beat;
- else delete root.dataset.beat;
}
const pad = `${Math.round(f.padding)}%`;
diff --git a/website/src/components/Recreation/scene.ts b/website/src/components/Recreation/scene.ts
index 83b4ddce2..287e2880a 100644
--- a/website/src/components/Recreation/scene.ts
+++ b/website/src/components/Recreation/scene.ts
@@ -32,10 +32,22 @@ export const T_TOTAL = 26.0;
/* ── the five beats ───────────────────────────────────────────────────────── */
+/* The five beats tile [0, T_TOTAL] with no gaps, and that is a correctness
+ * property, not tidiness. A frame that falls in a gap has no beat, the driver
+ * has nothing to write to `data-beat`, and the stylesheet's `:not([data-beat])`
+ * rule takes over — which is the RESTING frame, built for readers who will
+ * never get the driver at all: the timeline in, the transcript panel open, the
+ * scene at its closing values.
+ *
+ * So a gap does not show "nothing". It shows the end of the story. This opened
+ * at [0, 0.6), which is the state of the stage on every approach to the band,
+ * and the reader met the transcript panel before the background panel. There
+ * were two more at [14.5, 15.0) and [19.5, 19.6), invisible only because the
+ * panel happens to be faded out across both. */
export const BEATS = [
{
id: "style",
- from: 0.6,
+ from: 0,
to: 7.2,
kicker: "Style",
title: "Swap the background",
@@ -52,7 +64,7 @@ export const BEATS = [
{
id: "cursor",
from: 10.4,
- to: 14.5,
+ to: 15.0,
kicker: "Cursor",
title: "A cursor worth watching",
sub: "Size, smoothing, motion blur, click bounce — every move reads on screen.",
@@ -60,7 +72,7 @@ export const BEATS = [
{
id: "timeline",
from: 15.0,
- to: 19.5,
+ to: 19.6,
kicker: "Timeline",
title: "One click, one pill",
sub: "Zooms, speed ramps, trims, comments — each edit lands as a pill on the timeline.",
diff --git a/website/src/pages/index.module.css b/website/src/pages/index.module.css
index 587edd429..7b3710e4d 100644
--- a/website/src/pages/index.module.css
+++ b/website/src/pages/index.module.css
@@ -128,21 +128,6 @@
color: var(--os-fg-2);
}
-/* --os-meta is a 3.06:1 grey in dark and 2.55:1 in light; at 12.5px that is a
- 1.4.3 failure, and this paragraph is the one that says the app is not
- production-grade — the last sentence on the page that should be hard to read. */
-.note {
- margin: 22px auto 0;
- max-width: 460px;
- font-size: 12.5px;
- color: var(--os-muted);
- line-height: 1.5;
-}
-
-.note strong {
- color: var(--os-fg-2);
-}
-
/* ---- shared section chrome ---- */
.sectionKicker {
@@ -420,3 +405,12 @@
font-size: 12.5px;
color: var(--os-fg-2);
}
+
+/* The claim is literal, so it is only made where it holds: the scene needs
+ 901px and a reader who has not asked for less motion, and below either of
+ those the driver never attaches and nothing rides the scroll. */
+@media (max-width: 901px), (prefers-reduced-motion: reduce) {
+ .scrollHint {
+ display: none;
+ }
+}
diff --git a/website/src/pages/index.tsx b/website/src/pages/index.tsx
index e3148ce9e..6ec1247f7 100644
--- a/website/src/pages/index.tsx
+++ b/website/src/pages/index.tsx
@@ -46,14 +46,13 @@ export default function Home() {
Read the docs
</Link>
</div>
- {/* Kept from the previous cut, which the design drops. It is the one
- line on the page that manages expectations, and a pre-release that
- does not say so is the kind of omission that costs trust once. */}
- <p className={styles.note}>
- OpenScreen is <strong>not production-grade</strong>. Expect rough edges while we build
- in the open.
- </p>
- <p className={styles.scrollHint}>Scroll to ride the demo</p>
+ {/* The design's line here is "Scroll to ride the demo", which gives an
+ instruction the reader did not need and a reason they did not get.
+ This states the mechanism instead, and the mechanism is the reason:
+ scroll position IS the clock the edit runs on. Hidden where that
+ stops being true — below 901px, and under reduced motion, the driver
+ never attaches and the scrollbar is just a scrollbar. */}
+ <p className={styles.scrollHint}>Scroll — the scrollbar is the timeline</p>
</div>
</header>