@nodaro/prompts 1.42.0 → 1.45.0

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 (105) hide show
  1. package/dist/{chunk-PHFOKGYS.js → chunk-2HJJBXGA.js} +6 -6
  2. package/dist/{chunk-PHFOKGYS.js.map → chunk-2HJJBXGA.js.map} +1 -1
  3. package/dist/{chunk-HL6PZ4A6.js → chunk-2OIKQ4WB.js} +5 -5
  4. package/dist/{chunk-HL6PZ4A6.js.map → chunk-2OIKQ4WB.js.map} +1 -1
  5. package/dist/{chunk-ZFOXGNLK.js → chunk-57PTYJJX.js} +4 -4
  6. package/dist/{chunk-ZFOXGNLK.js.map → chunk-57PTYJJX.js.map} +1 -1
  7. package/dist/{chunk-XTOSNRWT.cjs → chunk-5NIKPMLU.cjs} +2 -4
  8. package/dist/chunk-5NIKPMLU.cjs.map +1 -0
  9. package/dist/{chunk-ZGA72NCT.cjs → chunk-C4FDHCEZ.cjs} +125 -125
  10. package/dist/{chunk-ZGA72NCT.cjs.map → chunk-C4FDHCEZ.cjs.map} +1 -1
  11. package/dist/chunk-CLHIPYTC.js +10913 -0
  12. package/dist/chunk-CLHIPYTC.js.map +1 -0
  13. package/dist/{chunk-QJACEKMZ.js → chunk-CPKYIVWP.js} +3 -3
  14. package/dist/{chunk-QJACEKMZ.js.map → chunk-CPKYIVWP.js.map} +1 -1
  15. package/dist/{chunk-JDNHMVEV.cjs → chunk-FCTK7RGO.cjs} +35 -35
  16. package/dist/{chunk-JDNHMVEV.cjs.map → chunk-FCTK7RGO.cjs.map} +1 -1
  17. package/dist/{chunk-IFRFYBGE.js → chunk-IKHRZ5UQ.js} +3 -3
  18. package/dist/{chunk-IFRFYBGE.js.map → chunk-IKHRZ5UQ.js.map} +1 -1
  19. package/dist/{chunk-SB7AYE6S.cjs → chunk-JHEZJKTX.cjs} +250 -6
  20. package/dist/chunk-JHEZJKTX.cjs.map +1 -0
  21. package/dist/{chunk-GIO77YH5.js → chunk-NN4FL7SB.js} +4 -4
  22. package/dist/{chunk-GIO77YH5.js.map → chunk-NN4FL7SB.js.map} +1 -1
  23. package/dist/{chunk-I3QS7BSY.cjs → chunk-OSKABA64.cjs} +8 -8
  24. package/dist/{chunk-I3QS7BSY.cjs.map → chunk-OSKABA64.cjs.map} +1 -1
  25. package/dist/{chunk-AXQK7UH7.cjs → chunk-OY7XOPDG.cjs} +49 -49
  26. package/dist/{chunk-AXQK7UH7.cjs.map → chunk-OY7XOPDG.cjs.map} +1 -1
  27. package/dist/{chunk-ZLRB5BVT.cjs → chunk-PHR4UETI.cjs} +18 -18
  28. package/dist/{chunk-ZLRB5BVT.cjs.map → chunk-PHR4UETI.cjs.map} +1 -1
  29. package/dist/chunk-S3H4TI6N.cjs +10948 -0
  30. package/dist/chunk-S3H4TI6N.cjs.map +1 -0
  31. package/dist/{chunk-6JABZ5OC.js → chunk-SMKIVT7P.js} +4 -4
  32. package/dist/{chunk-6JABZ5OC.js.map → chunk-SMKIVT7P.js.map} +1 -1
  33. package/dist/{chunk-CYMIXKFT.js → chunk-TXHFL725.js} +247 -3
  34. package/dist/chunk-TXHFL725.js.map +1 -0
  35. package/dist/{chunk-WARNUGXT.cjs → chunk-UNR34GYU.cjs} +191 -2
  36. package/dist/chunk-UNR34GYU.cjs.map +1 -0
  37. package/dist/{chunk-4YUXR23B.cjs → chunk-VAK4RUNU.cjs} +13 -13
  38. package/dist/{chunk-4YUXR23B.cjs.map → chunk-VAK4RUNU.cjs.map} +1 -1
  39. package/dist/{chunk-QBUSJGV3.js → chunk-XMFWHTQB.js} +2 -4
  40. package/dist/chunk-XMFWHTQB.js.map +1 -0
  41. package/dist/{chunk-JCYK7NSR.js → chunk-XZXUU3YH.js} +191 -2
  42. package/dist/chunk-XZXUU3YH.js.map +1 -0
  43. package/dist/{chunk-H4JMZWOE.cjs → chunk-YCCQXX3U.cjs} +39 -39
  44. package/dist/{chunk-H4JMZWOE.cjs.map → chunk-YCCQXX3U.cjs.map} +1 -1
  45. package/dist/entries/assembly.cjs +29 -29
  46. package/dist/entries/assembly.js +6 -6
  47. package/dist/entries/doctrine.cjs +46 -46
  48. package/dist/entries/doctrine.js +1 -1
  49. package/dist/entries/picker-art.cjs +19 -19
  50. package/dist/entries/picker-art.d.cts +188 -0
  51. package/dist/entries/picker-art.d.ts +188 -0
  52. package/dist/entries/picker-art.js +1 -1
  53. package/dist/entries/picker-catalogs.cjs +57 -57
  54. package/dist/entries/picker-catalogs.js +5 -5
  55. package/dist/entries/pickers.cjs +374 -374
  56. package/dist/entries/pickers.d.cts +1 -1
  57. package/dist/entries/pickers.d.ts +1 -1
  58. package/dist/entries/pickers.js +3 -3
  59. package/dist/entries/presets.cjs +47 -31
  60. package/dist/entries/presets.d.cts +37 -1
  61. package/dist/entries/presets.d.ts +37 -1
  62. package/dist/entries/presets.js +1 -1
  63. package/dist/entries/prompt-builder.cjs +76 -76
  64. package/dist/entries/prompt-builder.js +5 -5
  65. package/dist/index.cjs +637 -621
  66. package/dist/index.d.cts +1 -1
  67. package/dist/index.d.ts +1 -1
  68. package/dist/index.js +11 -11
  69. package/package.json +2 -2
  70. package/src/__tests__/factory-preset-previews.test.ts +98 -25
  71. package/src/__tests__/factory-preset-references.test.ts +4 -0
  72. package/src/__tests__/fixtures/parameter-hint-golden.json +6 -6
  73. package/src/__tests__/preset-tiles-generated.test.ts +88 -0
  74. package/src/factory-presets/generate-image.ts +8 -0
  75. package/src/factory-presets/index.ts +10 -1
  76. package/src/factory-presets/preview-files.generated.ts +639 -1
  77. package/src/factory-presets/previews.ts +34 -2
  78. package/src/factory-presets/tiles/business-and-marketing.generated.ts +426 -0
  79. package/src/factory-presets/tiles/business.generated.ts +261 -0
  80. package/src/factory-presets/tiles/content-and-creative.generated.ts +286 -0
  81. package/src/factory-presets/tiles/family-and-events.generated.ts +222 -0
  82. package/src/factory-presets/tiles/home-and-spaces.generated.ts +231 -0
  83. package/src/factory-presets/tiles/index.generated.ts +32 -0
  84. package/src/factory-presets/tiles/layout.generated.ts +110 -0
  85. package/src/factory-presets/tiles/life-and-events.generated.ts +246 -0
  86. package/src/factory-presets/tiles/personal-photos.generated.ts +306 -0
  87. package/src/factory-presets/tiles/products-and-fashion.generated.ts +303 -0
  88. package/src/factory-presets/tiles/shorts-tiktok.generated.ts +156 -0
  89. package/src/factory-presets/tiles/social-and-ads.generated.ts +606 -0
  90. package/src/factory-presets/tiles/text.generated.ts +591 -0
  91. package/src/factory-presets/tiles/youtube.generated.ts +906 -0
  92. package/src/factory-presets/types.ts +14 -0
  93. package/src/photographer.ts +277 -0
  94. package/src/picker-art/look-preview-sets.ts +189 -0
  95. package/src/prompt-wizard-categories.ts +0 -2
  96. package/dist/chunk-CYMIXKFT.js.map +0 -1
  97. package/dist/chunk-JCYK7NSR.js.map +0 -1
  98. package/dist/chunk-LZ53F5BN.cjs +0 -5652
  99. package/dist/chunk-LZ53F5BN.cjs.map +0 -1
  100. package/dist/chunk-QBUSJGV3.js.map +0 -1
  101. package/dist/chunk-RB2F5JQF.js +0 -5621
  102. package/dist/chunk-RB2F5JQF.js.map +0 -1
  103. package/dist/chunk-SB7AYE6S.cjs.map +0 -1
  104. package/dist/chunk-WARNUGXT.cjs.map +0 -1
  105. package/dist/chunk-XTOSNRWT.cjs.map +0 -1
@@ -1,5 +1,5 @@
1
- import { getRegisteredSubjectKeys, SUBJECT_CUSTOM_AGE_KEY, SUBJECT_ID_MAX_CHARS, SUBJECT_ARRAY_CEILING } from './chunk-6JABZ5OC.js';
2
- import { DIRECTION_FIELDS, DIRECTION_ID_MAX_CHARS, DIRECTION_ARRAY_CEILING } from './chunk-QJACEKMZ.js';
1
+ import { getRegisteredSubjectKeys, SUBJECT_CUSTOM_AGE_KEY, SUBJECT_ID_MAX_CHARS, SUBJECT_ARRAY_CEILING } from './chunk-SMKIVT7P.js';
2
+ import { DIRECTION_FIELDS, DIRECTION_ID_MAX_CHARS, DIRECTION_ARRAY_CEILING } from './chunk-CPKYIVWP.js';
3
3
 
4
4
  // src/read-node-direction.ts
