@forgewp/compiler 0.4.2 → 0.4.4

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 (144) hide show
  1. package/README.md +70 -3
  2. package/bin/add.js +30 -15
  3. package/bin/analyze.js +66 -1
  4. package/bin/cli.js +149 -70
  5. package/bin/doctor.js +21 -12
  6. package/bin/export.js +69 -20
  7. package/bin/fresh.js +6 -1
  8. package/bin/i18n-extract.js +3 -10
  9. package/bin/i18n-translate.js +15 -24
  10. package/bin/make-block.js +24 -0
  11. package/bin/make-editable.js +166 -0
  12. package/bin/make-form.js +131 -0
  13. package/bin/make-island.js +11 -0
  14. package/bin/make-loop.js +147 -0
  15. package/bin/make-mail.js +27 -0
  16. package/bin/make-page.js +83 -0
  17. package/bin/make-post-type.js +68 -29
  18. package/bin/make-sandbox.js +609 -0
  19. package/bin/make-section.js +221 -0
  20. package/bin/make-shell.js +375 -0
  21. package/bin/repair.js +14 -26
  22. package/bin/seed.js +119 -0
  23. package/bin/sync-routes.js +107 -85
  24. package/lib/adapters/html-adapter.js +13 -3
  25. package/lib/adapters/stub-adapter.js +10 -2
  26. package/lib/add-component.js +153 -92
  27. package/lib/asset-loader.js +333 -1
  28. package/lib/assets/asset-graph.js +432 -0
  29. package/lib/assets/asset-pipeline.js +125 -0
  30. package/lib/assets/diagnostics-report.js +345 -0
  31. package/lib/assets/external-fetcher.js +173 -0
  32. package/lib/assets/font-orchestrator.js +348 -0
  33. package/lib/assets/font-usage-scanner.js +242 -0
  34. package/lib/assets/image-optimizer.js +229 -0
  35. package/lib/assets/index.js +51 -0
  36. package/lib/assets/preload-generator.js +70 -0
  37. package/lib/assets/public-url.js +153 -0
  38. package/lib/block-authoring-help.js +11 -0
  39. package/lib/blocks/ast-parser.js +67 -0
  40. package/lib/blocks/discover-blocks.js +146 -0
  41. package/lib/blocks/editor-scope.js +733 -0
  42. package/lib/blocks/editor-transpiler.js +1229 -0
  43. package/lib/blocks/index.js +2838 -0
  44. package/lib/blocks/php-transpiler.js +4928 -0
  45. package/lib/blocks/scanner.js +1487 -0
  46. package/lib/blocks/shared-utils.js +290 -0
  47. package/lib/blocks/source-sanitize.js +1449 -0
  48. package/lib/blueprints.js +77 -5
  49. package/lib/build-assets.js +38 -33
  50. package/lib/collect-page-template-routes.js +102 -0
  51. package/lib/collect-static-routes.js +175 -0
  52. package/lib/diagnostics.js +58 -33
  53. package/lib/export-theme.js +84 -5
  54. package/lib/extract-template-content.js +90 -0
  55. package/lib/forms-preview.js +42 -0
  56. package/lib/functions/cpt-routing.js +69 -0
  57. package/lib/functions/forms.js +2461 -0
  58. package/lib/functions/hydration-enqueuer.js +400 -0
  59. package/lib/functions/index.js +1623 -0
  60. package/lib/functions/load-menus.js +112 -0
  61. package/lib/functions/load-translations.js +148 -0
  62. package/lib/functions/rest-endpoints.js +2923 -0
  63. package/lib/functions/routing.js +765 -0
  64. package/lib/functions/seed-mock-data.js +392 -0
  65. package/lib/functions/seed-products.js +481 -0
  66. package/lib/functions/settings-page.js +273 -0
  67. package/lib/functions/theme-setup.js +494 -0
  68. package/lib/generate-theme.js +2076 -303
  69. package/lib/hydration/editable-schemas.js +332 -0
  70. package/lib/hydration/enter-hidden-initial.js +65 -0
  71. package/lib/hydration/form-schemas.js +227 -0
  72. package/lib/hydration/index.js +12 -0
  73. package/lib/hydration/is-interactive.js +951 -0
  74. package/lib/hydration/island-split.js +1231 -0
  75. package/lib/hydration/islands-scanner.js +599 -0
  76. package/lib/hydration/resolve-island-chunk.js +103 -0
  77. package/lib/hydration/resolve-island-component.js +52 -0
  78. package/lib/hydration/rollup-inputs.js +81 -0
  79. package/lib/hydration/root-class-extractor.js +220 -0
  80. package/lib/hydration/scan-app-providers.js +154 -0
  81. package/lib/hydration/static-lint.js +382 -0
  82. package/lib/hydration/transform.js +257 -0
  83. package/lib/hydration/uses-block-area.js +49 -0
  84. package/lib/hydration/utils.js +119 -0
  85. package/lib/i18n/translation-cache.js +141 -0
  86. package/lib/icon-registry.js +72 -0
  87. package/lib/index.d.ts +324 -8
  88. package/lib/index.js +3 -2
  89. package/lib/load-config.js +338 -144
  90. package/lib/mail-templates.js +37 -0
  91. package/lib/markup-processor.js +483 -92
  92. package/lib/node-runtime.js +7 -0
  93. package/lib/page-config-plugin.js +84 -0
  94. package/lib/php-builders.js +383 -42
  95. package/lib/react-adapter.js +1053 -246
  96. package/lib/registration-metadata.js +11 -0
  97. package/lib/render-theme.mts +1410 -543
  98. package/lib/route-layout.js +76 -0
  99. package/lib/template-discovery.js +58 -0
  100. package/lib/theme-compatibility.js +32 -0
  101. package/lib/validate-export.js +51 -2
  102. package/lib/validate.js +27 -5
  103. package/lib/virtual-plugin.js +319 -0
  104. package/lib/walkthrough.md +26 -0
  105. package/package.json +17 -5
  106. package/templates/PresetsStyle.tsx +1 -1
  107. package/templates/auth/cms/email-logs.json +9 -0
  108. package/templates/auth/cms/menus.json +11 -0
  109. package/templates/auth/cms/mock-data.json +123 -0
  110. package/templates/auth/cms/roles.json +7 -0
  111. package/templates/auth/cms/sessions.json +1 -0
  112. package/templates/auth/cms/site-settings.json +28 -0
  113. package/templates/auth/cms/translations.json +4 -0
  114. package/templates/auth/cms/users.json +46 -0
  115. package/templates/auth/components/dashboard-view-wrapper.tsx +168 -0
  116. package/templates/auth/components/forgot-password-form-wrapper.tsx +141 -0
  117. package/templates/auth/components/login-form-wrapper.tsx +300 -0
  118. package/templates/auth/components/reset-password-form-wrapper.tsx +190 -0
  119. package/templates/auth/components/signup-form-wrapper.tsx +257 -0
  120. package/templates/auth/components/verify-email-view-wrapper.tsx +265 -0
  121. package/templates/auth/pages/DashboardPage.tsx +12 -0
  122. package/templates/auth/pages/ForgotPasswordPage.tsx +11 -0
  123. package/templates/auth/pages/LoginPage.tsx +11 -0
  124. package/templates/auth/pages/ResetPasswordPage.tsx +11 -0
  125. package/templates/auth/pages/SignUpPage.tsx +11 -0
  126. package/templates/auth/pages/VerifyEmailPage.tsx +11 -0
  127. package/templates/auth/ui/button.tsx +57 -0
  128. package/templates/auth/ui/card.tsx +76 -0
  129. package/templates/auth/ui/field.tsx +242 -0
  130. package/templates/auth/ui/input.tsx +22 -0
  131. package/templates/auth/ui/label.tsx +24 -0
  132. package/templates/auth/ui/separator.tsx +31 -0
  133. package/templates/forgewp-config.ts +70 -3
  134. package/templates/menus.json +12 -10
  135. package/templates/mock-data.json +122 -433
  136. package/templates/products.json +5 -0
  137. package/templates/roles.json +7 -0
  138. package/templates/sessions.json +1 -0
  139. package/templates/users.json +38 -0
  140. package/templates/wordpress.tsx +1835 -1297
  141. package/bin/make-template.js +0 -145
  142. package/lib/block-compiler.js +0 -552
  143. package/lib/functions-builder.js +0 -2044
  144. package/lib/hydration-scanner.js +0 -821
