@automovie/viewer 0.2.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/lib/inspector/AutoMovieInspector.js.map +1 -1
  2. package/lib/inspector/AutoMovieInspector.mjs.map +1 -1
  3. package/lib/inspector/AutoMovieInspectorMarksPanel.d.ts +2 -1
  4. package/lib/inspector/AutoMovieInspectorMarksPanel.js.map +1 -1
  5. package/lib/inspector/AutoMovieInspectorMarksPanel.mjs.map +1 -1
  6. package/lib/inspector/AutoMovieInspectorRequestPanel.d.ts +1 -1
  7. package/lib/inspector/AutoMovieInspectorRequestPanel.js.map +1 -1
  8. package/lib/inspector/AutoMovieInspectorRequestPanel.mjs.map +1 -1
  9. package/lib/inspector/AutoMovieInspectorSelectionPanel.d.ts +1 -1
  10. package/lib/inspector/AutoMovieInspectorSelectionPanel.js.map +1 -1
  11. package/lib/inspector/AutoMovieInspectorSelectionPanel.mjs.map +1 -1
  12. package/lib/inspector/AutoMovieInspectorShadePanel.d.ts +1 -1
  13. package/lib/inspector/AutoMovieInspectorShadePanel.js.map +1 -1
  14. package/lib/inspector/AutoMovieInspectorShadePanel.mjs.map +1 -1
  15. package/lib/inspector/AutoMovieInspectorViewPanel.d.ts +1 -1
  16. package/lib/inspector/AutoMovieInspectorViewPanel.js.map +1 -1
  17. package/lib/inspector/AutoMovieInspectorViewPanel.mjs.map +1 -1
  18. package/lib/inspector/IAutoMovieInspectorAction.d.ts +2 -2
  19. package/lib/inspector/IAutoMovieInspectorScene.d.ts +2 -1
  20. package/lib/inspector/IAutoMovieInspectorState.d.ts +1 -1
  21. package/lib/inspector/formatAutoMovieInspectorAddress.d.ts +1 -1
  22. package/lib/inspector/formatAutoMovieInspectorAddress.js.map +1 -1
  23. package/lib/inspector/formatAutoMovieInspectorAddress.mjs.map +1 -1
  24. package/lib/inspector/formatAutoMovieInspectorCommand.d.ts +1 -1
  25. package/lib/inspector/formatAutoMovieInspectorCommand.js.map +1 -1
  26. package/lib/inspector/formatAutoMovieInspectorCommand.mjs.map +1 -1
  27. package/lib/inspector/mountAutoMovieInspectorScene.d.ts +2 -1
  28. package/lib/inspector/mountAutoMovieInspectorScene.js.map +1 -1
  29. package/lib/inspector/mountAutoMovieInspectorScene.mjs.map +1 -1
  30. package/lib/inspector/readAutoMovieInspectorAddress.d.ts +1 -1
  31. package/lib/inspector/readAutoMovieInspectorAddress.js.map +1 -1
  32. package/lib/inspector/readAutoMovieInspectorAddress.mjs.map +1 -1
  33. package/lib/inspector/reduceAutoMovieInspectorState.js.map +1 -1
  34. package/lib/inspector/reduceAutoMovieInspectorState.mjs.map +1 -1
  35. package/package.json +5 -5
  36. package/src/inspector/AutoMovieInspector.tsx +2 -5
  37. package/src/inspector/AutoMovieInspectorMarksPanel.tsx +2 -7
  38. package/src/inspector/AutoMovieInspectorRequestPanel.tsx +2 -1
  39. package/src/inspector/AutoMovieInspectorSelectionPanel.tsx +6 -3
  40. package/src/inspector/AutoMovieInspectorShadePanel.tsx +6 -4
  41. package/src/inspector/AutoMovieInspectorViewPanel.tsx +2 -6
  42. package/src/inspector/IAutoMovieInspectorAction.ts +3 -3
  43. package/src/inspector/IAutoMovieInspectorScene.ts +2 -2
  44. package/src/inspector/IAutoMovieInspectorState.ts +1 -1
  45. package/src/inspector/formatAutoMovieInspectorAddress.ts +2 -4
  46. package/src/inspector/formatAutoMovieInspectorCommand.ts +2 -4
  47. package/src/inspector/mountAutoMovieInspectorScene.ts +5 -3
  48. package/src/inspector/readAutoMovieInspectorAddress.ts +2 -4
  49. package/src/inspector/reduceAutoMovieInspectorState.ts +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspector.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspector.tsx"],"names":[],"mappings":";;;;AAAA,8CAI2B;AAC3B,iCAYe;AAEf,uFAAiF;AACjF,mFAA6E;AAC7E,2FAAqF;AACrF,+FAAyF;AACzF,uFAAi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EAAE,QAAQ,GAClB,GACM,IACN,IACF,CACP,CAAC;AACJ,CAAC;AAED,0EAA0E;AAC1E,MAAM,MAAM,GAAW,GAAG,CAAC;AAE3B,iGAAiG;AACjG,SAAS,OAAO,CAAC,KAKhB;IACC,OAAO,CACL,qCACE,IAAI,EAAE,KAAK,CAAC,IAAI,KAAK,IAAI,EACzB,KAAK,EAAE,EAAE,SAAS,EAAE,gBAAgB,EAAE,OAAO,EAAE,OAAO,EAAE,aAExD,qCAAS,KAAK,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,UAAU,EAAE,GAAG,EAAE,aACnD,KAAK,CAAC,KAAK,EACX,KAAK,CAAC,IAAI,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CACjC,kCAAM,KAAK,EAAE,EAAE,UAAU,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,mBAC/C,KAAK,CAAC,IAAI,IACR,CACR,IACO,EACV,gCAAK,KAAK,EAAE,EAAE,UAAU,EAAE,CAAC,EAAE,YAAG,KAAK,CAAC,QAAQ,GAAO,IAC7C,CACX,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspector.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspector.tsx"],"sourcesContent":["import {\n type IAutoMovieDrawSubject,\n type IAutoMovieInspectionLegendEntry,\n selectAutoMovieDrawSubject,\n} from \"@automovie/render\";\nimport {\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type KeyboardEvent,\n type ReactNode,\n type RefObject,\n type SetStateAction,\n useEffect,\n useReducer,\n useRef,\n useState,\n} from \"react\";\n\nimport { AutoMovieInspectorMarksPanel } from \"./AutoMovieInspectorMarksPanel.js\";\nimport { AutoMovieInspectorPlayhead } from \"./AutoMovieInspectorPlayhead.js\";\nimport { AutoMovieInspectorRequestPanel } from \"./AutoMovieInspectorRequestPanel.js\";\nimport { AutoMovieInspectorSelectionPanel } from \"./AutoMovieInspectorSelectionPanel.js\";\nimport { AutoMovieInspectorShadePanel } from \"./AutoMovieInspectorShadePanel.js\";\nimport { AutoMovieInspectorTimePanel } from \"./AutoMovieInspectorTimePanel.js\";\nimport { AutoMovieInspectorViewPanel } from \"./AutoMovieInspectorViewPanel.js\";\nimport type { IAutoMovieInspectorProps } from \"./IAutoMovieInspectorProps.js\";\nimport type { IAutoMovieInspectorScene } from \"./IAutoMovieInspectorScene.js\";\nimport type { IAutoMovieInspectorState } from \"./IAutoMovieInspectorState.js\";\nimport { createAutoMovieInspectorCanvasHost } from \"./createAutoMovieInspectorCanvasHost.js\";\nimport { createAutoMovieInspectorState } from \"./createAutoMovieInspectorState.js\";\nimport { formatAutoMovieInspectorAddress } from \"./formatAutoMovieInspectorAddress.js\";\nimport { handleAutoMovieInspectorKey } from \"./handleAutoMovieInspectorKey.js\";\nimport { mountAutoMovieInspectorScene } from \"./mountAutoMovieInspectorScene.js\";\nimport { reduceAutoMovieInspectorState } from \"./reduceAutoMovieInspectorState.js\";\n\n/** No labels, the state before a paused picture places any. */\nconst UNLABELLED: IAutoMovieInspectorScene.ILabels = {\n labels: [],\n lineHeight: 0,\n dropped: 0,\n};\n\n/**\n * The inspection page as a React component: one canvas showing a subject through one request, and the panels that edit that request.\n *\n * The request is the component's only state that changes the picture. Every panel dispatches an edit to `reduceAutoMovieInspectorState`, the canvas is a plain three.js scene from `@automovie/render` mounted by `mountAutoMovieInspectorScene` in an effect, and every change of the request reaches `onRequestChange` as address text, so the page keeps its address equal to the request. The playhead is an `AutoMovieInspectorPlayhead` outside React that the render loop advances, so a playing frame re-renders only the time readout, and starting or stopping also the play button.\n *\n * The canvas has the transport directly under it. Beside it, or under the transport when the inspector is narrower than 900 pixels, a column holds one collapsible section per panel, each heading saying what is active: View and Shade start open, Marks, Selection and Request start closed, so a first look shows the picture and how it is drawn. While focus is inside the inspector, the playback keys of `handleAutoMovieInspectorKey` drive the playhead, except a key held with Ctrl, Meta or Alt and a key that goes to a control answering it itself.\n *\n * The mount effect depends on the chosen subject object only, which selectAutoMovieDrawSubject picks by the request's subject key, so each subject must keep its identity across renders; the request reaches a mounted scene through its `apply`, and a request the scene refuses is set back to the one it still draws, with the reason shown. Under StrictMode the mount effect runs, cleans up and runs again on the same canvas, which the mount supports with one renderer alive at the end.\n *\n * ```tsx\n * createRoot(element).render(\n * <AutoMovieInspector\n * subjects={subjects}\n * initialText={location.search}\n * onRequestChange={createAutoMovieInspectorAddressWriter({ location, history })}\n * />,\n * );\n * ```\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what the component shows and how it is laid out, where its state lives and changes, how the address follows it, why a playing frame renders only the readout and a start or stop the play button too, the keys, the effect split and the StrictMode behaviour, and shows the mount.\n * @evidence contracts/development/implementation.md#principled-implementation React owns layout and dispatch only: `useReducer` holds the request, `useEffect` owns the scene's lifetime per subject and forwards each request, and the canvas is drawn by three.js outside React's render, as the campaign decides against a React scene graph.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One component composes six panels, each a function of the request and a dispatch, five of them in collapsible sections of the platform's `details` element; every state change is the reducer's and every scene change the mount's.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No panel writes the scene, and a scene refusal is answered by restoring the request, never by drawing a picture the address does not name.\n * @evidence contracts/development/implementation.md#efficient-algorithms A dispatched edit renders the panels once and re-applies the inspection only when its text changed; a playing frame renders the readout alone, and a start or stop the play button too.\n * @evidence contracts/development/implementation.md#reuse-equivalent-work The mount, its renderer and its instance live while the subject stays; a request change reuses them.\n * @evidence contracts/development/implementation.md#bound-retention-and-release-resources The component owns one playhead and at most one mount at a time, disposed by the effect cleanup when the subject changes or the component unmounts.\n */\nexport function AutoMovieInspector(\n props: IAutoMovieInspectorProps,\n): JSX.Element {\n const [state, dispatch] = useReducer(\n reduceAutoMovieInspectorState,\n props.initialText,\n createAutoMovieInspectorState,\n );\n const [playhead] = useState<AutoMovieInspectorPlayhead>(\n (): AutoMovieInspectorPlayhead => new AutoMovieInspectorPlayhead(),\n );\n const [facts, setFacts] = useState<IAutoMovieInspectorScene.IFacts | null>(\n null,\n );\n const [legend, setLegend] = useState<IAutoMovieInspectionLegendEntry[]>([]);\n const [labels, setLabels] =\n useState<IAutoMovieInspectorScene.ILabels>(UNLABELLED);\n const [failure, setFailure] = useState<string | null>(null);\n const canvas: RefObject<HTMLCanvasElement | null> =\n useRef<HTMLCanvasElement>(null);\n const scene: RefObject<IAutoMovieInspectorScene | null> =\n useRef<IAutoMovieInspectorScene>(null);\n const { onRequestChange } = props;\n\n // A subject the request cannot name is shown as an error, with the subject choice still offered.\n const names: string[] = Object.keys(props.subjects);\n let name: string | null = null;\n let unnamed: string | null = null;\n try {\n name = selectAutoMovieDrawSubject(names, state.request.subject);\n } catch (error) {\n unnamed = error instanceof Error ? error.message : String(error);\n }\n\n // The scene lives as long as its subject; the effect reruns only then, so the request it captures is the one in force at mount.\n const request: IAutoMovieInspectorState[\"request\"] = state.request;\n const subject: IAutoMovieDrawSubject | null =\n name === null ? null : props.subjects[name]!;\n useEffect((): (() => void) | undefined => {\n if (canvas.current === null || subject === null || name === null)\n return undefined;\n const mounted: IAutoMovieInspectorScene = mountAutoMovieInspectorScene({\n subject,\n name,\n request,\n playhead,\n host: createAutoMovieInspectorCanvasHost(canvas.current),\n report: {\n ready: setFacts,\n legend: setLegend,\n labels: setLabels,\n error: setFailure,\n refused: (\n drawn: IAutoMovieInspectorState[\"request\"],\n message: string,\n ): void =>\n dispatch({ type: \"restore\", request: drawn, error: message }),\n },\n });\n scene.current = mounted;\n return (): void => {\n scene.current = null;\n setFacts(null);\n setLabels(UNLABELLED);\n mounted.dispose();\n };\n }, [subject, name, playhead]);\n\n // Every request reaches the scene and the page's address.\n useEffect((): void => {\n scene.current?.apply(request);\n onRequestChange?.(formatAutoMovieInspectorAddress(request));\n }, [request, onRequestChange]);\n\n // The column of sections moves under the transport when the inspector is\n // too narrow for both, measured on the inspector itself, since the page's\n // width is not the component's.\n const root: RefObject<HTMLDivElement | null> = useRef<HTMLDivElement>(null);\n const [narrow, setNarrow]: [boolean, Dispatch<SetStateAction<boolean>>] =\n useState<boolean>(false);\n useEffect((): (() => void) | undefined => {\n if (root.current === null || typeof ResizeObserver === \"undefined\")\n return undefined;\n const observer: ResizeObserver = new ResizeObserver(\n (entries: ResizeObserverEntry[]): void =>\n setNarrow((entries[0]?.contentRect.width ?? NARROW) < NARROW),\n );\n observer.observe(root.current);\n return (): void => observer.disconnect();\n }, []);\n\n // The playback keys, while focus is in the inspector; the handler leaves a\n // shortcut and a key a control answers itself to the page.\n const keys: (event: KeyboardEvent<HTMLDivElement>) => void = (\n event: KeyboardEvent<HTMLDivElement>,\n ): void => {\n const result: { handled: boolean; seconds: number | null } =\n handleAutoMovieInspectorKey(\n {\n key: event.key,\n ctrlKey: event.ctrlKey,\n metaKey: event.metaKey,\n altKey: event.altKey,\n target: event.target instanceof Element ? event.target : null,\n },\n playhead,\n facts?.fps ?? null,\n );\n if (!result.handled) return;\n event.preventDefault();\n if (result.seconds !== null)\n dispatch({ type: \"time\", seconds: result.seconds });\n };\n\n const inspection: IAutoMovieInspectorState[\"request\"][\"inspection\"] =\n request.inspection;\n return (\n <div\n ref={root}\n onKeyDown={keys}\n style={{\n display: \"flex\",\n flexDirection: narrow ? \"column\" : \"row\",\n gap: 12,\n fontFamily: \"sans-serif\",\n fontSize: 13,\n }}\n >\n <div style={{ flex: \"1 1 auto\", minWidth: 0 }}>\n <div style={{ position: \"relative\" }}>\n <canvas\n ref={canvas}\n tabIndex={0}\n role=\"application\"\n aria-label=\"The inspected picture; Space or K plays or pauses, J and L seek a second, comma and full stop step a frame, Home and End go to the ends\"\n style={{\n display: \"block\",\n width: \"100%\",\n aspectRatio:\n facts === null ? \"16 / 9\" : `${facts.width} / ${facts.height}`,\n background: \"#222\",\n }}\n />\n {labels.labels.map(\n (\n label: IAutoMovieInspectorScene.ILabels[\"labels\"][number],\n ): JSX.Element => (\n <span\n key={label.path}\n style={{\n position: \"absolute\",\n left: label.left,\n top: label.top,\n height: labels.lineHeight,\n fontSize: labels.lineHeight * 0.8,\n lineHeight: `${labels.lineHeight}px`,\n fontFamily: \"monospace\",\n background: \"#000\",\n color: \"#fff\",\n whiteSpace: \"nowrap\",\n pointerEvents: \"none\",\n }}\n >\n {label.text}\n </span>\n ),\n )}\n </div>\n <AutoMovieInspectorTimePanel\n playhead={playhead}\n fps={facts?.fps ?? null}\n dispatch={dispatch}\n />\n {[unnamed, failure, state.error]\n .filter(\n (message: string | null): message is string => message !== null,\n )\n .map(\n (message: string): JSX.Element => (\n <p\n key={message}\n role=\"alert\"\n style={{ color: \"#c00\", margin: \"4px 0\" }}\n >\n {message}\n </p>\n ),\n )}\n </div>\n <div\n style={\n narrow\n ? { width: \"100%\" }\n : { flex: \"0 0 300px\", overflowY: \"auto\", maxHeight: \"100vh\" }\n }\n >\n {names.length > 1 ? (\n <label style={{ display: \"block\", marginBottom: 8 }}>\n Subject{\" \"}\n <select\n value={request.subject ?? \"\"}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void =>\n dispatch({\n type: \"subject\",\n name: event.target.value === \"\" ? null : event.target.value,\n })\n }\n >\n <option value=\"\">(choose)</option>\n {names.map(\n (candidate: string): JSX.Element => (\n <option key={candidate} value={candidate}>\n {candidate}\n </option>\n ),\n )}\n </select>\n </label>\n ) : null}\n <Section title=\"View\" open>\n <AutoMovieInspectorViewPanel\n request={request}\n views={facts?.views ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Shade\" open>\n <AutoMovieInspectorShadePanel request={request} dispatch={dispatch} />\n </Section>\n <Section\n title=\"Marks\"\n note={\n inspection.marks.length === 0\n ? \"none on\"\n : `${inspection.marks.length} on`\n }\n >\n <AutoMovieInspectorMarksPanel\n request={request}\n marks={facts?.marks ?? []}\n legend={legend}\n dispatch={dispatch}\n />\n </Section>\n <Section\n title=\"Selection\"\n note={\n inspection.parts.length +\n inspection.hide.length +\n inspection.label.length +\n inspection.color.length ===\n 0\n ? `${facts?.paths.length ?? 0} paths`\n : `${inspection.parts.length} selected, ${inspection.hide.length} hidden, ${inspection.label.length} labelled`\n }\n >\n <AutoMovieInspectorSelectionPanel\n request={request}\n paths={facts?.paths ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Request\" note=\"address and capture command\">\n <AutoMovieInspectorRequestPanel\n request={request}\n dispatch={dispatch}\n />\n </Section>\n </div>\n </div>\n );\n}\n\n/** Below this width, in pixels, the sections move under the transport. */\nconst NARROW: number = 900;\n\n/** One collapsible section of the column: a heading that says what is active, over its panel. */\nfunction Section(props: {\n title: string;\n note?: string;\n open?: boolean;\n children: ReactNode;\n}): JSX.Element {\n return (\n <details\n open={props.open === true}\n style={{ borderTop: \"1px solid #ddd\", padding: \"6px 0\" }}\n >\n <summary style={{ cursor: \"pointer\", fontWeight: 600 }}>\n {props.title}\n {props.note === undefined ? null : (\n <span style={{ fontWeight: \"normal\", color: \"#666\" }}>\n : {props.note}\n </span>\n )}\n </summary>\n <div style={{ paddingTop: 6 }}>{props.children}</div>\n </details>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAqCA,MAAM,aAA+C;CACnD,QAAQ,CAAC;CACT,YAAY;CACZ,SAAS;AACX;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,SAAgB,mBACd,OACa;CACb,MAAM,CAAC,OAAO,YAAY,WACxB,+BACA,MAAM,aACN,6BACF;CACA,MAAM,CAAC,YAAY,eACiB,IAAI,2BAA2B,CACnE;CACA,MAAM,CAAC,OAAO,YAAY,SACxB,IACF;CACA,MAAM,CAAC,QAAQ,aAAa,SAA4C,CAAC,CAAC;CAC1E,MAAM,CAAC,QAAQ,aACb,SAA2C,UAAU;CACvD,MAAM,CAAC,SAAS,cAAc,SAAwB,IAAI;CAC1D,MAAM,SACJ,OAA0B,IAAI;CAChC,MAAM,QACJ,OAAiC,IAAI;CACvC,MAAM,EAAE,oBAAoB;CAG5B,MAAM,QAAkB,OAAO,KAAK,MAAM,QAAQ;CAClD,IAAI,OAA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W,WAAW,MAAM,OAAO;KAGxG,UAAA,oBAAC,kCAAD;MACW;MACT,OAAO,OAAO,SAAS,CAAC;MACd;KACX,CAAA;IACM,CAAA;IACT,oBAAC,SAAD;KAAS,OAAM;KAAU,MAAK;KAC5B,UAAA,oBAAC,gCAAD;MACW;MACC;KACX,CAAA;IACM,CAAA;GACN;EACF,CAAA,CAAA;;AAET;;AAGA,MAAM,SAAiB;;AAGvB,SAAS,QAAQ,OAKD;CACd,OACE,qBAAC,WAAD;EACE,MAAM,MAAM,SAAS;EACrB,OAAO;GAAE,WAAW;GAAkB,SAAS;EAAQ;EAFzD,UAAA,CAIE,qBAAC,WAAD;GAAS,OAAO;IAAE,QAAQ;IAAW,YAAY;GAAI;GAArD,UAAA,CACG,MAAM,OACN,MAAM,SAAS,KAAA,IAAY,OAC1B,qBAAC,QAAD;IAAM,OAAO;KAAE,YAAY;KAAU,OAAO;IAAO;IAAnD,UAAA,CAAsD,MACjD,MAAM,IACL;GAED,CAAA,CAAA;EACT,CAAA,GAAA,oBAAC,OAAD;GAAK,OAAO,EAAE,YAAY,EAAE;GAAI,UAAA,MAAM;EAAc,CAAA,CAC7C;;AAEb"}
