create-clientkit 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +228 -0
  3. package/THIRD-PARTY.md +61 -0
  4. package/bin/cli.js +52 -0
  5. package/dist/cli.js +2556 -0
  6. package/package.json +84 -0
  7. package/templates/astro-tailwind/base/README.md +131 -0
  8. package/templates/astro-tailwind/base/_gitattributes +5 -0
  9. package/templates/astro-tailwind/base/_gitignore +23 -0
  10. package/templates/astro-tailwind/base/_package.json +28 -0
  11. package/templates/astro-tailwind/base/astro.config.mjs +32 -0
  12. package/templates/astro-tailwind/base/public/favicon.svg +5 -0
  13. package/templates/astro-tailwind/base/src/components/Brand.astro +89 -0
  14. package/templates/astro-tailwind/base/src/components/Footer.astro +88 -0
  15. package/templates/astro-tailwind/base/src/components/Header.astro +104 -0
  16. package/templates/astro-tailwind/base/src/components/LaunchNotice.astro +156 -0
  17. package/templates/astro-tailwind/base/src/components/Seo.astro +73 -0
  18. package/templates/astro-tailwind/base/src/components/SocialLinks.astro +75 -0
  19. package/templates/astro-tailwind/base/src/components/StructuredData.astro +39 -0
  20. package/templates/astro-tailwind/base/src/config/site.config.ts +141 -0
  21. package/templates/astro-tailwind/base/src/layouts/BaseLayout.astro +121 -0
  22. package/templates/astro-tailwind/base/src/lib/seo.ts +87 -0
  23. package/templates/astro-tailwind/base/src/pages/404.astro +147 -0
  24. package/templates/astro-tailwind/base/src/pages/index.astro +31 -0
  25. package/templates/astro-tailwind/base/src/pages/robots.txt.ts +32 -0
  26. package/templates/astro-tailwind/base/src/styles/global.css +330 -0
  27. package/templates/astro-tailwind/base/tsconfig.json +11 -0
  28. package/templates/astro-tailwind/modes/coming-soon/_package.json +3 -0
  29. package/templates/astro-tailwind/modes/coming-soon/src/pages/index.astro +149 -0
  30. package/templates/astro-tailwind/modes/full/_package.json +3 -0
  31. package/templates/astro-tailwind/modes/full/src/pages/index.astro +237 -0
  32. package/templates/astro-tailwind/template.json +23 -0
