Skip to content

Commit b397401

Browse files
authored
chore: migrate to shadcn-docs (#519)
1 parent ea39e26 commit b397401

21 files changed

+1941
-1559
lines changed

docs/.config/docs.yaml

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

docs/.gitignore

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
1-
node_modules
2-
.nuxt
1+
# Nuxt dev/build outputs
32
.output
3+
.data
4+
.nuxt
5+
.nitro
6+
.cache
47
dist
8+
9+
# Node dependencies
10+
node_modules
11+
12+
# Logs
13+
logs
14+
*.log
15+
16+
# Misc
517
.DS_Store
18+
.fleet
19+
.idea
20+
21+
# Local env files
22+
.env
23+
.env.*
24+
!.env.example

docs/.vscode/extensions.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"recommendations": [
3+
"nuxt.mdc"
4+
]
5+
}

docs/app.config.ts

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
export default defineAppConfig({
2+
shadcnDocs: {
3+
site: {
4+
name: 'magic-regexp',
5+
description: 'Beautifully designed Nuxt Content template built with shadcn-vue. Customizable. Compatible. Open Source.',
6+
ogImageComponent: 'ShadcnDocs',
7+
ogImageColor: 'dark',
8+
},
9+
theme: {
10+
customizable: false,
11+
color: '',
12+
radius: 0.5,
13+
},
14+
header: {
15+
title: 'magic-regexp',
16+
showTitle: true,
17+
darkModeToggle: true,
18+
logo: {
19+
light: '/logo.svg',
20+
dark: '/logo.svg',
21+
},
22+
nav: [],
23+
links: [{
24+
icon: 'lucide:github',
25+
to: 'https://github.com/unjs/magic-regexp',
26+
target: '_blank',
27+
}],
28+
},
29+
aside: {
30+
useLevel: true,
31+
collapse: false,
32+
},
33+
main: {
34+
breadCrumb: true,
35+
showTitle: true,
36+
},
37+
footer: {
38+
credits: 'Made with ❤️. Copyright © 2025 Daniel Roe',
39+
links: [{
40+
icon: 'lucide:github',
41+
to: 'https://github.com/unjs/magic-regexp',
42+
target: '_blank',
43+
}],
44+
},
45+
toc: {
46+
enable: true,
47+
title: 'On This Page',
48+
links: [{
49+
title: 'Star on GitHub',
50+
icon: 'lucide:star',
51+
to: 'https://github.com/unjs/magic-regexp',
52+
target: '_blank',
53+
}, {
54+
title: 'Create Issues',
55+
icon: 'lucide:circle-dot',
56+
to: 'https://github.com/unjs/magic-regexp/issues',
57+
target: '_blank',
58+
}],
59+
},
60+
search: {
61+
enable: true,
62+
inAside: false,
63+
},
64+
},
65+
})

docs/assets/css/tailwind.css

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
@tailwind base;
2+
@tailwind components;
3+
@tailwind utilities;
4+
5+
6+
@layer base {
7+
:root {
8+
--background: 0 0% 100%;
9+
--foreground: 240 10% 3.9%;
10+
11+
--card: 0 0% 100%;
12+
--card-foreground: 240 10% 3.9%;
13+
14+
--popover: 0 0% 100%;
15+
--popover-foreground: 240 10% 3.9%;
16+
17+
--primary: 320 90% 60%;
18+
--primary-foreground: 0 0% 100%;
19+
20+
--secondary: 240 4.8% 95.9%;
21+
--secondary-foreground: 240 5.9% 10%;
22+
23+
--muted: 240 4.8% 95.9%;
24+
--muted-foreground: 240 3.8% 46.1%;
25+
26+
--accent: 240 4.8% 95.9%;
27+
--accent-foreground: 240 5.9% 10%;
28+
29+
--destructive: 0 84.2% 60.2%;
30+
--destructive-foreground: 0 0% 98%;
31+
32+
--border:240 5.9% 10%;
33+
--input:240 5.9% 90%;
34+
--ring:240 5.9% 10%;
35+
--radius: 0.5rem;
36+
}
37+
38+
.dark {
39+
--background:240 10% 3.9%;
40+
--foreground:0 0% 98%;
41+
42+
--card:240 10% 3.9%;
43+
--card-foreground:0 0% 98%;
44+
45+
--popover:240 10% 3.9%;
46+
--popover-foreground:0 0% 98%;
47+
48+
--primary: 320 90% 60%;
49+
--primary-foreground: 0 0% 100%;
50+
51+
--secondary:240 3.7% 15.9%;
52+
--secondary-foreground:0 0% 98%;
53+
54+
--muted:240 3.7% 15.9%;
55+
--muted-foreground:240 5% 64.9%;
56+
57+
--accent:240 3.7% 15.9%;
58+
--accent-foreground:0 0% 98%;
59+
60+
--destructive:0 62.8% 30.6%;
61+
--destructive-foreground:0 0% 98%;
62+
63+
--border:240 3.7% 15.9%;
64+
--input:240 3.7% 15.9%;
65+
--ring:240 4.9% 83.9%;
66+
}
67+
}
68+
69+
70+
@layer utilities {
71+
.step {
72+
counter-increment: step;
73+
}
74+
75+
.step:before {
76+
@apply absolute w-9 h-9 bg-muted rounded-full font-mono font-medium text-center text-base inline-flex items-center justify-center -indent-px border-4 border-background;
77+
@apply -ml-[50px] -mt-1;
78+
content: counter(step);
79+
}
80+
}
81+
82+
@layer base {
83+
* {
84+
@apply border-border;
85+
}
86+
87+
body {
88+
@apply bg-background text-foreground;
89+
}
90+
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

docs/1.guide/5.converter.md renamed to docs/content/1.guide/5.converter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ It is also possible to convert existing regular expressions to `magic-regexp` sy
77
```ts
88
import { convert } from 'magic-regexp/converter'
99

10-
convert(/a|b|c/)
10+
convert(/[abc]/)
1111
// createRegExp(exactly('a').or('b').or('c'))
1212

1313
convert(/(foo)bar\d+/)

0 commit comments

Comments
 (0)