1
+ {"version":3,"file":"AutoMovieInspector.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspector.tsx"],"sourcesContent":["import type { IAutoMovieInspectionLegendEntry } from \"@automovie/interface\";\nimport { type IAutoMovieDrawSubject, selectAutoMovieDrawSubject } from \"@automovie/render\";\nimport {\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type KeyboardEvent,\n type ReactNode,\n type RefObject,\n type SetStateAction,\n useEffect,\n useReducer,\n useRef,\n useState,\n} from \"react\";\n\nimport { AutoMovieInspectorMarksPanel } from \"./AutoMovieInspectorMarksPanel.js\";\nimport { AutoMovieInspectorPlayhead } from \"./AutoMovieInspectorPlayhead.js\";\nimport { AutoMovieInspectorRequestPanel } from \"./AutoMovieInspectorRequestPanel.js\";\nimport { AutoMovieInspectorSelectionPanel } from \"./AutoMovieInspectorSelectionPanel.js\";\nimport { AutoMovieInspectorShadePanel } from \"./AutoMovieInspectorShadePanel.js\";\nimport { AutoMovieInspectorTimePanel } from \"./AutoMovieInspectorTimePanel.js\";\nimport { AutoMovieInspectorViewPanel } from \"./AutoMovieInspectorViewPanel.js\";\nimport type { IAutoMovieInspectorProps } from \"./IAutoMovieInspectorProps.js\";\nimport type { IAutoMovieInspectorScene } from \"./IAutoMovieInspectorScene.js\";\nimport type { IAutoMovieInspectorState } from \"./IAutoMovieInspectorState.js\";\nimport { createAutoMovieInspectorCanvasHost } from \"./createAutoMovieInspectorCanvasHost.js\";\nimport { createAutoMovieInspectorState } from \"./createAutoMovieInspectorState.js\";\nimport { formatAutoMovieInspectorAddress } from \"./formatAutoMovieInspectorAddress.js\";\nimport { handleAutoMovieInspectorKey } from \"./handleAutoMovieInspectorKey.js\";\nimport { mountAutoMovieInspectorScene } from \"./mountAutoMovieInspectorScene.js\";\nimport { reduceAutoMovieInspectorState } from \"./reduceAutoMovieInspectorState.js\";\n\n/** No labels, the state before a paused picture places any. */\nconst UNLABELLED: IAutoMovieInspectorScene.ILabels = {\n labels: [],\n lineHeight: 0,\n dropped: 0,\n};\n\n/**\n * The inspection page as a React component: one canvas showing a subject through one request, and the panels that edit that request.\n *\n * The request is the component's only state that changes the picture. Every panel dispatches an edit to `reduceAutoMovieInspectorState`, the canvas is a plain three.js scene from `@automovie/render` mounted by `mountAutoMovieInspectorScene` in an effect, and every change of the request reaches `onRequestChange` as address text, so the page keeps its address equal to the request. The playhead is an `AutoMovieInspectorPlayhead` outside React that the render loop advances, so a playing frame re-renders only the time readout, and starting or stopping also the play button.\n *\n * The canvas has the transport directly under it. Beside it, or under the transport when the inspector is narrower than 900 pixels, a column holds one collapsible section per panel, each heading saying what is active: View and Shade start open, Marks, Selection and Request start closed, so a first look shows the picture and how it is drawn. While focus is inside the inspector, the playback keys of `handleAutoMovieInspectorKey` drive the playhead, except a key held with Ctrl, Meta or Alt and a key that goes to a control answering it itself.\n *\n * The mount effect depends on the chosen subject object only, which selectAutoMovieDrawSubject picks by the request's subject key, so each subject must keep its identity across renders; the request reaches a mounted scene through its `apply`, and a request the scene refuses is set back to the one it still draws, with the reason shown. Under StrictMode the mount effect runs, cleans up and runs again on the same canvas, which the mount supports with one renderer alive at the end.\n *\n * ```tsx\n * createRoot(element).render(\n * <AutoMovieInspector\n * subjects={subjects}\n * initialText={location.search}\n * onRequestChange={createAutoMovieInspectorAddressWriter({ location, history })}\n * />,\n * );\n * ```\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what the component shows and how it is laid out, where its state lives and changes, how the address follows it, why a playing frame renders only the readout and a start or stop the play button too, the keys, the effect split and the StrictMode behaviour, and shows the mount.\n * @evidence contracts/development/implementation.md#principled-implementation React owns layout and dispatch only: `useReducer` holds the request, `useEffect` owns the scene's lifetime per subject and forwards each request, and the canvas is drawn by three.js outside React's render, as the campaign decides against a React scene graph.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One component composes six panels, each a function of the request and a dispatch, five of them in collapsible sections of the platform's `details` element; every state change is the reducer's and every scene change the mount's.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No panel writes the scene, and a scene refusal is answered by restoring the request, never by drawing a picture the address does not name.\n * @evidence contracts/development/implementation.md#efficient-algorithms A dispatched edit renders the panels once and re-applies the inspection only when its text changed; a playing frame renders the readout alone, and a start or stop the play button too.\n * @evidence contracts/development/implementation.md#reuse-equivalent-work The mount, its renderer and its instance live while the subject stays; a request change reuses them.\n * @evidence contracts/development/implementation.md#bound-retention-and-release-resources The component owns one playhead and at most one mount at a time, disposed by the effect cleanup when the subject changes or the component unmounts.\n */\nexport function AutoMovieInspector(\n props: IAutoMovieInspectorProps,\n): JSX.Element {\n const [state, dispatch] = useReducer(\n reduceAutoMovieInspectorState,\n props.initialText,\n createAutoMovieInspectorState,\n );\n const [playhead] = useState<AutoMovieInspectorPlayhead>(\n (): AutoMovieInspectorPlayhead => new AutoMovieInspectorPlayhead(),\n );\n const [facts, setFacts] = useState<IAutoMovieInspectorScene.IFacts | null>(\n null,\n );\n const [legend, setLegend] = useState<IAutoMovieInspectionLegendEntry[]>([]);\n const [labels, setLabels] =\n useState<IAutoMovieInspectorScene.ILabels>(UNLABELLED);\n const [failure, setFailure] = useState<string | null>(null);\n const canvas: RefObject<HTMLCanvasElement | null> =\n useRef<HTMLCanvasElement>(null);\n const scene: RefObject<IAutoMovieInspectorScene | null> =\n useRef<IAutoMovieInspectorScene>(null);\n const { onRequestChange } = props;\n\n // A subject the request cannot name is shown as an error, with the subject choice still offered.\n const names: string[] = Object.keys(props.subjects);\n let name: string | null = null;\n let unnamed: string | null = null;\n try {\n name = selectAutoMovieDrawSubject(names, state.request.subject);\n } catch (error) {\n unnamed = error instanceof Error ? error.message : String(error);\n }\n\n // The scene lives as long as its subject; the effect reruns only then, so the request it captures is the one in force at mount.\n const request: IAutoMovieInspectorState[\"request\"] = state.request;\n const subject: IAutoMovieDrawSubject | null =\n name === null ? null : props.subjects[name]!;\n useEffect((): (() => void) | undefined => {\n if (canvas.current === null || subject === null || name === null)\n return undefined;\n const mounted: IAutoMovieInspectorScene = mountAutoMovieInspectorScene({\n subject,\n name,\n request,\n playhead,\n host: createAutoMovieInspectorCanvasHost(canvas.current),\n report: {\n ready: setFacts,\n legend: setLegend,\n labels: setLabels,\n error: setFailure,\n refused: (\n drawn: IAutoMovieInspectorState[\"request\"],\n message: string,\n ): void =>\n dispatch({ type: \"restore\", request: drawn, error: message }),\n },\n });\n scene.current = mounted;\n return (): void => {\n scene.current = null;\n setFacts(null);\n setLabels(UNLABELLED);\n mounted.dispose();\n };\n }, [subject, name, playhead]);\n\n // Every request reaches the scene and the page's address.\n useEffect((): void => {\n scene.current?.apply(request);\n onRequestChange?.(formatAutoMovieInspectorAddress(request));\n }, [request, onRequestChange]);\n\n // The column of sections moves under the transport when the inspector is\n // too narrow for both, measured on the inspector itself, since the page's\n // width is not the component's.\n const root: RefObject<HTMLDivElement | null> = useRef<HTMLDivElement>(null);\n const [narrow, setNarrow]: [boolean, Dispatch<SetStateAction<boolean>>] =\n useState<boolean>(false);\n useEffect((): (() => void) | undefined => {\n if (root.current === null || typeof ResizeObserver === \"undefined\")\n return undefined;\n const observer: ResizeObserver = new ResizeObserver(\n (entries: ResizeObserverEntry[]): void =>\n setNarrow((entries[0]?.contentRect.width ?? NARROW) < NARROW),\n );\n observer.observe(root.current);\n return (): void => observer.disconnect();\n }, []);\n\n // The playback keys, while focus is in the inspector; the handler leaves a\n // shortcut and a key a control answers itself to the page.\n const keys: (event: KeyboardEvent<HTMLDivElement>) => void = (\n event: KeyboardEvent<HTMLDivElement>,\n ): void => {\n const result: { handled: boolean; seconds: number | null } =\n handleAutoMovieInspectorKey(\n {\n key: event.key,\n ctrlKey: event.ctrlKey,\n metaKey: event.metaKey,\n altKey: event.altKey,\n target: event.target instanceof Element ? event.target : null,\n },\n playhead,\n facts?.fps ?? null,\n );\n if (!result.handled) return;\n event.preventDefault();\n if (result.seconds !== null)\n dispatch({ type: \"time\", seconds: result.seconds });\n };\n\n const inspection: IAutoMovieInspectorState[\"request\"][\"inspection\"] =\n request.inspection;\n return (\n <div\n ref={root}\n onKeyDown={keys}\n style={{\n display: \"flex\",\n flexDirection: narrow ? \"column\" : \"row\",\n gap: 12,\n fontFamily: \"sans-serif\",\n fontSize: 13,\n }}\n >\n <div style={{ flex: \"1 1 auto\", minWidth: 0 }}>\n <div style={{ position: \"relative\" }}>\n <canvas\n ref={canvas}\n tabIndex={0}\n role=\"application\"\n aria-label=\"The inspected picture; Space or K plays or pauses, J and L seek a second, comma and full stop step a frame, Home and End go to the ends\"\n style={{\n display: \"block\",\n width: \"100%\",\n aspectRatio:\n facts === null ? \"16 / 9\" : `${facts.width} / ${facts.height}`,\n background: \"#222\",\n }}\n />\n {labels.labels.map(\n (\n label: IAutoMovieInspectorScene.ILabels[\"labels\"][number],\n ): JSX.Element => (\n <span\n key={label.path}\n style={{\n position: \"absolute\",\n left: label.left,\n top: label.top,\n height: labels.lineHeight,\n fontSize: labels.lineHeight * 0.8,\n lineHeight: `${labels.lineHeight}px`,\n fontFamily: \"monospace\",\n background: \"#000\",\n color: \"#fff\",\n whiteSpace: \"nowrap\",\n pointerEvents: \"none\",\n }}\n >\n {label.text}\n </span>\n ),\n )}\n </div>\n <AutoMovieInspectorTimePanel\n playhead={playhead}\n fps={facts?.fps ?? null}\n dispatch={dispatch}\n />\n {[unnamed, failure, state.error]\n .filter(\n (message: string | null): message is string => message !== null,\n )\n .map(\n (message: string): JSX.Element => (\n <p\n key={message}\n role=\"alert\"\n style={{ color: \"#c00\", margin: \"4px 0\" }}\n >\n {message}\n </p>\n ),\n )}\n </div>\n <div\n style={\n narrow\n ? { width: \"100%\" }\n : { flex: \"0 0 300px\", overflowY: \"auto\", maxHeight: \"100vh\" }\n }\n >\n {names.length > 1 ? (\n <label style={{ display: \"block\", marginBottom: 8 }}>\n Subject{\" \"}\n <select\n value={request.subject ?? \"\"}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void =>\n dispatch({\n type: \"subject\",\n name: event.target.value === \"\" ? null : event.target.value,\n })\n }\n >\n <option value=\"\">(choose)</option>\n {names.map(\n (candidate: string): JSX.Element => (\n <option key={candidate} value={candidate}>\n {candidate}\n </option>\n ),\n )}\n </select>\n </label>\n ) : null}\n <Section title=\"View\" open>\n <AutoMovieInspectorViewPanel\n request={request}\n views={facts?.views ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Shade\" open>\n <AutoMovieInspectorShadePanel request={request} dispatch={dispatch} />\n </Section>\n <Section\n title=\"Marks\"\n note={\n inspection.marks.length === 0\n ? \"none on\"\n : `${inspection.marks.length} on`\n }\n >\n <AutoMovieInspectorMarksPanel\n request={request}\n marks={facts?.marks ?? []}\n legend={legend}\n dispatch={dispatch}\n />\n </Section>\n <Section\n title=\"Selection\"\n note={\n inspection.parts.length +\n inspection.hide.length +\n inspection.label.length +\n inspection.color.length ===\n 0\n ? `${facts?.paths.length ?? 0} paths`\n : `${inspection.parts.length} selected, ${inspection.hide.length} hidden, ${inspection.label.length} labelled`\n }\n >\n <AutoMovieInspectorSelectionPanel\n request={request}\n paths={facts?.paths ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Request\" note=\"address and capture command\">\n <AutoMovieInspectorRequestPanel\n request={request}\n dispatch={dispatch}\n />\n </Section>\n </div>\n </div>\n );\n}\n\n/** Below this width, in pixels, the sections move under the transport. */\nconst NARROW: number = 900;\n\n/** One collapsible section of the column: a heading that says what is active, over its panel. */\nfunction Section(props: {\n title: string;\n note?: string;\n open?: boolean;\n children: ReactNode;\n}): JSX.Element {\n return (\n <details\n open={props.open === true}\n style={{ borderTop: \"1px solid #ddd\", padding: \"6px 0\" }}\n >\n <summary style={{ cursor: \"pointer\", fontWeight: 600 }}>\n {props.title}\n {props.note === undefined ? null : (\n <span style={{ fontWeight: \"normal\", color: \"#666\" }}>\n : {props.note}\n </span>\n )}\n </summary>\n <div style={{ paddingTop: 6 }}>{props.children}</div>\n </details>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAkCA,MAAM,aAA+C;CACnD,QAAQ,CAAC;CACT,YAAY;CACZ,SAAS;AACX;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,SAAgB,mBACd,OACa;CACb,MAAM,CAAC,OAAO,YAAY,WACxB,+BACA,MAAM,aACN,6BACF;CACA,MAAM,CAAC,YAAY,eACiB,IAAI,2BAA2B,CACnE;CACA,MAAM,CAAC,OAAO,YAAY,SACxB,IACF;CACA,MAAM,CAAC,QAAQ,aAAa,SAA4C,CAAC,CAAC;CAC1E,MAAM,CAAC,QAAQ,aACb,SAA2C,UAAU;CACvD,MAAM,CAAC,SAAS,cAAc,SAAwB,IAAI;CAC1D,MAAM,SACJ,OAA0B,IAAI;CAChC,MAAM,QACJ,OAAiC,IAAI;CACvC,MAAM,EAAE,oBAAoB;CAG5B,MAAM,QAAkB,OAAO,KAAK,MAAM,QAAQ;CAClD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,OAAO,WAAW,WAAW,MAAM,OAAO;KAGxG,UAAA,oBAAC,kCAAD;MACW;MACT,OAAO,OAAO,SAAS,CAAC;MACd;KACX,CAAA;IACM,CAAA;IACT,oBAAC,SAAD;KAAS,OAAM;KAAU,MAAK;KAC5B,UAAA,oBAAC,gCAAD;MACW;MACC;KACX,CAAA;IACM,CAAA;GACN;EACF,CAAA,CAAA;;AAET;;AAGA,MAAM,SAAiB;;AAGvB,SAAS,QAAQ,OAKD;CACd,OACE,qBAAC,WAAD;EACE,MAAM,MAAM,SAAS;EACrB,OAAO;GAAE,WAAW;GAAkB,SAAS;EAAQ;EAFzD,UAAA,CAIE,qBAAC,WAAD;GAAS,OAAO;IAAE,QAAQ;IAAW,YAAY;GAAI;GAArD,UAAA,CACG,MAAM,OACN,MAAM,SAAS,KAAA,IAAY,OAC1B,qBAAC,QAAD;IAAM,OAAO;KAAE,YAAY;KAAU,OAAO;IAAO;IAAnD,UAAA,CAAsD,MACjD,MAAM,IACL;GAED,CAAA,CAAA;EACT,CAAA,GAAA,oBAAC,OAAD;GAAK,OAAO,EAAE,YAAY,EAAE;GAAI,UAAA,MAAM;EAAc,CAAA,CAC7C;;AAEb"}
@@ -1,4 +1,5 @@
1
- import { type IApplyAutoMovieInspectionProps, type IAutoMovieCapturePlanRequest, type IAutoMovieInspectionLegendEntry } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest, IAutoMovieInspectionLegendEntry } from "@automovie/interface";
2
+ import { type IApplyAutoMovieInspectionProps } from "@automovie/render";
2
3
  import type { JSX } from "react";
