@windrun-huaiin/diaomao 10.0.1 → 11.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.
- package/.env.local.txt +97 -28
- package/.gitignore +1 -0
- package/dev-scripts.config.json +4 -2
- package/messages/en.json +102 -97
- package/messages/zh.json +391 -0
- package/package.json +16 -10
- package/public/asserts/Montserrat-Regular.otf +0 -0
- package/src/app/[locale]/(clerk)/layout.tsx +1 -1
- package/src/app/[locale]/(home)/layout.tsx +1 -1
- package/src/app/[locale]/(home)/page.tsx +17 -4
- package/src/app/[locale]/(home)/pricing/page.tsx +2 -2
- package/src/app/[locale]/layout.tsx +0 -1
- package/src/app/api/stripe/checkout/route.ts +3 -145
- package/src/app/api/stripe/customer-portal/route.ts +3 -83
- package/src/app/api/user/anonymous/init/route.ts +3 -175
- package/src/app/api/webhook/clerk/user/route.ts +3 -249
- package/src/app/api/webhook/stripe/route.ts +3 -92
- package/src/components/credit-popover.tsx +3 -3
- package/src/lib/appConfig.ts +1 -1
- package/src/lib/fonts.ts +8 -6
- package/src/mdx/blog/index.mdx +1 -4
- package/src/mdx/blog/ioc.mdx +2 -3
- package/tsconfig.json +0 -9
- package/next-env.d.ts +0 -6
- package/src/lib/auth-utils.ts +0 -101
- package/src/lib/fingerprint-config.ts +0 -6
- package/src/lib/money-price-config.ts +0 -263
- package/src/lib/money-price-helper.ts +0 -61
- package/src/lib/price-config.ts +0 -14
- package/src/lib/stripe-config.ts +0 -333
- package/src/mdx/blog/paid-system-design.mdx +0 -2547
- package/src/services/aggregate/billing.aggregate.service.ts +0 -498
- package/src/services/aggregate/index.ts +0 -2
- package/src/services/aggregate/user.aggregate.service.ts +0 -164
- package/src/services/context/index.ts +0 -1
- package/src/services/context/user-context-service.ts +0 -200
- package/src/services/database/apilog.service.ts +0 -185
- package/src/services/database/constants.ts +0 -148
- package/src/services/database/credit.service.ts +0 -747
- package/src/services/database/creditAuditLog.service.ts +0 -402
- package/src/services/database/index.ts +0 -41
- package/src/services/database/prisma-model-type.ts +0 -13
- package/src/services/database/prisma-transaction-util.ts +0 -24
- package/src/services/database/prisma.ts +0 -122
- package/src/services/database/subscription.service.ts +0 -319
- package/src/services/database/transaction.service.ts +0 -447
- package/src/services/database/user.service.ts +0 -216
- package/src/services/database/userBackup.service.ts +0 -290
- package/src/services/stripe/webhook-handler.ts +0 -648
package/.env.local.txt
CHANGED
|
@@ -1,49 +1,118 @@
|
|
|
1
|
-
#
|
|
1
|
+
# domain and github link
|
|
2
2
|
NEXT_PUBLIC_BASE_URL=http://localhost:3000
|
|
3
|
-
# 测试(线上需要删除)
|
|
4
|
-
EXAMPLE_TEST_X=sk-dev-7C021EA0-386B-4908-BFDD-3ACC55B2BD6F
|
|
5
3
|
|
|
6
|
-
# Github在菜单上的筛选按钮链接配置(可选)
|
|
7
4
|
NEXT_PUBLIC_GITHUB=https://github.com/caofanCPU/diaomao/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
# R2上的图片下载代理服务器配置(可选, 如果需要下载图片则必须配置, 否则会出现跨域报错)
|
|
11
|
-
NEXT_PUBLIC_STYLE_CDN_PROXY_URL=https://r2-explorer-template.zcy777et.workers.dev/proxy
|
|
5
|
+
NEXT_PUBLIC_GITHUB_BASE_URL=https://github.com/caofanCPU/diaomao/main
|
|
6
|
+
NEXT_PUBLIC_STYLE_CDN_PROXY_URL=YOURS-
|
|
12
7
|
|
|
13
|
-
|
|
8
|
+
## 直连模式supabase只支持ipv6;事务模式又不支持Prisma的预处理语句;所以必须降级为会话模式
|
|
9
|
+
## Project View -> Connect -> 查看连接方式以及限制
|
|
10
|
+
# DATABASE_URL="postgresql://用户名.项目ID:[YOUR-PASSWORD]@服务厂商域名.pooler.supabase.com:5432/postgres?sslmode=require&schema=diaomao"
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# DB Config, replace YOUR port、db name、schema
|
|
14
|
+
DATABASE_URL="postgresql://postgres:PASSWORD@localhost:5432/postgres?schema=diaomao"
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# Website uniform style
|
|
14
18
|
NEXT_PUBLIC_STYLE_ICON_COLOR=text-purple-500
|
|
15
|
-
|
|
16
|
-
NEXT_PUBLIC_STYLE_SVG_ICON_COLOR="#AC62FD"
|
|
17
|
-
# 网站svg图标大小适配(可选)
|
|
19
|
+
NEXT_PUBLIC_STYLE_SVG_ICON_COLOR=#AC62FD
|
|
18
20
|
NEXT_PUBLIC_STYLE_SVG_ICON_SIZE=18
|
|
19
21
|
|
|
20
|
-
# 网站Banner展示开关, 默认展示
|
|
21
22
|
NEXT_PUBLIC_STYLE_SHOW_BANNER=true
|
|
22
|
-
# 网站Clerk页面Banner展示开关(可选), 默认不展示
|
|
23
23
|
NEXT_PUBLIC_STYLE_CLERK_PAGE_BANNER=false
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
# MDX页面中mermaid图是否开启图片水印(可选), 默认开启
|
|
24
|
+
NEXT_PUBLIC_STYLE_CLERK_AUTH_IN_MODAL=true
|
|
25
|
+
|
|
27
26
|
NEXT_PUBLIC_STYLE_WATERMARK_ENABLED=true
|
|
28
|
-
|
|
29
|
-
NEXT_PUBLIC_STYLE_WATERMARK_TEXT=Windrun·Huaiin
|
|
27
|
+
NEXT_PUBLIC_STYLE_WATERMARK_TEXT=YOURS-
|
|
30
28
|
|
|
31
|
-
# GoogleID
|
|
29
|
+
# GoogleID TODO
|
|
32
30
|
NEXT_PUBLIC_GOOGLE_ANALYTICS_ID=
|
|
33
|
-
# MicrosoftID
|
|
31
|
+
# MicrosoftID TODO
|
|
34
32
|
NEXT_PUBLIC_MICROSOFT_CLARITY_ID=
|
|
35
33
|
|
|
36
34
|
# Only-Use-In-Server, !!DO NOT USE IN CLIENT!!
|
|
37
|
-
# Clerk组件的日志调试开关(可选)
|
|
38
35
|
CLERK_DEBUG=false
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
CLERK_SECRET_KEY=
|
|
36
|
+
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=YOURS-
|
|
37
|
+
CLERK_SECRET_KEY=YOURS-
|
|
38
|
+
CLERK_WEBHOOK_SECRET=YOURS-
|
|
43
39
|
|
|
44
|
-
#
|
|
40
|
+
# sign-in url
|
|
45
41
|
NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in
|
|
46
42
|
NEXT_PUBLIC_CLERK_SIGN_IN_FALLBACK_REDIRECT_URL=/
|
|
43
|
+
# sign-up url
|
|
47
44
|
NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up
|
|
48
45
|
NEXT_PUBLIC_CLERK_SIGN_UP_FALLBACK_REDIRECT_URL=/
|
|
49
|
-
|
|
46
|
+
|
|
47
|
+
# waitlist-url
|
|
48
|
+
NEXT_PUBLIC_CLERK_WAITLIST_URL=/waitlist
|
|
49
|
+
|
|
50
|
+
# Enable Subscription Upgrade button
|
|
51
|
+
ENABLE_STRIPE_SUBSCRIPTION_UPGRADE = true
|
|
52
|
+
# Show Debug Status
|
|
53
|
+
SHOW_FINGERPRINT_STATUS = true
|
|
54
|
+
|
|
55
|
+
# Stripe Configuration
|
|
56
|
+
STRIPE_PUBLISHABLE_KEY=YOURS-
|
|
57
|
+
STRIPE_SECRET_KEY=YOURS-
|
|
58
|
+
STRIPE_WEBHOOK_SECRET=YOURS-
|
|
59
|
+
STRIPE_PRO_PRODUCT_ID=YOURS-
|
|
60
|
+
STRIPE_ULTRA_PRODUCT_ID=YOURS-
|
|
61
|
+
STRIPE_ONE_TIME_PRODUCT_ID=YOURS-
|
|
62
|
+
|
|
63
|
+
MONEY_PRICE_MOCK_USER_ENABLED=false
|
|
64
|
+
# 0-FreeUser | 1-MonthPro | 2-MonthUltra | 3-YearPro | 4-YearUltra
|
|
65
|
+
MONEY_PRICE_MOCK_USER_TYPE=4
|
|
66
|
+
# 激活的支付供应商
|
|
67
|
+
ACTIVE_PAYMENT_PROVIDER=stripe
|
|
68
|
+
|
|
69
|
+
# 积分初始化配置
|
|
70
|
+
CREDITS_INIT_FREE_AMOUNT=1
|
|
71
|
+
CREDITS_INIT_FREE_REGISTER_AMOUNT=2
|
|
72
|
+
CREDITS_INIT_FREE_EXPIRED_DAYS=7
|
|
73
|
+
CREDITS_ONE_TIME_EXPIRED_DAYS=30
|
|
74
|
+
|
|
75
|
+
# Stripe Pro 月付配置
|
|
76
|
+
STRIPE_PRO_MONTHLY_PRICE_ID=YOURS-
|
|
77
|
+
STRIPE_PRO_MONTHLY_AMOUNT=10
|
|
78
|
+
STRIPE_PRO_MONTHLY_CURRENCY=usd
|
|
79
|
+
STRIPE_PRO_MONTHLY_CREDITS=100
|
|
80
|
+
|
|
81
|
+
# Stripe Ultra 月付配置
|
|
82
|
+
STRIPE_ULTRA_MONTHLY_PRICE_ID=YOURS-
|
|
83
|
+
STRIPE_ULTRA_MONTHLY_AMOUNT=50
|
|
84
|
+
STRIPE_ULTRA_MONTHLY_CURRENCY=usd
|
|
85
|
+
STRIPE_ULTRA_MONTHLY_CREDITS=800
|
|
86
|
+
|
|
87
|
+
# Stripe Pro 年付配置
|
|
88
|
+
STRIPE_PRO_YEARLY_PRICE_ID=YOURS-
|
|
89
|
+
STRIPE_PRO_YEARLY_AMOUNT=8
|
|
90
|
+
STRIPE_PRO_YEARLY_CURRENCY=usd
|
|
91
|
+
STRIPE_PRO_YEARLY_CREDITS=1200
|
|
92
|
+
STRIPE_PRO_DISCOUNT_PERCENT=20
|
|
93
|
+
|
|
94
|
+
# Stripe Ultra 年付配置
|
|
95
|
+
STRIPE_ULTRA_YEARLY_PRICE_ID=YOURS-
|
|
96
|
+
STRIPE_ULTRA_YEARLY_AMOUNT=40
|
|
97
|
+
STRIPE_ULTRA_YEARLY_CURRENCY=usd
|
|
98
|
+
STRIPE_ULTRA_YEARLY_CREDITS=9600
|
|
99
|
+
STRIPE_ULTRA_DISCOUNT_PERCENT=20
|
|
100
|
+
|
|
101
|
+
# Stripe One-Time 即付配置-少
|
|
102
|
+
STRIPE_ONE_TIME_LESS_PRICE_ID=YOURS-
|
|
103
|
+
STRIPE_ONE_TIME_LESS_AMOUNT=5
|
|
104
|
+
STRIPE_ONE_TIME_LESS_CURRENCY=usd
|
|
105
|
+
STRIPE_ONE_TIME_LESS_CREDITS=5
|
|
106
|
+
|
|
107
|
+
# Stripe One-Time 即付配置-中(默认)
|
|
108
|
+
STRIPE_ONE_TIME_MID_PRICE_ID=YOURS-
|
|
109
|
+
STRIPE_ONE_TIME_MID_AMOUNT=10
|
|
110
|
+
STRIPE_ONE_TIME_MID_CURRENCY=usd
|
|
111
|
+
STRIPE_ONE_TIME_MID_CREDITS=10
|
|
112
|
+
|
|
113
|
+
# Stripe One-Time 即付配置-多
|
|
114
|
+
STRIPE_ONE_TIME_MORE_PRICE_ID=YOURS-
|
|
115
|
+
STRIPE_ONE_TIME_MORE_AMOUNT=20
|
|
116
|
+
STRIPE_ONE_TIME_MORE_CURRENCY=usd
|
|
117
|
+
STRIPE_ONE_TIME_MORE_CREDITS=20
|
|
118
|
+
|
package/.gitignore
CHANGED
package/dev-scripts.config.json
CHANGED
|
@@ -21,7 +21,9 @@
|
|
|
21
21
|
},
|
|
22
22
|
"architectureConfig": {
|
|
23
23
|
".": "Diaomao Project",
|
|
24
|
-
"fumadocs-ui@15.3.3.patch": "fumadocs
|
|
25
|
-
".
|
|
24
|
+
"fumadocs-ui@15.3.3.patch": "fumadocs-ui版本15.3.3补丁",
|
|
25
|
+
"fumadocs-ui@16.0.9.patch": "fumadocs-ui版本16.0.9补丁",
|
|
26
|
+
"fumadocs-core@16.0.9.patch": "fumadocs-core版本16.0.9补丁",
|
|
27
|
+
".env.local.txt": "config example"
|
|
26
28
|
}
|
|
27
29
|
}
|
package/messages/en.json
CHANGED
|
@@ -2,84 +2,64 @@
|
|
|
2
2
|
"home": {
|
|
3
3
|
"title": "Diaomao",
|
|
4
4
|
"banner": "Rethink | Redefine | Rebuild",
|
|
5
|
-
"webTitle": "Diaomao
|
|
6
|
-
"webDescription": "
|
|
7
|
-
"keywords": "AI
|
|
5
|
+
"webTitle": "Diaomao AI-Orchestrated SaaS | Pricing, Credits, Docs & Stripe",
|
|
6
|
+
"webDescription": "Ship an AI-era product site fast: Diaomao packs Next.js + Prisma + PostgreSQL + Stripe with orchestrated pricing, credit gates, docs, and navigation—ready for real payments and growth.",
|
|
7
|
+
"keywords": "AI product template, Next.js SaaS, Stripe pricing, credit billing UI, Fumadocs, Prisma PostgreSQL, fingerprint onboarding, Money Price, Credit Overview"
|
|
8
8
|
},
|
|
9
9
|
"hero": {
|
|
10
|
-
"mainTitle": "
|
|
10
|
+
"mainTitle": "Build an AI-ready product with",
|
|
11
11
|
"mainEyesOn": "Diaomao",
|
|
12
|
-
"description": "
|
|
12
|
+
"description": "An orchestrated template for the AI age: pricing that knows your users, credit engines that guide upgrades, docs and navigation that stay in sync, and Stripe flows that simply work.",
|
|
13
13
|
"button": "Get Started",
|
|
14
|
-
"about": "
|
|
15
|
-
"heroImageAlt": "Diaomao AI
|
|
14
|
+
"about": "SSR-stable, mobile-respectful, with fingerprint-to-Clerk onboarding baked in",
|
|
15
|
+
"heroImageAlt": "Diaomao AI product template showing pricing, credits, docs navigation, and gradients",
|
|
16
16
|
"heroImageUrl": "https://r2.d8ger.com/default.webp"
|
|
17
17
|
},
|
|
18
18
|
"usage": {
|
|
19
|
-
"title": "
|
|
20
|
-
"eyesOn": "
|
|
21
|
-
"description": "",
|
|
19
|
+
"title": "Make it yours",
|
|
20
|
+
"eyesOn": "in three moves",
|
|
21
|
+
"description": "An AI + product-orchestrated base—configure, ship, and sell.",
|
|
22
22
|
"steps": [
|
|
23
23
|
{
|
|
24
|
-
"title": "
|
|
25
|
-
"description": "
|
|
24
|
+
"title": "Wire the stack",
|
|
25
|
+
"description": "Add Stripe secrets, PostgreSQL, and Clerk—InitUserContext + Prisma schema hydrate SSR pricing and credits on day one.",
|
|
26
26
|
"iconKey": "MousePointerClick"
|
|
27
27
|
},
|
|
28
28
|
{
|
|
29
|
-
"title": "
|
|
30
|
-
"description": "
|
|
29
|
+
"title": "Orchestrate the product",
|
|
30
|
+
"description": "Tune billing toggles, credit buckets, and CTA behaviors in config; Money Price and Credit Overview adapt to user state and device.",
|
|
31
31
|
"iconKey": "Pencil"
|
|
32
32
|
},
|
|
33
33
|
{
|
|
34
|
-
"title": "
|
|
35
|
-
"description": "
|
|
34
|
+
"title": "Launch the story",
|
|
35
|
+
"description": "Fumadocs + Header Mega Menu keep navigation and docs in sync; gradients and accessibility are pre-tuned across devices.",
|
|
36
36
|
"iconKey": "Download"
|
|
37
37
|
}
|
|
38
38
|
]
|
|
39
39
|
},
|
|
40
40
|
"faq": {
|
|
41
41
|
"title": "Frequently Asked Questions",
|
|
42
|
-
"description": "",
|
|
42
|
+
"description": "Core flows are prebuilt—these answers clarify what ships out of the box.",
|
|
43
43
|
"items":[
|
|
44
44
|
{
|
|
45
|
-
"question": "What is
|
|
46
|
-
"answer": "
|
|
45
|
+
"question": "What is Diaomao?",
|
|
46
|
+
"answer": "An AI-era product template: Next.js + Prisma + PostgreSQL + Stripe, with Money Price, Credit Overview, fingerprint-to-Clerk onboarding, and Fumadocs navigation/docs."
|
|
47
47
|
},
|
|
48
48
|
{
|
|
49
|
-
"question": "
|
|
50
|
-
"answer": "Yes
|
|
49
|
+
"question": "Does it support both subscriptions and one-time credit packs?",
|
|
50
|
+
"answer": "Yes. Money Price covers subscriptions and one-time credit packs; billing toggles are configurable, and upgrade buttons fall back to Portal/Checkout."
|
|
51
51
|
},
|
|
52
52
|
{
|
|
53
|
-
"question": "How
|
|
54
|
-
"answer": "
|
|
53
|
+
"question": "How are anonymous users handled?",
|
|
54
|
+
"answer": "First visit issues a fingerprint ID, starter credits, and records; after login the same context persists, balances stay intact, and SSR avoids first-screen flicker."
|
|
55
55
|
},
|
|
56
56
|
{
|
|
57
|
-
"question": "
|
|
58
|
-
"answer": "
|
|
57
|
+
"question": "Can I change the navigation and docs layout?",
|
|
58
|
+
"answer": "Yes. Header supports mega menus, pinned mobile actions, and secondary buttons; Fumadocs is config-driven for cards, banners, and per-device ordering."
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
|
-
"question": "
|
|
62
|
-
"answer": "
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
"question": "What file formats can I download my newspaper in?",
|
|
66
|
-
"answer": "You can download your newspaper as a high-quality PDF, PNG, JPG, WEBP, or SVG, suitable for printing or digital sharing."
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
"question": "Can I save my work and come back to it later?",
|
|
70
|
-
"answer": "Currently, you can complete your newspaper in one session. Future updates may include a save feature."
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
"question": "Are there limits to how many newspapers I can create?",
|
|
74
|
-
"answer": "No limits! You can create as many newspapers as you like, all for free."
|
|
75
|
-
},
|
|
76
|
-
{
|
|
77
|
-
"question": "Can I use my own fonts or colors?",
|
|
78
|
-
"answer": "You can use pre-set fonts and color schemes in our free online newspaper templates for a professional look. Custom font uploads may be available in future updates."
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
"question": "How can I share my finished newspaper?",
|
|
82
|
-
"answer": "After completing your newspaper, you can download it as a PDF, PNG, JPG, WEBP, or SVG and share it via email, social media, or print it for physical distribution."
|
|
61
|
+
"question": "What Stripe lifecycle is covered?",
|
|
62
|
+
"answer": "Checkout/Portal, async confirms, renewals, dunning, refunds, end-of-period cancel, and upgrade/downgrade all map to Transactions/Subscriptions with event.id + order_id idempotency."
|
|
83
63
|
}
|
|
84
64
|
]
|
|
85
65
|
},
|
|
@@ -137,7 +117,7 @@
|
|
|
137
117
|
},
|
|
138
118
|
{ "description": "Priority support" },
|
|
139
119
|
{
|
|
140
|
-
"description": "
|
|
120
|
+
"description": "50 credits/month",
|
|
141
121
|
"tooltip": "1 credit = 1 AI generation"
|
|
142
122
|
},
|
|
143
123
|
{ "description": "Advanced analytics" }
|
|
@@ -154,7 +134,7 @@
|
|
|
154
134
|
"tag": "Pro"
|
|
155
135
|
},
|
|
156
136
|
{
|
|
157
|
-
"description": "
|
|
137
|
+
"description": "200 credits/month",
|
|
158
138
|
"tooltip": "1 credit = 1 AI generation"
|
|
159
139
|
},
|
|
160
140
|
{ "description": "Early access to new features" },
|
|
@@ -172,10 +152,10 @@
|
|
|
172
152
|
{
|
|
173
153
|
"key": "F1",
|
|
174
154
|
"title": "Starter",
|
|
175
|
-
"subtitle": "
|
|
155
|
+
"subtitle": "25 Credits",
|
|
176
156
|
"showBillingSubTitle": true,
|
|
177
157
|
"features": [
|
|
178
|
-
{ "description": "
|
|
158
|
+
{ "description": "525AI generations" },
|
|
179
159
|
{ "description": "Perfect for trying out" },
|
|
180
160
|
{ "description": "No expiration" },
|
|
181
161
|
{ "description": "Instant activation" }
|
|
@@ -184,11 +164,11 @@
|
|
|
184
164
|
{
|
|
185
165
|
"key": "P2",
|
|
186
166
|
"title": "Popular",
|
|
187
|
-
"subtitle": "
|
|
167
|
+
"subtitle": "150 Credits",
|
|
188
168
|
"showBillingSubTitle": true,
|
|
189
169
|
"titleTags": ["Preferred"],
|
|
190
170
|
"features": [
|
|
191
|
-
{ "description": "
|
|
171
|
+
{ "description": "150 AI generations" },
|
|
192
172
|
{ "description": "Great for regular use" },
|
|
193
173
|
{ "description": "No expiration" },
|
|
194
174
|
{ "description": "Instant activation" },
|
|
@@ -198,10 +178,10 @@
|
|
|
198
178
|
{
|
|
199
179
|
"key": "U3",
|
|
200
180
|
"title": "Power",
|
|
201
|
-
"subtitle": "
|
|
181
|
+
"subtitle": "350 Credits",
|
|
202
182
|
"showBillingSubTitle": true,
|
|
203
183
|
"features": [
|
|
204
|
-
{ "description": "
|
|
184
|
+
{ "description": "350 AI generations" },
|
|
205
185
|
{ "description": "Perfect for heavy users" },
|
|
206
186
|
{ "description": "No expiration" },
|
|
207
187
|
{ "description": "Instant activation" }
|
|
@@ -248,21 +228,26 @@
|
|
|
248
228
|
"features": {
|
|
249
229
|
"title": "Why Choose",
|
|
250
230
|
"eyesOn": "Diaomao",
|
|
251
|
-
"description": "
|
|
231
|
+
"description": "An AI + product-orchestrated chassis: launch fast, charge with confidence.",
|
|
252
232
|
"items": [
|
|
253
233
|
{
|
|
254
|
-
"title": "
|
|
255
|
-
"description": "
|
|
234
|
+
"title": "Money Price 2.0",
|
|
235
|
+
"description": "Monthly/yearly/onetime switching keyed to user state, with discount badges, upgrade guards, and SSR defaults aligned.",
|
|
256
236
|
"iconKey": "Sparkles"
|
|
257
237
|
},
|
|
258
238
|
{
|
|
259
|
-
"title": "
|
|
260
|
-
"description": "
|
|
239
|
+
"title": "Credit Overview UX",
|
|
240
|
+
"description": "Buckets, expiry hints, and a CTA matrix; desktop modals and mobile redirects each follow best practices.",
|
|
261
241
|
"iconKey": "Gift"
|
|
262
242
|
},
|
|
263
243
|
{
|
|
264
|
-
"title": "
|
|
265
|
-
"description": "
|
|
244
|
+
"title": "Fingerprint to Clerk",
|
|
245
|
+
"description": "Anonymous visitors get IDs and starter credits; login upgrades seamlessly with no balance loss, no flicker.",
|
|
246
|
+
"iconKey": "MessageCircleMore"
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
"title": "Docs & Nav System",
|
|
250
|
+
"description": "Fumadocs + Header Mega Menu keep marketing and docs aligned; mobile can pin critical actions.",
|
|
266
251
|
"iconKey": "MessageCircleMore"
|
|
267
252
|
}
|
|
268
253
|
]
|
|
@@ -271,9 +256,9 @@
|
|
|
271
256
|
"titleL": "Gallery of",
|
|
272
257
|
"eyesOn": "Diaomao",
|
|
273
258
|
"titleR": "Creations",
|
|
274
|
-
"description": "
|
|
259
|
+
"description": "Swipe through the built-in UI language: gradient CTAs, pill billing toggles, credit buckets, and docs hero visuals.",
|
|
275
260
|
"button": {
|
|
276
|
-
"title": "
|
|
261
|
+
"title": "Preview the template",
|
|
277
262
|
"href": "https://preview.reve.art/",
|
|
278
263
|
"align": "center"
|
|
279
264
|
},
|
|
@@ -282,7 +267,27 @@
|
|
|
282
267
|
"prompts": [
|
|
283
268
|
{
|
|
284
269
|
"url": "https://r2.d8ger.com/Reve-Image/1.webp",
|
|
285
|
-
"altMsg": "
|
|
270
|
+
"altMsg": "Pricing grid with Money Price gradients and discount badges"
|
|
271
|
+
},
|
|
272
|
+
{
|
|
273
|
+
"url": "https://r2.d8ger.com/Reve-Image/2.webp",
|
|
274
|
+
"altMsg": "Credit Overview dropdown showing buckets and CTA buttons"
|
|
275
|
+
},
|
|
276
|
+
{
|
|
277
|
+
"url": "https://r2.d8ger.com/Reve-Image/3.webp",
|
|
278
|
+
"altMsg": "Fumadocs hero with banner, cards, and responsive layout"
|
|
279
|
+
},
|
|
280
|
+
{
|
|
281
|
+
"url": "https://r2.d8ger.com/Reve-Image/4.webp",
|
|
282
|
+
"altMsg": "Header mega menu with pinned mobile actions and secondary buttons"
|
|
283
|
+
},
|
|
284
|
+
{
|
|
285
|
+
"url": "https://r2.d8ger.com/Reve-Image/5.webp",
|
|
286
|
+
"altMsg": "Fingerprint status panel summarizing anonymous onboarding"
|
|
287
|
+
},
|
|
288
|
+
{
|
|
289
|
+
"url": "https://r2.d8ger.com/Reve-Image/6.webp",
|
|
290
|
+
"altMsg": "Stripe lifecycle blueprint for subscriptions and one-time payments"
|
|
286
291
|
}
|
|
287
292
|
]
|
|
288
293
|
},
|
|
@@ -291,69 +296,69 @@
|
|
|
291
296
|
"eyesOn": "Diaomao",
|
|
292
297
|
"sections": [
|
|
293
298
|
{
|
|
294
|
-
"title": "
|
|
295
|
-
"description": "
|
|
299
|
+
"title": "Configure before coding",
|
|
300
|
+
"description": "Pricing, credits, navigation, and CTAs are config/translation-driven—tune parameters before touching code."
|
|
296
301
|
},
|
|
297
302
|
{
|
|
298
|
-
"title": "
|
|
299
|
-
"description": "
|
|
303
|
+
"title": "Keep billing options",
|
|
304
|
+
"description": "Even if you default to onetime, leave monthly/yearly available to avoid dead ends."
|
|
300
305
|
},
|
|
301
306
|
{
|
|
302
|
-
"title": "
|
|
303
|
-
"description": "
|
|
307
|
+
"title": "Honor device behaviors",
|
|
308
|
+
"description": "Mobile uses redirects/auth then closes; desktop can modal—follow the design guide for scroll and close timing."
|
|
304
309
|
},
|
|
305
310
|
{
|
|
306
|
-
"title": "
|
|
307
|
-
"description": "
|
|
311
|
+
"title": "Prefer SSR context",
|
|
312
|
+
"description": "Use InitUserContext to prehydrate user state—no first-screen jitter, billing defaults match reality."
|
|
308
313
|
},
|
|
309
314
|
{
|
|
310
|
-
"title": "
|
|
311
|
-
"description": "
|
|
315
|
+
"title": "Follow the schema",
|
|
316
|
+
"description": "Stick to Users/Subscriptions/Transactions/Credits; order_id + event.id keep webhooks idempotent."
|
|
312
317
|
},
|
|
313
318
|
{
|
|
314
|
-
"title": "
|
|
315
|
-
"description": "
|
|
319
|
+
"title": "Tell the story in docs",
|
|
320
|
+
"description": "Use Fumadocs cards and banners to ship product narrative and releases without extra styling."
|
|
316
321
|
}
|
|
317
322
|
]
|
|
318
323
|
},
|
|
319
324
|
"seoContent": {
|
|
320
|
-
"title": "
|
|
325
|
+
"title": "The AI-era product chassis with",
|
|
321
326
|
"eyesOn": "Diaomao",
|
|
322
|
-
"description": "
|
|
323
|
-
"intro": "Diaomao
|
|
327
|
+
"description": "Pricing, credits, docs, navigation, and Stripe orchestrated as one.",
|
|
328
|
+
"intro": "Diaomao compresses the slowest parts of shipping AI products into one template: Money Price runs subscription/onetime in parallel, Credit Overview governs buckets and CTA matrix, fingerprint-to-Clerk prevents funnel gaps, Stripe lifecycle and schema are pre-aligned, and Fumadocs + Header keep story and navigation consistent.",
|
|
324
329
|
"sections": [
|
|
325
330
|
{
|
|
326
|
-
"title": "
|
|
327
|
-
"content": "
|
|
331
|
+
"title": "Pricing that adapts to user state",
|
|
332
|
+
"content": "Billing pills switch monthly|yearly|onetime; SSR defaults to the user’s plan, and upgrade buttons honor enableSubscriptionUpgrade with Portal fallback."
|
|
328
333
|
},
|
|
329
334
|
{
|
|
330
|
-
"title": "
|
|
331
|
-
"content": "
|
|
335
|
+
"title": "Credits with clear buckets and CTA matrix",
|
|
336
|
+
"content": "Buckets, expiry hints, and device-aware actions: desktop modals or auth-to-Portal, mobile redirects or custom handlers."
|
|
332
337
|
},
|
|
333
338
|
{
|
|
334
|
-
"title": "
|
|
335
|
-
"content": "
|
|
339
|
+
"title": "Anonymous-first onboarding",
|
|
340
|
+
"content": "Fingerprint issues `fp_xxx`, grants starter credits, and writes records; after login the same context continues with balances and audit intact."
|
|
336
341
|
},
|
|
337
342
|
{
|
|
338
|
-
"title": "
|
|
339
|
-
"content": "
|
|
343
|
+
"title": "Stripe lifecycle baked in",
|
|
344
|
+
"content": "Checkout|Portal, async confirmation, renewal, past-due, refund, end-of-period cancel, upgrade|downgrade—all guarded by order_id metadata and webhook idempotency."
|
|
340
345
|
},
|
|
341
346
|
{
|
|
342
|
-
"title": "
|
|
343
|
-
"content": "
|
|
347
|
+
"title": "Navigation and docs that scale",
|
|
348
|
+
"content": "Header mega menu, pinned behaviors, and actionOrders keep Docs|pricing|auth buttons in place; Fumadocs cards and banners ship with no extra styling."
|
|
344
349
|
},
|
|
345
350
|
{
|
|
346
|
-
"title": "
|
|
347
|
-
"content": "
|
|
351
|
+
"title": "Schema-first reliability",
|
|
352
|
+
"content": "Users, Subscriptions, Credits, Transactions, CreditAuditLog indexed for fingerprint lookup, order routing, and audit stability."
|
|
348
353
|
}
|
|
349
354
|
],
|
|
350
|
-
"conclusion": "
|
|
355
|
+
"conclusion": "Plug in keys, tune config, fill copy—launch an AI-ready, revenue-ready, story-ready site in a week."
|
|
351
356
|
},
|
|
352
357
|
"cta": {
|
|
353
|
-
"title": "
|
|
358
|
+
"title": "Bring your AI product to life with",
|
|
354
359
|
"eyesOn": "Diaomao",
|
|
355
|
-
"description1": "
|
|
356
|
-
"description2": "
|
|
360
|
+
"description1": "One template for pricing, credits, docs, navigation, and Stripe.",
|
|
361
|
+
"description2": "Gradients, accessibility, and mobile behaviors are already tuned.",
|
|
357
362
|
"button": "Get Started Now",
|
|
358
363
|
"url": "https://preview.reve.art/"
|
|
359
364
|
},
|
|
@@ -399,4 +404,4 @@
|
|
|
399
404
|
"copyMarkdownDone": "Copied!",
|
|
400
405
|
"editOnGithub": "Edit this page on GitHub"
|
|
401
406
|
}
|
|
402
|
-
}
|
|
407
|
+
}
|