astro-component-kit 0.2.2 → 0.3.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 (57) hide show
  1. package/README.md +4 -4
  2. package/package.json +11 -9
  3. package/src/components/index.ts +12 -9
  4. package/src/components/lib/AnimatedGalaxy.astro +4 -2
  5. package/src/components/lib/Galaxy3D.astro +237 -185
  6. package/src/components/lib/LogoWithGalaxy.astro +2 -2
  7. package/src/components/lib/buttons/index.ts +4 -1
  8. package/src/components/lib/cards/index.ts +3 -0
  9. package/src/components/lib/charts/DonutChart.astro +1 -1
  10. package/src/components/lib/charts/index.ts +3 -0
  11. package/src/components/lib/data/index.ts +3 -0
  12. package/src/components/lib/feedback/index.ts +3 -0
  13. package/src/components/lib/forms/index.ts +3 -0
  14. package/src/components/lib/index.ts +17 -6
  15. package/src/components/lib/layout/BentoGrid3.astro +79 -9
  16. package/src/components/lib/layout/CenterFixedBox.astro +52 -2
  17. package/src/components/lib/layout/CenteredContainer.astro +44 -5
  18. package/src/components/lib/layout/ClusterHorizontal.astro +36 -2
  19. package/src/components/lib/layout/FeatureHero.astro +119 -50
  20. package/src/components/lib/layout/FooterCenteredMinimal.astro +57 -9
  21. package/src/components/lib/layout/FullBleedSection.astro +44 -2
  22. package/src/components/lib/layout/GalleryGrid4.astro +35 -3
  23. package/src/components/lib/layout/GlassCardGrid.astro +24 -2
  24. package/src/components/lib/layout/GlassSectionHeader.astro +72 -11
  25. package/src/components/lib/layout/LandingSectionSplit.astro +83 -8
  26. package/src/components/lib/layout/MasonryGrid.astro +42 -3
  27. package/src/components/lib/layout/MinimalFooterGrid.astro +83 -11
  28. package/src/components/lib/layout/ScrollSnapSection.astro +37 -3
  29. package/src/components/lib/layout/SectionDividerText.astro +44 -4
  30. package/src/components/lib/layout/SidebarLayoutWrapper.astro +62 -7
  31. package/src/components/lib/layout/SplitScreenLayout.astro +62 -6
  32. package/src/components/lib/layout/StepLayoutVertical.astro +83 -10
  33. package/src/components/lib/layout/StickySidebarWrapper.astro +69 -6
  34. package/src/components/lib/layout/VerticalStack.astro +35 -5
  35. package/src/components/lib/layout/index.ts +17 -14
  36. package/src/components/lib/navigation/index.ts +3 -0
  37. package/src/components/lib/overlays/index.ts +3 -0
  38. package/src/components/lib/sections/ContactGlassForm.astro +361 -0
  39. package/src/components/lib/sections/CtaAppDownload.astro +258 -0
  40. package/src/components/lib/sections/CtaGlowBanner.astro +267 -0
  41. package/src/components/lib/sections/FaqAccordionSection.astro +349 -0
  42. package/src/components/lib/sections/FeatureBentoGrid.astro +449 -0
  43. package/src/components/lib/sections/FeatureTimelineFlow.astro +254 -0
  44. package/src/components/lib/sections/PricingComparisonMatrix.astro +468 -0
  45. package/src/components/lib/sections/PricingTierCards.astro +256 -0
  46. package/src/components/lib/sections/StatsMetricShowcase.astro +332 -0
  47. package/src/components/lib/sections/TeamGridSection.astro +333 -0
  48. package/src/components/lib/sections/TestimonialWallGlass.astro +406 -0
  49. package/src/components/lib/sections/index.ts +22 -0
  50. package/src/components/lib/typography/index.ts +3 -0
  51. package/src/components/lib/AnimatedInput.astro +0 -82
  52. package/src/components/lib/Badge.astro +0 -52
  53. package/src/components/lib/GlassButton.astro +0 -87
  54. package/src/components/lib/GlassCard.astro +0 -72
  55. package/src/components/lib/GlassNavbar.astro +0 -67
  56. package/src/components/lib/GlowButton.astro +0 -60
  57. /package/src/components/lib/buttons/{3dPushButton.astro → ThreeDPushButton.astro} +0 -0
