// "Signs to know" (round 5): the generic sign schematics for one finding type — a small line drawing, the sign's // name, one paragraph on what to look for, and a Radiopaedia link (link only). Generic material from GET /api/signs: // it never says anything about the case being read, so it is shown before submit (the "i" drawer) as well as after. // The drawing is our own API's SVG, guarded in api/signs.ts (no scripts, handlers or external references) and // rendered inline in a fixed 120×120 box. import { labelDisplay } from '../api/labels'; import { signsForLabel, type SignSchematic } from '../api/signs'; import { NOT_GRADED, SCHEMATIC_PROVENANCE, useSignSchematics } from './signsData'; import s from './Reference.module.css'; export function Schematic({ sign }: { sign: SignSchematic }) { return ( // The markup comes from our own API and passed safeSvg(); nothing user-written is ever rendered this way.
); } /** `showLabels` (the Signs tab): name the graded finding(s) the sign points to. */ export function SignCard({ sign, onFilm = false, notGraded = false, showLabels = false }: { sign: SignSchematic; onFilm?: boolean; notGraded?: boolean; showLabels?: boolean }) { return ({sign.name} {onFilm && Drawn on your film}
{sign.description &&{sign.description}
} {showLabels && sign.labels.length > 0 &&Points to: {sign.labels.map(labelDisplay).join(', ')}
} {notGraded &&{NOT_GRADED}
} {sign.radiopaedia_url && ( Read more on Radiopaedia (opens in a new tab) )}