@xenterprises/nuxt-x-marketing 1.0.2 → 1.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 (64) hide show
  1. package/README.md +130 -11
  2. package/app/components/X/Mark/CodeBlock/index.vue +19 -7
  3. package/app/components/X/Mark/Divider/Glow.vue +25 -19
  4. package/app/components/X/Mark/Section/Stitch.vue +45 -31
  5. package/app/composables/{useParallax.ts → useParallax.js} +6 -7
  6. package/app/composables/{useScrollReveal.ts → useScrollReveal.js} +4 -4
  7. package/nuxt.config.ts +1 -11
  8. package/package.json +1 -1
  9. package/.claude/settings.local.json +0 -23
  10. package/.nuxtrc +0 -1
  11. package/.playground/app.config.ts +0 -74
  12. package/.playground/app.vue +0 -269
  13. package/.playground/components/AppFooter.vue +0 -103
  14. package/.playground/components/AppHeader.vue +0 -41
  15. package/.playground/components/CodeExample.vue +0 -70
  16. package/.playground/components/ComponentPlayground.vue +0 -117
  17. package/.playground/components/DocsHeader.vue +0 -19
  18. package/.playground/layouts/default.vue +0 -15
  19. package/.playground/layouts/docs-layout.vue +0 -161
  20. package/.playground/layouts/docs.vue +0 -11
  21. package/.playground/nuxt.config.ts +0 -5
  22. package/.playground/package-lock.json +0 -6
  23. package/.playground/pages/blog/author.vue +0 -145
  24. package/.playground/pages/blog/card.vue +0 -149
  25. package/.playground/pages/blog/cta.vue +0 -131
  26. package/.playground/pages/blog/detail.vue +0 -471
  27. package/.playground/pages/blog/list.vue +0 -261
  28. package/.playground/pages/blog/navigation.vue +0 -228
  29. package/.playground/pages/blog/sidebar.vue +0 -279
  30. package/.playground/pages/config.vue +0 -289
  31. package/.playground/pages/content/comparison.vue +0 -253
  32. package/.playground/pages/content/cta.vue +0 -245
  33. package/.playground/pages/content/features.vue +0 -217
  34. package/.playground/pages/content/newsletter-section.vue +0 -260
  35. package/.playground/pages/content/newsletter.vue +0 -200
  36. package/.playground/pages/content/pricing.vue +0 -335
  37. package/.playground/pages/content/testimonials.vue +0 -188
  38. package/.playground/pages/hero.vue +0 -257
  39. package/.playground/pages/index.vue +0 -381
  40. package/.playground/pages/layout/footer.vue +0 -210
  41. package/.playground/pages/layout/legal-footer.vue +0 -121
  42. package/.playground/pages/layout/navbar.vue +0 -285
  43. package/.playground/pages/layout/section.vue +0 -266
  44. package/.playground/pages/layout/x-legal.vue +0 -199
  45. package/.playground/pages/modals/feature-modal.vue +0 -320
  46. package/.playground/pages/modals/image-lightbox.vue +0 -277
  47. package/.playground/pages/modals/video-modal.vue +0 -222
  48. package/.playground/pages/notifications/announcement-bar.vue +0 -164
  49. package/.playground/pages/notifications/cookie-banner.vue +0 -210
  50. package/.playground/pages/notifications/cookie-toast.vue +0 -143
  51. package/.playground/pages/notifications/gdpr.vue +0 -276
  52. package/.playground/pages/notifications/social-proof-toast.vue +0 -515
  53. package/.playground/pages/ui/badge.vue +0 -161
  54. package/.playground/pages/ui/bg-pattern.vue +0 -177
  55. package/.playground/pages/ui/glass-card.vue +0 -179
  56. package/.playground/pages/ui/glow-divider.vue +0 -179
  57. package/.playground/pages/ui/promo-card.vue +0 -259
  58. package/.playground/pages/ui/section-stitch.vue +0 -411
  59. package/.playground/pages/utilities/back-to-top.vue +0 -153
  60. package/.playground/pages/utilities/popup-chat.vue +0 -224
  61. package/componentList.json +0 -2129
  62. package/screenshots/playground-home.png +0 -0
  63. package/tsconfig.json +0 -3
  64. /package/app/composables/{useXBlog.ts → useXBlog.js} +0 -0
