Skip to content

Commit 6958411

Browse files
committed
feat: add CtaSection, FeaturesSection, HeroSection, and HeroStat components with interactive features and styling
- Implemented CtaSection for call-to-action with installation options and links. - Created FeaturesSection showcasing key features with visual elements and code examples. - Developed HeroSection with engaging background effects, title, subtitle, and action buttons. - Added HeroStat component for displaying statistics with icons and labels. - Introduced useAppToast composable for managing toast notifications. - Configured content management with Nuxt Content and Vercel deployment settings. - Updated package-lock.json for dependency management.
1 parent 3d661cf commit 6958411

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+6842
-9415
lines changed

UPGRADING.md

Lines changed: 0 additions & 455 deletions
This file was deleted.
3.14 MB
Binary file not shown.

docs-v3/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,3 +99,5 @@ Thumbs.db
9999
# Temporary files
100100
*.tmp
101101
*.temp
102+
103+
.vercel

docs-v3/app.vue

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
11
<template>
2-
<div>
2+
<UApp>
33
<NuxtPage />
4-
</div>
4+
<ClientOnly>
5+
<LazyUContentSearch
6+
v-model:search-term="searchTerm"
7+
shortcut="meta_k"
8+
:files="files"
9+
:navigation="navigation"
10+
:fuse="{ resultLimit: 42 }"
11+
placeholder="Search documentation..."
12+
/>
13+
</ClientOnly>
14+
</UApp>
515
</template>
616

717
<script setup lang="ts">
@@ -12,6 +22,9 @@ useHead({
1222
}
1323
})
1424
15-
// Enable dark mode
16-
const colorMode = useColorMode()
25+
// Fetch navigation and search data using the correct Nuxt Content composables
26+
const { data: navigation } = await useAsyncData('navigation', () => queryCollectionNavigation('content'))
27+
const { data: files } = await useAsyncData('search', () => queryCollectionSearchSections('content'))
28+
29+
const searchTerm = ref('')
1730
</script>

docs-v3/assets/css/main.css

Lines changed: 19 additions & 136 deletions
Original file line numberDiff line numberDiff line change
@@ -1,130 +1,30 @@
1-
@import 'tailwindcss/base';
2-
@import 'tailwindcss/components';
3-
@import 'tailwindcss/utilities';
4-
51
/* Custom fonts */
62
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
73
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&display=swap');
84

9-
/* Base styles */
10-
html {
11-
scroll-behavior: smooth;
12-
}
13-
14-
body {
15-
@apply font-sans antialiased;
16-
}
17-
18-
/* Scrollbar styling */
19-
::-webkit-scrollbar {
20-
@apply w-2;
21-
}
22-
23-
::-webkit-scrollbar-track {
24-
@apply bg-gray-100 dark:bg-gray-800;
25-
}
26-
27-
::-webkit-scrollbar-thumb {
28-
@apply bg-gray-300 dark:bg-gray-600 rounded-full;
29-
}
30-
31-
::-webkit-scrollbar-thumb:hover {
32-
@apply bg-gray-400 dark:bg-gray-500;
33-
}
34-
35-
/* Code block styling */
36-
pre {
37-
@apply overflow-x-auto p-4 rounded-lg;
38-
}
39-
40-
/* Shiki code blocks - light theme improvements */
41-
.shiki {
42-
@apply bg-gray-50 dark:bg-gray-900 border border-gray-200 dark:border-gray-700 rounded-lg;
43-
}
44-
45-
.shiki pre {
46-
@apply bg-transparent m-0 p-4;
47-
}
48-
49-
/* Override the dark background in light mode */
50-
.shiki.shiki-themes.github-light.github-dark {
51-
@apply bg-gray-50 dark:bg-gray-900;
52-
}
5+
@import "tailwindcss";
6+
@import "@nuxt/ui";
537