package/bin/seed.js ADDED
@@ -0,0 +1,119 @@
1
+ #!/usr/bin/env node
2
+
3
+ import fs from 'node:fs';
4
+ import path from 'node:path';
5
+ import pc from 'picocolors';
6
+ import { loadProductsData } from '../lib/functions/seed-products.js';
7
+ import { loadMockData, normalizeMockSeedData } from '../lib/functions/seed-mock-data.js';
8
+ import { loadConfig } from '../lib/load-config.js';
9
+
10
+ const projectRoot = process.cwd();
11
+ const args = process.argv.slice(2);
12
+ const target = args[0] || 'all';
13
+
14
+ // Preview only: no configuration writes, export, network request, or database access.
15
+ if (args.includes('--dry-run')) {
16
+ if (args.some((arg) => !['mock-data', 'mock', 'posts', '--dry-run', '--json'].includes(arg))) {
17
+ console.error('Dry-run supports mock-data only: forgewp seed mock-data --dry-run [--json]');
18
+ process.exit(1);
19
+ }
20
+ const config = await loadConfig(projectRoot);
21
+ const raw = loadMockData(projectRoot);
22
+ const seed = config.seed || {};
23
+ const data = normalizeMockSeedData(raw, seed.mockData);
24
+ const strategyMap = seed.mockData && typeof seed.mockData === 'object' ? seed.mockData : null;
25
+ const report = {
26
+ mode: 'preview-only',
27
+ configChanged: false,
28
+ databaseConnected: false,
29
+ developmentOnly: seed.developmentOnly !== false,
30
+ sideloadImages: seed.sideloadImages !== false,
31
+ activation: 'Requires export/install; WordPress debug flag, seed markers, and database state are not inspected.',
32
+ types: Object.entries(raw).map(([postType, entries]) => {
33
+ const strategy = strategyMap ? strategyMap[postType] : seed.mockData;
34
+ return {
35
+ postType,
36
+ fixtureCount: Array.isArray(entries) ? entries.length : 0,
37
+ strategy: data[postType] ? (strategy === true ? 'once' : strategy) : false,
38
+ records: data[postType] || [],
39
+ };
40
+ }),
41
+ };
42
+ if (!args.includes('--json')) console.log('Mock seed preview — no files changed. Disabled types have no seed records.\n');
43
+ console.log(JSON.stringify(report, null, 2));
44
+ process.exit(0);
45
+ }
46
+
47
+ console.log(`\n ${pc.bold(pc.bgGreen(pc.black(' 🌱 FORGEWP DATA SEEDER ')))} ${pc.green('— WordPress & WooCommerce Synchronization')}\n`);
48
+
49
+ const configPath = path.join(projectRoot, 'wp.config.ts');
50
+ if (!fs.existsSync(configPath)) {
51
+ console.error(pc.red(`❌ Error: wp.config.ts not found at ${configPath}`));
52
+ process.exit(1);
53
+ }
54
+
55
+ // 1. Inspect Products
56
+ let productsCount = 0;
57
+ if (target === 'all' || target === 'products' || target === 'product') {
58
+ const products = loadProductsData(projectRoot);
59
+ productsCount = products.length;
60
+ if (productsCount > 0) {
61
+ console.log(` 📦 ${pc.bold('WooCommerce Products')}: Found ${pc.green(productsCount)} item(s) in ${pc.cyan('cms/products.ts')}`);
62
+ } else {
63
+ console.log(` 📦 ${pc.bold('WooCommerce Products')}: No products declared in ${pc.yellow('cms/products.ts')}`);
64
+ }
65
+ }
66
+
67
+ // 2. Inspect Mock Data
68
+ let mockTypesCount = 0;
69
+ let totalMockPosts = 0;
70
+ if (target === 'all' || target === 'mock-data' || target === 'mock' || target === 'posts') {
71
+ const mockData = loadMockData(projectRoot);
72
+ const types = Object.keys(mockData);
73
+ mockTypesCount = types.length;
74
+ if (mockTypesCount > 0) {
75
+ types.forEach((t) => {
76
+ const count = Array.isArray(mockData[t]) ? mockData[t].length : 0;
77
+ totalMockPosts += count;
78
+ console.log(` 📝 ${pc.bold(`Post Type "${t}"`)}: Found ${pc.green(count)} mock entry/entries`);
79
+ });
80
+ } else {
81
+ console.log(` 📝 ${pc.bold('Mock Content')}: No mock content declared in ${pc.yellow('cms/mock-data.ts')}`);
82
+ }
83
+ }
84
+
85
+ // 3. Check wp.config.ts for seed settings
86
+ let configRaw = fs.readFileSync(configPath, 'utf8');
87
+ const hasSeedConfig = configRaw.includes('seed:');
88
+
89
+ if (!hasSeedConfig && (productsCount > 0 || mockTypesCount > 0)) {
90
+ console.log(`\n ⚙️ ${pc.cyan('Enabling data seeding in wp.config.ts')}...`);
91
+ const lines = [' seed: {'];
92
+ if (productsCount > 0) {
93
+ lines.push(" products: 'once',");
94
+ }
95
+ if (mockTypesCount > 0) {
96
+ lines.push(" mockData: 'once',");
97
+ }
98
+ lines.push(' developmentOnly: true,');
99
+ lines.push(' },');
100
+ const seedBlock = lines.join('\n') + '\n';
101
+
102
+ if (configRaw.includes('defineConfig({')) {
103
+ configRaw = configRaw.replace(/defineConfig\(\{/, `defineConfig({\n${seedBlock}`);
104
+ fs.writeFileSync(configPath, configRaw, 'utf8');
105
+ console.log(pc.green(` ✅ Added tailored seed configuration to wp.config.ts`));
106
+ }
107
+ } else if (hasSeedConfig) {
108
+ console.log(`\n ✅ ${pc.bold('wp.config.ts')} has active seed configuration.`);
109
+ }
110
+
111
+ console.log(`
112
+ ${pc.bold('🚀 Synchronization Status:')}
113
+ • Local seed configuration has been inspected. This command has not exported PHP or connected to WordPress.
114
+ • Review wp.config.ts, then export and install the theme to generate its configured seed routines.
115
+ • Automatic execution depends on the configured strategy, WordPress debug guard, and existing seed markers.
116
+ • ${pc.dim('Optional:')} If using WP-CLI, you can also run:
117
+ ${pc.cyan('wp forgewp seed-products')}
118
+ ${pc.cyan('wp forgewp seed-mock-data')}
119
+ `);
@@ -1,113 +1,131 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- import { existsSync, readFileSync, writeFileSync, mkdirSync } from "node:fs";
4
- import path from "node:path";
5
- import pc from "picocolors";
6
- import { loadConfig } from "../lib/load-config.js";
7
- import { loadFrameworkAdapter } from "../lib/framework-adapter.js";
3
+ import { existsSync, writeFileSync, mkdirSync } from 'node:fs';
4
+ import path from 'node:path';
5
+ import pc from 'picocolors';
6
+ import { loadConfig } from '../lib/load-config.js';
7
+ import { loadFrameworkAdapter } from '../lib/framework-adapter.js';
8
+ import { loadMenusData } from '../lib/functions/load-menus.js';
8
9
 
9
- console.log(`\n⚡ ${pc.bold(pc.bgCyan(pc.black(" FORGEWP SITEMAP COMPILER (SYNC:ROUTES) ")))}\n`);
10
+ console.log(
11
+ `\n⚡ ${pc.bold(pc.bgCyan(pc.black(' FORGEWP SITEMAP COMPILER (SYNC:ROUTES) ')))}\n`,
12
+ );
10
13
 
11
14
  const projectRoot = process.cwd();
12
15
  const args = process.argv.slice(2);
13
- const isForce = args.includes("--force") || args.includes("--override");
14
-
15
- // 1. Locate menus configuration file
16
- let menusPath = path.join(projectRoot, "cms", "menus.json");
17
- let menus = null;
18
-
19
- if (!existsSync(menusPath)) {
20
- // Try fallback in mock-data.json
21
- const mockDataPath = path.join(projectRoot, "cms", "mock-data.json");
22
- if (existsSync(mockDataPath)) {
23
- try {
24
- const mockData = JSON.parse(readFileSync(mockDataPath, "utf8"));
25
- if (mockData.menu) {
26
- menus = mockData.menu;
27
- console.log(` ℹ️ Using legacy menus block inside: cms/mock-data.json`);
28
- }
29
- } catch (e) {
30
- // Ignored
31
- }
32
- }
33
- if (!menus) {
34
- menus = {
35
- _comment: "⚡ ForgeWP Navigation Menus — Edit this file to add/remove links in local dev. Run 'pnpm forgewp sync:routes' to auto-scaffold corresponding React pages!",
36
- primary: [
37
- { title: "Home", url: "/" },
38
- { title: "New", url: "/new" },
39
- { title: "Men", url: "/men" },
40
- { title: "Women", url: "/women" }
41
- ],
42
- utility: [
43
- { title: "Help", url: "/help" },
44
- { title: "Sign In", url: "/login" }
45
- ]
46
- };
47
-
48
- const dir = path.dirname(menusPath);
49
- if (!existsSync(dir)) {
50
- mkdirSync(dir, { recursive: true });
51
- }
52
- writeFileSync(menusPath, JSON.stringify(menus, null, 2), "utf8");
53
- console.log(` 🎉 ${pc.green("Created dedicated sitemap source")}: cms/menus.json`);
16
+ const isForce = args.includes('--force') || args.includes('--override');
17
+
18
+ // 1. Locate menus configuration file (cms/menus.ts preferred, cms/menus.json fallback)
19
+ const menusTsPath = path.join(projectRoot, 'cms', 'menus.ts');
20
+ const menusPath = path.join(projectRoot, 'cms', 'menus.json');
21
+ let menus = loadMenusData(projectRoot);
22
+
23
+ const hasMenuLocations = Object.keys(menus).some(
24
+ (k) => !k.startsWith('_') && Array.isArray(menus[k]),
25
+ );
26
+
27
+ if (hasMenuLocations) {
28
+ if (existsSync(menusTsPath)) {
29
+ console.log(` 📖 ${pc.green('Loaded sitemap source')}: cms/menus.ts`);
30
+ } else {
31
+ console.log(` 📖 ${pc.green('Loaded sitemap source')}: cms/menus.json`);
54
32
  }
55
33
  } else {
56
- try {
57
- menus = JSON.parse(readFileSync(menusPath, "utf8"));
58
- console.log(` 📖 ${pc.green("Loaded sitemap source")}: cms/menus.json`);
59
- } catch (err) {
60
- console.error(pc.red(`\n❌ Error: Failed to parse cms/menus.json.\nReason: ${err.message}`));
61
- process.exit(1);
34
+ menus = {
35
+ _comment:
36
+ "⚡ ForgeWP Navigation Menus — Edit this file to add/remove links in local dev. Run 'pnpm forgewp sync:routes' to auto-scaffold corresponding React pages!",
37
+ primary: [
38
+ { title: 'Home', url: '/' },
39
+ { title: 'New', url: '/new' },
40
+ { title: 'Men', url: '/men' },
41
+ { title: 'Women', url: '/women' },
42
+ ],
43
+ utility: [
44
+ { title: 'Help', url: '/help' },
45
+ { title: 'Sign In', url: '/login' },
46
+ ],
47
+ };
48
+
49
+ const dir = path.dirname(menusPath);
50
+ if (!existsSync(dir)) {
51
+ mkdirSync(dir, { recursive: true });
62
52
  }
53
+ writeFileSync(menusPath, JSON.stringify(menus, null, 2), 'utf8');
54
+ console.log(
55
+ ` 🎉 ${pc.green('Created dedicated sitemap source')}: cms/menus.json`,
56
+ );
63
57
  }
64
58
 
65
- // 2. Extract unique local paths and sanitize them
59
+ // 2. Extract unique local paths and sanitize them recursively
66
60
  const routesToScaffold = [];
67
- const seenUrls = new Set(["/", ""]);
61
+ const seenUrls = new Set(['/', '']);
68
62
 
69
- for (const [location, items] of Object.entries(menus)) {
70
- if (!Array.isArray(items)) continue;
63
+ function extractRoutesFromItems(items) {
64
+ if (!Array.isArray(items)) return;
71
65
  for (const item of items) {
72
- if (!item.url || typeof item.url !== "string") continue;
73
- let url = item.url.trim();
74
-
75
- // Skip external, anchors, mailto, etc.
76
- if (
77
- url.startsWith("http://") ||
78
- url.startsWith("https://") ||
79
- url.startsWith("#") ||
80
- url.startsWith("mailto:") ||
81
- url.startsWith("tel:")
82
- ) {
83
- continue;
84
- }
66
+ if (item && item.url && typeof item.url === 'string') {
67
+ let url = item.url.trim();
68
+
69
+ // Skip external, anchors, mailto, etc.
70
+ if (
71
+ !url.startsWith('http://') &&
72
+ !url.startsWith('https://') &&
73
+ !url.startsWith('#') &&
74
+ !url.startsWith('mailto:') &&
75
+ !url.startsWith('tel:')
76
+ ) {
77
+ // Menu fragments navigate within an existing page; they are not pages
78
+ // that should be scaffolded by route synchronization.
79
+ url = url.split(/[?#]/)[0] || '/';
80
+
81
+ // Normalize starting slash
82
+ if (!url.startsWith('/')) {
83
+ url = '/' + url;
84
+ }
85
85
 
86
- // Normalize starting slash
87
- if (!url.startsWith("/")) {
88
- url = "/" + url;
86
+ if (url === '/') {
87
+ if (item && Array.isArray(item.children)) {
88
+ extractRoutesFromItems(item.children);
89
+ }
90
+ continue;
91
+ }
92
+
93
+ if (!seenUrls.has(url)) {
94
+ seenUrls.add(url);
95
+ routesToScaffold.push({
96
+ path: url,
97
+ title: item.title || url.replace('/', ''),
98
+ });
99
+ }
100
+ }
89
101
  }
90
102
 
91
- if (seenUrls.has(url)) continue;
92
- seenUrls.add(url);
103
+ if (item && Array.isArray(item.children)) {
104
+ extractRoutesFromItems(item.children);
105
+ }
106
+ }
107
+ }
93
108
 
94
- routesToScaffold.push({
95
- path: url,
96
- title: item.title || url.replace("/", "")
97
- });
109
+ for (const [location, items] of Object.entries(menus)) {
110
+ if (!location.startsWith('_')) {
111
+ extractRoutesFromItems(items);
98
112
  }
99
113
  }
100
114
 
101
115
  if (routesToScaffold.length === 0) {
102
- console.log(pc.yellow(`\nℹ️ No local pages to synchronize inside your sitemap menu config.`));
116
+ console.log(
117
+ pc.yellow(
118
+ `\nℹ️ No local pages to synchronize inside your sitemap menu config.`,
119
+ ),
120
+ );
103
121
  process.exit(0);
104
122
  }
105
123
 
106
124
  // Load configuration and invoke adapter
107
- let frameworkAdapter = "react";
125
+ let frameworkAdapter = 'react';
108
126
  try {
109
127
  const config = await loadConfig(projectRoot);
110
- frameworkAdapter = config.frameworkAdapter || "react";
128
+ frameworkAdapter = config.frameworkAdapter || 'react';
111
129
  } catch (err) {
112
130
  // Use default
113
131
  }
@@ -115,14 +133,18 @@ try {
115
133
  try {
116
134
  const adapterModule = await loadFrameworkAdapter(frameworkAdapter);
117
135
  const adapter = adapterModule.default || adapterModule;
118
- if (typeof adapter.onSyncRoutes === "function") {
136
+ if (typeof adapter.onSyncRoutes === 'function') {
119
137
  await adapter.onSyncRoutes(projectRoot, {
120
138
  routesToScaffold,
121
139
  isForce,
122
- pc
140
+ pc,
123
141
  });
124
142
  } else {
125
- console.log(pc.yellow(` ⚠️ No sync:routes hook implemented for framework adapter: ${frameworkAdapter}`));
143
+ console.log(
144
+ pc.yellow(
145
+ ` ⚠️ No sync:routes hook implemented for framework adapter: ${frameworkAdapter}`,
146
+ ),
147
+ );
126
148
  }
127
149
  } catch (err) {
128
150
  console.error(pc.red(`\n❌ Failed to execute sync:routes: ${err.message}`));
@@ -55,9 +55,19 @@ export function onMakeBlock(themeRoot, { pascalCase, pc }) {
55
55
  console.log(` Block "${pascalCase}" was not created.\n`);
56
56
  }
57
57
 
58
- export function onMakeComponent(themeRoot, { pascalCase, pc }) {
59
- console.log(pc.yellow(`\n⚠️ The Static HTML framework adapter does not support custom loop components.`));
60
- console.log(` Component "${pascalCase}" was not created.\n`);
58
+ export function onMakeShell(themeRoot, { pascalCase, pc }) {
59
+ console.log(pc.yellow(`\n⚠️ The Static HTML framework adapter does not support parent shell blocks.`));
60
+ console.log(` Shell "${pascalCase}" was not created.\n`);
61
+ }
62
+
63
+ export function onMakeLoop(themeRoot, { pascalCase, pc }) {
64
+ console.log(pc.yellow(`\n⚠️ The Static HTML framework adapter does not support custom loops.`));
65
+ console.log(` Loop "${pascalCase}" was not created.\n`);
66
+ }
67
+
68
+ export function onMakePage(themeRoot, { pascalCase, pc }) {
69
+ console.log(pc.yellow(`\n⚠️ The Static HTML framework adapter does not support custom page templates.`));
70
+ console.log(` Page "${pascalCase}" was not created.\n`);
61
71
  }
62
72
 
63
73
  export function onSyncRoutes(themeRoot, { pc }) {
@@ -40,8 +40,16 @@ export function onMakeBlock(themeRoot, { pascalCase, pc }) {
40
40
  console.log(pc.yellow(`\n⚠️ The Stub framework adapter does not support custom Gutenberg blocks.`));
41
41
  }
42
42
 
43
- export function onMakeComponent(themeRoot, { pascalCase, pc }) {
44
- console.log(pc.yellow(`\n⚠️ The Stub framework adapter does not support custom loop components.`));
43
+ export function onMakeShell(themeRoot, { pascalCase, pc }) {
44
+ console.log(pc.yellow(`\n⚠️ The Stub framework adapter does not support parent shell blocks.`));
45
+ }
46
+
47
+ export function onMakeLoop(themeRoot, { pascalCase, pc }) {
48
+ console.log(pc.yellow(`\n⚠️ The Stub framework adapter does not support custom loops.`));
49
+ }
50
+
51
+ export function onMakePage(themeRoot, { pascalCase, pc }) {
52
+ console.log(pc.yellow(`\n⚠️ The Stub framework adapter does not support custom page templates.`));
45
53
  }
46
54
 
47
55
  export function onSyncRoutes(themeRoot, { pc }) {