3
4
  import type { IAutoMovieInspectorAction } from "./IAutoMovieInspectorAction.js";
4
5
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorMarksPanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorMarksPanel.tsx"],"names":[],"mappings":";;;;AAAA,8CAM2B;AAK3B;;;;;;;;;;;;GAYG;AACH,sCAA6C,KAY5C;IACC,MAAM,KAAK,GAAa,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AC,EAAE;6BAC5D,GACD,EACD,KAAK,CAAC,KAAK,QAAI,KAAK,CAAC,KAAK,KAVpB,GAAG,KAAK,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,EAAE,CAWnC,CACN,CACF,GACE,IACI,CACZ,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"AutoMovieInspectorMarksPanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorMarksPanel.tsx"],"names":[],"mappings":";;;;AACA,8CAAsG;AAKtG;;;;;;;;;;;;GAYG;AACH,sCAA6C,KAY5C;IACC,MAAM,KAAK,GAAa,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC;IACvD,MAAM,KAAK,GAA+B,IAAA,qCAA4B,EAAC;QACrE,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,UAAU;QACjC,KAAK,EAAE,KAAK,CAAC,KAAK;KACnB,CAAC,CAAC;IACH,MAAM,MAAM,GAAwB,IAAI,GAAG,CACzC,KAAK,CAAC,GAAG,CAAC,CAAC,KAA+B,EAAoB,EAAE,CAAC;QAC/D,KAAK,CAAC,IAAI;QACV,KAAK,CAAC,KAAK;KACZ,CAAC,CACH,CAAC;IACF,MAAM,MAAM,GAAa;QACvB,GAAG,IAAI,GAAG,CAAS;YACjB,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC,KAA+B,EAAU,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC;YACrE,GAAG,KAAK;SACT,CAAC;KACH,CAAC;IACF,OAAO,CACL,sCAAU,KAAK,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,aAChE,mCACE,KAAK,EAAE;oBACL,QAAQ,EAAE,UAAU;oBACpB,KAAK,EAAE,CAAC;oBACR,MAAM,EAAE,CAAC;oBACT,QAAQ,EAAE,QAAQ;oBAClB,QAAQ,EAAE,YAAY;oBACtB,UAAU,EAA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,MAAM,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,SAAS,EAAE,YAC5D,KAAK,CAAC,MAAM,CAAC,GAAG,CACf,CAAC,KAAsC,EAAe,EAAE,CAAC,CACvD,2CACE,iCACE,KAAK,EAAE;gCACL,OAAO,EAAE,cAAc;gCACvB,KAAK,EAAE,EAAE;gCACT,MAAM,EAAE,EAAE;gCACV,WAAW,EAAE,CAAC;gCACd,UAAU,EAAE,IAAI,KAAK,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE;6BAC5D,GACD,EACD,KAAK,CAAC,KAAK,QAAI,KAAK,CAAC,KAAK,KAVpB,GAAG,KAAK,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,EAAE,CAWnC,CACN,CACF,GACE,IACI,CACZ,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorMarksPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorMarksPanel.tsx"],"sourcesContent":["import {\n type IApplyAutoMovieInspectionProps,\n type IAutoMovieCapturePlanRequest,\n type IAutoMovieInspectionKind,\n type IAutoMovieInspectionLegendEntry,\n listAutoMovieInspectionKinds,\n} from \"@automovie/render\";\nimport type { ChangeEvent, JSX } from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\n\n/**\n * Marks: the kinds the picture can draw, each with its default colour and switched by its own kind pattern, the x-ray switch, and the legend of what the picture draws.\n *\n * The kinds are render's `listAutoMovieInspectionKinds` of the supplied marks under the request in force, so a sliver limit or a trail adds its kinds as soon as it is asked for. A kind is checked when the request's `marks` holds that kind as a pattern; patterns typed in the address, such as `defect/*`, stay in the request and are listed beside the kinds. The legend is the inspection's: each colour drawn, what it marks and how many marks carry it.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what is listed, when a kind is checked, where typed patterns appear and what the legend counts.\n * @evidence contracts/development/implementation.md#principled-implementation The kinds come from render's one kind list and the legend from render's inspection handle, so the panel restates no kind rule and invents no colour.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One checkbox per kind, one switch, one list of legend entries.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts A typed pattern that is not a listed kind is shown with its own checkbox rather than dropped.\n * @evidence contracts/development/implementation.md#efficient-algorithms Linear in the supplied marks, the kinds, the patterns and the legend.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds nothing.\n */\nexport function AutoMovieInspectorMarksPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** The marks the subject supplies, from which the kinds are listed. */\n marks: NonNullable<IApplyAutoMovieInspectionProps[\"marks\"]>;\n\n /** The legend of the current picture. */\n legend: readonly IAutoMovieInspectionLegendEntry[];\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const marks: string[] = props.request.inspection.marks;\n const kinds: IAutoMovieInspectionKind[] = listAutoMovieInspectionKinds({\n request: props.request.inspection,\n marks: props.marks,\n });\n const colors: Map<string, number> = new Map<string, number>(\n kinds.map((entry: IAutoMovieInspectionKind): [string, number] => [\n entry.kind,\n entry.color,\n ]),\n );\n const listed: string[] = [\n ...new Set<string>([\n ...kinds.map((entry: IAutoMovieInspectionKind): string => entry.kind),\n ...marks,\n ]),\n ];\n return (\n <fieldset style={{ border: 0, padding: 0, margin: 0, minWidth: 0 }}>\n <legend\n style={{\n position: \"absolute\",\n width: 1,\n height: 1,\n overflow: \"hidden\",\n clipPath: \"inset(50%)\",\n whiteSpace: \"nowrap\",\n }}\n >\n Marks\n </legend>\n {listed.map(\n (kind: string): JSX.Element => (\n <label key={kind} style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={marks.includes(kind)}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n props.dispatch({\n type: \"marks\",\n pattern: kind,\n on: event.target.checked,\n })\n }\n />{\" \"}\n {colors.has(kind) ? (\n <span\n style={{\n display: \"inline-block\",\n width: 10,\n height: 10,\n marginRight: 4,\n background: `#${colors.get(kind)!.toString(16).padStart(6, \"0\")}`,\n }}\n />\n ) : null}\n {kind}\n </label>\n ),\n )}\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={props.request.inspection.xray}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n props.dispatch({\n type: \"switch\",\n key: \"xray\",\n on: event.target.checked,\n })\n }\n />{\" \"}\n x-ray\n </label>\n <ul style={{ listStyle: \"none\", padding: 0, margin: \"6px 0 0\" }}>\n {props.legend.map(\n (entry: IAutoMovieInspectionLegendEntry): JSX.Element => (\n <li key={`${entry.label}:${entry.color}`}>\n <span\n style={{\n display: \"inline-block\",\n width: 10,\n height: 10,\n marginRight: 6,\n background: `#${entry.color.toString(16).padStart(6, \"0\")}`,\n }}\n />\n {entry.label} x{entry.count}\n </li>\n ),\n )}\n </ul>\n </fieldset>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAwBA,SAAgB,6BAA6B,OAY7B;CACd,MAAM,QAAkB,MAAM,QAAQ,WAAW;CACjD,MAAM,QAAoC,6BAA6B;EACrE,SAAS,MAAM,QAAQ;EACvB,OAAO,MAAM;CACf,CAAC;CACD,MAAM,SAA8B,IAAI,IACtC,MAAM,KAAK,UAAsD,CAC/D,MAAM,MACN,MAAM,KACR,CAAC,CACH;CACA,MAAM,SAAmB,CACvB,mBAAG,IAAI,IAAY,CACjB,GAAG,MAAM,KAAK,UAA4C,MAAM,IAAI,GACpE,GAAG,KACL,CAAC,CACH;CACA,OACE,qBAAC,YAAD;EAAU,OAAO;GAAE,QAAQ;GAAG,SAAS;GAAG,QAAQ;GAAG,UAAU;EAAE;EAAjE,UAAA;GACE,oBAAC,UAAD;IACE,OAAO;KACL,UAAU;KACV,OAAO;KACP,QAAQ;KACR,UAAU;KACV,UAA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../src/inspector/AutoMovieInspectorMarksPanel.tsx"],"sourcesContent":["import type { IAutoMovieCapturePlanRequest, IAutoMovieInspectionKind, IAutoMovieInspectionLegendEntry } from \"@automovie/interface\";\nimport { type IApplyAutoMovieInspectionProps, listAutoMovieInspectionKinds } from \"@automovie/render\";\nimport type { ChangeEvent, JSX } from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\n\n/**\n * Marks: the kinds the picture can draw, each with its default colour and switched by its own kind pattern, the x-ray switch, and the legend of what the picture draws.\n *\n * The kinds are render's `listAutoMovieInspectionKinds` of the supplied marks under the request in force, so a sliver limit or a trail adds its kinds as soon as it is asked for. A kind is checked when the request's `marks` holds that kind as a pattern; patterns typed in the address, such as `defect/*`, stay in the request and are listed beside the kinds. The legend is the inspection's: each colour drawn, what it marks and how many marks carry it.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what is listed, when a kind is checked, where typed patterns appear and what the legend counts.\n * @evidence contracts/development/implementation.md#principled-implementation The kinds come from render's one kind list and the legend from render's inspection handle, so the panel restates no kind rule and invents no colour.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One checkbox per kind, one switch, one list of legend entries.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts A typed pattern that is not a listed kind is shown with its own checkbox rather than dropped.\n * @evidence contracts/development/implementation.md#efficient-algorithms Linear in the supplied marks, the kinds, the patterns and the legend.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds nothing.\n */\nexport function AutoMovieInspectorMarksPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** The marks the subject supplies, from which the kinds are listed. */\n marks: NonNullable<IApplyAutoMovieInspectionProps[\"marks\"]>;\n\n /** The legend of the current picture. */\n legend: readonly IAutoMovieInspectionLegendEntry[];\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const marks: string[] = props.request.inspection.marks;\n const kinds: IAutoMovieInspectionKind[] = listAutoMovieInspectionKinds({\n request: props.request.inspection,\n marks: props.marks,\n });\n const colors: Map<string, number> = new Map<string, number>(\n kinds.map((entry: IAutoMovieInspectionKind): [string, number] => [\n entry.kind,\n entry.color,\n ]),\n );\n const listed: string[] = [\n ...new Set<string>([\n ...kinds.map((entry: IAutoMovieInspectionKind): string => entry.kind),\n ...marks,\n ]),\n ];\n return (\n <fieldset style={{ border: 0, padding: 0, margin: 0, minWidth: 0 }}>\n <legend\n style={{\n position: \"absolute\",\n width: 1,\n height: 1,\n overflow: \"hidden\",\n clipPath: \"inset(50%)\",\n whiteSpace: \"nowrap\",\n }}\n >\n Marks\n </legend>\n {listed.map(\n (kind: string): JSX.Element => (\n <label key={kind} style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={marks.includes(kind)}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n props.dispatch({\n type: \"marks\",\n pattern: kind,\n on: event.target.checked,\n })\n }\n />{\" \"}\n {colors.has(kind) ? (\n <span\n style={{\n display: \"inline-block\",\n width: 10,\n height: 10,\n marginRight: 4,\n background: `#${colors.get(kind)!.toString(16).padStart(6, \"0\")}`,\n }}\n />\n ) : null}\n {kind}\n </label>\n ),\n )}\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={props.request.inspection.xray}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n props.dispatch({\n type: \"switch\",\n key: \"xray\",\n on: event.target.checked,\n })\n }\n />{\" \"}\n x-ray\n </label>\n <ul style={{ listStyle: \"none\", padding: 0, margin: \"6px 0 0\" }}>\n {props.legend.map(\n (entry: IAutoMovieInspectionLegendEntry): JSX.Element => (\n <li key={`${entry.label}:${entry.color}`}>\n <span\n style={{\n display: \"inline-block\",\n width: 10,\n height: 10,\n marginRight: 6,\n background: `#${entry.color.toString(16).padStart(6, \"0\")}`,\n }}\n />\n {entry.label} x{entry.count}\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AAS,MAAM,QAAQ,WAAW;MAClC,WAAW,UACT,MAAM,SAAS;OACb,MAAM;OACN,KAAK;OACL,IAAI,MAAM,OAAO;MACnB,CAAC;KAEJ,CAAA;KAAE;KAAI;IAEF;;GACP,oBAAC,MAAD;IAAI,OAAO;KAAE,WAAW;KAAQ,SAAS;KAAG,QAAQ;IAAU;IAC3D,UAAA,MAAM,OAAO,KACX,UACC,qBAAC,MAAD,EAAA,UAAA;KACE,oBAAC,QAAD,EACE,OAAO;MACL,SAAS;MACT,OAAO;MACP,QAAQ;MACR,aAAa;MACb,YAAY,IAAI,MAAM,MAAM,SAAS,EAAE,CAAC,CAAC,SAAS,GAAG,GAAG;KAC1D,EACD,CAAA;KACA,MAAM;KAAM;KAAG,MAAM;IACpB,EAAA,GAXK,GAAG,MAAM,MAAM,GAAG,MAAM,OAW7B,CAER;GACE,CAAA;EACI;;AAEd"}
@@ -1,4 +1,4 @@
1
- import type { IAutoMovieCapturePlanRequest } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  import { type JSX } from "react";
3
3
  import type { IAutoMovieInspectorAction } from "./IAutoMovieInspectorAction.js";
