@sudajs/cli 0.10.4 → 0.11.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.
- package/dist/index.js +43 -30
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/templates/theme/AGENTS.md +355 -21
- package/templates/theme/src/index.tsx +3 -2
- package/templates/theme/src/locales/en.json +8 -0
- package/templates/theme/src/sections.tsx +70 -2
- package/templates/theme/src/templates.ts +151 -6
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type { ThemeStarterPage } from "@sudajs/theme-engine";
|
|
1
|
+
import type { ThemeCmsTemplates, ThemeStarterPage } from "@sudajs/theme-engine";
|
|
2
2
|
|
|
3
3
|
import { themeAsset } from "./theme-asset.js";
|
|
4
4
|
|
|
5
5
|
export const starterPages: ThemeStarterPage[] = [
|
|
6
6
|
{
|
|
7
|
-
slug: "
|
|
7
|
+
slug: "index",
|
|
8
8
|
title: "Home",
|
|
9
9
|
isHome: true,
|
|
10
10
|
data: {
|
|
@@ -35,6 +35,15 @@ export const starterPages: ThemeStarterPage[] = [
|
|
|
35
35
|
],
|
|
36
36
|
},
|
|
37
37
|
},
|
|
38
|
+
{
|
|
39
|
+
type: "FeaturedPosts",
|
|
40
|
+
props: {
|
|
41
|
+
id: "FeaturedPosts-1",
|
|
42
|
+
title: "Featured posts",
|
|
43
|
+
description: "Use CMS posts to keep the homepage fresh without manual card editing.",
|
|
44
|
+
postList: { strategy: "featured", limit: 3 },
|
|
45
|
+
},
|
|
46
|
+
},
|
|
38
47
|
{
|
|
39
48
|
type: "CallToAction",
|
|
40
49
|
props: {
|
|
@@ -42,14 +51,71 @@ export const starterPages: ThemeStarterPage[] = [
|
|
|
42
51
|
title: "Launch your first page",
|
|
43
52
|
description: "Customize this starter template or let an agent generate a new draft.",
|
|
44
53
|
buttonLabel: "Get in touch",
|
|
45
|
-
buttonHref: "/contact",
|
|
54
|
+
buttonHref: "/contact-us",
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
],
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
slug: "services",
|
|
62
|
+
title: "Services",
|
|
63
|
+
data: {
|
|
64
|
+
root: { props: {} },
|
|
65
|
+
content: [
|
|
66
|
+
{
|
|
67
|
+
type: "Hero",
|
|
68
|
+
props: {
|
|
69
|
+
id: "Hero-Services",
|
|
70
|
+
eyebrow: "Services",
|
|
71
|
+
title: "Show what you offer",
|
|
72
|
+
description: "Use this page to explain core services, packages, or capabilities.",
|
|
73
|
+
primaryLabel: "Contact us",
|
|
74
|
+
primaryHref: "/contact-us",
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
type: "FeatureGrid",
|
|
79
|
+
props: {
|
|
80
|
+
id: "FeatureGrid-Services",
|
|
81
|
+
title: "Service highlights",
|
|
82
|
+
description: "Replace these cards with the most important ways you help customers.",
|
|
46
83
|
},
|
|
47
84
|
},
|
|
48
85
|
],
|
|
49
86
|
},
|
|
50
87
|
},
|
|
51
88
|
{
|
|
52
|
-
slug: "
|
|
89
|
+
slug: "team",
|
|
90
|
+
title: "Team",
|
|
91
|
+
data: {
|
|
92
|
+
root: { props: {} },
|
|
93
|
+
content: [
|
|
94
|
+
{
|
|
95
|
+
type: "Hero",
|
|
96
|
+
props: {
|
|
97
|
+
id: "Hero-Team",
|
|
98
|
+
eyebrow: "Team",
|
|
99
|
+
title: "Introduce the people behind the work",
|
|
100
|
+
description: "Share experience, roles, and the human story behind the project.",
|
|
101
|
+
primaryLabel: "Work with us",
|
|
102
|
+
primaryHref: "/contact-us",
|
|
103
|
+
},
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
type: "Testimonial",
|
|
107
|
+
props: {
|
|
108
|
+
id: "Testimonial-Team",
|
|
109
|
+
quote: "Use this block for a founder note, client quote, or team philosophy.",
|
|
110
|
+
author: "Team lead",
|
|
111
|
+
role: "Founder",
|
|
112
|
+
},
|
|
113
|
+
},
|
|
114
|
+
],
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
{
|
|
118
|
+
slug: "about-us",
|
|
53
119
|
title: "About",
|
|
54
120
|
data: {
|
|
55
121
|
root: { props: {} },
|
|
@@ -62,7 +128,7 @@ export const starterPages: ThemeStarterPage[] = [
|
|
|
62
128
|
title: "A clean starting point for your story",
|
|
63
129
|
description: "Use this page to introduce the project, audience, and promise.",
|
|
64
130
|
primaryLabel: "Contact us",
|
|
65
|
-
primaryHref: "/contact",
|
|
131
|
+
primaryHref: "/contact-us",
|
|
66
132
|
},
|
|
67
133
|
},
|
|
68
134
|
{
|
|
@@ -78,7 +144,7 @@ export const starterPages: ThemeStarterPage[] = [
|
|
|
78
144
|
},
|
|
79
145
|
},
|
|
80
146
|
{
|
|
81
|
-
slug: "contact",
|
|
147
|
+
slug: "contact-us",
|
|
82
148
|
title: "Contact",
|
|
83
149
|
data: {
|
|
84
150
|
root: { props: {} },
|
|
@@ -108,3 +174,82 @@ export const starterPages: ThemeStarterPage[] = [
|
|
|
108
174
|
},
|
|
109
175
|
},
|
|
110
176
|
];
|
|
177
|
+
|
|
178
|
+
export const cmsTemplates: ThemeCmsTemplates = {
|
|
179
|
+
posts: {
|
|
180
|
+
title: "Posts",
|
|
181
|
+
data: {
|
|
182
|
+
root: { props: {} },
|
|
183
|
+
content: [
|
|
184
|
+
{
|
|
185
|
+
type: "Hero",
|
|
186
|
+
props: {
|
|
187
|
+
id: "Hero-Posts",
|
|
188
|
+
eyebrow: "Articles",
|
|
189
|
+
title: "Latest updates",
|
|
190
|
+
description: "Browse news, articles, and practical insights.",
|
|
191
|
+
primaryLabel: "View tags",
|
|
192
|
+
primaryHref: "/tags",
|
|
193
|
+
},
|
|
194
|
+
},
|
|
195
|
+
],
|
|
196
|
+
},
|
|
197
|
+
},
|
|
198
|
+
post: {
|
|
199
|
+
title: "Post",
|
|
200
|
+
data: {
|
|
201
|
+
root: { props: {} },
|
|
202
|
+
content: [
|
|
203
|
+
{
|
|
204
|
+
type: "Hero",
|
|
205
|
+
props: {
|
|
206
|
+
id: "Hero-Post",
|
|
207
|
+
eyebrow: "Article",
|
|
208
|
+
title: "Article detail",
|
|
209
|
+
description: "This template renders a single published post.",
|
|
210
|
+
primaryLabel: "Back to posts",
|
|
211
|
+
primaryHref: "/posts",
|
|
212
|
+
},
|
|
213
|
+
},
|
|
214
|
+
],
|
|
215
|
+
},
|
|
216
|
+
},
|
|
217
|
+
tags: {
|
|
218
|
+
title: "Tags",
|
|
219
|
+
data: {
|
|
220
|
+
root: { props: {} },
|
|
221
|
+
content: [
|
|
222
|
+
{
|
|
223
|
+
type: "Hero",
|
|
224
|
+
props: {
|
|
225
|
+
id: "Hero-Tags",
|
|
226
|
+
eyebrow: "Topics",
|
|
227
|
+
title: "Browse by topic",
|
|
228
|
+
description: "Explore tags used across published posts.",
|
|
229
|
+
primaryLabel: "View posts",
|
|
230
|
+
primaryHref: "/posts",
|
|
231
|
+
},
|
|
232
|
+
},
|
|
233
|
+
],
|
|
234
|
+
},
|
|
235
|
+
},
|
|
236
|
+
tag: {
|
|
237
|
+
title: "Tag",
|
|
238
|
+
data: {
|
|
239
|
+
root: { props: {} },
|
|
240
|
+
content: [
|
|
241
|
+
{
|
|
242
|
+
type: "Hero",
|
|
243
|
+
props: {
|
|
244
|
+
id: "Hero-Tag",
|
|
245
|
+
eyebrow: "Topic",
|
|
246
|
+
title: "Topic posts",
|
|
247
|
+
description: "This template renders posts filtered by the current tag.",
|
|
248
|
+
primaryLabel: "All posts",
|
|
249
|
+
primaryHref: "/posts",
|
|
250
|
+
},
|
|
251
|
+
},
|
|
252
|
+
],
|
|
253
|
+
},
|
|
254
|
+
},
|
|
255
|
+
};
|