@kyro-cms/core 0.8.0 → 0.9.1

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 (248) hide show
  1. package/README.md +57 -589
  2. package/dist/{WebhookService-118ZTFis.d.ts → WebhookService-CUTb9XOy.d.ts} +1 -1
  3. package/dist/{WebhookService-AefJfqX0.d.cts → WebhookService-Yg2UEOB4.d.cts} +1 -1
  4. package/dist/api-handler-graphql.cjs +44 -0
  5. package/dist/api-handler-graphql.cjs.map +1 -0
  6. package/dist/api-handler-graphql.d.cts +6 -0
  7. package/dist/api-handler-graphql.d.ts +6 -0
  8. package/dist/api-handler-graphql.js +41 -0
  9. package/dist/api-handler-graphql.js.map +1 -0
  10. package/dist/api-handler-trpc.cjs +38 -0
  11. package/dist/api-handler-trpc.cjs.map +1 -0
  12. package/dist/api-handler-trpc.d.cts +5 -0
  13. package/dist/api-handler-trpc.d.ts +5 -0
  14. package/dist/api-handler-trpc.js +36 -0
  15. package/dist/api-handler-trpc.js.map +1 -0
  16. package/dist/api-handler.cjs +31 -97
  17. package/dist/api-handler.cjs.map +1 -1
  18. package/dist/api-handler.d.cts +2 -1
  19. package/dist/api-handler.d.ts +2 -1
  20. package/dist/api-handler.js +19 -95
  21. package/dist/api-handler.js.map +1 -1
  22. package/dist/{tenant-B1YB0Jy8.d.ts → base-B71y_EAF.d.cts} +6 -12
  23. package/dist/{tenant-Cpeveji6.d.cts → base-DaqY2GhA.d.ts} +6 -12
  24. package/dist/bootstrap-5NLASFOG.cjs +32 -0
  25. package/dist/{bootstrap-AKAUP6F6.cjs.map → bootstrap-5NLASFOG.cjs.map} +1 -1
  26. package/dist/bootstrap-T5BK77LD.js +7 -0
  27. package/dist/{bootstrap-JCML6NFO.js.map → bootstrap-T5BK77LD.js.map} +1 -1
  28. package/dist/{chunk-35U3FROB.js → chunk-22M4O4ZJ.js} +607 -63
  29. package/dist/chunk-22M4O4ZJ.js.map +1 -0
  30. package/dist/chunk-2HZRBATX.cjs +253 -0
  31. package/dist/chunk-2HZRBATX.cjs.map +1 -0
  32. package/dist/{chunk-VJT6P4N6.cjs → chunk-3HR772HI.cjs} +199 -32
  33. package/dist/chunk-3HR772HI.cjs.map +1 -0
  34. package/dist/chunk-3KTWGODI.cjs +178 -0
  35. package/dist/chunk-3KTWGODI.cjs.map +1 -0
  36. package/dist/{chunk-QXIQWPAP.js → chunk-3UK5XBVJ.js} +4 -134
  37. package/dist/chunk-3UK5XBVJ.js.map +1 -0
  38. package/dist/{chunk-FXYP2HA6.js → chunk-4AO3A3JM.js} +48 -4
  39. package/dist/chunk-4AO3A3JM.js.map +1 -0
  40. package/dist/chunk-4M7X5HAB.cjs +173 -0
  41. package/dist/chunk-4M7X5HAB.cjs.map +1 -0
  42. package/dist/chunk-5EPFQUQD.js +3243 -0
  43. package/dist/chunk-5EPFQUQD.js.map +1 -0
  44. package/dist/{chunk-Y3N7UUDO.js → chunk-7OGPN7MP.js} +5 -2
  45. package/dist/chunk-7OGPN7MP.js.map +1 -0
  46. package/dist/{chunk-WOWUL7ZY.js → chunk-AL5KX63J.js} +4 -3
  47. package/dist/chunk-AL5KX63J.js.map +1 -0
  48. package/dist/{chunk-2OL4O2TH.cjs → chunk-C36TMDTY.cjs} +66 -61
  49. package/dist/chunk-C36TMDTY.cjs.map +1 -0
  50. package/dist/{chunk-ES5HNFFT.js → chunk-CF7OL6HR.js} +4 -2
  51. package/dist/chunk-CF7OL6HR.js.map +1 -0
  52. package/dist/chunk-CJONKRHJ.js +162 -0
  53. package/dist/chunk-CJONKRHJ.js.map +1 -0
  54. package/dist/{chunk-2KVHZE6O.cjs → chunk-COIASRDK.cjs} +202 -46
  55. package/dist/chunk-COIASRDK.cjs.map +1 -0
  56. package/dist/chunk-DEVFAKCQ.cjs +3291 -0
  57. package/dist/chunk-DEVFAKCQ.cjs.map +1 -0
  58. package/dist/{chunk-3ZFYL34R.js → chunk-DYTZ6FQ7.js} +12 -185
  59. package/dist/chunk-DYTZ6FQ7.js.map +1 -0
  60. package/dist/{chunk-QPPDLRNR.js → chunk-EJN2PAOE.js} +197 -41
  61. package/dist/chunk-EJN2PAOE.js.map +1 -0
  62. package/dist/chunk-FAXU7BMP.js +220 -0
  63. package/dist/chunk-FAXU7BMP.js.map +1 -0
  64. package/dist/{chunk-OHVB4AJ7.js → chunk-FOPGUM27.js} +22 -17
  65. package/dist/chunk-FOPGUM27.js.map +1 -0
  66. package/dist/chunk-GAOXD3XT.js +175 -0
  67. package/dist/chunk-GAOXD3XT.js.map +1 -0
  68. package/dist/{chunk-4DA7QPLA.cjs → chunk-GXFOGU7N.cjs} +5 -2
  69. package/dist/chunk-GXFOGU7N.cjs.map +1 -0
  70. package/dist/{chunk-I7HHI6QV.cjs → chunk-IDVRRRAK.cjs} +17 -9
  71. package/dist/chunk-IDVRRRAK.cjs.map +1 -0
  72. package/dist/{chunk-WQBRWOQT.cjs → chunk-JOPVMWTM.cjs} +3 -2
  73. package/dist/chunk-JOPVMWTM.cjs.map +1 -0
  74. package/dist/chunk-KC2GDBLS.cjs +84 -0
  75. package/dist/chunk-KC2GDBLS.cjs.map +1 -0
  76. package/dist/{chunk-K7JPTH3G.cjs → chunk-KNRSROWB.cjs} +132 -74
  77. package/dist/chunk-KNRSROWB.cjs.map +1 -0
  78. package/dist/{chunk-3AJE4SEG.js → chunk-KPA4AN4R.js} +125 -67
  79. package/dist/chunk-KPA4AN4R.js.map +1 -0
  80. package/dist/{chunk-QUW2RZTM.cjs → chunk-L46ROHUS.cjs} +51 -7
  81. package/dist/chunk-L46ROHUS.cjs.map +1 -0
  82. package/dist/chunk-L4EZKIEX.js +185 -0
  83. package/dist/chunk-L4EZKIEX.js.map +1 -0
  84. package/dist/{chunk-REK7AYOC.js → chunk-L5UKKZQN.js} +199 -32
  85. package/dist/chunk-L5UKKZQN.js.map +1 -0
  86. package/dist/chunk-NKPKR5BW.cjs +188 -0
  87. package/dist/chunk-NKPKR5BW.cjs.map +1 -0
  88. package/dist/{chunk-Y3QQN7PN.js → chunk-P2HKJ7P5.js} +13 -4
  89. package/dist/chunk-P2HKJ7P5.js.map +1 -0
  90. package/dist/{chunk-SA7NSSIQ.cjs → chunk-PI73NNOK.cjs} +13 -187
  91. package/dist/chunk-PI73NNOK.cjs.map +1 -0
  92. package/dist/{chunk-HXRD4B37.js → chunk-PU2Z5VWF.js} +1279 -556
  93. package/dist/chunk-PU2Z5VWF.js.map +1 -0
  94. package/dist/{chunk-H727JIG7.js → chunk-Q72BOAPK.js} +16 -8
  95. package/dist/chunk-Q72BOAPK.js.map +1 -0
  96. package/dist/{chunk-IBG6V56E.cjs → chunk-QFLB4EIJ.cjs} +2 -139
  97. package/dist/chunk-QFLB4EIJ.cjs.map +1 -0
  98. package/dist/{chunk-YVUJBEXE.cjs → chunk-RAMGUDJN.cjs} +16 -7
  99. package/dist/chunk-RAMGUDJN.cjs.map +1 -0
  100. package/dist/{chunk-LINKCEG4.cjs → chunk-ROJHKAQ4.cjs} +617 -73
  101. package/dist/chunk-ROJHKAQ4.cjs.map +1 -0
  102. package/dist/{chunk-5KVM3WEY.cjs → chunk-RSF3UU7H.cjs} +1330 -602
  103. package/dist/chunk-RSF3UU7H.cjs.map +1 -0
  104. package/dist/{chunk-V3LKPM3O.cjs → chunk-SHTTJMLT.cjs} +4 -2
  105. package/dist/chunk-SHTTJMLT.cjs.map +1 -0
  106. package/dist/chunk-SPBTLUN6.js +92 -0
  107. package/dist/chunk-SPBTLUN6.js.map +1 -0
  108. package/dist/{chunk-57P6MJKC.js → chunk-TXSZFA4G.js} +3 -3
  109. package/dist/chunk-TXSZFA4G.js.map +1 -0
  110. package/dist/chunk-UERVXYVK.cjs +99 -0
  111. package/dist/chunk-UERVXYVK.cjs.map +1 -0
  112. package/dist/{chunk-PDYFVNUX.cjs → chunk-V2TVSCV5.cjs} +16 -23
  113. package/dist/chunk-V2TVSCV5.cjs.map +1 -0
  114. package/dist/{chunk-DXHRBMGB.js → chunk-VO35MNPH.js} +12 -19
  115. package/dist/chunk-VO35MNPH.js.map +1 -0
  116. package/dist/{chunk-IA6AU5PI.cjs → chunk-WNCYAKF3.cjs} +3 -3
  117. package/dist/chunk-WNCYAKF3.cjs.map +1 -0
  118. package/dist/chunk-XEB7PH2E.js +81 -0
  119. package/dist/chunk-XEB7PH2E.js.map +1 -0
  120. package/dist/cli/index.cjs +5 -5
  121. package/dist/cli/index.cjs.map +1 -1
  122. package/dist/cli/index.js +5 -5
  123. package/dist/cli/index.js.map +1 -1
  124. package/dist/client.cjs +3 -3
  125. package/dist/client.d.cts +3 -3
  126. package/dist/client.d.ts +3 -3
  127. package/dist/client.js +1 -1
  128. package/dist/drizzle/index.cjs +14 -13
  129. package/dist/drizzle/index.d.cts +9 -7
  130. package/dist/drizzle/index.d.ts +9 -7
  131. package/dist/drizzle/index.js +5 -4
  132. package/dist/fields/index.cjs +21 -37
  133. package/dist/fields/index.d.cts +2 -22
  134. package/dist/fields/index.d.ts +2 -22
  135. package/dist/fields/index.js +1 -1
  136. package/dist/graphql/index.cjs +5 -4
  137. package/dist/graphql/index.d.cts +5 -3
  138. package/dist/graphql/index.d.ts +5 -3
  139. package/dist/graphql/index.js +3 -2
  140. package/dist/index-CJXPB_ot.d.ts +276 -0
  141. package/dist/index-CaTNnLGd.d.cts +276 -0
  142. package/dist/index.cjs +304 -162
  143. package/dist/index.cjs.map +1 -1
  144. package/dist/index.d.cts +129 -205
  145. package/dist/index.d.ts +129 -205
  146. package/dist/index.js +172 -33
  147. package/dist/index.js.map +1 -1
  148. package/dist/integration.cjs +2 -2
  149. package/dist/integration.js +1 -1
  150. package/dist/mongo-auth-adapter-ISOM7FSS.cjs +17 -0
  151. package/dist/{mongo-auth-adapter-NHHUJHVH.cjs.map → mongo-auth-adapter-ISOM7FSS.cjs.map} +1 -1
  152. package/dist/mongo-auth-adapter-MO6STCV3.js +4 -0
  153. package/dist/{mongo-auth-adapter-NJQUUCTP.js.map → mongo-auth-adapter-MO6STCV3.js.map} +1 -1
  154. package/dist/mongodb/index.cjs +8 -7
  155. package/dist/mongodb/index.d.cts +5 -7
  156. package/dist/mongodb/index.d.ts +5 -7
  157. package/dist/mongodb/index.js +4 -3
  158. package/dist/postgres-auth-adapter-DWDR7P5G.js +5 -0
  159. package/dist/{postgres-auth-adapter-3T2NKTSE.js.map → postgres-auth-adapter-DWDR7P5G.js.map} +1 -1
  160. package/dist/postgres-auth-adapter-WRWSJD4E.cjs +14 -0
  161. package/dist/{postgres-auth-adapter-7IEENCKQ.cjs.map → postgres-auth-adapter-WRWSJD4E.cjs.map} +1 -1
  162. package/dist/redis-adapter-HGTPWIGV.js +4 -0
  163. package/dist/{redis-adapter-VQXD7ESY.js.map → redis-adapter-HGTPWIGV.js.map} +1 -1
  164. package/dist/redis-adapter-KJ3YOOT6.cjs +13 -0
  165. package/dist/{redis-adapter-D2E2S3GB.cjs.map → redis-adapter-KJ3YOOT6.cjs.map} +1 -1
  166. package/dist/rest/index.cjs +15 -14
  167. package/dist/rest/index.d.cts +4 -4
  168. package/dist/rest/index.d.ts +4 -4
  169. package/dist/rest/index.js +13 -12
  170. package/dist/{schema-5PHL5IVB.js → schema-6I5OFR4Z.js} +3 -3
  171. package/dist/{schema-5PHL5IVB.js.map → schema-6I5OFR4Z.js.map} +1 -1
  172. package/dist/{schema-37SE2F4B.cjs → schema-TTFE4467.cjs} +14 -14
  173. package/dist/{schema-37SE2F4B.cjs.map → schema-TTFE4467.cjs.map} +1 -1
  174. package/dist/sqlite-adapter-6GEUSVXQ.js +4 -0
  175. package/dist/{sqlite-adapter-TR3U3W6Q.js.map → sqlite-adapter-6GEUSVXQ.js.map} +1 -1
  176. package/dist/sqlite-adapter-CSIZE5SX.cjs +13 -0
  177. package/dist/{sqlite-adapter-LVK5PS4T.cjs.map → sqlite-adapter-CSIZE5SX.cjs.map} +1 -1
  178. package/dist/templates/index.cjs +133 -31
  179. package/dist/templates/index.d.cts +52 -9
  180. package/dist/templates/index.d.ts +52 -9
  181. package/dist/templates/index.js +3 -1
  182. package/dist/trpc/index.cjs +13 -12
  183. package/dist/trpc/index.d.cts +55 -49
  184. package/dist/trpc/index.d.ts +55 -49
  185. package/dist/trpc/index.js +4 -3
  186. package/dist/{types-D6ZLRGbH.d.cts → types-CpjuXbe7.d.cts} +2 -0
  187. package/dist/{types-D6ZLRGbH.d.ts → types-CpjuXbe7.d.ts} +2 -0
  188. package/dist/{types-Bs1up4yP.d.ts → types-CyCQ6SAI.d.ts} +28 -2
  189. package/dist/{types-J3R9nVsZ.d.cts → types-DJxD9394.d.cts} +28 -2
  190. package/dist/{types-VtjUxIMp.d.cts → types-Z6FBiqa2.d.cts} +35 -14
  191. package/dist/{types-VtjUxIMp.d.ts → types-Z6FBiqa2.d.ts} +35 -14
  192. package/package.json +22 -4
  193. package/dist/bootstrap-AKAUP6F6.cjs +0 -32
  194. package/dist/bootstrap-JCML6NFO.js +0 -7
  195. package/dist/chunk-2KVHZE6O.cjs.map +0 -1
  196. package/dist/chunk-2OL4O2TH.cjs.map +0 -1
  197. package/dist/chunk-35U3FROB.js.map +0 -1
  198. package/dist/chunk-3AJE4SEG.js.map +0 -1
  199. package/dist/chunk-3J4MFTI3.js +0 -3872
  200. package/dist/chunk-3J4MFTI3.js.map +0 -1
  201. package/dist/chunk-3ZFYL34R.js.map +0 -1
  202. package/dist/chunk-4DA7QPLA.cjs.map +0 -1
  203. package/dist/chunk-57P6MJKC.js.map +0 -1
  204. package/dist/chunk-5KVM3WEY.cjs.map +0 -1
  205. package/dist/chunk-6IMPH6WV.cjs +0 -3897
  206. package/dist/chunk-6IMPH6WV.cjs.map +0 -1
  207. package/dist/chunk-ATBOUGQP.cjs +0 -513
  208. package/dist/chunk-ATBOUGQP.cjs.map +0 -1
  209. package/dist/chunk-DXHRBMGB.js.map +0 -1
  210. package/dist/chunk-ES5HNFFT.js.map +0 -1
  211. package/dist/chunk-FXYP2HA6.js.map +0 -1
  212. package/dist/chunk-H727JIG7.js.map +0 -1
  213. package/dist/chunk-HXRD4B37.js.map +0 -1
  214. package/dist/chunk-I7HHI6QV.cjs.map +0 -1
  215. package/dist/chunk-IA6AU5PI.cjs.map +0 -1
  216. package/dist/chunk-IBG6V56E.cjs.map +0 -1
  217. package/dist/chunk-K7JPTH3G.cjs.map +0 -1
  218. package/dist/chunk-LINKCEG4.cjs.map +0 -1
  219. package/dist/chunk-OHVB4AJ7.js.map +0 -1
  220. package/dist/chunk-PDYFVNUX.cjs.map +0 -1
  221. package/dist/chunk-Q23JB3KL.js +0 -488
  222. package/dist/chunk-Q23JB3KL.js.map +0 -1
  223. package/dist/chunk-QPPDLRNR.js.map +0 -1
  224. package/dist/chunk-QUW2RZTM.cjs.map +0 -1
  225. package/dist/chunk-QXIQWPAP.js.map +0 -1
  226. package/dist/chunk-R3XIBBAW.cjs +0 -34
  227. package/dist/chunk-R3XIBBAW.cjs.map +0 -1
  228. package/dist/chunk-REK7AYOC.js.map +0 -1
  229. package/dist/chunk-SA7NSSIQ.cjs.map +0 -1
  230. package/dist/chunk-SDMNUYVU.js +0 -30
  231. package/dist/chunk-SDMNUYVU.js.map +0 -1
  232. package/dist/chunk-V3LKPM3O.cjs.map +0 -1
  233. package/dist/chunk-VJT6P4N6.cjs.map +0 -1
  234. package/dist/chunk-WOWUL7ZY.js.map +0 -1
  235. package/dist/chunk-WQBRWOQT.cjs.map +0 -1
  236. package/dist/chunk-Y3N7UUDO.js.map +0 -1
  237. package/dist/chunk-Y3QQN7PN.js.map +0 -1
  238. package/dist/chunk-YVUJBEXE.cjs.map +0 -1
  239. package/dist/index-CLp-DRKA.d.ts +0 -64
  240. package/dist/index-DfO7G4kN.d.cts +0 -64
  241. package/dist/mongo-auth-adapter-NHHUJHVH.cjs +0 -17
  242. package/dist/mongo-auth-adapter-NJQUUCTP.js +0 -4
  243. package/dist/postgres-auth-adapter-3T2NKTSE.js +0 -5
  244. package/dist/postgres-auth-adapter-7IEENCKQ.cjs +0 -14
  245. package/dist/redis-adapter-D2E2S3GB.cjs +0 -13
  246. package/dist/redis-adapter-VQXD7ESY.js +0 -4
  247. package/dist/sqlite-adapter-LVK5PS4T.cjs +0 -13
  248. package/dist/sqlite-adapter-TR3U3W6Q.js +0 -4
