@project-ava-supernova/core 0.2.177 → 0.2.179

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 (189) hide show
  1. package/dist/agent/agent.d.ts.map +1 -1
  2. package/dist/agent/agent.js +12 -4
  3. package/dist/agent/agent.js.map +1 -1
  4. package/dist/agent/social-craft.d.ts +30 -67
  5. package/dist/agent/social-craft.d.ts.map +1 -1
  6. package/dist/agent/social-craft.js +58 -185
  7. package/dist/agent/social-craft.js.map +1 -1
  8. package/dist/agent/system-prompt.d.ts +8 -2
  9. package/dist/agent/system-prompt.d.ts.map +1 -1
  10. package/dist/agent/system-prompt.js +1172 -1357
  11. package/dist/agent/system-prompt.js.map +1 -1
  12. package/dist/brand/kit-py.d.ts.map +1 -1
  13. package/dist/brand/kit-py.js +4 -0
  14. package/dist/brand/kit-py.js.map +1 -1
  15. package/dist/config/personality.js +1 -1
  16. package/dist/creative/folder-export.d.ts +79 -0
  17. package/dist/creative/folder-export.d.ts.map +1 -0
  18. package/dist/creative/folder-export.js +470 -0
  19. package/dist/creative/folder-export.js.map +1 -0
  20. package/dist/creative/library-folders.d.ts +171 -0
  21. package/dist/creative/library-folders.d.ts.map +1 -0
  22. package/dist/creative/library-folders.js +515 -0
  23. package/dist/creative/library-folders.js.map +1 -0
  24. package/dist/creative/library-upload.d.ts +24 -0
  25. package/dist/creative/library-upload.d.ts.map +1 -0
  26. package/dist/creative/library-upload.js +223 -0
  27. package/dist/creative/library-upload.js.map +1 -0
  28. package/dist/creative/making-report.d.ts +46 -0
  29. package/dist/creative/making-report.d.ts.map +1 -0
  30. package/dist/creative/making-report.js +244 -0
  31. package/dist/creative/making-report.js.map +1 -0
  32. package/dist/creative/pack-plan-status.d.ts +18 -0
  33. package/dist/creative/pack-plan-status.d.ts.map +1 -0
  34. package/dist/creative/pack-plan-status.js +58 -0
  35. package/dist/creative/pack-plan-status.js.map +1 -0
  36. package/dist/creative/project-copy.d.ts +49 -0
  37. package/dist/creative/project-copy.d.ts.map +1 -0
  38. package/dist/creative/project-copy.js +149 -0
  39. package/dist/creative/project-copy.js.map +1 -0
  40. package/dist/creative/store-profiles.d.ts +55 -0
  41. package/dist/creative/store-profiles.d.ts.map +1 -0
  42. package/dist/creative/store-profiles.js +530 -0
  43. package/dist/creative/store-profiles.js.map +1 -0
  44. package/dist/docs/content/features.d.ts.map +1 -1
  45. package/dist/docs/content/features.js +20 -13
  46. package/dist/docs/content/features.js.map +1 -1
  47. package/dist/docs/content/troubleshooting.d.ts.map +1 -1
  48. package/dist/docs/content/troubleshooting.js +9 -0
  49. package/dist/docs/content/troubleshooting.js.map +1 -1
  50. package/dist/docs/data/tools.d.ts.map +1 -1
  51. package/dist/docs/data/tools.js +2 -0
  52. package/dist/docs/data/tools.js.map +1 -1
  53. package/dist/docs/i18n/translations.d.ts.map +1 -1
  54. package/dist/docs/i18n/translations.js +1 -1
  55. package/dist/docs/i18n/translations.js.map +1 -1
  56. package/dist/i18n/locales/ar.d.ts.map +1 -1
  57. package/dist/i18n/locales/ar.js +281 -0
  58. package/dist/i18n/locales/ar.js.map +1 -1
  59. package/dist/i18n/locales/de.d.ts.map +1 -1
  60. package/dist/i18n/locales/de.js +281 -0
  61. package/dist/i18n/locales/de.js.map +1 -1
  62. package/dist/i18n/locales/en.d.ts +281 -0
  63. package/dist/i18n/locales/en.d.ts.map +1 -1
  64. package/dist/i18n/locales/en.js +282 -0
  65. package/dist/i18n/locales/en.js.map +1 -1
  66. package/dist/i18n/locales/es.d.ts.map +1 -1
  67. package/dist/i18n/locales/es.js +281 -0
  68. package/dist/i18n/locales/es.js.map +1 -1
  69. package/dist/i18n/locales/fr.d.ts.map +1 -1
  70. package/dist/i18n/locales/fr.js +281 -0
  71. package/dist/i18n/locales/fr.js.map +1 -1
  72. package/dist/i18n/locales/hi.d.ts.map +1 -1
  73. package/dist/i18n/locales/hi.js +281 -0
  74. package/dist/i18n/locales/hi.js.map +1 -1
  75. package/dist/i18n/locales/id.d.ts.map +1 -1
  76. package/dist/i18n/locales/id.js +281 -0
  77. package/dist/i18n/locales/id.js.map +1 -1
  78. package/dist/i18n/locales/it.d.ts.map +1 -1
  79. package/dist/i18n/locales/it.js +281 -0
  80. package/dist/i18n/locales/it.js.map +1 -1
  81. package/dist/i18n/locales/ja.d.ts.map +1 -1
  82. package/dist/i18n/locales/ja.js +281 -0
  83. package/dist/i18n/locales/ja.js.map +1 -1
  84. package/dist/i18n/locales/ko.d.ts.map +1 -1
  85. package/dist/i18n/locales/ko.js +281 -0
  86. package/dist/i18n/locales/ko.js.map +1 -1
  87. package/dist/i18n/locales/nl.d.ts.map +1 -1
  88. package/dist/i18n/locales/nl.js +281 -0
  89. package/dist/i18n/locales/nl.js.map +1 -1
  90. package/dist/i18n/locales/pl.d.ts.map +1 -1
  91. package/dist/i18n/locales/pl.js +281 -0
  92. package/dist/i18n/locales/pl.js.map +1 -1
  93. package/dist/i18n/locales/pt.d.ts.map +1 -1
  94. package/dist/i18n/locales/pt.js +281 -0
  95. package/dist/i18n/locales/pt.js.map +1 -1
  96. package/dist/i18n/locales/ru.d.ts.map +1 -1
  97. package/dist/i18n/locales/ru.js +281 -0
  98. package/dist/i18n/locales/ru.js.map +1 -1
  99. package/dist/i18n/locales/th.d.ts.map +1 -1
  100. package/dist/i18n/locales/th.js +281 -0
  101. package/dist/i18n/locales/th.js.map +1 -1
  102. package/dist/i18n/locales/tr.d.ts.map +1 -1
  103. package/dist/i18n/locales/tr.js +281 -0
  104. package/dist/i18n/locales/tr.js.map +1 -1
  105. package/dist/i18n/locales/uk.d.ts.map +1 -1
  106. package/dist/i18n/locales/uk.js +281 -0
  107. package/dist/i18n/locales/uk.js.map +1 -1
  108. package/dist/i18n/locales/vi.d.ts.map +1 -1
  109. package/dist/i18n/locales/vi.js +281 -0
  110. package/dist/i18n/locales/vi.js.map +1 -1
  111. package/dist/i18n/locales/zh-CN.d.ts.map +1 -1
  112. package/dist/i18n/locales/zh-CN.js +281 -0
  113. package/dist/i18n/locales/zh-CN.js.map +1 -1
  114. package/dist/i18n/locales/zh-TW.d.ts.map +1 -1
  115. package/dist/i18n/locales/zh-TW.js +281 -0
  116. package/dist/i18n/locales/zh-TW.js.map +1 -1
  117. package/dist/index.d.ts +18 -0
  118. package/dist/index.d.ts.map +1 -1
  119. package/dist/index.js +10 -0
  120. package/dist/index.js.map +1 -1
  121. package/dist/portability/bundle.d.ts.map +1 -1
  122. package/dist/portability/bundle.js +1 -0
  123. package/dist/portability/bundle.js.map +1 -1
  124. package/dist/portability/factory-reset.js +1 -1
  125. package/dist/portability/factory-reset.js.map +1 -1
  126. package/dist/social/index.d.ts +9 -0
  127. package/dist/social/index.d.ts.map +1 -1
  128. package/dist/social/index.js +35 -5
  129. package/dist/social/index.js.map +1 -1
  130. package/dist/social/tag-volume.d.ts +7 -0
  131. package/dist/social/tag-volume.d.ts.map +1 -1
  132. package/dist/social/tag-volume.js +27 -0
  133. package/dist/social/tag-volume.js.map +1 -1
  134. package/dist/tools/blender/build-model.d.ts +11 -1
  135. package/dist/tools/blender/build-model.d.ts.map +1 -1
  136. package/dist/tools/blender/build-model.js +79 -4
  137. package/dist/tools/blender/build-model.js.map +1 -1
  138. package/dist/tools/blender/model-brief.d.ts +5 -2
  139. package/dist/tools/blender/model-brief.d.ts.map +1 -1
  140. package/dist/tools/blender/model-brief.js +5 -5
  141. package/dist/tools/blender/model-brief.js.map +1 -1
  142. package/dist/tools/blender/model-history.d.ts +42 -0
  143. package/dist/tools/blender/model-history.d.ts.map +1 -0
  144. package/dist/tools/blender/model-history.js +145 -0
  145. package/dist/tools/blender/model-history.js.map +1 -0
  146. package/dist/tools/blender/runner-py.d.ts.map +1 -1
  147. package/dist/tools/blender/runner-py.js +13 -0
  148. package/dist/tools/blender/runner-py.js.map +1 -1
  149. package/dist/tools/brief-store.d.ts +4 -1
  150. package/dist/tools/brief-store.d.ts.map +1 -1
  151. package/dist/tools/brief-store.js +22 -5
  152. package/dist/tools/brief-store.js.map +1 -1
  153. package/dist/tools/design-folder.d.ts +24 -0
  154. package/dist/tools/design-folder.d.ts.map +1 -0
  155. package/dist/tools/design-folder.js +277 -0
  156. package/dist/tools/design-folder.js.map +1 -0
  157. package/dist/tools/design-fonts.d.ts +6 -2
  158. package/dist/tools/design-fonts.d.ts.map +1 -1
  159. package/dist/tools/design-fonts.js +6 -2
  160. package/dist/tools/design-fonts.js.map +1 -1
  161. package/dist/tools/design-studio-tools.d.ts +1 -1
  162. package/dist/tools/design-studio-tools.d.ts.map +1 -1
  163. package/dist/tools/design-studio-tools.js +5 -3
  164. package/dist/tools/design-studio-tools.js.map +1 -1
  165. package/dist/tools/gimp/build-image.d.ts +15 -6
  166. package/dist/tools/gimp/build-image.d.ts.map +1 -1
  167. package/dist/tools/gimp/build-image.js +105 -14
  168. package/dist/tools/gimp/build-image.js.map +1 -1
  169. package/dist/tools/gimp/runner-py.d.ts.map +1 -1
  170. package/dist/tools/gimp/runner-py.js +27 -0
  171. package/dist/tools/gimp/runner-py.js.map +1 -1
  172. package/dist/tools/making-record.d.ts +80 -0
  173. package/dist/tools/making-record.d.ts.map +1 -0
  174. package/dist/tools/making-record.js +221 -0
  175. package/dist/tools/making-record.js.map +1 -0
  176. package/dist/tools/research-post.d.ts +1 -1
  177. package/dist/tools/research-post.d.ts.map +1 -1
  178. package/dist/tools/research-post.js +20 -9
  179. package/dist/tools/research-post.js.map +1 -1
  180. package/dist/tools/tool-registry.d.ts.map +1 -1
  181. package/dist/tools/tool-registry.js +9 -1
  182. package/dist/tools/tool-registry.js.map +1 -1
  183. package/dist/tools/write-post.d.ts.map +1 -1
  184. package/dist/tools/write-post.js +34 -2
  185. package/dist/tools/write-post.js.map +1 -1
  186. package/dist/tools/write-video-post.d.ts.map +1 -1
  187. package/dist/tools/write-video-post.js +5 -1
  188. package/dist/tools/write-video-post.js.map +1 -1
  189. package/package.json +2 -1