4
4
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorRequestPanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorRequestPanel.tsx"],"names":[],"mappings":";;;;AACA,iCAOe;AAGf,6FAAuF;AACvF,6FAAuF;AAEvF;;;;;;;;;;;;GAYG;AACH,wCAA+C,KAM9C;IACC,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,IAAA,gBAAQ,EAAgB,IAAI,CAAC,CAAC;IACxD,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAGrB,IAAA,gBAAQ,EAAgB,IAAI,CAAC,CAAC;IAClC,MAAM,MAAM,GAAe,GAAS,EAAE;QACpC,IAAI,KAAK,KAAK,IAAI;YAAE,OAAO;QAC3B,QAAQ,CAAC,IAAI,CAAC,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AAE,CAAC,EAAE,UAAU,EAAE,WAAW,EAAE,EACjE,KAAK,EAAE,OAAO,EACd,QAAQ,EAAE,CAAC,KAAoC,EAAQ,EAAE,CACvD,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,EAE9B,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,CAAC,KAAsB,EAAQ,EAAE;oCAC1C,IAAI,KAAK,CAAC,GAAG,KAAK,OAAO;wCAAE,MAAM,EAAE,CAAC;gCACtC,CAAC,GACD,EACF,mCACE,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,GAAS,EAAE,CAAC,KAAK,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,6BAG3C,IACJ,IACD,EACR,mCAAO,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,EAAE,gCAEhC,kCAAM,KAAK,EAAE,GAAG,aACd,gDACa,iBAAiB,EAC5B,QAAQ,QACR,KAAK,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,QAAQ,EAAE,CAAC,EAAE,UAAU,EAAE,WAAW,EAAE,EACjE,KAAK,EAAE,OAAO,GACd,EACF,mCACE,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,GAAS,EAAE,CAAC,KAAK,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,6BAG3C,IACJ,IACD,EAGR,8BAAG,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,EAAE,YACxD,MAAM,IAAI,EAAE,GACX,IACA,CACP,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorRequestPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorRequestPanel.tsx"],"sourcesContent":["import type { IAutoMovieCapturePlanRequest } from \"@automovie/render\";\nimport {\n type CSSProperties,\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type SetStateAction,\n useState,\n} from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\nimport { formatAutoMovieInspectorAddress } from \"./formatAutoMovieInspectorAddress.js\";\nimport { formatAutoMovieInspectorCommand } from \"./formatAutoMovieInspectorCommand.js\";\n\n/**\n * The request as text: the address query, editable, and the `automovie capture` command that repeats the picture, each with a button named for what it copies.\n *\n * The query field shows the request's address text; an edit is dispatched as a `text` action when the field is left or Enter is pressed, and a text the grammar refuses keeps the previous request with the refusal shown above. The command is read-only, quoted for a POSIX shell. Copying writes the field's text to the clipboard where the page may, and says so under the fields, in a status region that stays mounted so each note is announced; where the page has no clipboard, as outside a secure context, or is refused it, the note says to select the text and copy it instead.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what each field shows, when an edit is dispatched, the refusal, the command's quoting, what copying does and what it says when the clipboard is missing or refused.\n * @evidence contracts/development/implementation.md#principled-implementation Both texts are written from the request by the grammar's writers, so the address, the command and the picture name one request; copying goes through the platform's clipboard.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One editable field and one read-only field, each with a copy button.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts The typed text is held only until it is dispatched; the request stays the reducer's; a missing or refused clipboard is reported, never swallowed or thrown.\n * @evidence contracts/development/implementation.md#efficient-algorithms Two writes of the request per render, linear in its text.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds only the text being typed and the last copy's note.\n */\nexport function AutoMovieInspectorRequestPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** Where an edited text goes. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const [typed, setTyped] = useState<string | null>(null);\n const [copied, setCopied]: [\n string | null,\n Dispatch<SetStateAction<string | null>>,\n ] = useState<string | null>(null);\n const commit: () => void = (): void => {\n if (typed === null) return;\n setTyped(null);\n props.dispatch({ type: \"text\", text: typed });\n };\n // A page outside a secure context has no clipboard, and a page may be\n // refused it; either is reported with what to do instead.\n const copy: (name: string, text: string) => Promise<void> = async (\n name: string,\n text: string,\n ): Promise<void> => {\n const refused: string = `Select the ${name} and copy it.`;\n const clipboard: Clipboard | undefined = (\n navigator as Navigator & { clipboard?: Clipboard }\n ).clipboard;\n if (clipboard === undefined) {\n setCopied(refused);\n return;\n }\n try {\n await clipboard.writeText(text);\n setCopied(`The ${name} was copied.`);\n } catch {\n setCopied(refused);\n }\n };\n const address: string =\n typed ?? formatAutoMovieInspectorAddress(props.request);\n const command: string = formatAutoMovieInspectorCommand(props.request).text;\n const row: CSSProperties = {\n display: \"flex\",\n gap: 4,\n alignItems: \"center\",\n };\n return (\n <div>\n <label style={{ display: \"block\", marginBottom: 6 }}>\n Address\n <span style={row}>\n <input\n aria-label=\"Request address\"\n style={{ flex: \"1 1 auto\", minWidth: 0, fontFamily: \"monospace\" }}\n value={address}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setTyped(event.target.value)\n }\n onBlur={commit}\n onKeyDown={(event: { key: string }): void => {\n if (event.key === \"Enter\") commit();\n }}\n />\n <button\n type=\"button\"\n onClick={(): void => void copy(\"address\", address)}\n >\n Copy address\n </button>\n </span>\n </label>\n <label style={{ display: \"block\" }}>\n Capture command\n <span style={row}>\n <input\n aria-label=\"Capture command\"\n readOnly\n style={{ flex: \"1 1 auto\", minWidth: 0, fontFamily: \"monospace\" }}\n value={command}\n />\n <button\n type=\"button\"\n onClick={(): void => void copy(\"command\", command)}\n >\n Copy command\n </button>\n </span>\n </label>\n {/* The live region stays mounted and only its text changes, so each\n copy's note is announced. */}\n <p role=\"status\" style={{ margin: \"4px 0 0\", fontSize: 12 }}>\n {copied ?? \"\"}\n </p>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AA2BA,SAAgB,+BAA+B,OAM/B;CACd,MAAM,CAAC,OAAO,YAAY,SAAwB,IAAI;CACtD,MAAM,CAAC,QAAQ,aAGX,SAAwB,IAAI;CAChC,MAAM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ChE,OAAO;IACR,CAAA,GACD,oBAAC,UAAD;KACE,MAAK;KACL,eAAqB,KAAK,KAAK,WAAW,OAAO;KAClD,UAAA;IAEO,CAAA,CACJ;GACD,CAAA,CAAA;;EAGP,oBAAC,KAAD;GAAG,MAAK;GAAS,OAAO;IAAE,QAAQ;IAAW,UAAU;GAAG;GACvD,UAAA,UAAU;EACV,CAAA;CACA,EAAA,CAAA;AAET"}
1
+ {"version":3,"file":"AutoMovieInspectorRequestPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorRequestPanel.tsx"],"sourcesContent":["import type { IAutoMovieCapturePlanRequest } from \"@automovie/interface\";\n\nimport {\n type CSSProperties,\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type SetStateAction,\n useState,\n} from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\nimport { formatAutoMovieInspectorAddress } from \"./formatAutoMovieInspectorAddress.js\";\nimport { formatAutoMovieInspectorCommand } from \"./formatAutoMovieInspectorCommand.js\";\n\n/**\n * The request as text: the address query, editable, and the `automovie capture` command that repeats the picture, each with a button named for what it copies.\n *\n * The query field shows the request's address text; an edit is dispatched as a `text` action when the field is left or Enter is pressed, and a text the grammar refuses keeps the previous request with the refusal shown above. The command is read-only, quoted for a POSIX shell. Copying writes the field's text to the clipboard where the page may, and says so under the fields, in a status region that stays mounted so each note is announced; where the page has no clipboard, as outside a secure context, or is refused it, the note says to select the text and copy it instead.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what each field shows, when an edit is dispatched, the refusal, the command's quoting, what copying does and what it says when the clipboard is missing or refused.\n * @evidence contracts/development/implementation.md#principled-implementation Both texts are written from the request by the grammar's writers, so the address, the command and the picture name one request; copying goes through the platform's clipboard.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One editable field and one read-only field, each with a copy button.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts The typed text is held only until it is dispatched; the request stays the reducer's; a missing or refused clipboard is reported, never swallowed or thrown.\n * @evidence contracts/development/implementation.md#efficient-algorithms Two writes of the request per render, linear in its text.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds only the text being typed and the last copy's note.\n */\nexport function AutoMovieInspectorRequestPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** Where an edited text goes. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const [typed, setTyped] = useState<string | null>(null);\n const [copied, setCopied]: [\n string | null,\n Dispatch<SetStateAction<string | null>>,\n ] = useState<string | null>(null);\n const commit: () => void = (): void => {\n if (typed === null) return;\n setTyped(null);\n props.dispatch({ type: \"text\", text: typed });\n };\n // A page outside a secure context has no clipboard, and a page may be\n // refused it; either is reported with what to do instead.\n const copy: (name: string, text: string) => Promise<void> = async (\n name: string,\n text: string,\n ): Promise<void> => {\n const refused: string = `Select the ${name} and copy it.`;\n const clipboard: Clipboard | undefined = (\n navigator as Navigator & { clipboard?: Clipboard }\n ).clipboard;\n if (clipboard === undefined) {\n setCopied(refused);\n return;\n }\n try {\n await clipboard.writeText(text);\n setCopied(`The ${name} was copied.`);\n } catch {\n setCopied(refused);\n }\n };\n const address: string =\n typed ?? formatAutoMovieInspectorAddress(props.request);\n const command: string = formatAutoMovieInspectorCommand(props.request).text;\n const row: CSSProperties = {\n display: \"flex\",\n gap: 4,\n alignItems: \"center\",\n };\n return (\n <div>\n <label style={{ display: \"block\", marginBottom: 6 }}>\n Address\n <span style={row}>\n <input\n aria-label=\"Request address\"\n style={{ flex: \"1 1 auto\", minWidth: 0, fontFamily: \"monospace\" }}\n value={address}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setTyped(event.target.value)\n }\n onBlur={commit}\n onKeyDown={(event: { key: string }): void => {\n if (event.key === \"Enter\") commit();\n }}\n />\n <button\n type=\"button\"\n onClick={(): void => void copy(\"address\", address)}\n >\n Copy address\n </button>\n </span>\n </label>\n <label style={{ display: \"block\" }}>\n Capture command\n <span style={row}>\n <input\n aria-label=\"Capture command\"\n readOnly\n style={{ flex: \"1 1 auto\", minWidth: 0, fontFamily: \"monospace\" }}\n value={command}\n />\n <button\n type=\"button\"\n onClick={(): void => void copy(\"command\", command)}\n >\n Copy command\n </button>\n </span>\n </label>\n {/* The live region stays mounted and only its text changes, so each\n copy's note is announced. */}\n <p role=\"status\" style={{ margin: \"4px 0 0\", fontSize: 12 }}>\n {copied ?? \"\"}\n </p>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AA4BA,SAAgB,+BAA+B,OAM/B;CACd,MAAM,CAAC,OAAO,YAAY,SAAwB,IAAI;CACtD,MAAM,CAAC,QAAQ,aAGX,SAAwB,IAAI;CAChC,MAAM,eAAiC;EACrC,IAAI,UAAU,MAAM;EACpB,SAAS,IAAI;EACb,MAAM,SAAS;GAAE,MAAM;GAAQ,MAAM;EAAM,CAAC;CAC9C;CAGA,MAAM,OAAsD,OAC1D,MACA,SACkB;EAClB,MAAM,UAAkB,cAAc,KAAK;EAC3C,MAAM,YACJ,UACA;EACF,IAAI,cAAc,KAAA,GAAW;GAC3B,UAAU,OAAO;GACjB;EACF;EACA,IAAI;GACF,MAAM,UAAU,UAAU,IAAI;GAC9B,UAAU,OAAO,KAAK,aAAa;EACrC,QAAQ;GACN,UAAU,OAAO;EACnB;CACF;CACA,MAAM,UACJ,SAAS,gCAAgC,MAAM,OAAO;CACxD,MAAM,UAAkB,gCAAgC,MAAM,OAAO,CAAC,CAAC;CACvE,MAAM,MAAqB;EACzB,SAAS;EACT,KAAK;EACL,YAAY;CACd;CACA,OACE,qBAAC,OAAD,EAAA,UAAA;EACE,qBAAC,SAAD;GAAO,OAAO;IAAE,SAAS;IAAS,cAAc;GAAE;GAAlD,UAAA,CAAqD,WAEnD,qBAAC,QAAD;IAAM,OAAO;IAAb,UAAA,CACE,oBAAC,SAAD;KACE,cAAW;KACX,OAAO;MAAE,MAAM;MAAY,UAAU;MAAG,YAAY;KAAY;KAChE,OAAO;KACP,WAAW,UACT,SAAS,MAAM,OAAO,KAAK;KAE7B,QAAQ;KACR,YAAY,UAAiC;MAC3C,IAAI,MAAM,QAAQ,SAAS,OAAO;KACpC;IACD,CAAA,GACD,oBAAC,UAAD;KACE,MAAK;KACL,eAAqB,KAAK,KAAK,WAAW,OAAO;KAClD,UAAA;IAEO,CAAA,CACJ;GACD,CAAA,CAAA;;EACP,qBAAC,SAAD;GAAO,OAAO,EAAE,SAAS,QAAQ;GAAjC,UAAA,CAAoC,mBAElC,qBAAC,QAAD;IAAM,OAAO;IAAb,UAAA,CACE,oBAAC,SAAD;KACE,cAAW;KACX,UAAA;KACA,OAAO;MAAE,MAAM;MAAY,UAAU;MAAG,YAAY;KAAY;KAChE,OAAO;IACR,CAAA,GACD,oBAAC,UAAD;KACE,MAAK;KACL,eAAqB,KAAK,KAAK,WAAW,OAAO;KAClD,UAAA;IAEO,CAAA,CACJ;GACD,CAAA,CAAA;;EAGP,oBAAC,KAAD;GAAG,MAAK;GAAS,OAAO;IAAE,QAAQ;IAAW,UAAU;GAAG;GACvD,UAAA,UAAU;EACV,CAAA;CACA,EAAA,CAAA;AAET"}
@@ -1,4 +1,4 @@
1
- import type { IAutoMovieCapturePlanRequest } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  import { type JSX } from "react";
3
3
  import type { IAutoMovieInspectorAction } from "./IAutoMovieInspectorAction.js";