5
5
  function readDirectionFields(value) {
@@ -114,5 +114,5 @@ function readStructuredFields(value) {
114
114
  }
115
115
 
116
116
  export { readDirectionFields, readStructuredFields, readSubjectFields };
117
- //# sourceMappingURL=chunk-GIO77YH5.js.map
118
- //# sourceMappingURL=chunk-GIO77YH5.js.map
117
+ //# sourceMappingURL=chunk-NN4FL7SB.js.map
118
+ //# sourceMappingURL=chunk-NN4FL7SB.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/read-node-direction.ts"],"names":[],"mappings":";;;;AA2EO,SAAS,oBAAoB,KAAA,EAA6C;AAC/E,EAAA,IAAI,OAAO,UAAU,QAAA,IAAY,KAAA,KAAU,QAAQ,KAAA,CAAM,OAAA,CAAQ,KAAK,CAAA,EAAG,OAAO,MAAA;AAChF,EAAA,MAAM,GAAA,GAAM,KAAA;AACZ,EAAA,MAAM,MAAyC,EAAC;AAChD,EAAA,KAAA,MAAW,QAAQ,gBAAA,EAAkB;AACnC,IAAA,MAAM,CAAA,GAAI,GAAA,CAAI,IAAA,CAAK,GAAG,CAAA;AACtB,IAAA,IAAI,OAAO,MAAM,QAAA,EAAU;AACzB,MAAA,IAAI,CAAA,CAAE,SAAS,CAAA,IAAK,CAAA,CAAE,UAAU,sBAAA,EAAwB,GAAA,CAAI,IAAA,CAAK,GAAG,CAAA,GAAI,CAAA;AAAA,IAC1E,CAAA,MAAA,IAAW,KAAA,CAAM,OAAA,CAAQ,CAAC,CAAA,EAAG;AAC3B,MAAA,MAAM,OAAiB,EAAC;AACxB,MAAA,KAAA,MAAW,KAAK,CAAA,EAAG;AACjB,QAAA,IAAI,IAAA,CAAK,UAAU,uBAAA,EAAyB;AAC5C,QAAA,IAAI,OAAO,MAAM,QAAA,IAAY,CAAA,CAAE,SAAS,CAAA,IAAK,CAAA,CAAE,UAAU,sBAAA,EAAwB;AAC/E,UAAA,IAAA,CAAK,KAAK,CAAC,CAAA;AAAA,QACb;AAAA,MACF;AACA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AA,CAAO,KAAK,IAAI,CAAA,CAAE,SAAS,CAAA,EAAG,GAAA,CAAI,KAAK,CAAA,GAAI,IAAA;AAAA,EACjD;AACA,EAAA,MAAM,IAAA,GAAO,SAAA,CAAU,GAAA,CAAI,IAAA,EAAM,QAAQ,CAAA;AACzC,EAAA,IAAI,IAAA,KAAS,MAAA,EAAW,GAAA,CAAI,IAAA,GAAO,IAAA;AACnC,EAAA,OAAO,OAAO,IAAA,CAAK,GAAG,CAAA,CAAE,MAAA,GAAS,IAAK,GAAA,GAAiC,MAAA;AACzE","file":"chunk-GIO77YH5.js","sourcesContent":["/**\n * Narrow readers turning UNTRUSTED persisted node data (`workflows.nodes`\n * JSONB — import, MCP write, node preset, a Studio-emitted graph) into the\n * typed `subject` / `direction` / `structured` levers `assembleImageInput`\n * accepts.\n * `buildPayload` has no zod and workflow writes are\n * `z.record(z.string(), z.unknown())`, so this blob may have been written years\n * ago by any client.\n *\n * Used by ALL THREE image-assembly sites so what the canvas accepts cannot\n * drift between them: the frontend single-node executor (`execute-node.ts`),\n * the orchestrator (`payload-builder.ts`), and the config-panel final-prompt\n * preview (`build-image-assemble-input.ts`).\n *\n * `readDirectionFields` is DERIVED FROM `DIRECTION_FIELDS`, never a hand list:\n * a dimension added to the registry is honored here by construction, so the\n * reader can never silently drop a key the wire schema and the renderer both\n * know about. Anything unrecognised is DROPPED, never thrown on — a malformed\n * blob must not fail a canvas run, and an unknown catalog ID already degrades\n * to `\"\"` inside each `get*PromptHint`, so this validates SHAPE only.\n *\n * BOUNDS MATCH THE WIRE SCHEMA where both exist, by SHARED CONSTANT:\n * `DIRECTION_ID_MAX_CHARS` and `DIRECTION_ARRAY_CEILING` are the same two\n * literals the `generate-image` route's `directionSchema` enforces, imported\n * from the registry rather than re-typed here — a body the route accepts and a\n * node the canvas re-runs must not disagree about which strings are ids.\n *\n * DELIBERATELY STRICTER THAN THE WIRE SCHEMA on `structured` values: the\n * route's `structuredPromptFieldsSchema` declares every field as a bare\n * `z.string().optional()` (unbounded), while `MAX_STRUCTURED_VALUE_CHARS` below\n * bounds them at 200. Do not \"fix\" that asymmetry by loosening HERE — this\n * reads a blob any client may have written years ago, and the values land\n * verbatim in `jobs.input_data.prompt`. Tightening the ROUTE instead would be a\n * new 400 on currently-accepted input, so a >200-char structured value stored\n * on a node is dropped on a canvas run while `POST /v1/generate-image` still\n * renders it. That is the one known divergence; it is bounded to a field the\n * canvas UI never writes that long.\n *\n * RETURNS `undefined`, NEVER `{}`: an empty object would still be a *defined*\n * `direction`, and the call sites' `...(x !== undefined ? { x } : {})` spread\n * would then hand `assembleImageInput` a defined-but-empty lever. Returning\n * `undefined` keeps that spread honest and the exact no-op branch taken.\n */\nimport {\n DIRECTION_ARRAY_CEILING,\n DIRECTION_FIELDS,\n DIRECTION_ID_MAX_CHARS,\n type DirectionFields,\n} from \"./direction-registry.js\"\nimport {\n SUBJECT_ARRAY_CEILING,\n SUBJECT_CUSTOM_AGE_KEY,\n SUBJECT_ID_MAX_CHARS,\n getRegisteredSubjectKeys,\n type SubjectFields,\n} from \"./subject-registry.js\"\nimport type { StructuredPromptFields } from \"./prompt-builder-structured-fields.js\"\n\n/**\n * Read a node's stored cinematic-direction ids. Accepts a single id OR an array\n * on every key (multi-pick dimensions carry arrays; a single-pick key may\n * legitimately carry one).\n *\n * The SEMANTIC per-dimension cap stays the renderer's slice (`maxPicks`) — this\n * reader does not know a row's pick budget and must not guess it. But it DOES\n * bound cardinality at `DIRECTION_ARRAY_CEILING`, the same ceiling the wire\n * schema enforces: the value is untrusted persisted JSONB (a node blob is\n * validated only as `z.record(z.string(), z.unknown())` on write), and handing\n * an unbounded array to `renderDirectionHints` would put an `includes`-dedupe\n * scan in front of that slice. Keeping the FIRST `DIRECTION_ARRAY_CEILING`\n * survivors is what the wire door already does to the same input.\n *\n * Junk is filtered BEFORE the cap, so valid ids sitting behind malformed\n * entries survive rather than being crowded out by them.\n */\nexport function readDirectionFields(value: unknown): DirectionFields | undefined {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return undefined\n const src = value as Record<string, unknown>\n const out: Record<string, string | string[]> = {}\n for (const spec of DIRECTION_FIELDS) {\n const v = src[spec.key]\n if (typeof v === \"string\") {\n if (v.length > 0 && v.length <= DIRECTION_ID_MAX_CHARS) out[spec.key] = v\n } else if (Array.isArray(v)) {\n const kept: string[] = []\n for (const x of v) {\n if (kept.length >= DIRECTION_ARRAY_CEILING) break\n if (typeof x === \"string\" && x.length > 0 && x.length <= DIRECTION_ID_MAX_CHARS) {\n kept.push(x)\n }\n }\n if (kept.length > 0) out[spec.key] = kept\n }\n }\n return Object.keys(out).length > 0 ? (out as DirectionFields) : undefined\n}\n\n// ── subject ──────────────────────────────────────────────────────────────────\n\n/**\n * Read a node's stored SUBJECT ids — the flat Person / Styling / prop bag the\n * `subject` channel carries. Same three contracts as `readDirectionFields`:\n * drop-never-throw, `undefined` never `{}`, and bounds shared with the wire\n * door by CONSTANT (`SUBJECT_ID_MAX_CHARS` / `SUBJECT_ARRAY_CEILING`, which are\n * defined AS the direction constants) so a body the route accepts and the same\n * node re-run from the canvas cannot disagree about which strings are ids.\n *\n * DERIVED from `getRegisteredSubjectKeys()`, never a hand-authored field list —\n * that is the whole lesson of `readStructuredFields` below, whose hand table is\n * only viable because `StructuredPromptFields` is a small hand-authored type.\n * The subject vocabulary is ~54 catalog-derived fields PLUS deployment-registered\n * pack dimensions unknown at compile time, so it is read from the registry at\n * call time. Iterating the KEY SET (never `Object.keys(value)`) is also what\n * keeps an adversarial blob's key count off the hot path.\n *\n * The SEMANTIC per-dimension cap stays the renderer's job\n * (`normalizeSubjectFields`), exactly as `maxPicks` does for direction: this\n * reader bounds cardinality only. `customAge` is the one number on the wire and\n * is passed through finite-only — the renderer clamps it.\n */\nexport function readSubjectFields(value: unknown): SubjectFields | undefined {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return undefined\n const src = value as Record<string, unknown>\n const out: Record<string, string | string[] | number> = {}\n for (const key of getRegisteredSubjectKeys()) {\n const v = src[key]\n if (key === SUBJECT_CUSTOM_AGE_KEY) {\n if (typeof v === \"number\" && Number.isFinite(v)) out[key] = v\n continue\n }\n if (typeof v === \"string\") {\n if (v.length > 0 && v.length <= SUBJECT_ID_MAX_CHARS) out[key] = v\n } else if (Array.isArray(v)) {\n // Junk is filtered BEFORE the cap, so valid ids sitting behind malformed\n // entries survive rather than being crowded out by them.\n const kept: string[] = []\n for (const x of v) {\n if (kept.length >= SUBJECT_ARRAY_CEILING) break\n if (typeof x === \"string\" && x.length > 0 && x.length <= SUBJECT_ID_MAX_CHARS) {\n kept.push(x)\n }\n }\n if (kept.length > 0) out[key] = kept\n }\n }\n return Object.keys(out).length > 0 ? (out as SubjectFields) : undefined\n}\n\n// ── structured ───────────────────────────────────────────────────────────────\n\ntype FieldKind = \"string\" | \"number\" | \"gender\"\nconst GENDERS = [\"man\", \"woman\", \"child\", \"non-binary\"] as const\nconst MAX_STRUCTURED_VALUE_CHARS = 200\n\ntype Group = Exclude<keyof StructuredPromptFields, \"mood\">\ntype GroupFields<K extends Group> = Record<keyof NonNullable<StructuredPromptFields[K]>, FieldKind>\n\n/**\n * A FIELD-BY-FIELD table (not a registry walk) on purpose:\n * `StructuredPromptFields` is a small HAND-AUTHORED type, not catalog-derived,\n * and the table is what blocks `person: { age: \"drop table\" }` from rendering\n * verbatim into `jobs.input_data.prompt` — `renderStructuredFields` never\n * throws on junk, but it does render it. Totality is enforced by the\n * `GroupFields<K>` / `{ [K in Group]: … }` mapped types: a new field or group\n * on the published type fails to typecheck here.\n */\nconst PERSON_FIELDS: GroupFields<\"person\"> = {\n age: \"number\",\n gender: \"gender\",\n hair: \"string\",\n eyes: \"string\",\n expression: \"string\",\n profession: \"string\",\n warriorType: \"string\",\n}\nconst STYLING_FIELDS: GroupFields<\"styling\"> = {\n mood: \"string\",\n lighting: \"string\",\n aesthetic: \"string\",\n colorLook: \"string\",\n}\nconst SETTING_FIELDS: GroupFields<\"setting\"> = {\n era: \"string\",\n atmosphere: \"string\",\n backdrop: \"string\",\n}\nconst CAMERA_FIELDS: GroupFields<\"camera\"> = {\n framing: \"string\",\n motion: \"string\",\n format: \"string\",\n}\nconst LENS_FIELDS: GroupFields<\"lens\"> = { focalLength: \"string\", aperture: \"string\" }\n\nconst STRUCTURED_GROUPS: { [K in Group]: GroupFields<K> } = {\n person: PERSON_FIELDS,\n styling: STYLING_FIELDS,\n setting: SETTING_FIELDS,\n camera: CAMERA_FIELDS,\n lens: LENS_FIELDS,\n}\n\nfunction readField(v: unknown, kind: FieldKind): string | number | undefined {\n if (kind === \"number\") return typeof v === \"number\" && Number.isFinite(v) ? v : undefined\n if (typeof v !== \"string\" || v.length === 0 || v.length > MAX_STRUCTURED_VALUE_CHARS) {\n return undefined\n }\n if (kind === \"gender\") return (GENDERS as readonly string[]).includes(v) ? v : undefined\n return v\n}\n\n/** Read a node's stored Path-1 structured prompt fields. Same drop-never-throw\n * and `undefined`-never-`{}` contract as `readDirectionFields`. */\nexport function readStructuredFields(value: unknown): StructuredPromptFields | undefined {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return undefined\n const src = value as Record<string, unknown>\n const out: Record<string, unknown> = {}\n for (const group of Object.keys(STRUCTURED_GROUPS) as Group[]) {\n const raw = src[group]\n if (typeof raw !== \"object\" || raw === null || Array.isArray(raw)) continue\n const rawRec = raw as Record<string, unknown>\n const kept: Record<string, unknown> = {}\n for (const [field, kind] of Object.entries(\n STRUCTURED_GROUPS[group] as Record<string, FieldKind>,\n )) {\n const v = readField(rawRec[field], kind)\n if (v !== undefined) kept[field] = v\n }\n if (Object.keys(kept).length > 0) out[group] = kept\n }\n const mood = readField(src.mood, \"string\")\n if (mood !== undefined) out.mood = mood\n return Object.keys(out).length > 0 ? (out as StructuredPromptFields) : undefined\n}\n"]}
1
+ {"version":3,"sources":["../src/read-node-direction.ts"],"names":[],"mappings":";;;;AA2EO,SAAS,oBAAoB,KAAA,EAA6C;AAC/E,EAAA,IAAI,OAAO,UAAU,QA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n * JSONB — import, MCP write, node preset, a Studio-emitted graph) into the\n * typed `subject` / `direction` / `structured` levers `assembleImageInput`\n * accepts.\n * `buildPayload` has no zod and workflow writes are\n * `z.record(z.string(), z.unknown())`, so this blob may have been written years\n * ago by any client.\n *\n * Used by ALL THREE image-assembly sites so what the canvas accepts cannot\n * drift between them: the frontend single-node executor (`execute-node.ts`),\n * the orchestrator (`payload-builder.ts`), and the config-panel final-prompt\n * preview (`build-image-assemble-input.ts`).\n *\n * `readDirectionFields` is DERIVED FROM `DIRECTION_FIELDS`, never a hand list:\n * a dimension added to the registry is honored here by construction, so the\n * reader can never silently drop a key the wire schema and the renderer both\n * know about. Anything unrecognised is DROPPED, never thrown on — a malformed\n * blob must not fail a canvas run, and an unknown catalog ID already degrades\n * to `\"\"` inside each `get*PromptHint`, so this validates SHAPE only.\n *\n * BOUNDS MATCH THE WIRE SCHEMA where both exist, by SHARED CONSTANT:\n * `DIRECTION_ID_MAX_CHARS` and `DIRECTION_ARRAY_CEILING` are the same two\n * literals the `generate-image` route's `directionSchema` enforces, imported\n * from the registry rather than re-typed here — a body the route accepts and a\n * node the canvas re-runs must not disagree about which strings are ids.\n *\n * DELIBERATELY STRICTER THAN THE WIRE SCHEMA on `structured` values: the\n * route's `structuredPromptFieldsSchema` declares every field as a bare\n * `z.string().optional()` (unbounded), while `MAX_STRUCTURED_VALUE_CHARS` below\n * bounds them at 200. Do not \"fix\" that asymmetry by loosening HERE — this\n * reads a blob any client may have written years ago, and the values land\n * verbatim in `jobs.input_data.prompt`. Tightening the ROUTE instead would be a\n * new 400 on currently-accepted input, so a >200-char structured value stored\n * on a node is dropped on a canvas run while `POST /v1/generate-image` still\n * renders it. That is the one known divergence; it is bounded to a field the\n * canvas UI never writes that long.\n *\n * RETURNS `undefined`, NEVER `{}`: an empty object would still be a *defined*\n * `direction`, and the call sites' `...(x !== undefined ? { x } : {})` spread\n * would then hand `assembleImageInput` a defined-but-empty lever. Returning\n * `undefined` keeps that spread honest and the exact no-op branch taken.\n */\nimport {\n DIRECTION_ARRAY_CEILING,\n DIRECTION_FIELDS,\n DIRECTION_ID_MAX_CHARS,\n type DirectionFields,\n} from \"./direction-registry.js\"\nimport {\n SUBJECT_ARRAY_CEILING,\n SUBJECT_CUSTOM_AGE_KEY,\n SUBJECT_ID_MAX_CHARS,\n getRegisteredSubjectKeys,\n type SubjectFields,\n} from \"./subject-registry.js\"\nimport type { StructuredPromptFields } from \"./prompt-builder-structured-fields.js\"\n\n/**\n * Read a node's stored cinematic-direction ids. Accepts a single id OR an array\n * on every key (multi-pick dimensions carry arrays; a single-pick key may\n * legitimately carry one).\n *\n * The SEMANTIC per-dimension cap stays the renderer's slice (`maxPicks`) — this\n * reader does not know a row's pick budget and must not guess it. But it DOES\n * bound cardinality at `DIRECTION_ARRAY_CEILING`, the same ceiling the wire\n * schema enforces: the value is untrusted persisted JSONB (a node blob is\n * validated only as `z.record(z.string(), z.unknown())` on write), and handing\n * an unbounded array to `renderDirectionHints` would put an `includes`-dedupe\n * scan in front of that slice. Keeping the FIRST `DIRECTION_ARRAY_CEILING`\n * survivors is what the wire door already does to the same input.\n *\n * Junk is filtered BEFORE the cap, so valid ids sitting behind malformed\n * entries survive rather than being crowded out by them.\n */\nexport function readDirectionFields(value: unknown): DirectionFields | undefined {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return undefined\n const src = value as Record<string, unknown>\n const out: Record<string, string | string[]> = {}\n for (const spec of DIRECTION_FIELDS) {\n const v = src[spec.key]\n if (typeof v === \"string\") {\n if (v.length > 0 && v.length <= DIRECTION_ID_MAX_CHARS) out[spec.key] = v\n } else if (Array.isArray(v)) {\n const kept: string[] = []\n for (const x of v) {\n if (kept.length >= DIRECTION_ARRAY_CEILING) break\n if (typeof x === \"string\" && x.length > 0 && x.length <= DIRECTION_ID_MAX_CHARS) {\n kept.push(x)\n }\n }\n if (kept.length > 0) out[spec.key] = kept\n }\n }\n return Object.keys(out).length > 0 ? (out as DirectionFields) : undefined\n}\n\n// ── subject ──────────────────────────────────────────────────────────────────\n\n/**\n * Read a node's stored SUBJECT ids — the flat Person / Styling / prop bag the\n * `subject` channel carries. Same three contracts as `readDirectionFields`:\n * drop-never-throw, `undefined` never `{}`, and bounds shared with the wire\n * door by CONSTANT (`SUBJECT_ID_MAX_CHARS` / `SUBJECT_ARRAY_CEILING`, which are\n * defined AS the direction constants) so a body the route accepts and the same\n * node re-run from the canvas cannot disagree about which strings are ids.\n *\n * DERIVED from `getRegisteredSubjectKeys()`, never a hand-authored field list —\n * that is the whole lesson of `readStructuredFields` below, whose hand table is\n * only viable because `StructuredPromptFields` is a small hand-authored type.\n * The subject vocabulary is ~54 catalog-derived fields PLUS deployment-registered\n * pack dimensions unknown at compile time, so it is read from the registry at\n * call time. Iterating the KEY SET (never `Object.keys(value)`) is also what\n * keeps an adversarial blob's key count off the hot path.\n *\n * The SEMANTIC per-dimension cap stays the renderer's job\n * (`normalizeSubjectFields`), exactly as `maxPicks` does for direction: this\n * reader bounds cardinality only. `customAge` is the one number on the wire and\n * is passed through finite-only — the renderer clamps it.\n */\nexport function readSubjectFields(value: unknown): SubjectFields | undefined {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return undefined\n const src = value as Record<string, unknown>\n const out: Record<string, string | string[] | number> = {}\n for (const key of getRegisteredSubjectKeys()) {\n const v = src[key]\n if (key === SUBJECT_CUSTOM_AGE_KEY) {\n if (typeof v === \"number\" && Number.isFinite(v)) out[key] = v\n continue\n }\n if (typeof v === \"string\") {\n if (v.length > 0 && v.length <= SUBJECT_ID_MAX_CHARS) out[key] = v\n } else if (Array.isArray(v)) {\n // Junk is filtered BEFORE the cap, so valid ids sitting behind malformed\n // entries survive rather than being crowded out by them.\n const kept: string[] = []\n for (const x of v) {\n if (kept.length >= SUBJECT_ARRAY_CEILING) break\n if (typeof x === \"string\" && x.length > 0 && x.length <= SUBJECT_ID_MAX_CHARS) {\n kept.push(x)\n }\n }\n if (kept.length > 0) out[key] = kept\n }\n }\n return Object.keys(out).length > 0 ? (out as SubjectFields) : undefined\n}\n\n// ── structured ───────────────────────────────────────────────────────────────\n\ntype FieldKind = \"string\" | \"number\" | \"gender\"\nconst GENDERS = [\"man\", \"woman\", \"child\", \"non-binary\"] as const\nconst MAX_STRUCTURED_VALUE_CHARS = 200\n\ntype Group = Exclude<keyof StructuredPromptFields, \"mood\">\ntype GroupFields<K extends Group> = Record<keyof NonNullable<StructuredPromptFields[K]>, FieldKind>\n\n/**\n * A FIELD-BY-FIELD table (not a registry walk) on purpose:\n * `StructuredPromptFields` is a small HAND-AUTHORED type, not catalog-derived,\n * and the table is what blocks `person: { age: \"drop table\" }` from rendering\n * verbatim into `jobs.input_data.prompt` — `renderStructuredFields` never\n * throws on junk, but it does render it. Totality is enforced by the\n * `GroupFields<K>` / `{ [K in Group]: … }` mapped types: a new field or group\n * on the published type fails to typecheck here.\n */\nconst PERSON_FIELDS: GroupFields<\"person\"> = {\n age: \"number\",\n gender: \"gender\",\n hair: \"string\",\n eyes: \"string\",\n expression: \"string\",\n profession: \"string\",\n warriorType: \"string\",\n}\nconst STYLING_FIELDS: GroupFields<\"styling\"> = {\n mood: \"string\",\n lighting: \"string\",\n aesthetic: \"string\",\n colorLook: \"string\",\n}\nconst SETTING_FIELDS: GroupFields<\"setting\"> = {\n era: \"string\",\n atmosphere: \"string\",\n backdrop: \"string\",\n}\nconst CAMERA_FIELDS: GroupFields<\"camera\"> = {\n framing: \"string\",\n motion: \"string\",\n format: \"string\",\n}\nconst LENS_FIELDS: GroupFields<\"lens\"> = { focalLength: \"string\", aperture: \"string\" }\n\nconst STRUCTURED_GROUPS: { [K in Group]: GroupFields<K> } = {\n person: PERSON_FIELDS,\n styling: STYLING_FIELDS,\n setting: SETTING_FIELDS,\n camera: CAMERA_FIELDS,\n lens: LENS_FIELDS,\n}\n\nfunction readField(v: unknown, kind: FieldKind): string | number | undefined {\n if (kind === \"number\") return typeof v === \"number\" && Number.isFinite(v) ? v : undefined\n if (typeof v !== \"string\" || v.length === 0 || v.length > MAX_STRUCTURED_VALUE_CHARS) {\n return undefined\n }\n if (kind === \"gender\") return (GENDERS as readonly string[]).includes(v) ? v : undefined\n return v\n}\n\n/** Read a node's stored Path-1 structured prompt fields. Same drop-never-throw\n * and `undefined`-never-`{}` contract as `readDirectionFields`. */\nexport function readStructuredFields(value: unknown): StructuredPromptFields | undefined {\n if (typeof value !== \"object\" || value === null || Array.isArray(value)) return undefined\n const src = value as Record<string, unknown>\n const out: Record<string, unknown> = {}\n for (const group of Object.keys(STRUCTURED_GROUPS) as Group[]) {\n const raw = src[group]\n if (typeof raw !== \"object\" || raw === null || Array.isArray(raw)) continue\n const rawRec = raw as Record<string, unknown>\n const kept: Record<string, unknown> = {}\n for (const [field, kind] of Object.entries(\n STRUCTURED_GROUPS[group] as Record<string, FieldKind>,\n )) {\n const v = readField(rawRec[field], kind)\n if (v !== undefined) kept[field] = v\n }\n if (Object.keys(kept).length > 0) out[group] = kept\n }\n const mood = readField(src.mood, \"string\")\n if (mood !== undefined) out.mood = mood\n return Object.keys(out).length > 0 ? (out as StructuredPromptFields) : undefined\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkSB7AYE6S_cjs = require('./chunk-SB7AYE6S.cjs');
3
+ var chunkJHEZJKTX_cjs = require('./chunk-JHEZJKTX.cjs');
4
4
  var catalogs = require('@nodaro/shared/catalogs');
5
5
 
6
6
  var WARDROBE_DIMENSION_ORDER = [
@@ -169,11 +169,11 @@ function getCharacterMotionDiagnostics(value, timing, bindings = {}) {
169
169
  const requested = typeof value === "string" ? [value] : Array.isArray(value) ? [...new Set(value)] : [];
170
170
  const result = [];
171
171
  const add = (code, severity, ids, message) => result.push({ code, severity, ids, message });
172
- if (requested.length > chunkSB7AYE6S_cjs.CHARACTER_MOTION_MAX_PICKS) add("capacity", "warning", requested, "Only the first three selections contribute. Remove extra selections.");
173
- const picks = requested.slice(0, chunkSB7AYE6S_cjs.CHARACTER_MOTION_MAX_PICKS);
174
- for (const id of picks) if (!chunkSB7AYE6S_cjs.getCharacterMotion(id)) add("unknown", "error", [id], `Motion \u201C${id}\u201D is unavailable and contributes no fragment. Remove or replace it.`);
172
+ if (requested.length > chunkJHEZJKTX_cjs.CHARACTER_MOTION_MAX_PICKS) add("capacity", "warning", requested, "Only the first three selections contribute. Remove extra selections.");
173
+ const picks = requested.slice(0, chunkJHEZJKTX_cjs.CHARACTER_MOTION_MAX_PICKS);
174
+ for (const id of picks) if (!chunkJHEZJKTX_cjs.getCharacterMotion(id)) add("unknown", "error", [id], `Motion \u201C${id}\u201D is unavailable and contributes no fragment. Remove or replace it.`);
175
175
  const entries = picks.flatMap((id) => {
176
- const entry = chunkSB7AYE6S_cjs.getCharacterMotion(id);
176
+ const entry = chunkJHEZJKTX_cjs.getCharacterMotion(id);
177
177
  return entry?.promptHint ? [entry] : [];
178
178
  });
179
179
  const active = entries.filter((e) => !bindings.subjectMinor || !e.adultOnly);
@@ -182,7 +182,7 @@ function getCharacterMotionDiagnostics(value, timing, bindings = {}) {
182
182
  if (omitted.length) add("omitted", active.length ? "warning" : "error", omitted.map((e) => e.id), `${omitted.map((e) => e.label).join(", ")} omitted for a connected minor. ${active.length ? "Replace these selections." : "No selected motion contributes a fragment."}`);
183
183
  if ((bindings.targetNames?.length ?? 0) > 1) add("multiple-targets", "warning", picks, "Each target performs a separate copy of the sequence. Use separate motion nodes for coordinated choreography.");
184
184
  for (const entry of active) {
185
- if (entry.deprecated) add("retired", "warning", [entry.id], `${entry.label} is retired from new choices but still resolves in saved workflows.${entry.replacementId ? ` Use ${chunkSB7AYE6S_cjs.getCharacterMotion(entry.replacementId)?.label ?? entry.replacementId}.` : ""}`);
185
+ if (entry.deprecated) add("retired", "warning", [entry.id], `${entry.label} is retired from new choices but still resolves in saved workflows.${entry.replacementId ? ` Use ${chunkJHEZJKTX_cjs.getCharacterMotion(entry.replacementId)?.label ?? entry.replacementId}.` : ""}`);
186
186
  if (entry.fixedPace && timing?.pace && timing.pace !== "auto") add("pace", "warning", [entry.id], `${entry.label} sets its own timing. Set Pace to Auto or replace the motion.`);
187
187
  if (entry.requires?.length) add("requirements", "info", [entry.id], `${entry.label} requires: ${entry.requires.join(", ")}.${entry.twoPerson || entry.counterpart ? bindings.partnerNames?.length ? ` Partner reference: ${bindings.partnerNames.join(", ")}; confirm it matches the required recipient.` : " Connect a Partner reference to identify the recipient; otherwise the model chooses it." : " Establish these in the scene or prompt; the fragment does not supply reference media."}`);
188
188
  }
@@ -206,5 +206,5 @@ exports.getCharacterMotionDiagnostics = getCharacterMotionDiagnostics;
206
206
  exports.getWardrobeEntriesByDimension = getWardrobeEntriesByDimension;
207
207
  exports.getWardrobeEntry = getWardrobeEntry;
208
208
  exports.getWardrobePromptHint = getWardrobePromptHint;
209
- //# sourceMappingURL=chunk-I3QS7BSY.cjs.map
210
- //# sourceMappingURL=chunk-I3QS7BSY.cjs.map
209
+ //# sourceMappingURL=chunk-OSKABA64.cjs.map
210
+ //# sourceMappingURL=chunk-OSKABA64.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/wardrobe.ts","../src/character-motion-diagnostics.ts"],"names":["id","pickIds","h","CHARACTER_MOTION_MAX_PICKS","getCharacterMotion"],"mappings":";;;;;AA0BO,IAAM,wBAAA,GAA6D;AAAA,EACxE,WAAA;AAAA,EAAa,KAAA;AAAA,EAAO,QAAA;AAAA,EAAU,WAAA;AAAA,EAAa,UAAA;AAAA,EAC3C,UAAA;AAAA,EAAY,aAAA;AAAA,EAAe,eAAA;AAAA,EAAiB,UAAA;AAAA,EAAY;AAC1D;AAEO,IAAM,wBAAA,GAAwE;AAAA,EACnF,SAAA,EAAW,WAAA;AAAA,EAAa,GAAA,EAAK,KAAA;AAAA,EAAO,MAAA,EAAQ,QAAA;AAAA,EAAU,SAAA,EAAW,WAAA;AAAA,EACjE,QAAA,EAAU,UAAA;AAAA,EAAY,QAAA,EAAU,UAAA;AAAA,EAAY,WAAA,EAAa,aAAA;AAAA,EACzD,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EAAgB,GAAA,CAAI,OAAA,EAAS,SAAA,EAAW,KAAK,CAAA,EAAG,MAAA,CAAO,KAAK,CAAA,wBAAA,EAA2B,KAAA,CAAM,KAAK,CAAA,uCAAA,CAAyC,CAAA;AAAA,EAC5M;AACA,EAAA,MAAM,WAAW,MAAA,CAAO,MAAA,CAAO,CAAA,CAAA,KAAK,CAAA,CAAE,SAAS,UAAU,CAAA;AACzD,EAAA,IAAI,QAAA,CAAS,QAAQ,GAAA,CAAI,UAAA,EAAY,WAAW,QAAA,CAAS,GAAA,CAAI,OAAK,CAAA,CAAE,EAAE,GAAG,CAAA,EAAG,QAAA,CAAS,MAAM,CAAA,UAAA,EAAa,QAAA,CAAS,WAAW,CAAA,GAAI,KAAA,GAAQ,OAAO,CAAA,0GAAA,CAA4G,CAAA;AAC3P,EAAA,OAAO,MAAA;AACT","file":"chunk-I3QS7BSY.cjs","sourcesContent":["import { pickIds } from \"@nodaro/shared/catalogs\"\n\nexport type WardrobeDimension =\n | \"archetype\" | \"top\" | \"bottom\" | \"outerwear\" | \"footwear\"\n | \"headwear\" | \"accessories\" | \"color-palette\" | \"material\" | \"era\"\n\nexport interface WardrobeEntry {\n readonly id: string\n readonly label: string\n readonly dimension: WardrobeDimension\n readonly promptHint: string\n}\n\nexport interface WardrobeValue {\n archetype?: string\n top?: string\n bottom?: string\n outerwear?: string\n footwear?: string\n headwear?: string | ReadonlyArray<string>\n accessories?: string | ReadonlyArray<string>\n colorPalette?: string\n material?: string\n era?: string\n}\n\nexport const WARDROBE_DIMENSION_ORDER: ReadonlyArray<WardrobeDimension> = [\n \"archetype\", \"top\", \"bottom\", \"outerwear\", \"footwear\",\n \"headwear\", \"accessories\", \"color-palette\", \"material\", \"era\",\n]\n\nexport const WARDROBE_CATEGORY_LABELS: Readonly<Record<WardrobeDimension, string>> = {\n archetype: \"Archetype\", top: \"Top\", bottom: \"Bottom\", outerwear: \"Outerwear\",\n footwear: \"Footwear\", headwear: \"Headwear\", accessories: \"Accessories\",\n \"color-palette\": \"Color Palette\", material: \"Material\", era: \"Era\",\n}\n\nexport const WARDROBE_FIELD_BY_DIMENSION: Record<WardrobeDimension, keyof WardrobeValue> = {\n archetype: \"archetype\", top: \"top\", bottom: \"bottom\", outerwear: \"outerwear\",\n footwear: \"footwear\", headwear: \"headwear\", accessories: \"accessories\",\n \"color-palette\": \"colorPalette\", material: \"material\", era: \"era\",\n}\n\n/** Multi-pick dims emit each picked entry independently. */\nconst MULTI_PICK: ReadonlySet<WardrobeDimension> = new Set([\"headwear\", \"accessories\"])\n/** Sentinel ids that mean \"nothing here\" and emit no hint. */\nconst NONE_IDS: ReadonlySet<string> = new Set([\"wd-outer-none\"])\n\nexport const WARDROBE: ReadonlyArray<WardrobeEntry> = [\n // archetype\n { id: \"wd-casual\", label: \"Casual\", dimension: \"archetype\", promptHint: \"in casual everyday clothing\" },\n { id: \"wd-business\", label: \"Business\", dimension: \"archetype\", promptHint: \"in smart business attire\" },\n { id: \"wd-formal\", label: \"Formal\", dimension: \"archetype\", promptHint: \"in elegant formal wear\" },\n { id: \"wd-streetwear\", label: \"Streetwear\", dimension: \"archetype\", promptHint: \"in contemporary streetwear\" },\n { id: \"wd-athletic\", label: \"Athletic\", dimension: \"archetype\", promptHint: \"in athletic sportswear\" },\n { id: \"wd-fantasy\", label: \"Fantasy\", dimension: \"archetype\", promptHint: \"in fantasy costume\" },\n { id: \"wd-scifi\", label: \"Sci-Fi\", dimension: \"archetype\", promptHint: \"in futuristic sci-fi attire\" },\n { id: \"wd-historical\", label: \"Historical\", dimension: \"archetype\", promptHint: \"in period historical dress\" },\n { id: \"wd-uniform\", label: \"Uniform\", dimension: \"archetype\", promptHint: \"in a uniform\" },\n { id: \"wd-loungewear\", label: \"Loungewear\", dimension: \"archetype\", promptHint: \"in relaxed loungewear\" },\n // top\n { id: \"wd-tshirt\", label: \"T-Shirt\", dimension: \"top\", promptHint: \"wearing a t-shirt\" },\n { id: \"wd-blouse\", label: \"Blouse\", dimension: \"top\", promptHint: \"wearing a blouse\" },\n { id: \"wd-hoodie\", label: \"Hoodie\", dimension: \"top\", promptHint: \"wearing a hoodie\" },\n { id: \"wd-buttondown\", label: \"Button-down\", dimension: \"top\", promptHint: \"wearing a button-down shirt\" },\n { id: \"wd-tank\", label: \"Tank\", dimension: \"top\", promptHint: \"wearing a tank top\" },\n { id: \"wd-sweater\", label: \"Sweater\", dimension: \"top\", promptHint: \"wearing a sweater\" },\n { id: \"wd-turtleneck\", label: \"Turtleneck\", dimension: \"top\", promptHint: \"wearing a turtleneck\" },\n // bottom\n { id: \"wd-jeans\", label: \"Jeans\", dimension: \"bottom\", promptHint: \"wearing jeans\" },\n { id: \"wd-trousers\", label: \"Trousers\", dimension: \"bottom\", promptHint: \"wearing tailored trousers\" },\n { id: \"wd-skirt\", label: \"Skirt\", dimension: \"bottom\", promptHint: \"wearing a skirt\" },\n { id: \"wd-shorts\", label: \"Shorts\", dimension: \"bottom\", promptHint: \"wearing shorts\" },\n { id: \"wd-leggings\", label: \"Leggings\", dimension: \"bottom\", promptHint: \"wearing leggings\" },\n { id: \"wd-cargo\", label: \"Cargo\", dimension: \"bottom\", promptHint: \"wearing cargo pants\" },\n // outerwear\n { id: \"wd-outer-none\", label: \"None\", dimension: \"outerwear\", promptHint: \"\" },\n { id: \"wd-leatherjkt\", label: \"Leather Jacket\", dimension: \"outerwear\", promptHint: \"in a leather jacket\" },\n { id: \"wd-blazer\", label: \"Blazer\", dimension: \"outerwear\", promptHint: \"in a blazer\" },\n { id: \"wd-trench\", label: \"Trench Coat\", dimension: \"outerwear\", promptHint: \"in a trench coat\" },\n { id: \"wd-parka\", label: \"Parka\", dimension: \"outerwear\", promptHint: \"in a parka\" },\n { id: \"wd-cloak\", label: \"Cloak\", dimension: \"outerwear\", promptHint: \"in a flowing cloak\" },\n { id: \"wd-denimjkt\", label: \"Denim Jacket\", dimension: \"outerwear\", promptHint: \"in a denim jacket\" },\n { id: \"wd-cardigan\", label: \"Cardigan\", dimension: \"outerwear\", promptHint: \"in a cardigan\" },\n // footwear\n { id: \"wd-sneakers\", label: \"Sneakers\", dimension: \"footwear\", promptHint: \"wearing sneakers\" },\n { id: \"wd-boots\", label: \"Boots\", dimension: \"footwear\", promptHint: \"wearing boots\" },\n { id: \"wd-heels\", label: \"Heels\", dimension: \"footwear\", promptHint: \"wearing heels\" },\n { id: \"wd-sandals\", label: \"Sandals\", dimension: \"footwear\", promptHint: \"wearing sandals\" },\n { id: \"wd-dressshoe\", label: \"Dress Shoes\", dimension: \"footwear\", promptHint: \"wearing dress shoes\" },\n { id: \"wd-barefoot\", label: \"Barefoot\", dimension: \"footwear\", promptHint: \"barefoot\" },\n // headwear (multi)\n { id: \"wd-cap\", label: \"Cap\", dimension: \"headwear\", promptHint: \"wearing a cap\" },\n { id: \"wd-beanie\", label: \"Beanie\", dimension: \"headwear\", promptHint: \"wearing a beanie\" },\n { id: \"wd-widehat\", label: \"Wide-brim Hat\", dimension: \"headwear\", promptHint: \"wearing a wide-brim hat\" },\n { id: \"wd-hood\", label: \"Hood\", dimension: \"headwear\", promptHint: \"with the hood up\" },\n { id: \"wd-crown\", label: \"Crown\", dimension: \"headwear\", promptHint: \"wearing a crown\" },\n { id: \"wd-helmet\", label: \"Helmet\", dimension: \"headwear\", promptHint: \"wearing a helmet\" },\n // accessories (multi)\n { id: \"wd-glasses\", label: \"Glasses\", dimension: \"accessories\", promptHint: \"wearing glasses\" },\n { id: \"wd-sunglasses\", label: \"Sunglasses\", dimension: \"accessories\", promptHint: \"wearing sunglasses\" },\n { id: \"wd-scarf\", label: \"Scarf\", dimension: \"accessories\", promptHint: \"wearing a scarf\" },\n { id: \"wd-gloves\", label: \"Gloves\", dimension: \"accessories\", promptHint: \"wearing gloves\" },\n { id: \"wd-jewelry\", label: \"Jewelry\", dimension: \"accessories\", promptHint: \"wearing statement jewelry\" },\n { id: \"wd-belt\", label: \"Belt\", dimension: \"accessories\", promptHint: \"with a belt\" },\n { id: \"wd-watch\", label: \"Watch\", dimension: \"accessories\", promptHint: \"wearing a watch\" },\n // color-palette\n { id: \"wd-neutral\", label: \"Neutral\", dimension: \"color-palette\", promptHint: \"in a neutral color palette\" },\n { id: \"wd-all-black\", label: \"All Black\", dimension: \"color-palette\", promptHint: \"in an all-black palette\" },\n { id: \"wd-earth\", label: \"Earth Tones\", dimension: \"color-palette\", promptHint: \"in earth-tone colors\" },\n { id: \"wd-pastel\", label: \"Pastel\", dimension: \"color-palette\", promptHint: \"in pastel colors\" },\n { id: \"wd-jewel\", label: \"Jewel Tones\", dimension: \"color-palette\", promptHint: \"in rich jewel-tone colors\" },\n { id: \"wd-neon\", label: \"Neon\", dimension: \"color-palette\", promptHint: \"in vivid neon colors\" },\n { id: \"wd-all-white\", label: \"All White\", dimension: \"color-palette\", promptHint: \"in an all-white palette\" },\n // material\n { id: \"wd-cotton\", label: \"Cotton\", dimension: \"material\", promptHint: \"in cotton fabric\" },\n { id: \"wd-denim\", label: \"Denim\", dimension: \"material\", promptHint: \"in denim\" },\n { id: \"wd-leather\", label: \"Leather\", dimension: \"material\", promptHint: \"in leather\" },\n { id: \"wd-silk\", label: \"Silk\", dimension: \"material\", promptHint: \"in silk\" },\n { id: \"wd-wool\", label: \"Wool\", dimension: \"material\", promptHint: \"in wool\" },\n { id: \"wd-latex\", label: \"Latex\", dimension: \"material\", promptHint: \"in latex\" },\n { id: \"wd-linen\", label: \"Linen\", dimension: \"material\", promptHint: \"in linen\" },\n // era\n { id: \"wd-contemporary\", label: \"Contemporary\", dimension: \"era\", promptHint: \"in contemporary fashion\" },\n { id: \"wd-1920s\", label: \"1920s\", dimension: \"era\", promptHint: \"in 1920s fashion\" },\n { id: \"wd-1950s\", label: \"1950s\", dimension: \"era\", promptHint: \"in 1950s fashion\" },\n { id: \"wd-1980s\", label: \"1980s\", dimension: \"era\", promptHint: \"in 1980s fashion\" },\n { id: \"wd-victorian\", label: \"Victorian\", dimension: \"era\", promptHint: \"in Victorian-era dress\" },\n { id: \"wd-medieval\", label: \"Medieval\", dimension: \"era\", promptHint: \"in medieval dress\" },\n { id: \"wd-futuristic\", label: \"Futuristic\", dimension: \"era\", promptHint: \"in futuristic clothing\" },\n] as const\n\nconst BY_ID: Map<string, WardrobeEntry> = new Map(WARDROBE.map((e) => [e.id, e]))\n\n/** Entries grouped by dimension — precomputed once so per-dimension lookups\n * (the picker calls one per dimension per render) are O(1) with stable array\n * refs, instead of a full WARDROBE scan each call. */\nconst BY_DIMENSION: Map<WardrobeDimension, WardrobeEntry[]> = (() => {\n const map = new Map<WardrobeDimension, WardrobeEntry[]>()\n for (const e of WARDROBE) {\n const list = map.get(e.dimension)\n if (list) list.push(e)\n else map.set(e.dimension, [e])\n }\n return map\n})()\n\nexport function getWardrobeEntry(id: string | undefined | null): WardrobeEntry | undefined {\n return id ? BY_ID.get(id) : undefined\n}\n\nexport function getWardrobePromptHint(id: string | undefined | null): string {\n return getWardrobeEntry(id)?.promptHint ?? \"\"\n}\n\nexport function getWardrobeEntriesByDimension(dim: WardrobeDimension): WardrobeEntry[] {\n return BY_DIMENSION.get(dim) ?? []\n}\n\nexport function buildWardrobeHints(value: Record<string, unknown> & WardrobeValue): string[] {\n const hints: string[] = []\n for (const dimension of WARDROBE_DIMENSION_ORDER) {\n const field = WARDROBE_FIELD_BY_DIMENSION[dimension]\n const raw = value[field]\n if (MULTI_PICK.has(dimension)) {\n for (const id of pickIds(raw)) {\n if (NONE_IDS.has(id)) continue\n const h = getWardrobePromptHint(id)\n if (h) hints.push(h)\n }\n continue\n }\n const id = typeof raw === \"string\" ? raw : undefined\n if (!id || NONE_IDS.has(id)) continue\n const h = getWardrobePromptHint(id)\n if (h) hints.push(h)\n }\n return hints\n}\n","import { getCharacterMotion, CHARACTER_MOTION_MAX_PICKS, type CharacterMotionTiming } from \"./character-motion.js\"\n\nexport interface CharacterMotionDiagnostic {\n readonly code: \"unknown\" | \"omitted\" | \"retired\" | \"pose\" | \"visibility\" | \"hands\" | \"pace\" | \"requirements\" | \"compound\" | \"capacity\" | \"multiple-targets\" | \"roles\"\n readonly severity: \"error\" | \"warning\" | \"info\"\n readonly ids: readonly string[]\n readonly message: string\n}\nexport interface CharacterMotionBindings {\n readonly selfPairing?: boolean\n readonly subjectMinor?: boolean\n readonly partnerNames?: readonly string[]\n readonly targetNames?: readonly string[]\n}\n\n/** Shared by editor, API clients and local review. Missing metadata means\n * unknown; this never certifies a sequence or predicts clip duration. */\nexport function getCharacterMotionDiagnostics(\n value: string | readonly string[] | null | undefined,\n timing?: CharacterMotionTiming,\n bindings: CharacterMotionBindings = {},\n): readonly CharacterMotionDiagnostic[] {\n const requested = typeof value === \"string\" ? [value] : Array.isArray(value) ? [...new Set(value)] : []\n const result: CharacterMotionDiagnostic[] = []\n const add = (code: CharacterMotionDiagnostic[\"code\"], severity: CharacterMotionDiagnostic[\"severity\"], ids: readonly string[], message: string) => result.push({ code, severity, ids, message })\n if (requested.length > CHARACTER_MOTION_MAX_PICKS) add(\"capacity\", \"warning\", requested, \"Only the first three selections contribute. Remove extra selections.\")\n const picks = requested.slice(0, CHARACTER_MOTION_MAX_PICKS)\n for (const id of picks) if (!getCharacterMotion(id)) add(\"unknown\", \"error\", [id], `Motion “${id}” is unavailable and contributes no fragment. Remove or replace it.`)\n const entries = picks.flatMap(id => { const entry = getCharacterMotion(id); return entry?.promptHint ? [entry] : [] })\n const active = entries.filter(e => !bindings.subjectMinor || !e.adultOnly)\n if (bindings.selfPairing && active.some(e => e.twoPerson || e.counterpart)) add(\"roles\", \"error\", active.filter(e => e.twoPerson || e.counterpart).map(e => e.id), \"The same reference is connected as Target and Partner. Connect distinct participants before running this interaction.\")\n const omitted = entries.filter(e => bindings.subjectMinor && e.adultOnly)\n if (omitted.length) add(\"omitted\", active.length ? \"warning\" : \"error\", omitted.map(e => e.id), `${omitted.map(e => e.label).join(\", \")} omitted for a connected minor. ${active.length ? \"Replace these selections.\" : \"No selected motion contributes a fragment.\"}`)\n if ((bindings.targetNames?.length ?? 0) > 1) add(\"multiple-targets\", \"warning\", picks, \"Each target performs a separate copy of the sequence. Use separate motion nodes for coordinated choreography.\")\n for (const entry of active) {\n if (entry.deprecated) add(\"retired\", \"warning\", [entry.id], `${entry.label} is retired from new choices but still resolves in saved workflows.${entry.replacementId ? ` Use ${getCharacterMotion(entry.replacementId)?.label ?? entry.replacementId}.` : \"\"}`)\n if (entry.fixedPace && timing?.pace && timing.pace !== \"auto\") add(\"pace\", \"warning\", [entry.id], `${entry.label} sets its own timing. Set Pace to Auto or replace the motion.`)\n if (entry.requires?.length) add(\"requirements\", \"info\", [entry.id], `${entry.label} requires: ${entry.requires.join(\", \")}.${entry.twoPerson || entry.counterpart ? bindings.partnerNames?.length ? ` Partner reference: ${bindings.partnerNames.join(\", \")}; confirm it matches the required recipient.` : \" Connect a Partner reference to identify the recipient; otherwise the model chooses it.\" : \" Establish these in the scene or prompt; the fragment does not supply reference media.\"}`)\n }\n for (let i = 1; i < active.length; i++) {\n const before = active[i - 1]!, after = active[i]!, ids = [before.id, after.id]\n if (before.endVisibility === \"out-of-frame\") add(\"visibility\", \"warning\", ids, `${before.label} ends out of view before ${after.label}. Reorder or add an entrance.`)\n if (before.endPose && after.startPose && before.endPose !== \"any\" && after.startPose !== \"any\" && before.endPose !== after.startPose) add(\"pose\", \"warning\", ids, `${before.label} ends ${before.endPose}; ${after.label} starts ${after.startPose}. Add a transition or replace a motion.`)\n if (before.handsAfter && before.handsAfter !== \"free\" && after.needsFreeHands) add(\"hands\", \"warning\", ids, `${before.label} leaves hands occupied; ${after.label} needs free hands. Add a release first.`)\n }\n const compound = active.filter(e => e.kind === \"compound\")\n if (compound.length) add(\"compound\", \"warning\", compound.map(e => e.id), `${compound.length} selection${compound.length === 1 ? \" is\" : \"s are\"} compound choreography. Short clips may not fit every phase; test the sequence before adding more actions.`)\n return result\n}\n"]}
1
+ {"version":3,"sources":["../src/wardrobe.ts","../src/character-motion-diagnostics.ts"],"names":["id","pickIds","h","CHARACTER_MOTION_MAX_PICKS","getCharacterMotion"],"mappings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,IAAI,MAAA,CAAO,OAAA,IAAW,KAAA,CAAM,SAAA,IAAa,MAAA,CAAO,OAAA,KAAY,KAAA,IAAS,KAAA,CAAM,SAAA,KAAc,KAAA,IAAS,MAAA,CAAO,OAAA,KAAY,MAAM,SAAA,EAAW,GAAA,CAAI,MAAA,EAAQ,SAAA,EAAW,GAAA,EAAK,CAAA,EAAG,MAAA,CAAO,KAAK,CAAA,MAAA,EAAS,MAAA,CAAO,OAAO,CAAA,EAAA,EAAK,KAAA,CAAM,KAAK,CAAA,QAAA,EAAW,KAAA,CAAM,SAAS,CAAA,uCAAA,CAAyC,CAAA;AAC3R,IAAA,IAAI,OAAO,UAAA,IAAc,MAAA,CAAO,UAAA,KAAe,MAAA,IAAU,MAAM,cAAA,EAAgB,GAAA,CAAI,OAAA,EAAS,SAAA,EAAW,KAAK,CAAA,EAAG,MAAA,CAAO,KAAK,CAAA,wBAAA,EAA2B,KAAA,CAAM,KAAK,CAAA,uCAAA,CAAyC,CAAA;AAAA,EAC5M;AACA,EAAA,MAAM,WAAW,MAAA,CAAO,MAAA,CAAO,CAAA,CAAA,KAAK,CAAA,CAAE,SAAS,UAAU,CAAA;AACzD,EAAA,IAAI,QAAA,CAAS,QAAQ,GAAA,CAAI,UAAA,EAAY,WAAW,QAAA,CAAS,GAAA,CAAI,OAAK,CAAA,CAAE,EAAE,GAAG,CAAA,EAAG,QAAA,CAAS,MAAM,CAAA,UAAA,EAAa,QAAA,CAAS,WAAW,CAAA,GAAI,KAAA,GAAQ,OAAO,CAAA,0GAAA,CAA4G,CAAA;AAC3P,EAAA,OAAO,MAAA;AACT","file":"chunk-OSKABA64.cjs","sourcesContent":["import { pickIds } from \"@nodaro/shared/catalogs\"\n\nexport type WardrobeDimension =\n | \"archetype\" | \"top\" | \"bottom\" | \"outerwear\" | \"footwear\"\n | \"headwear\" | \"accessories\" | \"color-palette\" | \"material\" | \"era\"\n\nexport interface WardrobeEntry {\n readonly id: string\n readonly label: string\n readonly dimension: WardrobeDimension\n readonly promptHint: string\n}\n\nexport interface WardrobeValue {\n archetype?: string\n top?: string\n bottom?: string\n outerwear?: string\n footwear?: string\n headwear?: string | ReadonlyArray<string>\n accessories?: string | ReadonlyArray<string>\n colorPalette?: string\n material?: string\n era?: string\n}\n\nexport const WARDROBE_DIMENSION_ORDER: ReadonlyArray<WardrobeDimension> = [\n \"archetype\", \"top\", \"bottom\", \"outerwear\", \"footwear\",\n \"headwear\", \"accessories\", \"color-palette\", \"material\", \"era\",\n]\n\nexport const WARDROBE_CATEGORY_LABELS: Readonly<Record<WardrobeDimension, string>> = {\n archetype: \"Archetype\", top: \"Top\", bottom: \"Bottom\", outerwear: \"Outerwear\",\n footwear: \"Footwear\", headwear: \"Headwear\", accessories: \"Accessories\",\n \"color-palette\": \"Color Palette\", material: \"Material\", era: \"Era\",\n}\n\nexport const WARDROBE_FIELD_BY_DIMENSION: Record<WardrobeDimension, keyof WardrobeValue> = {\n archetype: \"archetype\", top: \"top\", bottom: \"bottom\", outerwear: \"outerwear\",\n footwear: \"footwear\", headwear: \"headwear\", accessories: \"accessories\",\n \"color-palette\": \"colorPalette\", material: \"material\", era: \"era\",\n}\n\n/** Multi-pick dims emit each picked entry independently. */\nconst MULTI_PICK: ReadonlySet<WardrobeDimension> = new Set([\"headwear\", \"accessories\"])\n/** Sentinel ids that mean \"nothing here\" and emit no hint. */\nconst NONE_IDS: ReadonlySet<string> = new Set([\"wd-outer-none\"])\n\nexport const WARDROBE: ReadonlyArray<WardrobeEntry> = [\n // archetype\n { id: \"wd-casual\", label: \"Casual\", dimension: \"archetype\", promptHint: \"in casual everyday clothing\" },\n { id: \"wd-business\", label: \"Business\", dimension: \"archetype\", promptHint: \"in smart business attire\" },\n { id: \"wd-formal\", label: \"Formal\", dimension: \"archetype\", promptHint: \"in elegant formal wear\" },\n { id: \"wd-streetwear\", label: \"Streetwear\", dimension: \"archetype\", promptHint: \"in contemporary streetwear\" },\n { id: \"wd-athletic\", label: \"Athletic\", dimension: \"archetype\", promptHint: \"in athletic sportswear\" },\n { id: \"wd-fantasy\", label: \"Fantasy\", dimension: \"archetype\", promptHint: \"in fantasy costume\" },\n { id: \"wd-scifi\", label: \"Sci-Fi\", dimension: \"archetype\", promptHint: \"in futuristic sci-fi attire\" },\n { id: \"wd-historical\", label: \"Historical\", dimension: \"archetype\", promptHint: \"in period historical dress\" },\n { id: \"wd-uniform\", label: \"Uniform\", dimension: \"archetype\", promptHint: \"in a uniform\" },\n { id: \"wd-loungewear\", label: \"Loungewear\", dimension: \"archetype\", promptHint: \"in relaxed loungewear\" },\n // top\n { id: \"wd-tshirt\", label: \"T-Shirt\", dimension: \"top\", promptHint: \"wearing a t-shirt\" },\n { id: \"wd-blouse\", label: \"Blouse\", dimension: \"top\", promptHint: \"wearing a blouse\" },\n { id: \"wd-hoodie\", label: \"Hoodie\", dimension: \"top\", promptHint: \"wearing a hoodie\" },\n { id: \"wd-buttondown\", label: \"Button-down\", dimension: \"top\", promptHint: \"wearing a button-down shirt\" },\n { id: \"wd-tank\", label: \"Tank\", dimension: \"top\", promptHint: \"wearing a tank top\" },\n { id: \"wd-sweater\", label: \"Sweater\", dimension: \"top\", promptHint: \"wearing a sweater\" },\n { id: \"wd-turtleneck\", label: \"Turtleneck\", dimension: \"top\", promptHint: \"wearing a turtleneck\" },\n // bottom\n { id: \"wd-jeans\", label: \"Jeans\", dimension: \"bottom\", promptHint: \"wearing jeans\" },\n { id: \"wd-trousers\", label: \"Trousers\", dimension: \"bottom\", promptHint: \"wearing tailored trousers\" },\n { id: \"wd-skirt\", label: \"Skirt\", dimension: \"bottom\", promptHint: \"wearing a skirt\" },\n { id: \"wd-shorts\", label: \"Shorts\", dimension: \"bottom\", promptHint: \"wearing shorts\" },\n { id: \"wd-leggings\", label: \"Leggings\", dimension: \"bottom\", promptHint: \"wearing leggings\" },\n { id: \"wd-cargo\", label: \"Cargo\", dimension: \"bottom\", promptHint: \"wearing cargo pants\" },\n // outerwear\n { id: \"wd-outer-none\", label: \"None\", dimension: \"outerwear\", promptHint: \"\" },\n { id: \"wd-leatherjkt\", label: \"Leather Jacket\", dimension: \"outerwear\", promptHint: \"in a leather jacket\" },\n { id: \"wd-blazer\", label: \"Blazer\", dimension: \"outerwear\", promptHint: \"in a blazer\" },\n { id: \"wd-trench\", label: \"Trench Coat\", dimension: \"outerwear\", promptHint: \"in a trench coat\" },\n { id: \"wd-parka\", label: \"Parka\", dimension: \"outerwear\", promptHint: \"in a parka\" },\n { id: \"wd-cloak\", label: \"Cloak\", dimension: \"outerwear\", promptHint: \"in a flowing cloak\" },\n { id: \"wd-denimjkt\", label: \"Denim Jacket\", dimension: \"outerwear\", promptHint: \"in a denim jacket\" },\n { id: \"wd-cardigan\", label: \"Cardigan\", dimension: \"outerwear\", promptHint: \"in a cardigan\" },\n // footwear\n { id: \"wd-sneakers\", label: \"Sneakers\", dimension: \"footwear\", promptHint: \"wearing sneakers\" },\n { id: \"wd-boots\", label: \"Boots\", dimension: \"footwear\", promptHint: \"wearing boots\" },\n { id: \"wd-heels\", label: \"Heels\", dimension: \"footwear\", promptHint: \"wearing heels\" },\n { id: \"wd-sandals\", label: \"Sandals\", dimension: \"footwear\", promptHint: \"wearing sandals\" },\n { id: \"wd-dressshoe\", label: \"Dress Shoes\", dimension: \"footwear\", promptHint: \"wearing dress shoes\" },\n { id: \"wd-barefoot\", label: \"Barefoot\", dimension: \"footwear\", promptHint: \"barefoot\" },\n // headwear (multi)\n { id: \"wd-cap\", label: \"Cap\", dimension: \"headwear\", promptHint: \"wearing a cap\" },\n { id: \"wd-beanie\", label: \"Beanie\", dimension: \"headwear\", promptHint: \"wearing a beanie\" },\n { id: \"wd-widehat\", label: \"Wide-brim Hat\", dimension: \"headwear\", promptHint: \"wearing a wide-brim hat\" },\n { id: \"wd-hood\", label: \"Hood\", dimension: \"headwear\", promptHint: \"with the hood up\" },\n { id: \"wd-crown\", label: \"Crown\", dimension: \"headwear\", promptHint: \"wearing a crown\" },\n { id: \"wd-helmet\", label: \"Helmet\", dimension: \"headwear\", promptHint: \"wearing a helmet\" },\n // accessories (multi)\n { id: \"wd-glasses\", label: \"Glasses\", dimension: \"accessories\", promptHint: \"wearing glasses\" },\n { id: \"wd-sunglasses\", label: \"Sunglasses\", dimension: \"accessories\", promptHint: \"wearing sunglasses\" },\n { id: \"wd-scarf\", label: \"Scarf\", dimension: \"accessories\", promptHint: \"wearing a scarf\" },\n { id: \"wd-gloves\", label: \"Gloves\", dimension: \"accessories\", promptHint: \"wearing gloves\" },\n { id: \"wd-jewelry\", label: \"Jewelry\", dimension: \"accessories\", promptHint: \"wearing statement jewelry\" },\n { id: \"wd-belt\", label: \"Belt\", dimension: \"accessories\", promptHint: \"with a belt\" },\n { id: \"wd-watch\", label: \"Watch\", dimension: \"accessories\", promptHint: \"wearing a watch\" },\n // color-palette\n { id: \"wd-neutral\", label: \"Neutral\", dimension: \"color-palette\", promptHint: \"in a neutral color palette\" },\n { id: \"wd-all-black\", label: \"All Black\", dimension: \"color-palette\", promptHint: \"in an all-black palette\" },\n { id: \"wd-earth\", label: \"Earth Tones\", dimension: \"color-palette\", promptHint: \"in earth-tone colors\" },\n { id: \"wd-pastel\", label: \"Pastel\", dimension: \"color-palette\", promptHint: \"in pastel colors\" },\n { id: \"wd-jewel\", label: \"Jewel Tones\", dimension: \"color-palette\", promptHint: \"in rich jewel-tone colors\" },\n { id: \"wd-neon\", label: \"Neon\", dimension: \"color-palette\", promptHint: \"in vivid neon colors\" },\n { id: \"wd-all-white\", label: \"All White\", dimension: \"color-palette\", promptHint: \"in an all-white palette\" },\n // material\n { id: \"wd-cotton\", label: \"Cotton\", dimension: \"material\", promptHint: \"in cotton fabric\" },\n { id: \"wd-denim\", label: \"Denim\", dimension: \"material\", promptHint: \"in denim\" },\n { id: \"wd-leather\", label: \"Leather\", dimension: \"material\", promptHint: \"in leather\" },\n { id: \"wd-silk\", label: \"Silk\", dimension: \"material\", promptHint: \"in silk\" },\n { id: \"wd-wool\", label: \"Wool\", dimension: \"material\", promptHint: \"in wool\" },\n { id: \"wd-latex\", label: \"Latex\", dimension: \"material\", promptHint: \"in latex\" },\n { id: \"wd-linen\", label: \"Linen\", dimension: \"material\", promptHint: \"in linen\" },\n // era\n { id: \"wd-contemporary\", label: \"Contemporary\", dimension: \"era\", promptHint: \"in contemporary fashion\" },\n { id: \"wd-1920s\", label: \"1920s\", dimension: \"era\", promptHint: \"in 1920s fashion\" },\n { id: \"wd-1950s\", label: \"1950s\", dimension: \"era\", promptHint: \"in 1950s fashion\" },\n { id: \"wd-1980s\", label: \"1980s\", dimension: \"era\", promptHint: \"in 1980s fashion\" },\n { id: \"wd-victorian\", label: \"Victorian\", dimension: \"era\", promptHint: \"in Victorian-era dress\" },\n { id: \"wd-medieval\", label: \"Medieval\", dimension: \"era\", promptHint: \"in medieval dress\" },\n { id: \"wd-futuristic\", label: \"Futuristic\", dimension: \"era\", promptHint: \"in futuristic clothing\" },\n] as const\n\nconst BY_ID: Map<string, WardrobeEntry> = new Map(WARDROBE.map((e) => [e.id, e]))\n\n/** Entries grouped by dimension — precomputed once so per-dimension lookups\n * (the picker calls one per dimension per render) are O(1) with stable array\n * refs, instead of a full WARDROBE scan each call. */\nconst BY_DIMENSION: Map<WardrobeDimension, WardrobeEntry[]> = (() => {\n const map = new Map<WardrobeDimension, WardrobeEntry[]>()\n for (const e of WARDROBE) {\n const list = map.get(e.dimension)\n if (list) list.push(e)\n else map.set(e.dimension, [e])\n }\n return map\n})()\n\nexport function getWardrobeEntry(id: string | undefined | null): WardrobeEntry | undefined {\n return id ? BY_ID.get(id) : undefined\n}\n\nexport function getWardrobePromptHint(id: string | undefined | null): string {\n return getWardrobeEntry(id)?.promptHint ?? \"\"\n}\n\nexport function getWardrobeEntriesByDimension(dim: WardrobeDimension): WardrobeEntry[] {\n return BY_DIMENSION.get(dim) ?? []\n}\n\nexport function buildWardrobeHints(value: Record<string, unknown> & WardrobeValue): string[] {\n const hints: string[] = []\n for (const dimension of WARDROBE_DIMENSION_ORDER) {\n const field = WARDROBE_FIELD_BY_DIMENSION[dimension]\n const raw = value[field]\n if (MULTI_PICK.has(dimension)) {\n for (const id of pickIds(raw)) {\n if (NONE_IDS.has(id)) continue\n const h = getWardrobePromptHint(id)\n if (h) hints.push(h)\n }\n continue\n }\n const id = typeof raw === \"string\" ? raw : undefined\n if (!id || NONE_IDS.has(id)) continue\n const h = getWardrobePromptHint(id)\n if (h) hints.push(h)\n }\n return hints\n}\n","import { getCharacterMotion, CHARACTER_MOTION_MAX_PICKS, type CharacterMotionTiming } from \"./character-motion.js\"\n\nexport interface CharacterMotionDiagnostic {\n readonly code: \"unknown\" | \"omitted\" | \"retired\" | \"pose\" | \"visibility\" | \"hands\" | \"pace\" | \"requirements\" | \"compound\" | \"capacity\" | \"multiple-targets\" | \"roles\"\n readonly severity: \"error\" | \"warning\" | \"info\"\n readonly ids: readonly string[]\n readonly message: string\n}\nexport interface CharacterMotionBindings {\n readonly selfPairing?: boolean\n readonly subjectMinor?: boolean\n readonly partnerNames?: readonly string[]\n readonly targetNames?: readonly string[]\n}\n\n/** Shared by editor, API clients and local review. Missing metadata means\n * unknown; this never certifies a sequence or predicts clip duration. */\nexport function getCharacterMotionDiagnostics(\n value: string | readonly string[] | null | undefined,\n timing?: CharacterMotionTiming,\n bindings: CharacterMotionBindings = {},\n): readonly CharacterMotionDiagnostic[] {\n const requested = typeof value === \"string\" ? [value] : Array.isArray(value) ? [...new Set(value)] : []\n const result: CharacterMotionDiagnostic[] = []\n const add = (code: CharacterMotionDiagnostic[\"code\"], severity: CharacterMotionDiagnostic[\"severity\"], ids: readonly string[], message: string) => result.push({ code, severity, ids, message })\n if (requested.length > CHARACTER_MOTION_MAX_PICKS) add(\"capacity\", \"warning\", requested, \"Only the first three selections contribute. Remove extra selections.\")\n const picks = requested.slice(0, CHARACTER_MOTION_MAX_PICKS)\n for (const id of picks) if (!getCharacterMotion(id)) add(\"unknown\", \"error\", [id], `Motion “${id}” is unavailable and contributes no fragment. Remove or replace it.`)\n const entries = picks.flatMap(id => { const entry = getCharacterMotion(id); return entry?.promptHint ? [entry] : [] })\n const active = entries.filter(e => !bindings.subjectMinor || !e.adultOnly)\n if (bindings.selfPairing && active.some(e => e.twoPerson || e.counterpart)) add(\"roles\", \"error\", active.filter(e => e.twoPerson || e.counterpart).map(e => e.id), \"The same reference is connected as Target and Partner. Connect distinct participants before running this interaction.\")\n const omitted = entries.filter(e => bindings.subjectMinor && e.adultOnly)\n if (omitted.length) add(\"omitted\", active.length ? \"warning\" : \"error\", omitted.map(e => e.id), `${omitted.map(e => e.label).join(\", \")} omitted for a connected minor. ${active.length ? \"Replace these selections.\" : \"No selected motion contributes a fragment.\"}`)\n if ((bindings.targetNames?.length ?? 0) > 1) add(\"multiple-targets\", \"warning\", picks, \"Each target performs a separate copy of the sequence. Use separate motion nodes for coordinated choreography.\")\n for (const entry of active) {\n if (entry.deprecated) add(\"retired\", \"warning\", [entry.id], `${entry.label} is retired from new choices but still resolves in saved workflows.${entry.replacementId ? ` Use ${getCharacterMotion(entry.replacementId)?.label ?? entry.replacementId}.` : \"\"}`)\n if (entry.fixedPace && timing?.pace && timing.pace !== \"auto\") add(\"pace\", \"warning\", [entry.id], `${entry.label} sets its own timing. Set Pace to Auto or replace the motion.`)\n if (entry.requires?.length) add(\"requirements\", \"info\", [entry.id], `${entry.label} requires: ${entry.requires.join(\", \")}.${entry.twoPerson || entry.counterpart ? bindings.partnerNames?.length ? ` Partner reference: ${bindings.partnerNames.join(\", \")}; confirm it matches the required recipient.` : \" Connect a Partner reference to identify the recipient; otherwise the model chooses it.\" : \" Establish these in the scene or prompt; the fragment does not supply reference media.\"}`)\n }\n for (let i = 1; i < active.length; i++) {\n const before = active[i - 1]!, after = active[i]!, ids = [before.id, after.id]\n if (before.endVisibility === \"out-of-frame\") add(\"visibility\", \"warning\", ids, `${before.label} ends out of view before ${after.label}. Reorder or add an entrance.`)\n if (before.endPose && after.startPose && before.endPose !== \"any\" && after.startPose !== \"any\" && before.endPose !== after.startPose) add(\"pose\", \"warning\", ids, `${before.label} ends ${before.endPose}; ${after.label} starts ${after.startPose}. Add a transition or replace a motion.`)\n if (before.handsAfter && before.handsAfter !== \"free\" && after.needsFreeHands) add(\"hands\", \"warning\", ids, `${before.label} leaves hands occupied; ${after.label} needs free hands. Add a release first.`)\n }\n const compound = active.filter(e => e.kind === \"compound\")\n if (compound.length) add(\"compound\", \"warning\", compound.map(e => e.id), `${compound.length} selection${compound.length === 1 ? \" is\" : \"s are\"} compound choreography. Short clips may not fit every phase; test the sequence before adding more actions.`)\n return result\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var chunkJDNHMVEV_cjs = require('./chunk-JDNHMVEV.cjs');
4
- var chunkSB7AYE6S_cjs = require('./chunk-SB7AYE6S.cjs');
3
+ var chunkFCTK7RGO_cjs = require('./chunk-FCTK7RGO.cjs');
4
+ var chunkJHEZJKTX_cjs = require('./chunk-JHEZJKTX.cjs');
5
5
  var chunk3UEA3UHQ_cjs = require('./chunk-3UEA3UHQ.cjs');
6
6
  var chunkK6NT635Z_cjs = require('./chunk-K6NT635Z.cjs');
7
7
  var chunkFY4AMIDB_cjs = require('./chunk-FY4AMIDB.cjs');
@@ -14,7 +14,7 @@ function optionsOf(catalog) {
14
14
  return (catalog.dimensions ?? []).flatMap((d) => d.options);
15
15
  }
16
16
  function getAdultOnlyEntries() {
17
- const catalogEntries = chunkSB7AYE6S_cjs.getRegisteredPickerCatalogs().filter((c) => ADULT_SWEPT_CATALOG_ID_SET.has(c.catalogId)).flatMap(optionsOf);
17
+ const catalogEntries = chunkJHEZJKTX_cjs.getRegisteredPickerCatalogs().filter((c) => ADULT_SWEPT_CATALOG_ID_SET.has(c.catalogId)).flatMap(optionsOf);
18
18
  const all = [...chunkK6NT635Z_cjs.getRegisteredPeople(), ...catalogEntries];
19
19
  return all.filter((e) => e.adultOnly === true);
20
20
  }
@@ -221,7 +221,7 @@ function resolveParameterHint(node, ctx, inherited) {
221
221
  const mode = readHintMode(data) ?? inherited ?? "full";
222
222
  if (node.type === "camera-motion") {
223
223
  const motionId = asStr(data.cameraMotion) || void 0;
224
- if (!ctx) return withCustomText(data, chunkSB7AYE6S_cjs.composeCameraMotionHintFromConnections(motionId, [], [], mode));
224
+ if (!ctx) return withCustomText(data, chunkJHEZJKTX_cjs.composeCameraMotionHintFromConnections(motionId, [], [], mode));
225
225
  const startHints = [];
226
226
  const endHints = [];
227
227
  for (const edge of ctx.edges) {
@@ -233,7 +233,7 @@ function resolveParameterHint(node, ctx, inherited) {
233
233
  if (edge.targetHandle === "startState") startHints.push(hint);
234
234
  else if (edge.targetHandle === "endState") endHints.push(hint);
235
235
  }
236
- return withCustomText(data, chunkSB7AYE6S_cjs.composeCameraMotionHintFromConnections(motionId, startHints, endHints, mode));
236
+ return withCustomText(data, chunkJHEZJKTX_cjs.composeCameraMotionHintFromConnections(motionId, startHints, endHints, mode));
237
237
  }
238
238
  if (node.type === "transition") {
239
239
  const raw = data.transition;
@@ -243,10 +243,10 @@ function resolveParameterHint(node, ctx, inherited) {
243
243
  duration: asStr(data.duration),
244
244
  intensity: asStr(data.intensity)
245
245
  };
246
- const optionValues = chunkSB7AYE6S_cjs.readTransitionOptionValues(data);
246
+ const optionValues = chunkJHEZJKTX_cjs.readTransitionOptionValues(data);
247
247
  const hintOptions = optionValues ? { optionValues } : void 0;
248
248
  if (!ctx) {
249
- return withCustomText(data, chunkSB7AYE6S_cjs.composeTransitionHintFromConnections(transitionId, [], [], timing, mode, hintOptions));
249
+ return withCustomText(data, chunkJHEZJKTX_cjs.composeTransitionHintFromConnections(transitionId, [], [], timing, mode, hintOptions));
250
250
  }
251
251
  const startHints = [];
252
252
  const endHints = [];
@@ -259,7 +259,7 @@ function resolveParameterHint(node, ctx, inherited) {
259
259
  if (edge.targetHandle === "startState") startHints.push(hint);
260
260
  else if (edge.targetHandle === "endState") endHints.push(hint);
261
261
  }
262
- return withCustomText(data, chunkSB7AYE6S_cjs.composeTransitionHintFromConnections(transitionId, startHints, endHints, timing, mode, hintOptions));
262
+ return withCustomText(data, chunkJHEZJKTX_cjs.composeTransitionHintFromConnections(transitionId, startHints, endHints, timing, mode, hintOptions));
263
263
  }
264
264
  if (node.type === "character-fx") {
265
265
  const raw = data.characterFx;
@@ -270,7 +270,7 @@ function resolveParameterHint(node, ctx, inherited) {
270
270
  intensity: asStr(data.intensity)
271
271
  };
272
272
  if (!ctx) {
273
- return withCustomText(data, chunkSB7AYE6S_cjs.composeCharacterFxHintFromConnections(effectId, [], timing, mode));
273
+ return withCustomText(data, chunkJHEZJKTX_cjs.composeCharacterFxHintFromConnections(effectId, [], timing, mode));
274
274
  }
275
275
  const targetNames = [];
276
276
  for (const edge of ctx.edges) {
@@ -281,7 +281,7 @@ function resolveParameterHint(node, ctx, inherited) {
281
281
  const name = extractCharacterRefName(src);
282
282
  if (name) targetNames.push(name);
283
283
  }
284
- return withCustomText(data, chunkSB7AYE6S_cjs.composeCharacterFxHintFromConnections(effectId, targetNames, timing, mode));
284
+ return withCustomText(data, chunkJHEZJKTX_cjs.composeCharacterFxHintFromConnections(effectId, targetNames, timing, mode));
285
285
  }
286
286
  if (node.type === "character-motion") {
287
287
  const raw = data.characterMotion;
@@ -291,17 +291,17 @@ function resolveParameterHint(node, ctx, inherited) {
291
291
  pace: asStr(data.pace)
292
292
  };
293
293
  if (!ctx) {
294
- return withCustomText(data, chunkSB7AYE6S_cjs.composeCharacterMotionHintFromConnections(motionId, [], [], timing, mode));
294
+ return withCustomText(data, chunkJHEZJKTX_cjs.composeCharacterMotionHintFromConnections(motionId, [], [], timing, mode));
295
295
  }
296
296
  const { targetNames, partnerNames, subjectMinor } = getCharacterMotionBindings(node, ctx);
297
297
  return withCustomText(
298
298
  data,
299
- chunkSB7AYE6S_cjs.composeCharacterMotionHintFromConnections(motionId, targetNames, partnerNames, timing, mode, { subjectMinor })
299
+ chunkJHEZJKTX_cjs.composeCharacterMotionHintFromConnections(motionId, targetNames, partnerNames, timing, mode, { subjectMinor })
300
300
  );
301
301
  }
302
302
  const base = resolveBaseHint(node.type, data, mode);
303
303
  if (base) return base;
304
- const cat = chunkSB7AYE6S_cjs.getPickerCatalog(node.type);
304
+ const cat = chunkJHEZJKTX_cjs.getPickerCatalog(node.type);
305
305
  if (cat?.kind === "single" && cat.valueField) {
306
306
  const id = typeof data[cat.valueField] === "string" ? data[cat.valueField] : "";
307
307
  const opt = cat.options?.find((o) => o.id === id);
@@ -312,88 +312,88 @@ function resolveParameterHint(node, ctx, inherited) {
312
312
  function resolveBaseHint(type, data, mode = "full") {
313
313
  switch (type) {
314
314
  case "framing":
315
- return withCustomText(data, chunkSB7AYE6S_cjs.buildFramingHints(data, false, mode).join(", "));
315
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildFramingHints(data, false, mode).join(", "));
316
316
  case "lighting":
317
- return withCustomText(data, chunkSB7AYE6S_cjs.buildLightingHints(data, mode).join(", "));
317
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildLightingHints(data, mode).join(", "));
318
318
  case "lens":
319
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getLensPromptHint, chunkSB7AYE6S_cjs.getLensTerm)(asStr(data.lens)));
319
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getLensPromptHint, chunkJHEZJKTX_cjs.getLensTerm)(asStr(data.lens)));
320
320
  case "camera-format":
321
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getCameraFormatPromptHint, chunkSB7AYE6S_cjs.getCameraFormatTerm)(asStr(data.cameraFormat)));
321
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getCameraFormatPromptHint, chunkJHEZJKTX_cjs.getCameraFormatTerm)(asStr(data.cameraFormat)));
322
322
  case "color-look":
323
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getColorLookPromptHint, chunkSB7AYE6S_cjs.getColorLookTerm)(asStr(data.colorLook)));
323
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getColorLookPromptHint, chunkJHEZJKTX_cjs.getColorLookTerm)(asStr(data.colorLook)));
324
324
  // build*Hints in music-* / voice-* / mood / person / etc. compose