@@ -0,0 +1,58 @@
1
+ /**
2
+ * How far along a pack plan is (pack plans, 9 Nov 2026). Its own module so the
3
+ * folder store never has to import the rooms.
4
+ *
5
+ * planned nobody has started it
6
+ * started a piece of work is named for it, nothing made yet
7
+ * in_progress made, not finished
8
+ * made finished: GIMP work with a final; a Blender model built AND
9
+ * baked (textures/ exists), because an unbaked model reaches an
10
+ * engine flat and so isn't finished
11
+ */
12
+ import { existsSync } from 'node:fs';
13
+ import { readFile, readdir } from 'node:fs/promises';
14
+ import { join } from 'node:path';
15
+ import { metadataFile, modelsDir } from '../tools/blender/paths.js';
16
+ import { readImageFinals } from '../tools/gimp/build-image.js';
17
+ import { planWorkId } from './library-folders.js';
18
+ async function libraryIds() {
19
+ try {
20
+ const items = JSON.parse(await readFile(metadataFile(), 'utf-8'));
21
+ return new Set((Array.isArray(items) ? items : []).map((i) => i?.id).filter((x) => typeof x === 'string'));
22
+ }
23
+ catch {
24
+ return new Set();
25
+ }
26
+ }
27
+ async function stateOf(item, lib) {
28
+ if (!item.work)
29
+ return 'planned';
30
+ if (!lib.has(planWorkId(item.work)))
31
+ return 'started';
32
+ if (item.work.tool === 'gimp')
33
+ return (await readImageFinals(item.work.slug)).length ? 'made' : 'in_progress';
34
+ const tex = join(modelsDir(), item.work.slug, 'textures');
35
+ return existsSync(tex) && (await readdir(tex).catch(() => [])).length ? 'made' : 'in_progress';
36
+ }
37
+ /** Every planned piece's state, by folder and piece id. */
38
+ export async function planStatuses(folders) {
39
+ const lib = await libraryIds();
40
+ const out = {};
41
+ for (const f of folders) {
42
+ if (!f.plan)
43
+ continue;
44
+ out[f.id] = {};
45
+ for (const item of f.plan.items)
46
+ out[f.id][item.id] = await stateOf(item, lib);
47
+ }
48
+ return out;
49
+ }
50
+ /** "7 of 16 made · 2 in progress · next: Arched window". */
51
+ export function planProgressLine(folder, states) {
52
+ const items = folder.plan?.items ?? [];
53
+ const made = items.filter((i) => states[i.id] === 'made').length;
54
+ const going = items.filter((i) => states[i.id] === 'in_progress' || states[i.id] === 'started').length;
55
+ const next = items.find((i) => states[i.id] === 'planned');
56
+ return `${made} of ${items.length} made${going ? ` · ${going} in progress` : ''}${next ? ` · next on the plan: ${next.name}` : made === items.length ? ' · every piece is made' : ''}`;
57
+ }
58
+ //# sourceMappingURL=pack-plan-status.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pack-plan-status.js","sourceRoot":"","sources":["../../src/creative/pack-plan-status.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,UAAU,EAAqC,MAAM,sBAAsB,CAAC;AAIrF,KAAK,UAAU,UAAU;IACvB,IAAI,CAAC;QACH,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,QAAQ,CAAC,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC,CAAC;QAClE,OAAO,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAe,EAAE,CAAC,OAAO,CAAC,KAAK,QAAQ,CAAC,CAAC,CAAC;IAC1H,CAAC;IAAC,MAAM,CAAC;QAAC,OAAO,IAAI,GAAG,EAAE,CAAC;IAAC,CAAC;AAC/B,CAAC;AAED,KAAK,UAAU,OAAO,CAAC,IAAc,EAAE,GAAgB;IACrD,IAAI,CAAC,IAAI,CAAC,IAAI;QAAE,OAAO,SAAS,CAAC;IACjC,IAA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MAAM,KAAK,GAAG,MAAM,CAAC,IAAI,EAAE,KAAK,IAAI,EAAE,CAAC;IACvC,MAAM,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,MAAM,CAAC,CAAC,MAAM,CAAC;IACjE,MAAM,KAAK,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,aAAa,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,SAAS,CAAC,CAAC,MAAM,CAAC;IACvG,MAAM,IAAI,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,SAAS,CAAC,CAAC;IAC3D,OAAO,GAAG,IAAI,OAAO,KAAK,CAAC,MAAM,QAAQ,KAAK,CAAC,CAAC,CAAC,MAAM,KAAK,cAAc,CAAC,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,CAAC,CAAC,wBAAwB,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,wBAAwB,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;AACzL,CAAC"}
@@ -0,0 +1,49 @@
1
+ /**
2
+ * "Use in project" — copy a piece of Library work into the project that is
3
+ * open, the way that project's engine expects it (11 Nov 2026).
4
+ *
5
+ * It used to copy the whole work folder: Ava's brief, her scripts, the step
6
+ * history, test exports and proofs, and a .blend whose textures still pointed
7
+ * into ~/.ava — so it opened with every texture missing on anyone else's
8
+ * machine. Now it copies FINISHED files only, made the same way as a folder
9
+ * download (exportModel re-saves the .blend with relative links and exports a
10
+ * fresh .fbx), and filed where the engine looks:
11
+ *
12
+ * Unity (ProjectSettings/ProjectVersion.txt) → Assets/<Name>/ .fbx + textures/
13
+ * Unreal (*.uproject) → Content/<Name>/ .fbx + textures/
14
+ * Epic's default auto-import watches Content and offers to import.
15
+ * Godot (project.godot) → assets/<Name>/ .glb only
16
+ * other first of public/, src/assets/, assets/, static/, images/ → every file
17
+ *
18
+ * One model format per engine on purpose: Unity imports a .blend as well as
19
+ * the .fbx when Blender is installed, and Godot imports .fbx and .blend beside
20
+ * the .glb — two copies of the same model in the project. Where the preferred
21
+ * format could not be made (no Blender, no .fbx), the .glb stays, with a
22
+ * warning, rather than leaving the project with no model at all.
23
+ */
24
+ import { type ExportWarning } from './folder-export.js';
25
+ export type ProjectEngine = 'unity' | 'unreal' | 'godot' | null;
26
+ export declare function detectEngine(projectRoot: string): ProjectEngine;
27
+ /** Where Library work goes in this project, creating the folder if it must. */
28
+ export declare function projectAssetDir(projectRoot: string): Promise<{
29
+ dir: string;
30
+ engine: ProjectEngine;
31
+ }>;
32
+ export interface WorkToCopy {
33
+ id: string;
34
+ kind?: string;
35
+ title?: string;
36
+ absoluteFolder?: string;
37
+ }
38
+ export interface ProjectCopyResult {
39
+ ok: boolean;
40
+ /** Project-relative, forward slashes: ready to paste into code. */
41
+ relPath?: string;
42
+ absPath?: string;
43
+ engine: ProjectEngine;
44
+ warnings: ExportWarning[];
45
+ error?: string;
46
+ }
47
+ /** Copy one piece of folder-shaped Library work (a model, GIMP work or an uploaded model) into the project. */
48
+ export declare function copyWorkToProject(item: WorkToCopy, projectRoot: string): Promise<ProjectCopyResult>;
49
+ //# sourceMappingURL=project-copy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"project-copy.d.ts","sourceRoot":"","sources":["../../src/creative/project-copy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAOH,OAAO,EAAyB,KAAK,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAE/E,MAAM,MAAM,aAAa,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,GAAG,IAAI,CAAC;AAEhE,wBAAgB,YAAY,CAAC,WAAW,EAAE,MAAM,GAAG,aAAa,CAS/D;AAID,+EAA+E;AAC/E,wBAAsB,eAAe,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,aAAa,CAAA;CAAE,CAAC,CAY1G;AAuBD,MAAM,WAAW,UAAU;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,OAAO,CAAC;IACZ,mEAAmE;IACnE,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,aAAa,CAAC;IACtB,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,+GAA+G;AAC/G,wBAAsB,iBAAiB,CAAC,IAAI,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC,CA2DzG"}
@@ -0,0 +1,149 @@
1
+ /**
2
+ * "Use in project" — copy a piece of Library work into the project that is
3
+ * open, the way that project's engine expects it (11 Nov 2026).
4
+ *
5
+ * It used to copy the whole work folder: Ava's brief, her scripts, the step
6
+ * history, test exports and proofs, and a .blend whose textures still pointed
7
+ * into ~/.ava — so it opened with every texture missing on anyone else's
8
+ * machine. Now it copies FINISHED files only, made the same way as a folder
9
+ * download (exportModel re-saves the .blend with relative links and exports a
10
+ * fresh .fbx), and filed where the engine looks:
11
+ *
12
+ * Unity (ProjectSettings/ProjectVersion.txt) → Assets/<Name>/ .fbx + textures/
13
+ * Unreal (*.uproject) → Content/<Name>/ .fbx + textures/
14
+ * Epic's default auto-import watches Content and offers to import.
15
+ * Godot (project.godot) → assets/<Name>/ .glb only
16
+ * other first of public/, src/assets/, assets/, static/, images/ → every file
17
+ *
18
+ * One model format per engine on purpose: Unity imports a .blend as well as
19
+ * the .fbx when Blender is installed, and Godot imports .fbx and .blend beside
20
+ * the .glb — two copies of the same model in the project. Where the preferred
21
+ * format could not be made (no Blender, no .fbx), the .glb stays, with a
22
+ * warning, rather than leaving the project with no model at all.
23
+ */
24
+ import { existsSync, readdirSync } from 'node:fs';
25
+ import { copyFile, mkdir, readdir, rm } from 'node:fs/promises';
26
+ import { basename, dirname, extname, join, relative } from 'node:path';
27
+ import { findBlender } from '../tools/blender/find-blender.js';
28
+ import { readImageFinals } from '../tools/gimp/build-image.js';
29
+ import { exportModel, safeName } from './folder-export.js';
30
+ export function detectEngine(projectRoot) {
31
+ if (existsSync(join(projectRoot, 'ProjectSettings', 'ProjectVersion.txt')) && existsSync(join(projectRoot, 'Assets')))
32
+ return 'unity';
33
+ if (existsSync(join(projectRoot, 'project.godot')))
34
+ return 'godot';
35
+ try {
36
+ // The project root, one level: cheap.
37
+ const names = readdirSync(projectRoot);
38
+ if (names.some((n) => n.toLowerCase().endsWith('.uproject')))
39
+ return 'unreal';
40
+ }
41
+ catch { /* unreadable root: not an engine we know */ }
42
+ return null;
43
+ }
44
+ const PREFERRED = ['public', join('src', 'assets'), 'assets', 'static', 'images'];
45
+ /** Where Library work goes in this project, creating the folder if it must. */
46
+ export async function projectAssetDir(projectRoot) {
47
+ const engine = detectEngine(projectRoot);
48
+ const fixed = engine === 'unity' ? 'Assets' : engine === 'unreal' ? 'Content' : engine === 'godot' ? 'assets' : null;
49
+ if (fixed) {
50
+ const dir = join(projectRoot, fixed);
51
+ await mkdir(dir, { recursive: true });
52
+ return { dir, engine };
53
+ }
54
+ for (const c of PREFERRED)
55
+ if (existsSync(join(projectRoot, c)))
56
+ return { dir: join(projectRoot, c), engine };
57
+ const dir = join(projectRoot, 'images');
58
+ await mkdir(dir, { recursive: true });
59
+ return { dir, engine };
60
+ }
61
+ /** A name not taken in `dir` (case-insensitive, as Windows and macOS are). */
62
+ function free(dir, name, ext = '') {
63
+ const taken = new Set();
64
+ try {
65
+ for (const n of readdirSync(dir))
66
+ taken.add(n.toLowerCase());
67
+ }
68
+ catch { /* new folder */ }
69
+ let out = `${name}${ext}`;
70
+ for (let n = 2; taken.has(out.toLowerCase()); n++)
71
+ out = `${name}-${n}${ext}`;
72
+ return out;
73
+ }
74
+ async function filesUnder(dir, base = dir) {
75
+ const out = [];
76
+ for (const e of await readdir(dir, { withFileTypes: true }).catch(() => [])) {
77
+ const p = join(dir, e.name);
78
+ if (e.isDirectory())
79
+ out.push(...await filesUnder(p, base));
80
+ else if (e.isFile())
81
+ out.push(relative(base, p));
82
+ }
83
+ return out;
84
+ }
85
+ /** Copy one piece of folder-shaped Library work (a model, GIMP work or an uploaded model) into the project. */
86
+ export async function copyWorkToProject(item, projectRoot) {
87
+ const warnings = [];
88
+ const { dir, engine } = await projectAssetDir(projectRoot);
89
+ const label = item.title ?? 'Untitled';
90
+ const name = safeName(label);
91
+ const rel = (p) => relative(projectRoot, p).split(/[\\/]/).join('/');
92
+ const folder = item.absoluteFolder;
93
+ if (!folder || !existsSync(folder))
94
+ return { ok: false, engine, warnings, error: 'Its folder is missing from the Library.' };
95
+ // GIMP work: its finished files only.
96
+ if (item.kind === 'gimp') {
97
+ const finals = await readImageFinals(basename(folder));
98
+ if (!finals.length)
99
+ return { ok: false, engine, warnings, error: 'This has no finished file yet. Mark a final in the GIMP room first.' };
100
+ if (finals.length === 1) {
101
+ const ext = extname(finals[0]).toLowerCase();
102
+ const to = join(dir, free(dir, name, ext));
103
+ await copyFile(join(folder, finals[0]), to);
104
+ return { ok: true, relPath: rel(to), absPath: to, engine, warnings };
105
+ }
106
+ const out = join(dir, free(dir, name));
107
+ await mkdir(out, { recursive: true });
108
+ for (const f of finals) {
109
+ const ext = extname(f).toLowerCase();
110
+ await copyFile(join(folder, f), join(out, free(out, safeName(basename(f, extname(f))), ext)));
111
+ }
112
+ return { ok: true, relPath: rel(out), absPath: out, engine, warnings };
113
+ }
114
+ if (item.kind !== 'model')
115
+ return { ok: false, engine, warnings, error: 'This is not a model or GIMP work.' };
116
+ const out = join(dir, free(dir, name));
117
+ // A model they uploaded: their files exactly as they are (side files keep
118
+ // their names — a .gltf names its .bin and textures).
119
+ if (item.id.startsWith('upload_')) {
120
+ for (const f of await filesUnder(folder)) {
121
+ if (f === 'preview.png')
122
+ continue;
123
+ await mkdir(dirname(join(out, f)), { recursive: true });
124
+ await copyFile(join(folder, f), join(out, f));
125
+ }
126
+ return { ok: true, relPath: rel(out), absPath: out, engine, warnings };
127
+ }
128
+ // A model Ava built: made the same way as a folder download.
129
+ const blenderPath = (await findBlender().catch(() => null))?.path ?? null;
130
+ await exportModel({ label, folder, slug: basename(folder), to: basename(out), name }, dir, blenderPath, warnings);
131
+ const has = (ext) => existsSync(join(out, `${name}${ext}`));
132
+ const drop = async (ext) => rm(join(out, `${name}${ext}`), { force: true });
133
+ if (engine === 'unity' || engine === 'unreal') {
134
+ await drop('.blend');
135
+ if (has('.fbx'))
136
+ await drop('.glb');
137
+ else
138
+ warnings.push({ item: label, message: `There is no .fbx (Blender isn't installed to make one), so the .glb was copied instead. ${engine === 'unity' ? 'Unity reads .glb only with its glTF package.' : 'Import it through the Content Browser.'}` });
139
+ }
140
+ else if (engine === 'godot') {
141
+ if (has('.glb')) {
142
+ await drop('.fbx');
143
+ await drop('.blend');
144
+ await rm(join(out, 'textures'), { recursive: true, force: true }); // the .glb carries them
145
+ }
146
+ }
147
+ return { ok: true, relPath: rel(out), absPath: out, engine, warnings };
148
+ }
149
+ //# sourceMappingURL=project-copy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"project-copy.js","sourceRoot":"","sources":["../../src/creative/project-copy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAClD,OAAO,EAAE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,KAAK,OAAO,EAAE,CAAC;QAC9B,IAAI,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;YAChB,MAAM,IAAI,CAAC,MAAM,CAAC,CAAC;YAAC,MAAM,IAAI,CAAC,QAAQ,CAAC,CAAC;YACzC,MAAM,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,wBAAwB;QAC7F,CAAC;IACH,CAAC;IACD,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,GAAG,CAAC,GAAG,CAAC,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;AACzE,CAAC"}
@@ -0,0 +1,55 @@
1
+ /**
2
+ * Store-ready downloads (Library folders and packs plan, Phase 5).
3
+ *
4
+ * Choose a store, and the download is PREPARED for it and CHECKED against its
5
+ * rules — the rules read on the stores' own pages on 7 Nov 2026 and re-read
6
+ * at the source on 11 Nov 2026 (seller agreements, AI policies, trademark rules;
7
+ * see the plan's "Store rules checked at the source").
8
+ * Checks report problems and let the person decide; nothing is hidden.
9
+ *
10
+ * Wording rules: "prepared for Fab", never "approved" — only the store
11
+ * approves. Stores that ban this work are listed as blocked, with the reason,
12
+ * so nobody finds out when their account is suspended. Declaring AI use is in
13
+ * every open store's rules and is the person's to do; the making record is
14
+ * what they write it from. We never choose their licence.
15
+ */
16
+ import { type ReportPiece } from './making-report.js';
17
+ export type StoreId = 'unity' | 'fab' | 'itch' | 'gumroad' | 'superhive' | 'godot';
18
+ export interface StoreProfile {
19
+ id: StoreId | 'turbosquid' | 'envato';
20
+ name: string;
21
+ /** ready: we prepare for it. blocked: the store bans this work. target: not a store (Godot). */
22
+ status: 'ready' | 'blocked' | 'target';
23
+ /** One line on what the download will be. */
24
+ summary: string;
25
+ /** Why a blocked store is blocked, or the disclosure rule for an open one. */
26
+ note: string;
27
+ }
28
+ /** Every store we know about, ready or not. Shown in the Download panel exactly like this. */
29
+ export declare const STORE_PROFILES: StoreProfile[];
30
+ /**
31
+ * Store names are their owners' trademarks, used here only to describe what a
32
+ * download is laid out for. Unity's trademark guidelines ask for a notice like
33
+ * this wherever its marks appear; the Download panel shows it whenever a store
34
+ * is chosen, and the checklists carry it. (Terms of Service 10.8.)
35
+ */
36
+ export declare const STORE_TRADEMARK_NOTICE: string;
37
+ export interface StoreContext {
38
+ root: string;
39
+ topName: string;
40
+ pieces: ReportPiece[];
41
+ models: Array<{
42
+ label: string;
43
+ to: string;
44
+ name: string;
45
+ triangles?: number;
46
+ sizeM?: number[];
47
+ }>;
48
+ blender: string | null;
49
+ warn: (item: string, message: string) => void;
50
+ }
51
+ /** Prepare the downloaded folder for a store, in place. */
52
+ export declare function prepareForStore(store: StoreId, ctx: StoreContext): Promise<void>;
53
+ /** Gumroad is sold as one zip. */
54
+ export declare const STORE_WANTS_ZIP: Partial<Record<StoreId, boolean>>;
55
+ //# sourceMappingURL=store-profiles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"store-profiles.d.ts","sourceRoot":"","sources":["../../src/creative/store-profiles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAUH,OAAO,EAAsB,KAAK,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAG1E,MAAM,MAAM,OAAO,GAAG,OAAO,GAAG,KAAK,GAAG,MAAM,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,CAAC;AAEnF,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,OAAO,GAAG,YAAY,GAAG,QAAQ,CAAC;IACtC,IAAI,EAAE,MAAM,CAAC;IACb,gGAAgG;IAChG,MAAM,EAAE,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAC;IACvC,6CAA6C;IAC7C,OAAO,EAAE,MAAM,CAAC;IAChB,8EAA8E;IAC9E,IAAI,EAAE,MAAM,CAAC;CACd;AAED,8FAA8F;AAC9F,e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