popeye-cli 1.4.7 → 1.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 (134) hide show
  1. package/README.md +222 -63
  2. package/dist/adapters/gemini.d.ts +1 -0
  3. package/dist/adapters/gemini.d.ts.map +1 -1
  4. package/dist/adapters/gemini.js +9 -4
  5. package/dist/adapters/gemini.js.map +1 -1
  6. package/dist/adapters/grok.d.ts +1 -0
  7. package/dist/adapters/grok.d.ts.map +1 -1
  8. package/dist/adapters/grok.js +9 -4
  9. package/dist/adapters/grok.js.map +1 -1
  10. package/dist/adapters/openai.d.ts +1 -1
  11. package/dist/adapters/openai.d.ts.map +1 -1
  12. package/dist/adapters/openai.js +35 -9
  13. package/dist/adapters/openai.js.map +1 -1
  14. package/dist/cli/interactive.d.ts.map +1 -1
  15. package/dist/cli/interactive.js +42 -0
  16. package/dist/cli/interactive.js.map +1 -1
  17. package/dist/generators/all.d.ts +4 -1
  18. package/dist/generators/all.d.ts.map +1 -1
  19. package/dist/generators/all.js +2 -1
  20. package/dist/generators/all.js.map +1 -1
  21. package/dist/generators/doc-parser.d.ts +49 -0
  22. package/dist/generators/doc-parser.d.ts.map +1 -0
  23. package/dist/generators/doc-parser.js +336 -0
  24. package/dist/generators/doc-parser.js.map +1 -0
  25. package/dist/generators/templates/index.d.ts +4 -0
  26. package/dist/generators/templates/index.d.ts.map +1 -1
  27. package/dist/generators/templates/index.js +4 -0
  28. package/dist/generators/templates/index.js.map +1 -1
  29. package/dist/generators/templates/website-components.d.ts +33 -0
  30. package/dist/generators/templates/website-components.d.ts.map +1 -0
  31. package/dist/generators/templates/website-components.js +278 -0
  32. package/dist/generators/templates/website-components.js.map +1 -0
  33. package/dist/generators/templates/website-config.d.ts +41 -0
  34. package/dist/generators/templates/website-config.d.ts.map +1 -0
  35. package/dist/generators/templates/website-config.js +283 -0
  36. package/dist/generators/templates/website-config.js.map +1 -0
  37. package/dist/generators/templates/website-conversion.d.ts +27 -0
  38. package/dist/generators/templates/website-conversion.d.ts.map +1 -0
  39. package/dist/generators/templates/website-conversion.js +326 -0
  40. package/dist/generators/templates/website-conversion.js.map +1 -0
  41. package/dist/generators/templates/website-seo.d.ts +76 -0
  42. package/dist/generators/templates/website-seo.d.ts.map +1 -0
  43. package/dist/generators/templates/website-seo.js +326 -0
  44. package/dist/generators/templates/website-seo.js.map +1 -0
  45. package/dist/generators/templates/website.d.ts +14 -47
  46. package/dist/generators/templates/website.d.ts.map +1 -1
  47. package/dist/generators/templates/website.js +412 -499
  48. package/dist/generators/templates/website.js.map +1 -1
  49. package/dist/generators/website-context.d.ts +83 -0
  50. package/dist/generators/website-context.d.ts.map +1 -0
  51. package/dist/generators/website-context.js +190 -0
  52. package/dist/generators/website-context.js.map +1 -0
  53. package/dist/generators/website.d.ts +3 -0
  54. package/dist/generators/website.d.ts.map +1 -1
  55. package/dist/generators/website.js +73 -10
  56. package/dist/generators/website.js.map +1 -1
  57. package/dist/state/index.d.ts +27 -0
  58. package/dist/state/index.d.ts.map +1 -1
  59. package/dist/state/index.js +30 -0
  60. package/dist/state/index.js.map +1 -1
  61. package/dist/types/consensus.d.ts +3 -0
  62. package/dist/types/consensus.d.ts.map +1 -1
  63. package/dist/types/consensus.js +1 -0
  64. package/dist/types/consensus.js.map +1 -1
  65. package/dist/types/website-strategy.d.ts +263 -0
  66. package/dist/types/website-strategy.d.ts.map +1 -0
  67. package/dist/types/website-strategy.js +105 -0
  68. package/dist/types/website-strategy.js.map +1 -0
  69. package/dist/types/workflow.d.ts +15 -0
  70. package/dist/types/workflow.d.ts.map +1 -1
  71. package/dist/types/workflow.js +6 -0
  72. package/dist/types/workflow.js.map +1 -1
  73. package/dist/workflow/consensus.d.ts.map +1 -1
  74. package/dist/workflow/consensus.js +2 -0
  75. package/dist/workflow/consensus.js.map +1 -1
  76. package/dist/workflow/execution-mode.d.ts.map +1 -1
  77. package/dist/workflow/execution-mode.js +18 -0
  78. package/dist/workflow/execution-mode.js.map +1 -1
  79. package/dist/workflow/index.d.ts +3 -0
  80. package/dist/workflow/index.d.ts.map +1 -1
  81. package/dist/workflow/index.js +25 -0
  82. package/dist/workflow/index.js.map +1 -1
  83. package/dist/workflow/overview.d.ts +89 -0
  84. package/dist/workflow/overview.d.ts.map +1 -0
  85. package/dist/workflow/overview.js +354 -0
  86. package/dist/workflow/overview.js.map +1 -0
  87. package/dist/workflow/plan-mode.d.ts +2 -1
  88. package/dist/workflow/plan-mode.d.ts.map +1 -1
  89. package/dist/workflow/plan-mode.js +83 -5
  90. package/dist/workflow/plan-mode.js.map +1 -1
  91. package/dist/workflow/website-strategy.d.ts +70 -0
  92. package/dist/workflow/website-strategy.d.ts.map +1 -0
  93. package/dist/workflow/website-strategy.js +238 -0
  94. package/dist/workflow/website-strategy.js.map +1 -0
  95. package/dist/workflow/website-updater.d.ts +17 -0
  96. package/dist/workflow/website-updater.d.ts.map +1 -0
  97. package/dist/workflow/website-updater.js +105 -0
  98. package/dist/workflow/website-updater.js.map +1 -0
  99. package/dist/workflow/workflow-logger.d.ts +1 -1
  100. package/dist/workflow/workflow-logger.d.ts.map +1 -1
  101. package/dist/workflow/workflow-logger.js.map +1 -1
  102. package/package.json +1 -1
  103. package/src/adapters/gemini.ts +10 -4
  104. package/src/adapters/grok.ts +10 -4
  105. package/src/adapters/openai.ts +38 -6
  106. package/src/cli/interactive.ts +47 -0
  107. package/src/generators/all.ts +6 -1
  108. package/src/generators/doc-parser.ts +372 -0
  109. package/src/generators/templates/index.ts +4 -0
  110. package/src/generators/templates/website-components.ts +305 -0
  111. package/src/generators/templates/website-config.ts +291 -0
  112. package/src/generators/templates/website-conversion.ts +341 -0
  113. package/src/generators/templates/website-seo.ts +370 -0
  114. package/src/generators/templates/website.ts +451 -505
  115. package/src/generators/website-context.ts +265 -0
  116. package/src/generators/website.ts +109 -19
  117. package/src/state/index.ts +42 -0
  118. package/src/types/consensus.ts +3 -0
  119. package/src/types/website-strategy.ts +243 -0
  120. package/src/types/workflow.ts +15 -0
  121. package/src/workflow/consensus.ts +2 -0
  122. package/src/workflow/execution-mode.ts +21 -0
  123. package/src/workflow/index.ts +25 -0
  124. package/src/workflow/overview.ts +469 -0
  125. package/src/workflow/plan-mode.ts +115 -4
  126. package/src/workflow/website-strategy.ts +305 -0
  127. package/src/workflow/website-updater.ts +131 -0
  128. package/src/workflow/workflow-logger.ts +1 -0
  129. package/tests/adapters/persona-switching.test.ts +63 -0
  130. package/tests/generators/website-components.test.ts +159 -0
  131. package/tests/generators/website-context.test.ts +222 -0
  132. package/tests/generators/website-seo-quality.test.ts +246 -0
  133. package/tests/workflow/overview.test.ts +392 -0
  134. package/tests/workflow/website-strategy.test.ts +191 -0