@@ -0,0 +1,237 @@
1
+ ---
2
+ import SocialLinks from '../components/SocialLinks.astro';
3
+ import { CONTACT, NAV, SITE, SOCIAL, type NavItem } from '../config/site.config.ts';
4
+ import BaseLayout from '../layouts/BaseLayout.astro';
5
+
6
+ /**
7
+ * These anchors point at sections that genuinely exist further down this page,
8
+ * so the header has something real to link to out of the box. Once you add
9
+ * proper pages, move the navigation into NAV in src/config/site.config.ts and
10
+ * delete this override.
11
+ */
12
+ const pageNav: NavItem[] =
13
+ NAV.length > 0
14
+ ? NAV
15
+ : [
16
+ { label: 'About', href: '#about' },
17
+ { label: 'Work', href: '#work' },
18
+ { label: 'Contact', href: '#contact' },
19
+ ];
20
+
21
+ const hasEmail = CONTACT.email !== '';
22
+ const hasSocial = SOCIAL.some((link) => link.label !== '' && link.href !== '');
23
+
24
+ /** Placeholder structure, not placeholder claims - replace the copy, keep the shape. */
25
+ const sections = [
26
+ {
27
+ id: 'about',
28
+ title: 'About',
29
+ body: 'Introduce the business here: who they are, who they serve, and what makes the work worth choosing.',
30
+ },
31
+ {
32
+ id: 'work',
33
+ title: 'Work',
34
+ body: 'Show the work. Case studies, projects or services - whichever tells the clearest story.',
35
+ },
36
+ {
37
+ id: 'contact',
38
+ title: 'Contact',
39
+ body: 'Make the next step obvious. One clear way to get in touch beats five competing options.',
40
+ },
41
+ ];
42
+ ---
43
+
44
+ <BaseLayout nav={pageNav}>
45
+ <section class="hero">
46
+ <div class="container-page inner">
47
+ {SITE.author !== '' && <p class="eyebrow rise">{SITE.author}</p>}
48
+
49
+ <h1 class="rise" style="animation-delay: 60ms">{SITE.name}</h1>
50
+
51
+ <p class="lead rise" style="animation-delay: 120ms">{SITE.description}</p>
52
+
53
+ {
54
+ (hasEmail || hasSocial) && (
55
+ <div class="actions rise" style="animation-delay: 180ms">
56
+ {hasEmail && (
57
+ <a class="btn btn-primary" href={`mailto:${CONTACT.email}`}>
58
+ Get in touch
59
+ </a>
60
+ )}
61
+ <a class="btn btn-secondary" href="#about">
62
+ Learn more
63
+ </a>
64
+ </div>
65
+ )
66
+ }
67
+ </div>
68
+ </section>
69
+
70
+ <hr class="rule" />
71
+
72
+ <div class="container-page sections">
73
+ {
74
+ sections.map((section) => (
75
+ <section id={section.id} class="section">
76
+ <h2>{section.title}</h2>
77
+ <p>{section.body}</p>
78
+ </section>
79
+ ))
80
+ }
81
+ </div>
82
+
83
+ {
84
+ (hasEmail || hasSocial || CONTACT.location !== '') && (
85
+ <div class="container-page details">
86
+ <hr class="rule" />
87
+ <dl>
88
+ {hasEmail && (
89
+ <div>
90
+ <dt>Email</dt>
91
+ <dd>
92
+ <a class="link" href={`mailto:${CONTACT.email}`}>
93
+ {CONTACT.email}
94
+ </a>
95
+ </dd>
96
+ </div>
97
+ )}
98
+ {CONTACT.phone !== '' && (
99
+ <div>
100
+ <dt>Phone</dt>
101
+ <dd>
102
+ <a class="link" href={`tel:${CONTACT.phone.replace(/[^+\d]/g, '')}`}>
103
+ {CONTACT.phone}
104
+ </a>
105
+ </dd>
106
+ </div>
107
+ )}
108
+ {CONTACT.location !== '' && (
109
+ <div>
110
+ <dt>Location</dt>
111
+ <dd>{CONTACT.location}</dd>
112
+ </div>
113
+ )}
114
+ {hasSocial && (
115
+ <div>
116
+ <dt>Elsewhere</dt>
117
+ <dd>
118
+ <SocialLinks label="Social links" />
119
+ </dd>
120
+ </div>
121
+ )}
122
+ </dl>
123
+ </div>
124
+ )
125
+ }
126
+ </BaseLayout>
127
+
128
+ <style>
129
+ .hero {
130
+ padding-block: var(--spacing-section) var(--spacing-section);
131
+ }
132
+
133
+ .inner {
134
+ display: flex;
135
+ flex-direction: column;
136
+ align-items: flex-start;
137
+ gap: 1.5rem;
138
+ }
139
+
140
+ h1 {
141
+ margin: 0;
142
+ max-width: 18ch;
143
+ font-size: var(--text-display);
144
+ line-height: var(--text-display--line-height);
145
+ letter-spacing: var(--text-display--letter-spacing);
146
+ font-weight: 600;
147
+ text-wrap: balance;
148
+ }
149
+
150
+ .lead {
151
+ margin: 0;
152
+ max-width: 52ch;
153
+ color: var(--color-muted);
154
+ font-size: var(--text-lead);
155
+ line-height: var(--text-lead--line-height);
156
+ text-wrap: pretty;
157
+ }
158
+
159
+ .actions {
160
+ display: flex;
161
+ flex-wrap: wrap;
162
+ gap: 0.75rem;
163
+ margin-top: 0.5rem;
164
+ }
165
+
166
+ .sections {
167
+ display: grid;
168
+ gap: 2.5rem;
169
+ padding-block: var(--spacing-section);
170
+ }
171
+
172
+ .section {
173
+ /* Anchor links land below the sticky header rather than under it. */
174
+ scroll-margin-top: 5rem;
175
+ }
176
+
177
+ .section h2 {
178
+ margin: 0 0 0.625rem;
179
+ font-size: var(--text-h2);
180
+ line-height: var(--text-h2--line-height);
181
+ letter-spacing: var(--text-h2--letter-spacing);
182
+ font-weight: 600;
183
+ }
184
+
185
+ .section p {
186
+ margin: 0;
187
+ max-width: 60ch;
188
+ color: var(--color-muted);
189
+ text-wrap: pretty;
190
+ }
191
+
192
+ .details {
193
+ padding-bottom: var(--spacing-section);
194
+ }
195
+
196
+ .details dl {
197
+ display: grid;
198
+ gap: 1.25rem 2.5rem;
199
+ margin: 0;
200
+ padding-top: 2rem;
201
+ }
202
+
203
+ .details dt {
204
+ font-size: var(--text-label);
205
+ font-weight: 600;
206
+ letter-spacing: var(--text-label--letter-spacing);
207
+ text-transform: uppercase;
208
+ color: var(--color-muted);
209
+ }
210
+
211
+ .details dd {
212
+ margin: 0.375rem 0 0;
213
+ }
214
+
215
+ @media (min-width: 48rem) {
216
+ .sections {
217
+ grid-template-columns: repeat(3, minmax(0, 1fr));
218
+ gap: 3rem;
219
+ }
220
+
221
+ .details dl {
222
+ grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
223
+ }
224
+ }
225
+
226
+ @media (max-width: 30rem) {
227
+ .actions {
228
+ flex-direction: column;
229
+ align-items: stretch;
230
+ width: 100%;
231
+ }
232
+
233
+ .actions .btn {
234
+ width: 100%;
235
+ }
236
+ }
237
+ </style>
@@ -0,0 +1,23 @@
1
+ {
2
+ "id": "astro-tailwind",
3
+ "displayName": "Astro + TypeScript + Tailwind",
4
+ "description": "Professional client website foundation",
5
+ "version": "0.1.0",
6
+ "framework": "astro",
7
+ "frameworkVersion": "7.3.2",
8
+ "minNode": ">=22.12.0",
9
+ "supportedModes": ["coming-soon", "full"],
10
+ "defaults": {
11
+ "mode": "coming-soon",
12
+ "locale": "en"
13
+ },
14
+ "availableFeatures": [],
15
+ "tokens": ["siteName", "siteUrl", "description", "projectName", "author", "locale", "mode"],
16
+ "postSteps": ["install", "git-init"],
17
+ "nextSteps": [
18
+ "Edit src/config/site.config.ts - name, description, navigation, social, contact, launch date and SEO all live there.",
19
+ "Set SITE.url once the domain is known; canonical tags, Open Graph and the sitemap switch on with it.",
20
+ "Set theme.accent to the client brand colour, or leave it for the neutral ink palette.",
21
+ "Replace public/favicon.svg with the client mark."
22
+ ]
23
+ }