mirror of
https://github.com/NeteaseCloudMusicApiEnhanced/api-enhanced.git
synced 2025-10-22 14:43:10 +00:00
refactor: 页面重写
This commit is contained in:
parent
442d0a8f81
commit
8787bc6bb6
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@neteaseapireborn/api",
|
"name": "@neteaseapireborn/api",
|
||||||
"version": "4.28.28-beta.1",
|
"version": "4.28.29",
|
||||||
"description": "为停更的网易云音乐 NodeJs API 提供持续的维护!",
|
"description": "为停更的网易云音乐 NodeJs API 提供持续的维护!",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "node app.js",
|
"start": "node app.js",
|
||||||
|
@ -1,176 +1,302 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="zh">
|
<html lang="zh">
|
||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||||
<title>网易云音乐 API Enhanced</title>
|
<title>网易云音乐 API Enhanced</title>
|
||||||
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@mdi/font@6.5.95/css/materialdesignicons.min.css">
|
||||||
<style>
|
<style>
|
||||||
html, body {
|
:root {
|
||||||
height: 100vh;
|
--primary-color: #2d8cf0;
|
||||||
width: 100vw;
|
--secondary-color: #42b983;
|
||||||
|
--text-color: #333;
|
||||||
|
--text-secondary: #666;
|
||||||
|
--bg-color: #f5f7fa;
|
||||||
|
--card-bg: rgba(255,255,255,0.95);
|
||||||
|
--hover-bg: #eaf4fb;
|
||||||
|
--border-radius: 12px;
|
||||||
|
--transition: all 0.3s ease;
|
||||||
|
--shadow: 0 8px 24px rgba(31, 38, 135, 0.12);
|
||||||
|
--container-width: 1200px;
|
||||||
|
}
|
||||||
|
|
||||||
|
* {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
background: linear-gradient(135deg, #e0eafc 0%, #cfdef3 100%);
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
html, body {
|
||||||
|
height: 100%;
|
||||||
font-family: 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', Arial, sans-serif;
|
font-family: 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', Arial, sans-serif;
|
||||||
color: #333;
|
background: linear-gradient(135deg, #e0eafc 0%, #cfdef3 100%);
|
||||||
|
color: var(--text-color);
|
||||||
|
line-height: 1.6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.layout {
|
||||||
|
min-height: 100%;
|
||||||
|
padding: 2rem 1rem;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.container {
|
.container {
|
||||||
background: rgba(255,255,255,0.95);
|
width: 100%;
|
||||||
padding: 2.5em 2em 2em 2em;
|
max-width: var(--container-width);
|
||||||
border-radius: 18px;
|
margin: 0 auto;
|
||||||
box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.18);
|
display: grid;
|
||||||
max-width: 520px;
|
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
|
||||||
width: 95vw;
|
gap: 2rem;
|
||||||
margin-top: 2em;
|
animation: fadeIn 0.8s ease-out;
|
||||||
margin-bottom: 2em;
|
|
||||||
position: relative;
|
|
||||||
overflow: hidden;
|
|
||||||
animation: fadeIn 1.2s cubic-bezier(.39,.575,.565,1) both;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes fadeIn {
|
@keyframes fadeIn {
|
||||||
0% { opacity: 0; transform: translateY(30px); }
|
from { opacity: 0; transform: translateY(20px); }
|
||||||
100% { opacity: 1; transform: translateY(0); }
|
to { opacity: 1; transform: translateY(0); }
|
||||||
}
|
}
|
||||||
|
|
||||||
h1 {
|
.header {
|
||||||
font-size: 2.3em;
|
grid-column: 1 / -1;
|
||||||
margin-bottom: 0.5em;
|
text-align: center;
|
||||||
color: #2d8cf0;
|
padding: 2rem;
|
||||||
letter-spacing: 1px;
|
background: var(--card-bg);
|
||||||
font-weight: 700;
|
border-radius: var(--border-radius);
|
||||||
|
box-shadow: var(--shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.header h1 {
|
||||||
|
font-size: 2.5rem;
|
||||||
|
color: var(--primary-color);
|
||||||
|
margin-bottom: 1rem;
|
||||||
text-shadow: 0 2px 8px #e0eafc;
|
text-shadow: 0 2px 8px #e0eafc;
|
||||||
}
|
}
|
||||||
|
|
||||||
.version {
|
.header p {
|
||||||
font-size: 1.1em;
|
color: var(--text-secondary);
|
||||||
color: #888;
|
font-size: 1.1rem;
|
||||||
margin-left: 0.5em;
|
max-width: 800px;
|
||||||
|
margin: 0 auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
p {
|
.card {
|
||||||
font-size: 1.1em;
|
background: var(--card-bg);
|
||||||
margin-bottom: 1.2em;
|
border-radius: var(--border-radius);
|
||||||
color: #555;
|
padding: 1.5rem;
|
||||||
line-height: 1.7;
|
box-shadow: var(--shadow);
|
||||||
|
transition: var(--transition);
|
||||||
}
|
}
|
||||||
|
|
||||||
.current-url {
|
.card:hover {
|
||||||
font-size: 0.98em;
|
transform: translateY(-5px);
|
||||||
color: #aaa;
|
box-shadow: 0 12px 32px rgba(31, 38, 135, 0.15);
|
||||||
margin-bottom: 1.2em;
|
|
||||||
word-break: break-all;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
a {
|
.card h2 {
|
||||||
color: #2d8cf0;
|
color: var(--primary-color);
|
||||||
text-decoration: none;
|
font-size: 1.5rem;
|
||||||
transition: color 0.2s;
|
margin-bottom: 1rem;
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
a:hover {
|
|
||||||
color: #42b983;
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
h2 {
|
|
||||||
font-size: 1.3em;
|
|
||||||
margin: 1.5em 0 0.7em 0;
|
|
||||||
color: #2d8cf0;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul {
|
|
||||||
list-style: none;
|
|
||||||
padding: 0;
|
|
||||||
margin: 0;
|
|
||||||
text-align: left;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
li {
|
|
||||||
margin: 0.6em 0;
|
|
||||||
line-height: 1.7;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
background: #f4f8fb;
|
gap: 0.5rem;
|
||||||
border-radius: 6px;
|
|
||||||
padding: 0.5em 1em;
|
|
||||||
transition: box-shadow 0.2s;
|
|
||||||
box-shadow: 0 1px 2px rgba(45,140,240,0.04);
|
|
||||||
}
|
|
||||||
li:hover {
|
|
||||||
box-shadow: 0 4px 12px rgba(45,140,240,0.10);
|
|
||||||
background: #eaf4fb;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.number {
|
.card h2 i {
|
||||||
margin-right: 12px;
|
font-size: 1.8rem;
|
||||||
color: #2d8cf0;
|
}
|
||||||
font-weight: bold;
|
|
||||||
font-size: 1.1em;
|
.feature-list {
|
||||||
min-width: 2em;
|
list-style: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-item {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
padding: 0.8rem;
|
||||||
|
margin: 0.5rem 0;
|
||||||
|
background: var(--bg-color);
|
||||||
|
border-radius: 8px;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-item:hover {
|
||||||
|
background: var(--hover-bg);
|
||||||
|
transform: translateX(5px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-item a {
|
||||||
|
color: var(--text-color);
|
||||||
|
text-decoration: none;
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.feature-item i {
|
||||||
|
color: var(--primary-color);
|
||||||
|
font-size: 1.2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.status {
|
||||||
|
background: var(--card-bg);
|
||||||
|
padding: 1rem;
|
||||||
|
border-radius: var(--border-radius);
|
||||||
|
margin-top: 2rem;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.version {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
text-align: right;
|
padding: 0.2rem 0.8rem;
|
||||||
|
background: var(--primary-color);
|
||||||
|
color: white;
|
||||||
|
border-radius: 20px;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
margin-left: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer {
|
.footer {
|
||||||
margin-top: 2em;
|
grid-column: 1 / -1;
|
||||||
color: #aaa;
|
|
||||||
font-size: 0.98em;
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
letter-spacing: 0.5px;
|
margin-top: 2rem;
|
||||||
|
padding: 1rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer a {
|
||||||
|
color: var(--primary-color);
|
||||||
|
text-decoration: none;
|
||||||
|
transition: var(--transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer a:hover {
|
||||||
|
color: var(--secondary-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
.container {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
|
||||||
|
.header h1 {
|
||||||
|
font-size: 2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card {
|
||||||
|
margin: 0 1rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div class="container">
|
<div class="layout">
|
||||||
<h1>网易云音乐 API Enhanced <span id="api-version" class="version"></span></h1>
|
<div class="container">
|
||||||
<p>🎵 这是一个持续维护的第三方网易云音乐 API 服务,兼容原版接口,支持多平台部署。</p>
|
<header class="header">
|
||||||
<p>当你看到这个页面时,服务已成功运行!</p>
|
<h1>网易云音乐 API Enhanced <span id="api-version" class="version"></span></h1>
|
||||||
<p class="current-url">当前访问:<span id="current-url"></span></p>
|
<p>🔍 A revival project for NeteaseCloudMusicApi Node.js Services</p>
|
||||||
<a href="/docs" target="_blank">📚 查看接口文档</a>
|
</header>
|
||||||
<h2>常用示例</h2>
|
|
||||||
<ul id="example-list">
|
<div class="card">
|
||||||
<li><a href="./search?keywords=这么可爱真是抱歉">搜索歌曲</a></li>
|
<h2><i class="mdi mdi-book-open-page-variant"></i>文档与演示</h2>
|
||||||
<li><a href="./song/url/unblock?id=1969519579">歌曲解灰</a></li>
|
<ul class="feature-list">
|
||||||
<li><a href="./comment/music?id=1969519579&limit=1">获取歌曲评论</a></li>
|
<li class="feature-item">
|
||||||
<li><a href="./dj/program?rid=336355127">获取电台节目</a></li>
|
<a href="/docs" target="_blank">
|
||||||
<li><a href="./qrlogin.html">二维码登录演示</a></li>
|
<i class="mdi mdi-file-document"></i>
|
||||||
<li><a href="./audio_match_demo/index.html">听歌识曲 Demo</a></li>
|
API 文档
|
||||||
<li><a href="./cloud.html">云盘上传 Demo</a></li>
|
</a>
|
||||||
<li><a href="./eapi_decrypt.html">EAPI 参数/返回值解析</a></li>
|
</li>
|
||||||
<li><a href="./api.html">API 调试界面</a></li>
|
<li class="feature-item">
|
||||||
<li><a href="./playlist_import.html">歌单导入工具</a></li>
|
<a href="./api.html">
|
||||||
</ul>
|
<i class="mdi mdi-console"></i>
|
||||||
<div class="footer">
|
API 调试界面
|
||||||
<span>© 2025 网易云音乐 API Enhanced(Reborn) | <a href="https://github.com/neteasecloudmusicapienhanced/api-enhanced" target="_blank">GitHub</a></span>
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./qrlogin.html">
|
||||||
|
<i class="mdi mdi-qrcode"></i>
|
||||||
|
二维码登录演示
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card">
|
||||||
|
<h2><i class="mdi mdi-music"></i>音乐功能</h2>
|
||||||
|
<ul class="feature-list">
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./search?keywords=这么可爱真是抱歉">
|
||||||
|
<i class="mdi mdi-magnify"></i>
|
||||||
|
搜索歌曲
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./song/url/unblock?id=1969519579">
|
||||||
|
<i class="mdi mdi-lock-open"></i>
|
||||||
|
歌曲解灰
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./comment/music?id=1969519579&limit=1">
|
||||||
|
<i class="mdi mdi-comment"></i>
|
||||||
|
获取评论
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card">
|
||||||
|
<h2><i class="mdi mdi-tools"></i>实用工具</h2>
|
||||||
|
<ul class="feature-list">
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./audio_match_demo/index.html">
|
||||||
|
<i class="mdi mdi-music-note-search"></i>
|
||||||
|
听歌识曲
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./cloud.html">
|
||||||
|
<i class="mdi mdi-cloud-upload"></i>
|
||||||
|
云盘上传
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./playlist_import.html">
|
||||||
|
<i class="mdi mdi-playlist-plus"></i>
|
||||||
|
歌单导入
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="feature-item">
|
||||||
|
<a href="./eapi_decrypt.html">
|
||||||
|
<i class="mdi mdi-decode"></i>
|
||||||
|
EAPI 解析
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="status">
|
||||||
|
当前访问地址:<span id="current-url"></span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<footer class="footer">
|
||||||
|
<span>© 2025 网易云音乐 API Enhanced(Reborn) | </span>
|
||||||
|
<a href="https://github.com/neteasecloudmusicapienhanced/api-enhanced" target="_blank">
|
||||||
|
<i class="mdi mdi-github"></i> GitHub
|
||||||
|
</a>
|
||||||
|
</footer>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script src="https://fastly.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
|
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
|
||||||
<script>
|
<script>
|
||||||
document.addEventListener('DOMContentLoaded', function() {
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
const currentUrlElement = document.getElementById('current-url');
|
// 显示当前URL
|
||||||
currentUrlElement.textContent = window.location.href;
|
document.getElementById('current-url').textContent = window.location.href;
|
||||||
|
|
||||||
const exampleList = document.getElementById('example-list');
|
|
||||||
const items = exampleList.getElementsByTagName('li');
|
|
||||||
|
|
||||||
for (let i = 0; i < items.length; i++) {
|
|
||||||
const number = document.createElement('span');
|
|
||||||
number.className = 'number';
|
|
||||||
number.textContent = (i + 1) + '. ';
|
|
||||||
items[i].prepend(number);
|
|
||||||
}
|
|
||||||
|
|
||||||
// 获取API版本号
|
// 获取API版本号
|
||||||
axios({
|
axios({
|
||||||
@ -178,13 +304,10 @@
|
|||||||
method: 'post',
|
method: 'post',
|
||||||
data: {},
|
data: {},
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
const body = res.data;
|
const version = res.data.data.version;
|
||||||
const version = body.data.version;
|
document.getElementById('api-version').textContent = `v${version}`;
|
||||||
const apiVersionElement = document.getElementById('api-version');
|
|
||||||
apiVersionElement.textContent = ` v${version}`;
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
Loading…
x
Reference in New Issue
Block a user