@zoyth/simple-site-framework 1.0.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 (166) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +572 -0
  3. package/bin/create-simple-site.js +390 -0
  4. package/bin/simple-site.js +664 -0
  5. package/dist/client.js +135 -0
  6. package/dist/client.js.map +1 -0
  7. package/dist/client.mjs +107 -0
  8. package/dist/client.mjs.map +1 -0
  9. package/dist/components/index.d.mts +3936 -0
  10. package/dist/components/index.d.ts +3936 -0
  11. package/dist/components/index.js +38265 -0
  12. package/dist/components/index.js.map +1 -0
  13. package/dist/components/index.mjs +38173 -0
  14. package/dist/components/index.mjs.map +1 -0
  15. package/dist/config/index.d.mts +298 -0
  16. package/dist/config/index.d.ts +298 -0
  17. package/dist/config/index.js +19 -0
  18. package/dist/config/index.js.map +1 -0
  19. package/dist/config/index.mjs +1 -0
  20. package/dist/config/index.mjs.map +1 -0
  21. package/dist/index.d.mts +2184 -0
  22. package/dist/index.d.ts +2184 -0
  23. package/dist/index.js +1713 -0
  24. package/dist/index.js.map +1 -0
  25. package/dist/index.mjs +1605 -0
  26. package/dist/index.mjs.map +1 -0
  27. package/dist/lib/i18n/index.js +665 -0
  28. package/dist/lib/i18n/index.js.map +1 -0
  29. package/dist/lib/i18n/index.mjs +621 -0
  30. package/dist/lib/i18n/index.mjs.map +1 -0
  31. package/docs/DOCUMENTATION-STRUCTURE.md +1156 -0
  32. package/docs/EXPORTS.md +125 -0
  33. package/docs/PERFORMANCE.md +757 -0
  34. package/docs/POLICY-PAGES.md +867 -0
  35. package/docs/ROADMAP.md +334 -0
  36. package/docs/SEO.md +455 -0
  37. package/docs/SITEMAP.md +708 -0
  38. package/docs/STRUCTURED-DATA.md +671 -0
  39. package/docs/accessibility/common-patterns.md +529 -0
  40. package/docs/accessibility/keyboard-navigation.md +263 -0
  41. package/docs/accessibility/overview.md +122 -0
  42. package/docs/accessibility/screen-readers.md +311 -0
  43. package/docs/accessibility/wcag-compliance.md +159 -0
  44. package/docs/api/README.md +164 -0
  45. package/docs/api/components/Accessibility.md +356 -0
  46. package/docs/api/components/Button.md +240 -0
  47. package/docs/api/components/HeroSection.md +306 -0
  48. package/docs/architecture/decisions.md +449 -0
  49. package/docs/components/AnalyticsTracker.md +58 -0
  50. package/docs/components/AnimatedCounter.md +48 -0
  51. package/docs/components/AnimatedSection.md +56 -0
  52. package/docs/components/BlogCard.md +42 -0
  53. package/docs/components/Checkbox.md +56 -0
  54. package/docs/components/CodeBlock.md +52 -0
  55. package/docs/components/ComparisonTable.md +40 -0
  56. package/docs/components/ComponentDemo.md +38 -0
  57. package/docs/components/CountdownTimer.md +51 -0
  58. package/docs/components/ExitIntentModal.md +56 -0
  59. package/docs/components/FAQAccordion.md +66 -0
  60. package/docs/components/FeaturesGrid.md +55 -0
  61. package/docs/components/FileUpload.md +54 -0
  62. package/docs/components/I18nMetaTags.md +55 -0
  63. package/docs/components/Icon.md +53 -0
  64. package/docs/components/LazySection.md +46 -0
  65. package/docs/components/LiveProof.md +53 -0
  66. package/docs/components/LoadingSpinner.md +46 -0
  67. package/docs/components/MultiStepForm.md +48 -0
  68. package/docs/components/PolicyLayout.md +55 -0
  69. package/docs/components/PricingTable.md +49 -0
  70. package/docs/components/Radio.md +59 -0
  71. package/docs/components/SEOMetaTags.md +58 -0
  72. package/docs/components/ScriptInjector.md +50 -0
  73. package/docs/components/Select.md +72 -0
  74. package/docs/components/Skeleton.md +47 -0
  75. package/docs/components/StatsSection.md +48 -0
  76. package/docs/components/StickyBar.md +62 -0
  77. package/docs/components/StructuredData.md +99 -0
  78. package/docs/components/StyleGuide.md +46 -0
  79. package/docs/components/TableOfContents.md +47 -0
  80. package/docs/components/TestimonialCarousel.md +42 -0
  81. package/docs/components/Timeline.md +51 -0
  82. package/docs/components/Toast.md +59 -0
  83. package/docs/components/TrackedLink.md +62 -0
  84. package/docs/components/TrustBadges.md +44 -0
  85. package/docs/components/conversion/MobileCTA.md +363 -0
  86. package/docs/components/forms/ContactForm.md +75 -0
  87. package/docs/components/forms/FormField.md +74 -0
  88. package/docs/components/layout/Footer.md +601 -0
  89. package/docs/components/layout/Header.md +549 -0
  90. package/docs/components/layout/LanguageSelector.md +54 -0
  91. package/docs/components/layout/LanguageSwitcher.md +24 -0
  92. package/docs/components/overview.md +447 -0
  93. package/docs/components/sections/AboutSection.md +48 -0
  94. package/docs/components/sections/CTASection.md +596 -0
  95. package/docs/components/sections/CaseStudySection.md +47 -0
  96. package/docs/components/sections/ContactSection.md +599 -0
  97. package/docs/components/sections/FeatureSection.md +44 -0
  98. package/docs/components/sections/HeroSection.md +404 -0
  99. package/docs/components/sections/LogosSection.md +47 -0
  100. package/docs/components/sections/PersonalTaxesSection.md +23 -0
  101. package/docs/components/sections/RecruitingSection.md +23 -0
  102. package/docs/components/sections/SecurePortalSection.md +23 -0
  103. package/docs/components/sections/ServicePageLayout.md +52 -0
  104. package/docs/components/sections/ServicesSection.md +49 -0
  105. package/docs/components/sections/TestimonialSection.md +44 -0
  106. package/docs/components/sections/WhyChooseUsSection.md +54 -0
  107. package/docs/components/ui/Breadcrumb.md +70 -0
  108. package/docs/components/ui/Button.md +514 -0
  109. package/docs/components/ui/Card.md +501 -0
  110. package/docs/components/ui/Input.md +54 -0
  111. package/docs/components/ui/MobileLinks.md +43 -0
  112. package/docs/components/ui/Modal.md +60 -0
  113. package/docs/components/ui/Tabs.md +62 -0
  114. package/docs/components/ui/Textarea.md +52 -0
  115. package/docs/core-concepts/configuration-driven.md +552 -0
  116. package/docs/core-concepts/overview.md +351 -0
  117. package/docs/features/accessibility/README.md +73 -0
  118. package/docs/features/accessibility/aria-support.md +177 -0
  119. package/docs/features/accessibility/color-contrast.md +155 -0
  120. package/docs/features/accessibility/focus-management.md +187 -0
  121. package/docs/features/accessibility/testing.md +196 -0
  122. package/docs/features/analytics/README.md +51 -0
  123. package/docs/features/analytics/ab-testing.md +171 -0
  124. package/docs/features/analytics/conversion-tracking.md +207 -0
  125. package/docs/features/analytics/custom-events.md +219 -0
  126. package/docs/features/analytics/privacy.md +198 -0
  127. package/docs/features/analytics/setup.md +114 -0
  128. package/docs/features/analytics/tracking-events.md +224 -0
  129. package/docs/features/i18n/README.md +51 -0
  130. package/docs/features/i18n/best-practices.md +273 -0
  131. package/docs/features/i18n/configuration.md +84 -0
  132. package/docs/features/i18n/formatting.md +133 -0
  133. package/docs/features/i18n/locale-detection.md +122 -0
  134. package/docs/features/i18n/routing.md +99 -0
  135. package/docs/features/i18n/rtl-support.md +191 -0
  136. package/docs/features/i18n/translations.md +129 -0
  137. package/docs/features/internationalization.md +595 -0
  138. package/docs/features/performance/README.md +77 -0
  139. package/docs/features/performance/bundle-size.md +134 -0
  140. package/docs/features/performance/caching.md +131 -0
  141. package/docs/features/performance/code-splitting.md +121 -0
  142. package/docs/features/performance/image-optimization.md +110 -0
  143. package/docs/features/performance/lazy-loading.md +92 -0
  144. package/docs/features/performance/monitoring.md +148 -0
  145. package/docs/features/seo/README.md +51 -0
  146. package/docs/features/seo/best-practices.md +184 -0
  147. package/docs/features/seo/canonical-urls.md +182 -0
  148. package/docs/features/seo/meta-tags.md +126 -0
  149. package/docs/features/seo/open-graph.md +166 -0
  150. package/docs/features/seo/robots-txt.md +146 -0
  151. package/docs/features/seo/sitemaps.md +162 -0
  152. package/docs/features/seo/structured-data.md +166 -0
  153. package/docs/getting-started/installation.md +292 -0
  154. package/docs/getting-started/introduction.md +195 -0
  155. package/docs/getting-started/quick-start.md +460 -0
  156. package/docs/guides/analytics-setup.md +616 -0
  157. package/docs/i18n/CONFIGURATION.md +353 -0
  158. package/docs/i18n/EXAMPLES.md +402 -0
  159. package/docs/i18n/MIGRATION.md +260 -0
  160. package/docs/i18n/SEO.md +392 -0
  161. package/docs/i18n/STATIC-GENERATION-FIX.md +71 -0
  162. package/docs/migration/changelog.md +136 -0
  163. package/docs/migration/overview.md +233 -0
  164. package/docs/recipes/adding-animations.md +475 -0
  165. package/docs/recipes/forms-with-validation.md +393 -0
  166. package/package.json +152 -0
