create-ailk 0.4.0 → 0.5.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 (146) hide show
  1. package/component-catalog.json +11939 -0
  2. package/component-catalog.md +176 -64
  3. package/dist/cli.js +29 -1
  4. package/dist/derive-architecture.js +5 -2
  5. package/dist/lib/extract-module-bundle.d.ts +50 -2
  6. package/dist/lib/extract-module-bundle.js +223 -15
  7. package/dist/lib/fetch-guard.d.ts +28 -0
  8. package/dist/lib/fetch-guard.js +101 -0
  9. package/dist/lib/fetch-module.js +4 -0
  10. package/dist/lib/fetch-template.js +4 -0
  11. package/dist/module-architecture.d.ts +59 -8
  12. package/dist/module-architecture.js +334 -115
  13. package/dist/parse-args.js +6 -2
  14. package/dist/programmatic.d.ts +10 -0
  15. package/dist/programmatic.js +134 -19
  16. package/dist/site-chrome.d.ts +80 -0
  17. package/dist/site-chrome.js +135 -0
  18. package/dist/surfaces.d.ts +21 -6
  19. package/dist/surfaces.js +107 -32
  20. package/dist/template-manifest.d.ts +55 -3
  21. package/dist/template-manifest.js +181 -12
  22. package/dist/template-names.d.ts +1 -1
  23. package/dist/template-names.js +1 -0
  24. package/package.json +9 -2
  25. package/site-templates/_base/ailk-template.json +6 -0
  26. package/site-templates/_base/content/en/Pricing/pricing.mdx +169 -0
  27. package/site-templates/marketing-site/TEMPLATE-MANIFEST.json +331 -0
  28. package/site-templates/marketing-site/TEMPLATE-MANIFEST.md +393 -0
  29. package/site-templates/marketing-site/ailk-template.json +11 -0
  30. package/site-templates/marketing-site/content/en/blog/05-this-vc-morning-routine-will-make-you-super-annoying.mdx +36 -0
  31. package/site-templates/marketing-site/provenance.json +4 -0
  32. package/site-templates/marketing-site-free/TEMPLATE-MANIFEST.json +288 -0
  33. package/site-templates/marketing-site-free/TEMPLATE-MANIFEST.md +285 -0
  34. package/site-templates/marketing-site-free/ailk-template.json +2 -1
  35. package/site-templates/minimalism-site/TEMPLATE-MANIFEST.json +271 -0
  36. package/site-templates/minimalism-site/TEMPLATE-MANIFEST.md +324 -0
  37. package/site-templates/minimalism-site/ailk-template.json +21 -0
  38. package/site-templates/minimalism-site/assets/avatar-placeholder-1.svg +7 -0
  39. package/site-templates/minimalism-site/assets/avatar-placeholder-2.svg +7 -0
  40. package/site-templates/minimalism-site/assets/avatar-placeholder-3.svg +7 -0
  41. package/site-templates/minimalism-site/assets/avatar-placeholder-4.svg +7 -0
  42. package/site-templates/minimalism-site/assets/avatar-placeholder-5.svg +7 -0
  43. package/site-templates/minimalism-site/assets/avatar-placeholder-6.svg +7 -0
  44. package/site-templates/minimalism-site/assets/hero-backdrop.svg +17 -0
  45. package/site-templates/minimalism-site/assets/logo-placeholder-1.svg +6 -0
  46. package/site-templates/minimalism-site/assets/logo-placeholder-2.svg +6 -0
  47. package/site-templates/minimalism-site/assets/logo-placeholder-3.svg +6 -0
  48. package/site-templates/minimalism-site/content/en/AboutPage/about.mdx +110 -0
  49. package/site-templates/minimalism-site/content/en/ContactPage/contact.mdx +68 -0
  50. package/site-templates/minimalism-site/content/en/FAQPage/faq.mdx +57 -0
  51. package/site-templates/minimalism-site/content/en/HomePage/home.mdx +214 -0
  52. package/site-templates/minimalism-site/content/en/LandingPage/referral.mdx +77 -0
  53. package/site-templates/minimalism-site/content/en/LandingPage/reports.mdx +73 -0
  54. package/site-templates/minimalism-site/content/en/ReportPage/annual-letter-2024.mdx +52 -0
  55. package/site-templates/minimalism-site/content/en/ReportPage/field-notes-2023.mdx +52 -0
  56. package/site-templates/minimalism-site/content/en/ReportPage/platform-shift-2025.mdx +52 -0
  57. package/site-templates/minimalism-site/content/en/ReportPage/state-of-the-market-2026.mdx +52 -0
  58. package/site-templates/minimalism-site/content/en/Service/first-engagement.mdx +38 -0
  59. package/site-templates/minimalism-site/content/en/Service/second-engagement.mdx +38 -0
  60. package/site-templates/minimalism-site/content/en/Service/third-engagement.mdx +38 -0
  61. package/site-templates/minimalism-site/content/en/ServicesList/services.mdx +73 -0
  62. package/site-templates/minimalism-site/flows/referral.flow.json +71 -0
  63. package/site-templates/minimalism-site/provenance.json +4 -0
  64. package/site-templates/saas-product/TEMPLATE-MANIFEST.md +61 -0
  65. package/site-templates/saas-product/ailk-template.json +16 -0
  66. package/site-templates/saas-product/provenance.json +10 -0
  67. package/templates/.claude/skills/README.md +16 -25
  68. package/templates/.env.example +32 -7
  69. package/templates/.github/workflows/ci.yml +48 -0
  70. package/templates/README.md +3 -1
  71. package/templates/apps/api/CLAUDE.md +4 -1
  72. package/templates/apps/api/eslint.config.mjs +69 -0
  73. package/templates/apps/api/package.json +6 -2
  74. package/templates/apps/api/src/__tests__/module-exclusion.test.ts +6 -2
  75. package/templates/apps/api/src/__tests__/review-surface-registration.test.ts +167 -0
  76. package/templates/apps/api/src/__tests__/workspace-module-registration.test.ts +8 -1
  77. package/templates/apps/api/src/lib/__mocks__/prisma.ts +3 -0
  78. package/templates/apps/api/src/middleware/__tests__/default-tenant.test.ts +339 -0
  79. package/templates/apps/api/src/middleware/__tests__/rate-limit.test.ts +108 -0
  80. package/templates/apps/api/src/middleware/default-tenant.ts +136 -0
  81. package/templates/apps/api/src/routes/leads/__tests__/list.test.ts +171 -0
  82. package/templates/apps/api/src/routes/leads/list.ts +104 -0
  83. package/templates/apps/api/src/server.ts +82 -6
  84. package/templates/apps/api/src/services/__tests__/lead-promotion.test.ts +408 -0
  85. package/templates/apps/api/src/services/__tests__/leads-inbox.test.ts +329 -0
  86. package/templates/apps/api/src/services/default-tenant.ts +261 -0
  87. package/templates/apps/api/src/services/lead-promotion.ts +161 -0
  88. package/templates/apps/api/src/services/leads-inbox.ts +263 -0
  89. package/templates/apps/api/src/services/owner-workspaces.ts +132 -0
  90. package/templates/apps/mcp/CLAUDE.md +1 -1
  91. package/templates/apps/mcp/__tests__/parity.test.ts +2 -2
  92. package/templates/apps/mcp/__tests__/tools/{scaffold.test.ts → create_project.test.ts} +23 -23
  93. package/templates/apps/mcp/eslint.config.mjs +69 -0
  94. package/templates/apps/mcp/package.json +6 -2
  95. package/templates/apps/mcp/src/server.ts +2 -2
  96. package/templates/apps/mcp/src/tools/{scaffold.ts → create_project.ts} +3 -3
  97. package/templates/apps/mcp/src/tools/index.ts +2 -2
  98. package/templates/apps/web/.env.example +3 -3
  99. package/templates/apps/web/CLAUDE.md +2 -0
  100. package/templates/apps/web/app/[locale]/(authed)/account/page.tsx +4 -6
  101. package/templates/apps/web/app/[locale]/(authed)/layout.tsx +1 -1
  102. package/templates/apps/web/app/[locale]/(authed)/leads/__tests__/page.test.tsx +181 -0
  103. package/templates/apps/web/app/[locale]/(authed)/leads/components/LeadsTable.tsx +137 -0
  104. package/templates/apps/web/app/[locale]/(authed)/leads/page.tsx +111 -0
  105. package/templates/apps/web/app/[locale]/(authed)/sign-in-gate.tsx +1 -1
  106. package/templates/apps/web/app/[locale]/[slug]/__tests__/page.test.tsx +111 -0
  107. package/templates/apps/web/app/[locale]/[slug]/page.tsx +65 -0
  108. package/templates/apps/web/app/[locale]/flows/[slug]/FlowStepperClient.tsx +1 -1
  109. package/templates/apps/web/app/[locale]/flows/[slug]/__tests__/FlowStepperClient.permalink.test.tsx +1 -1
  110. package/templates/apps/web/app/[locale]/flows/[slug]/__tests__/FlowStepperClient.test.tsx +6 -5
  111. package/templates/apps/web/app/[locale]/flows/[slug]/flow.actions.ts +1 -1
  112. package/templates/apps/web/app/[locale]/layout.tsx +214 -17
  113. package/templates/apps/web/components/google-analytics.tsx +18 -1
  114. package/templates/apps/web/eslint.config.mjs +69 -0
  115. package/templates/apps/web/jest.config.cjs +7 -15
  116. package/templates/apps/web/lib/__tests__/structured-data.test.tsx +32 -5
  117. package/templates/apps/web/lib/nav-config.ts +27 -7
  118. package/templates/apps/web/lib/server-api.ts +1 -1
  119. package/templates/apps/web/lib/site-chrome.ts +29 -0
  120. package/templates/apps/web/lib/telemetry-scrub.ts +46 -0
  121. package/templates/apps/web/messages/en.json +29 -2
  122. package/templates/apps/web/next.config.mjs +20 -0
  123. package/templates/apps/web/package.json +6 -2
  124. package/templates/apps/web/sentry.client.config.ts +131 -0
  125. package/templates/apps/web/sentry.edge.config.ts +72 -0
  126. package/templates/apps/web/sentry.server.config.ts +72 -0
  127. package/templates/apps/web/src/lib/routes.ts +13 -18
  128. package/templates/brand_assets/README.md +24 -0
  129. package/templates/content/en/AboutPage/about.mdx +160 -15
  130. package/templates/content/en/ContactPage/contact.mdx +90 -13
  131. package/templates/content/en/FAQPage/faq.mdx +62 -22
  132. package/templates/content/en/HomePage/home.mdx +244 -20
  133. package/templates/content/en/LandingPage/blog.mdx +83 -0
  134. package/templates/content/en/LandingPage/features.mdx +103 -0
  135. package/templates/content/en/LandingPage/how-it-works.mdx +143 -0
  136. package/templates/database/CHANGELOG.md +7 -0
  137. package/templates/database/__tests__/seed.test.ts +1 -1
  138. package/templates/database/eslint.config.mjs +69 -0
  139. package/templates/database/package.json +7 -3
  140. package/templates/database/seed.ts +1 -1
  141. package/templates/package.json +1 -14
  142. package/versions.json +52 -0
  143. package/site-templates/marketing-site-free/content/en/Pricing/pricing.mdx +0 -103
  144. /package/site-templates/{marketing-site-free → _base}/content/en/PrivacyPage/privacy.mdx +0 -0
  145. /package/site-templates/{marketing-site-free → _base}/content/en/TermsPage/terms.mdx +0 -0
  146. /package/templates/apps/web/{src/components → components}/SiteNav.tsx +0 -0