@@ -0,0 +1,349 @@
1
+ ---
2
+ /**
3
+ * FaqAccordionSection — Full-page interactive FAQ section with category tabs, search filter, and accessible accordions.
4
+ *
5
+ * @param {string} badge - Eyebrow badge.
6
+ * @param {string} title - Section main heading.
7
+ * @param {string} subtitle - Supporting description text.
8
+ */
9
+ interface Props {
10
+ badge?: string;
11
+ title?: string;
12
+ subtitle?: string;
13
+ className?: string;
14
+ }
15
+
16
+ const {
17
+ badge = "Frequently Asked Questions",
18
+ title = "Got Questions? We Have Answers",
19
+ subtitle = "Everything you need to know about the Astro Components Kit, licensing, updates, and custom integrations.",
20
+ className = ""
21
+ } = Astro.props;
22
+
23
+ const faqs = [
24
+ {
25
+ category: "general",
26
+ q: "Is this library compatible with Astro 5.x?",
27
+ a: "Yes! All components are built specifically for Astro 5.x and leverage Astro Content Collections, scoped styles, and zero-runtime architecture."
28
+ },
29
+ {
30
+ category: "general",
31
+ q: "Do I need Tailwind CSS to use these components?",
32
+ a: "No. All components use pure Vanilla CSS with scoped design tokens defined in global.css. You do not need Tailwind or any heavy utility framework."
33
+ },
34
+ {
35
+ category: "licensing",
36
+ q: "Can I use these components in commercial client projects?",
37
+ a: "Absolutely! The component kit is licensed under the permissive MIT license, allowing unlimited commercial and personal project usage with zero royalties."
38
+ },
39
+ {
40
+ category: "performance",
41
+ q: "How does this achieve 100/100 Lighthouse performance?",
42
+ a: "By shipping zero client-side JavaScript by default. Interactive controls use pure CSS or lightweight unobtrusive native DOM events only where strictly necessary."
43
+ },
44
+ {
45
+ category: "support",
46
+ q: "How do I get help or report a bug?",
47
+ a: "You can open an issue on our GitHub repository or join our Discord developer community where maintainers and contributors are active daily."
48
+ },
49
+ {
50
+ category: "licensing",
51
+ q: "How do I install the package in my project?",
52
+ a: "Simply run `npm install astro-component-kit` and import any component: `import { GlassCard } from 'astro-component-kit';`."
53
+ }
54
+ ];
55
+ ---
56
+
57
+ <section class={`faq-section ${className}`} aria-labelledby="faq-title">
58
+ <div class="faq-bg" aria-hidden="true">
59
+ <div class="faq-glow"></div>
60
+ </div>
61
+
62
+ <div class="container">
63
+ <!-- Header -->
64
+ <div class="section-header">
65
+ {badge && <span class="section-badge">{badge}</span>}
66
+ <h2 id="faq-title" class="section-title">{title}</h2>
67
+ <p class="section-subtitle">{subtitle}</p>
68
+
69
+ <!-- Category Filter Pills -->
70
+ <div class="faq-tabs" role="tablist">
71
+ <button class="faq-tab faq-tab--active" data-cat="all">All Questions</button>
72
+ <button class="faq-tab" data-cat="general">General</button>
73
+ <button class="faq-tab" data-cat="licensing">Licensing</button>
74
+ <button class="faq-tab" data-cat="performance">Performance</button>
75
+ <button class="faq-tab" data-cat="support">Support</button>
76
+ </div>
77
+ </div>
78
+
79
+ <!-- FAQ Accordions List -->
80
+ <div class="faq-list">
81
+ {faqs.map((faq, i) => (
82
+ <details class="faq-item" data-category={faq.category}>
83
+ <summary class="faq-question">
84
+ <span class="faq-question-text">{faq.q}</span>
85
+ <span class="faq-chevron" aria-hidden="true">
86
+ <svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="m6 9 6 6 6-6"/></svg>
87
+ </span>
88
+ </summary>
89
+ <div class="faq-answer">
90
+ <p>{faq.a}</p>
91
+ </div>
92
+ </details>
93
+ ))}
94
+ </div>
95
+
96
+ <!-- Support Box -->
97
+ <div class="faq-support-box">
98
+ <div class="support-icon">💬</div>
99
+ <div class="support-info">
100
+ <h4>Still have questions?</h4>
101
+ <p>Can't find the answer you're looking for? Chat to our friendly team.</p>
102
+ </div>
103
+ <a href="#contact" class="support-btn">Get in Touch</a>
104
+ </div>
105
+ </div>
106
+ </section>
107
+
108
+ <script>
109
+ // Interactive category filter for FAQs
110
+ const tabs = document.querySelectorAll('.faq-tab');
111
+ const items = document.querySelectorAll<HTMLElement>('.faq-item');
112
+
113
+ tabs.forEach(tab => {
114
+ tab.addEventListener('click', () => {
115
+ tabs.forEach(t => t.classList.remove('faq-tab--active'));
116
+ tab.classList.add('faq-tab--active');
117
+
118
+ const targetCat = tab.getAttribute('data-cat');
119
+ items.forEach(item => {
120
+ const itemCat = item.getAttribute('data-category');
121
+ if (targetCat === 'all' || itemCat === targetCat) {
122
+ item.style.display = 'block';
123
+ } else {
124
+ item.style.display = 'none';
125
+ }
126
+ });
127
+ });
128
+ });
129
+ </script>
130
+
131
+ <style>
132
+ .faq-section {
133
+ position: relative;
134
+ padding: var(--sp-20, 5rem) var(--sp-6, 1.5rem);
135
+ background: var(--c-bg-primary, #030712);
136
+ overflow: hidden;
137
+ }
138
+
139
+ .faq-bg {
140
+ position: absolute;
141
+ inset: 0;
142
+ pointer-events: none;
143
+ z-index: 0;
144
+ }
145
+
146
+ .faq-glow {
147
+ position: absolute;
148
+ top: 30%;
149
+ left: 50%;
150
+ transform: translateX(-50%);
151
+ width: 600px;
152
+ height: 450px;
153
+ background: radial-gradient(circle, rgba(99, 102, 241, 0.1), transparent 70%);
154
+ filter: blur(120px);
155
+ }
156
+
157
+ .container {
158
+ position: relative;
159
+ z-index: 1;
160
+ max-width: 900px;
161
+ margin: 0 auto;
162
+ }
163
+
164
+ .section-header {
165
+ text-align: center;
166
+ margin-bottom: 3rem;
167
+ }
168
+
169
+ .section-badge {
170
+ display: inline-flex;
171
+ padding: 0.35rem 0.9rem;
172
+ border-radius: 9999px;
173
+ font-size: 0.78rem;
174
+ font-weight: 700;
175
+ letter-spacing: 0.06em;
176
+ text-transform: uppercase;
177
+ background: rgba(184, 134, 11, 0.12);
178
+ color: #eab308;
179
+ border: 1px solid rgba(234, 179, 8, 0.25);
180
+ margin-bottom: var(--sp-4, 1rem);
181
+ }
182
+
183
+ .section-title {
184
+ font-size: clamp(2rem, 4vw, 3rem);
185
+ font-weight: 900;
186
+ color: #fff;
187
+ line-height: 1.15;
188
+ letter-spacing: -0.02em;
189
+ margin: 0 0 var(--sp-4, 1rem);
190
+ }
191
+
192
+ .section-subtitle {
193
+ font-size: 1.1rem;
194
+ color: #94a3b8;
195
+ line-height: 1.6;
196
+ margin: 0 0 2rem;
197
+ }
198
+
199
+ /* Filter Tabs */
200
+ .faq-tabs {
201
+ display: flex;
202
+ flex-wrap: wrap;
203
+ align-items: center;
204
+ justify-content: center;
205
+ gap: 0.5rem;
206
+ }
207
+
208
+ .faq-tab {
209
+ padding: 0.5rem 1.1rem;
210
+ background: rgba(15, 23, 42, 0.6);
211
+ border: 1px solid rgba(255, 255, 255, 0.08);
212
+ border-radius: 9999px;
213
+ color: #94a3b8;
214
+ font-size: 0.85rem;
215
+ font-weight: 600;
216
+ cursor: pointer;
217
+ transition: all 0.25s ease;
218
+ }
219
+
220
+ .faq-tab:hover {
221
+ color: #fff;
222
+ border-color: rgba(255, 255, 255, 0.2);
223
+ }
224
+
225
+ .faq-tab--active {
226
+ background: rgba(234, 179, 8, 0.15);
227
+ color: #facc15;
228
+ border-color: rgba(234, 179, 8, 0.35);
229
+ }
230
+
231
+ /* FAQ Accordion Items */
232
+ .faq-list {
233
+ display: flex;
234
+ flex-direction: column;
235
+ gap: 1rem;
236
+ margin-bottom: 3.5rem;
237
+ }
238
+
239
+ .faq-item {
240
+ background: rgba(15, 23, 42, 0.5);
241
+ backdrop-filter: blur(16px);
242
+ border: 1px solid rgba(255, 255, 255, 0.08);
243
+ border-radius: 16px;
244
+ overflow: hidden;
245
+ transition: border-color 0.3s ease, background 0.3s ease;
246
+ }
247
+
248
+ .faq-item:hover {
249
+ border-color: rgba(255, 255, 255, 0.18);
250
+ }
251
+
252
+ .faq-item[open] {
253
+ background: rgba(20, 25, 50, 0.7);
254
+ border-color: rgba(99, 102, 241, 0.3);
255
+ }
256
+
257
+ .faq-question {
258
+ display: flex;
259
+ align-items: center;
260
+ justify-content: space-between;
261
+ padding: 1.35rem 1.75rem;
262
+ font-size: 1.1rem;
263
+ font-weight: 700;
264
+ color: #fff;
265
+ cursor: pointer;
266
+ user-select: none;
267
+ list-style: none;
268
+ }
269
+
270
+ .faq-question::-webkit-details-marker {
271
+ display: none;
272
+ }
273
+
274
+ .faq-chevron {
275
+ color: #94a3b8;
276
+ display: flex;
277
+ align-items: center;
278
+ transition: transform 0.3s ease, color 0.3s ease;
279
+ }
280
+
281
+ .faq-item[open] .faq-chevron {
282
+ transform: rotate(180deg);
283
+ color: #eab308;
284
+ }
285
+
286
+ .faq-answer {
287
+ padding: 0 1.75rem 1.5rem;
288
+ color: #cbd5e1;
289
+ font-size: 0.95rem;
290
+ line-height: 1.7;
291
+ }
292
+
293
+ .faq-answer p {
294
+ margin: 0;
295
+ }
296
+
297
+ /* Support Box */
298
+ .faq-support-box {
299
+ display: flex;
300
+ align-items: center;
301
+ justify-content: space-between;
302
+ gap: 1.5rem;
303
+ padding: 1.75rem 2rem;
304
+ background: rgba(15, 23, 42, 0.6);
305
+ border: 1px solid rgba(255, 255, 255, 0.1);
306
+ border-radius: 20px;
307
+ flex-wrap: wrap;
308
+ }
309
+
310
+ .support-icon {
311
+ font-size: 2rem;
312
+ }
313
+
314
+ .support-info {
315
+ flex: 1;
316
+ min-width: 240px;
317
+ }
318
+
319
+ .support-info h4 {
320
+ font-size: 1.15rem;
321
+ font-weight: 800;
322
+ color: #fff;
323
+ margin: 0 0 0.25rem;
324
+ }
325
+
326
+ .support-info p {
327
+ font-size: 0.88rem;
328
+ color: #94a3b8;
329
+ margin: 0;
330
+ }
331
+
332
+ .support-btn {
333
+ padding: 0.75rem 1.4rem;
334
+ background: rgba(255, 255, 255, 0.08);
335
+ border: 1px solid rgba(255, 255, 255, 0.15);
336
+ border-radius: 10px;
337
+ color: #fff;
338
+ font-size: 0.9rem;
339
+ font-weight: 700;
340
+ text-decoration: none;
341
+ transition: all 0.25s ease;
342
+ }
343
+
344
+ .support-btn:hover {
345
+ background: #eab308;
346
+ color: #000;
347
+ border-color: #eab308;
348
+ }
349
+ </style>