325
325
  // preText/postText internally — bypass the wrapper to avoid double-
326
326
  // composition.
327
327
  case "music-genre":
328
- return chunkSB7AYE6S_cjs.buildMusicGenreHints(data ?? {}, mode);
328
+ return chunkJHEZJKTX_cjs.buildMusicGenreHints(data ?? {}, mode);
329
329
  case "music-mood":
330
- return chunkSB7AYE6S_cjs.buildMusicMoodHints(data ?? {}, mode);
330
+ return chunkJHEZJKTX_cjs.buildMusicMoodHints(data ?? {}, mode);
331
331
  case "instrumentation":
332
- return chunkSB7AYE6S_cjs.buildInstrumentationHints(data ?? {}, mode);
332
+ return chunkJHEZJKTX_cjs.buildInstrumentationHints(data ?? {}, mode);
333
333
  case "voice-character":
334
- return chunkSB7AYE6S_cjs.buildVoiceCharacterHints(data ?? {}, mode);
334
+ return chunkJHEZJKTX_cjs.buildVoiceCharacterHints(data ?? {}, mode);
335
335
  case "voice-delivery":
336
- return chunkSB7AYE6S_cjs.buildVoiceDeliveryHints(data ?? {}, mode);
336
+ return chunkJHEZJKTX_cjs.buildVoiceDeliveryHints(data ?? {}, mode);
337
337
  case "person":