@@ -0,0 +1,69 @@
1
+ // Self-contained ESLint flat config for this scaffolded package.
2
+ //
3
+ // It deliberately does NOT depend on @working-theory/eslint-config — that
4
+ // package is internal to the AI Launch Kit monorepo and is not published, so
5
+ // it cannot be a dependency of a scaffolded starter. Everything below comes
6
+ // from public npm packages already pinned as devDependencies (see
7
+ // package.json): @eslint/js, globals and typescript-eslint.
8
+ //
9
+ // Source file name (#5556): this file is checked in as `_eslint.config.mjs`,
10
+ // not `eslint.config.mjs` — build-templates.mjs renames it at snapshot time
11
+ // (renameScaffoldLintConfigs()). A file literally named `eslint.config.mjs`
12
+ // anywhere under this monorepo (even one this repo's own root eslint.config.ts
13
+ // lists in its `ignores`) is auto-discovered by ESLint's flat-config nested
14
+ // resolution as a competing config root, which breaks the monorepo's own
15
+ // lint runs (verified live: typescript-eslint's "multiple candidate
16
+ // TSConfigRootDirs" parser error across unrelated packages/create-ailk
17
+ // files). The underscore prefix keeps it invisible to that discovery while
18
+ // it lives in this checkout; only the snapshot in templates/ — which ships
19
+ // to the customer, not this repo — gets the real filename.
20
+ import js from "@eslint/js";
21
+ import globals from "globals";
22
+ import tseslint from "typescript-eslint";
23
+
24
+ export default tseslint.config(
25
+ {
26
+ ignores: [
27
+ "**/.next/**",
28
+ "**/dist/**",
29
+ "**/generated/**",
30
+ "**/node_modules/**",
31
+ ],
32
+ },
33
+ js.configs.recommended,
34
+ ...tseslint.configs.recommended,
35
+ {
36
+ languageOptions: {
37
+ globals: {
38
+ ...globals.node,
39
+ ...globals.browser,
40
+ ...globals.jest,
41
+ },
42
+ // Explicit, self-contained root — this scaffold config is never meant
43
+ // to combine with any sibling scaffold package's config (each ships
44
+ // standalone), and leaving it unset makes typescript-eslint's
45
+ // candidate-root disambiguation ambiguous the moment more than one
46
+ // scaffold package's config resolves in the same ESLint process (e.g.
47
+ // this monorepo's own `templates/` build, where all four exist
48
+ // side by side; a real customer scaffold never has that problem,
49
+ // since it only ever ships and lints ONE of these four at a time).
50
+ parserOptions: {
51
+ tsconfigRootDir: import.meta.dirname,
52
+ },
53
+ },
54
+ rules: {
55
+ // Downgraded rather than off, so both stay visible without failing a
56
+ // fresh scaffold's lint:
57
+ // - unused-vars: most of the source follows the underscore-prefix
58
+ // convention for intentionally-unused bindings, which this rule's
59
+ // default options don't recognize; a handful of test fixtures also
60
+ // carry genuinely-unused locals this minimal config doesn't try to
61
+ // triage file-by-file.
62
+ // - require-imports: CommonJS require() is the correct form in Jest
63
+ // config/mock files and in a few test-only dynamic re-require
64
+ // patterns.
65
+ "@typescript-eslint/no-unused-vars": "warn",
66
+ "@typescript-eslint/no-require-imports": "warn",
67
+ },
68
+ },
69
+ );
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@working-theory/database",
3
- "version": "0.23.0",
3
+ "version": "0.24.0",
4
4
  "license": "Apache-2.0",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -50,7 +50,7 @@