54-
.shiki code {
55-
@apply bg-transparent text-sm leading-relaxed;
8+
/* Tailwind v4 theme customization */
9+
@theme {
10+
--font-sans: 'Inter', system-ui, sans-serif;
11+
--font-mono: 'JetBrains Mono', Monaco, Consolas, monospace;
5612
}
5713

58-
/* Fix unstyled content in HTTP and other code blocks */
59-
.shiki code span:not([style]),
60-
.shiki code span[style=""],
61-
.shiki code span:empty,
62-
.shiki code span {
63-
@apply text-gray-800 dark:text-gray-200;
64-
}
65-
66-
/* Specific styling for HTTP code blocks */
67-
.language-http .shiki,
68-
.language-http.shiki {
69-
@apply bg-blue-50 dark:bg-gray-900;
70-
}
71-
72-
.language-http code,
73-
.language-http .shiki code,
74-
.language-http span {
75-
@apply text-blue-900 dark:text-blue-200 font-semibold;
76-
}
77-
78-
/* Override for all code block content to ensure visibility */
79-
.prose .shiki code,
80-
.prose .language-http code,
81-
.prose pre code {
82-
@apply text-gray-900 dark:text-gray-100;
83-
}
84-
85-
/* Force visibility for any unstyled spans in code */
86-
.prose .shiki code span,
87-
.prose .language-http code span,
88-
.prose pre code span {
89-
@apply text-gray-900 dark:text-gray-100;
90-
}
91-
92-
/* Special handling for HTTP method blocks */
93-
.language-http.shiki code span {
94-
@apply text-blue-900 dark:text-blue-200 font-semibold !important;
95-
}
96-
97-
/* Custom components */
98-
.prose-docs {
99-
@apply prose prose-gray max-w-none dark:prose-dark;
100-
}
101-
102-
/* Code blocks with blue gradient in light theme */
103-
.prose-docs pre {
104-
@apply bg-gradient-to-br from-blue-50 to-indigo-100 dark:from-gray-800 dark:to-gray-900 border border-blue-200 dark:border-gray-700 relative;
105-
}
106-
107-
.prose-docs pre code {
108-
@apply text-gray-900 dark:text-gray-100;
109-
}
110-
111-
/* Code block copy button styling */
112-
.prose-docs .group:hover .copy-button {
113-
@apply opacity-100;
114-
}
115-
116-
.prose-docs code {
117-
@apply text-sm font-mono bg-blue-200 dark:bg-gray-700 text-blue-900 dark:text-blue-300 px-2 py-1 rounded;
14+
/* Base styles */
15+
html {
16+
scroll-behavior: smooth;
11817
}
11918

120-
/* Inline code styling */
121-
.prose-docs :not(pre) > code {
122-
@apply bg-blue-200 dark:bg-gray-700 text-blue-900 dark:text-blue-300 px-2 py-1 rounded font-medium;
19+
/* Basic component styles */
20+
.nav-link-active {
21+
color: rgb(37 99 235);
22+
background-color: rgb(239 246 255);
12323
}
12424

125-
/* Navigation active states */
126-
.nav-link-active {
127-
@apply text-primary-600 dark:text-primary-400 bg-primary-50 dark:bg-primary-900/20;
25+
.dark .nav-link-active {
26+
color: rgb(96 165 250);
27+
background-color: rgba(59 130 246 / 0.2);
12828
}
12929

13030
/* Content transitions */
@@ -138,11 +38,6 @@ pre {
13838
opacity: 0;
13939
}
14040

141-
/* Focus styles */
142-
.focus-ring {
143-
@apply focus:outline-none focus:ring-2 focus:ring-primary-500 focus:ring-offset-2 dark:focus:ring-offset-gray-800;
144-
}
145-
14641
/* Mobile menu animation */
14742
.mobile-menu-enter-active,
14843
.mobile-menu-leave-active {
@@ -168,19 +63,7 @@ pre {
16863
transform: scale(1.05);
16964
}
17065

171-
/* Search highlight styles */
172-
mark {
173-
@apply bg-yellow-200 dark:bg-yellow-800 px-1 rounded text-gray-900 dark:text-white;
174-
}
175-
176-
/* Search modal animation */
177-
.search-modal-enter-active,
178-
.search-modal-leave-active {
179-
transition: all 0.2s ease;
180-
}
181-
182-
.search-modal-enter-from,
183-
.search-modal-leave-to {
184-
opacity: 0;
185-
transform: scale(0.95);
66+
/* Focus ring utility */
67+
.focus-ring {
68+
@apply focus:outline-none focus:ring-2 focus:ring-primary-500 focus:ring-offset-2 dark:focus:ring-offset-gray-800;
18669
}

docs-v3/components/CopyButton.vue

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,14 @@ const handleCopy = async () => {
6161
6262
} catch (error) {
6363
console.error('❌ All copy methods failed:', error)
64-
const { error: showError } = useToast()
64+
const { error: showError } = useAppToast()
6565
showError('Copy failed - please manually select and copy the text')
6666
}
6767
}
6868
6969
const showSuccess = () => {
7070
iscopied.value = true
71-
const { success } = useToast()
71+
const { success } = useAppToast()
7272
success('Copied to clipboard!')
7373
7474
setTimeout(() => {
@@ -78,6 +78,8 @@ const showSuccess = () => {
7878
</script>
7979

8080
<style scoped>
81+
@reference "tailwindcss";
82+
8183
.copy-btn {
8284
@apply absolute top-3 right-3 opacity-0 group-hover:opacity-100 transition-all duration-200 p-2 bg-white/90 dark:bg-gray-800/90 hover:bg-white dark:hover:bg-gray-800 rounded-md border border-gray-200 dark:border-gray-600 text-gray-600 dark:text-gray-400 hover:text-gray-900 dark:hover:text-gray-100 active:scale-95;
8385
}

docs-v3/components/SearchInput.vue

Lines changed: 0 additions & 49 deletions
This file was deleted.

0 commit comments

Comments
 (0)