4
4
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorSelectionPanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorSelectionPanel.tsx"],"names":[],"mappings":";;;;AAIA,iCAOe;AAIf,6FAAuF;AAEvF,qFAAqF;AACrF,MAAM,MAAM,GAAW,EAAE,CAAC;AAE1B,gEAAgE;AAChE,MAAM,UAAU,GAAW,EAAE,CAAC;AAE9B;;;;;;;;;;;;;;GAcG;AACH,0C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AK,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,CACrB,uBAAC,GAAG,IAEF,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,UAAU,EACtB,QAAQ,EAAE,QAAQ,IAJb,KAAK,CAAC,IAAI,CAKf,CACH,CAAC,CAAC,CAAC,IAAI,CACX,GACE,CACN,CAAC,CAAC,CAAC,IAAI,IACL,CACN,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"AutoMovieInspectorSelectionPanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorSelectionPanel.tsx"],"names":[],"mappings":";;;;AAMA,iCAOe;AAIf,6FAAuF;AAGvF,qFAAqF;AACrF,MAAM,MAAM,GAAW,EAAE,CAAC;AAE1B,gEAAgE;AAChE,MAAM,UAAU,GAAW,EAAE,CAAC;AAE9B;;;;;;;;;;;;;;GAcG;AACH,0CAAiD,KAShD;IACC,MAAM,IAAI,GAAkC,IAAA,eAAO,EACjD,GAAkC,EAAE,CAClC,IAAA,oEAA+B,EAAC,KAAK,CAAC,KAAK,CAAC,EAC9C,CAAC,KAAK,CAAC,KAAK,CAAC,CACd,CAAC;IACF,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GACvB,IAAA,gBAAQ,EAAS,EAAE,CAAC,CAAC;IACvB,MAAM,MAAM,GAAW,MAAM,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;IACnD,OAAO,CACL,4CACE,kCACE,IAAI,EAAC,QAAQ,gBACF,cAAc,EACzB,WAAW,EAAC,cAAc,EAC1B,KAAK,EAAE,MAAM,EACb,KAAK,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,YAAY,EAAE,YAAY,EAAE,CAAC,EAAE,EAClE,QAAQ,EAAE,CAAC,KAAoC,EAAQ,EAAE,CACvD,SAAS,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,GAE/B,EACF,gDACc,MAAM,EAClB,KAAK,EAAE;o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AAC,CAAC,MAAM,EAAE,YACxD,KAAK,GACD,EACN,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CACb,iDAAkB,MAAM,EAAC,KAAK,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE,EAAE,aAC5D,GAAG,EACH,KAAK,CAAC,IAAI,CAAC,IACP,CACR,IACI,CACR,CAAC;IACF,IAAI,IAAI;QAAE,OAAO,yCAAK,QAAQ,GAAM,CAAC;IACrC,OAAO,CACL,2CACG,QAAQ,EACR,QAAQ,CAAC,CAAC,CAAC,CACV,+BAAI,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,YACzD,IAAI,CAAC,QAAQ,CAAC,GAAG,CAChB,CAAC,KAAkC,EAAsB,EAAE,CACzD,KAAK,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,CACrB,uBAAC,GAAG,IAEF,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,UAAU,EACtB,QAAQ,EAAE,QAAQ,IAJb,KAAK,CAAC,IAAI,CAKf,CACH,CAAC,CAAC,CAAC,IAAI,CACX,GACE,CACN,CAAC,CAAC,CAAC,IAAI,IACL,CACN,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorSelectionPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorSelectionPanel.tsx"],"sourcesContent":["import type {\n IAutoMovieCapturePlanRequest,\n IAutoMovieInspectionRequest,\n} from \"@automovie/render\";\nimport {\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type SetStateAction,\n useMemo,\n useState,\n} from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\nimport type { IAutoMovieInspectorPathNode } from \"./IAutoMovieInspectorPathNode.js\";\nimport { buildAutoMovieInspectorPathTree } from \"./buildAutoMovieInspectorPathTree.js\";\n\n/** The width of each of the three checkbox columns and the colour column, pixels. */\nconst COLUMN: number = 22;\n\n/** The width of the disclosure button before a name, pixels. */\nconst DISCLOSURE: number = 16;\n\n/**\n * Selection: the subject's identity paths as a tree, with select, hide, label and colour per path.\n *\n * A header names the four columns. Each node edits the request by its pattern, the one that selects the node and its subtree: a checkbox puts the pattern in or takes it out of `parts`, `hide` or `label`, and the colour input gives it a `color` pair, which the clear button takes back. A node is checked when its own pattern is in the list, so a pattern typed in the address that matches several nodes checks none of them, and stays in the request. The empty path has no pattern and only a name.\n *\n * A node with children is folded until opened, with the number of paths under it, so a figure's dozens of bones do not fill the panel. Its disclosure button, between the controls and the name, opens and folds it and states whether it is open; it sits beside the controls, never around them, so no control is nested in another. The filter keeps the nodes whose path contains the typed text, with their ancestors, and opens them; while it does, their disclosure buttons are disabled.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States the header, what each control edits, when a node is checked, what happens to typed patterns and the empty path, and how folding and the filter work.\n * @evidence contracts/development/implementation.md#principled-implementation The tree and each node's pattern come from `buildAutoMovieInspectorPathTree`, and every edit is a reducer action through the grammar, so the panel restates no path rule; folding is the disclosure pattern, a button with `aria-expanded` that owns no other control.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One memoized tree, one filter, and one recursive row per node.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts A checked state is read from the request, never kept in the panel; the filter hides rows and changes no request.\n * @evidence contracts/development/implementation.md#efficient-algorithms The tree is rebuilt only when the path list changes; a render is linear in the nodes times the lists' lengths, and a folded subtree is not rendered.\n * @evidence contracts/development/implementation.md#reuse-equivalent-work `useMemo` keeps the tree while the path list is the same array, which the mount reports once per instance.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds the memoized tree and the filter text only while mounted.\n */\nexport function AutoMovieInspectorSelectionPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** The subject's identity paths in scene order. */\n paths: readonly string[];\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const tree: IAutoMovieInspectorPathNode[] = useMemo(\n (): IAutoMovieInspectorPathNode[] =>\n buildAutoMovieInspectorPathTree(props.paths),\n [props.paths],\n );\n const [filter, setFilter]: [string, Dispatch<SetStateAction<string>>] =\n useState<string>(\"\");\n const needle: string = filter.trim().toLowerCase();\n return (\n <div>\n <input\n type=\"search\"\n aria-label=\"Filter paths\"\n placeholder=\"Filter paths\"\n value={filter}\n style={{ width: \"100%\", boxSizing: \"border-box\", marginBottom: 6 }}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setFilter(event.target.value)\n }\n />\n <div\n aria-hidden=\"true\"\n style={{\n display: \"flex\",\n fontSize: 11,\n color: \"#555\",\n borderBottom: \"1px solid #ccc\",\n marginBottom: 2,\n }}\n >\n {[\"Select\", \"Hide\", \"Label\", \"Colour\"].map(\n (name: string): JSX.Element => (\n <span\n key={name}\n title={name}\n style={{\n width: COLUMN,\n overflow: \"hidden\",\n textAlign: \"center\",\n writingMode: \"vertical-rl\",\n transform: \"rotate(180deg)\",\n height: 40,\n }}\n >\n {name}\n </span>\n ),\n )}\n <span style={{ alignSelf: \"flex-end\", paddingLeft: 6 }}>Path</span>\n </div>\n <ul style={{ listStyle: \"none\", paddingLeft: 0, margin: 0 }}>\n {tree.map((node: IAutoMovieInspectorPathNode): JSX.Element | null =>\n shown(node, needle) ? (\n <Row\n key={node.path}\n node={node}\n needle={needle}\n inspection={props.request.inspection}\n dispatch={props.dispatch}\n />\n ) : null,\n )}\n </ul>\n </div>\n );\n}\n\n/** Whether a node or any node under it matches the filter. */\nfunction shown(node: IAutoMovieInspectorPathNode, needle: string): boolean {\n return (\n needle === \"\" ||\n node.path.toLowerCase().includes(needle) ||\n node.children.some((child: IAutoMovieInspectorPathNode): boolean =>\n shown(child, needle),\n )\n );\n}\n\n/** The number of paths under a node. */\nfunction count(node: IAutoMovieInspectorPathNode): number {\n return node.children.reduce(\n (sum: number, child: IAutoMovieInspectorPathNode): number =>\n sum + 1 + count(child),\n 0,\n );\n}\n\n/** One node with its controls and, folded until opened, its children. */\nfunction Row(props: {\n node: IAutoMovieInspectorPathNode;\n needle: string;\n inspection: IAutoMovieInspectionRequest;\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const { node, needle, inspection, dispatch }: typeof props = props;\n const [open, setOpen]: [boolean, Dispatch<SetStateAction<boolean>>] =\n useState<boolean>(false);\n const pattern: string | null = node.pattern;\n const color: IAutoMovieInspectionRequest.IColor | undefined =\n pattern === null\n ? undefined\n : inspection.color.find(\n (entry: IAutoMovieInspectionRequest.IColor): boolean =>\n entry.pattern === pattern,\n );\n const label: string = node.name === \"\" ? \"(unnamed)\" : node.name;\n\n // A filter opens every node it keeps, so the matches are seen.\n const expanded: boolean = open || needle !== \"\";\n const toggle: (\n type: IAutoMovieInspectorAction.IToggle[\"type\"],\n list: readonly string[],\n ) => JSX.Element = (\n type: IAutoMovieInspectorAction.IToggle[\"type\"],\n list: readonly string[],\n ): JSX.Element => (\n <input\n type=\"checkbox\"\n aria-label={`${type} ${label}`}\n disabled={pattern === null}\n checked={pattern !== null && list.includes(pattern)}\n style={{ width: COLUMN - 8, margin: \"0 4px\" }}\n onChange={(event: ChangeEvent<HTMLInputElement>): void => {\n if (pattern !== null)\n dispatch({ type, pattern, on: event.target.checked });\n }}\n />\n );\n // A node with children has a disclosure button between its controls and\n // its name, beside them rather than around them, so no control sits inside\n // another; a leaf keeps the button's width, so the names stay aligned.\n const leaf: boolean = node.children.length === 0;\n const disclosure: JSX.Element = leaf ? (\n <span style={{ display: \"inline-block\", width: DISCLOSURE }} />\n ) : (\n <button\n type=\"button\"\n aria-expanded={expanded}\n aria-label={`${label}, ${count(node)} paths`}\n title={needle === \"\" ? undefined : \"Opened by the filter\"}\n disabled={needle !== \"\"}\n style={{\n width: DISCLOSURE,\n padding: 0,\n border: 0,\n background: \"none\",\n cursor: \"pointer\",\n }}\n onClick={(): void => setOpen(!open)}\n >\n {expanded ? \"▾\" : \"▸\"}\n </button>\n );\n const controls: JSX.Element = (\n <span\n style={{\n whiteSpace: \"nowrap\",\n display: \"inline-flex\",\n alignItems: \"center\",\n }}\n >\n {toggle(\"select\", inspection.parts)}\n {toggle(\"hide\", inspection.hide)}\n {toggle(\"label\", inspection.label)}\n <input\n type=\"color\"\n aria-label={`colour ${label}`}\n disabled={pattern === null}\n value={`#${(color?.color ?? 0x808080).toString(16).padStart(6, \"0\")}`}\n style={{ width: COLUMN - 4, height: 16, padding: 0, border: 0 }}\n onChange={(event: ChangeEvent<HTMLInputElement>): void => {\n if (pattern !== null)\n dispatch({\n type: \"color\",\n pattern,\n color: Number.parseInt(event.target.value.slice(1), 16),\n });\n }}\n />\n {color === undefined || pattern === null ? null : (\n <button\n type=\"button\"\n aria-label={`clear the colour of ${label}`}\n onClick={(): void =>\n dispatch({ type: \"color\", pattern, color: null })\n }\n >\n x\n </button>\n )}\n {disclosure}\n <span style={{ fontWeight: node.drawn ? \"normal\" : \"bold\" }}>\n {label}\n </span>\n {leaf ? null : (\n <span aria-hidden=\"true\" style={{ color: \"#666\", fontSize: 11 }}>\n {\" \"}\n {count(node)}\n </span>\n )}\n </span>\n );\n if (leaf) return <li>{controls}</li>;\n return (\n <li>\n {controls}\n {expanded ? (\n <ul style={{ listStyle: \"none\", paddingLeft: 14, margin: 0 }}>\n {node.children.map(\n (child: IAutoMovieInspectorPathNode): JSX.Element | null =>\n shown(child, needle) ? (\n <Row\n key={child.path}\n node={child}\n needle={needle}\n inspection={inspection}\n dispatch={dispatch}\n />\n ) : null,\n )}\n </ul>\n ) : null}\n </li>\n );\n}\n"],"mappings":";;;;;AAkBA,MAAM,SAAiB;;AAGvB,MAAM,aAAqB;;;;;;;;;;;;;;;;AAiB3B,SAAgB,iCAAiC,OASjC;CACd,MAAM,OAAsC,cAExC,gCAAgC,MAAM,KAAK,GAC7C,CAAC,MAAM,KAAK,CACd;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ACE,MAAK;IACL,cAAY,UAAU;IACtB,UAAU,YAAY;IACtB,OAAO,KAAK,OAAO,SAAS,QAAA,CAAU,SAAS,EAAE,CAAC,CAAC,SAAS,GAAG,GAAG;IAClE,OAAO;KAAE,OAAO;KAAY,QAAQ;KAAI,SAAS;KAAG,QAAQ;IAAE;IAC9D,WAAW,UAA+C;KACxD,IAAI,YAAY,MACd,SAAS;MACP,MAAM;MACN;MACA,OAAO,OAAO,SAAS,MAAM,OAAO,MAAM,MAAM,CAAC,GAAG,EAAE;KACxD,CAAC;IACL;GACD,CAAA;GACA,UAAU,KAAA,KAAa,YAAY,OAAO,OACzC,oBAAC,UAAD;IACE,MAAK;IACL,cAAY,uBAAuB;IACnC,eACE,SAAS;KAAE,MAAM;KAAS;KAAS,OAAO;IAAK,CAAC;IAEnD,UAAA;GAEO,CAAA;GAET;GACD,oBAAC,QAAD;IAAM,OAAO,EAAE,YAAY,KAAK,QAAQ,WAAW,OAAO;IACvD,UAAA;GACG,CAAA;GACL,OAAO,OACN,qBAAC,QAAD;IAAM,eAAY;IAAO,OAAO;KAAE,OAAO;KAAQ,UAAU;IAAG;IAA9D,UAAA,CACG,KACA,MAAM,IAAI,CACP;;EAEJ;;CAER,IAAI,MAAM,OAAO,oBAAC,MAAD,EAAA,UAAK,SAAa,CAAA;CACnC,OACE,qBAAC,MAAD,EAAA,UAAA,CACG,UACA,WACC,oBAAC,MAAD;EAAI,OAAO;GAAE,WAAW;GAAQ,aAAa;GAAI,QAAQ;EAAE;EACxD,UAAA,KAAK,SAAS,KACZ,UACC,MAAM,OAAO,MAAM,IACjB,oBAAC,KAAD;GAEE,MAAM;GACE;GACI;GACF;EACX,GALM,MAAM,IAKZ,IACC,IACR;CACE,CAAA,IACF,IACF,EAAA,CAAA;AAER"}
1
+ {"version":3,"file":"AutoMovieInspectorSelectionPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorSelectionPanel.tsx"],"sourcesContent":["import type {\n IAutoMovieCapturePlanRequest,\n IAutoMovieInspectionColorAssignment,\n IAutoMovieInspectionRequest,\n} from \"@automovie/interface\";\n\nimport {\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type SetStateAction,\n useMemo,\n useState,\n} from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\nimport type { IAutoMovieInspectorPathNode } from \"./IAutoMovieInspectorPathNode.js\";\nimport { buildAutoMovieInspectorPathTree } from \"./buildAutoMovieInspectorPathTree.js\";\n\n\n/** The width of each of the three checkbox columns and the colour column, pixels. */\nconst COLUMN: number = 22;\n\n/** The width of the disclosure button before a name, pixels. */\nconst DISCLOSURE: number = 16;\n\n/**\n * Selection: the subject's identity paths as a tree, with select, hide, label and colour per path.\n *\n * A header names the four columns. Each node edits the request by its pattern, the one that selects the node and its subtree: a checkbox puts the pattern in or takes it out of `parts`, `hide` or `label`, and the colour input gives it a `color` pair, which the clear button takes back. A node is checked when its own pattern is in the list, so a pattern typed in the address that matches several nodes checks none of them, and stays in the request. The empty path has no pattern and only a name.\n *\n * A node with children is folded until opened, with the number of paths under it, so a figure's dozens of bones do not fill the panel. Its disclosure button, between the controls and the name, opens and folds it and states whether it is open; it sits beside the controls, never around them, so no control is nested in another. The filter keeps the nodes whose path contains the typed text, with their ancestors, and opens them; while it does, their disclosure buttons are disabled.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States the header, what each control edits, when a node is checked, what happens to typed patterns and the empty path, and how folding and the filter work.\n * @evidence contracts/development/implementation.md#principled-implementation The tree and each node's pattern come from `buildAutoMovieInspectorPathTree`, and every edit is a reducer action through the grammar, so the panel restates no path rule; folding is the disclosure pattern, a button with `aria-expanded` that owns no other control.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One memoized tree, one filter, and one recursive row per node.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts A checked state is read from the request, never kept in the panel; the filter hides rows and changes no request.\n * @evidence contracts/development/implementation.md#efficient-algorithms The tree is rebuilt only when the path list changes; a render is linear in the nodes times the lists' lengths, and a folded subtree is not rendered.\n * @evidence contracts/development/implementation.md#reuse-equivalent-work `useMemo` keeps the tree while the path list is the same array, which the mount reports once per instance.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds the memoized tree and the filter text only while mounted.\n */\nexport function AutoMovieInspectorSelectionPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** The subject's identity paths in scene order. */\n paths: readonly string[];\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const tree: IAutoMovieInspectorPathNode[] = useMemo(\n (): IAutoMovieInspectorPathNode[] =>\n buildAutoMovieInspectorPathTree(props.paths),\n [props.paths],\n );\n const [filter, setFilter]: [string, Dispatch<SetStateAction<string>>] =\n useState<string>(\"\");\n const needle: string = filter.trim().toLowerCase();\n return (\n <div>\n <input\n type=\"search\"\n aria-label=\"Filter paths\"\n placeholder=\"Filter paths\"\n value={filter}\n style={{ width: \"100%\", boxSizing: \"border-box\", marginBottom: 6 }}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setFilter(event.target.value)\n }\n />\n <div\n aria-hidden=\"true\"\n style={{\n display: \"flex\",\n fontSize: 11,\n color: \"#555\",\n borderBottom: \"1px solid #ccc\",\n marginBottom: 2,\n }}\n >\n {[\"Select\", \"Hide\", \"Label\", \"Colour\"].map(\n (name: string): JSX.Element => (\n <span\n key={name}\n title={name}\n style={{\n width: COLUMN,\n overflow: \"hidden\",\n textAlign: \"center\",\n writingMode: \"vertical-rl\",\n transform: \"rotate(180deg)\",\n height: 40,\n }}\n >\n {name}\n </span>\n ),\n )}\n <span style={{ alignSelf: \"flex-end\", paddingLeft: 6 }}>Path</span>\n </div>\n <ul style={{ listStyle: \"none\", paddingLeft: 0, margin: 0 }}>\n {tree.map((node: IAutoMovieInspectorPathNode): JSX.Element | null =>\n shown(node, needle) ? (\n <Row\n key={node.path}\n node={node}\n needle={needle}\n inspection={props.request.inspection}\n dispatch={props.dispatch}\n />\n ) : null,\n )}\n </ul>\n </div>\n );\n}\n\n/** Whether a node or any node under it matches the filter. */\nfunction shown(node: IAutoMovieInspectorPathNode, needle: string): boolean {\n return (\n needle === \"\" ||\n node.path.toLowerCase().includes(needle) ||\n node.children.some((child: IAutoMovieInspectorPathNode): boolean =>\n shown(child, needle),\n )\n );\n}\n\n/** The number of paths under a node. */\nfunction count(node: IAutoMovieInspectorPathNode): number {\n return node.children.reduce(\n (sum: number, child: IAutoMovieInspectorPathNode): number =>\n sum + 1 + count(child),\n 0,\n );\n}\n\n/** One node with its controls and, folded until opened, its children. */\nfunction Row(props: {\n node: IAutoMovieInspectorPathNode;\n needle: string;\n inspection: IAutoMovieInspectionRequest;\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const { node, needle, inspection, dispatch }: typeof props = props;\n const [open, setOpen]: [boolean, Dispatch<SetStateAction<boolean>>] =\n useState<boolean>(false);\n const pattern: string | null = node.pattern;\n const color: IAutoMovieInspectionColorAssignment | undefined =\n pattern === null\n ? undefined\n : inspection.color.find(\n (entry: IAutoMovieInspectionColorAssignment): boolean =>\n entry.pattern === pattern,\n );\n const label: string = node.name === \"\" ? \"(unnamed)\" : node.name;\n\n // A filter opens every node it keeps, so the matches are seen.\n const expanded: boolean = open || needle !== \"\";\n const toggle: (\n type: IAutoMovieInspectorAction.IToggle[\"type\"],\n list: readonly string[],\n ) => JSX.Element = (\n type: IAutoMovieInspectorAction.IToggle[\"type\"],\n list: readonly string[],\n ): JSX.Element => (\n <input\n type=\"checkbox\"\n aria-label={`${type} ${label}`}\n disabled={pattern === null}\n checked={pattern !== null && list.includes(pattern)}\n style={{ width: COLUMN - 8, margin: \"0 4px\" }}\n onChange={(event: ChangeEvent<HTMLInputElement>): void => {\n if (pattern !== null)\n dispatch({ type, pattern, on: event.target.checked });\n }}\n />\n );\n // A node with children has a disclosure button between its controls and\n // its name, beside them rather than around them, so no control sits inside\n // another; a leaf keeps the button's width, so the names stay aligned.\n const leaf: boolean = node.children.length === 0;\n const disclosure: JSX.Element = leaf ? (\n <span style={{ display: \"inline-block\", width: DISCLOSURE }} />\n ) : (\n <button\n type=\"button\"\n aria-expanded={expanded}\n aria-label={`${label}, ${count(node)} paths`}\n title={needle === \"\" ? undefined : \"Opened by the filter\"}\n disabled={needle !== \"\"}\n style={{\n width: DISCLOSURE,\n padding: 0,\n border: 0,\n background: \"none\",\n cursor: \"pointer\",\n }}\n onClick={(): void => setOpen(!open)}\n >\n {expanded ? \"▾\" : \"▸\"}\n </button>\n );\n const controls: JSX.Element = (\n <span\n style={{\n whiteSpace: \"nowrap\",\n display: \"inline-flex\",\n alignItems: \"center\",\n }}\n >\n {toggle(\"select\", inspection.parts)}\n {toggle(\"hide\", inspection.hide)}\n {toggle(\"label\", inspection.label)}\n <input\n type=\"color\"\n aria-label={`colour ${label}`}\n disabled={pattern === null}\n value={`#${(color?.color ?? 0x808080).toString(16).padStart(6, \"0\")}`}\n style={{ width: COLUMN - 4, height: 16, padding: 0, border: 0 }}\n onChange={(event: ChangeEvent<HTMLInputElement>): void => {\n if (pattern !== null)\n dispatch({\n type: \"color\",\n pattern,\n color: Number.parseInt(event.target.value.slice(1), 16),\n });\n }}\n />\n {color === undefined || pattern === null ? null : (\n <button\n type=\"button\"\n aria-label={`clear the colour of ${label}`}\n onClick={(): void =>\n dispatch({ type: \"color\", pattern, color: null })\n }\n >\n x\n </button>\n )}\n {disclosure}\n <span style={{ fontWeight: node.drawn ? \"normal\" : \"bold\" }}>\n {label}\n </span>\n {leaf ? null : (\n <span aria-hidden=\"true\" style={{ color: \"#666\", fontSize: 11 }}>\n {\" \"}\n {count(node)}\n </span>\n )}\n </span>\n );\n if (leaf) return <li>{controls}</li>;\n return (\n <li>\n {controls}\n {expanded ? (\n <ul style={{ listStyle: \"none\", paddingLeft: 14, margin: 0 }}>\n {node.children.map(\n (child: IAutoMovieInspectorPathNode): JSX.Element | null =>\n shown(child, needle) ? (\n <Row\n key={child.path}\n node={child}\n needle={needle}\n inspection={inspection}\n dispatch={dispatch}\n />\n ) : null,\n )}\n </ul>\n ) : null}\n </li>\n );\n}\n"],"mappings":";;;;;AAqBA,MAAM,SAAiB;;AAGvB,MAAM,aAAqB;;;;;;;;;;;;;;;;AAiB3B,SAAgB,iCAAiC,OASjC;CACd,MAAM,OAAsC,cAExC,gCAAgC,MAAM,KAAK,GAC7C,CAAC,MAAM,KAAK,CACd;CACA,MAAM,CAAC,QAAQ,aACb,SAAiB,EAAE;CACrB,MAAM,SAAiB,OAAO,KAAK,CAAC,CAAC,YAAY;CACjD,OACE,qBAAC,OAAD,EAAA,UAAA;EACE,oBAAC,SAAD;GACE,MAAK;GACL,cAAW;GACX,aAAY;GACZ,OAAO;GACP,OAAO;IAAE,OAAO;IAAQ,WAAW;IAAc,cAAc;GAAE;GACjE,WAAW,UACT,UAAU,MAAM,OAAO,KAAK;EAE/B,CAAA;EACD,qBAAC,OAAD;GACE,eAAY;GACZ,OAAO;IACL,SAAS;IACT,UAAU;IACV,OAAO;IACP,cAAc;IACd,cAAc;GAChB;GARF,UAAA,CAUG;IAAC;IAAU;IAAQ;IAAS;GAAQ,CAAC,CAAC,KACpC,SACC,oBAAC,QAAD;IAEE,OAAO;IACP,OAAO;KACL,OAAO;KACP,UAAU;KACV,WAAW;KACX,aAAa;KACb,WAAW;KACX,QAAQ;IACV;IAEC,UAAA;GACG,GAZC,IAYD,CAEV,GACA,oBAAC,QAAD;IAAM,OAAO;KAAE,WAAW;KAAY,aAAa;IAAE;IAAG,UAAA;GAAU,CAAA,CAC/D;;EACL,oBAAC,MAAD;GAAI,OAAO;IAAE,WAAW;IAAQ,aAAa;IAAG,QAAQ;GAAE;GACvD,UAAA,KAAK,KAAK,SACT,MAAM,MAAM,MAAM,IAChB,oBAAC,KAAD;IAEQ;IACE;IACR,YAAY,MAAM,QAAQ;IAC1B,UAAU,MAAM;GACjB,GALM,KAAK,IAKX,IACC,IACN;EACE,CAAA;CACD,EAAA,C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ACZ,UACC,MAAM,OAAO,MAAM,IACjB,oBAAC,KAAD;GAEE,MAAM;GACE;GACI;GACF;EACX,GALM,MAAM,IAKZ,IACC,IACR;CACE,CAAA,IACF,IACF,EAAA,CAAA;AAER"}
@@ -1,4 +1,4 @@
1
- import type { IAutoMovieCapturePlanRequest } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  import type { JSX } from "react";
3
3
  import type { IAutoMovieInspectorAction } from "./IAutoMovieInspectorAction.js";