50
50
  }
51
51
  },
52
52
  "scripts": {
53
- "lint": "tsx ../scripts/lint-package.ts",
53
+ "lint": "eslint .",
54
54
  "build": "tsc -b tsconfig.build.json && tsc -b tsconfig.tenancy.json && tsc -b tsconfig.flows.json",
55
55
  "db:generate": "prisma generate && pnpm run build",
56
56
  "db:migrate": "prisma migrate dev",
@@ -78,6 +78,10 @@
78
78
  "prisma": "^7.8.0",
79
79
  "ts-jest": "^29.4.11",
80
80
  "tsx": "^4.22.4",
81
- "typescript": "^6.0.3"
81
+ "typescript": "^6.0.3",
82
+ "eslint": "^10.6.0",
83
+ "@eslint/js": "^10.0.1",
84
+ "globals": "^17.7.0",
85
+ "typescript-eslint": "^8.62.1"
82
86
  }
83
87
  }
@@ -104,7 +104,7 @@ async function main(): Promise<void> {
104
104
  // Dynamic imports: the generated client + adapter are constructed only when
105
105
  // this module actually runs as the seed entrypoint — never at import time
106
106
  // (spec §5.2 Quality Constraints), matching the DI note on seed-test.ts's
107
- // sibling and the lazy-require pattern in apps-paid/workspace/auth.ts.
107
+ // sibling and the lazy-require pattern in apps-paid/admin/auth.ts.
108
108
  const [{ PrismaClient: RealPrismaClient }, { PrismaPg }] = await Promise.all([
109
109
  import("./generated/client/client.js"),
110
110
  import("@prisma/adapter-pg"),
@@ -45,10 +45,8 @@
45
45
  "globals": "^17.7.0",
46
46
  "gray-matter": "^4.0.3",
47
47
  "http-server": "^14.1.1",
48
- "husky": "^9.1.7",
49
48
  "jest": "^30.4.2",
50
49
  "jiti": "^2.4.2",
51
- "lint-staged": "^15.3.0",
52
50
  "prettier": "^3.9.4",
53
51
  "ts-declaration-location": "^1.0.7",
54
52
  "ts-jest": "^29.4.11",
@@ -60,18 +58,7 @@
60
58
  "yaml": "^2.9.0",
61
59
  "zod": "^4.2.1",
62
60
  "zod-to-ts": "^2.1.0",
63
- "@working-theory/cli": "^0.23.0"
64
- },
65
- "lint-staged": {
66
- "*.{ts,tsx}": [
67
- "eslint --fix --cache"
68
- ],
69
- "*.{js,jsx,json,md,mdx,yaml,yml,css,scss,html}": [
70
- "prettier --write"
71
- ],
72
- "{apps,packages,database}/**": [
73
- "bash -c 'pnpm architecture'"
74
- ]
61
+ "@working-theory/cli": "workspace:*"
75
62
  },
76
63
  "packageManager": "pnpm@10.34.5+sha512.a4ee05f2f73658255bd6a89859c065a45c28a57daefae2c893a168ee2b73168c37b91e83e57ea67654ad03f03031746430e8bce38e362e042605fb8abc80192e",
77
64
  "engines": {
package/versions.json ADDED
@@ -0,0 +1,52 @@
1
+ {
2
+ "@working-theory/admin-ui": "0.24.0",
3
+ "@working-theory/aeo": "0.24.0",
4
+ "@working-theory/agent-context": "0.24.0",
5
+ "@working-theory/agent-contract": "0.1.0",
6
+ "@working-theory/agent-memory": "0.0.0",
7
+ "@working-theory/ai": "0.1.0",
8
+ "@working-theory/analytics": "0.24.0",
9
+ "@working-theory/api-client": "0.24.0",
10
+ "@working-theory/cda-filesystem": "0.0.0",
11
+ "@working-theory/cli": "0.24.0",
12
+ "@working-theory/common": "0.24.0",
13
+ "@working-theory/consent": "0.1.0",
14
+ "@working-theory/content-adapters": "0.24.0",
15
+ "@working-theory/content-projection": "0.24.0",
16
+ "@working-theory/email": "0.24.0",
17
+ "@working-theory/env": "0.0.0",
18
+ "@working-theory/eslint-config": "0.24.0",
19
+ "@working-theory/fumadocs-schema": "0.24.0",
20
+ "@working-theory/ids": "0.7.0",
21
+ "@working-theory/jsonld": "0.24.0",
22
+ "@working-theory/license": "0.24.0",
23
+ "@working-theory/metadata": "0.24.0",
24
+ "@working-theory/observability": "0.24.0",
25
+ "@working-theory/page-renderer": "0.24.0",
26
+ "@working-theory/schema": "0.24.0",
27
+ "@working-theory/schema-pack-registry": "0.24.0",
28
+ "@working-theory/schema-validator": "0.24.0",
29
+ "@working-theory/sections-registry": "0.24.0",
30
+ "@working-theory/site-config": "0.24.0",
31
+ "@working-theory/stripe-client": "0.24.0",
32
+ "@working-theory/templates": "0.24.0",
33
+ "@working-theory/theme": "0.24.0",
34
+ "@working-theory/ui": "0.24.0",
35
+ "@working-theory/validation": "0.24.0",
36
+ "@working-theory/web-i18n": "0.24.0",
37
+ "@working-theory/billing-client": "0.0.0",
38
+ "@working-theory/branding": "0.0.0",
39
+ "@working-theory/license-client": "0.0.0",
40
+ "@working-theory/license-manifest": "0.0.0",
41
+ "@working-theory/marketing-api-client": "0.0.0",
42
+ "@working-theory/partner-session": "0.0.0",
43
+ "@working-theory/preview-protocol": "0.0.0",
44
+ "@working-theory/ui-commerce": "0.23.1",
45
+ "@working-theory/ui-docs-blog": "0.23.1",
46
+ "@working-theory/ui-scheduling": "0.23.1",
47
+ "@working-theory/ui-signal-collectors": "0.23.1",
48
+ "@working-theory/web": "0.0.0",
49
+ "@working-theory/api": "1.0.0",
50
+ "@working-theory/mcp": "0.0.0",
51
+ "@working-theory/database": "0.24.0"
52
+ }
@@ -1,103 +0,0 @@
1
- ---
2
- type: "Pricing"
3
- slug: "pricing"
4
- title: "Pricing"
5
- description: "Replace this with one sentence naming how Your Company charges — the unit, the range, and what moves the number. It is the description answer engines quote."
6
- sections:
7
- [
8
- {
9
- "id": "hero",
10
- "type": "hero",
11
- "data":
12
- {
13
- "headline": "Pricing",
14
- "subheadline": "Replace this with the one thing a buyer most needs to know about what they will pay.",
15
- },
16
- },
17
- {
18
- "id": "plans",
19
- "type": "pricing",
20
- "data":
21
- {
22
- "headline": "Replace these plans with your own",
23
- "description": "Three placeholder plans. Rename them, set real prices, and list what each one actually includes. Delete any plan you do not offer — an empty tier is worse than one fewer.",
24
- "plans":
25
- [
26
- {
27
- "name": "Plan one",
28
- "description": "Replace this with who this plan is for.",
29
- "price": { "custom": "Your price" },
30
- "features":
31
- [
32
- "Replace this line with something the plan includes.",
33
- "One line per included thing.",
34
- "Name the limit, not just the feature.",
35
- ],
36
- "cta": { "label": "Get in touch", "href": "/contact" },
37
- },
38
- {
39
- "name": "Plan two",
40
- "description": "Replace this with who this plan is for.",
41
- "price": { "custom": "Your price" },
42
- "features":
43
- [
44
- "Everything in plan one.",
45
- "Replace this line with what the step up buys.",
46
- "Say the number when there is one.",
47
- ],
48
- "cta": { "label": "Get in touch", "href": "/contact" },
49
- "highlighted": true,
50
- },
51
- {
52
- "name": "Plan three",
53
- "description": "Replace this with who this plan is for.",
54
- "price": { "custom": "Let's talk" },
55
- "features":
56
- [
57
- "Everything in plan two.",
58
- "Replace this line with the work you quote per engagement.",
59
- "Scope, not adjectives.",
60
- ],
61
- "cta":
62
- {
63
- "label": "Book a call",
64
- "href": "/contact",
65
- "variant": "outline",
66
- },
67
- },
68
- ],
69
- },
70
- },
71
- {
72
- "id": "pricing-faq",
73
- "type": "faq",
74
- "data":
75
- {
76
- "headline": "Pricing questions",
77
- "items":
78
- [
79
- {
80
- "question": "Replace this with the pricing question you are actually asked.",
81
- "answer": "Answer it in the first sentence, with the number in it. A pricing answer that opens with context is the one buyers stop reading.",
82
- },
83
- {
84
- "question": "What happens when the scope changes?",
85
- "answer": "Replace this with how you handle a change in scope — who decides, how it is priced, and when the new price starts. Say it plainly here and you will not have to say it awkwardly later.",
86
- },
87
- ],
88
- },
89
- },
90
- {
91
- "id": "cta",
92
- "type": "cta",
93
- "data":
94
- {
95
- "headline": "Not sure which plan fits?",
96
- "description": "Replace this with an invitation to the conversation you actually want to have.",
97
- "primaryCta": { "label": "Get in touch", "href": "/contact" },
98
- },
99
- },
100
- ]
101
- ---
102
-
103
- {/* Rendered from frontmatter `sections[]`. Seed content — replace the plan names, prices and features above with your own before you launch. */}