diff --git a/change.patch b/change.patch
new file mode 100644
index 000000000000..5c42f7684577
--- /dev/null
+++ b/change.patch
@@ -0,0 +1,173 @@
+diff --git a/web/classic/src/hooks/common/useNavigation.js b/web/classic/src/hooks/common/useNavigation.js
+index f7e61a20..c2a64b01 100644
+--- a/web/classic/src/hooks/common/useNavigation.js
++++ b/web/classic/src/hooks/common/useNavigation.js
+@@ -49,16 +49,16 @@ export const useNavigation = (t, docsLink, headerNavModules) => {
+ itemKey: 'pricing',
+ to: '/pricing',
+ },
+- ...(docsLink
+- ? [
+- {
+- text: t('文档'),
+- itemKey: 'docs',
+- isExternal: true,
+- externalLink: docsLink,
+- },
+- ]
+- : []),
++ // ...(docsLink
++ // ? [
++ // {
++ // text: t('文档'),
++ // itemKey: 'docs',
++ // isExternal: true,
++ // externalLink: docsLink,
++ // },
++ // ]
++ // : []),
+ {
+ text: t('关于'),
+ itemKey: 'about',
+diff --git a/web/classic/src/pages/Home/index.jsx b/web/classic/src/pages/Home/index.jsx
+index c153c1b3..0aa93b11 100644
+--- a/web/classic/src/pages/Home/index.jsx
++++ b/web/classic/src/pages/Home/index.jsx
+@@ -239,16 +239,17 @@ const Home = () => {
+ {statusState.status.version}
+
+ ) : (
+- docsLink && (
+- }
+- onClick={() => window.open(docsLink, '_blank')}
+- >
+- {t('文档')}
+-
+- )
++ // docsLink && (
++ // }
++ // onClick={() => window.open(docsLink, '_blank')}
++ // >
++ // {t('文档')}
++ //
++ null
++ // )
+ )}
+
+
+diff --git a/web/classic/src/pages/Setting/Operation/SettingsHeaderNavModules.jsx b/web/classic/src/pages/Setting/Operation/SettingsHeaderNavModules.jsx
+index 19943c1a..5c061ef2 100644
+--- a/web/classic/src/pages/Setting/Operation/SettingsHeaderNavModules.jsx
++++ b/web/classic/src/pages/Setting/Operation/SettingsHeaderNavModules.jsx
+@@ -178,11 +178,11 @@ export default function SettingsHeaderNavModules(props) {
+ description: t('模型定价,需要登录访问'),
+ hasSubConfig: true, // 标识该模块有子配置
+ },
+- {
+- key: 'docs',
+- title: t('文档'),
+- description: t('系统文档和帮助信息'),
+- },
++ // {
++ // key: 'docs',
++ // title: t('文档'),
++ // description: t('系统文档和帮助信息'),
++ // },
+ {
+ key: 'about',
+ title: t('关于'),
+diff --git a/web/default/src/components/layout/components/public-header.tsx b/web/default/src/components/layout/components/public-header.tsx
+index 476cddbd..f82b01ac 100644
+--- a/web/default/src/components/layout/components/public-header.tsx
++++ b/web/default/src/components/layout/components/public-header.tsx
+@@ -123,7 +123,7 @@ export function PublicHeader(props: PublicHeaderProps) {
+
+ {/* Desktop nav */}
+
+- {links.map((link, i) => {
++ {links.filter(link => t(link.title) !== '文档').map((link, i) => {
+ const isActive = pathname === link.href
+ if (link.external) {
+ return (
+diff --git a/web/default/src/features/home/components/sections/stats.tsx b/web/default/src/features/home/components/sections/stats.tsx
+index 33e1b9d4..5bcd086d 100644
+--- a/web/default/src/features/home/components/sections/stats.tsx
++++ b/web/default/src/features/home/components/sections/stats.tsx
+@@ -79,25 +79,27 @@ export function Stats(_props: StatsProps) {
+ { end: 10, suffix: 'K+', label: t('active routes') },
+ ]
+
+- return (
+-
+-
+-
+- {stats.map((s) => (
+-
+-
+-
+-
+-
+- {s.label}
+-
+-
+- ))}
+-
+-
+-
+- )
++ // return (
++ //
++ //
++ //
++ // {stats.map((s) => (
++ //
++ //
++ //
++ //
++ //
++ // {s.label}
++ //
++ //
++ // ))}
++ //
++ //
++ //
++ // )
++
++ return '';
+ }
+diff --git a/web/default/src/hooks/use-top-nav-links.ts b/web/default/src/hooks/use-top-nav-links.ts
+index dfbd8844..2db4b0c0 100644
+--- a/web/default/src/hooks/use-top-nav-links.ts
++++ b/web/default/src/hooks/use-top-nav-links.ts
+@@ -77,15 +77,15 @@ export function useTopNavLinks(): TopNavLink[] {
+ // Docs (supports external links)
+ if (modules?.docs !== false) {
+ if (docsLink) {
+- links.push({ title: t('Docs'), href: docsLink, external: true })
++ // links.push({ title: t('Docs'), href: docsLink, external: true })
+ } else {
+- links.push({ title: t('Docs'), href: '/docs' })
++ // links.push({ title: t('Docs'), href: '/docs' })
+ }
+ }
+
+ // About
+ if (modules?.about !== false) {
+- links.push({ title: t('About'), href: '/about' })
++ // links.push({ title: t('About'), href: '/about' })
+ }
+
+ return links
diff --git a/controller/misc.go b/controller/misc.go
index 1250bb7f874b..5a453351c86b 100644
--- a/controller/misc.go
+++ b/controller/misc.go
@@ -71,7 +71,7 @@ func GetStatus(c *gin.Context) {
"turnstile_check": common.TurnstileCheckEnabled,
"turnstile_site_key": common.TurnstileSiteKey,
"top_up_link": common.TopUpLink,
- "docs_link": operation_setting.GetGeneralSetting().DocsLink,
+ // "docs_link": operation_setting.GetGeneralSetting().DocsLink,
"quota_per_unit": common.QuotaPerUnit,
// 兼容旧前端:保留 display_in_currency,同时提供新的 quota_display_type
"display_in_currency": operation_setting.IsCurrencyDisplay(),
diff --git a/setting/operation_setting/general_setting.go b/setting/operation_setting/general_setting.go
index b4a3ccccdaf3..e29daa4c01ca 100644
--- a/setting/operation_setting/general_setting.go
+++ b/setting/operation_setting/general_setting.go
@@ -11,7 +11,7 @@ const (
)
type GeneralSetting struct {
- DocsLink string `json:"docs_link"`
+ // DocsLink string `json:"docs_link"`
PingIntervalEnabled bool `json:"ping_interval_enabled"`
PingIntervalSeconds int `json:"ping_interval_seconds"`
// 当前站点额度展示类型:USD / CNY / TOKENS
@@ -24,7 +24,7 @@ type GeneralSetting struct {
// 默认配置
var generalSetting = GeneralSetting{
- DocsLink: "https://docs.newapi.pro",
+ // DocsLink: "https://docs.newapi.pro",
PingIntervalEnabled: false,
PingIntervalSeconds: 60,
QuotaDisplayType: QuotaDisplayTypeUSD,
diff --git a/web/classic/bun.lock b/web/classic/bun.lock
index da3c1e452a9d..4f109c348221 100644
--- a/web/classic/bun.lock
+++ b/web/classic/bun.lock
@@ -1,5 +1,6 @@
{
"lockfileVersion": 1,
+ "configVersion": 0,
"workspaces": {
"": {
"name": "react-template",
diff --git a/web/classic/src/components/common/DocumentRenderer/index.jsx b/web/classic/src/components/common/DocumentRenderer/index.jsx
index 8c15c073de1d..eaec9a6ba5f9 100644
--- a/web/classic/src/components/common/DocumentRenderer/index.jsx
+++ b/web/classic/src/components/common/DocumentRenderer/index.jsx
@@ -69,6 +69,8 @@ const sanitizeHtml = (html) => {
* @param {string} emptyMessage - 空内容时的提示消息
*/
const DocumentRenderer = ({ apiEndpoint, title, cacheKey, emptyMessage }) => {
+ return null;
+ /* eslint-disable no-unreachable */
const { t } = useTranslation();
const [content, setContent] = useState('');
const [loading, setLoading] = useState(true);
diff --git a/web/classic/src/components/layout/Footer.jsx b/web/classic/src/components/layout/Footer.jsx
index ba64689374ab..0aa5268fdee7 100644
--- a/web/classic/src/components/layout/Footer.jsx
+++ b/web/classic/src/components/layout/Footer.jsx
@@ -89,7 +89,7 @@ const FooterBar = () => {
-
+ {/*
{t('文档')}
@@ -119,7 +119,7 @@ const FooterBar = () => {
{t('API 文档')}
-
+ */}
diff --git a/web/classic/src/components/settings/OperationSetting.jsx b/web/classic/src/components/settings/OperationSetting.jsx
index 8585a3e90278..07cf4afe3c76 100644
--- a/web/classic/src/components/settings/OperationSetting.jsx
+++ b/web/classic/src/components/settings/OperationSetting.jsx
@@ -40,7 +40,7 @@ const OperationSetting = () => {
/* 通用设置 */
TopUpLink: '',
- 'general_setting.docs_link': '',
+ // 'general_setting.docs_link': '',
QuotaPerUnit: 0,
USDExchangeRate: 0,
RetryTimes: 0,
diff --git a/web/classic/src/helpers/data.js b/web/classic/src/helpers/data.js
index e45aac3e9941..da517738032a 100644
--- a/web/classic/src/helpers/data.js
+++ b/web/classic/src/helpers/data.js
@@ -49,11 +49,11 @@ export function setStatusData(data) {
} else {
localStorage.removeItem('chat_link2');
}
- if (data.docs_link) {
- localStorage.setItem('docs_link', data.docs_link);
- } else {
- localStorage.removeItem('docs_link');
- }
+ // if (data.docs_link) {
+ // localStorage.setItem('docs_link', data.docs_link);
+ // } else {
+ // localStorage.removeItem('docs_link');
+ // }
}
export function setUserData(data) {
diff --git a/web/classic/src/hooks/common/useHeaderBar.js b/web/classic/src/hooks/common/useHeaderBar.js
index a4842ee6ba98..f892ae5596ff 100644
--- a/web/classic/src/hooks/common/useHeaderBar.js
+++ b/web/classic/src/hooks/common/useHeaderBar.js
@@ -49,7 +49,8 @@ export const useHeaderBar = ({ onMobileMenuToggle, drawerOpen }) => {
const isNewYear = currentDate.getMonth() === 0 && currentDate.getDate() === 1;
const isSelfUseMode = statusState?.status?.self_use_mode_enabled || false;
- const docsLink = statusState?.status?.docs_link || '';
+ // const docsLink = statusState?.status?.docs_link || '';
+ const docsLink = '';
const isDemoSiteMode = statusState?.status?.demo_site_enabled || false;
// 获取顶栏模块配置
diff --git a/web/classic/src/hooks/common/useNavigation.js b/web/classic/src/hooks/common/useNavigation.js
index f7e61a203a8e..29ae54a63232 100644
--- a/web/classic/src/hooks/common/useNavigation.js
+++ b/web/classic/src/hooks/common/useNavigation.js
@@ -26,7 +26,7 @@ export const useNavigation = (t, docsLink, headerNavModules) => {
home: true,
console: true,
pricing: true,
- docs: true,
+ // docs: true,
about: true,
};
@@ -49,16 +49,16 @@ export const useNavigation = (t, docsLink, headerNavModules) => {
itemKey: 'pricing',
to: '/pricing',
},
- ...(docsLink
- ? [
- {
- text: t('文档'),
- itemKey: 'docs',
- isExternal: true,
- externalLink: docsLink,
- },
- ]
- : []),
+ // ...(docsLink
+ // ? [
+ // {
+ // text: t('文档'),
+ // itemKey: 'docs',
+ // isExternal: true,
+ // externalLink: docsLink,
+ // },
+ // ]
+ // : []),
{
text: t('关于'),
itemKey: 'about',
@@ -68,9 +68,9 @@ export const useNavigation = (t, docsLink, headerNavModules) => {
// 根据配置过滤导航链接
return allLinks.filter((link) => {
- if (link.itemKey === 'docs') {
- return docsLink && modules.docs;
- }
+ // if (link.itemKey === 'docs') {
+ // return docsLink && modules.docs;
+ // }
if (link.itemKey === 'pricing') {
// 支持新的pricing配置格式
return typeof modules.pricing === 'object'
diff --git a/web/classic/src/pages/Home/index.jsx b/web/classic/src/pages/Home/index.jsx
index c153c1b3da99..166d5a39dc91 100644
--- a/web/classic/src/pages/Home/index.jsx
+++ b/web/classic/src/pages/Home/index.jsx
@@ -74,7 +74,7 @@ const Home = () => {
const [noticeVisible, setNoticeVisible] = useState(false);
const isMobile = useIsMobile();
const isDemoSiteMode = statusState?.status?.demo_site_enabled || false;
- const docsLink = statusState?.status?.docs_link || '';
+ // const docsLink = statusState?.status?.docs_link || '';
const serverAddress =
statusState?.status?.server_address || `${window.location.origin}`;
const endpointItems = API_ENDPOINTS.map((e) => ({ value: e }));
@@ -239,16 +239,17 @@ const Home = () => {
{statusState.status.version}
) : (
- docsLink && (
- }
- onClick={() => window.open(docsLink, '_blank')}
- >
- {t('文档')}
-
- )
+ // docsLink && (
+ // }
+ // onClick={() => window.open(docsLink, '_blank')}
+ // >
+ // {t('文档')}
+ //
+ null
+ // )
)}
diff --git a/web/classic/src/pages/PrivacyPolicy/index.jsx b/web/classic/src/pages/PrivacyPolicy/index.jsx
index d2c4a872d48a..86105c9d4a17 100644
--- a/web/classic/src/pages/PrivacyPolicy/index.jsx
+++ b/web/classic/src/pages/PrivacyPolicy/index.jsx
@@ -18,20 +18,21 @@ For commercial licensing, please contact support@quantumnous.com
*/
import React from 'react';
-import { useTranslation } from 'react-i18next';
-import DocumentRenderer from '../../components/common/DocumentRenderer';
+// import { useTranslation } from 'react-i18next';
+// import DocumentRenderer from '../../components/common/DocumentRenderer';
const PrivacyPolicy = () => {
- const { t } = useTranslation();
-
- return (
-
- );
+ // const { t } = useTranslation();
+
+ return null;
+ // return (
+ //
+ // );
};
export default PrivacyPolicy;
diff --git a/web/classic/src/pages/Setting/Operation/SettingsGeneral.jsx b/web/classic/src/pages/Setting/Operation/SettingsGeneral.jsx
index 80810da068cc..ec474949260f 100644
--- a/web/classic/src/pages/Setting/Operation/SettingsGeneral.jsx
+++ b/web/classic/src/pages/Setting/Operation/SettingsGeneral.jsx
@@ -46,7 +46,7 @@ export default function GeneralSettings(props) {
const [showQuotaWarning, setShowQuotaWarning] = useState(false);
const [inputs, setInputs] = useState({
TopUpLink: '',
- 'general_setting.docs_link': '',
+ // 'general_setting.docs_link': '',
'general_setting.quota_display_type': 'USD',
'general_setting.custom_currency_symbol': '¤',
'general_setting.custom_currency_exchange_rate': '',
@@ -252,7 +252,7 @@ export default function GeneralSettings(props) {
showClear
/>
-
+ {/*
-
+ */}
{/* 单位美元额度已合入汇率组合控件(TOKENS 模式下编辑),不再单独展示 */}
{
- const { t } = useTranslation();
-
- return (
-
- );
+ // const { t } = useTranslation();
+
+ return null;
+ // return (
+ //
+ // );
};
export default UserAgreement;
diff --git a/web/default/src/components/layout/components/footer.tsx b/web/default/src/components/layout/components/footer.tsx
index eed0b6c5141b..23c890941d22 100644
--- a/web/default/src/components/layout/components/footer.tsx
+++ b/web/default/src/components/layout/components/footer.tsx
@@ -83,23 +83,23 @@ export function Footer(props: FooterProps) {
},
],
},
- {
- title: t('footer.columns.docs.title'),
- links: [
- {
- text: t('footer.columns.docs.links.quickStart'),
- href: 'https://docs.newapi.pro/getting-started/',
- },
- {
- text: t('footer.columns.docs.links.installation'),
- href: 'https://docs.newapi.pro/installation/',
- },
- {
- text: t('footer.columns.docs.links.apiDocs'),
- href: 'https://docs.newapi.pro/api/',
- },
- ],
- },
+ // {
+ // title: t('footer.columns.docs.title'),
+ // links: [
+ // {
+ // text: t('footer.columns.docs.links.quickStart'),
+ // href: 'https://docs.newapi.pro/getting-started/',
+ // },
+ // {
+ // text: t('footer.columns.docs.links.installation'),
+ // href: 'https://docs.newapi.pro/installation/',
+ // },
+ // {
+ // text: t('footer.columns.docs.links.apiDocs'),
+ // href: 'https://docs.newapi.pro/api/',
+ // },
+ // ],
+ // },
{
title: t('footer.columns.related.title'),
links: [
diff --git a/web/default/src/components/layout/components/public-header.tsx b/web/default/src/components/layout/components/public-header.tsx
index 476cddbda1b2..9cbf962e0506 100644
--- a/web/default/src/components/layout/components/public-header.tsx
+++ b/web/default/src/components/layout/components/public-header.tsx
@@ -124,6 +124,7 @@ export function PublicHeader(props: PublicHeaderProps) {
{/* Desktop nav */}
{links.map((link, i) => {
+ // {links.filter(link => t(link.title) !== '文档').map((link, i) => {
const isActive = pathname === link.href
if (link.external) {
return (
diff --git a/web/default/src/features/home/components/sections/features.tsx b/web/default/src/features/home/components/sections/features.tsx
index d414cee78830..e9c35cad87ea 100644
--- a/web/default/src/features/home/components/sections/features.tsx
+++ b/web/default/src/features/home/components/sections/features.tsx
@@ -2,7 +2,7 @@ import {
Zap,
Shield,
Globe,
- Code,
+ // Code,
Gauge,
DollarSign,
Users,
@@ -109,32 +109,32 @@ export function Features(_props: FeaturesProps) {
),
},
- {
- id: 'developer',
- num: '04',
- title: t('Developer Friendly'),
- desc: t('Complete API documentation with multi-language SDK support'),
- span: 'md:col-span-2',
- icon: ,
- visual: (
-
-
- {['API', 'SDK', 'CLI', 'Docs'].map((n) => (
-
- {n}
-
- ))}
-
-
-
- {t('OpenAI Compatible')}
-
-
- ),
- },
+ // {
+ // id: 'developer',
+ // num: '04',
+ // title: t('Developer Friendly'),
+ // desc: t('Complete API documentation with multi-language SDK support'),
+ // span: 'md:col-span-2',
+ // icon: ,
+ // visual: (
+ //
+ //
+ // {['API', 'SDK', 'CLI', 'Docs'].map((n) => (
+ //
+ // {n}
+ //
+ // ))}
+ //
+ //
+ //
+ // {t('OpenAI Compatible')}
+ //
+ //
+ // ),
+ // },
]
const additionalFeatures = [
diff --git a/web/default/src/features/home/components/sections/stats.tsx.rej b/web/default/src/features/home/components/sections/stats.tsx.rej
new file mode 100644
index 000000000000..8a08cdb5df14
--- /dev/null
+++ b/web/default/src/features/home/components/sections/stats.tsx.rej
@@ -0,0 +1,49 @@
+@@ -79,25 +79,27 @@
+ { end: 10, suffix: 'K+', label: t('active routes') },
+ ]
+
+- return (
+-
+-
+-
+- {stats.map((s) => (
+-
+-
+-
+-
+-
+- {s.label}
+-
+-
+- ))}
+-
+-
+-
+- )
++ // return (
++ //
++ //
++ //
++ // {stats.map((s) => (
++ //
++ //
++ //
++ //
++ //
++ // {s.label}
++ //
++ //
++ // ))}
++ //
++ //
++ //
++ // )
++
++ return '';
+ }
diff --git a/web/default/src/features/legal/legal-document.tsx b/web/default/src/features/legal/legal-document.tsx
index 9df00f847c8b..8cdce59db350 100644
--- a/web/default/src/features/legal/legal-document.tsx
+++ b/web/default/src/features/legal/legal-document.tsx
@@ -1,8 +1,8 @@
import { useQuery } from '@tanstack/react-query'
import { FileWarning } from 'lucide-react'
import { useTranslation } from 'react-i18next'
-import { Button } from '@/components/ui/button'
-import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'
+// import { Button } from '@/components/ui/button'
+import { Card, CardHeader, CardTitle } from '@/components/ui/card'
import { Markdown } from '@/components/ui/markdown'
import { Skeleton } from '@/components/ui/skeleton'
import { PublicLayout } from '@/components/layout'
@@ -82,31 +82,31 @@ export function LegalDocument({
)
}
- if (isUrl) {
- return (
-
-
-
-
- {title}
-
-
-
- {t(
- 'The administrator configured an external link for this document.'
- )}
-
-
-
-
-
-
- )
- }
+ // if (isUrl) {
+ // return (
+ //
+ //
+ //
+ //
+ // {title}
+ //
+ //
+ //
+ // {t(
+ // 'The administrator configured an external link for this document.'
+ // )}
+ //
+ //
+ //
+ //
+ //
+ //
+ // )
+ // }
return (
diff --git a/web/default/src/features/system-settings/general/index.tsx b/web/default/src/features/system-settings/general/index.tsx
index 054a3f865045..da1ed0598543 100644
--- a/web/default/src/features/system-settings/general/index.tsx
+++ b/web/default/src/features/system-settings/general/index.tsx
@@ -24,7 +24,7 @@ const defaultGeneralSettings: GeneralSettings = {
QuotaForInviter: 0,
QuotaForInvitee: 0,
TopUpLink: '',
- 'general_setting.docs_link': '',
+ // 'general_setting.docs_link': '',
'quota_setting.enable_free_model_pre_consume': true,
QuotaPerUnit: 500000,
USDExchangeRate: 7,
diff --git a/web/default/src/features/system-settings/general/quota-settings-section.tsx b/web/default/src/features/system-settings/general/quota-settings-section.tsx
index 466eca4be28e..7dbe18982025 100644
--- a/web/default/src/features/system-settings/general/quota-settings-section.tsx
+++ b/web/default/src/features/system-settings/general/quota-settings-section.tsx
@@ -26,7 +26,7 @@ const quotaSchema = z.object({
QuotaForInviter: z.coerce.number().min(0),
QuotaForInvitee: z.coerce.number().min(0),
TopUpLink: z.string().url().optional().or(z.literal('')),
- 'general_setting.docs_link': z.string().url().optional().or(z.literal('')),
+ // 'general_setting.docs_link': z.string().url().optional().or(z.literal('')),
'quota_setting.enable_free_model_pre_consume': z.boolean(),
})
@@ -212,7 +212,7 @@ export function QuotaSettingsSection({
)}
/>
- (
@@ -230,7 +230,7 @@ export function QuotaSettingsSection({
)}
- />
+ /> */}