4
4
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorShadePanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorShadePanel.tsx"],"names":[],"mappings":";;;;AAQA,yEAAyE;AACzE,MAAM,MAAM,GAAoD;IAC9D,MAAM,EAAE,IAAI;IACZ,KAAK,EAAE,IAAI;IACX,IAAI,EAAE,IAAI;IACV,MAAM,EAAE,IAAI;IACZ,OAAO,EAAE,IAAI;IACb,IAAI,EAAE,IAAI;IACV,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,IAAI;CACZ,CAAC;AAEF;;;;;;;;;;;;GAYG;AACH,sCAA6C,KAM5C;IACC,OAAO,CACL,sCAAU,KAAK,EAAE,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,aAChE,mCACE,KAAK,EAAE;oBACL,QAAQ,EAAE,UAAU;oBACpB,KAAK,EAAE,CAAC;oBACR,MAAM,EAAE,CAAC;oBACT,QAAQ,EAAE,QAAQ;oBAClB,QAAQ,EAAE,YAAY;oBACtB,UAAU,EAAE,QAAQ;iBACrB,sBAGM,EACT,iDACa,OAAO,EAClB,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAC9B,QAAQ,EAAE,CAAC,KAAqC,EAAQ,EAAE;oBACxD,MAAM,KAAK,GAAW,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;oBACzC,IAAI,OAAO,CAAC,KAAK,CAAC;wBAAE,KAAK,CAAC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC,CAAC;gBAC/D,CAAC,YAEA,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,GAAG,CACtB,CAAC,KAAa,EAAe,EAAE,CAAC,CAC9B,mCAAoB,KAAK,EAAE,KAAK,YAC7B,KAAK,IADK,KAAK,CAET,CACV,CACF,GACM,EAAC,GAAG,EACb,8CACE,kCACE,IAAI,EAAC,UAAU,EACf,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,EACzC,QAAQ,EAAE,CAAC,KAAoC,EAAQ,EAAE,CACvD,KAAK,CAAC,QAAQ,CAAC;4BACb,IAAI,EAAE,QAAQ;4BACd,GAAG,EAAE,SAAS;4BACd,EAAE,EAAE,KAAK,CAAC,MAAM,CAAC,OAAO;yBACzB,CAAC,GAEJ,EAAC,GAAG,eAEA,IACC,CACZ,CAAC;AACJ,CAAC;AAED,mDAAmD;AACnD,SAAS,OAAO,CAAC,IAAY;IAC3B,OAAO,MAAM,CAAC,MAAM,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;AACrC,CAAC"}
1
+ {"version":3,"file":"AutoMovieInspectorShadePanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorShadePanel.tsx"],"names":[],"mappings":";;;;AAUA,yEAAyE;AACzE,MAAM,MAAM,GAA2C;IACrD,MAAM,EAAE,IAAI;IACZ,KAAK,EAAE,IAAI;IACX,IAAI,EAAE,IAAI;IACV,MAAM,EAAE,IAAI;IACZ,OAAO,EAAE,IAAI;IACb,IAAI,EAAE,IAAI;IACV,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,IAAI;CACZ,CAAC;AAEF;;;;;;;;;;;;GAYG;AACH,sCAA6C,KAM5C;IACC,OAAO,CACL,sCAAU,KAAK,EAAE,EAAE,M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CAAC,CAAC;AACrC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorShadePanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorShadePanel.tsx"],"sourcesContent":["import type {\n IAutoMovieCapturePlanRequest,\n IAutoMovieInspectionRequest,\n} from \"@automovie/render\";\nimport type { ChangeEvent, JSX } from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\n\n/** Every shade, keyed so the compiler refuses a list that misses one. */\nconst SHADES: Record<IAutoMovieInspectionRequest.Shade, true> = {\n beauty: true,\n depth: true,\n mask: true,\n normal: true,\n outline: true,\n pose: true,\n clay: true,\n faces: true,\n};\n\n/**\n * Shade and surface: how surfaces are coloured and whether they are drawn.\n *\n * The page draws the request's first pass, so the shade shown is `passes[0]`; choosing one replaces every pass with it.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what the panel edits and how several passes become one.\n * @evidence contracts/development/implementation.md#principled-implementation The shade list is a record keyed by the request's shade union, so a shade render adds fails compilation here until it is offered.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One select and one checkbox, each dispatching one edit.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts The panel shows the request's values and keeps no copy of them.\n * @evidence contracts/development/implementation.md#efficient-algorithms Constant per render.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds nothing.\n */\nexport function AutoMovieInspectorShadePanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n return (\n <fieldset style={{ border: 0, padding: 0, margin: 0, minWidth: 0 }}>\n <legend\n style={{\n position: \"absolute\",\n width: 1,\n height: 1,\n overflow: \"hidden\",\n clipPath: \"inset(50%)\",\n whiteSpace: \"nowrap\",\n }}\n >\n Shade\n </legend>\n <select\n aria-label=\"Shade\"\n value={props.request.passes[0]}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void => {\n const shade: string = event.target.value;\n if (isShade(shade)) props.dispatch({ type: \"shade\", shade });\n }}\n >\n {Object.keys(SHADES).map(\n (shade: string): JSX.Element => (\n <option key={shade} value={shade}>\n {shade}\n </option>\n ),\n )}\n </select>{\" \"}\n <label>\n <input\n type=\"checkbox\"\n checked={props.request.inspection.surface}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n props.dispatch({\n type: \"switch\",\n key: \"surface\",\n on: event.target.checked,\n })\n }\n />{\" \"}\n surface\n </label>\n </fieldset>\n );\n}\n\n/** Whether a text is one of the shades offered. */\nfunction isShade(text: string): text is IAutoMovieInspectionRequest.Shade {\n return Object.hasOwn(SHADES, text);\n}\n"],"mappings":";;;AASA,MAAM,SAA0D;CAC9D,QAAQ;CACR,OAAO;CACP,MAAM;CACN,QAAQ;CACR,SAAS;CACT,MAAM;CACN,MAAM;CACN,OAAO;AACT;;;;;;;;;;;;;;AAeA,SAAgB,6BAA6B,OAM7B;CACd,OACE,qBAAC,YAAD;EAAU,OAAO;GAAE,QAAQ;GAAG,SAAS;GAAG,QAAQ;GAAG,UAAU;EAAE;EAAjE,UAAA;GACE,oBAAC,UAAD;IACE,OAAO;KACL,UAAU;KACV,OAAO;KACP,QAAQ;KACR,UAAU;KACV,UAAU;KACV,YAAY;IACd;IACD,UAAA;GAEO,CAAA;GACR,oBAAC,UAAD;IACE,cAAW;IACX,OAAO,MAAM,QAAQ,OAAO;IAC5B,WAAW,UAAgD;KACzD,MAAM,QAAgB,MAAM,OAAO;KACnC,IAAI,QAAQ,KAAK,GAAG,MAAM,SAAS;MAAE,MAAM;MAAS;KAAM,CAAC;IAC7D;IAEC,UAAA,OAAO,KAAK,MAAM,CAAC,CAAC,KAClB,UACC,oBAAC,UAAD;KAAoB,OAAO;KACxB,UAAA;IACK,GAFK,KAEL,CAEZ;GACM,CAAA;GAAE;GACV,qBAAC,SAAD,EAAA,UAAA;IACE,oBAAC,SAAD;KACE,MAAK;KACL,SAAS,MAAM,QAAQ,WAAW;KAClC,WAAW,UACT,MAAM,SAAS;MACb,MAAM;MACN,KAAK;MACL,IAAI,MAAM,OAAO;KACnB,CAAC;IAEJ,CAAA;IAAE;IAAI;GAEF,EAAA,CAAA;EACC;;AAEd;;AAGA,SAAS,QAAQ,MAAyD;CACxE,OAAO,OAAO,OAAO,QAAQ,IAAI;AACnC"}
1
+ {"version":3,"file":"AutoMovieInspectorShadePanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorShadePanel.tsx"],"sourcesContent":["import type {\n AutoMovieInspectionShade,\n IAutoMovieCapturePlanRequest,\n} from \"@automovie/interface\";\n\nimport type { ChangeEvent, JSX } from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\n\n\n/** Every shade, keyed so the compiler refuses a list that misses one. */\nconst SHADES: Record<AutoMovieInspectionShade, true> = {\n beauty: true,\n depth: true,\n mask: true,\n normal: true,\n outline: true,\n pose: true,\n clay: true,\n faces: true,\n};\n\n/**\n * Shade and surface: how surfaces are coloured and whether they are drawn.\n *\n * The page draws the request's first pass, so the shade shown is `passes[0]`; choosing one replaces every pass with it.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what the panel edits and how several passes become one.\n * @evidence contracts/development/implementation.md#principled-implementation The shade list is a record keyed by the request's shade union, so a shade render adds fails compilation here until it is offered.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One select and one checkbox, each dispatching one edit.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts The panel shows the request's values and keeps no copy of them.\n * @evidence contracts/development/implementation.md#efficient-algorithms Constant per render.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds nothing.\n */\nexport function AutoMovieInspectorShadePanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n return (\n <fieldset style={{ border: 0, padding: 0, margin: 0, minWidth: 0 }}>\n <legend\n style={{\n position: \"absolute\",\n width: 1,\n height: 1,\n overflow: \"hidden\",\n clipPath: \"inset(50%)\",\n whiteSpace: \"nowrap\",\n }}\n >\n Shade\n </legend>\n <select\n aria-label=\"Shade\"\n value={props.request.passes[0]}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void => {\n const shade: string = event.target.value;\n if (isShade(shade)) props.dispatch({ type: \"shade\", shade });\n }}\n >\n {Object.keys(SHADES).map(\n (shade: string): JSX.Element => (\n <option key={shade} value={shade}>\n {shade}\n </option>\n ),\n )}\n </select>{\" \"}\n <label>\n <input\n type=\"checkbox\"\n checked={props.request.inspection.surface}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n props.dispatch({\n type: \"switch\",\n key: \"surface\",\n on: event.target.checked,\n })\n }\n />{\" \"}\n surface\n </label>\n </fieldset>\n );\n}\n\n/** Whether a text is one of the shades offered. */\nfunction isShade(text: string): text is AutoMovieInspectionShade {\n return Object.hasOwn(SHADES, text);\n}\n"],"mappings":";;;AAWA,MAAM,SAAiD;CACrD,QAAQ;CACR,OAAO;CACP,MAAM;CACN,QAAQ;CACR,SAAS;CACT,MAAM;CACN,MAAM;CACN,OAAO;AACT;;;;;;;;;;;;;;AAeA,SAAgB,6BAA6B,OAM7B;CACd,OACE,qBAAC,YAAD;EAAU,OAAO;GAAE,QAAQ;GAAG,SAAS;GAAG,QAAQ;GAAG,UAAU;EAAE;EAAjE,UAAA;GACE,oBAAC,UAAD;IACE,OAAO;KACL,UAAU;KACV,OAAO;KACP,QAAQ;KACR,UAAU;KACV,UAAU;KACV,YAAY;IACd;IACD,UAAA;GAEO,CAAA;GACR,oBAAC,UAAD;IACE,cAAW;IACX,OAAO,MAAM,QAAQ,OAAO;IAC5B,WAAW,UAAgD;KACzD,MAAM,QAAgB,MAAM,OAAO;KACnC,IAAI,QAAQ,KAAK,GAAG,MAAM,SAAS;MAAE,MAAM;MAAS;KAAM,CAAC;IAC7D;IAEC,UAAA,OAAO,KAAK,MAAM,CAAC,CAAC,KAClB,UACC,oBAAC,UAAD;KAAoB,OAAO;KACxB,UAAA;IACK,GAFK,KAEL,CAEZ;GACM,CAAA;GAAE;GACV,qBAAC,SAAD,EAAA,UAAA;IACE,oBAAC,SAAD;KACE,MAAK;KACL,SAAS,MAAM,QAAQ,WAAW;KAClC,WAAW,UACT,MAAM,SAAS;MACb,MAAM;MACN,KAAK;MACL,IAAI,MAAM,OAAO;KACnB,CAAC;IAEJ,CAAA;IAAE;IAAI;GAEF,EAAA,CAAA;EACC;;AAEd;;AAGA,SAAS,QAAQ,MAAgD;CAC/D,OAAO,OAAO,OAAO,QAAQ,IAAI;AACnC"}
@@ -1,4 +1,4 @@
1
- import { type IAutoMovieCapturePlanRequest } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  import { type JSX } from "react";
3
3
  import type { IAutoMovieInspectorAction } from "./IAutoMovieInspectorAction.js";