@@ -0,0 +1,326 @@
1
+ /**
2
+ * SEO infrastructure templates for Next.js marketing websites
3
+ * Generates JSON-LD components, enhanced sitemap, robots.txt,
4
+ * error pages, web manifest, and meta helpers
5
+ */
6
+ /**
7
+ * Escape a string for safe use inside JSX template literals
8
+ */
9
+ function escapeJsx(str) {
10
+ return str
11
+ .replace(/\\/g, '\\\\')
12
+ .replace(/'/g, "\\'")
13
+ .replace(/`/g, '\\`')
14
+ .replace(/\$/g, '\\$');
15
+ }
16
+ /**
17
+ * Generate reusable JSON-LD component
18
+ *
19
+ * @returns JsonLd component source code
20
+ */
21
+ export function generateJsonLdComponent() {
22
+ return `/**
23
+ * Reusable JSON-LD structured data component
24
+ * Renders schema.org structured data as a script tag
25
+ */
26
+
27
+ interface JsonLdProps {
28
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
29
+ schema: Record<string, any>;
30
+ }
31
+
32
+ export default function JsonLd({ schema }: JsonLdProps) {
33
+ return (
34
+ <script
35
+ type="application/ld+json"
36
+ dangerouslySetInnerHTML={{ __html: JSON.stringify(schema) }}
37
+ />
38
+ );
39
+ }
40
+ `;
41
+ }
42
+ /**
43
+ * Generate Organization JSON-LD schema data
44
+ *
45
+ * @param projectName - Product name
46
+ * @param context - Optional content context
47
+ * @returns Organization schema as string constant
48
+ */
49
+ export function generateOrganizationJsonLd(projectName, context) {
50
+ const displayName = context?.productName || projectName;
51
+ const description = context?.description || `${displayName} - Modern web application`;
52
+ return `{
53
+ "@context": "https://schema.org",
54
+ "@type": "Organization",
55
+ "name": "${escapeJsx(displayName)}",
56
+ "description": "${escapeJsx(description)}",
57
+ "url": process.env.NEXT_PUBLIC_SITE_URL || "https://${projectName}.com"
58
+ }`;
59
+ }
60
+ /**
61
+ * Generate SoftwareApplication JSON-LD schema data
62
+ *
63
+ * @param projectName - Product name
64
+ * @param context - Optional content context
65
+ * @returns Software application schema as string constant
66
+ */
67
+ export function generateProductJsonLd(projectName, context) {
68
+ const displayName = context?.productName || projectName;
69
+ const description = context?.description || `${displayName} - Modern web application`;
70
+ return `{
71
+ "@context": "https://schema.org",
72
+ "@type": "SoftwareApplication",
73
+ "name": "${escapeJsx(displayName)}",
74
+ "description": "${escapeJsx(description)}",
75
+ "applicationCategory": "BusinessApplication",
76
+ "operatingSystem": "Web",
77
+ "url": process.env.NEXT_PUBLIC_SITE_URL || "https://${projectName}.com"
78
+ }`;
79
+ }
80
+ /**
81
+ * Generate enhanced sitemap with all strategy pages
82
+ *
83
+ * @param projectName - Project name for base URL fallback
84
+ * @param strategy - Optional strategy for page list
85
+ * @returns Enhanced sitemap.ts source code
86
+ */
87
+ export function generateEnhancedSitemap(projectName, strategy) {
88
+ // Build page entries from strategy or defaults
89
+ const pages = strategy?.siteArchitecture.pages || [
90
+ { path: '/', pageType: 'landing' },
91
+ { path: '/pricing', pageType: 'pricing' },
92
+ { path: '/docs', pageType: 'docs' },
93
+ { path: '/blog', pageType: 'blog' },
94
+ ];
95
+ const priorityMap = {
96
+ landing: 1.0,
97
+ pricing: 0.9,
98
+ solution: 0.8,
99
+ 'use-cases': 0.8,
100
+ docs: 0.7,
101
+ blog: 0.7,
102
+ about: 0.6,
103
+ contact: 0.6,
104
+ legal: 0.3,
105
+ };
106
+ const frequencyMap = {
107
+ landing: 'weekly',
108
+ pricing: 'monthly',
109
+ solution: 'monthly',
110
+ 'use-cases': 'monthly',
111
+ docs: 'weekly',
112
+ blog: 'daily',
113
+ about: 'monthly',
114
+ contact: 'monthly',
115
+ legal: 'yearly',
116
+ };
117
+ const entries = pages.map(page => {
118
+ const priority = priorityMap[page.pageType] || 0.5;
119
+ const frequency = frequencyMap[page.pageType] || 'monthly';
120
+ const urlPath = page.path === '/' ? '' : page.path;
121
+ return ` {
122
+ url: \`\${baseUrl}${urlPath}\`,
123
+ lastModified: new Date(),
124
+ changeFrequency: '${frequency}' as const,
125
+ priority: ${priority},
126
+ }`;
127
+ });
128
+ return `import { MetadataRoute } from 'next';
129
+
130
+ export default function sitemap(): MetadataRoute.Sitemap {
131
+ const baseUrl = process.env.NEXT_PUBLIC_SITE_URL || 'https://${projectName}.com';
132
+
133
+ return [
134
+ ${entries.join(',\n')}
135
+ ];
136
+ }
137
+ `;
138
+ }
139
+ /**
140
+ * Generate enhanced robots.txt
141
+ *
142
+ * @param projectName - Project name for base URL fallback
143
+ * @returns robots.ts source code
144
+ */
145
+ export function generateEnhancedRobots(projectName) {
146
+ return `import { MetadataRoute } from 'next';
147
+
148
+ export default function robots(): MetadataRoute.Robots {
149
+ const baseUrl = process.env.NEXT_PUBLIC_SITE_URL || 'https://${projectName}.com';
150
+
151
+ return {
152
+ rules: [
153
+ {
154
+ userAgent: '*',
155
+ allow: '/',
156
+ disallow: ['/api/', '/admin/', '/_next/'],
157
+ },
158
+ ],
159
+ sitemap: \`\${baseUrl}/sitemap.xml\`,
160
+ };
161
+ }
162
+ `;
163
+ }
164
+ /**
165
+ * Generate branded 404 Not Found page
166
+ *
167
+ * @param projectName - Product name for branding
168
+ * @param context - Optional content context
169
+ * @returns not-found.tsx source code
170
+ */
171
+ export function generate404Page(projectName, context) {
172
+ const displayName = context?.productName || projectName
173
+ .split('-')
174
+ .map((w) => w.charAt(0).toUpperCase() + w.slice(1))
175
+ .join(' ');
176
+ return `import Link from 'next/link';
177
+
178
+ export default function NotFound() {
179
+ return (
180
+ <main className="flex min-h-[60vh] flex-col items-center justify-center">
181
+ <div className="text-center">
182
+ <p className="text-7xl font-bold text-primary-600">404</p>
183
+ <h1 className="mt-4 text-3xl font-bold text-gray-900">Page not found</h1>
184
+ <p className="mt-4 text-lg text-gray-600">
185
+ Sorry, we couldn&apos;t find the page you&apos;re looking for.
186
+ </p>
187
+ <div className="mt-8">
188
+ <Link
189
+ href="/"
190
+ className="rounded-md bg-primary-600 px-6 py-3 text-sm font-semibold text-white shadow-sm hover:bg-primary-500"
191
+ >
192
+ Back to ${escapeJsx(displayName)}
193
+ </Link>
194
+ </div>
195
+ </div>
196
+ </main>
197
+ );
198
+ }
199
+ `;
200
+ }
201
+ /**
202
+ * Generate error boundary page (500)
203
+ *
204
+ * @param projectName - Product name for branding
205
+ * @returns error.tsx source code
206
+ */
207
+ export function generate500Page(_projectName) {
208
+ return `'use client';
209
+
210
+ export default function Error({
211
+ reset,
212
+ }: {
213
+ error: Error & { digest?: string };
214
+ reset: () => void;
215
+ }) {
216
+ return (
217
+ <main className="flex min-h-[60vh] flex-col items-center justify-center">
218
+ <div className="text-center">
219
+ <p className="text-7xl font-bold text-red-600">500</p>
220
+ <h1 className="mt-4 text-3xl font-bold text-gray-900">Something went wrong</h1>
221
+ <p className="mt-4 text-lg text-gray-600">
222
+ An unexpected error occurred. Please try again.
223
+ </p>
224
+ <div className="mt-8">
225
+ <button
226
+ onClick={() => reset()}
227
+ className="rounded-md bg-primary-600 px-6 py-3 text-sm font-semibold text-white shadow-sm hover:bg-primary-500"
228
+ >
229
+ Try again
230
+ </button>
231
+ </div>
232
+ </div>
233
+ </main>
234
+ );
235
+ }
236
+ `;
237
+ }
238
+ /**
239
+ * Generate PWA web manifest
240
+ *
241
+ * @param projectName - Product name
242
+ * @param context - Optional content context
243
+ * @returns manifest.webmanifest JSON content
244
+ */
245
+ export function generateWebManifest(projectName, context) {
246
+ const displayName = context?.productName || projectName
247
+ .split('-')
248
+ .map((w) => w.charAt(0).toUpperCase() + w.slice(1))
249
+ .join(' ');
250
+ const primaryColor = context?.brand?.primaryColor || '#0ea5e9';
251
+ const description = context?.description || `${displayName} - Modern web application`;
252
+ return JSON.stringify({
253
+ name: displayName,
254
+ short_name: displayName,
255
+ description,
256
+ start_url: '/',
257
+ display: 'standalone',
258
+ background_color: '#ffffff',
259
+ theme_color: primaryColor,
260
+ icons: [
261
+ { src: '/favicon.ico', sizes: '48x48', type: 'image/x-icon' },
262
+ { src: '/icon-192.png', sizes: '192x192', type: 'image/png' },
263
+ { src: '/icon-512.png', sizes: '512x512', type: 'image/png' },
264
+ ],
265
+ }, null, 2);
266
+ }
267
+ /**
268
+ * Generate shared metadata helper utility
269
+ *
270
+ * @param projectName - Product name
271
+ * @param strategy - Optional strategy for SEO data
272
+ * @returns Metadata helper source code
273
+ */
274
+ export function generateMetaHelper(projectName, strategy) {
275
+ const primaryKeywords = strategy?.seoStrategy.primaryKeywords || [projectName, 'web app'];
276
+ const keywordsStr = primaryKeywords.map(k => `'${escapeJsx(k)}'`).join(', ');
277
+ return `import type { Metadata } from 'next';
278
+
279
+ const BASE_URL = process.env.NEXT_PUBLIC_SITE_URL || 'https://${projectName}.com';
280
+
281
+ /**
282
+ * Build page-level metadata with site-wide defaults
283
+ *
284
+ * @param title - Page title (combined with site name via template)
285
+ * @param description - Page meta description
286
+ * @param keywords - Additional page-specific keywords
287
+ * @param path - Page path for canonical URL
288
+ * @returns Next.js Metadata object
289
+ */
290
+ export function buildMetadata({
291
+ title,
292
+ description,
293
+ keywords = [],
294
+ path = '/',
295
+ }: {
296
+ title: string;
297
+ description: string;
298
+ keywords?: string[];
299
+ path?: string;
300
+ }): Metadata {
301
+ const url = \`\${BASE_URL}\${path}\`;
302
+ const allKeywords = [...new Set([${keywordsStr}, ...keywords])];
303
+
304
+ return {
305
+ title,
306
+ description,
307
+ keywords: allKeywords,
308
+ alternates: {
309
+ canonical: url,
310
+ },
311
+ openGraph: {
312
+ title,
313
+ description,
314
+ url,
315
+ type: 'website',
316
+ },
317
+ twitter: {
318
+ card: 'summary_large_image',
319
+ title,
320
+ description,
321
+ },
322
+ };
323
+ }
324
+ `;
325
+ }
326
+ //# sourceMappingURL=website-seo.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"website-seo.js","sourceRoot":"","sources":["../../../src/generators/templates/website-seo.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAKH;;GAEG;AACH,SAAS,SAAS,CAAC,GAAW;IAC5B,OAAO,GAAG;SACP,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC;SACtB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;AAC3B,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,uBAAuB;IACrC,OAAO;;;;;;;;;;;;;;;;;;CAkBR,CAAC;AACF,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,0BAA0B,CACxC,WAAmB,EACnB,OAA+B;IAE/B,MAAM,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,WAAW,CAAC;IACxD,MAAM,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,GAAG,WAAW,2BAA2B,CAAC;IAEtF,OAAO;;;aAGI,SAAS,CAAC,WAAW,CAAC;oBACf,SAAS,CAAC,WAAW,CAAC;wDACc,WAAW;EACjE,CAAC;AACH,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,qBAAqB,CACnC,WAAmB,EACnB,OAA+B;IAE/B,MAAM,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,WAAW,CAAC;IACxD,MAAM,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,GAAG,WAAW,2BAA2B,CAAC;IAEtF,OAAO;;;aAGI,SAAS,CAAC,WAAW,CAAC;oBACf,SAAS,CAAC,WAAW,CAAC;;;wDAGc,WAAW;EACjE,CAAC;AACH,CAAC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;IAEb,MAAM,YAAY,GAAG,OAAO,EAAE,KAAK,EAAE,YAAY,IAAI,SAAS,CAAC;IAC/D,MAAM,WAAW,GAAG,OAAO,EAAE,WAAW,IAAI,GAAG,WAAW,2BAA2B,CAAC;IAEtF,OAAO,IAAI,CAAC,SAAS,CACnB;QACE,IAAI,EAAE,WAAW;QACjB,UAAU,EAAE,WAAW;QACvB,WAAW;QACX,SAAS,EAAE,GAAG;QACd,OAAO,EAAE,YAAY;QACrB,gBAAgB,EAAE,SAAS;QAC3B,WAAW,EAAE,YAAY;QACzB,KAAK,EAAE;YACL,EAAE,GAAG,EAAE,cAAc,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE;YAC7D,EAAE,GAAG,EAAE,eAAe,EAAE,KAAK,EAAE,SAAS,EAAE,IAAI,EAAE,WAAW,EAAE;YAC7D,EAAE,GAAG,EAAE,eAAe,EAAE,KAAK,EAAE,SAAS,EAAE,IAAI,EAAE,WAAW,EAAE;SAC9D;KACF,EACD,IAAI,EACJ,CAAC,CACF,CAAC;AACJ,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,kBAAkB,CAChC,WAAmB,EACnB,QAAkC;IAElC,MAAM,eAAe,GAAG,QAAQ,EAAE,WAAW,CAAC,eAAe,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;IAC1F,MAAM,WAAW,GAAG,eAAe,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAE7E,OAAO;;gEAEuD,WAAW;;;;;;;;;;;;;;;;;;;;;;;qCAuBtC,WAAW;;;;;;;;;;;;;;;;;;;;;;CAsB/C,CAAC;AACF,CAAC"}
@@ -1,43 +1,26 @@
1
1
  /**
2
- * Website templates for Next.js marketing sites
3
- * Generates SEO-ready Next.js App Router projects
2
+ * Website content templates for Next.js marketing sites
3
+ * Generates SEO-ready content pages with optional project context
4
+ * and strategy-driven marketing content
4
5
  */
5
- /**
6
- * Generate Next.js package.json
7
- */
8
- export declare function generateWebsitePackageJson(projectName: string): string;
9
- /**
10
- * Generate Next.js config
11
- */
12
- export declare function generateNextConfig(): string;
13
- /**
14
- * Generate website tsconfig.json
15
- */
16
- export declare function generateWebsiteTsconfig(): string;
17
- /**
18
- * Generate Tailwind config for website
19
- */
20
- export declare function generateWebsiteTailwindConfig(): string;
21
- /**
22
- * Generate PostCSS config for website
23
- */
24
- export declare function generateWebsitePostcssConfig(): string;
6
+ import type { WebsiteContentContext } from '../website-context.js';
25
7
  /**
26
8
  * Generate root layout.tsx with metadata
27
9
  */
28
- export declare function generateWebsiteLayout(projectName: string): string;
10
+ export declare function generateWebsiteLayout(projectName: string, context?: WebsiteContentContext): string;
29
11
  /**
30
- * Generate globals.css
12
+ * Generate globals.css with optional brand colors
31
13
  */
32
- export declare function generateWebsiteGlobalsCss(): string;
14
+ export declare function generateWebsiteGlobalsCss(context?: WebsiteContentContext): string;
33
15
  /**
34
- * Generate landing page.tsx
16
+ * Generate landing page.tsx with optional context-driven content
17
+ * When strategy is available, uses strategy messaging, trust signals, and CTAs
35
18
  */
36
- export declare function generateWebsiteLandingPage(projectName: string): string;
19
+ export declare function generateWebsiteLandingPage(projectName: string, context?: WebsiteContentContext): string;
37
20
  /**
38
- * Generate pricing page
21
+ * Generate pricing page with optional context-driven tiers and FAQ
39
22
  */
40
- export declare function generateWebsitePricingPage(projectName: string): string;
23
+ export declare function generateWebsitePricingPage(projectName: string, context?: WebsiteContentContext): string;
41
24
  /**
42
25
  * Generate sitemap.ts
43
26
  */
@@ -46,26 +29,14 @@ export declare function generateWebsiteSitemap(projectName: string): string;
46
29
  * Generate robots.ts
47
30
  */
48
31
  export declare function generateWebsiteRobots(projectName: string): string;
49
- /**
50
- * Generate website Dockerfile
51
- */
52
- export declare function generateWebsiteDockerfile(): string;
53
32
  /**
54
33
  * Generate website README
55
34
  */
56
35
  export declare function generateWebsiteReadme(projectName: string): string;
57
36
  /**
58
- * Generate website spec JSON
59
- */
60
- export declare function generateWebsiteSpec(projectName: string): string;
61
- /**
62
- * Generate vitest config for website
37
+ * Generate website spec JSON with optional context
63
38
  */
64
- export declare function generateWebsiteVitestConfig(): string;
65
- /**
66
- * Generate vitest setup for website
67
- */
68
- export declare function generateWebsiteVitestSetup(): string;
39
+ export declare function generateWebsiteSpec(projectName: string, context?: WebsiteContentContext): string;
69
40
  /**
70
41
  * Generate sample test for website
71
42
  */
@@ -78,8 +49,4 @@ export declare function generateWebsiteDocsPage(): string;
78
49
  * Generate blog listing page placeholder
79
50
  */
80
51
  export declare function generateWebsiteBlogPage(): string;
81
- /**
82
- * Generate Next.js environment declaration
83
- */
84
- export declare function generateWebsiteNextEnv(): string;
85
52
  //# sourceMappingURL=website.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"website.d.ts","sourceRoot":"","sources":["../../../src/generators/templates/website.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAqCtE;AAED;;GAEG;AACH,wBAAgB,kBAAkB,IAAI,MAAM,CAwC3C;AAED;;GAEG;AACH,wBAAgB,uBAAuB,IAAI,MAAM,CA6BhD;AAED;;GAEG;AACH,wBAAgB,6BAA6B,IAAI,MAAM,CAmCtD;AAED;;GAEG;AACH,wBAAgB,4BAA4B,IAAI,MAAM,CAQrD;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAyDjE;AAED;;GAEG;AACH,wBAAgB,yBAAyB,IAAI,MAAM,CAwBlD;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAoGtE;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAmJtE;AAED;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAkClE;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAkBjE;AAED;;GAEG;AACH,wBAAgB,yBAAyB,IAAI,MAAM,CA4ClD;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CA0DjE;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAkD/D;AAED;;GAEG;AACH,wBAAgB,2BAA2B,IAAI,MAAM,CAoBpD;AAED;;GAEG;AACH,wBAAgB,0BAA0B,IAAI,MAAM,CAsBnD;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CA8B/D;AAED;;GAEG;AACH,wBAAgB,uBAAuB,IAAI,MAAM,CAqBhD;AAED;;GAEG;AACH,wBAAgB,uBAAuB,IAAI,MAAM,CAqBhD;AAED;;GAEG;AACH,wBAAgB,sBAAsB,IAAI,MAAM,CAO/C"}
1
+ {"version":3,"file":"website.d.ts","sourceRoot":"","sources":["../../../src/generators/templates/website.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAGnE;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,qBAAqB,GAC9B,MAAM,CAuER;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CACvC,OAAO,CAAC,EAAE,qBAAqB,GAC9B,MAAM,CA6BR;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,qBAAqB,GAC9B,MAAM,CAkNR;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CACxC,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,qBAAqB,GAC9B,MAAM,CA8LR;AAED;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAkClE;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAkBjE;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CA0DjE;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CACjC,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,qBAAqB,GAC9B,MAAM,CAsDR;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAuB/D;AAED;;GAEG;AACH,wBAAgB,uBAAuB,IAAI,MAAM,CAqBhD;AAED;;GAEG;AACH,wBAAgB,uBAAuB,IAAI,MAAM,CAqBhD"}