338
338
  return chunkK6NT635Z_cjs.buildPersonHints(data, mode).join(", ");
339
339
  case "mood":
340
- return chunkSB7AYE6S_cjs.buildMoodHints(data, mode).join(", ");
340
+ return chunkJHEZJKTX_cjs.buildMoodHints(data, mode).join(", ");
341
341
  case "pose":
342
- return chunkSB7AYE6S_cjs.buildPoseHints(data, mode).join(", ");
342
+ return chunkJHEZJKTX_cjs.buildPoseHints(data, mode).join(", ");
343
343
  case "styling":
344
- return chunkSB7AYE6S_cjs.buildStylingHints(data, mode).join(", ");
344
+ return chunkJHEZJKTX_cjs.buildStylingHints(data, mode).join(", ");
345
345
  case "atmosphere":
346
- return withCustomText(data, chunkSB7AYE6S_cjs.buildAtmosphereHints(data.atmosphere, mode).join(", "));
346
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildAtmosphereHints(data.atmosphere, mode).join(", "));
347
347
  case "action-fx":
348
- return withCustomText(data, chunkSB7AYE6S_cjs.buildActionFxHints(data.actionFx, mode).join(", "));
348
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildActionFxHints(data.actionFx, mode).join(", "));
349
349
  case "style":