4
4
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorViewPanel.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspectorViewPanel.tsx"],"names":[],"mappings":";;;;AAAA,8CAK2B;AAC3B,iCAA6D;AAI7D,yHAAyH;AACzH,MAAM,KAAK,GAAW,eAAe,CAAC;AAEtC;;;;;;;;;;;;GAYG;AACH,qCAA4C,KAS3C;IACC,MAAM,IAAI,GAAW,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAE,CAAC;IAC7C,MAAM,IAAI,GAA6B,IAAA,qCAA4B,EAAC,IAAI,CAAC,CAAC;IAC1E,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,IAAA,gBAAQ,EAAgB,IAAI,CAAC,CAAC;IACxD,MAAM,IAAI,GAA6C,CACrD,IAA8B,EACxB,EAAE,CACR,KAAK,CAAC,Q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AAS,EAAE,CAAC,KAAsB,EAAQ,EAAE;oCAC1C,IAAI,KAAK,CAAC,GAAG,KAAK,OAAO;wCAAE,MAAM,EAAE,CAAC;gCACtC,CAAC,GACD,IACI,IACP,CACJ,CAAC,CAAC,CAAC,IAAI,IACC,CACZ,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"AutoMovieInspectorViewPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorViewPanel.tsx"],"sourcesContent":["import {\n type IAutoMovieCapturePlanRequest,\n type IAutoMovieInspectionView,\n formatAutoMovieInspectionView,\n parseAutoMovieInspectionView,\n} from \"@automovie/render\";\nimport { type ChangeEvent, type JSX, useState } from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\n\n/** The fixed camera a person starts from when choosing one: 4 m in front at eye height, looking at the origin at 1 m. */\nconst FIXED: string = \"0,1.6,4:0,1,0\";\n\n/**\n * View: the subject's camera (`film`), a named view (the subject's own or a fitted viewpoint) with orthographic projection, following each second and a focus, or a fixed camera by coordinates, typed with any scale and up its text carries.\n *\n * The panel shows the request's first view, the one the page draws, and writes every change back as one view text through render's `formatAutoMovieInspectionView`, which the reducer replaces the request's views with. A fixed camera and a focus pattern are typed and dispatched when the field is left or Enter is pressed.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States the forms offered, which view is shown, how a change is written and when typed fields are dispatched.\n * @evidence contracts/development/implementation.md#principled-implementation The shown view is parsed by render's view grammar and the dispatched text written by its inverse, so every switch is one the grammar reads.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One select for the form, then the controls that form takes.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts A view the grammar refuses is refused by the reducer with the key named; the panel validates nothing itself.\n * @evidence contracts/development/implementation.md#efficient-algorithms Constant per render beyond the view names listed.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds only the text being typed.\n */\nexport function AutoMovieInspectorViewPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** View names the subject offers: its own, then the fitted viewpoints. */\n views: readonly string[];\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const text: string = props.request.views[0]!;\n const view: IAutoMovieInspectionView = parseAutoMovieInspectionView(text);\n const [typed, setTyped] = useState<string | null>(null);\n const send: (next: IAutoMovieInspectionView) => void = (\n next: IAutoMovieInspectionView,\n ): void =>\n props.dispatch({ type: \"view\", view: formatAutoMovieInspectionView(next) });\n const form: string = view.type === \"named\" ? view.name : view.type;\n const focus: string =\n view.type === \"named\" && view.focus?.type === \"pattern\"\n ? view.focus.pattern\n : \"\";\n const commit: () => void = (): void => {\n if (typed === null) return;\n setTyped(null);\n if (view.type === \"fixed\") props.dispatch({ type: \"view\", view: typed });\n else if (view.type === \"named\")\n send({\n ...view,\n focus: typed === \"\" ? null : { type: \"pattern\", pattern: typed },\n });\n };\n return (\n <fieldset style={{ border: 0, padding: 0, margin: 0, minWidth: 0 }}>\n <legend\n style={{\n position: \"absolute\",\n width: 1,\n height: 1,\n overflow: \"hidden\",\n clipPath: \"inset(50%)\",\n whiteSpace: \"nowrap\",\n }}\n >\n View\n </legend>\n <select\n aria-label=\"View\"\n value={form}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void => {\n const chosen: string = event.target.value;\n setTyped(null);\n if (chosen === \"film\") send({ type: \"film\" });\n else if (chosen === \"fixed\")\n props.dispatch({ type: \"view\", view: FIXED });\n else\n send({\n type: \"named\",\n name: chosen,\n orthographic: false,\n follow: false,\n focus: null,\n });\n }}\n >\n <option value=\"film\">film</option>\n {[\n ...new Set<string>([\n ...props.views,\n ...(view.type === \"named\" ? [view.name] : []),\n ]),\n ].map(\n (name: string): JSX.Element => (\n <option key={name} value={name}>\n {name}\n </option>\n ),\n )}\n <option value=\"fixed\">fixed</option>\n </select>\n {view.type === \"fixed\" ? (\n <input\n aria-label=\"Fixed camera x,y,z:tx,ty,tz\"\n value={typed ?? text}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setTyped(event.target.value)\n }\n onBlur={commit}\n onKeyDown={(event: { key: string }): void => {\n if (event.key === \"Enter\") commit();\n }}\n />\n ) : null}\n {view.type === \"named\" ? (\n <>\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={view.orthographic}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n send({ ...view, orthographic: event.target.checked })\n }\n />{\" \"}\n orthographic\n </label>\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={view.follow}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n send({ ...view, follow: event.target.checked })\n }\n />{\" \"}\n follow each second\n </label>\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={view.focus?.type === \"flagged\"}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n send({\n ...view,\n focus: event.target.checked ? { type: \"flagged\" } : null,\n })\n }\n />{\" \"}\n focus on flagged marks\n </label>\n <label style={{ display: \"block\" }}>\n focus{\" \"}\n <input\n aria-label=\"Focus pattern\"\n placeholder=\"path pattern\"\n value={typed ?? focus}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setTyped(event.target.value)\n }\n onBlur={commit}\n onKeyDown={(event: { key: string }): void => {\n if (event.key === \"Enter\") commit();\n }}\n />\n </label>\n </>\n ) : null}\n </fieldset>\n );\n}\n"],"mappings":";;;;;AAWA,MAAM,QAAgB;;;;;;;;;;;;;;AAetB,SAAgB,4BAA4B,OAS5B;CACd,MAAM,OAAe,MAAM,QAAQ,MAAM;CACzC,MAAM,OAAiC,6BAA6B,IAAI;CACxE,MAAM,CAAC,OAAO,YAAY,SAAwB,IAAI;CACtD,MAAM,QACJ,SAEA,MAAM,SAAS;EAAE,MAAM;EAAQ,MAAM,8BAA8B,IAAI;CAAE,CAAC;CAC5E,MAAM,OAAe,K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AA,CAAA,IACA;EACI;;AAEd"}
1
+ {"version":3,"file":"AutoMovieInspectorViewPanel.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspectorViewPanel.tsx"],"sourcesContent":["import type { IAutoMovieCapturePlanRequest, IAutoMovieInspectionView } from \"@automovie/interface\";\nimport { formatAutoMovieInspectionView, parseAutoMovieInspectionView } from \"@automovie/render\";\nimport { type ChangeEvent, type JSX, useState } from \"react\";\n\nimport type { IAutoMovieInspectorAction } from \"./IAutoMovieInspectorAction.js\";\n\n/** The fixed camera a person starts from when choosing one: 4 m in front at eye height, looking at the origin at 1 m. */\nconst FIXED: string = \"0,1.6,4:0,1,0\";\n\n/**\n * View: the subject's camera (`film`), a named view (the subject's own or a fitted viewpoint) with orthographic projection, following each second and a focus, or a fixed camera by coordinates, typed with any scale and up its text carries.\n *\n * The panel shows the request's first view, the one the page draws, and writes every change back as one view text through render's `formatAutoMovieInspectionView`, which the reducer replaces the request's views with. A fixed camera and a focus pattern are typed and dispatched when the field is left or Enter is pressed.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States the forms offered, which view is shown, how a change is written and when typed fields are dispatched.\n * @evidence contracts/development/implementation.md#principled-implementation The shown view is parsed by render's view grammar and the dispatched text written by its inverse, so every switch is one the grammar reads.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One select for the form, then the controls that form takes.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts A view the grammar refuses is refused by the reducer with the key named; the panel validates nothing itself.\n * @evidence contracts/development/implementation.md#efficient-algorithms Constant per render beyond the view names listed.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A view with handlers.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Holds only the text being typed.\n */\nexport function AutoMovieInspectorViewPanel(props: {\n /** The request shown. */\n request: IAutoMovieCapturePlanRequest;\n\n /** View names the subject offers: its own, then the fitted viewpoints. */\n views: readonly string[];\n\n /** Where edits go. */\n dispatch: (action: IAutoMovieInspectorAction) => void;\n}): JSX.Element {\n const text: string = props.request.views[0]!;\n const view: IAutoMovieInspectionView = parseAutoMovieInspectionView(text);\n const [typed, setTyped] = useState<string | null>(null);\n const send: (next: IAutoMovieInspectionView) => void = (\n next: IAutoMovieInspectionView,\n ): void =>\n props.dispatch({ type: \"view\", view: formatAutoMovieInspectionView(next) });\n const form: string = view.type === \"named\" ? view.name : view.type;\n const focus: string =\n view.type === \"named\" && view.focus?.type === \"pattern\"\n ? view.focus.pattern\n : \"\";\n const commit: () => void = (): void => {\n if (typed === null) return;\n setTyped(null);\n if (view.type === \"fixed\") props.dispatch({ type: \"view\", view: typed });\n else if (view.type === \"named\")\n send({\n ...view,\n focus: typed === \"\" ? null : { type: \"pattern\", pattern: typed },\n });\n };\n return (\n <fieldset style={{ border: 0, padding: 0, margin: 0, minWidth: 0 }}>\n <legend\n style={{\n position: \"absolute\",\n width: 1,\n height: 1,\n overflow: \"hidden\",\n clipPath: \"inset(50%)\",\n whiteSpace: \"nowrap\",\n }}\n >\n View\n </legend>\n <select\n aria-label=\"View\"\n value={form}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void => {\n const chosen: string = event.target.value;\n setTyped(null);\n if (chosen === \"film\") send({ type: \"film\" });\n else if (chosen === \"fixed\")\n props.dispatch({ type: \"view\", view: FIXED });\n else\n send({\n type: \"named\",\n name: chosen,\n orthographic: false,\n follow: false,\n focus: null,\n });\n }}\n >\n <option value=\"film\">film</option>\n {[\n ...new Set<string>([\n ...props.views,\n ...(view.type === \"named\" ? [view.name] : []),\n ]),\n ].map(\n (name: string): JSX.Element => (\n <option key={name} value={name}>\n {name}\n </option>\n ),\n )}\n <option value=\"fixed\">fixed</option>\n </select>\n {view.type === \"fixed\" ? (\n <input\n aria-label=\"Fixed camera x,y,z:tx,ty,tz\"\n value={typed ?? text}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setTyped(event.target.value)\n }\n onBlur={commit}\n onKeyDown={(event: { key: string }): void => {\n if (event.key === \"Enter\") commit();\n }}\n />\n ) : null}\n {view.type === \"named\" ? (\n <>\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={view.orthographic}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n send({ ...view, orthographic: event.target.checked })\n }\n />{\" \"}\n orthographic\n </label>\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={view.follow}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n send({ ...view, follow: event.target.checked })\n }\n />{\" \"}\n follow each second\n </label>\n <label style={{ display: \"block\" }}>\n <input\n type=\"checkbox\"\n checked={view.focus?.type === \"flagged\"}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n send({\n ...view,\n focus: event.target.checked ? { type: \"flagged\" } : null,\n })\n }\n />{\" \"}\n focus on flagged marks\n </label>\n <label style={{ display: \"block\" }}>\n focus{\" \"}\n <input\n aria-label=\"Focus pattern\"\n placeholder=\"path pattern\"\n value={typed ?? focus}\n onChange={(event: ChangeEvent<HTMLInputElement>): void =>\n setTyped(event.target.value)\n }\n onBlur={commit}\n onKeyDown={(event: { key: string }): void => {\n if (event.key === \"Enter\") commit();\n }}\n />\n </label>\n </>\n ) : null}\n </fieldset>\n );\n}\n"],"mappings":";;;;;AAOA,MAAM,QAAgB;;;;;;;;;;;;;;AAetB,SAAgB,4BAA4B,OAS5B;CACd,MAAM,OAAe,MAAM,QAAQ,MAAM;CACzC,MAAM,OAAiC,6BAA6B,IAAI;CACxE,MAAM,CAAC,OAAO,YAAY,SAAwB,IAAI;CACtD,MAAM,QACJ,SAEA,MAAM,SAAS;EAAE,MAAM;EAAQ,MAAM,8BAA8B,IAAI;CAAE,CAAC;CAC5E,MAAM,OAAe,KAAK,SAAS,UAAU,KAAK,OAAO,KAAK;CAC9D,MAAM,QACJ,KAAK,SAAS,WAAW,KAAK,OAAO,SAAS,YAC1C,KAAK,MAAM,UACX;CACN,MAAM,eAAiC;EACrC,IAAI,UAAU,MAAM;EACpB,SAAS,IAAI;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3C,IAAI,MAAM,QAAQ,SAAS,OAAO;IACpC;GACD,CAAA,IACC;GACH,KAAK,SAAS,UACb,qBAAA,UAAA,EAAA,UAAA;IACE,qBAAC,SAAD;KAAO,OAAO,EAAE,SAAS,QAAQ;KAAjC,UAAA;MACE,oBAAC,SAAD;OACE,MAAK;OACL,SAAS,KAAK;OACd,WAAW,UACT,KAAK;QAAE,GAAG;QAAM,cAAc,MAAM,OAAO;OAAQ,CAAC;MAEvD,CAAA;MAAE;MAAI;KAEF;;IACP,qBAAC,SAAD;KAAO,OAAO,EAAE,SAAS,QAAQ;KAAjC,UAAA;MACE,oBAAC,SAAD;OACE,MAAK;OACL,SAAS,KAAK;OACd,WAAW,UACT,KAAK;QAAE,GAAG;QAAM,QAAQ,MAAM,OAAO;OAAQ,CAAC;MAEjD,CAAA;MAAE;MAAI;KAEF;;IACP,qBAAC,SAAD;KAAO,OAAO,EAAE,SAAS,QAAQ;KAAjC,UAAA;MACE,oBAAC,SAAD;OACE,MAAK;OACL,SAAS,KAAK,OAAO,SAAS;OAC9B,WAAW,UACT,KAAK;QACH,GAAG;QACH,OAAO,MAAM,OAAO,UAAU,EAAE,MAAM,UAAU,IAAI;OACtD,CAAC;MAEJ,CAAA;MAAE;MAAI;KAEF;;IACP,qBAAC,SAAD;KAAO,OAAO,EAAE,SAAS,QAAQ;KAAjC,UAAA;MAAoC;MAC5B;MACN,oBAAC,SAAD;OACE,cAAW;OACX,aAAY;OACZ,OAAO,SAAS;OAChB,WAAW,UACT,SAAS,MAAM,OAAO,KAAK;OAE7B,QAAQ;OACR,YAAY,UAAiC;QAC3C,IAAI,MAAM,QAAQ,SAAS,OAAO;OACpC;MACD,CAAA;KACI;;GACP,EAAA,CAAA,IACA;EACI;;AAEd"}
@@ -1,4 +1,4 @@
1
- import type { IAutoMovieCapturePlanRequest, IAutoMovieInspectionRequest } from "@automovie/render";
1
+ import type { AutoMovieInspectionShade, IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  /**
3
3
  * One edit of the inspector's request, as a control dispatches it to `reduceAutoMovieInspectorState`.
4
4
  *
@@ -70,7 +70,7 @@ export declare namespace IAutoMovieInspectorAction {
70
70
  /** Discriminant. */
71
71
  type: "shade";
72
72
  /** The shade drawn. */
73
- shade: IAutoMovieInspectionRequest.Shade;
73
+ shade: AutoMovieInspectionShade;
74
74
  }
