chore(comments): drop epic, sprint and review-round ids from the code
The code cited its plan instead of saying why: `E28 review J4`, `(R6 S3b)`, `S1 justified…`,
`deep-review round 5`. That plan lives in the private ops repo, so for every reader of this one the
citation was noise, and a sentence whose subject was the plan step ("round 2 showed…") hid its
lesson behind an id. Each one is gone and the "why" kept: a bare citation is deleted, a sentence
carrying a lesson is reworded around it ("a later attempt showed…").
Measured (`scripts/audit_metrics.py`, product code): 652 lines in 270 files carried an epic code by
the definition the next commit holds (507 / 241 by the old, two-digit-only one) -> 0. Across all
code, tests, scripts and configs: ~1100 epic-code lines plus ~320 sprint/round ids.
Behaviour unchanged, checked mechanically: every changed .py file has the same AST once docstrings
are blanked; css/sh/toml/yml/json files are identical once comments are stripped; the only
non-comment changes in TS/JS are test titles, one description string in a contract table, and five
ESLint messages, whose text is all the gates snapshot diff holds. Not touched: Markdown (docs and
the changelog keep their history), Alembic migrations, TV episode notation (`S2 · E5`), DESIGN.md
ids (`C1`, `B4`, `S3h`), tracker ids (`SEC-16`, `DX-17`).
One stale claim fixed on the way: test_hls_reaper's docstring said the player checkpoints "every
10 s whether or not it is playing", which plex/stream.py calls wrong; it now says what the code does.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// @vitest-environment jsdom
|
||||
//
|
||||
// Plex card a11y: locks the accessible names on the icon-only card controls (the E4 a11y sweep). These
|
||||
// Plex card a11y: locks the accessible names on the icon-only card controls (an a11y sweep). These
|
||||
// buttons are icon-only (WatchedIcon / ListPlus / the "…", no text), so their name comes solely from the
|
||||
// aria-label — a dropped label silently reintroduces an unnamed button for screen-reader users. i18n is
|
||||
// key-passthrough, so the asserted names are the i18n keys.
|
||||
@@ -60,7 +60,7 @@ describe("PlexPosterCard a11y", () => {
|
||||
expect(screen.getByRole("button", { name: "plex.playlistAdd.manage" })).toBeTruthy();
|
||||
// Two: the hover row's and its touch twin beside the title (CSS shows one per device).
|
||||
expect(screen.getAllByRole("button", { name: "card.menu.more" })).toHaveLength(2);
|
||||
// Details moved into the menu (E28 C1): the card has no ⓘ of its own any more.
|
||||
// Details moved into the menu: the card has no ⓘ of its own any more.
|
||||
expect(screen.queryByRole("button", { name: "plex.info.title" })).toBeNull();
|
||||
});
|
||||
|
||||
@@ -69,7 +69,7 @@ describe("PlexPosterCard a11y", () => {
|
||||
expect(screen.getByRole("button", { name: "plex.markUnwatched" })).toBeTruthy();
|
||||
});
|
||||
|
||||
// E28 S3h: the one media card — the year and the rating are the meta line under the title (pinned
|
||||
// The one media card — the year and the rating are the meta line under the title (pinned
|
||||
// to the frame's bottom), the length a badge on the picture. The synopsis is NOT the picture's
|
||||
// tooltip any more: it lives in the card's preview (below).
|
||||
it("carries the year and rating in its meta line, the length on the picture", () => {
|
||||
@@ -217,7 +217,7 @@ describe("a started Plex card", () => {
|
||||
expect(container.querySelector(".flex-col.reveal-hover")).toBeNull();
|
||||
});
|
||||
|
||||
// E28 review D4: the card read "started" off the rounded progress %, the menu off the position —
|
||||
// The card read "started" off the rounded progress %, the menu off the position —
|
||||
// 20 s into a 3 h film is 0 % here and started there, so the card offered no Restart the menu had.
|
||||
it("a resume point under 1 % still offers the Restart, as the card's menu does", () => {
|
||||
render(
|
||||
@@ -257,7 +257,7 @@ describe("EpisodeCard a11y", () => {
|
||||
});
|
||||
});
|
||||
|
||||
// E11 S4b: in a keyboard-walkable grid or rail the WHOLE card is the item (the ring goes round the
|
||||
// In a keyboard-walkable grid or rail the WHOLE card is the item (the ring goes round the
|
||||
// poster and its title, D2) and the poster — the card's own role=button — is what Enter opens.
|
||||
describe("Plex cards in a keyboard-walkable list", () => {
|
||||
const cases = [
|
||||
@@ -293,7 +293,7 @@ describe("Plex cards in a keyboard-walkable list", () => {
|
||||
expect(root.getAttribute("data-nav-index")).toBe("3");
|
||||
const open = root.querySelector<HTMLElement>("[data-nav-open]")!;
|
||||
// A real button (ui/Pressable), not a div wearing its role: Enter/Space and the touch target
|
||||
// come from the primitive (S3g found the S3h picture hand-built).
|
||||
// come from the primitive (the picture was once found hand-built).
|
||||
expect(open.tagName).toBe("BUTTON");
|
||||
expect(open.getAttribute("type")).toBe("button");
|
||||
fireEvent.click(open);
|
||||
@@ -339,7 +339,7 @@ describe("a Plex card's caption and a drag", () => {
|
||||
|
||||
// On a shelf (Home, the Plex rails, a collection strip) the title is one line, so every card on the
|
||||
// strip is the same height; a landscape shelf picture is short, so it takes the smaller Play, clear
|
||||
// of the hover row under it (E28 S3h: at the large size they touched on a 232px slot).
|
||||
// of the hover row under it (at the large size they touched on a 232px slot).
|
||||
describe("PlexPosterCard on a shelf", () => {
|
||||
const titleOf = () => screen.getByText("M");
|
||||
const play = (c: HTMLElement) =>
|
||||
@@ -370,7 +370,7 @@ describe("PlexPosterCard on a shelf", () => {
|
||||
});
|
||||
});
|
||||
|
||||
// E31 S4e: a card fetched the detail page's 400px poster for its ~144px picture. It offers the
|
||||
// A card fetched the detail page's 400px poster for its ~144px picture. It offers the
|
||||
// proxy's small cut too and lets the browser pick by its width.
|
||||
describe("a Plex card's picture", () => {
|
||||
it("offers the small cut beside the full one, lazily", () => {
|
||||
|
||||
Reference in New Issue
Block a user