Files
kanban/public/index.html
Gahow Wang 74279b9d35 feat: add frontend dashboard, login page and portal entry
Public directory contains the Kanban SPA with dashboard UI, login
page, and styles. Portal directory provides a standalone service
entry page with CSS styling.
2026-05-15 11:13:59 +08:00

119 lines
4.8 KiB
HTML

<!doctype html>
<html lang="zh-CN">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Local Kanban</title>
<link rel="stylesheet" href="/styles.css?v=20260514">
</head>
<body>
<div class="bg-glow" aria-hidden="true"></div>
<main class="shell">
<header class="topbar">
<div class="brand">
<div class="brand-mark" aria-hidden="true">LK</div>
<div>
<h1>Local Kanban</h1>
<p id="subtitle" class="muted">GPU · 额度 · 项目 · Agent</p>
</div>
</div>
<div class="top-actions">
<button id="refreshButton" type="button" class="icon-button" title="刷新" aria-label="刷新">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 12a9 9 0 0 1 15.36-6.36L21 8"/><path d="M21 3v5h-5"/><path d="M21 12a9 9 0 0 1-15.36 6.36L3 16"/><path d="M3 21v-5h5"/></svg>
</button>
<button id="logoutButton" type="button" class="ghost-button">退出</button>
</div>
</header>
<div id="errorBanner" class="error-banner" hidden></div>
<section class="grid dashboard-grid">
<section class="panel span-2">
<div class="panel-heading">
<div class="panel-title">
<h2>GPU</h2>
<span id="gpuSummary" class="badge"></span>
</div>
</div>
<div class="gpu-hosts-row">
<div id="gpuHostsChips" class="gpu-hosts-chips"></div>
<button id="hostAddTrigger" type="button" class="host-add-button" title="添加机器">
<span aria-hidden="true">+</span>
<span>添加</span>
</button>
<form id="hostAddForm" class="host-add-form" hidden>
<input id="hostAddInput" type="text" placeholder="主机名" autocomplete="off" spellcheck="false">
<button type="submit" class="primary-button small">添加</button>
<button id="hostAddCancel" type="button" class="link-button">取消</button>
</form>
</div>
<div id="gpuBoard" class="gpu-board"></div>
</section>
<section class="panel">
<div class="panel-heading">
<div class="panel-title">
<h2>AI 额度</h2>
<span id="quotaSummary" class="badge"></span>
</div>
</div>
<div id="quotaBoard" class="quota-board"></div>
</section>
</section>
<section class="grid work-grid">
<section class="panel project-panel">
<div class="panel-heading">
<div class="panel-title">
<h2>项目</h2>
<span id="repoSummary" class="badge"></span>
</div>
</div>
<div id="repoBoard" class="repo-board"></div>
</section>
<section class="panel agent-panel">
<div class="panel-heading">
<div class="panel-title">
<h2>Agent</h2>
<span id="taskSummary" class="badge"></span>
</div>
</div>
<div id="agentContext" class="agent-context">
<span class="agent-context-label">当前项目</span>
<span id="agentContextRepo" class="agent-context-repo">未选择</span>
<span id="agentContextBranch" class="chip" hidden></span>
</div>
<form id="taskForm" class="task-form">
<div class="task-controls">
<label class="select-field">
<span class="field-label">Branch</span>
<select id="branchSelect" required></select>
</label>
<label class="select-field">
<span class="field-label">AI 配置</span>
<select id="profileSelect" required></select>
</label>
<label class="select-field">
<span class="field-label">历史 Session</span>
<select id="resumeTaskSelect"></select>
</label>
</div>
<label class="prompt-field">
<span class="field-label">命令</span>
<textarea id="promptInput" rows="5" required placeholder="输入要交给 agent 的任务"></textarea>
</label>
<div class="form-actions">
<button id="startTaskButton" type="submit" class="primary-button">启动任务</button>
<button id="resumeTaskButton" type="button" class="secondary-button">继续 Session</button>
</div>
</form>
<div id="taskBoard" class="task-board"></div>
</section>
</section>
</main>
<div id="toastHost" class="toast-host" aria-live="polite"></div>
<script type="module" src="/app.js?v=20260514"></script>
</body>
</html>