75
75
  /**
76
76
  * Turn one of the request's switches on or off.
@@ -1,4 +1,5 @@
1
- import type { IApplyAutoMovieInspectionProps, IAutoMovieCapturePlanRequest, IAutoMovieInspectionLegendEntry } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest, IAutoMovieInspectionLegendEntry } from "@automovie/interface";
2
+ import type { IApplyAutoMovieInspectionProps } from "@automovie/render";
2
3
  /**
3
4
  * A subject mounted on the inspector's canvas by `mountAutoMovieInspectorScene`: the calls the component makes while it lives.
4
5
  *
@@ -1,4 +1,4 @@
1
- import type { IAutoMovieCapturePlanRequest } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  /**
3
3
  * What the inspector holds between edits: the one request every control edits and the canvas draws, and the last refusal.
4
4
  *
@@ -1,4 +1,4 @@
1
- import { type IAutoMovieCapturePlanRequest } from "@automovie/render";
1
+ import type { IAutoMovieCapturePlanRequest } from "@automovie/interface";
2
2
  /**
3
3
  * Write a request as the query text of an address, without the leading `?`, so the address repeats the request and `readAutoMovieInspectorAddress` reads it back equal.
4
4
  *
@@ -1 +1 @@
1
- {"version":3,"file":"formatAutoMovieInspectorAddress.js","sourceRoot":"","sources":["../../src/inspector/formatAutoMovieInspectorAddress.ts"],"names":[],"mappings":";;;AAAA,8CAG2B;AAE3B,0HAA0H;AAC1H,MAAM,QAAQ,GAAgC,IAAI,GAAG,CAAiB;IACpE,CAAC,KAAK,EAAE,GAAG,CAAC;IACZ,CAAC,KAAK,EAAE,GAAG,CAAC;IACZ,CAAC,KAAK,EAAE,GAAG,CAAC;IACZ,CAAC,KAAK,EAAE,GAAG,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AAE,CAC1D,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,KAAK,CAAC,EAAE,CAC/D;SACA,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC;AAED,kEAAkE;AAClE,SAAS,MAAM,CAAC,IAAY;IAC1B,OAAO,kBAAkB,CAAC,IAAI,CAAC,CAAC,OAAO,CACrC,2BAA2B,EAC3B,CAAC,IAAY,EAAU,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAE,CAC9C,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"formatAutoMovieInspectorAddress.mjs","names":[],"sources":["../../src/inspector/formatAutoMovieInspectorAddress.ts"],"sourcesContent":["import {\n type IAutoMovieCapturePlanRequest,\n formatAutoMovieCapturePlanRequest,\n} from \"@automovie/render\";\n\n/** Characters the grammar writes that a query keeps readable: list, view, path, focus, colour pair and cut separators. */\nconst READABLE: ReadonlyMap<string, string> = new Map<string, string>([\n [\"%2C\", \",\"],\n [\"%3A\", \":\"],\n [\"%3B\", \";\"],\n [\"%2F\", \"/\"],\n [\"%40\", \"@\"],\n [\"%3D\", \"=\"],\n]);\n\n/**\n * Write a request as the query text of an address, without the leading `?`, so the address repeats the request and `readAutoMovieInspectorAddress` reads it back equal.\n *\n * Keys and values come from `formatAutoMovieCapturePlanRequest`, in its order and with absent values left out, so the request that asks for nothing is the empty text. Each key and value is escaped by `encodeURIComponent`, then the separators `,`, `:`, `;`, `/`, `@` and `=` are put back, because a query may hold them as they are and `URLSearchParams` reads them unchanged (a pair splits at its first `=`, and no key holds one), so `parts=hero/torso&views=front@focus=hero&color=hero=ff8800` stays readable. A key whose value is empty is written bare.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States the order, the escaping, which characters stay readable and why that is safe, the bare key and the round trip.\n * @evidence contracts/development/implementation.md#principled-implementation The grammar's own writer decides keys and values; `encodeURIComponent` escapes every character that would change the query's structure (`&`, `+`, `#`, `%`, space), and the restored separators are sub-delimiters RFC 3986 allows in a query, which the WHATWG URL parser leaves as they are; `=` inside a value is safe because `URLSearchParams` splits a pair at its first `=` and no grammar key holds one.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One map over the written pairs and one join.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No key or value is written here by hand, so a key the grammar adds reaches the address unchanged.\n * @evidence contracts/development/implementation.md#efficient-algorithms Linear in the length of the written request.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A pure conversion of one request.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Returns a fresh string and keeps nothing.\n */\nexport function formatAutoMovieInspectorAddress(\n request: IAutoMovieCapturePlanRequest,\n): string {\n return formatAutoMovieCapturePlanRequest(request)\n .map(([key, value]: [key: string, value: string]): string =>\n value === \"\" ? escape(key) : `${escape(key)}=${escape(value)}`,\n )\n .join(\"&\");\n}\n\n/** `encodeURIComponent` with the readable separators put back. */\nfunction escape(text: string): string {\n return encodeURIComponent(text).replace(\n /%2C|%3A|%3B|%2F|%40|%3D/gu,\n (code: string): string => READABLE.get(code)!,\n );\n}\n"],"mappings":";;;AAMA,MAAM,2BAAwC,IAAI,IAAoB;CACpE,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;AACb,CAAC;;;;;;;;;;;;;;AAeD,SAAgB,gCACd,SACQ;CACR,OAAO,kCAAkC,OAAO,CAAC,CAC9C,KAAK,CAAC,KAAK,WACV,UAAU,KAAK,OAAO,GAAG,IAAI,GAAG,OAAO,GAAG,EAAE,GAAG,OAAO,KAAK,GAC7D,CAAC,CACA,KAAK,GAAG;AACb;;AAGA,SAAS,OAAO,MAAsB;CACpC,OAAO,mBAAmB,IAAI,CAAC,CAAC,QAC9B,8BACC,SAAyB,SAAS,IAAI,IAAI,CAC7C;AACF"}
1
+ {"version":3,"file":"formatAutoMovieInspectorAddress.mjs","names":[],"sources":["../../src/inspector/formatAutoMovieInspectorAddress.ts"],"sourcesContent":["import type { IAutoMovieCapturePlanRequest } from \"@automovie/interface\";\nimport { formatAutoMovieCapturePlanRequest } from \"@automovie/render\";\n\n/** Characters the grammar writes that a query keeps readable: list, view, path, focus, colour pair and cut separators. */\nconst READABLE: ReadonlyMap<string, string> = new Map<string, string>([\n [\"%2C\", \",\"],\n [\"%3A\", \":\"],\n [\"%3B\", \";\"],\n [\"%2F\", \"/\"],\n [\"%40\", \"@\"],\n [\"%3D\", \"=\"],\n]);\n\n/**\n * Write a request as the query text of an address, without the leading `?`, so the address repeats the request and `readAutoMovieInspectorAddress` reads it back equal.\n *\n * Keys and values come from `formatAutoMovieCapturePlanRequest`, in its order and with absent values left out, so the request that asks for nothing is the empty text. Each key and value is escaped by `encodeURIComponent`, then the separators `,`, `:`, `;`, `/`, `@` and `=` are put back, because a query may hold them as they are and `URLSearchParams` reads them unchanged (a pair splits at its first `=`, and no key holds one), so `parts=hero/torso&views=front@focus=hero&color=hero=ff8800` stays readable. A key whose value is empty is written bare.\n *\n * @evidence contracts/development/common.md#meaningful-documentation States the order, the escaping, which characters stay readable and why that is safe, the bare key and the round trip.\n * @evidence contracts/development/implementation.md#principled-implementation The grammar's own writer decides keys and values; `encodeURIComponent` escapes every character that would change the query's structure (`&`, `+`, `#`, `%`, space), and the restored separators are sub-delimiters RFC 3986 allows in a query, which the WHATWG URL parser leaves as they are; `=` inside a value is safe because `URLSearchParams` splits a pair at its first `=` and no grammar key holds one.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One map over the written pairs and one join.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No key or value is written here by hand, so a key the grammar adds reaches the address unchanged.\n * @evidence contracts/development/implementation.md#efficient-algorithms Linear in the length of the written request.\n * @evidenceExclude contracts/development/implementation.md#reuse-equivalent-work A pure conversion of one request.\n * @evidenceExclude contracts/development/implementation.md#bound-retention-and-release-resources Returns a fresh string and keeps nothing.\n */\nexport function formatAutoMovieInspectorAddress(\n request: IAutoMovieCapturePlanRequest,\n): string {\n return formatAutoMovieCapturePlanRequest(request)\n .map(([key, value]: [key: string, value: string]): string =>\n value === \"\" ? escape(key) : `${escape(key)}=${escape(value)}`,\n )\n .join(\"&\");\n}\n\n/** `encodeURIComponent` with the readable separators put back. */\nfunction escape(text: string): string {\n return encodeURIComponent(text).replace(\n /%2C|%3A|%3B|%2F|%40|%3D/gu,\n (code: string): string => READABLE.get(code)!,\n );\n}\n"],"mappings":";;;AAIA,MAAM,2BAAwC,IAAI,IAAoB;CACpE,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;CACX,CAAC,OAAO,GAAG;AACb,CAAC;;;;;;;;;;;;;;AAeD,SAAgB,gCACd,SACQ;CACR,OAAO,kCAAkC,OAAO,CAAC,CAC9C,KAAK,CAAC,KAAK,WACV,UAAU,KAAK,OAAO,GAAG,IAAI,GAAG,OAAO,GAAG,EAAE,GAAG,OAAO,KAAK,GAC7D,CAAC,CACA,KAAK,GAAG;AACb;;AAGA,SAAS,OAAO,MAAsB;CACpC,OAAO,mBAAmB,IAAI,CAAC,CAAC,QAC9B,8BACC,SAAyB,SAAS,IAAI,IAAI,CAC7C;AACF"}