@@ -0,0 +1,75 @@
1
+ # ContactForm
2
+
3
+ Production-ready contact form with validation and accessibility.
4
+
5
+ ## Import
6
+
7
+ ```typescript
8
+ import { ContactForm } from '@zoyth/simple-site-framework';
9
+ ```
10
+
11
+ **Type:** Client Component (`/client` export)
12
+
13
+ ## Basic Usage
14
+
15
+ ```typescript
16
+ <ContactForm
17
+ fields={[
18
+ { name: 'name', type: 'text', label: 'Name', required: true },
19
+ { name: 'email', type: 'email', label: 'Email', required: true },
20
+ { name: 'message', type: 'textarea', label: 'Message', required: true },
21
+ ]}
22
+ onSubmit={async (data) => {
23
+ await fetch('/api/contact', {
24
+ method: 'POST',
25
+ body: JSON.stringify(data),
26
+ });
27
+ }}
28
+ />
29
+ ```
30
+
31
+ ## Props
32
+
33
+ | Prop | Type | Required | Description |
34
+ |------|------|----------|-------------|
35
+ | `fields` | `ContactFormField[]` | Yes | Form fields |
36
+ | `onSubmit` | `function` | Yes | Submit handler |
37
+ | `submitText` | `string \| LocalizedString` | No | Submit button text |
38
+ | `successMessage` | `string \| LocalizedString` | No | Success message |
39
+ | `errorMessage` | `string \| LocalizedString` | No | Error message |
40
+ | `className` | `string` | No | Custom classes |
41
+ | `locale` | `string` | No | Current locale |
42
+
43
+ ### ContactFormField
44
+
45
+ | Prop | Type | Required | Description |
46
+ |------|------|----------|-------------|
47
+ | `name` | `string` | Yes | Field name |
48
+ | `type` | `string` | No | Field type |
49
+ | `label` | `string \| LocalizedString` | Yes | Field label |
50
+ | `placeholder` | `string` | No | Placeholder |
51
+ | `required` | `boolean` | No | Required field |
52
+ | `rows` | `number` | No | Rows (textarea) |
53
+
54
+ ## Examples
55
+
56
+ ```typescript
57
+ // Quote request form
58
+ <ContactForm
59
+ fields={[
60
+ { name: 'name', type: 'text', label: 'Full Name', required: true },
61
+ { name: 'email', type: 'email', label: 'Email', required: true },
62
+ { name: 'company', type: 'text', label: 'Company' },
63
+ { name: 'budget', type: 'text', label: 'Budget' },
64
+ { name: 'details', type: 'textarea', label: 'Project Details', required: true, rows: 6 },
65
+ ]}
66
+ submitText="Request Quote"
67
+ successMessage="Thanks! We'll send you a quote within 24 hours."
68
+ onSubmit={handleSubmit}
69
+ />
70
+ ```
71
+
72
+ ## See Also
73
+
74
+ - [ContactSection](../sections/ContactSection.md)
75
+ - [FormField](./FormField.md)
@@ -0,0 +1,74 @@
1
+ # FormField
2
+
3
+ Form field wrapper with label, error, and help text.
4
+
5
+ ## Import
6
+
7
+ ```typescript
8
+ import { FormField } from '@zoyth/simple-site-framework';
9
+ ```
10
+
11
+ **Type:** Server Component
12
+
13
+ ## Basic Usage
14
+
15
+ ```typescript
16
+ <FormField
17
+ label="Email Address"
18
+ name="email"
19
+ error={errors.email}
20
+ helperText="We'll never share your email"
21
+ >
22
+ <Input name="email" type="email" />
23
+ </FormField>
24
+ ```
25
+
26
+ ## Props
27
+
28
+ | Prop | Type | Required | Description |
29
+ |------|------|----------|-------------|
30
+ | `label` | `string \| LocalizedString` | Yes | Field label |
31
+ | `name` | `string` | Yes | Field name |
32
+ | `children` | `ReactNode` | Yes | Input element |
33
+ | `error` | `string` | No | Error message |
34
+ | `helperText` | `string` | No | Help text |
35
+ | `required` | `boolean` | No | Mark as required |
36
+ | `className` | `string` | No | Custom classes |
37
+
38
+ ## Examples
39
+
40
+ ```typescript
41
+ // With error
42
+ <FormField
43
+ label="Password"
44
+ name="password"
45
+ error="Password must be at least 8 characters"
46
+ required
47
+ >
48
+ <Input name="password" type="password" />
49
+ </FormField>
50
+
51
+ // With helper text
52
+ <FormField
53
+ label="Username"
54
+ name="username"
55
+ helperText="Choose a unique username"
56
+ >
57
+ <Input name="username" />
58
+ </FormField>
59
+
60
+ // Multi-language
61
+ <FormField
62
+ label={{ en: 'Full Name', fr: 'Nom complet' }}
63
+ name="name"
64
+ locale={locale}
65
+ >
66
+ <Input name="name" />
67
+ </FormField>
68
+ ```
69
+
70
+ ## See Also
71
+
72
+ - [Input](../ui/Input.md)
73
+ - [Textarea](../ui/Textarea.md)
74
+ - [ContactForm](./ContactForm.md)