350
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getStylePromptHint, chunkSB7AYE6S_cjs.getStyleTerm)(asStr(data.style)));
350
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getStylePromptHint, chunkJHEZJKTX_cjs.getStyleTerm)(asStr(data.style)));
351
351
  case "setting":
352
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getSettingPromptHint, chunkSB7AYE6S_cjs.getSettingTerm)(asStr(data.setting)));
352
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getSettingPromptHint, chunkJHEZJKTX_cjs.getSettingTerm)(asStr(data.setting)));
353
353
  case "loop-subject":
354
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getLoopSubjectPromptHint, chunkSB7AYE6S_cjs.getLoopSubjectTerm)(asStr(data.loopSubject)));
354
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getLoopSubjectPromptHint, chunkJHEZJKTX_cjs.getLoopSubjectTerm)(asStr(data.loopSubject)));
355
355
  case "material":
356
- return withCustomText(data, chunkSB7AYE6S_cjs.buildMaterialHints(data.material, mode));
356
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildMaterialHints(data.material, mode));
357
357
  // The four object-entity catalogs are owned by @nodaro/shared and overlaid
358
358
  // in shared-catalog-overlay.ts — the ONE module every prompt-text read of
359
359
  // them goes through (the subject fold uses it too). Each returns "" on a
360
360
  // miss, so the entry lookup is the module's job, not this switch's.
