@coloopx/colocad 0.1.0-alpha.3 → 0.1.0-alpha.5

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 (53) hide show
  1. package/NOTICE.md +2 -0
  2. package/README.md +130 -4
  3. package/README.zh-CN.md +111 -4
  4. package/bin/colocad.mjs +28 -4
  5. package/docs/README.md +28 -0
  6. package/docs/README.zh-CN.md +85 -0
  7. package/docs/agent-modeling-handbook.md +68 -0
  8. package/docs/agent-modeling-handbook.zh-CN.md +222 -0
  9. package/docs/agent-modeling-research.md +22 -0
  10. package/docs/api.md +95 -0
  11. package/docs/best-practices.md +45 -0
  12. package/docs/concepts.md +37 -0
  13. package/docs/getting-started.md +53 -0
  14. package/docs/integrations/claude-code.md +52 -0
  15. package/docs/integrations/codex.md +55 -0
  16. package/docs/integrations/overview.md +53 -0
  17. package/docs/integrations/pi.md +73 -0
  18. package/docs/integrations/verification.md +30 -0
  19. package/docs/modeling-history.md +60 -0
  20. package/docs/modeling-workflow.zh-CN.md +77 -0
  21. package/docs/troubleshooting.md +25 -0
  22. package/docs/validation.md +23 -0
  23. package/examples/hiwin-kk60/README.md +55 -0
  24. package/examples/hiwin-kk60/model.mjs +94 -0
  25. package/examples/hiwin-kk60/run.mjs +14 -0
  26. package/examples/hiwin-kk60/sources.json +88 -0
  27. package/examples/integrations/README.md +47 -0
  28. package/examples/integrations/compact-tools.mjs +27 -0
  29. package/examples/integrations/guided-workflow.mjs +31 -0
  30. package/kernel/native/darwin-arm64/agent-cad +1 -1
  31. package/kernel/native/darwin-arm64/manifest.json +1 -2
  32. package/kernel/native/linux-arm64/agent-cad +1 -1
  33. package/kernel/native/linux-arm64/manifest.json +1 -2
  34. package/kernel/native/linux-x64/agent-cad +2 -2
  35. package/kernel/native/linux-x64/manifest.json +2 -3
  36. package/kernel/release.json +4 -4
  37. package/package.json +40 -4
  38. package/skills/colocad/SKILL.md +18 -8
  39. package/skills/colocad/assets/product-brief.example.json +20 -0
  40. package/skills/colocad/references/history.md +19 -0
  41. package/skills/colocad/references/materials.md +37 -0
  42. package/skills/colocad/references/modeling-loop.md +33 -0
  43. package/skills/colocad/references/prompt-patterns.md +70 -0
  44. package/skills/colocad/references/tool-contracts.md +33 -0
  45. package/skills/colocad/references/tuning.md +30 -0
  46. package/src/render.mjs +72 -0
  47. package/src/session.d.mts +34 -0
  48. package/src/session.mjs +140 -0
  49. package/src/view-server.mjs +50 -0
  50. package/viewer/THREE-LICENSE +21 -0
  51. package/viewer/dist/index.js +4236 -0
  52. package/viewer/dist/standalone.js +4236 -0
  53. package/viewer/index.d.ts +18 -0
@@ -0,0 +1,18 @@
1
+ /** Browser-only custom element. Import registers <colocad-viewer>. */
2
+ export interface ViewerSession {
3
+ format: 'colocad/viewer/1'; title: string; id: string; createdAt: string;
4
+ display?: { cutaway?: boolean; view?: 'iso'|'front'|'side'|'top' };
5
+ steps: Array<Record<string, any>>;
6
+ meshes: Record<string, {positions: number[][]; normals?: number[][]; triangles: number[][]}>;
7
+ }
8
+ export class ColocadViewer extends HTMLElement {
9
+ session: ViewerSession;
10
+ setStep(index: number): void;
11
+ setView(view: 'iso'|'front'|'side'|'top'): void;
12
+ select(id: string): void;
13
+ setProjection(mode: 'perspective'|'orthographic'): void;
14
+ setSectionAxis(axis: 'x'|'y'|'z'): void;
15
+ play(): void;
16
+ pause(): void;
17
+ getState(): {stepIndex: number; status?: string; parts: number; visibleParts: number; view: string; exploded: number; cutaway: boolean; playing: boolean; selectedId: string|null; webgl: boolean};
18
+ }