fix: 更新当前界面,支持多公帐号切换
This commit is contained in:
47
app/templates/auth.html
Normal file
47
app/templates/auth.html
Normal file
@@ -0,0 +1,47 @@
|
||||
<!doctype html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>{{ app_name }} - 登录注册</title>
|
||||
<link rel="icon" type="image/svg+xml" href="/static/favicon.svg?v=20260406a" />
|
||||
<link rel="stylesheet" href="/static/style.css?v=20260410a" />
|
||||
</head>
|
||||
<body class="simple-page">
|
||||
<main class="simple-wrap">
|
||||
<section class="panel simple-panel">
|
||||
<h2>登录 / 注册</h2>
|
||||
<p class="muted small">登录后将跳转到编辑主页。</p>
|
||||
|
||||
<div class="grid2">
|
||||
<div>
|
||||
<label>用户名</label>
|
||||
<input id="username" type="text" placeholder="请输入用户名" />
|
||||
</div>
|
||||
<div>
|
||||
<label>密码</label>
|
||||
<input id="password" type="password" placeholder="请输入密码(至少 6 位)" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="check-row">
|
||||
<label class="check-label">
|
||||
<input id="rememberMe" type="checkbox" checked />
|
||||
<span>7 天内免登录(限时)</span>
|
||||
</label>
|
||||
<a class="subtle-link" href="/auth/forgot">忘记密码?</a>
|
||||
</div>
|
||||
|
||||
<div class="actions">
|
||||
<button id="loginBtn" class="primary" type="button">登录</button>
|
||||
<button id="registerBtn" class="secondary" type="button">注册</button>
|
||||
</div>
|
||||
<p id="status" class="status"></p>
|
||||
</section>
|
||||
</main>
|
||||
|
||||
<script>
|
||||
window.__NEXT_PATH__ = {{ next|tojson }};
|
||||
</script>
|
||||
<script src="/static/auth.js?v=20260410a"></script>
|
||||
</body>
|
||||
</html>
|
||||
42
app/templates/forgot_password.html
Normal file
42
app/templates/forgot_password.html
Normal file
@@ -0,0 +1,42 @@
|
||||
<!doctype html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>{{ app_name }} - 忘记密码</title>
|
||||
<link rel="icon" type="image/svg+xml" href="/static/favicon.svg?v=20260406a" />
|
||||
<link rel="stylesheet" href="/static/style.css?v=20260410a" />
|
||||
</head>
|
||||
<body class="simple-page">
|
||||
<main class="simple-wrap">
|
||||
<section class="panel simple-panel">
|
||||
<h2>忘记密码</h2>
|
||||
|
||||
<div class="grid2">
|
||||
<div>
|
||||
<label>用户名</label>
|
||||
<input id="username" type="text" placeholder="请输入账号用户名" />
|
||||
</div>
|
||||
<div>
|
||||
<label>重置码</label>
|
||||
<input id="resetKey" type="password" placeholder="请输入管理员提供的重置码" />
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<label>新密码</label>
|
||||
<input id="newPassword" type="password" placeholder="请输入新密码(至少 6 位)" />
|
||||
</div>
|
||||
<p class="muted small">请向管理员获取重置码。若未改配置,默认重置码为 x2ws-reset-2026(建议尽快修改)。</p>
|
||||
<div class="actions">
|
||||
<button id="resetBtn" class="primary" type="button">重置密码</button>
|
||||
</div>
|
||||
<p id="status" class="status"></p>
|
||||
<div class="actions">
|
||||
<a class="subtle-link" href="/auth?next=/">返回登录页</a>
|
||||
<a class="subtle-link" href="/settings">去设置页</a>
|
||||
</div>
|
||||
</section>
|
||||
</main>
|
||||
<script src="/static/forgot_password.js?v=20260410b"></script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -5,7 +5,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>{{ app_name }}</title>
|
||||
<link rel="icon" type="image/svg+xml" href="/static/favicon.svg?v=20260406a" />
|
||||
<link rel="stylesheet" href="/static/style.css?v=20260406a" />
|
||||
<link rel="stylesheet" href="/static/style.css?v=20260410d" />
|
||||
</head>
|
||||
<body>
|
||||
<header class="topbar">
|
||||
@@ -13,7 +13,15 @@
|
||||
<h1>{{ app_name }}</h1>
|
||||
<p class="muted">从原文到公众号草稿,一页完成编辑、封面和发布。</p>
|
||||
</div>
|
||||
<div class="badge">编辑台</div>
|
||||
<div class="topbar-actions">
|
||||
<div class="wechat-account-switch" title="草稿发布、封面上传均使用此处选中的公众号">
|
||||
<label for="wechatAccountSelect" class="wechat-account-label">发表主体</label>
|
||||
<select id="wechatAccountSelect" class="topbar-select" aria-label="切换公众号"></select>
|
||||
<span id="wechatAccountStatus" class="muted small wechat-account-status" aria-live="polite"></span>
|
||||
</div>
|
||||
<a class="subtle-link" href="/settings">公众号设置</a>
|
||||
<button id="logoutBtn" class="subtle-btn topbar-btn" type="button">退出登录</button>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main class="layout">
|
||||
@@ -33,16 +41,49 @@
|
||||
<label>标题提示</label>
|
||||
<input id="titleHint" type="text" placeholder="如:AI Agent 商业化路径" />
|
||||
</div>
|
||||
<div>
|
||||
<label>目标读者</label>
|
||||
<input id="audience" type="text" value="公众号运营者/产品经理" />
|
||||
<div class="multi-field">
|
||||
<div class="field-head">
|
||||
<label>目标读者</label>
|
||||
<span class="meta">下拉多选</span>
|
||||
</div>
|
||||
<details class="multi-dropdown" id="audienceDetails">
|
||||
<summary>
|
||||
<span class="multi-dropdown-text" id="audienceSummary"></span>
|
||||
</summary>
|
||||
<div class="multi-dropdown-body" role="group" aria-label="目标读者选项">
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="audienceChip" value="公众号运营者" checked />公众号运营者</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="audienceChip" value="产品经理" checked />产品经理</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="audienceChip" value="技术开发者" />技术开发者</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="audienceChip" value="创业者" />创业者</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="audienceChip" value="学生与研究者" />学生与研究者</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="audienceChip" value="普通读者" />普通读者</label>
|
||||
</div>
|
||||
</details>
|
||||
<input id="audienceExtra" type="text" class="multi-extra" placeholder="其他补充(可选)" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid2">
|
||||
<div>
|
||||
<label>语气风格</label>
|
||||
<input id="tone" type="text" value="专业、有观点、口语自然" />
|
||||
<div class="multi-field">
|
||||
<div class="field-head">
|
||||
<label>语气风格</label>
|
||||
<span class="meta">下拉多选</span>
|
||||
</div>
|
||||
<details class="multi-dropdown" id="toneDetails">
|
||||
<summary>
|
||||
<span class="multi-dropdown-text" id="toneSummary"></span>
|
||||
</summary>
|
||||
<div class="multi-dropdown-body" role="group" aria-label="语气风格选项">
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="专业严谨" checked />专业严谨</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="有观点" checked />有观点</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="口语自然" checked />口语自然</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="轻松幽默" />轻松幽默</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="故事化叙事" />故事化叙事</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="科普解读" />科普解读</label>
|
||||
<label class="multi-dropdown-option"><input type="checkbox" name="toneChip" value="理性克制" />理性克制</label>
|
||||
</div>
|
||||
</details>
|
||||
<input id="toneExtra" type="text" class="multi-extra" placeholder="其他补充(可选)" />
|
||||
</div>
|
||||
<div>
|
||||
<label>避免词汇</label>
|
||||
@@ -102,6 +143,6 @@
|
||||
</main>
|
||||
|
||||
<script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"></script>
|
||||
<script src="/static/app.js?v=20260406a"></script>
|
||||
<script src="/static/app.js?v=20260410d"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
67
app/templates/settings.html
Normal file
67
app/templates/settings.html
Normal file
@@ -0,0 +1,67 @@
|
||||
<!doctype html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>{{ app_name }} - 公众号设置</title>
|
||||
<link rel="icon" type="image/svg+xml" href="/static/favicon.svg?v=20260406a" />
|
||||
<link rel="stylesheet" href="/static/style.css?v=20260410a" />
|
||||
</head>
|
||||
<body class="simple-page">
|
||||
<main class="simple-wrap">
|
||||
<section class="panel simple-panel">
|
||||
<div class="panel-head">
|
||||
<h2>公众号设置</h2>
|
||||
<p class="muted small">支持绑定多个公众号并切换当前发布账号。</p>
|
||||
</div>
|
||||
|
||||
<div class="grid2">
|
||||
<div>
|
||||
<label>当前账号</label>
|
||||
<select id="accountSelect"></select>
|
||||
</div>
|
||||
<div class="actions-inline">
|
||||
<a class="subtle-link" href="/">返回主页</a>
|
||||
<button id="logoutBtn" class="subtle-btn topbar-btn" type="button">退出登录</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3 class="section-title">新增公众号</h3>
|
||||
<div class="grid2">
|
||||
<div>
|
||||
<label>账号名</label>
|
||||
<input id="accountName" type="text" placeholder="如:公司主号 / 客户A号" />
|
||||
</div>
|
||||
<div>
|
||||
<label>AppID</label>
|
||||
<input id="appid" type="text" placeholder="请输入公众号 AppID" />
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<label>Secret</label>
|
||||
<input id="secret" type="password" placeholder="请输入公众号 Secret" />
|
||||
</div>
|
||||
<button id="bindBtn" class="primary" type="button">绑定并设为当前账号</button>
|
||||
|
||||
<h3 class="section-title">账号安全</h3>
|
||||
<div class="grid2">
|
||||
<div>
|
||||
<label>当前密码</label>
|
||||
<input id="oldPassword" type="password" placeholder="请输入当前密码" />
|
||||
</div>
|
||||
<div>
|
||||
<label>新密码</label>
|
||||
<input id="newPassword" type="password" placeholder="请输入新密码(至少 6 位)" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="actions-inline">
|
||||
<a class="subtle-link" href="/auth/forgot">忘记密码提示</a>
|
||||
<button id="changePwdBtn" class="secondary topbar-btn" type="button">修改密码</button>
|
||||
</div>
|
||||
<p id="status" class="status"></p>
|
||||
</section>
|
||||
</main>
|
||||
|
||||
<script src="/static/settings.js?v=20260410a"></script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user