361
361
  case "animal":
362
- return withCustomText(data, byMode(mode, chunkJDNHMVEV_cjs.curatedAnimalPromptHint, chunkJDNHMVEV_cjs.curatedAnimalTerm)(asStr(data.animal)));
362
+ return withCustomText(data, byMode(mode, chunkFCTK7RGO_cjs.curatedAnimalPromptHint, chunkFCTK7RGO_cjs.curatedAnimalTerm)(asStr(data.animal)));
363
363
  case "vehicle": {
364
- const t = chunkJDNHMVEV_cjs.curatedVehicleText(asStr(data.vehicle));
364
+ const t = chunkFCTK7RGO_cjs.curatedVehicleText(asStr(data.vehicle));
365
365
  return withCustomText(data, byMode(mode, t.hint, t.term));
366
366
  }
367
367
  case "weapon": {
368
- const t = chunkJDNHMVEV_cjs.curatedWeaponText(asStr(data.weapon));
368
+ const t = chunkFCTK7RGO_cjs.curatedWeaponText(asStr(data.weapon));
369
369
  return withCustomText(data, byMode(mode, t.hint, t.term));
370
370
  }
371
371
  case "furniture": {
372
- const t = chunkJDNHMVEV_cjs.curatedFurnitureText(asStr(data.furniture));
372
+ const t = chunkFCTK7RGO_cjs.curatedFurnitureText(asStr(data.furniture));
373
373
  return withCustomText(data, byMode(mode, t.hint, t.term));
374
374
  }
