kbsearch-extension/pages/settings.html
2025-06-02 01:47:35 +08:00

153 lines
3.5 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8" />
<title>插件设置</title>
<style>
body {
font-family: "Microsoft YaHei", sans-serif;
padding: 20px 30px;
max-width: 1000px;
margin: auto;
background-color: #f7f8fc;
color: #333;
}
h2 {
margin-top: 0;
}
.back-link {
display: inline-block;
margin-bottom: 20px;
font-size: 14px;
color: #2560de;
cursor: pointer;
}
.section {
margin-bottom: 30px;
background: #fff;
border: 1px solid #dfe4ed;
border-radius: 8px;
box-shadow: 0 2px 6px rgba(0,0,0,0.04);
padding: 20px 24px;
}
.section h3 {
margin: 0 0 10px;
font-size: 17px;
color: #1e3a8a;
}
.form-row {
margin-bottom: 14px;
}
.form-row label {
display: block;
font-weight: bold;
font-size: 13px;
margin-bottom: 4px;
}
.form-row input {
width: 100%;
padding: 8px;
font-size: 13px;
border: 1px solid #ccc;
border-radius: 5px;
box-sizing: border-box;
}
.api-block {
border-top: 1px solid #e3e7f1;
margin-top: 25px;
padding-top: 18px;
}
.api-name {
font-weight: bold;
font-size: 15px;
margin-bottom: 8px;
color: #2560de;
padding: 4px 8px;
background: #eef3fc;
border-left: 4px solid #2560de;
border-radius: 4px;
}
.param-group {
margin-top: 12px;
padding-left: 12px;
border-left: 3px solid #e0e8f8;
margin-bottom: 14px;
}
.param-group h4 {
font-size: 13px;
margin-bottom: 8px;
color: #444;
}
.btn-row {
display: flex;
justify-content: flex-end;
gap: 10px;
margin-top: 20px;
}
button {
padding: 8px 18px;
font-size: 14px;
border-radius: 5px;
cursor: pointer;
border: 1px solid #ccc;
}
#saveBtn {
background-color: #2560de;
color: white;
border: none;
}
#resetBtn {
background: #f8f8f8;
}
.desc {
font-size: 13px;
color: #666;
margin-top: 4px;
}
</style>
</head>
<body>
<div class="back-link" id="backToPopup">← 返回主界面</div>
<h2>插件设置</h2>
<div class="section">
<h3>通用设置</h3>
<div class="form-row">
<label for="tokenExpireHours">Token 有效期(小时,最大 168</label>
<input id="tokenExpireHours" type="number" min="1" max="168" />
<div class="desc">超出有效期将要求重新登录</div>
</div>
</div>
<div class="section" id="endpointSection">
<h3>接口配置</h3>
<!-- 动态插入接口配置 -->
</div>
<div class="btn-row">
<button id="resetBtn">恢复默认</button>
<button id="saveBtn">保存设置</button>
</div>
<script src="../scripts/config.js"></script>
<script src="../scripts/settings.js"></script>
</body>
</html>