@@ -1,161 +0,0 @@
1
- <template>
2
- <div class="min-h-screen bg-white dark:bg-gray-950">
3
- <NuxtLoadingIndicator />
4
-
5
- <DocsHeader />
6
-
7
- <div class="flex h-[calc(100vh-3.5rem)]">
8
- <!-- Collapsible Sidebar -->
9
- <aside
10
- class="hidden lg:flex lg:flex-col lg:border-r lg:border-gray-200 dark:lg:border-gray-800 transition-all duration-300"
11
- :class="sidebarCollapsed ? 'lg:w-20' : 'lg:w-64'"
12
- >
13
- <!-- Toggle Button -->
14
- <div
15
- class="flex items-center justify-between px-4 py-4 border-b border-gray-200 dark:border-gray-800"
16
- >
17
- <span
18
- v-if="!sidebarCollapsed"
19
- class="text-sm font-semibold text-gray-900 dark:text-white"
20
- >
21
- Navigation
22
- </span>
23
- <button
24
- @click="sidebarCollapsed = !sidebarCollapsed"
25
- class="p-1.5 hover:bg-gray-100 dark:hover:bg-gray-800 rounded-md transition-colors"
26
- :title="sidebarCollapsed ? 'Expand' : 'Collapse'"
27
- >
28
- <UIcon
29
- :name="
30
- sidebarCollapsed
31
- ? 'i-lucide-chevron-right'
32
- : 'i-lucide-chevron-left'
33
- "
34
- class="w-5 h-5"
35
- />
36
- </button>
37
- </div>
38
-
39
- <!-- Navigation Menu -->
40
- <nav class="flex-1 overflow-y-auto">
41
- <UNavigationMenu
42
- :items="navigationItems"
43
- orientation="vertical"
44
- :collapsed="sidebarCollapsed"
45
- :tooltip="sidebarCollapsed"
46
- :popover="sidebarCollapsed"
47
- variant="link"
48
- class="w-full"
49
- />
50
- </nav>
51
-
52
- <!-- Sidebar Footer -->
53
- <div class="border-t border-gray-200 dark:border-gray-800 px-4 py-4">
54
- <NuxtLink
55
- to="/"
56
- class="flex items-center gap-2 px-2 py-1.5 text-sm text-gray-600 dark:text-gray-400 hover:text-gray-900 dark:hover:text-white rounded-md hover:bg-gray-100 dark:hover:bg-gray-800 transition-colors"
57
- :title="sidebarCollapsed ? 'Back to Demo' : ''"
58
- >
59
- <UIcon name="i-lucide-arrow-left" class="w-4 h-4 shrink-0" />
60
- <span v-if="!sidebarCollapsed">Back to Demo</span>
61
- </NuxtLink>
62
- </div>
63
- </aside>
64
-
65
- <!-- Main Content - Full Screen -->
66
- <main class="flex-1 overflow-y-auto">
67
- <div class="w-full h-full px-4 sm:px-6 lg:px-8 py-8">
68
- <slot />
69
- </div>
70
- </main>
71
- </div>
72
- </div>
73
- </template>
74
-
75
- <script setup lang="ts">
76
- import type { NavigationMenuItem } from "@nuxt/ui";
77
-
78
- const route = useRoute();
79
- const sidebarCollapsed = ref(false);
80
-
81
- const navigationItems: NavigationMenuItem[][] = [
82
- [
83
- {
84
- label: "Getting Started",
85
- icon: "i-lucide-book-open",
86
- defaultOpen: true,
87
- children: [
88
- { label: "Introduction", to: "/docs" },
89
- { label: "Quick Start", to: "/docs/quick-start" },
90
- { label: "Installation", to: "/docs/installation" },
91
- ],
92
- },
93
- {
94
- label: "Hero Sections",
95
- icon: "i-lucide-image",
96
- children: [
97
- { label: "Hero Centered", to: "/docs/components/hero/centered" },
98
- { label: "Hero Split", to: "/docs/components/hero/split" },
99
- { label: "Hero Image", to: "/docs/components/hero/image" },
100
- { label: "Hero Video", to: "/docs/components/hero/video" },
101
- { label: "Hero Slider", to: "/docs/components/hero/slider" },
102
- ],
103
- },
104
- {
105
- label: "Features",
106
- icon: "i-lucide-sparkles",
107
- children: [
108
- { label: "Feature Grid", to: "/docs/components/feature/grid" },
109
- { label: "Feature Card", to: "/docs/components/feature/card" },
110
- { label: "Feature Showcase", to: "/docs/components/feature/showcase" },
111
- { label: "Feature Preview", to: "/docs/components/feature/preview" },
112
- ],
113
- },
114
- {
115
- label: "CTA & Conversion",
116
- icon: "i-lucide-zap",
117
- children: [
118
- { label: "CTA Section", to: "/docs/components/cta/section" },
119
- { label: "CTA Card", to: "/docs/components/cta/card" },
120
- { label: "CTA Banner", to: "/docs/components/cta/banner" },
121
- ],
122
- },
123
- {
124
- label: "Content",
125
- icon: "i-lucide-file-text",
126
- children: [
127
- { label: "Testimonials", to: "/docs/components/testimonial" },
128
- { label: "Blog Grid", to: "/docs/components/blog/grid" },
129
- { label: "Blog Card", to: "/docs/components/blog/card" },
130
- { label: "FAQ", to: "/docs/components/faq" },
131
- ],
132
- },
133
- {
134
- label: "Stats & Metrics",
135
- icon: "i-lucide-bar-chart-3",
136
- children: [
137
- { label: "Stats Section", to: "/docs/components/stats/section" },
138
- { label: "Stats Grid", to: "/docs/components/stats/grid" },
139
- ],
140
- },
141
- {
142
- label: "Navigation & Layout",
143
- icon: "i-lucide-layout",
144
- children: [
145
- { label: "Header App", to: "/docs/components/header/app" },
146
- { label: "Header Nav", to: "/docs/components/header/nav" },
147
- { label: "Footer", to: "/docs/components/footer" },
148
- ],
149
- },
150
- {
151
- label: "State",
152
- icon: "i-lucide-inbox",
153
- children: [
154
- { label: "Empty State", to: "/docs/components/state/empty" },
155
- { label: "Loading State", to: "/docs/components/state/loading" },
156
- ],
157
- },
158
- ],
159
- ];
160
- </script>
161
-
@@ -1,11 +0,0 @@
1
- <template>
2
- <div>
3
- <script setup>
4
- definePageMeta({
5
- layout: "docs-layout",
6
- });
7
- </script>
8
- <slot />
9
- </div>
10
- </template>
11
-
@@ -1,5 +0,0 @@
1
- export default defineNuxtConfig({
2
- extends: ['..'],
3
-
4
- compatibilityDate: "2024-10-23",
5
- });
@@ -1,6 +0,0 @@
1
- {
2
- "name": ".playground",
3
- "lockfileVersion": 3,
4
- "requires": true,
5
- "packages": {}
6
- }
@@ -1,145 +0,0 @@
1
- <template>
2
- <div class="min-h-screen">
3
- <div class="bg-white dark:bg-neutral-900 border-b border-neutral-200 dark:border-neutral-800 px-8 py-6">
4
- <h1 class="text-2xl font-bold text-neutral-900 dark:text-white">Blog Author</h1>
5
- <p class="mt-2 text-neutral-600 dark:text-neutral-400">Author bios in inline, card, and full variants.</p>
6
- </div>
7
-
8
- <div class="space-y-0">
9
- <!-- Inline Variant -->
10
- <XMarkSection bg="default">
11
- <div class="text-center mb-8">
12
- <span class="inline-block px-3 py-1 rounded-full bg-primary-100 dark:bg-primary-900/30 text-primary-600 dark:text-primary-400 text-xs font-medium mb-4">variant="inline"</span>
13
- <h2 class="xText-headline">Inline Variant</h2>
14
- <p class="mt-4 text-neutral-600 dark:text-neutral-400">Compact author info for post headers and bylines</p>
15
- </div>
16
- <div class="max-w-2xl mx-auto">
17
- <XMarkBlogAuthor :author="author" variant="inline" />
18
- </div>
19
- </XMarkSection>
20
-
21
- <!-- Card Variant -->
22
- <XMarkSection bg="subtle">
23
- <div class="text-center mb-8">
24
- <span class="inline-block px-3 py-1 rounded-full bg-primary-100 dark:bg-primary-900/30 text-primary-600 dark:text-primary-400 text-xs font-medium mb-4">variant="card"</span>
25
- <h2 class="xText-headline">Card Variant</h2>
26
- <p class="mt-4 text-neutral-600 dark:text-neutral-400">Author card for sidebars or author grids</p>
27
- </div>
28
- <div class="max-w-sm mx-auto">
29
- <XMarkBlogAuthor :author="author" variant="card" />
30
- </div>
31
- </XMarkSection>
32
-
33
- <!-- Full Variant -->
34
- <XMarkSection bg="default">
35
- <div class="text-center mb-8">
36
- <span class="inline-block px-3 py-1 rounded-full bg-primary-100 dark:bg-primary-900/30 text-primary-600 dark:text-primary-400 text-xs font-medium mb-4">variant="full"</span>
37
- <h2 class="xText-headline">Full Variant</h2>
38
- <p class="mt-4 text-neutral-600 dark:text-neutral-400">Complete author bio for post footers</p>
39
- </div>
40
- <div class="max-w-2xl mx-auto">
41
- <XMarkBlogAuthor :author="author" variant="full" />
42
- </div>
43
- </XMarkSection>
44
-
45
- <!-- Props -->
46
- <XMarkSection bg="subtle">
47
- <h2 class="text-lg font-semibold mb-6">Props</h2>
48
- <div class="overflow-x-auto">
49
- <table class="w-full text-sm">
50
- <thead>
51
- <tr class="border-b border-neutral-200 dark:border-neutral-700">
52
- <th class="text-left py-3 px-4 font-medium">Prop</th>
53
- <th class="text-left py-3 px-4 font-medium">Type</th>
54
- <th class="text-left py-3 px-4 font-medium">Default</th>
55
- <th class="text-left py-3 px-4 font-medium">Description</th>
56
- </tr>
57
- </thead>
58
- <tbody class="divide-y divide-neutral-200 dark:divide-neutral-700">
59
- <tr>
60
- <td class="py-3 px-4 font-mono text-xs">author</td>
61
- <td class="py-3 px-4">Object</td>
62
- <td class="py-3 px-4">required</td>
63
- <td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Author data object</td>
64
- </tr>
65
- <tr>
66
- <td class="py-3 px-4 font-mono text-xs">variant</td>
67
- <td class="py-3 px-4">String</td>
68
- <td class="py-3 px-4">'inline'</td>
69
- <td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">inline, sm, full, card</td>
70
- </tr>
71
- </tbody>
72
- </table>
73
- </div>
74
- </XMarkSection>
75
-
76
- <!-- Author Object Structure -->
77
- <XMarkSection bg="default">
78
- <h2 class="text-lg font-semibold mb-4">Author Object Structure</h2>
79
- <div class="bg-neutral-100 dark:bg-neutral-800 rounded-lg p-4 text-sm font-mono overflow-x-auto">
80
- <pre>{
81
- name: "Sarah Chen",
82
- avatar: "https://...",
83
- title: "Senior Developer",
84
- bio: "Sarah specializes in Vue.js and Nuxt...",
85
- social: {
86
- twitter: "https://twitter.com/sarahchen",
87
- linkedin: "https://linkedin.com/in/sarahchen",
88
- github: "https://github.com/sarahchen"
89
- }
90
- }</pre>
91
- </div>
92
- </XMarkSection>
93
-
94
- <!-- Code Example -->
95
- <XMarkSection bg="subtle">
96
- <h2 class="text-lg font-semibold mb-4">Code Example</h2>
97
- <CodeExample title="Blog Author Usage" :code="codeExample" />
98
- </XMarkSection>
99
- </div>
100
- </div>
101
- </template>
102
-
103
- <script setup>
104
- // Initialize scroll reveal animations
105
- useScrollReveal()
106
-
107
- const codeExample = `<!-- Inline - for post headers -->
108
- <XMarkBlogAuthor :author="author" variant="inline" />
109
-
110
- <!-- Small - compact byline -->
111
- <XMarkBlogAuthor :author="author" variant="sm" />
112
-
113
- <!-- Card - for sidebars -->
114
- <XMarkBlogAuthor :author="author" variant="card" />
115
-
116
- <!-- Full - for post footers -->
117
- <XMarkBlogAuthor :author="author" variant="full" />
118
-
119
- <!-- Author data structure -->
120
- <script setup>
121
- const author = {
122
- name: 'Sarah Chen',
123
- avatar: 'https://...',
124
- title: 'Senior Developer',
125
- bio: 'Sarah specializes in Vue.js and Nuxt...',
126
- social: {
127
- twitter: 'https://twitter.com/sarahchen',
128
- linkedin: 'https://linkedin.com/in/sarahchen',
129
- github: 'https://github.com/sarahchen'
130
- }
131
- }
132
- <\/script>`
133
-
134
- const author = {
135
- name: 'Sarah Chen',
136
- avatar: 'https://images.unsplash.com/photo-1494790108377-be9c29b29330?w=200&h=200&fit=crop',
137
- title: 'Senior Developer',
138
- bio: 'Sarah is a frontend developer with 8+ years of experience. She specializes in Vue.js and Nuxt, and loves creating beautiful, performant web applications. When not coding, she enjoys hiking and photography.',
139
- social: {
140
- twitter: 'https://twitter.com/sarahchen',
141
- linkedin: 'https://linkedin.com/in/sarahchen',
142
- github: 'https://github.com/sarahchen'
143
- }
144
- }
145
- </script>
@@ -1,149 +0,0 @@
1
- <template>
2
- <div class="min-h-screen">
3
- <div class="bg-white dark:bg-neutral-900 border-b border-neutral-200 dark:border-neutral-800 px-8 py-6">
4
- <h1 class="text-2xl font-bold text-neutral-900 dark:text-white">Blog Card</h1>
5
- <p class="mt-2 text-neutral-600 dark:text-neutral-400">Blog post cards with image, metadata, and excerpts.</p>
6
- </div>
7
-
8
- <div class="p-8">
9
- <!-- Default Cards -->
10
- <section>
11
- <h2 class="text-lg font-semibold mb-4">Default Cards</h2>
12
- <div class="grid md:grid-cols-3 gap-8 max-w-6xl">
13
- <XMarkBlogCard
14
- v-for="post in posts"
15
- :key="post.slug"
16
- :post="post"
17
- />
18
- </div>
19
- </section>
20
-
21
- <!-- With Button -->
22
- <section class="mt-12">
23
- <h2 class="text-lg font-semibold mb-4">With Button</h2>
24
- <p class="text-sm text-neutral-500 mb-4">Add a full-width button below the card content</p>
25
- <div class="grid md:grid-cols-3 gap-8 max-w-6xl">
26
- <XMarkBlogCard
27
- v-for="post in posts"
28
- :key="`btn-${post.slug}`"
29
- :post="post"
30
- :button="{ label: 'Read More', icon: 'i-lucide-arrow-right' }"
31
- />
32
- </div>
33
- </section>
34
-
35
- <div class="mt-12">
36
- <h2 class="text-lg font-semibold mb-4">Post Object Shape</h2>
37
- <div class="bg-neutral-100 dark:bg-neutral-800 rounded-lg p-4 text-sm font-mono overflow-x-auto">
38
- <pre>{
39
- title: "Post Title",
40
- description: "Brief description...",
41
- img: { src: "https://...", alt: "Image description" },
42
- slug: "post-slug",
43
- date: "2024-01-15",
44
- readingTime: 5,
45
- author: { name: "Author", avatar: "https://..." },
46
- category: "Tutorial"
47
- }</pre>
48
- </div>
49
- </div>
50
-
51
- <div class="mt-8">
52
- <h2 class="text-lg font-semibold mb-4">Component Props</h2>
53
- <table class="w-full text-sm">
54
- <thead>
55
- <tr class="border-b border-neutral-200 dark:border-neutral-700">
56
- <th class="text-left py-3 px-4">Prop</th>
57
- <th class="text-left py-3 px-4">Type</th>
58
- <th class="text-left py-3 px-4">Default</th>
59
- <th class="text-left py-3 px-4">Description</th>
60
- </tr>
61
- </thead>
62
- <tbody class="divide-y divide-neutral-200 dark:divide-neutral-700">
63
- <tr><td class="py-3 px-4 font-mono text-xs">post</td><td class="py-3 px-4">Object</td><td class="py-3 px-4">required</td><td class="py-3 px-4">Blog post object (see shape above)</td></tr>
64
- <tr><td class="py-3 px-4 font-mono text-xs">hasCategory</td><td class="py-3 px-4">Boolean</td><td class="py-3 px-4">true</td><td class="py-3 px-4">Show category badge</td></tr>
65
- <tr><td class="py-3 px-4 font-mono text-xs">hasAuthor</td><td class="py-3 px-4">Boolean</td><td class="py-3 px-4">true</td><td class="py-3 px-4">Show author info</td></tr>
66
- <tr><td class="py-3 px-4 font-mono text-xs">hasExcerpt</td><td class="py-3 px-4">Boolean</td><td class="py-3 px-4">true</td><td class="py-3 px-4">Show description</td></tr>
67
- <tr><td class="py-3 px-4 font-mono text-xs">button</td><td class="py-3 px-4">Object</td><td class="py-3 px-4">null</td><td class="py-3 px-4">{ label, color?, variant?, icon? }</td></tr>
68
- </tbody>
69
- </table>
70
- </div>
71
-
72
- <!-- Code Example -->
73
- <section class="mt-12">
74
- <h2 class="text-lg font-semibold mb-4">Code Example</h2>
75
- <CodeExample title="Blog Card Usage" :code="codeExample" />
76
- </section>
77
- </div>
78
- </div>
79
- </template>
80
-
81
- <script setup>
82
- // Initialize scroll reveal animations
83
- useScrollReveal()
84
-
85
- const codeExample = `<!-- Single blog card -->
86
- <XMarkBlogCard
87
- :post="{
88
- title: 'Getting Started with Nuxt',
89
- description: 'Learn the basics of building modern web apps.',
90
- img: { src: 'https://images.unsplash.com/...', alt: 'Code on screen' },
91
- slug: 'getting-started',
92
- date: '2024-01-15',
93
- readingTime: 5,
94
- author: { name: 'Sarah Chen', avatar: 'https://...' },
95
- category: 'Tutorial'
96
- }"
97
- />
98
-
99
- <!-- With button -->
100
- <XMarkBlogCard
101
- :post="post"
102
- :button="{ label: 'Read More', icon: 'i-lucide-arrow-right' }"
103
- />
104
-
105
- <!-- Without author -->
106
- <XMarkBlogCard :post="post" :has-author="false" />
107
-
108
- <!-- Grid of blog cards -->
109
- <div class="grid md:grid-cols-3 gap-8">
110
- <XMarkBlogCard
111
- v-for="post in posts"
112
- :key="post.slug"
113
- :post="post"
114
- />
115
- </div>`
116
-
117
- const posts = [
118
- {
119
- title: 'Getting Started with Nuxt',
120
- description: 'Learn the basics of building modern web applications with Nuxt 3.',
121
- img: { src: 'https://images.unsplash.com/photo-1517694712202-14dd9538aa97?w=400&h=300&fit=crop', alt: 'Code on laptop' },
122
- slug: 'getting-started',
123
- date: '2024-01-15',
124
- readingTime: 5,
125
- author: { name: 'Sarah Chen', avatar: 'https://images.unsplash.com/photo-1494790108377-be9c29b29330?w=50&h=50&fit=crop' },
126
- category: 'Tutorial'
127
- },
128
- {
129
- title: 'Vue 3 Composition API',
130
- description: 'Mastering the composition API for cleaner, more reusable code.',
131
- img: { src: 'https://images.unsplash.com/photo-1555066931-4365d14bab8c?w=400&h=300&fit=crop', alt: 'Programming code' },
132
- slug: 'composition-api',
133
- date: '2024-01-10',
134
- readingTime: 8,
135
- author: { name: 'Michael Torres', avatar: 'https://images.unsplash.com/photo-1500648767791-00dcc994a43e?w=50&h=50&fit=crop' },
136
- category: 'Development'
137
- },
138
- {
139
- title: 'Building Design Systems',
140
- description: 'Create consistent, scalable design systems for your projects.',
141
- img: { src: 'https://images.unsplash.com/photo-1460925895917-afdab827c52f?w=400&h=300&fit=crop', alt: 'Design dashboard' },
142
- slug: 'design-systems',
143
- date: '2024-01-05',
144
- readingTime: 6,
145
- author: { name: 'Emma Williams', avatar: 'https://images.unsplash.com/photo-1438761681033-6461ffad8d80?w=50&h=50&fit=crop' },
146
- category: 'Design'
147
- }
148
- ]
149
- </script>
@@ -1,131 +0,0 @@
1
- <template>
2
- <div class="min-h-screen">
3
- <div class="bg-white dark:bg-neutral-900 border-b border-neutral-200 dark:border-neutral-800 px-8 py-6">
4
- <h1 class="text-2xl font-bold text-neutral-900 dark:text-white">Blog Newsletter CTA</h1>
5
- <p class="mt-2 text-neutral-600 dark:text-neutral-400">In-article call-to-action for newsletter signups.</p>
6
- </div>
7
-
8
- <div class="p-8 space-y-16">
9
- <div class="space-y-12">
10
- <!-- Default -->
11
- <section>
12
- <h3 class="text-lg font-semibold mb-4">Default</h3>
13
- <div class="max-w-2xl">
14
- <XMarkBlogCTANewsletter
15
- title="Enjoying this article?"
16
- description="Subscribe to get notified when we publish new content."
17
- :button="{ label: 'Subscribe' }"
18
- />
19
- </div>
20
- </section>
21
-
22
- <!-- Featured -->
23
- <section>
24
- <h3 class="text-lg font-semibold mb-4">Featured</h3>
25
- <div class="max-w-2xl">
26
- <XMarkBlogCTANewsletter
27
- title="Join our newsletter"
28
- description="Get the latest posts delivered right to your inbox."
29
- :button="{ label: 'Subscribe Now' }"
30
- variant="featured"
31
- />
32
- </div>
33
- </section>
34
-
35
- <!-- Inline -->
36
- <section>
37
- <h3 class="text-lg font-semibold mb-4">Inline</h3>
38
- <div class="max-w-2xl">
39
- <XMarkBlogCTANewsletter
40
- title="Stay updated"
41
- description="New posts every week."
42
- :button="{ label: 'Join' }"
43
- variant="inline"
44
- />
45
- </div>
46
- </section>
47
-
48
- <!-- Compact -->
49
- <section>
50
- <h3 class="text-lg font-semibold mb-4">Compact (for sidebars)</h3>
51
- <div class="max-w-xs">
52
- <XMarkBlogCTANewsletter
53
- title="Subscribe"
54
- description="Get notified about new posts."
55
- :button="{ label: 'Subscribe' }"
56
- variant="compact"
57
- />
58
- </div>
59
- </section>
60
- </div>
61
-
62
- <!-- Props Documentation -->
63
- <div class="border-t border-neutral-200 dark:border-neutral-800 pt-16">
64
- <h2 class="text-lg font-semibold mb-6">Props</h2>
65
- <div class="overflow-x-auto">
66
- <table class="w-full text-sm">
67
- <thead>
68
- <tr class="border-b border-neutral-200 dark:border-neutral-700">
69
- <th class="text-left py-3 px-4 font-medium">Prop</th>
70
- <th class="text-left py-3 px-4 font-medium">Type</th>
71
- <th class="text-left py-3 px-4 font-medium">Default</th>
72
- <th class="text-left py-3 px-4 font-medium">Description</th>
73
- </tr>
74
- </thead>
75
- <tbody class="divide-y divide-neutral-200 dark:divide-neutral-700">
76
- <tr><td class="py-3 px-4 font-mono text-xs">title</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'Subscribe to our newsletter'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">CTA heading</td></tr>
77
- <tr><td class="py-3 px-4 font-mono text-xs">description</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'Get the latest posts...'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Supporting text</td></tr>
78
- <tr><td class="py-3 px-4 font-mono text-xs">button</td><td class="py-3 px-4">Object</td><td class="py-3 px-4">{ label: 'Subscribe' }</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Button config { label, color? }</td></tr>
79
- <tr><td class="py-3 px-4 font-mono text-xs">placeholder</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'Enter your email'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Email input placeholder</td></tr>
80
- <tr><td class="py-3 px-4 font-mono text-xs">variant</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'default'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">default, featured, inline, compact</td></tr>
81
- <tr><td class="py-3 px-4 font-mono text-xs">icon</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'i-lucide-mail'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Optional icon name</td></tr>
82
- <tr><td class="py-3 px-4 font-mono text-xs">hasPrivacy</td><td class="py-3 px-4">Boolean</td><td class="py-3 px-4">true</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Show privacy note</td></tr>
83
- <tr><td class="py-3 px-4 font-mono text-xs">privacyText</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'No spam. Unsubscribe anytime.'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Privacy note text</td></tr>
84
- <tr><td class="py-3 px-4 font-mono text-xs">successMessage</td><td class="py-3 px-4">String</td><td class="py-3 px-4">'Thanks for subscribing!'</td><td class="py-3 px-4 text-neutral-600 dark:text-neutral-400">Message shown on success</td></tr>
85
- </tbody>
86
- </table>
87
- </div>
88
-
89
- <h2 class="text-lg font-semibold mt-12 mb-4">Events</h2>
90
- <div class="space-y-4">
91
- <div class="p-4 bg-neutral-50 dark:bg-neutral-800/50 rounded-lg">
92
- <p class="font-mono text-sm text-primary-500">@submit</p>
93
- <p class="text-sm text-neutral-600 dark:text-neutral-400 mt-1">Emitted with email address when newsletter form is submitted</p>
94
- </div>
95
- </div>
96
- </div>
97
-
98
- <!-- Code Example -->
99
- <section>
100
- <h2 class="text-lg font-semibold mb-4">Code Example</h2>
101
- <CodeExample title="Blog Newsletter CTA" :code="codeExample" />
102
- </section>
103
- </div>
104
- </div>
105
- </template>
106
-
107
- <script setup>
108
- const codeExample = `<!-- Default -->
109
- <XMarkBlogCTANewsletter
110
- title="Enjoying this article?"
111
- description="Subscribe to get notified."
112
- :button="{ label: 'Subscribe' }"
113
- @submit="handleSubscribe"
114
- />
115
-
116
- <!-- Featured -->
117
- <XMarkBlogCTANewsletter
118
- title="Join our newsletter"
119
- :button="{ label: 'Subscribe Now' }"
120
- variant="featured"
121
- @submit="handleSubscribe"
122
- />
123
-
124
- <!-- Compact (for sidebars) -->
125
- <XMarkBlogCTANewsletter
126
- title="Subscribe"
127
- :button="{ label: 'Join' }"
128
- variant="compact"
129
- @submit="handleSubscribe"
130
- />`
131
- </script>