posture.tsx
This file
Path
apps/web/src/features/shared/posture.tsx
37 lines · 943 bytes · TypeScript
Last changed by
Merge build/comments-web-features into mainoscabrielbefore adoption74bfc72
History of this fileTake it
The walk stopped after 200 commits: lines older than 678c8b8 point at it.
Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
line 1why, one step back1/**Merge build/comments-web-features into mainoscabrielbefore adoption74bfc72
lines 2–3why, one step back2 * The posture literal rides as `data-posture`, so tests and styles key on it;3 * the words are the platform's label, never rewritten here.Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
lines 4–6why, one step back4 */5import type { Posture } from "@repo/protocol/posture";6Draw every list and subject from one row, one status line, one family fan and one set of fact blocksoscabrielbefore adoption886b726
lines 7–8why, one step back7import { POSTURE_MARKS } from "./mark-look.ts";8import { StateBadge } from "./state-badge.tsx";Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
line 9why, one step back9Draw every list and subject from one row, one status line, one family fan and one set of fact blocksoscabrielbefore adoption886b726
lines 10–15why, one step back10const wordTone = {11 open: "text-foreground",12 openCore: "text-sealed",13 openOnSchedule: "text-sealed",14 openWithSealedEvidence: "text-sealed",15 sourceAvailable: "text-muted-foreground",Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
lines 16–20why, one step back16} as const satisfies Record<Posture, string>;1718export const PostureBadge = ({19 label,20 posture,Merge build/1500-design-draws into mainoscabrielbefore adoption9bc46b7
line 21why, one step back21 title,Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
lines 22–24why, one step back22}: {23 readonly label: string;24 readonly posture: Posture;Merge build/1500-design-draws into mainoscabrielbefore adoption9bc46b7
line 25why, one step back25 readonly title?: string | undefined;Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
line 26why, one step back26}) => (Draw every list and subject from one row, one status line, one family fan and one set of fact blocksoscabrielbefore adoption886b726
lines 27–29why, one step back27 <StateBadge28 className="text-ui items-start [&>svg]:mt-0.5"29 mark={POSTURE_MARKS[posture]}Merge build/1500-design-draws into mainoscabrielbefore adoption9bc46b7
lines 30–34why, one step back30 word={31 <span data-posture={posture} title={title}>32 {label}33 </span>34 }Draw every list and subject from one row, one status line, one family fan and one set of fact blocksoscabrielbefore adoption886b726
lines 35–36why, one step back35 wordTone={wordTone[posture]}36 />Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8
line 37why, one step back37);