@windrun-huaiin/diaomao 11.1.0 → 11.1.2
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.
- package/eslint.config.js +32 -0
- package/messages/en.json +55 -53
- package/messages/zh.json +3 -1
- package/package.json +12 -10
- package/src/app/[locale]/(home)/layout.tsx +1 -1
- package/src/app/api/blog/llm-content/route.ts +1 -1
- package/src/app/api/legal/llm-content/route.ts +1 -1
- package/src/components/hero.tsx +1 -2
- package/src/components/mdx-components.tsx +1 -1
- package/src/mdx/blog/index.mdx +1 -1
- package/src/mdx/blog/ioc.mdx +1 -1
- package/src/proxy.ts +1 -1
- package/tsconfig.json +1 -1
- package/.eslintrc.json +0 -26
package/eslint.config.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import nextConfig from "eslint-config-next";
|
|
2
|
+
import unusedImports from "eslint-plugin-unused-imports";
|
|
3
|
+
|
|
4
|
+
const config = [
|
|
5
|
+
...nextConfig,
|
|
6
|
+
{
|
|
7
|
+
plugins: {
|
|
8
|
+
"unused-imports": unusedImports,
|
|
9
|
+
},
|
|
10
|
+
ignores: [
|
|
11
|
+
".source/source.config.mjs",
|
|
12
|
+
// 其他文件或模式
|
|
13
|
+
],
|
|
14
|
+
rules: {
|
|
15
|
+
// 关闭原生规则,启用 unused-imports 插件
|
|
16
|
+
"no-unused-vars": "off",
|
|
17
|
+
"@typescript-eslint/no-unused-vars": "off",
|
|
18
|
+
"unused-imports/no-unused-imports": "error",
|
|
19
|
+
"unused-imports/no-unused-vars": [
|
|
20
|
+
"error",
|
|
21
|
+
{
|
|
22
|
+
vars: "all",
|
|
23
|
+
varsIgnorePattern: "^_",
|
|
24
|
+
args: "after-used",
|
|
25
|
+
argsIgnorePattern: "^_",
|
|
26
|
+
},
|
|
27
|
+
],
|
|
28
|
+
},
|
|
29
|
+
},
|
|
30
|
+
];
|
|
31
|
+
|
|
32
|
+
export default config;
|
package/messages/en.json
CHANGED
|
@@ -1,65 +1,65 @@
|
|
|
1
1
|
{
|
|
2
2
|
"home": {
|
|
3
3
|
"title": "Diaomao",
|
|
4
|
-
"banner": "
|
|
5
|
-
"webTitle": "Diaomao AI
|
|
6
|
-
"webDescription": "
|
|
7
|
-
"keywords": "AI
|
|
4
|
+
"banner": "Ship Faster | Charge Smarter | Scale Fearlessly",
|
|
5
|
+
"webTitle": "Diaomao – The Ultimate AI SaaS Starter Kit with Stripe, Credits & Docs",
|
|
6
|
+
"webDescription": "Next.js 14 + Prisma + PostgreSQL + Stripe + Clerk + Fumadocs. Production-ready pricing tiers, credit system, anonymous-to-auth onboarding, and beautiful docs — everything you need to launch and monetize your AI product in days, not months.",
|
|
7
|
+
"keywords": "AI SaaS template, Next.js boilerplate, Stripe billing, credit-based pricing, anonymous onboarding, Fumadocs, Prisma PostgreSQL, Clerk authentication"
|
|
8
8
|
},
|
|
9
9
|
"hero": {
|
|
10
|
-
"mainTitle": "
|
|
10
|
+
"mainTitle": "Ship a paid AI product with",
|
|
11
11
|
"mainEyesOn": "Diaomao",
|
|
12
|
-
"description": "
|
|
13
|
-
"button": "Get
|
|
14
|
-
"about": "SSR-
|
|
15
|
-
"heroImageAlt": "Diaomao
|
|
12
|
+
"description": "Pricing that upgrades itself. Credits that never leak. Docs that stay in sync. Stripe flows that just work. Diaomao is the full-stack chassis trusted by makers who refuse to waste another weekend on billing infrastructure.",
|
|
13
|
+
"button": "Get Diaomao →",
|
|
14
|
+
"about": "SSR-first • Mobile-perfected • Fingerprint → Clerk seamless onboarding",
|
|
15
|
+
"heroImageAlt": "Diaomao – Modern pricing, credit dashboard and documentation system",
|
|
16
16
|
"heroImageUrl": "https://r2.d8ger.com/default.webp"
|
|
17
17
|
},
|
|
18
18
|
"usage": {
|
|
19
|
-
"title": "
|
|
20
|
-
"eyesOn": "in
|
|
21
|
-
"description": "
|
|
19
|
+
"title": "From zero to paid users",
|
|
20
|
+
"eyesOn": "in 3 stupidly simple steps",
|
|
21
|
+
"description": "Everything is pre-wired. You just turn the knobs.",
|
|
22
22
|
"steps": [
|
|
23
23
|
{
|
|
24
|
-
"title": "
|
|
25
|
-
"description": "
|
|
26
|
-
"iconKey": "
|
|
24
|
+
"title": "Connect your stack",
|
|
25
|
+
"description": "Drop in Stripe, PostgreSQL, and Clerk keys. Your pricing page and credit system instantly become user-aware on day one.",
|
|
26
|
+
"iconKey": "Zap"
|
|
27
27
|
},
|
|
28
28
|
{
|
|
29
|
-
"title": "
|
|
30
|
-
"description": "
|
|
31
|
-
"iconKey": "
|
|
29
|
+
"title": "Tune your config",
|
|
30
|
+
"description": "Switch between monthly, yearly, and one-time credit packs with a single config flag. Upgrade paths, discounts, and CTAs auto-adapt to each user.",
|
|
31
|
+
"iconKey": "Settings"
|
|
32
32
|
},
|
|
33
33
|
{
|
|
34
|
-
"title": "Launch
|
|
35
|
-
"description": "
|
|
36
|
-
"iconKey": "
|
|
34
|
+
"title": "Launch your story",
|
|
35
|
+
"description": "Beautiful docs, mega-menu navigation, and gradient-rich marketing pages — all driven by the same MDX files. Ship updates without touching CSS.",
|
|
36
|
+
"iconKey": "Rocket"
|
|
37
37
|
}
|
|
38
38
|
]
|
|
39
39
|
},
|
|
40
40
|
"faq": {
|
|
41
|
-
"title": "
|
|
42
|
-
"description": "
|
|
43
|
-
"items":[
|
|
41
|
+
"title": "Got questions?",
|
|
42
|
+
"description": "We’ve got answers.",
|
|
43
|
+
"items": [
|
|
44
44
|
{
|
|
45
|
-
"question": "What is Diaomao?",
|
|
46
|
-
"answer": "
|
|
45
|
+
"question": "What exactly is Diaomao?",
|
|
46
|
+
"answer": "The fastest way to launch a production-ready, monetized AI product. Next.js 14 + Prisma + PostgreSQL + Stripe + Clerk + beautiful docs — everything pre-built and battle-tested."
|
|
47
47
|
},
|
|
48
48
|
{
|
|
49
|
-
"question": "
|
|
50
|
-
"answer": "
|
|
49
|
+
"question": "Can I sell both subscriptions AND one-time credit packs?",
|
|
50
|
+
"answer": "Absolutely. Toggle between monthly, yearly, and one-time purchases with a single config change. Upgrade buttons automatically route to Stripe Checkout or Customer Portal."
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
|
-
"question": "
|
|
54
|
-
"answer": "
|
|
53
|
+
"question": "What happens to anonymous users?",
|
|
54
|
+
"answer": "They get a fingerprint ID and starter credits instantly. When they eventually sign in, their balance and history merge seamlessly — zero data loss, zero flicker."
|
|
55
55
|
},
|
|
56
56
|
{
|
|
57
|
-
"question": "
|
|
58
|
-
"answer": "
|
|
57
|
+
"question": "How hard is it to customize navigation & docs?",
|
|
58
|
+
"answer": "Dead easy. Mega-menu, mobile pinning, and docs are all driven by simple JSON/MDX config. Change once, updates everywhere."
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
|
-
"question": "
|
|
62
|
-
"answer": "Checkout
|
|
61
|
+
"question": "Is the entire Stripe lifecycle handled?",
|
|
62
|
+
"answer": "Yes. Checkout, Portal, webhooks, renewals, dunning, refunds, upgrades/downgrades — all idempotent and logged. You’ll never lose a payment event again."
|
|
63
63
|
}
|
|
64
64
|
]
|
|
65
65
|
},
|
|
@@ -226,29 +226,29 @@
|
|
|
226
226
|
}
|
|
227
227
|
},
|
|
228
228
|
"features": {
|
|
229
|
-
"title": "
|
|
230
|
-
"eyesOn": "Diaomao",
|
|
231
|
-
"description": "
|
|
229
|
+
"title": "Everything you keep rebuilding",
|
|
230
|
+
"eyesOn": "Diaomao already solved",
|
|
231
|
+
"description": "Stop gluing together half-baked solutions. This is the template that ends the weekend billing nightmares.",
|
|
232
232
|
"items": [
|
|
233
233
|
{
|
|
234
234
|
"title": "Money Price 2.0",
|
|
235
|
-
"description": "Monthly/
|
|
235
|
+
"description": "Monthly / Yearly / One-time toggle that instantly reflects the user’s current plan. Discount badges, upgrade guards, and SSR defaults — all automatic.",
|
|
236
236
|
"iconKey": "Sparkles"
|
|
237
237
|
},
|
|
238
238
|
{
|
|
239
|
-
"title": "Credit
|
|
240
|
-
"description": "Buckets,
|
|
239
|
+
"title": "Credit System",
|
|
240
|
+
"description": "Buckets, expiration tags, and smart CTAs. Desktop = modals. Mobile = redirects. Zero confusion, maximum upsells.",
|
|
241
241
|
"iconKey": "Gift"
|
|
242
242
|
},
|
|
243
243
|
{
|
|
244
|
-
"title": "
|
|
245
|
-
"description": "
|
|
246
|
-
"iconKey": "
|
|
244
|
+
"title": "Auth and Anonymous",
|
|
245
|
+
"description": "Fingerprint on first visit → starter credits → seamless merge on sign-in. No flicker, no balance loss, no support tickets.",
|
|
246
|
+
"iconKey": "Fingerprint"
|
|
247
247
|
},
|
|
248
248
|
{
|
|
249
|
-
"title": "Docs &
|
|
250
|
-
"description": "Fumadocs +
|
|
251
|
-
"iconKey": "
|
|
249
|
+
"title": "Docs & Navigation",
|
|
250
|
+
"description": "Fumadocs + mega-menu header. One source of truth for marketing and documentation. Mobile pinning, dark mode, and accessibility included.",
|
|
251
|
+
"iconKey": "BookOpen"
|
|
252
252
|
}
|
|
253
253
|
]
|
|
254
254
|
},
|
|
@@ -297,7 +297,7 @@
|
|
|
297
297
|
"sections": [
|
|
298
298
|
{
|
|
299
299
|
"title": "Configure before coding",
|
|
300
|
-
"description": "Pricing, credits, navigation, and CTAs are config
|
|
300
|
+
"description": "Pricing, credits, navigation, and CTAs are config-driven—tune parameters before touching code."
|
|
301
301
|
},
|
|
302
302
|
{
|
|
303
303
|
"title": "Keep billing options",
|
|
@@ -305,7 +305,7 @@
|
|
|
305
305
|
},
|
|
306
306
|
{
|
|
307
307
|
"title": "Honor device behaviors",
|
|
308
|
-
"description": "Mobile uses redirects/auth then closes; desktop can modal—follow the design guide
|
|
308
|
+
"description": "Mobile uses redirects/auth then closes; desktop can modal—follow the design guide."
|
|
309
309
|
},
|
|
310
310
|
{
|
|
311
311
|
"title": "Prefer SSR context",
|
|
@@ -355,11 +355,11 @@
|
|
|
355
355
|
"conclusion": "Plug in keys, tune config, fill copy—launch an AI-ready, revenue-ready, story-ready site in a week."
|
|
356
356
|
},
|
|
357
357
|
"cta": {
|
|
358
|
-
"title": "
|
|
358
|
+
"title": "Start shipping your AI idea with",
|
|
359
359
|
"eyesOn": "Diaomao",
|
|
360
|
-
"description1": "One template
|
|
361
|
-
"description2": "
|
|
362
|
-
"button": "Get
|
|
360
|
+
"description1": "One template. Every hard part solved.",
|
|
361
|
+
"description2": "Stripe, credits, auth— all production-ready out of the box.",
|
|
362
|
+
"button": "Get Diaomao Now →",
|
|
363
363
|
"url": "https://preview.reve.art/"
|
|
364
364
|
},
|
|
365
365
|
"languageDetection": {
|
|
@@ -381,7 +381,9 @@
|
|
|
381
381
|
},
|
|
382
382
|
"clerk": {
|
|
383
383
|
"signIn": "Sign In",
|
|
384
|
-
"signUp": "Sign Up"
|
|
384
|
+
"signUp": "Sign Up",
|
|
385
|
+
"signUpBonus": "+2",
|
|
386
|
+
"signUpBonusTooltip": "Sign up and get 2 free credits!"
|
|
385
387
|
},
|
|
386
388
|
"linkPreview": {
|
|
387
389
|
"blog": "Blog",
|
package/messages/zh.json
CHANGED
package/package.json
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@windrun-huaiin/diaomao",
|
|
3
|
-
"version": "11.1.
|
|
3
|
+
"version": "11.1.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
8
|
+
"type": "module",
|
|
8
9
|
"keywords": [
|
|
9
10
|
"fumadocs",
|
|
10
11
|
"clerk",
|
|
@@ -26,10 +27,10 @@
|
|
|
26
27
|
"@radix-ui/react-slot": "^1.2.4",
|
|
27
28
|
"@tailwindcss/typography": "^0.5.19",
|
|
28
29
|
"@types/mdx": "^2.0.13",
|
|
29
|
-
"@windrun-huaiin/
|
|
30
|
-
"@windrun-huaiin/
|
|
31
|
-
"@windrun-huaiin/
|
|
32
|
-
"@windrun-huaiin/
|
|
30
|
+
"@windrun-huaiin/backend-core": "^11.0.3",
|
|
31
|
+
"@windrun-huaiin/base-ui": "^11.0.1",
|
|
32
|
+
"@windrun-huaiin/lib": "^11.0.1",
|
|
33
|
+
"@windrun-huaiin/third-ui": "^11.0.2",
|
|
33
34
|
"autoprefixer": "^10.4.22",
|
|
34
35
|
"class-variance-authority": "^0.7.1",
|
|
35
36
|
"clsx": "^2.1.1",
|
|
@@ -42,7 +43,7 @@
|
|
|
42
43
|
"katex": "^0.16.25",
|
|
43
44
|
"lucide-react": "^0.525.0",
|
|
44
45
|
"mermaid": "^11.12.1",
|
|
45
|
-
"next": "16.0.
|
|
46
|
+
"next": "16.0.10",
|
|
46
47
|
"next-intl": "^4.4.0",
|
|
47
48
|
"next-themes": "^0.4.6",
|
|
48
49
|
"react": "19.2.0",
|
|
@@ -55,7 +56,7 @@
|
|
|
55
56
|
"remark-math": "^6.0.0",
|
|
56
57
|
"remark-mdx": "^3.1.1",
|
|
57
58
|
"shiki": "^3.15.0",
|
|
58
|
-
"stripe": "
|
|
59
|
+
"stripe": "20.0.0",
|
|
59
60
|
"svix": "^1.81.0",
|
|
60
61
|
"swiper": "^12.0.3",
|
|
61
62
|
"tailwind-merge": "^3.4.0",
|
|
@@ -76,7 +77,7 @@
|
|
|
76
77
|
"@types/react-medium-image-zoom": "^3.0.3",
|
|
77
78
|
"@types/uuid": "^10.0.0",
|
|
78
79
|
"@typescript-eslint/parser": "^8.46.4",
|
|
79
|
-
"@windrun-huaiin/dev-scripts": "^11.0.
|
|
80
|
+
"@windrun-huaiin/dev-scripts": "^11.0.3",
|
|
80
81
|
"eslint": "^9.39.1",
|
|
81
82
|
"eslint-config-next": "^16.0.0",
|
|
82
83
|
"eslint-plugin-unused-imports": "^4.3.0",
|
|
@@ -99,7 +100,7 @@
|
|
|
99
100
|
".gitignore",
|
|
100
101
|
"messages",
|
|
101
102
|
".env.local.txt",
|
|
102
|
-
".
|
|
103
|
+
"eslint.config.js",
|
|
103
104
|
"components.json",
|
|
104
105
|
"dev-scripts.config.json",
|
|
105
106
|
"LICENSE",
|
|
@@ -120,7 +121,8 @@
|
|
|
120
121
|
"build:dev": "pnpm generate-blog-index && prisma generate && next build",
|
|
121
122
|
"build:prod": "prisma generate && next build",
|
|
122
123
|
"start": "next start",
|
|
123
|
-
"lint": "
|
|
124
|
+
"lint": "eslint . --ext .js,.jsx,.ts,.tsx",
|
|
125
|
+
"lint:fix": "eslint . --ext .js,.jsx,.ts,.tsx --fix",
|
|
124
126
|
"deep-clean": "dev-scripts deep-clean",
|
|
125
127
|
"d8": "pnpm run deep-clean",
|
|
126
128
|
"easy-changeset": "dev-scripts easy-changeset",
|
package/src/components/hero.tsx
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import Image from "next/image"
|
|
1
|
+
import Image from "next/image"
|
|
3
2
|
import { getTranslations } from 'next-intl/server'
|
|
4
3
|
import { globalLucideIcons as icons} from '@windrun-huaiin/base-ui/components/server'
|
|
5
4
|
import { GradientButton } from "@windrun-huaiin/third-ui/fuma/mdx"
|
|
@@ -119,7 +119,7 @@ export function getMDXComponents(
|
|
|
119
119
|
);
|
|
120
120
|
},
|
|
121
121
|
// global image zoom
|
|
122
|
-
|
|
122
|
+
|
|
123
123
|
img: (props) => <ImageZoom {...(props as any)} />,
|
|
124
124
|
// global Mermaid component
|
|
125
125
|
Mermaid: (props) => (
|
package/src/mdx/blog/index.mdx
CHANGED
package/src/mdx/blog/ioc.mdx
CHANGED
package/src/proxy.ts
CHANGED
package/tsconfig.json
CHANGED
package/.eslintrc.json
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": [
|
|
3
|
-
"next/core-web-vitals",
|
|
4
|
-
"eslint:recommended",
|
|
5
|
-
"plugin:@typescript-eslint/recommended"
|
|
6
|
-
],
|
|
7
|
-
"parser": "@typescript-eslint/parser",
|
|
8
|
-
"plugins": [
|
|
9
|
-
"@typescript-eslint",
|
|
10
|
-
"unused-imports"
|
|
11
|
-
],
|
|
12
|
-
"rules": {
|
|
13
|
-
"no-unused-vars": "off",
|
|
14
|
-
"@typescript-eslint/no-unused-vars": "off",
|
|
15
|
-
"unused-imports/no-unused-imports": "error",
|
|
16
|
-
"unused-imports/no-unused-vars": [
|
|
17
|
-
"error",
|
|
18
|
-
{
|
|
19
|
-
"vars": "all",
|
|
20
|
-
"varsIgnorePattern": "^_",
|
|
21
|
-
"args": "after-used",
|
|
22
|
-
"argsIgnorePattern": "^_"
|
|
23
|
-
}
|
|
24
|
-
]
|
|
25
|
-
}
|
|
26
|
-
}
|