375
375
  case "photo-genre":
376
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getPhotoGenrePromptHint, chunkSB7AYE6S_cjs.getPhotoGenreTerm)(asStr(data.photoGenre)));
376
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getPhotoGenrePromptHint, chunkJHEZJKTX_cjs.getPhotoGenreTerm)(asStr(data.photoGenre)));
377
377
  case "backdrop":
378
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getBackdropPromptHint, chunkSB7AYE6S_cjs.getBackdropTerm)(asStr(data.backdrop)));
378
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getBackdropPromptHint, chunkJHEZJKTX_cjs.getBackdropTerm)(asStr(data.backdrop)));
379
379
  case "held-prop":
380
- return withCustomText(data, chunkSB7AYE6S_cjs.buildHeldPropHints(data.heldProp, mode).join(", "));
380
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildHeldPropHints(data.heldProp, mode).join(", "));
381
381
  case "photographer":
382
- return withCustomText(data, chunkSB7AYE6S_cjs.buildPhotographerHints(data.photographer, mode));
382
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildPhotographerHints(data.photographer, mode));
383
383
  case "aesthetic":
384
- return withCustomText(data, chunkSB7AYE6S_cjs.buildAestheticHints(data.aesthetic, mode));
384
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildAestheticHints(data.aesthetic, mode));
385
385
  case "era":