@@ -0,0 +1,3291 @@
1
+ 'use strict';
2
+
3
+ var chunk3KTWGODI_cjs = require('./chunk-3KTWGODI.cjs');
4
+ var chunkKC2GDBLS_cjs = require('./chunk-KC2GDBLS.cjs');
5
+
6
+ // src/templates/minimal.ts
7
+ var minimalCollections = {};
8
+
9
+ // src/templates/starter.ts
10
+ var starterCollections = {};
11
+
12
+ // src/templates/blog.ts
13
+ var blogCollections = {};
14
+ var blogGlobals = [];
15
+
16
+ // src/templates/ecommerce.ts
17
+ var ecommerceCollections = {};
18
+ var ecommerceGlobals = [];
19
+
20
+ // src/templates/kitchen-sink.ts
21
+ var kitchenSinkCollections = {};
22
+
23
+ // src/templates/media.ts
24
+ var mediaCollection = {
25
+ slug: "media",
26
+ label: "Media Library",
27
+ admin: {
28
+ useAsTitle: "title",
29
+ defaultColumns: ["thumbnailUrl", "title", "type", "fileSize", "createdAt"],
30
+ group: "content"
31
+ },
32
+ access: {
33
+ read: () => true,
34
+ create: () => true,
35
+ update: () => true,
36
+ delete: () => true
37
+ },
38
+ fields: [
39
+ {
40
+ name: "title",
41
+ type: "text",
42
+ label: "Title",
43
+ required: true,
44
+ admin: {
45
+ description: "Descriptive title for the file"
46
+ }
47
+ },
48
+ {
49
+ name: "filename",
50
+ type: "text",
51
+ label: "Filename",
52
+ required: true,
53
+ admin: {
54
+ readOnly: true,
55
+ description: "System filename (auto-generated)"
56
+ }
57
+ },
58
+ {
59
+ name: "originalName",
60
+ type: "text",
61
+ label: "Original Name",
62
+ admin: {
63
+ readOnly: true
64
+ }
65
+ },
66
+ {
67
+ name: "alt",
68
+ type: "text",
69
+ label: "Alt Text",
70
+ admin: {
71
+ description: "Alternative text for images (accessibility)"
72
+ }
73
+ },
74
+ {
75
+ name: "caption",
76
+ type: "richtext",
77
+ label: "Caption",
78
+ admin: {
79
+ description: "Optional caption or description"
80
+ }
81
+ },
82
+ {
83
+ name: "type",
84
+ type: "select",
85
+ label: "File Type",
86
+ required: true,
87
+ defaultValue: "document",
88
+ options: [
89
+ { label: "Image", value: "image" },
90
+ { label: "Video", value: "video" },
91
+ { label: "Audio", value: "audio" },
92
+ { label: "Document", value: "document" },
93
+ { label: "Archive", value: "archive" },
94
+ { label: "Other", value: "other" }
95
+ ],
96
+ admin: {
97
+ readOnly: true
98
+ }
99
+ },
100
+ {
101
+ name: "mimeType",
102
+ type: "text",
103
+ label: "MIME Type",
104
+ admin: {
105
+ readOnly: true
106
+ }
107
+ },
108
+ {
109
+ name: "url",
110
+ type: "text",
111
+ label: "URL",
112
+ required: true,
113
+ admin: {
114
+ readOnly: true,
115
+ description: "Public URL of the file"
116
+ }
117
+ },
118
+ {
119
+ name: "thumbnailUrl",
120
+ type: "text",
121
+ label: "Thumbnail URL",
122
+ admin: {
123
+ readOnly: true
124
+ }
125
+ },
126
+ {
127
+ name: "width",
128
+ type: "number",
129
+ label: "Width",
130
+ admin: {
131
+ readOnly: true,
132
+ description: "Width in pixels (for images/videos)"
133
+ }
134
+ },
135
+ {
136
+ name: "height",
137
+ type: "number",
138
+ label: "Height",
139
+ admin: {
140
+ readOnly: true,
141
+ description: "Height in pixels (for images/videos)"
142
+ }
143
+ },
144
+ {
145
+ name: "fileSize",
146
+ type: "number",
147
+ label: "File Size",
148
+ admin: {
149
+ readOnly: true,
150
+ description: "Size in bytes"
151
+ }
152
+ },
153
+ {
154
+ name: "folder",
155
+ type: "text",
156
+ label: "Folder",
157
+ admin: {
158
+ description: "Folder path for organization (e.g., /products, /blog)"
159
+ }
160
+ },
161
+ {
162
+ name: "tags",
163
+ type: "array",
164
+ label: "Tags",
165
+ fields: [
166
+ {
167
+ name: "tag",
168
+ type: "text",
169
+ label: "Tag"
170
+ }
171
+ ]
172
+ },
173
+ {
174
+ name: "focalPoint",
175
+ type: "group",
176
+ label: "Focal Point",
177
+ admin: {
178
+ description: "Point of interest for cropping"
179
+ },
180
+ fields: [
181
+ {
182
+ name: "x",
183
+ type: "number",
184
+ label: "X",
185
+ defaultValue: 50
186
+ },
187
+ {
188
+ name: "y",
189
+ type: "number",
190
+ label: "Y",
191
+ defaultValue: 50
192
+ }
193
+ ]
194
+ },
195
+ {
196
+ name: "metadata",
197
+ type: "json",
198
+ label: "Metadata",
199
+ admin: {
200
+ readOnly: true,
201
+ description: "Additional file metadata (EXIF, etc.)"
202
+ }
203
+ },
204
+ {
205
+ name: "provider",
206
+ type: "select",
207
+ label: "Storage Provider",
208
+ defaultValue: "local",
209
+ options: [
210
+ { label: "Local", value: "local" },
211
+ { label: "AWS S3", value: "s3" },
212
+ { label: "Cloudinary", value: "cloudinary" },
213
+ { label: "Imgix", value: "imgix" }
214
+ ],
215
+ admin: {
216
+ readOnly: true
217
+ }
218
+ },
219
+ {
220
+ name: "status",
221
+ type: "select",
222
+ label: "Status",
223
+ defaultValue: "active",
224
+ options: [
225
+ { label: "Active", value: "active" },
226
+ { label: "Archived", value: "archived" }
227
+ ]
228
+ },
229
+ {
230
+ name: "createdAt",
231
+ type: "date",
232
+ label: "Created",
233
+ admin: {
234
+ readOnly: true
235
+ }
236
+ },
237
+ {
238
+ name: "updatedAt",
239
+ type: "date",
240
+ label: "Last Modified",
241
+ admin: {
242
+ readOnly: true
243
+ }
244
+ }
245
+ ]
246
+ };
247
+ var mediaCollections = [mediaCollection];
248
+
249
+ // src/templates/menu.ts
250
+ var menuCollection = {
251
+ slug: "menu",
252
+ label: "Menu",
253
+ singularLabel: "Menu Item",
254
+ admin: {
255
+ useAsTitle: "title",
256
+ defaultColumns: ["title", "menu_location"]
257
+ },
258
+ fields: [
259
+ { name: "title", type: "text", label: "Title", required: true },
260
+ {
261
+ name: "menu_location",
262
+ type: "select",
263
+ label: "Menu Location",
264
+ options: [
265
+ { label: "Header", value: "header" },
266
+ { label: "Footer", value: "footer" },
267
+ { label: "Sidebar", value: "sidebar" },
268
+ { label: "Primary", value: "primary" },
269
+ { label: "Secondary", value: "secondary" }
270
+ ],
271
+ required: true,
272
+ admin: { position: "sidebar" }
273
+ },
274
+ {
275
+ name: "order",
276
+ type: "number",
277
+ label: "Order",
278
+ admin: { position: "sidebar" }
279
+ },
280
+ {
281
+ name: "menu",
282
+ type: "group",
283
+ fields: [
284
+ {
285
+ name: "menu_item",
286
+ label: "Menu Item",
287
+ type: "array",
288
+ fields: [
289
+ {
290
+ name: "link_type",
291
+ type: "select",
292
+ label: "Link Type",
293
+ options: [
294
+ { label: "Internal", value: "internal" },
295
+ { label: "External", value: "external" }
296
+ ]
297
+ },
298
+ {
299
+ name: "internal_target",
300
+ type: "relationship",
301
+ label: "Internal Target",
302
+ relationTo: ["pages", "posts"],
303
+ admin: {
304
+ condition: { field: "link_type", equals: "internal" }
305
+ }
306
+ },
307
+ {
308
+ name: "external_url",
309
+ type: "text",
310
+ label: "External URL",
311
+ admin: {
312
+ condition: { field: "link_type", equals: "external" }
313
+ }
314
+ }
315
+ ]
316
+ }
317
+ ]
318
+ }
319
+ ]
320
+ };
321
+ var menuCollections = {
322
+ menu: menuCollection
323
+ };
324
+
325
+ // src/templates/posts.ts
326
+ var postsCollection = {
327
+ slug: "posts",
328
+ label: "Posts",
329
+ labelPlural: "Posts",
330
+ singularLabel: "Post",
331
+ admin: {
332
+ useAsTitle: "title",
333
+ defaultColumns: ["title", "slug", "publishStatus", "createdAt", "updatedAt"],
334
+ description: "Blog posts and articles"
335
+ },
336
+ fields: [
337
+ {
338
+ name: "mainTabs",
339
+ type: "tabs",
340
+ tabs: [
341
+ {
342
+ label: "Content",
343
+ fields: [
344
+ {
345
+ name: "title",
346
+ type: "text",
347
+ required: true,
348
+ label: "Title",
349
+ admin: {
350
+ description: "The main title of the post as it will appear publicly."
351
+ }
352
+ },
353
+ {
354
+ name: "content",
355
+ type: "richtext",
356
+ label: "Content"
357
+ }
358
+ ]
359
+ },
360
+ {
361
+ label: "Meta",
362
+ fields: [
363
+ {
364
+ name: "category",
365
+ type: "relationship",
366
+ label: "Category",
367
+ relationTo: "categories",
368
+ admin: {
369
+ description: "Select the primary category this post belongs to."
370
+ }
371
+ },
372
+ {
373
+ name: "relatedPosts",
374
+ type: "array",
375
+ label: "Related Posts",
376
+ fields: [
377
+ {
378
+ name: "post",
379
+ type: "relationship",
380
+ relationTo: "posts",
381
+ label: "Post"
382
+ }
383
+ ],
384
+ admin: { description: "Select posts related to this one." }
385
+ }
386
+ ]
387
+ },
388
+ {
389
+ label: "SEO",
390
+ fields: [
391
+ {
392
+ name: "metaTitle",
393
+ type: "text",
394
+ label: "Meta Title",
395
+ admin: {
396
+ autoGenerate: "title",
397
+ description: "The title used for SEO and social sharing (recommended < 60 chars)."
398
+ }
399
+ },
400
+ {
401
+ name: "metaDescription",
402
+ type: "textarea",
403
+ label: "Meta Description",
404
+ admin: {
405
+ autoGenerate: "content",
406
+ description: "A brief summary for search engines (recommended < 160 chars)."
407
+ }
408
+ },
409
+ {
410
+ name: "ogImage",
411
+ type: "upload",
412
+ label: "OG Image",
413
+ relationTo: "media",
414
+ admin: {
415
+ description: "The image shown when the post is shared on social media."
416
+ }
417
+ }
418
+ ]
419
+ }
420
+ ]
421
+ },
422
+ {
423
+ name: "slug",
424
+ type: "text",
425
+ required: true,
426
+ label: "Slug",
427
+ admin: {
428
+ description: "The URL-friendly identifier for the post.",
429
+ position: "sidebar",
430
+ autoGenerate: "title"
431
+ }
432
+ },
433
+ {
434
+ name: "tags",
435
+ type: "list",
436
+ label: "Tags",
437
+ admin: {
438
+ description: "Add keywords to help categorize your post.",
439
+ position: "sidebar"
440
+ }
441
+ },
442
+ {
443
+ name: "authors",
444
+ type: "array",
445
+ label: "Authors",
446
+ fields: [
447
+ {
448
+ name: "user",
449
+ type: "relationship",
450
+ label: "User",
451
+ relationTo: "users"
452
+ }
453
+ ],
454
+ admin: {
455
+ description: "Select one or more authors for this post.",
456
+ position: "sidebar"
457
+ }
458
+ },
459
+ {
460
+ name: "featuredImage",
461
+ type: "upload",
462
+ label: "Featured Image",
463
+ relationTo: "media",
464
+ admin: {
465
+ description: "The primary visual used to represent this post.",
466
+ position: "sidebar"
467
+ }
468
+ }
469
+ ],
470
+ timestamps: true,
471
+ versions: {
472
+ drafts: true,
473
+ maxPerDoc: 10
474
+ }
475
+ };
476
+ var postsCollections = {
477
+ posts: postsCollection
478
+ };
479
+
480
+ // src/templates/blocks.ts
481
+ function withUtilityFields(block) {
482
+ return {
483
+ ...block,
484
+ fields: [...block.fields, ...utilityFields]
485
+ };
486
+ }
487
+ var buttonFields = [
488
+ { name: "text", type: "text", label: "Button Label" },
489
+ { name: "url", type: "text", label: "Button Redirection URL" }
490
+ ];
491
+ var buttonsField = {
492
+ name: "buttons",
493
+ type: "array",
494
+ label: "Action Buttons",
495
+ fields: buttonFields
496
+ };
497
+ var headingElement = {
498
+ slug: "heading-element",
499
+ label: "Heading",
500
+ admin: { group: "Basic Content Elements", description: "Section heading" },
501
+ fields: [
502
+ { name: "content", type: "text", label: "Content" }
503
+ ]
504
+ };
505
+ var textElement = {
506
+ slug: "text-element",
507
+ label: "Text",
508
+ admin: { group: "Basic Content Elements", description: "Plain text paragraph" },
509
+ fields: [
510
+ { name: "content", type: "textarea", label: "Content" }
511
+ ]
512
+ };
513
+ var imageElement = {
514
+ slug: "image-element",
515
+ label: "Image",
516
+ admin: { group: "Basic Content Elements", description: "Single image" },
517
+ fields: [
518
+ { name: "image", type: "upload", label: "Image", relationTo: "media" }
519
+ ]
520
+ };
521
+ var richtextElement = {
522
+ slug: "richtext-element",
523
+ label: "Rich Text",
524
+ admin: { group: "Basic Content Elements", description: "Formatted rich text content" },
525
+ fields: [
526
+ { name: "content", type: "richtext", label: "Content" }
527
+ ]
528
+ };
529
+ var buttonElement = {
530
+ slug: "button-element",
531
+ label: "Button",
532
+ admin: { group: "Basic Content Elements", description: "Call-to-action button" },
533
+ fields: [
534
+ {
535
+ name: "buttonData",
536
+ type: "group",
537
+ label: "Button",
538
+ admin: { inline: true },
539
+ fields: [
540
+ { name: "text", type: "text", label: "Label" },
541
+ { name: "url", type: "text", label: "URL" }
542
+ ]
543
+ }
544
+ ]
545
+ };
546
+ var videoElement = {
547
+ slug: "video-element",
548
+ label: "Video",
549
+ admin: { group: "Basic Content Elements", description: "Embedded video player" },
550
+ fields: [
551
+ { name: "url", type: "text", label: "Video URL" },
552
+ { name: "file", type: "upload", label: "Video File", relationTo: "media" },
553
+ { name: "caption", type: "text", label: "Caption" }
554
+ ]
555
+ };
556
+ var listElement = {
557
+ slug: "list-element",
558
+ label: "List",
559
+ admin: { group: "Basic Content Elements", description: "Bulleted or numbered list" },
560
+ fields: [
561
+ {
562
+ name: "items",
563
+ type: "array",
564
+ label: "Items",
565
+ fields: [
566
+ { name: "text", type: "text", label: "Item Text" }
567
+ ]
568
+ }
569
+ ]
570
+ };
571
+ var elementBlocks = [
572
+ headingElement,
573
+ textElement,
574
+ imageElement,
575
+ richtextElement,
576
+ buttonElement,
577
+ videoElement,
578
+ listElement
579
+ ];
580
+ var elementsField = {
581
+ name: "elements",
582
+ type: "blocks",
583
+ label: "Extra Content Elements",
584
+ blocks: elementBlocks,
585
+ admin: { pickerMode: "dropdown" }
586
+ };
587
+ var utilityFields = [elementsField];
588
+ var heroBlock = withUtilityFields({
589
+ slug: "hero",
590
+ admin: { group: "Structural Sections", description: "Primary landing section with heading, text, media & CTA" },
591
+ label: "Hero Section",
592
+ fields: [
593
+ {
594
+ name: "isMultiScreen",
595
+ type: "checkbox",
596
+ label: "Enable Multi-Screen Slides (Carousel)",
597
+ defaultValue: false
598
+ },
599
+ {
600
+ name: "multiSlides",
601
+ type: "group",
602
+ label: "Multi Slides",
603
+ admin: {
604
+ condition: { field: "isMultiScreen", equals: true }
605
+ },
606
+ fields: [
607
+ {
608
+ name: "multiSlides",
609
+ type: "array",
610
+ label: "Hero Slides",
611
+ fields: [
612
+ { name: "heading", type: "text", label: "Slide Heading" },
613
+ { name: "subheading", type: "textarea", label: "Slide Subheading" },
614
+ { name: "backgroundImage", type: "upload", label: "Slide Background Image", relationTo: "media" },
615
+ buttonsField
616
+ ]
617
+ }
618
+ ]
619
+ },
620
+ {
621
+ name: "singleSlide",
622
+ type: "group",
623
+ label: "Single Slide",
624
+ admin: {
625
+ condition: { field: "isMultiScreen", equals: false }
626
+ },
627
+ fields: [
628
+ { name: "heading", type: "text", label: "Heading" },
629
+ { name: "subheading", type: "textarea", label: "Subheading" },
630
+ { name: "backgroundImage", type: "upload", label: "Background Image", relationTo: "media" },
631
+ buttonsField
632
+ ]
633
+ }
634
+ ]
635
+ });
636
+ var cardBlock = withUtilityFields({
637
+ slug: "card",
638
+ admin: { group: "Structural Sections", description: "Modular card block featuring title, text, and optional media" },
639
+ label: "Card Block",
640
+ fields: [
641
+ {
642
+ name: "isMultiCard",
643
+ type: "checkbox",
644
+ label: "Enable Multicard Layout",
645
+ defaultValue: false
646
+ },
647
+ {
648
+ name: "multiCards",
649
+ type: "group",
650
+ label: "Multi Cards",
651
+ admin: {
652
+ condition: { field: "isMultiCard", equals: true }
653
+ },
654
+ fields: [
655
+ {
656
+ name: "cards",
657
+ type: "array",
658
+ label: "Cards List",
659
+ fields: [
660
+ { name: "title", type: "text", label: "Card Title" },
661
+ { name: "description", type: "textarea", label: "Card Description" },
662
+ { name: "image", type: "upload", label: "Card Image", relationTo: "media" },
663
+ { name: "icon", type: "text", label: "Card Icon (Emoji or Name)" },
664
+ { name: "linkText", type: "text", label: "Link Label Text" },
665
+ { name: "link", type: "text", label: "Link Redirection URL" }
666
+ ]
667
+ }
668
+ ]
669
+ },
670
+ {
671
+ name: "singleCard",
672
+ type: "group",
673
+ label: "Single Card",
674
+ admin: {
675
+ condition: { field: "isMultiCard", equals: false }
676
+ },
677
+ fields: [
678
+ { name: "title", type: "text", label: "Title" },
679
+ { name: "description", type: "textarea", label: "Description" },
680
+ { name: "image", type: "upload", label: "Image", relationTo: "media" },
681
+ { name: "icon", type: "text", label: "Icon (Emoji or Name)" },
682
+ { name: "linkText", type: "text", label: "Link Label Text" },
683
+ { name: "link", type: "text", label: "Link Redirection URL" }
684
+ ]
685
+ }
686
+ ]
687
+ });
688
+ withUtilityFields({
689
+ slug: "text",
690
+ admin: { group: "Basic Content Elements", description: "Rich text content" },
691
+ label: "Text Block",
692
+ fields: [
693
+ { name: "content", type: "richtext", label: "Content" }
694
+ ]
695
+ });
696
+ withUtilityFields({
697
+ slug: "image",
698
+ admin: { group: "Basic Content Elements", description: "Image upload container" },
699
+ label: "Image",
700
+ fields: [
701
+ { name: "image", type: "upload", label: "Image", relationTo: "media" },
702
+ { name: "caption", type: "text", label: "Caption" },
703
+ { name: "alt", type: "text", label: "Alt Text" },
704
+ {
705
+ name: "aspectRatio",
706
+ type: "select",
707
+ label: "Aspect Ratio",
708
+ defaultValue: "original",
709
+ options: [
710
+ { label: "Original", value: "original" },
711
+ { label: "16:9 Landscape", value: "16-9" },
712
+ { label: "4:3 Classic", value: "4-3" },
713
+ { label: "1:1 Square", value: "1-1" },
714
+ { label: "2:3 Portrait", value: "2-3" }
715
+ ]
716
+ },
717
+ { name: "enableLightbox", type: "checkbox", label: "Enable Zoom / Lightbox", defaultValue: false }
718
+ ]
719
+ });
720
+ var featureSplitBlock = withUtilityFields({
721
+ slug: "feature-split",
722
+ admin: { group: "Structural Sections", description: "Side-by-side text and media layout" },
723
+ label: "Feature Split (Text & Media)",
724
+ fields: [
725
+ { name: "title", type: "text", label: "Title" },
726
+ { name: "description", type: "richtext", label: "Description" },
727
+ {
728
+ name: "checkpoints",
729
+ type: "array",
730
+ label: "Value Checkpoints",
731
+ fields: [
732
+ { name: "title", type: "text", label: "Checkpoint Title" },
733
+ { name: "description", type: "textarea", label: "Checkpoint Description" },
734
+ { name: "icon", type: "text", label: "Icon Name" },
735
+ { name: "image", type: "upload", label: "Image", relationTo: "media" },
736
+ { name: "itemUrl", type: "text", label: "Link URL" }
737
+ ]
738
+ },
739
+ {
740
+ name: "images",
741
+ type: "array",
742
+ label: "Images",
743
+ fields: [
744
+ { name: "image", type: "upload", label: "Image", relationTo: "media" }
745
+ ]
746
+ },
747
+ buttonsField
748
+ ]
749
+ });
750
+ var featureGridBlock = withUtilityFields({
751
+ slug: "feature-grid",
752
+ admin: { group: "Marketing Grids", description: "Multi-column grid showcasing features or services" },
753
+ label: "Feature Grid",
754
+ fields: [
755
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
756
+ { name: "sectionSubtitle", type: "textarea", label: "Section Subtitle" },
757
+ {
758
+ name: "features",
759
+ type: "array",
760
+ label: "Features List",
761
+ fields: [
762
+ { name: "title", type: "text", label: "Title" },
763
+ { name: "description", type: "textarea", label: "Description" },
764
+ { name: "icon", type: "text", label: "Icon Name" },
765
+ { name: "image", type: "upload", label: "Feature Image", relationTo: "media" },
766
+ { name: "itemUrl", type: "text", label: "Card Redirection URL" }
767
+ ]
768
+ }
769
+ ]
770
+ });
771
+ var ctaBannerBlock = withUtilityFields({
772
+ slug: "cta-banner",
773
+ admin: { group: "Structural Sections", description: "High-impact call-to-action banner" },
774
+ label: "CTA Banner",
775
+ fields: [
776
+ { name: "headline", type: "text", label: "Headline" },
777
+ { name: "subheading", type: "textarea", label: "Subheading" },
778
+ { name: "backgroundImage", type: "upload", label: "Background Image", relationTo: "media" },
779
+ buttonsField
780
+ ]
781
+ });
782
+ var testimonialsBlock = withUtilityFields({
783
+ slug: "testimonials",
784
+ admin: { group: "Marketing Grids", description: "Customer reviews and quotes carousel" },
785
+ label: "Testimonials",
786
+ fields: [
787
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
788
+ {
789
+ name: "items",
790
+ type: "array",
791
+ label: "Testimonials",
792
+ fields: [
793
+ { name: "quote", type: "textarea", label: "Quote" },
794
+ {
795
+ name: "rating",
796
+ type: "select",
797
+ label: "Star Rating",
798
+ defaultValue: "5",
799
+ options: [
800
+ { label: "5 Stars", value: "5" },
801
+ { label: "4 Stars", value: "4" },
802
+ { label: "3 Stars", value: "3" },
803
+ { label: "2 Stars", value: "2" },
804
+ { label: "1 Star", value: "1" }
805
+ ]
806
+ },
807
+ { name: "authorName", type: "text", label: "Author Name" },
808
+ { name: "authorRole", type: "text", label: "Author Role" },
809
+ { name: "avatar", type: "upload", label: "Avatar", relationTo: "media" },
810
+ { name: "companyLogo", type: "upload", label: "Company Logo", relationTo: "media" }
811
+ ]
812
+ }
813
+ ]
814
+ });
815
+ var faqBlock = withUtilityFields({
816
+ slug: "faq",
817
+ admin: { group: "Lead Capture & Interactive", description: "Expandable list of frequently asked questions" },
818
+ label: "FAQ Section",
819
+ fields: [
820
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
821
+ {
822
+ name: "items",
823
+ type: "array",
824
+ label: "Questions List",
825
+ fields: [
826
+ { name: "tag", type: "text", label: "Category Tag (e.g. billing, account)" },
827
+ { name: "question", type: "text", label: "Question" },
828
+ { name: "answer", type: "richtext", label: "Answer" }
829
+ ]
830
+ },
831
+ { name: "footerHeading", type: "text", label: "Footer Heading (e.g. Still have questions?)" },
832
+ { name: "footerCtaUrl", type: "text", label: "Footer CTA Redirection URL" }
833
+ ]
834
+ });
835
+ var statsBlock = withUtilityFields({
836
+ slug: "stats",
837
+ admin: { group: "Marketing Grids", description: "Grid displaying key numerical metrics and stats" },
838
+ label: "Stats / Metrics",
839
+ fields: [
840
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
841
+ {
842
+ name: "items",
843
+ type: "array",
844
+ label: "Stats List",
845
+ fields: [
846
+ { name: "prefix", type: "text", label: "Value Prefix (e.g. + or $)" },
847
+ { name: "value", type: "text", label: "Value (e.g. 99.9 or 5M)" },
848
+ { name: "suffix", type: "text", label: "Value Suffix (e.g. % or users)" },
849
+ { name: "label", type: "text", label: "Label (e.g. Uptime)" },
850
+ { name: "description", type: "textarea", label: "Context Description" }
851
+ ]
852
+ }
853
+ ]
854
+ });
855
+ var logoCloudBlock = withUtilityFields({
856
+ slug: "logo-cloud",
857
+ admin: { group: "Structural Sections", description: "Showcase for partner and client company logos" },
858
+ label: "Logo Cloud / Partners",
859
+ fields: [
860
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
861
+ {
862
+ name: "logos",
863
+ type: "array",
864
+ label: "Logos List",
865
+ fields: [
866
+ { name: "name", type: "text", label: "Company Name" },
867
+ { name: "logo", type: "upload", label: "Logo Image", relationTo: "media" },
868
+ { name: "url", type: "text", label: "Website URL" }
869
+ ]
870
+ }
871
+ ]
872
+ });
873
+ var pricingBlock = withUtilityFields({
874
+ slug: "pricing",
875
+ admin: { group: "Marketing Grids", description: "Tiered pricing plans with feature comparisons" },
876
+ label: "Pricing Plans",
877
+ fields: [
878
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
879
+ { name: "sectionSubtitle", type: "textarea", label: "Section Subtitle" },
880
+ { name: "annualDiscount", type: "text", label: "Annual Promo Tag (e.g. Save 20%)" },
881
+ {
882
+ name: "plans",
883
+ type: "array",
884
+ label: "Pricing Plans",
885
+ fields: [
886
+ { name: "popularBadgeText", type: "text", label: "Plan Badge (e.g. MOST POPULAR)" },
887
+ { name: "name", type: "text", label: "Plan Name" },
888
+ { name: "description", type: "textarea", label: "Plan Description" },
889
+ { name: "currency", type: "text", label: "Plan Currency (e.g. $)", defaultValue: "$" },
890
+ { name: "price", type: "text", label: "Price (e.g. 29)" },
891
+ { name: "billingPeriod", type: "text", label: "Billing Period (e.g. /mo)" },
892
+ { name: "features", type: "list", label: "Features Checklist" },
893
+ buttonsField,
894
+ { name: "footnote", type: "text", label: "Footnote note (e.g. *cancel anytime)" },
895
+ { name: "isFeatured", type: "checkbox", label: "Highlight Plan (Featured)", defaultValue: false }
896
+ ]
897
+ }
898
+ ]
899
+ });
900
+ var teamBlock = withUtilityFields({
901
+ slug: "team",
902
+ admin: { group: "Marketing Grids", description: "Showcase of team members with photos and roles" },
903
+ label: "Team Showcase",
904
+ fields: [
905
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
906
+ { name: "sectionSubtitle", type: "textarea", label: "Section Subtitle" },
907
+ {
908
+ name: "members",
909
+ type: "array",
910
+ label: "Team Members",
911
+ fields: [
912
+ { name: "name", type: "text", label: "Member Name" },
913
+ { name: "role", type: "text", label: "Role / Position" },
914
+ { name: "department", type: "text", label: "Department / Team tag (e.g. engineering, design)" },
915
+ { name: "avatar", type: "upload", label: "Avatar Image", relationTo: "media" },
916
+ { name: "bio", type: "textarea", label: "Brief Bio" },
917
+ { name: "twitterUrl", type: "text", label: "Twitter URL" },
918
+ { name: "linkedinUrl", type: "text", label: "LinkedIn URL" },
919
+ { name: "githubUrl", type: "text", label: "GitHub URL" },
920
+ { name: "websiteUrl", type: "text", label: "Website URL" }
921
+ ]
922
+ }
923
+ ]
924
+ });
925
+ var recentFeedBlock = withUtilityFields({
926
+ slug: "recent-feed",
927
+ admin: { group: "Dynamic Content", description: "Dynamic feed of recent blog posts or articles" },
928
+ label: "Recent Posts Feed",
929
+ fields: [
930
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
931
+ { name: "sectionSubtitle", type: "textarea", label: "Section Subtitle" },
932
+ {
933
+ name: "collectionType",
934
+ type: "select",
935
+ label: "Feed Source Collection",
936
+ dynamicOptions: "collections"
937
+ },
938
+ { name: "categoryFilter", type: "text", label: "Filter results by category slug / tag" },
939
+ { name: "limit", type: "number", label: "Max Items to Show", defaultValue: 3 },
940
+ buttonsField
941
+ ]
942
+ });
943
+ var processStepsBlock = withUtilityFields({
944
+ slug: "process-steps",
945
+ admin: { group: "Lead Capture & Interactive", description: "Numbered sequence illustrating a process or workflow" },
946
+ label: "Process Steps / Timeline",
947
+ fields: [
948
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
949
+ { name: "sectionSubtitle", type: "textarea", label: "Section Subtitle" },
950
+ {
951
+ name: "steps",
952
+ type: "array",
953
+ label: "Steps",
954
+ fields: [
955
+ { name: "stepNumber", type: "text", label: "Step Number (e.g. 01)" },
956
+ { name: "icon", type: "upload", label: "Step Icon / Image", relationTo: "media" },
957
+ { name: "title", type: "text", label: "Step Title" },
958
+ { name: "description", type: "textarea", label: "Description" }
959
+ ]
960
+ }
961
+ ]
962
+ });
963
+ var formEmbedBlock = withUtilityFields({
964
+ slug: "form-embed",
965
+ admin: { group: "Lead Capture & Interactive", description: "Embeddable interactive forms for lead capture" },
966
+ label: "Form Embed",
967
+ fields: [
968
+ { name: "title", type: "text", label: "Form Title" },
969
+ { name: "subtitle", type: "textarea", label: "Form Subtitle" },
970
+ {
971
+ name: "form",
972
+ type: "relationship",
973
+ relationTo: "forms",
974
+ label: "Form",
975
+ required: true
976
+ }
977
+ ]
978
+ });
979
+ var videoShowcaseBlock = withUtilityFields({
980
+ slug: "video-showcase",
981
+ admin: { group: "Structural Sections", description: "Cinematic video player with custom thumbnail" },
982
+ label: "Cinematic Video Showcase",
983
+ fields: [
984
+ { name: "sectionTitle", type: "text", label: "Section Heading" },
985
+ { name: "sectionSubtitle", type: "textarea", label: "Section Subtitle" },
986
+ { name: "coverImage", type: "upload", label: "Cinematic Cover Image (Thumbnail)", relationTo: "media" },
987
+ { name: "videoUrl", type: "text", label: "Video Embed URL (YouTube / Vimeo / MP4)" },
988
+ { name: "videoTitle", type: "text", label: "Video Title (for accessibility & hover text)" },
989
+ { name: "durationBadge", type: "text", label: "Duration Badge (e.g. '\u25B6 2:34')" },
990
+ { name: "isLightbox", type: "checkbox", label: "Open in Cinematic Lightbox Modal", defaultValue: true },
991
+ { name: "autoplay", type: "checkbox", label: "Autoplay Video (muted)", defaultValue: false }
992
+ ]
993
+ });
994
+ var coreSemanticBlocks = [
995
+ heroBlock,
996
+ cardBlock,
997
+ featureSplitBlock,
998
+ featureGridBlock,
999
+ ctaBannerBlock,
1000
+ testimonialsBlock,
1001
+ faqBlock,
1002
+ statsBlock,
1003
+ logoCloudBlock,
1004
+ pricingBlock,
1005
+ teamBlock,
1006
+ recentFeedBlock,
1007
+ processStepsBlock,
1008
+ formEmbedBlock,
1009
+ videoShowcaseBlock
1010
+ ];
1011
+
1012
+ // src/templates/pages.ts
1013
+ var pageCollection = {
1014
+ slug: "pages",
1015
+ label: "Pages",
1016
+ labelPlural: "Pages",
1017
+ singularLabel: "Page",
1018
+ admin: {
1019
+ useAsTitle: "title",
1020
+ defaultColumns: ["title", "slug", "publishStatus", "updatedAt"],
1021
+ description: "Static pages"
1022
+ },
1023
+ fields: [
1024
+ {
1025
+ name: "mainTabs",
1026
+ type: "tabs",
1027
+ tabs: [
1028
+ {
1029
+ label: "Content",
1030
+ fields: [
1031
+ {
1032
+ name: "title",
1033
+ type: "text",
1034
+ required: true,
1035
+ label: "Title",
1036
+ admin: {
1037
+ description: "The main title of the page as it will appear publicly."
1038
+ }
1039
+ },
1040
+ {
1041
+ name: "content",
1042
+ type: "blocks",
1043
+ label: "Content",
1044
+ blocks: coreSemanticBlocks
1045
+ }
1046
+ ]
1047
+ },
1048
+ {
1049
+ label: "Meta",
1050
+ fields: []
1051
+ },
1052
+ {
1053
+ label: "SEO",
1054
+ fields: [
1055
+ {
1056
+ name: "metaTitle",
1057
+ type: "text",
1058
+ label: "Meta Title",
1059
+ admin: { autoGenerate: "title" }
1060
+ },
1061
+ {
1062
+ name: "metaDescription",
1063
+ type: "textarea",
1064
+ label: "Meta Description",
1065
+ admin: { autoGenerate: "content" }
1066
+ },
1067
+ {
1068
+ name: "ogImage",
1069
+ type: "upload",
1070
+ label: "OG Image",
1071
+ relationTo: "media"
1072
+ }
1073
+ ]
1074
+ }
1075
+ ]
1076
+ },
1077
+ {
1078
+ name: "slug",
1079
+ type: "text",
1080
+ required: true,
1081
+ label: "Slug",
1082
+ admin: { position: "sidebar", autoGenerate: "title" }
1083
+ },
1084
+ {
1085
+ name: "featuredImage",
1086
+ type: "upload",
1087
+ label: "Featured Image",
1088
+ relationTo: "media",
1089
+ admin: { position: "sidebar" }
1090
+ }
1091
+ ],
1092
+ timestamps: true,
1093
+ versions: {
1094
+ drafts: true,
1095
+ maxPerDoc: 10
1096
+ }
1097
+ };
1098
+ var pageCollections = {
1099
+ pages: pageCollection
1100
+ };
1101
+
1102
+ // src/templates/categories.ts
1103
+ var categoriesCollection = {
1104
+ slug: "categories",
1105
+ label: "Categories",
1106
+ labelPlural: "Categories",
1107
+ singularLabel: "Category",
1108
+ admin: {
1109
+ useAsTitle: "name",
1110
+ defaultColumns: ["name", "slug"],
1111
+ description: "Post categories",
1112
+ layout: "split"
1113
+ },
1114
+ fields: [
1115
+ { name: "name", type: "text", required: true, label: "Name" },
1116
+ {
1117
+ name: "description",
1118
+ type: "textarea",
1119
+ label: "Description"
1120
+ },
1121
+ {
1122
+ name: "slug",
1123
+ type: "text",
1124
+ required: true,
1125
+ label: "Slug",
1126
+ admin: { position: "sidebar", autoGenerate: "name" }
1127
+ },
1128
+ {
1129
+ name: "icon",
1130
+ type: "upload",
1131
+ label: "Icon",
1132
+ relationTo: "media",
1133
+ admin: { position: "sidebar" }
1134
+ },
1135
+ {
1136
+ name: "parent",
1137
+ type: "relationship",
1138
+ label: "Parent Category",
1139
+ relationTo: "categories",
1140
+ admin: { position: "sidebar" }
1141
+ },
1142
+ {
1143
+ name: "order",
1144
+ type: "number",
1145
+ label: "Order",
1146
+ defaultValue: 0,
1147
+ admin: { position: "sidebar" }
1148
+ }
1149
+ ],
1150
+ timestamps: true,
1151
+ versions: {
1152
+ drafts: true,
1153
+ maxPerDoc: 5
1154
+ }
1155
+ };
1156
+ var categoriesCollections = {
1157
+ categories: categoriesCollection
1158
+ };
1159
+ var productCategoriesCollection = {
1160
+ slug: "product-categories",
1161
+ label: "Product Categories",
1162
+ labelPlural: "Product Categories",
1163
+ singularLabel: "Product Category",
1164
+ admin: {
1165
+ useAsTitle: "name",
1166
+ defaultColumns: ["name", "slug"],
1167
+ description: "Product categories for organizing your catalog"
1168
+ },
1169
+ fields: [
1170
+ { name: "name", type: "text", required: true, label: "Name" },
1171
+ {
1172
+ name: "slug",
1173
+ type: "text",
1174
+ required: true,
1175
+ label: "Slug",
1176
+ admin: { position: "sidebar", autoGenerate: "name" }
1177
+ },
1178
+ {
1179
+ name: "description",
1180
+ type: "textarea",
1181
+ label: "Description"
1182
+ },
1183
+ { name: "image", type: "text", label: "Image URL" },
1184
+ {
1185
+ name: "parent",
1186
+ type: "relationship",
1187
+ label: "Parent Category",
1188
+ relationTo: "product-categories",
1189
+ admin: { position: "sidebar" }
1190
+ }
1191
+ ],
1192
+ timestamps: true,
1193
+ versions: {
1194
+ drafts: true,
1195
+ maxPerDoc: 5
1196
+ }
1197
+ };
1198
+ var productCategoriesCollections = {
1199
+ "product-categories": productCategoriesCollection
1200
+ };
1201
+
1202
+ // src/templates/products.ts
1203
+ var productsCollection = {
1204
+ slug: "products",
1205
+ label: "Products",
1206
+ labelPlural: "Products",
1207
+ singularLabel: "Product",
1208
+ admin: {
1209
+ useAsTitle: "title",
1210
+ defaultColumns: ["title", "slug", "price", "publishStatus", "inventory", "updatedAt"],
1211
+ description: "Product catalog"
1212
+ },
1213
+ fields: [
1214
+ { name: "title", type: "text", required: true, label: "Title" },
1215
+ {
1216
+ name: "slug",
1217
+ type: "text",
1218
+ required: true,
1219
+ label: "Slug",
1220
+ admin: { position: "sidebar", autoGenerate: "title" }
1221
+ },
1222
+ { name: "description", type: "richtext", label: "Description" },
1223
+ { name: "price", type: "number", required: true, label: "Price" },
1224
+ {
1225
+ name: "compareAtPrice",
1226
+ type: "number",
1227
+ label: "Compare at Price",
1228
+ admin: { description: "Original price for sale display" }
1229
+ },
1230
+ {
1231
+ name: "costPrice",
1232
+ type: "number",
1233
+ label: "Cost Price",
1234
+ admin: { description: "For profit calculation" }
1235
+ },
1236
+ { name: "sku", type: "text", required: true, label: "SKU" },
1237
+ { name: "barcode", type: "text", label: "Barcode" },
1238
+ {
1239
+ name: "images",
1240
+ type: "array",
1241
+ label: "Images",
1242
+ fields: [
1243
+ { name: "url", type: "text", label: "URL" },
1244
+ { name: "alt", type: "text", label: "Alt Text" }
1245
+ ]
1246
+ },
1247
+ {
1248
+ name: "category",
1249
+ type: "relationship",
1250
+ label: "Category",
1251
+ relationTo: "product-categories"
1252
+ },
1253
+ {
1254
+ name: "inventory",
1255
+ type: "number",
1256
+ label: "Inventory",
1257
+ defaultValue: 0
1258
+ }
1259
+ ],
1260
+ timestamps: true,
1261
+ versions: {
1262
+ drafts: true,
1263
+ maxPerDoc: 10
1264
+ }
1265
+ };
1266
+ var productsCollections = {
1267
+ products: productsCollection
1268
+ };
1269
+
1270
+ // src/templates/customers.ts
1271
+ var customersCollection = {
1272
+ slug: "customers",
1273
+ label: "Customers",
1274
+ labelPlural: "Customers",
1275
+ singularLabel: "Customer",
1276
+ admin: {
1277
+ useAsTitle: "email",
1278
+ defaultColumns: [
1279
+ "email",
1280
+ "firstName",
1281
+ "lastName",
1282
+ "createdAt",
1283
+ "updatedAt"
1284
+ ],
1285
+ description: "Customer accounts"
1286
+ },
1287
+ fields: [
1288
+ { name: "email", type: "email", required: true, label: "Email" },
1289
+ { name: "firstName", type: "text", label: "First Name" },
1290
+ { name: "lastName", type: "text", label: "Last Name" },
1291
+ { name: "phone", type: "text", label: "Phone" },
1292
+ {
1293
+ name: "addresses",
1294
+ type: "array",
1295
+ label: "Addresses",
1296
+ fields: [
1297
+ { name: "type", type: "text", label: "Type" },
1298
+ { name: "line1", type: "text", label: "Address Line 1" },
1299
+ { name: "line2", type: "text", label: "Address Line 2" },
1300
+ { name: "city", type: "text", label: "City" },
1301
+ { name: "state", type: "text", label: "State" },
1302
+ { name: "postalCode", type: "text", label: "Postal Code" },
1303
+ { name: "country", type: "text", label: "Country" }
1304
+ ]
1305
+ },
1306
+ {
1307
+ name: "slug",
1308
+ type: "text",
1309
+ required: true,
1310
+ label: "Slug",
1311
+ admin: { position: "sidebar", autoGenerate: "email" }
1312
+ }
1313
+ ],
1314
+ timestamps: true,
1315
+ versions: {
1316
+ drafts: true,
1317
+ maxPerDoc: 5
1318
+ }
1319
+ };
1320
+ var customersCollections = {
1321
+ customers: customersCollection
1322
+ };
1323
+
1324
+ // src/templates/orders.ts
1325
+ var ordersCollection = {
1326
+ slug: "orders",
1327
+ label: "Orders",
1328
+ labelPlural: "Orders",
1329
+ singularLabel: "Order",
1330
+ admin: {
1331
+ useAsTitle: "orderNumber",
1332
+ defaultColumns: [
1333
+ "orderNumber",
1334
+ "customer",
1335
+ "publishStatus",
1336
+ "total",
1337
+ "createdAt",
1338
+ "updatedAt"
1339
+ ],
1340
+ description: "Customer orders"
1341
+ },
1342
+ fields: [
1343
+ {
1344
+ name: "orderNumber",
1345
+ type: "text",
1346
+ required: true,
1347
+ label: "Order Number"
1348
+ },
1349
+ {
1350
+ name: "customer",
1351
+ type: "relationship",
1352
+ required: true,
1353
+ label: "Customer",
1354
+ relationTo: "customers"
1355
+ },
1356
+ {
1357
+ name: "paymentStatus",
1358
+ type: "select",
1359
+ label: "Payment Status",
1360
+ options: [
1361
+ { label: "Pending", value: "pending" },
1362
+ { label: "Paid", value: "paid" },
1363
+ { label: "Failed", value: "failed" },
1364
+ { label: "Refunded", value: "refunded" }
1365
+ ],
1366
+ defaultValue: "pending"
1367
+ },
1368
+ {
1369
+ name: "items",
1370
+ type: "array",
1371
+ label: "Items",
1372
+ fields: [
1373
+ { name: "product", type: "text", label: "Product" },
1374
+ { name: "quantity", type: "number", label: "Quantity" },
1375
+ { name: "unitPrice", type: "number", label: "Unit Price" },
1376
+ { name: "total", type: "number", label: "Total" }
1377
+ ]
1378
+ },
1379
+ { name: "subtotal", type: "number", required: true, label: "Subtotal" },
1380
+ { name: "tax", type: "number", label: "Tax" },
1381
+ { name: "shipping", type: "number", label: "Shipping" },
1382
+ { name: "discount", type: "number", label: "Discount" },
1383
+ { name: "total", type: "number", required: true, label: "Total" },
1384
+ { name: "notes", type: "richtext", label: "Notes" },
1385
+ {
1386
+ name: "slug",
1387
+ type: "text",
1388
+ required: true,
1389
+ label: "Slug",
1390
+ admin: { position: "sidebar", autoGenerate: "orderNumber" }
1391
+ }
1392
+ ],
1393
+ timestamps: true,
1394
+ versions: {
1395
+ drafts: true,
1396
+ maxPerDoc: 10
1397
+ }
1398
+ };
1399
+ var ordersCollections = {
1400
+ orders: ordersCollection
1401
+ };
1402
+
1403
+ // src/templates/coupons.ts
1404
+ var couponsCollection = {
1405
+ slug: "coupons",
1406
+ label: "Coupons",
1407
+ labelPlural: "Coupons",
1408
+ singularLabel: "Coupon",
1409
+ admin: {
1410
+ useAsTitle: "code",
1411
+ defaultColumns: ["code", "type", "value", "active", "expiresAt"],
1412
+ description: "Discount codes and promotions"
1413
+ },
1414
+ fields: [
1415
+ { name: "code", type: "text", required: true, label: "Code" },
1416
+ {
1417
+ name: "type",
1418
+ type: "select",
1419
+ required: true,
1420
+ label: "Type",
1421
+ options: [
1422
+ { label: "Percentage", value: "percentage" },
1423
+ { label: "Fixed Amount", value: "fixed" },
1424
+ { label: "Free Shipping", value: "freeShipping" }
1425
+ ]
1426
+ },
1427
+ { name: "value", type: "number", label: "Value" },
1428
+ { name: "minPurchase", type: "number", label: "Minimum Purchase" },
1429
+ { name: "maxDiscount", type: "number", label: "Max Discount" },
1430
+ { name: "usageLimit", type: "number", label: "Usage Limit" },
1431
+ {
1432
+ name: "usedCount",
1433
+ type: "number",
1434
+ defaultValue: 0,
1435
+ label: "Used Count"
1436
+ },
1437
+ { name: "startsAt", type: "date", label: "Starts At" },
1438
+ { name: "expiresAt", type: "date", label: "Expires At" },
1439
+ { name: "active", type: "checkbox", defaultValue: true, label: "Active" }
1440
+ ],
1441
+ timestamps: true,
1442
+ versions: {
1443
+ drafts: true,
1444
+ maxPerDoc: 5
1445
+ }
1446
+ };
1447
+ var couponsCollections = {
1448
+ coupons: couponsCollection
1449
+ };
1450
+
1451
+ // src/templates/forms.ts
1452
+ var formsCollection = {
1453
+ slug: "forms",
1454
+ label: "Forms",
1455
+ labelPlural: "Forms",
1456
+ singularLabel: "Form",
1457
+ admin: {
1458
+ useAsTitle: "name",
1459
+ defaultColumns: ["name", "slug", "updatedAt"],
1460
+ description: "Reusable form definitions"
1461
+ },
1462
+ fields: [
1463
+ { name: "name", type: "text", required: true, label: "Name" },
1464
+ { name: "subtitle", type: "textarea", label: "Subtitle" },
1465
+ {
1466
+ name: "slug",
1467
+ type: "text",
1468
+ required: true,
1469
+ label: "Slug",
1470
+ admin: { position: "sidebar", autoGenerate: "name" }
1471
+ },
1472
+ {
1473
+ name: "submitButtonText",
1474
+ type: "text",
1475
+ label: "Submit Button Text",
1476
+ defaultValue: "Submit",
1477
+ admin: { position: "sidebar" }
1478
+ },
1479
+ {
1480
+ name: "consentCheckboxText",
1481
+ type: "text",
1482
+ label: "Consent Agreement label (e.g. I agree to terms)",
1483
+ admin: { position: "sidebar" }
1484
+ },
1485
+ {
1486
+ name: "redirectUrl",
1487
+ type: "text",
1488
+ label: "Success Redirect URL",
1489
+ admin: { position: "sidebar" }
1490
+ },
1491
+ {
1492
+ name: "fields",
1493
+ type: "array",
1494
+ label: "Form Fields",
1495
+ fields: [
1496
+ {
1497
+ name: "fieldName",
1498
+ type: "text",
1499
+ label: "Field API Name (e.g. company)"
1500
+ },
1501
+ {
1502
+ name: "inputType",
1503
+ type: "select",
1504
+ label: "Input Type",
1505
+ defaultValue: "text",
1506
+ options: [
1507
+ { label: "Text input", value: "text" },
1508
+ { label: "Email input", value: "email" },
1509
+ { label: "Phone number input", value: "tel" },
1510
+ { label: "Multi-line textarea", value: "textarea" },
1511
+ { label: "Checkbox selector", value: "checkbox" }
1512
+ ]
1513
+ },
1514
+ {
1515
+ name: "placeholder",
1516
+ type: "text",
1517
+ label: "Input Placeholder Text"
1518
+ },
1519
+ {
1520
+ name: "isRequired",
1521
+ type: "checkbox",
1522
+ label: "Make this field required",
1523
+ defaultValue: false
1524
+ }
1525
+ ]
1526
+ },
1527
+ {
1528
+ name: "entries",
1529
+ type: "relationship",
1530
+ relationTo: "form-entries",
1531
+ hasMany: true,
1532
+ label: "Entries",
1533
+ admin: {
1534
+ description: "Form submissions linked to this form."
1535
+ }
1536
+ }
1537
+ ],
1538
+ timestamps: true,
1539
+ versions: {
1540
+ drafts: true,
1541
+ maxPerDoc: 5
1542
+ }
1543
+ };
1544
+ var formsCollections = {
1545
+ forms: formsCollection
1546
+ };
1547
+
1548
+ // src/templates/form-entries.ts
1549
+ var formEntriesCollection = {
1550
+ slug: "form-entries",
1551
+ label: "Form Entries",
1552
+ labelPlural: "Form Entries",
1553
+ singularLabel: "Form Entry",
1554
+ admin: {
1555
+ useAsTitle: "id",
1556
+ defaultColumns: ["id", "form", "createdAt", "ipAddress"],
1557
+ description: "Form submission entries"
1558
+ },
1559
+ fields: [
1560
+ {
1561
+ name: "form",
1562
+ type: "relationship",
1563
+ relationTo: "forms",
1564
+ required: true,
1565
+ label: "Form",
1566
+ admin: {
1567
+ position: "sidebar",
1568
+ readOnly: true,
1569
+ description: "The form this entry belongs to."
1570
+ }
1571
+ },
1572
+ {
1573
+ name: "data",
1574
+ type: "json",
1575
+ label: "Submitted Data",
1576
+ admin: {
1577
+ readOnly: true,
1578
+ description: "All field values submitted with this entry."
1579
+ }
1580
+ },
1581
+ {
1582
+ name: "ipAddress",
1583
+ type: "text",
1584
+ label: "IP Address",
1585
+ admin: {
1586
+ position: "sidebar",
1587
+ readOnly: true,
1588
+ description: "The IP address of the submitter."
1589
+ }
1590
+ }
1591
+ ],
1592
+ timestamps: true
1593
+ };
1594
+ var formEntriesCollections = {
1595
+ "form-entries": formEntriesCollection
1596
+ };
1597
+
1598
+ // src/templates/settings/site.ts
1599
+ var siteSettingsGlobal = {
1600
+ slug: "site-settings",
1601
+ label: "Site Settings",
1602
+ admin: {
1603
+ group: "settings"
1604
+ },
1605
+ access: {
1606
+ read: () => true,
1607
+ update: () => true
1608
+ },
1609
+ fields: [
1610
+ {
1611
+ name: "siteName",
1612
+ type: "text",
1613
+ label: "Site Name",
1614
+ required: true,
1615
+ admin: {}
1616
+ },
1617
+ {
1618
+ name: "siteDescription",
1619
+ type: "textarea",
1620
+ label: "Site Description",
1621
+ admin: {
1622
+ placeholder: "Enter a brief description of your site for SEO and search results."
1623
+ }
1624
+ },
1625
+ {
1626
+ name: "siteLogo",
1627
+ type: "upload",
1628
+ label: "Site Logo",
1629
+ relationTo: "media"
1630
+ },
1631
+ {
1632
+ name: "siteFavicon",
1633
+ type: "upload",
1634
+ label: "Favicon",
1635
+ relationTo: "media"
1636
+ },
1637
+ {
1638
+ name: "siteOgImage",
1639
+ type: "upload",
1640
+ label: "Default OG Image",
1641
+ relationTo: "media"
1642
+ },
1643
+ {
1644
+ name: "siteUrl",
1645
+ type: "text",
1646
+ label: "Site URL",
1647
+ admin: {}
1648
+ },
1649
+ {
1650
+ name: "maintenanceEnabled",
1651
+ type: "checkbox",
1652
+ label: "Enable Maintenance Mode",
1653
+ defaultValue: false,
1654
+ admin: {
1655
+ description: "When enabled, the public site will show a maintenance page."
1656
+ }
1657
+ },
1658
+ {
1659
+ name: "maintenance",
1660
+ type: "group",
1661
+ label: "Maintenance Configuration",
1662
+ admin: {
1663
+ condition: (data) => data.maintenanceEnabled === true
1664
+ },
1665
+ fields: [
1666
+ {
1667
+ name: "message",
1668
+ type: "textarea",
1669
+ label: "Maintenance Message",
1670
+ admin: {
1671
+ placeholder: "We'll be back soon! We're performing scheduled maintenance."
1672
+ }
1673
+ },
1674
+ {
1675
+ name: "bypassToken",
1676
+ type: "text",
1677
+ label: "Bypass Token",
1678
+ admin: {
1679
+ description: "Append ?bypass=YOUR_TOKEN to URL to view the site while in maintenance mode."
1680
+ }
1681
+ }
1682
+ ]
1683
+ },
1684
+ {
1685
+ name: "enableI18n",
1686
+ type: "checkbox",
1687
+ label: "Enable Internationalization (i18n)",
1688
+ defaultValue: false,
1689
+ admin: {
1690
+ description: "Enable support for multiple languages."
1691
+ }
1692
+ },
1693
+ {
1694
+ name: "i18n",
1695
+ type: "group",
1696
+ label: "Localization",
1697
+ admin: {
1698
+ condition: (data) => data.enableI18n === true
1699
+ },
1700
+ fields: [
1701
+ {
1702
+ name: "language",
1703
+ type: "select",
1704
+ label: "Default Language",
1705
+ defaultValue: "en",
1706
+ options: [
1707
+ { label: "English", value: "en" },
1708
+ { label: "Spanish", value: "es" },
1709
+ { label: "French", value: "fr" },
1710
+ { label: "German", value: "de" },
1711
+ { label: "Portuguese", value: "pt" },
1712
+ { label: "Italian", value: "it" },
1713
+ { label: "Dutch", value: "nl" },
1714
+ { label: "Russian", value: "ru" },
1715
+ { label: "Japanese", value: "ja" },
1716
+ { label: "Chinese", value: "zh" },
1717
+ { label: "Korean", value: "ko" },
1718
+ { label: "Arabic", value: "ar" }
1719
+ ]
1720
+ },
1721
+ {
1722
+ name: "timezone",
1723
+ type: "text",
1724
+ label: "Timezone",
1725
+ defaultValue: "UTC"
1726
+ }
1727
+ ]
1728
+ },
1729
+ {
1730
+ name: "logo",
1731
+ type: "group",
1732
+ label: "Logo Display Settings",
1733
+ fields: [
1734
+ {
1735
+ name: "width",
1736
+ type: "number",
1737
+ label: "Max Width (px)"
1738
+ },
1739
+ {
1740
+ name: "height",
1741
+ type: "number",
1742
+ label: "Max Height (px)"
1743
+ },
1744
+ {
1745
+ name: "altText",
1746
+ type: "text",
1747
+ label: "Alt Text"
1748
+ }
1749
+ ]
1750
+ },
1751
+ {
1752
+ name: "analyticsEnabled",
1753
+ type: "checkbox",
1754
+ label: "Enable Analytics & Tracking",
1755
+ defaultValue: false
1756
+ },
1757
+ {
1758
+ name: "analytics",
1759
+ type: "group",
1760
+ label: "Tracking Configurations",
1761
+ admin: {
1762
+ condition: (data) => data.analyticsEnabled === true
1763
+ },
1764
+ fields: [
1765
+ {
1766
+ name: "googleAnalyticsId",
1767
+ type: "text",
1768
+ label: "Google Analytics ID"
1769
+ },
1770
+ {
1771
+ name: "googleTagManagerId",
1772
+ type: "text",
1773
+ label: "Google Tag Manager ID"
1774
+ },
1775
+ {
1776
+ name: "plausibleDomain",
1777
+ type: "text",
1778
+ label: "Plausible Domain"
1779
+ },
1780
+ {
1781
+ name: "mixpanelToken",
1782
+ type: "password",
1783
+ label: "Mixpanel Token"
1784
+ }
1785
+ ]
1786
+ }
1787
+ ]
1788
+ };
1789
+
1790
+ // src/templates/settings/seo.ts
1791
+ var seoSettingsGlobal = {
1792
+ slug: "seo-settings",
1793
+ label: "SEO Settings",
1794
+ admin: {
1795
+ group: "settings"
1796
+ },
1797
+ access: {
1798
+ read: () => true,
1799
+ update: () => true
1800
+ },
1801
+ fields: [
1802
+ {
1803
+ name: "seoMode",
1804
+ type: "select",
1805
+ label: "Visibility Mode",
1806
+ defaultValue: "simple",
1807
+ options: [
1808
+ { label: "Simple (Basic Meta)", value: "simple" },
1809
+ { label: "Advanced (Full Technical SEO)", value: "advanced" }
1810
+ ],
1811
+ admin: {
1812
+ description: "Switch to advanced mode to control robots.txt, canonical URLs, and deep metadata."
1813
+ }
1814
+ },
1815
+ {
1816
+ name: "defaultTitle",
1817
+ type: "text",
1818
+ label: "Default Title",
1819
+ admin: {}
1820
+ },
1821
+ {
1822
+ name: "defaultDescription",
1823
+ type: "textarea",
1824
+ label: "Default Description",
1825
+ admin: {}
1826
+ },
1827
+ {
1828
+ name: "titleTemplate",
1829
+ type: "text",
1830
+ label: "Title Template",
1831
+ defaultValue: "{{title}} | {{siteName}}",
1832
+ admin: {}
1833
+ },
1834
+ {
1835
+ name: "siteNameInTitle",
1836
+ type: "checkbox",
1837
+ label: "Include Site Name in Title",
1838
+ defaultValue: true
1839
+ },
1840
+ {
1841
+ name: "separator",
1842
+ type: "text",
1843
+ label: "Title Separator",
1844
+ defaultValue: " | ",
1845
+ admin: {}
1846
+ },
1847
+ {
1848
+ name: "meta",
1849
+ type: "group",
1850
+ label: "Technical Meta Settings",
1851
+ admin: {
1852
+ condition: (data) => data.seoMode === "advanced"
1853
+ },
1854
+ fields: [
1855
+ {
1856
+ name: "robots",
1857
+ type: "text",
1858
+ label: "Robots Meta",
1859
+ defaultValue: "index, follow"
1860
+ },
1861
+ {
1862
+ name: "canonicalUrl",
1863
+ type: "text",
1864
+ label: "Canonical URL"
1865
+ },
1866
+ {
1867
+ name: "ogType",
1868
+ type: "select",
1869
+ label: "Default OG Type",
1870
+ defaultValue: "website",
1871
+ options: [
1872
+ { label: "Website", value: "website" },
1873
+ { label: "Article", value: "article" },
1874
+ { label: "Product", value: "product" },
1875
+ { label: "Book", value: "book" },
1876
+ { label: "Music", value: "music" },
1877
+ { label: "Video", value: "video" }
1878
+ ]
1879
+ }
1880
+ ]
1881
+ },
1882
+ {
1883
+ name: "enableSitemap",
1884
+ type: "checkbox",
1885
+ label: "Enable XML Sitemap",
1886
+ defaultValue: true
1887
+ },
1888
+ {
1889
+ name: "sitemap",
1890
+ type: "group",
1891
+ label: "Sitemap Configuration",
1892
+ admin: {
1893
+ condition: (data) => data.enableSitemap === true && data.seoMode === "advanced"
1894
+ },
1895
+ fields: [
1896
+ {
1897
+ name: "sitemapUrls",
1898
+ type: "number",
1899
+ label: "Sitemap URL Limit",
1900
+ defaultValue: 5e4
1901
+ }
1902
+ ]
1903
+ },
1904
+ {
1905
+ name: "robotsTxt",
1906
+ type: "textarea",
1907
+ label: "Custom robots.txt",
1908
+ admin: {
1909
+ condition: (data) => data.seoMode === "advanced"
1910
+ }
1911
+ },
1912
+ {
1913
+ name: "social",
1914
+ type: "group",
1915
+ label: "Social Media",
1916
+ fields: [
1917
+ {
1918
+ name: "twitterHandle",
1919
+ type: "text",
1920
+ label: "Twitter/X Handle",
1921
+ admin: {}
1922
+ },
1923
+ {
1924
+ name: "twitterCardType",
1925
+ type: "select",
1926
+ label: "Twitter Card Type",
1927
+ defaultValue: "summary_large_image",
1928
+ options: [
1929
+ { label: "Summary", value: "summary" },
1930
+ { label: "Summary with Large Image", value: "summary_large_image" },
1931
+ { label: "App", value: "app" },
1932
+ { label: "Player", value: "player" }
1933
+ ]
1934
+ },
1935
+ {
1936
+ name: "fbAppId",
1937
+ type: "text",
1938
+ label: "Facebook App ID"
1939
+ }
1940
+ ]
1941
+ },
1942
+ {
1943
+ name: "advanced",
1944
+ type: "group",
1945
+ label: "Advanced",
1946
+ fields: [
1947
+ {
1948
+ name: "jsonLdEnabled",
1949
+ type: "checkbox",
1950
+ label: "Enable JSON-LD",
1951
+ defaultValue: true,
1952
+ admin: {}
1953
+ },
1954
+ {
1955
+ name: "breadcrumbsEnabled",
1956
+ type: "checkbox",
1957
+ label: "Enable Breadcrumbs",
1958
+ defaultValue: true
1959
+ },
1960
+ {
1961
+ name: "paginationSize",
1962
+ type: "number",
1963
+ label: "Default Pagination Size",
1964
+ defaultValue: 10
1965
+ }
1966
+ ]
1967
+ }
1968
+ ]
1969
+ };
1970
+
1971
+ // src/templates/settings/social.ts
1972
+ var socialSettingsGlobal = {
1973
+ slug: "social-settings",
1974
+ label: "Social Media",
1975
+ admin: {
1976
+ group: "settings"
1977
+ },
1978
+ access: {
1979
+ read: () => true,
1980
+ update: () => true
1981
+ },
1982
+ fields: [
1983
+ {
1984
+ name: "showAll",
1985
+ type: "checkbox",
1986
+ label: "Show All Platforms",
1987
+ defaultValue: false,
1988
+ admin: {
1989
+ description: "Toggle to show niche or secondary social platforms."
1990
+ }
1991
+ },
1992
+ {
1993
+ name: "facebook",
1994
+ type: "text",
1995
+ label: "Facebook"
1996
+ },
1997
+ {
1998
+ name: "twitter",
1999
+ type: "text",
2000
+ label: "Twitter/X"
2001
+ },
2002
+ {
2003
+ name: "instagram",
2004
+ type: "text",
2005
+ label: "Instagram"
2006
+ },
2007
+ {
2008
+ name: "linkedin",
2009
+ type: "text",
2010
+ label: "LinkedIn"
2011
+ },
2012
+ {
2013
+ name: "youtube",
2014
+ type: "text",
2015
+ label: "YouTube"
2016
+ },
2017
+ {
2018
+ name: "tiktok",
2019
+ type: "text",
2020
+ label: "TikTok",
2021
+ admin: {
2022
+ condition: (data) => data.showAll === true
2023
+ }
2024
+ },
2025
+ {
2026
+ name: "pinterest",
2027
+ type: "text",
2028
+ label: "Pinterest",
2029
+ admin: {
2030
+ condition: (data) => data.showAll === true
2031
+ }
2032
+ },
2033
+ {
2034
+ name: "discord",
2035
+ type: "text",
2036
+ label: "Discord",
2037
+ admin: {
2038
+ condition: (data) => data.showAll === true
2039
+ }
2040
+ },
2041
+ {
2042
+ name: "twitch",
2043
+ type: "text",
2044
+ label: "Twitch",
2045
+ admin: {
2046
+ condition: (data) => data.showAll === true
2047
+ }
2048
+ },
2049
+ {
2050
+ name: "github",
2051
+ type: "text",
2052
+ label: "GitHub",
2053
+ admin: {
2054
+ condition: (data) => data.showAll === true
2055
+ }
2056
+ },
2057
+ {
2058
+ name: "mastodon",
2059
+ type: "text",
2060
+ label: "Mastodon",
2061
+ admin: {
2062
+ condition: (data) => data.showAll === true
2063
+ }
2064
+ }
2065
+ ]
2066
+ };
2067
+
2068
+ // src/templates/settings/email.ts
2069
+ var emailSettingsGlobal = {
2070
+ slug: "email-settings",
2071
+ label: "Email Settings",
2072
+ admin: {
2073
+ group: "settings"
2074
+ },
2075
+ access: {
2076
+ read: () => true,
2077
+ update: () => true
2078
+ },
2079
+ fields: [
2080
+ {
2081
+ name: "fromName",
2082
+ type: "text",
2083
+ label: "From Name",
2084
+ admin: {}
2085
+ },
2086
+ {
2087
+ name: "fromEmail",
2088
+ type: "email",
2089
+ label: "From Email",
2090
+ required: true,
2091
+ admin: {}
2092
+ },
2093
+ {
2094
+ name: "replyTo",
2095
+ type: "email",
2096
+ label: "Reply-To Email",
2097
+ admin: {}
2098
+ },
2099
+ {
2100
+ name: "provider",
2101
+ type: "select",
2102
+ label: "Email Provider",
2103
+ defaultValue: "smtp",
2104
+ options: [
2105
+ { label: "SMTP (Standard)", value: "smtp" },
2106
+ { label: "Resend", value: "resend" },
2107
+ { label: "SendGrid", value: "sendgrid" },
2108
+ { label: "Mailgun", value: "mailgun" },
2109
+ { label: "AWS SES", value: "ses" }
2110
+ ]
2111
+ },
2112
+ {
2113
+ name: "smtp",
2114
+ type: "group",
2115
+ label: "SMTP Settings",
2116
+ admin: {
2117
+ condition: (data) => data.provider === "smtp"
2118
+ },
2119
+ fields: [
2120
+ {
2121
+ name: "smtpService",
2122
+ type: "select",
2123
+ label: "SMTP Service",
2124
+ defaultValue: "custom",
2125
+ options: [
2126
+ { label: "Custom SMTP", value: "custom" },
2127
+ { label: "Gmail", value: "gmail" },
2128
+ { label: "Outlook / Office 365", value: "outlook" },
2129
+ { label: "Brevo (Sendinblue)", value: "brevo" },
2130
+ { label: "Mailgun (SMTP)", value: "mailgun-smtp" },
2131
+ { label: "SendGrid (SMTP)", value: "sendgrid-smtp" },
2132
+ { label: "Mandrill / Mailchimp", value: "mandrill" }
2133
+ ],
2134
+ admin: {
2135
+ description: "Selecting a known service will pre-configure host and port settings."
2136
+ }
2137
+ },
2138
+ {
2139
+ name: "host",
2140
+ type: "text",
2141
+ label: "Host",
2142
+ admin: {
2143
+ condition: (data, siblingData) => siblingData.smtpService === "custom",
2144
+ placeholder: "smtp.example.com"
2145
+ }
2146
+ },
2147
+ {
2148
+ name: "port",
2149
+ type: "number",
2150
+ label: "Port",
2151
+ defaultValue: 587,
2152
+ admin: {
2153
+ condition: (data, siblingData) => siblingData.smtpService === "custom"
2154
+ }
2155
+ },
2156
+ {
2157
+ name: "username",
2158
+ type: "text",
2159
+ label: "Username"
2160
+ },
2161
+ {
2162
+ name: "password",
2163
+ type: "password",
2164
+ label: "Password"
2165
+ },
2166
+ {
2167
+ name: "secure",
2168
+ type: "checkbox",
2169
+ label: "Use TLS/SSL",
2170
+ defaultValue: true
2171
+ }
2172
+ ]
2173
+ },
2174
+ {
2175
+ name: "resend",
2176
+ type: "group",
2177
+ label: "Resend Settings",
2178
+ admin: {
2179
+ condition: (data) => data.provider === "resend"
2180
+ },
2181
+ fields: [
2182
+ {
2183
+ name: "apiKey",
2184
+ type: "password",
2185
+ label: "API Key",
2186
+ required: true
2187
+ }
2188
+ ]
2189
+ },
2190
+ {
2191
+ name: "sendgrid",
2192
+ type: "group",
2193
+ label: "SendGrid Settings",
2194
+ admin: {
2195
+ condition: (data) => data.provider === "sendgrid"
2196
+ },
2197
+ fields: [
2198
+ {
2199
+ name: "apiKey",
2200
+ type: "password",
2201
+ label: "API Key",
2202
+ required: true
2203
+ }
2204
+ ]
2205
+ },
2206
+ {
2207
+ name: "mailgun",
2208
+ type: "group",
2209
+ label: "Mailgun Settings",
2210
+ admin: {
2211
+ condition: (data) => data.provider === "mailgun"
2212
+ },
2213
+ fields: [
2214
+ {
2215
+ name: "apiKey",
2216
+ type: "password",
2217
+ label: "API Key",
2218
+ required: true
2219
+ },
2220
+ {
2221
+ name: "domain",
2222
+ type: "text",
2223
+ label: "Domain",
2224
+ required: true
2225
+ },
2226
+ {
2227
+ name: "region",
2228
+ type: "select",
2229
+ label: "Region",
2230
+ defaultValue: "us",
2231
+ options: [
2232
+ { label: "US (United States)", value: "us" },
2233
+ { label: "EU (Europe)", value: "eu" }
2234
+ ]
2235
+ }
2236
+ ]
2237
+ },
2238
+ {
2239
+ name: "ses",
2240
+ type: "group",
2241
+ label: "AWS SES Settings",
2242
+ admin: {
2243
+ condition: (data) => data.provider === "ses"
2244
+ },
2245
+ fields: [
2246
+ {
2247
+ name: "accessKeyId",
2248
+ type: "text",
2249
+ label: "Access Key ID",
2250
+ required: true
2251
+ },
2252
+ {
2253
+ name: "secretAccessKey",
2254
+ type: "password",
2255
+ label: "Secret Access Key",
2256
+ required: true
2257
+ },
2258
+ {
2259
+ name: "region",
2260
+ type: "text",
2261
+ label: "Region",
2262
+ defaultValue: "us-east-1",
2263
+ admin: { placeholder: "us-east-1" }
2264
+ }
2265
+ ]
2266
+ },
2267
+ {
2268
+ name: "testEmailSection",
2269
+ type: "row",
2270
+ label: "Test Email",
2271
+ admin: {
2272
+ description: "Enter an email address to send a test email."
2273
+ },
2274
+ fields: [
2275
+ {
2276
+ name: "testEmail",
2277
+ type: "email",
2278
+ label: "Email",
2279
+ admin: {
2280
+ width: "300px"
2281
+ }
2282
+ },
2283
+ {
2284
+ name: "sendTestEmail",
2285
+ type: "action",
2286
+ label: "Send Test Email",
2287
+ admin: {
2288
+ action: "/api/globals/email-settings/test",
2289
+ method: "POST"
2290
+ }
2291
+ }
2292
+ ]
2293
+ }
2294
+ ]
2295
+ };
2296
+
2297
+ // src/templates/settings/access.ts
2298
+ var accessSettingsGlobal = {
2299
+ slug: "access-settings",
2300
+ label: "Access Control",
2301
+ admin: {
2302
+ group: "settings"
2303
+ },
2304
+ access: {
2305
+ read: () => true,
2306
+ update: () => true
2307
+ },
2308
+ fields: [
2309
+ {
2310
+ name: "enablePublicAccess",
2311
+ type: "checkbox",
2312
+ label: "Enable Public Access",
2313
+ defaultValue: true,
2314
+ admin: {}
2315
+ },
2316
+ {
2317
+ name: "defaultCollectionAccess",
2318
+ type: "select",
2319
+ label: "Default Collection Access",
2320
+ defaultValue: "read",
2321
+ options: [
2322
+ { label: "Read Only", value: "read" },
2323
+ { label: "Read & Create", value: "create" },
2324
+ { label: "Read & Create & Update", value: "update" },
2325
+ { label: "Full Access", value: "admin" },
2326
+ { label: "No Access", value: "none" }
2327
+ ],
2328
+ admin: {}
2329
+ },
2330
+ {
2331
+ name: "apiAccess",
2332
+ type: "group",
2333
+ label: "API Access",
2334
+ fields: [
2335
+ {
2336
+ name: "restEnabled",
2337
+ type: "checkbox",
2338
+ label: "Enable REST API",
2339
+ defaultValue: true
2340
+ },
2341
+ {
2342
+ name: "graphqlEnabled",
2343
+ type: "checkbox",
2344
+ label: "Enable GraphQL",
2345
+ defaultValue: false
2346
+ },
2347
+ {
2348
+ name: "trpcEnabled",
2349
+ type: "checkbox",
2350
+ label: "Enable tRPC",
2351
+ defaultValue: false
2352
+ },
2353
+ {
2354
+ name: "wsEnabled",
2355
+ type: "checkbox",
2356
+ label: "Enable WebSocket",
2357
+ defaultValue: false
2358
+ },
2359
+ {
2360
+ name: "requireAuth",
2361
+ type: "checkbox",
2362
+ label: "Require Authentication",
2363
+ defaultValue: false
2364
+ },
2365
+ {
2366
+ name: "cors",
2367
+ type: "group",
2368
+ label: "CORS Settings",
2369
+ admin: {
2370
+ condition: (data) => data.apiAccess?.restEnabled === true || data.apiAccess?.graphqlEnabled === true
2371
+ },
2372
+ fields: [
2373
+ {
2374
+ name: "allowedOrigins",
2375
+ type: "textarea",
2376
+ label: "Allowed Origins (one per line)",
2377
+ admin: {
2378
+ placeholder: "https://example.com\nhttps://app.example.com"
2379
+ }
2380
+ }
2381
+ ]
2382
+ }
2383
+ ]
2384
+ },
2385
+ {
2386
+ name: "rateLimiting",
2387
+ type: "group",
2388
+ label: "Rate Limiting Configuration",
2389
+ admin: {
2390
+ condition: (data) => data.rateLimiting?.enabled === true
2391
+ },
2392
+ fields: [
2393
+ {
2394
+ name: "enabled",
2395
+ type: "checkbox",
2396
+ label: "Enable Global Rate Limiting",
2397
+ defaultValue: true
2398
+ },
2399
+ {
2400
+ name: "maxRequests",
2401
+ type: "number",
2402
+ label: "Max Requests",
2403
+ defaultValue: 100,
2404
+ admin: {
2405
+ condition: (data, siblingData) => siblingData.enabled === true
2406
+ }
2407
+ },
2408
+ {
2409
+ name: "windowMs",
2410
+ type: "number",
2411
+ label: "Window (ms)",
2412
+ defaultValue: 6e4,
2413
+ admin: {
2414
+ condition: (data, siblingData) => siblingData.enabled === true
2415
+ }
2416
+ }
2417
+ ]
2418
+ }
2419
+ ]
2420
+ };
2421
+
2422
+ // src/templates/settings/store.ts
2423
+ var countryOptions = [
2424
+ { label: "United States", value: "US" },
2425
+ { label: "United Kingdom", value: "GB" },
2426
+ { label: "Canada", value: "CA" },
2427
+ { label: "Australia", value: "AU" },
2428
+ { label: "Germany", value: "DE" },
2429
+ { label: "France", value: "FR" },
2430
+ { label: "Netherlands", value: "NL" },
2431
+ { label: "Belgium", value: "BE" },
2432
+ { label: "Spain", value: "ES" },
2433
+ { label: "Italy", value: "IT" },
2434
+ { label: "Portugal", value: "PT" },
2435
+ { label: "Sweden", value: "SE" },
2436
+ { label: "Norway", value: "NO" },
2437
+ { label: "Denmark", value: "DK" },
2438
+ { label: "Finland", value: "FI" },
2439
+ { label: "Austria", value: "AT" },
2440
+ { label: "Switzerland", value: "CH" },
2441
+ { label: "Japan", value: "JP" },
2442
+ { label: "South Korea", value: "KR" },
2443
+ { label: "China", value: "CN" },
2444
+ { label: "India", value: "IN" },
2445
+ { label: "Brazil", value: "BR" },
2446
+ { label: "Mexico", value: "MX" }
2447
+ ];
2448
+ var storeSettingsGlobal = {
2449
+ slug: "store-settings",
2450
+ label: "Store Settings",
2451
+ admin: {
2452
+ group: "settings"
2453
+ },
2454
+ access: {
2455
+ read: () => true,
2456
+ update: () => true
2457
+ },
2458
+ fields: [
2459
+ {
2460
+ name: "storeName",
2461
+ type: "text",
2462
+ label: "Store Name",
2463
+ required: true
2464
+ },
2465
+ {
2466
+ name: "storeEmail",
2467
+ type: "email",
2468
+ label: "Contact Email",
2469
+ required: true
2470
+ },
2471
+ {
2472
+ name: "storePhone",
2473
+ type: "text",
2474
+ label: "Phone Number"
2475
+ },
2476
+ {
2477
+ name: "address",
2478
+ type: "group",
2479
+ label: "Store Address",
2480
+ fields: [
2481
+ {
2482
+ name: "street",
2483
+ type: "text",
2484
+ label: "Street Address"
2485
+ },
2486
+ {
2487
+ name: "city",
2488
+ type: "text",
2489
+ label: "City"
2490
+ },
2491
+ {
2492
+ name: "state",
2493
+ type: "text",
2494
+ label: "State/Province"
2495
+ },
2496
+ {
2497
+ name: "postalCode",
2498
+ type: "text",
2499
+ label: "Postal Code"
2500
+ },
2501
+ {
2502
+ name: "country",
2503
+ type: "select",
2504
+ label: "Country",
2505
+ options: countryOptions
2506
+ }
2507
+ ]
2508
+ },
2509
+ {
2510
+ name: "currency",
2511
+ type: "group",
2512
+ label: "Currency",
2513
+ fields: [
2514
+ {
2515
+ name: "code",
2516
+ type: "select",
2517
+ label: "Currency Code",
2518
+ defaultValue: "USD",
2519
+ options: [
2520
+ { label: "USD - US Dollar", value: "USD" },
2521
+ { label: "EUR - Euro", value: "EUR" },
2522
+ { label: "GBP - British Pound", value: "GBP" },
2523
+ { label: "CAD - Canadian Dollar", value: "CAD" },
2524
+ { label: "AUD - Australian Dollar", value: "AUD" },
2525
+ { label: "JPY - Japanese Yen", value: "JPY" },
2526
+ { label: "CNY - Chinese Yuan", value: "CNY" },
2527
+ { label: "INR - Indian Rupee", value: "INR" },
2528
+ { label: "BRL - Brazilian Real", value: "BRL" },
2529
+ { label: "MXN - Mexican Peso", value: "MXN" }
2530
+ ]
2531
+ },
2532
+ {
2533
+ name: "symbol",
2534
+ type: "text",
2535
+ label: "Symbol",
2536
+ defaultValue: "$"
2537
+ },
2538
+ {
2539
+ name: "position",
2540
+ type: "select",
2541
+ label: "Symbol Position",
2542
+ defaultValue: "before",
2543
+ options: [
2544
+ { label: "Before amount", value: "before" },
2545
+ { label: "After amount", value: "after" }
2546
+ ]
2547
+ },
2548
+ {
2549
+ name: "decimals",
2550
+ type: "number",
2551
+ label: "Decimal Places",
2552
+ defaultValue: 2
2553
+ }
2554
+ ]
2555
+ },
2556
+ {
2557
+ name: "tax",
2558
+ type: "group",
2559
+ label: "Tax Logistics",
2560
+ admin: {
2561
+ condition: (data) => data.tax?.enabled === true
2562
+ },
2563
+ fields: [
2564
+ {
2565
+ name: "enabled",
2566
+ type: "checkbox",
2567
+ label: "Enable Tax",
2568
+ defaultValue: true
2569
+ },
2570
+ {
2571
+ name: "rate",
2572
+ type: "number",
2573
+ label: "Tax Rate (%)",
2574
+ admin: {
2575
+ placeholder: "10",
2576
+ condition: (data, siblingData) => siblingData.enabled === true
2577
+ }
2578
+ },
2579
+ {
2580
+ name: "includedInPrice",
2581
+ type: "checkbox",
2582
+ label: "Tax Included in Prices",
2583
+ admin: {
2584
+ condition: (data, siblingData) => siblingData.enabled === true
2585
+ }
2586
+ },
2587
+ {
2588
+ name: "taxId",
2589
+ type: "text",
2590
+ label: "Tax ID / VAT Number",
2591
+ admin: {
2592
+ condition: (data, siblingData) => siblingData.enabled === true
2593
+ }
2594
+ }
2595
+ ]
2596
+ },
2597
+ {
2598
+ name: "shipping",
2599
+ type: "group",
2600
+ label: "Shipping Logic",
2601
+ admin: {
2602
+ condition: (data) => data.shipping?.enableLocalPickup === true || data.shipping?.flatRate > 0
2603
+ },
2604
+ fields: [
2605
+ {
2606
+ name: "enableLocalPickup",
2607
+ type: "checkbox",
2608
+ label: "Enable Local Pickup",
2609
+ defaultValue: true
2610
+ },
2611
+ {
2612
+ name: "flatRate",
2613
+ type: "number",
2614
+ label: "Flat Rate Shipping Fee",
2615
+ admin: {}
2616
+ },
2617
+ {
2618
+ name: "freeShippingThreshold",
2619
+ type: "number",
2620
+ label: "Free Shipping Minimum",
2621
+ admin: {
2622
+ condition: (data, siblingData) => siblingData.flatRate > 0
2623
+ }
2624
+ }
2625
+ ]
2626
+ },
2627
+ {
2628
+ name: "orders",
2629
+ type: "group",
2630
+ label: "Orders",
2631
+ fields: [
2632
+ {
2633
+ name: "orderNumberPrefix",
2634
+ type: "text",
2635
+ label: "Order Number Prefix",
2636
+ defaultValue: "ORD",
2637
+ admin: {}
2638
+ },
2639
+ {
2640
+ name: "allowGuestCheckout",
2641
+ type: "checkbox",
2642
+ label: "Allow Guest Checkout",
2643
+ defaultValue: true
2644
+ },
2645
+ {
2646
+ name: "requirePhone",
2647
+ type: "checkbox",
2648
+ label: "Require Phone Number",
2649
+ defaultValue: true
2650
+ }
2651
+ ]
2652
+ }
2653
+ ]
2654
+ };
2655
+
2656
+ // src/templates/settings/payments.ts
2657
+ var paymentSettingsGlobal = {
2658
+ slug: "payment-settings",
2659
+ label: "Payment Settings",
2660
+ admin: {
2661
+ group: "settings"
2662
+ },
2663
+ access: {
2664
+ read: () => true,
2665
+ update: () => true
2666
+ },
2667
+ fields: [
2668
+ {
2669
+ name: "testMode",
2670
+ type: "checkbox",
2671
+ label: "Test Mode",
2672
+ defaultValue: true,
2673
+ admin: {}
2674
+ },
2675
+ {
2676
+ name: "provider",
2677
+ type: "select",
2678
+ label: "Primary Payment Provider",
2679
+ defaultValue: "stripe",
2680
+ options: [
2681
+ { label: "Stripe", value: "stripe" },
2682
+ { label: "PayPal", value: "paypal" },
2683
+ { label: "Square", value: "square" },
2684
+ { label: "Manual Methods Only", value: "manual" }
2685
+ ]
2686
+ },
2687
+ {
2688
+ name: "stripe",
2689
+ type: "group",
2690
+ label: "Stripe",
2691
+ admin: {
2692
+ condition: (data) => data.provider === "stripe"
2693
+ },
2694
+ fields: [
2695
+ {
2696
+ name: "enabled",
2697
+ type: "checkbox",
2698
+ label: "Enable Stripe",
2699
+ defaultValue: false
2700
+ },
2701
+ {
2702
+ name: "publishableKey",
2703
+ type: "text",
2704
+ label: "Publishable Key",
2705
+ admin: {
2706
+ placeholder: "pk_live_..."
2707
+ }
2708
+ },
2709
+ {
2710
+ name: "secretKey",
2711
+ type: "password",
2712
+ label: "Secret Key"
2713
+ },
2714
+ {
2715
+ name: "webhookSecret",
2716
+ type: "password",
2717
+ label: "Webhook Secret",
2718
+ admin: {}
2719
+ }
2720
+ ]
2721
+ },
2722
+ {
2723
+ name: "paypal",
2724
+ type: "group",
2725
+ label: "PayPal",
2726
+ admin: {
2727
+ condition: (data) => data.provider === "paypal"
2728
+ },
2729
+ fields: [
2730
+ {
2731
+ name: "enabled",
2732
+ type: "checkbox",
2733
+ label: "Enable PayPal",
2734
+ defaultValue: false
2735
+ },
2736
+ {
2737
+ name: "clientId",
2738
+ type: "text",
2739
+ label: "Client ID"
2740
+ },
2741
+ {
2742
+ name: "clientSecret",
2743
+ type: "password",
2744
+ label: "Client Secret"
2745
+ },
2746
+ {
2747
+ name: "mode",
2748
+ type: "select",
2749
+ label: "Mode",
2750
+ defaultValue: "sandbox",
2751
+ options: [
2752
+ { label: "Sandbox (Test)", value: "sandbox" },
2753
+ { label: "Live", value: "live" }
2754
+ ]
2755
+ }
2756
+ ]
2757
+ },
2758
+ {
2759
+ name: "square",
2760
+ type: "group",
2761
+ label: "Square",
2762
+ admin: {
2763
+ condition: (data) => data.provider === "square"
2764
+ },
2765
+ fields: [
2766
+ {
2767
+ name: "enabled",
2768
+ type: "checkbox",
2769
+ label: "Enable Square",
2770
+ defaultValue: false
2771
+ },
2772
+ {
2773
+ name: "applicationId",
2774
+ type: "text",
2775
+ label: "Application ID"
2776
+ },
2777
+ {
2778
+ name: "accessToken",
2779
+ type: "password",
2780
+ label: "Access Token"
2781
+ },
2782
+ {
2783
+ name: "locationId",
2784
+ type: "text",
2785
+ label: "Location ID"
2786
+ }
2787
+ ]
2788
+ },
2789
+ {
2790
+ name: "methods",
2791
+ type: "group",
2792
+ label: "Manual Payment Methods",
2793
+ fields: [
2794
+ {
2795
+ name: "cod",
2796
+ type: "checkbox",
2797
+ label: "Cash on Delivery",
2798
+ defaultValue: true
2799
+ },
2800
+ {
2801
+ name: "bankTransfer",
2802
+ type: "checkbox",
2803
+ label: "Bank Transfer",
2804
+ defaultValue: true
2805
+ },
2806
+ {
2807
+ name: "cash",
2808
+ type: "checkbox",
2809
+ label: "Cash (Local Pickup)",
2810
+ defaultValue: true
2811
+ },
2812
+ {
2813
+ name: "check",
2814
+ type: "checkbox",
2815
+ label: "Check",
2816
+ defaultValue: false
2817
+ }
2818
+ ]
2819
+ },
2820
+ {
2821
+ name: "bankTransfer",
2822
+ type: "group",
2823
+ label: "Bank Transfer Details",
2824
+ admin: {},
2825
+ fields: [
2826
+ {
2827
+ name: "bankName",
2828
+ type: "text",
2829
+ label: "Bank Name"
2830
+ },
2831
+ {
2832
+ name: "accountName",
2833
+ type: "text",
2834
+ label: "Account Name"
2835
+ },
2836
+ {
2837
+ name: "accountNumber",
2838
+ type: "text",
2839
+ label: "Account Number"
2840
+ },
2841
+ {
2842
+ name: "routingNumber",
2843
+ type: "text",
2844
+ label: "Routing/Sort Code"
2845
+ },
2846
+ {
2847
+ name: "iban",
2848
+ type: "text",
2849
+ label: "IBAN"
2850
+ },
2851
+ {
2852
+ name: "swift",
2853
+ type: "text",
2854
+ label: "SWIFT/BIC"
2855
+ }
2856
+ ]
2857
+ }
2858
+ ]
2859
+ };
2860
+
2861
+ // src/templates/settings/system.ts
2862
+ var systemSettingsGlobal = {
2863
+ slug: "system",
2864
+ label: "System",
2865
+ admin: {
2866
+ group: "settings",
2867
+ description: "Core system configuration and secrets"
2868
+ },
2869
+ access: {
2870
+ read: () => true,
2871
+ update: () => true
2872
+ },
2873
+ fields: [
2874
+ {
2875
+ name: "appSecret",
2876
+ type: "secret",
2877
+ label: "App Secret",
2878
+ required: false,
2879
+ admin: {
2880
+ description: "Auto-generated master secret used for encryption and auth. Auto-created if empty on load.",
2881
+ readOnly: true
2882
+ }
2883
+ },
2884
+ {
2885
+ name: "encryptionKey",
2886
+ type: "text",
2887
+ label: "Encryption Key",
2888
+ required: false,
2889
+ admin: {
2890
+ description: "Auto-generated key for data encryption at rest.",
2891
+ readOnly: true
2892
+ }
2893
+ },
2894
+ {
2895
+ name: "sessionMaxAge",
2896
+ type: "number",
2897
+ label: "Session Max Age (days)",
2898
+ required: false,
2899
+ defaultValue: 7,
2900
+ admin: {
2901
+ description: "Maximum session duration in days"
2902
+ }
2903
+ },
2904
+ {
2905
+ name: "maxSessionsPerUser",
2906
+ type: "number",
2907
+ label: "Max Sessions Per User",
2908
+ required: false,
2909
+ defaultValue: 3,
2910
+ admin: {
2911
+ description: "Maximum concurrent sessions allowed per user"
2912
+ }
2913
+ }
2914
+ ]
2915
+ };
2916
+
2917
+ // src/templates/settings/header.ts
2918
+ var headerSettingsGlobal = {
2919
+ slug: "header-settings",
2920
+ label: "Header Settings",
2921
+ admin: {
2922
+ group: "Header Configuration",
2923
+ description: "Manage global header settings like the logo and navigation."
2924
+ },
2925
+ access: {
2926
+ read: () => true,
2927
+ update: () => true
2928
+ },
2929
+ fields: [
2930
+ {
2931
+ name: "site_logo",
2932
+ type: "upload",
2933
+ relationTo: "media",
2934
+ label: "Site Logo"
2935
+ },
2936
+ {
2937
+ name: "site_menu",
2938
+ type: "relationship",
2939
+ relationTo: "menu",
2940
+ label: "Site Menu"
2941
+ },
2942
+ {
2943
+ name: "header_text",
2944
+ type: "richtext",
2945
+ label: "Header Text"
2946
+ },
2947
+ {
2948
+ name: "header_buttons",
2949
+ type: "array",
2950
+ label: "Header Buttons",
2951
+ fields: [
2952
+ {
2953
+ name: "button",
2954
+ type: "group",
2955
+ label: "Button",
2956
+ fields: [
2957
+ {
2958
+ name: "text",
2959
+ type: "text",
2960
+ label: "Button Text"
2961
+ },
2962
+ {
2963
+ name: "url",
2964
+ type: "text",
2965
+ label: "Button URL"
2966
+ }
2967
+ ]
2968
+ }
2969
+ ]
2970
+ }
2971
+ ]
2972
+ };
2973
+
2974
+ // src/templates/settings/footer.ts
2975
+ var footerSettingsGlobal = {
2976
+ slug: "footer-settings",
2977
+ label: "Footer Settings",
2978
+ admin: {
2979
+ group: "Footer Configuration",
2980
+ description: "Manage global footer settings like the logo, text, and links."
2981
+ },
2982
+ access: {
2983
+ read: () => true,
2984
+ update: () => true
2985
+ },
2986
+ fields: [
2987
+ {
2988
+ name: "footer_logo",
2989
+ type: "upload",
2990
+ relationTo: "media",
2991
+ label: "Footer Logo"
2992
+ },
2993
+ {
2994
+ name: "footer_text",
2995
+ type: "richtext",
2996
+ label: "Footer Text"
2997
+ },
2998
+ {
2999
+ name: "footer_address",
3000
+ type: "text",
3001
+ label: "Footer Address"
3002
+ },
3003
+ {
3004
+ name: "footer_phone",
3005
+ type: "text",
3006
+ label: "Footer Phone"
3007
+ },
3008
+ {
3009
+ name: "footer_email",
3010
+ type: "text",
3011
+ label: "Footer Email"
3012
+ },
3013
+ {
3014
+ name: "footer_hours",
3015
+ type: "array",
3016
+ label: "Footer Hours",
3017
+ fields: [
3018
+ {
3019
+ name: "hour",
3020
+ type: "text",
3021
+ label: "Hour"
3022
+ }
3023
+ ]
3024
+ },
3025
+ {
3026
+ name: "footer_social_links",
3027
+ type: "array",
3028
+ label: "Footer Social Links",
3029
+ fields: [
3030
+ {
3031
+ name: "social_icon",
3032
+ type: "text",
3033
+ label: "Social Icon"
3034
+ },
3035
+ {
3036
+ name: "social_url",
3037
+ type: "text",
3038
+ label: "Social URL"
3039
+ }
3040
+ ]
3041
+ },
3042
+ {
3043
+ name: "footer_menu",
3044
+ type: "array",
3045
+ label: "Footer Menu",
3046
+ fields: [
3047
+ {
3048
+ name: "menu",
3049
+ type: "relationship",
3050
+ relationTo: "menu"
3051
+ }
3052
+ ]
3053
+ },
3054
+ {
3055
+ name: "footer_buttons",
3056
+ type: "array",
3057
+ label: "Footer Buttons",
3058
+ fields: [
3059
+ {
3060
+ name: "button",
3061
+ type: "button",
3062
+ label: "Button"
3063
+ }
3064
+ ]
3065
+ },
3066
+ {
3067
+ name: "footer_form",
3068
+ type: "relationship",
3069
+ relationTo: "forms",
3070
+ label: "Footer Form"
3071
+ }
3072
+ ]
3073
+ };
3074
+
3075
+ // src/templates/settings/index.ts
3076
+ var allSettingsGlobals = [
3077
+ siteSettingsGlobal,
3078
+ seoSettingsGlobal,
3079
+ socialSettingsGlobal,
3080
+ emailSettingsGlobal,
3081
+ chunk3KTWGODI_cjs.storageSettingsGlobal,
3082
+ accessSettingsGlobal,
3083
+ storeSettingsGlobal,
3084
+ paymentSettingsGlobal,
3085
+ systemSettingsGlobal,
3086
+ headerSettingsGlobal,
3087
+ footerSettingsGlobal
3088
+ ];
3089
+ var coreSettingsGlobals = [
3090
+ siteSettingsGlobal,
3091
+ seoSettingsGlobal,
3092
+ socialSettingsGlobal,
3093
+ emailSettingsGlobal,
3094
+ chunk3KTWGODI_cjs.storageSettingsGlobal,
3095
+ accessSettingsGlobal,
3096
+ systemSettingsGlobal,
3097
+ headerSettingsGlobal,
3098
+ footerSettingsGlobal
3099
+ ];
3100
+ var settingsBySlug = {
3101
+ [siteSettingsGlobal.slug]: siteSettingsGlobal,
3102
+ [seoSettingsGlobal.slug]: seoSettingsGlobal,
3103
+ [socialSettingsGlobal.slug]: socialSettingsGlobal,
3104
+ [emailSettingsGlobal.slug]: emailSettingsGlobal,
3105
+ [chunk3KTWGODI_cjs.storageSettingsGlobal.slug]: chunk3KTWGODI_cjs.storageSettingsGlobal,
3106
+ [accessSettingsGlobal.slug]: accessSettingsGlobal,
3107
+ [storeSettingsGlobal.slug]: storeSettingsGlobal,
3108
+ [paymentSettingsGlobal.slug]: paymentSettingsGlobal,
3109
+ [systemSettingsGlobal.slug]: systemSettingsGlobal,
3110
+ [headerSettingsGlobal.slug]: headerSettingsGlobal,
3111
+ [footerSettingsGlobal.slug]: footerSettingsGlobal
3112
+ };
3113
+ function getSettingsForTemplate(template) {
3114
+ switch (template) {
3115
+ case "minimal":
3116
+ return [siteSettingsGlobal, seoSettingsGlobal];
3117
+ case "starter":
3118
+ case "blog":
3119
+ return coreSettingsGlobals;
3120
+ case "ecommerce":
3121
+ case "kitchen-sink":
3122
+ return allSettingsGlobals;
3123
+ default:
3124
+ return coreSettingsGlobals;
3125
+ }
3126
+ }
3127
+
3128
+ // src/templates/index.ts
3129
+ function deduplicateCollections(collections) {
3130
+ const map = /* @__PURE__ */ new Map();
3131
+ for (const col of collections) {
3132
+ if (!map.has(col.slug)) {
3133
+ map.set(col.slug, col);
3134
+ }
3135
+ }
3136
+ return Array.from(map.values());
3137
+ }
3138
+ var templateCollections = {
3139
+ minimal: deduplicateCollections([
3140
+ ...Object.values(minimalCollections),
3141
+ ...Object.values(postsCollections),
3142
+ ...Object.values(pageCollections),
3143
+ ...Object.values(categoriesCollections),
3144
+ ...Object.values(formsCollections),
3145
+ ...Object.values(formEntriesCollections)
3146
+ ]),
3147
+ starter: deduplicateCollections([
3148
+ ...Object.values(starterCollections),
3149
+ ...mediaCollections,
3150
+ ...Object.values(chunkKC2GDBLS_cjs.authCollections),
3151
+ ...Object.values(postsCollections),
3152
+ ...Object.values(pageCollections),
3153
+ ...Object.values(menuCollections),
3154
+ ...Object.values(categoriesCollections),
3155
+ ...Object.values(formsCollections),
3156
+ ...Object.values(formEntriesCollections)
3157
+ ]),
3158
+ blog: deduplicateCollections([
3159
+ ...Object.values(blogCollections),
3160
+ ...mediaCollections,
3161
+ ...Object.values(chunkKC2GDBLS_cjs.authCollections),
3162
+ ...Object.values(postsCollections),
3163
+ ...Object.values(pageCollections),
3164
+ ...Object.values(menuCollections),
3165
+ ...Object.values(categoriesCollections),
3166
+ ...Object.values(formsCollections),
3167
+ ...Object.values(formEntriesCollections)
3168
+ ]),
3169
+ ecommerce: deduplicateCollections([
3170
+ ...Object.values(ecommerceCollections),
3171
+ ...Object.values(productsCollections),
3172
+ ...Object.values(customersCollections),
3173
+ ...Object.values(ordersCollections),
3174
+ ...Object.values(couponsCollections),
3175
+ ...mediaCollections,
3176
+ ...Object.values(chunkKC2GDBLS_cjs.authCollections),
3177
+ ...Object.values(postsCollections),
3178
+ ...Object.values(pageCollections),
3179
+ ...Object.values(menuCollections),
3180
+ ...Object.values(categoriesCollections),
3181
+ ...Object.values(productCategoriesCollections),
3182
+ ...Object.values(formsCollections),
3183
+ ...Object.values(formEntriesCollections)
3184
+ ]),
3185
+ "kitchen-sink": deduplicateCollections([
3186
+ ...Object.values(minimalCollections),
3187
+ ...Object.values(starterCollections),
3188
+ ...Object.values(blogCollections),
3189
+ ...Object.values(ecommerceCollections),
3190
+ ...Object.values(kitchenSinkCollections),
3191
+ ...Object.values(productsCollections),
3192
+ ...Object.values(customersCollections),
3193
+ ...Object.values(ordersCollections),
3194
+ ...Object.values(couponsCollections),
3195
+ ...mediaCollections,
3196
+ ...Object.values(chunkKC2GDBLS_cjs.authCollections),
3197
+ ...Object.values(postsCollections),
3198
+ ...Object.values(pageCollections),
3199
+ ...Object.values(menuCollections),
3200
+ ...Object.values(categoriesCollections),
3201
+ ...Object.values(productCategoriesCollections),
3202
+ ...Object.values(formsCollections),
3203
+ ...Object.values(formEntriesCollections)
3204
+ ])
3205
+ };
3206
+ function createTemplateConfig(options) {
3207
+ const collections = options.collections ? [...options.collections] : [];
3208
+ const globals = options.globals ? [...options.globals] : [];
3209
+ if (options.includeMedia !== false) {
3210
+ collections.push(...mediaCollections);
3211
+ }
3212
+ const templateSettings = options.template ? getSettingsForTemplate(options.template) : coreSettingsGlobals;
3213
+ if (options.includeSettings) {
3214
+ if (options.includeSettings === "all") {
3215
+ globals.push(...allSettingsGlobals);
3216
+ } else if (options.includeSettings === "core") {
3217
+ globals.push(...coreSettingsGlobals);
3218
+ } else if (Array.isArray(options.includeSettings)) {
3219
+ for (const setting of options.includeSettings) {
3220
+ const global = settingsBySlug[setting];
3221
+ if (global) {
3222
+ globals.push(global);
3223
+ }
3224
+ }
3225
+ }
3226
+ } else if (!options.globals || options.globals.length === 0) {
3227
+ globals.push(...templateSettings);
3228
+ }
3229
+ if (options.excludeSettings && options.excludeSettings.length > 0) {
3230
+ const excludeSet = new Set(options.excludeSettings);
3231
+ const filtered = globals.filter(
3232
+ (g) => !excludeSet.has(g.slug) && !excludeSet.has(g.label?.toLowerCase().replace(/\s+/g, "-") || "")
3233
+ );
3234
+ globals.length = 0;
3235
+ globals.push(...filtered);
3236
+ }
3237
+ return {
3238
+ collections: collections.length > 0 ? collections : void 0,
3239
+ globals: globals.length > 0 ? globals : void 0
3240
+ };
3241
+ }
3242
+
3243
+ exports.accessSettingsGlobal = accessSettingsGlobal;
3244
+ exports.allSettingsGlobals = allSettingsGlobals;
3245
+ exports.blogCollections = blogCollections;
3246
+ exports.blogGlobals = blogGlobals;
3247
+ exports.categoriesCollection = categoriesCollection;
3248
+ exports.categoriesCollections = categoriesCollections;
3249
+ exports.coreSettingsGlobals = coreSettingsGlobals;
3250
+ exports.couponsCollection = couponsCollection;
3251
+ exports.couponsCollections = couponsCollections;
3252
+ exports.createTemplateConfig = createTemplateConfig;
3253
+ exports.customersCollection = customersCollection;
3254
+ exports.customersCollections = customersCollections;
3255
+ exports.ecommerceCollections = ecommerceCollections;
3256
+ exports.ecommerceGlobals = ecommerceGlobals;
3257
+ exports.emailSettingsGlobal = emailSettingsGlobal;
3258
+ exports.footerSettingsGlobal = footerSettingsGlobal;
3259
+ exports.formEntriesCollection = formEntriesCollection;
3260
+ exports.formEntriesCollections = formEntriesCollections;
3261
+ exports.formsCollection = formsCollection;
3262
+ exports.formsCollections = formsCollections;
3263
+ exports.getSettingsForTemplate = getSettingsForTemplate;
3264
+ exports.headerSettingsGlobal = headerSettingsGlobal;
3265
+ exports.kitchenSinkCollections = kitchenSinkCollections;
3266
+ exports.mediaCollection = mediaCollection;
3267
+ exports.mediaCollections = mediaCollections;
3268
+ exports.menuCollection = menuCollection;
3269
+ exports.menuCollections = menuCollections;
3270
+ exports.minimalCollections = minimalCollections;
3271
+ exports.ordersCollection = ordersCollection;
3272
+ exports.ordersCollections = ordersCollections;
3273
+ exports.pageCollection = pageCollection;
3274
+ exports.pageCollections = pageCollections;
3275
+ exports.paymentSettingsGlobal = paymentSettingsGlobal;
3276
+ exports.postsCollection = postsCollection;
3277
+ exports.postsCollections = postsCollections;
3278
+ exports.productCategoriesCollection = productCategoriesCollection;
3279
+ exports.productCategoriesCollections = productCategoriesCollections;
3280
+ exports.productsCollection = productsCollection;
3281
+ exports.productsCollections = productsCollections;
3282
+ exports.seoSettingsGlobal = seoSettingsGlobal;
3283
+ exports.settingsBySlug = settingsBySlug;
3284
+ exports.siteSettingsGlobal = siteSettingsGlobal;
3285
+ exports.socialSettingsGlobal = socialSettingsGlobal;
3286
+ exports.starterCollections = starterCollections;
3287
+ exports.storeSettingsGlobal = storeSettingsGlobal;
3288
+ exports.systemSettingsGlobal = systemSettingsGlobal;
3289
+ exports.templateCollections = templateCollections;
3290
+ //# sourceMappingURL=chunk-DEVFAKCQ.cjs.map
3291
+ //# sourceMappingURL=chunk-DEVFAKCQ.cjs.map