From 48afa821e4ac3e55a8dcc19cf083db45bdef0d58 Mon Sep 17 00:00:00 2001 From: t0ng7u Date: Wed, 16 Jul 2025 03:38:06 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=96=8C=EF=B8=8F=20feat(ui):=20always=20sh?= =?UTF-8?q?ow=20colorful=20console=20banner=20for=20NewAPI=20in=20every=20?= =?UTF-8?q?environment?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a branded console log to `web/src/index.js` that prints: “We ❤ NewAPI Github: https://github.com/QuantumNous/new-api” Changes include: • Remove the `NODE_ENV` guard so the banner appears in both development and production. • Increase font size to 24 px and keep “NewAPI” in bold green for stronger branding. This is a purely visual/developer-experience enhancement—no runtime behavior is affected. --- web/src/index.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/web/src/index.js b/web/src/index.js index b193ddf1..f3dd3592 100644 --- a/web/src/index.js +++ b/web/src/index.js @@ -10,6 +10,13 @@ import PageLayout from './components/layout/PageLayout.js'; import './i18n/i18n.js'; import './index.css'; +// 欢迎信息(二次开发者不准将此移除) +if (typeof window !== 'undefined') { + console.log('%cWe ❤ NewAPI%c Github: https://github.com/QuantumNous/new-api', + 'color: #10b981; font-weight: bold; font-size: 24px;', + 'color: inherit; font-size: 14px;'); +} + // initialization const root = ReactDOM.createRoot(document.getElementById('root'));