386
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getEraPromptHint, chunkSB7AYE6S_cjs.getEraTerm)(asStr(data.era)));
386
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getEraPromptHint, chunkJHEZJKTX_cjs.getEraTerm)(asStr(data.era)));
387
387
  case "temporal":
388
- return withCustomText(data, chunkSB7AYE6S_cjs.buildTemporalHints(data, mode).join(", "));
388
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildTemporalHints(data, mode).join(", "));
389
389
  case "exposure-settings":
390
- return withCustomText(data, chunkSB7AYE6S_cjs.buildExposureHints(data, mode).join(", "));
390
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildExposureHints(data, mode).join(", "));
391
391
  case "render-quality":
392
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getRenderQualityPromptHint, chunkSB7AYE6S_cjs.getRenderQualityTerm)(asStr(data.renderQuality)));
392
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getRenderQualityPromptHint, chunkJHEZJKTX_cjs.getRenderQualityTerm)(asStr(data.renderQuality)));
393
393
  case "composition-effects":
394
- return withCustomText(data, byMode(mode, chunkSB7AYE6S_cjs.getCompositionEffectPromptHint, chunkSB7AYE6S_cjs.getCompositionEffectTerm)(asStr(data.compositionEffect)));
394
+ return withCustomText(data, byMode(mode, chunkJHEZJKTX_cjs.getCompositionEffectPromptHint, chunkJHEZJKTX_cjs.getCompositionEffectTerm)(asStr(data.compositionEffect)));
395
395
  case "post-process-effects":
396
- return withCustomText(data, chunkSB7AYE6S_cjs.buildPostProcessHints(data.postProcess, mode).join(", "));
396
+ return withCustomText(data, chunkJHEZJKTX_cjs.buildPostProcessHints(data.postProcess, mode).join(", "));
397
397
  // Motion intensity: a Generation Settings node that a video node's
398
398
  // Settings input takes as a prompt fragment (video only).
399
399
  case "motion": {
@@ -425,5 +425,5 @@ exports.getAdultOnlyIds = getAdultOnlyIds;
425
425
  exports.getCharacterMotionBindings = getCharacterMotionBindings;
426
426
  exports.getMinorAgeHintStrings = getMinorAgeHintStrings;
427
427
  exports.getParameterPromptHint = getParameterPromptHint;
428
- //# sourceMappingURL=chunk-AXQK7UH7.cjs.map
429
- //# sourceMappingURL=chunk-AXQK7UH7.cjs.map
428
+ //# sourceMappingURL=chunk-OY7XOPDG.cjs.map
429
+ //# sourceMappingURL=chunk-OY7XOPDG.cjs.map