feat: initial Tauri desktop shell for BatchTube v1.0
This commit is contained in:
BIN
backend/web/app.js
Normal file
BIN
backend/web/app.js
Normal file
Binary file not shown.
265
backend/web/index.html
Normal file
265
backend/web/index.html
Normal file
@@ -0,0 +1,265 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>YouTube SIPOC Tool</title>
|
||||
<link rel="stylesheet" href="/style.css" />
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<!-- ═══════════════════════════ HEADER ═══════════════════════════ -->
|
||||
<header class="app-header">
|
||||
<div class="app-logo">
|
||||
<svg width="28" height="28" viewBox="0 0 24 24" fill="currentColor">
|
||||
<path d="M19.59 6.69a4.83 4.83 0 01-3.77-4.25V2h-3.45v13.67a2.89 2.89 0 01-2.88 2.5 2.89 2.89 0 01-2.89-2.89 2.89 2.89 0 012.89-2.89c.28 0 .54.04.79.1V9.01a6.33 6.33 0 00-.79-.05 6.34 6.34 0 00-6.34 6.34 6.34 6.34 0 006.34 6.34 6.34 6.34 0 006.33-6.34v-7a8.15 8.15 0 004.77 1.52v-3.4a4.85 4.85 0 01-1-.09z"/>
|
||||
</svg>
|
||||
<span class="app-title">YouTube <span>SIPOC</span></span>
|
||||
</div>
|
||||
<nav class="header-nav">
|
||||
<button class="nav-btn active" onclick="showView('jobs')" id="nav-jobs">Jobs</button>
|
||||
<button class="nav-btn" onclick="showView('new')" id="nav-new">+ New Job</button>
|
||||
<button class="nav-btn" onclick="showView('settings')" id="nav-settings">⚙ Settings</button>
|
||||
</nav>
|
||||
</header>
|
||||
|
||||
<div class="app-body">
|
||||
|
||||
<!-- ═══════════════════════ SIDEBAR ═══════════════════════ -->
|
||||
<aside class="sidebar">
|
||||
<div class="sidebar-section">
|
||||
<button class="new-job-btn" onclick="showView('new')">
|
||||
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><line x1="12" y1="5" x2="12" y2="19"/><line x1="5" y1="12" x2="19" y2="12"/></svg>
|
||||
New Extraction Job
|
||||
</button>
|
||||
</div>
|
||||
<div class="sidebar-section" style="flex:1; overflow-y:auto; border-bottom:none;">
|
||||
<div class="sidebar-label">Recent Jobs</div>
|
||||
<div class="job-list" id="sidebar-job-list">
|
||||
<div class="text-muted" style="font-size:12px;padding:8px 4px;">No jobs yet</div>
|
||||
</div>
|
||||
</div>
|
||||
</aside>
|
||||
|
||||
<!-- ═══════════════════════ MAIN CONTENT ═══════════════════════ -->
|
||||
<main class="main-content">
|
||||
|
||||
<!-- ─── VIEW: NEW JOB ─── -->
|
||||
<div id="view-new" class="hidden">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="var(--accent)" stroke-width="2"><circle cx="12" cy="12" r="10"/><line x1="12" y1="8" x2="12" y2="16"/><line x1="8" y1="12" x2="16" y2="12"/></svg>
|
||||
<div>
|
||||
<div class="card-title">New Extraction Job</div>
|
||||
<div class="card-subtitle">Configure YouTube source and what to extract</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Input Type -->
|
||||
<div class="form-group">
|
||||
<label class="form-label">Input Type</label>
|
||||
<div class="type-pills">
|
||||
<div class="type-pill selected" data-type="url" onclick="selectInputType('url')">🔗 Single URL</div>
|
||||
<div class="type-pill" data-type="playlist" onclick="selectInputType('playlist')">📋 Playlist</div>
|
||||
<div class="type-pill" data-type="handle" onclick="selectInputType('handle')">👤 Channel Handle</div>
|
||||
<div class="type-pill" data-type="csv" onclick="selectInputType('csv')">📄 CSV List</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Input Value -->
|
||||
<div class="form-group" id="input-url-group">
|
||||
<label class="form-label" id="input-label">YouTube URL</label>
|
||||
<input type="text" class="form-input" id="input-value"
|
||||
placeholder="https://www.youtube.com/watch?v=..." />
|
||||
</div>
|
||||
|
||||
<!-- CSV textarea (only shown for csv type) -->
|
||||
<div class="form-group hidden" id="input-csv-group">
|
||||
<label class="form-label">CSV / List of URLs (one per line or comma-separated)</label>
|
||||
<textarea class="form-textarea" id="input-csv-value" rows="5"
|
||||
placeholder="https://youtu.be/abc123 https://youtu.be/xyz456 dQw4w9WgXcQ"></textarea>
|
||||
</div>
|
||||
|
||||
<hr class="divider" />
|
||||
|
||||
<!-- Artifact Selection -->
|
||||
<div class="form-group">
|
||||
<label class="form-label">What to Extract (select all that apply)</label>
|
||||
<div class="artifact-grid" id="artifact-grid">
|
||||
<!-- populated by JS -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr class="divider" />
|
||||
|
||||
<!-- Output Folder -->
|
||||
<div class="form-group">
|
||||
<label class="form-label">Output Folder</label>
|
||||
<div class="folder-display" id="folder-display" onclick="openFolderBrowser()">
|
||||
<span>📁</span>
|
||||
<span class="folder-path" id="folder-path-text">Click to choose a folder…</span>
|
||||
</div>
|
||||
<input type="hidden" id="output-folder" value="" />
|
||||
</div>
|
||||
|
||||
<!-- Resolution (shown only when mp4 selected) -->
|
||||
<div class="form-group hidden" id="resolution-group">
|
||||
<label class="form-label">MP4 Resolution</label>
|
||||
<select class="form-select" id="resolution">
|
||||
<option value="best">Best Available</option>
|
||||
<option value="2160">4K (2160p)</option>
|
||||
<option value="1440">2K (1440p)</option>
|
||||
<option value="1080" selected>1080p</option>
|
||||
<option value="720">720p</option>
|
||||
<option value="480">480p</option>
|
||||
<option value="360">360p</option>
|
||||
<option value="240">240p</option>
|
||||
<option value="144">144p</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<!-- Bot Avoidance Delays -->
|
||||
<div class="form-group">
|
||||
<label class="form-label">Random Delay Between Downloads (seconds, for bot detection avoidance)</label>
|
||||
<div class="range-row">
|
||||
<div class="form-group" style="margin:0">
|
||||
<label class="form-label" style="font-size:11px">Min Delay</label>
|
||||
<input type="number" class="form-input" id="delay-min" value="2" min="0" max="60" step="0.5" style="width:100px" />
|
||||
</div>
|
||||
<div class="form-group" style="margin:0">
|
||||
<label class="form-label" style="font-size:11px">Max Delay</label>
|
||||
<input type="number" class="form-input" id="delay-max" value="7" min="0" max="120" step="0.5" style="width:100px" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr class="divider" />
|
||||
|
||||
<!-- API Settings -->
|
||||
<div class="form-group">
|
||||
<label class="form-label">OpenRouter API Key <span class="text-muted">(required for summaries)</span></label>
|
||||
<input type="password" class="form-input" id="api-key"
|
||||
placeholder="sk-or-v1-..." autocomplete="off" />
|
||||
<div style="font-size:11px;color:var(--text-muted);margin-top:4px;">
|
||||
Not stored — only used for this session's summary requests
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="form-label">OpenRouter Model</label>
|
||||
<input type="text" class="form-input" id="or-model"
|
||||
value="openai/gpt-4o-mini"
|
||||
placeholder="openai/gpt-4o-mini" />
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="form-label">Summary Prompt <span class="text-muted">(leave blank for default)</span></label>
|
||||
<textarea class="form-textarea" id="summary-prompt" rows="3"
|
||||
placeholder="Custom system prompt for LLM summarization (optional)…"></textarea>
|
||||
</div>
|
||||
|
||||
<div class="btn-row">
|
||||
<button class="btn btn-primary" onclick="createJob()" id="create-btn">
|
||||
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><polyline points="5 12 12 5 19 12"/><polyline points="12 19 12 5"/></svg>
|
||||
Start Extraction
|
||||
</button>
|
||||
<button class="btn btn-outline" onclick="showView('jobs')">Cancel</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- ─── VIEW: JOB DETAIL ─── -->
|
||||
<div id="view-jobs">
|
||||
<div id="job-detail">
|
||||
<!-- Welcome / empty state -->
|
||||
<div class="empty-state">
|
||||
<div class="empty-state-icon">🎬</div>
|
||||
<div class="empty-state-title">YouTube SIPOC Tool</div>
|
||||
<div class="empty-state-body">
|
||||
Extract titles, stats, transcripts, summaries, thumbnails, MP3, and MP4 from YouTube videos.<br/><br/>
|
||||
Click <strong>+ New Job</strong> to get started.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- ─── VIEW: SETTINGS ─── -->
|
||||
<div id="view-settings" class="hidden">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="card-title">⚙ Settings & Defaults</div>
|
||||
<div class="card-subtitle">These defaults are used when creating new jobs</div>
|
||||
</div>
|
||||
<div class="settings-grid">
|
||||
<div class="form-group">
|
||||
<label class="form-label">Default Delay Min (s)</label>
|
||||
<input type="number" class="form-input" id="s-delay-min" value="2" min="0" />
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="form-label">Default Delay Max (s)</label>
|
||||
<input type="number" class="form-input" id="s-delay-max" value="7" min="0" />
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="form-label">Default MP4 Resolution</label>
|
||||
<select class="form-select" id="s-resolution">
|
||||
<option value="best">Best</option>
|
||||
<option value="1080" selected>1080p</option>
|
||||
<option value="720">720p</option>
|
||||
<option value="480">480p</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="form-label">Default OpenRouter Model</label>
|
||||
<input type="text" class="form-input" id="s-model" value="openai/gpt-4o-mini" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="form-label">Default Summary Prompt</label>
|
||||
<textarea class="form-textarea" id="s-prompt" rows="4"></textarea>
|
||||
</div>
|
||||
<div class="btn-row">
|
||||
<button class="btn btn-blue" onclick="saveSettings()">Save Defaults</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<div class="card-title">🔌 MCP Server Registration</div>
|
||||
<div class="card-subtitle">Add this to your MCP settings to use with AI agents</div>
|
||||
</div>
|
||||
<pre id="mcp-config-snippet" style="background:var(--bg);border:1px solid var(--border);border-radius:4px;padding:14px;font-size:12px;color:var(--text-dim);overflow-x:auto;white-space:pre-wrap;word-break:break-all;"></pre>
|
||||
<div class="mt-8">
|
||||
<button class="btn btn-outline btn-sm" onclick="copyMcpConfig()">📋 Copy to Clipboard</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</main>
|
||||
</div>
|
||||
|
||||
<!-- ═══════════════════════ FOLDER BROWSER MODAL ═══════════════════════ -->
|
||||
<div class="modal-overlay hidden" id="folder-modal">
|
||||
<div class="modal" style="max-width:600px">
|
||||
<div class="modal-title">📁 Choose Output Folder</div>
|
||||
<div style="margin-bottom:10px;">
|
||||
<div class="input-with-btn">
|
||||
<input type="text" class="form-input" id="folder-modal-path" placeholder="Type path or browse below…" />
|
||||
<button class="btn btn-blue btn-sm" onclick="navigateToTyped()">Go</button>
|
||||
<button class="btn btn-outline btn-sm" onclick="createNewFolder()">+ New Folder</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="folder-current" id="folder-current-path"></div>
|
||||
<div class="folder-browser" id="folder-browser-list"></div>
|
||||
<div class="btn-row mt-16">
|
||||
<button class="btn btn-green" onclick="selectCurrentFolder()">✔ Select This Folder</button>
|
||||
<button class="btn btn-outline" onclick="closeFolderModal()">Cancel</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- ═══════════════════════ TOAST CONTAINER ═══════════════════════ -->
|
||||
<div class="toast-container" id="toast-container"></div>
|
||||
|
||||
<script src="/app.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
778
backend/web/style.css
Normal file
778
backend/web/style.css
Normal file
@@ -0,0 +1,778 @@
|
||||
/* ============================================================
|
||||
YouTube SIPOC Tool - Dark Mode UI
|
||||
============================================================ */
|
||||
|
||||
:root {
|
||||
--bg: #0f0f0f;
|
||||
--bg2: #1a1a1a;
|
||||
--bg3: #242424;
|
||||
--bg4: #2e2e2e;
|
||||
--border: #3a3a3a;
|
||||
--text: #e8e8e8;
|
||||
--text-dim: #888;
|
||||
--text-muted: #555;
|
||||
--accent: #ff4444;
|
||||
--accent2: #cc2222;
|
||||
--blue: #4a9eff;
|
||||
--green: #22cc66;
|
||||
--yellow: #ffcc00;
|
||||
--orange: #ff8822;
|
||||
--purple: #9966ff;
|
||||
--red: #ff4444;
|
||||
--radius: 8px;
|
||||
--radius-sm: 4px;
|
||||
--shadow: 0 4px 20px rgba(0,0,0,0.4);
|
||||
--font: 'Segoe UI', system-ui, -apple-system, sans-serif;
|
||||
--font-mono: 'Cascadia Code', 'Fira Code', 'Consolas', monospace;
|
||||
}
|
||||
|
||||
* { box-sizing: border-box; margin: 0; padding: 0; }
|
||||
|
||||
body {
|
||||
font-family: var(--font);
|
||||
background: var(--bg);
|
||||
color: var(--text);
|
||||
font-size: 14px;
|
||||
line-height: 1.5;
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
/* ── Layout ───────────────────────────────────────────────── */
|
||||
|
||||
.app-header {
|
||||
background: var(--bg2);
|
||||
border-bottom: 1px solid var(--border);
|
||||
padding: 0 24px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 16px;
|
||||
height: 56px;
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
.app-logo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.app-logo svg { color: var(--accent); }
|
||||
|
||||
.app-title {
|
||||
font-size: 18px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
letter-spacing: -0.3px;
|
||||
}
|
||||
|
||||
.app-title span { color: var(--accent); }
|
||||
|
||||
.header-nav {
|
||||
display: flex;
|
||||
gap: 4px;
|
||||
margin-left: auto;
|
||||
}
|
||||
|
||||
.nav-btn {
|
||||
background: none;
|
||||
border: 1px solid transparent;
|
||||
color: var(--text-dim);
|
||||
padding: 6px 14px;
|
||||
border-radius: var(--radius-sm);
|
||||
cursor: pointer;
|
||||
font-size: 13px;
|
||||
transition: all 0.15s;
|
||||
}
|
||||
.nav-btn:hover { background: var(--bg3); color: var(--text); border-color: var(--border); }
|
||||
.nav-btn.active { background: var(--bg3); color: var(--text); border-color: var(--border); }
|
||||
|
||||
.app-body {
|
||||
display: flex;
|
||||
min-height: calc(100vh - 56px);
|
||||
}
|
||||
|
||||
/* Sidebar */
|
||||
.sidebar {
|
||||
width: 260px;
|
||||
background: var(--bg2);
|
||||
border-right: 1px solid var(--border);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.sidebar-section {
|
||||
padding: 12px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
}
|
||||
|
||||
.sidebar-label {
|
||||
font-size: 10px;
|
||||
font-weight: 700;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.8px;
|
||||
color: var(--text-muted);
|
||||
margin-bottom: 8px;
|
||||
padding: 0 4px;
|
||||
}
|
||||
|
||||
.job-list { display: flex; flex-direction: column; gap: 4px; }
|
||||
|
||||
.job-item {
|
||||
padding: 8px 10px;
|
||||
border-radius: var(--radius-sm);
|
||||
cursor: pointer;
|
||||
transition: background 0.12s;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
.job-item:hover { background: var(--bg3); }
|
||||
.job-item.active { background: var(--bg3); border-color: var(--border); }
|
||||
|
||||
.job-item-title {
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
color: var(--text);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.job-item-meta {
|
||||
font-size: 11px;
|
||||
color: var(--text-dim);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.new-job-btn {
|
||||
width: 100%;
|
||||
background: var(--accent);
|
||||
color: #fff;
|
||||
border: none;
|
||||
padding: 9px;
|
||||
border-radius: var(--radius-sm);
|
||||
cursor: pointer;
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 6px;
|
||||
transition: background 0.15s;
|
||||
}
|
||||
.new-job-btn:hover { background: var(--accent2); }
|
||||
|
||||
/* Main content */
|
||||
.main-content {
|
||||
flex: 1;
|
||||
overflow-y: auto;
|
||||
padding: 24px;
|
||||
max-width: 1100px;
|
||||
}
|
||||
|
||||
/* ── Cards & Panels ──────────────────────────────────────── */
|
||||
|
||||
.card {
|
||||
background: var(--bg2);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius);
|
||||
padding: 20px;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.card-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
margin-bottom: 16px;
|
||||
padding-bottom: 12px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
}
|
||||
|
||||
.card-title {
|
||||
font-size: 15px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
}
|
||||
|
||||
.card-subtitle {
|
||||
font-size: 12px;
|
||||
color: var(--text-dim);
|
||||
margin-top: 1px;
|
||||
}
|
||||
|
||||
/* ── Form Controls ────────────────────────────────────────── */
|
||||
|
||||
.form-group {
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.form-label {
|
||||
display: block;
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
color: var(--text-dim);
|
||||
margin-bottom: 6px;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.4px;
|
||||
}
|
||||
|
||||
.form-input,
|
||||
.form-select,
|
||||
.form-textarea {
|
||||
width: 100%;
|
||||
background: var(--bg3);
|
||||
border: 1px solid var(--border);
|
||||
color: var(--text);
|
||||
padding: 8px 12px;
|
||||
border-radius: var(--radius-sm);
|
||||
font-family: var(--font);
|
||||
font-size: 13px;
|
||||
transition: border-color 0.15s;
|
||||
outline: none;
|
||||
}
|
||||
.form-input:focus,
|
||||
.form-select:focus,
|
||||
.form-textarea:focus { border-color: var(--blue); }
|
||||
.form-textarea { resize: vertical; min-height: 80px; }
|
||||
.form-input.error { border-color: var(--red); }
|
||||
|
||||
.input-with-btn {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
}
|
||||
.input-with-btn .form-input { flex: 1; }
|
||||
|
||||
/* Type pills */
|
||||
.type-pills {
|
||||
display: flex;
|
||||
gap: 6px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.type-pill {
|
||||
padding: 5px 12px;
|
||||
border-radius: 20px;
|
||||
border: 1px solid var(--border);
|
||||
background: var(--bg3);
|
||||
color: var(--text-dim);
|
||||
font-size: 12px;
|
||||
cursor: pointer;
|
||||
transition: all 0.15s;
|
||||
user-select: none;
|
||||
}
|
||||
.type-pill:hover { border-color: var(--blue); color: var(--text); }
|
||||
.type-pill.selected { background: var(--blue); border-color: var(--blue); color: #fff; }
|
||||
|
||||
/* Artifact checkboxes */
|
||||
.artifact-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.artifact-check {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
padding: 8px 12px;
|
||||
background: var(--bg3);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-sm);
|
||||
cursor: pointer;
|
||||
transition: all 0.15s;
|
||||
user-select: none;
|
||||
}
|
||||
.artifact-check:hover { border-color: var(--blue); }
|
||||
.artifact-check.checked { border-color: var(--green); background: rgba(34,204,102,0.08); }
|
||||
.artifact-check input { display: none; }
|
||||
|
||||
.artifact-icon { font-size: 16px; width: 20px; text-align: center; }
|
||||
.artifact-label { font-size: 12px; font-weight: 600; color: var(--text); }
|
||||
|
||||
/* Range inputs */
|
||||
.range-row {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
}
|
||||
.range-row .form-group { flex: 1; }
|
||||
|
||||
/* Folder picker */
|
||||
.folder-display {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
padding: 8px 12px;
|
||||
background: var(--bg3);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-sm);
|
||||
font-size: 13px;
|
||||
color: var(--text-dim);
|
||||
font-family: var(--font-mono);
|
||||
cursor: pointer;
|
||||
transition: border-color 0.15s;
|
||||
min-height: 36px;
|
||||
}
|
||||
.folder-display:hover { border-color: var(--blue); }
|
||||
.folder-display .folder-path { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
|
||||
|
||||
/* ── Buttons ──────────────────────────────────────────────── */
|
||||
|
||||
.btn {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 8px 16px;
|
||||
border-radius: var(--radius-sm);
|
||||
border: 1px solid transparent;
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
cursor: pointer;
|
||||
transition: all 0.15s;
|
||||
font-family: var(--font);
|
||||
}
|
||||
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
|
||||
|
||||
.btn-primary { background: var(--accent); color: #fff; }
|
||||
.btn-primary:hover:not(:disabled) { background: var(--accent2); }
|
||||
|
||||
.btn-blue { background: var(--blue); color: #fff; }
|
||||
.btn-blue:hover:not(:disabled) { background: #3a8ee0; }
|
||||
|
||||
.btn-green { background: var(--green); color: #000; }
|
||||
.btn-green:hover:not(:disabled) { background: #1ab055; }
|
||||
|
||||
.btn-outline {
|
||||
background: transparent;
|
||||
border-color: var(--border);
|
||||
color: var(--text-dim);
|
||||
}
|
||||
.btn-outline:hover:not(:disabled) { border-color: var(--text-dim); color: var(--text); }
|
||||
|
||||
.btn-danger { background: rgba(255,68,68,0.15); border-color: var(--red); color: var(--red); }
|
||||
.btn-danger:hover:not(:disabled) { background: rgba(255,68,68,0.25); }
|
||||
|
||||
.btn-sm { padding: 5px 10px; font-size: 12px; }
|
||||
|
||||
.btn-row {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
/* ── Status Badges ────────────────────────────────────────── */
|
||||
|
||||
.badge {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
padding: 2px 8px;
|
||||
border-radius: 20px;
|
||||
font-size: 11px;
|
||||
font-weight: 700;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.4px;
|
||||
}
|
||||
|
||||
.badge-running { background: rgba(74,158,255,0.15); color: var(--blue); border: 1px solid rgba(74,158,255,0.3); }
|
||||
.badge-done { background: rgba(34,204,102,0.15); color: var(--green); border: 1px solid rgba(34,204,102,0.3); }
|
||||
.badge-done_with_errors { background: rgba(255,136,34,0.15); color: var(--orange); border: 1px solid rgba(255,136,34,0.3); }
|
||||
.badge-failed { background: rgba(255,68,68,0.15); color: var(--red); border: 1px solid rgba(255,68,68,0.3); }
|
||||
.badge-paused { background: rgba(255,204,0,0.15); color: var(--yellow); border: 1px solid rgba(255,204,0,0.3); }
|
||||
.badge-stopped { background: rgba(136,136,136,0.15); color: var(--text-dim); border: 1px solid var(--border); }
|
||||
.badge-pending { background: rgba(153,102,255,0.15); color: var(--purple); border: 1px solid rgba(153,102,255,0.3); }
|
||||
|
||||
/* Artifact status */
|
||||
.art-dot {
|
||||
display: inline-block;
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-radius: 50%;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
.art-dot-done { background: var(--green); }
|
||||
.art-dot-failed { background: var(--red); box-shadow: 0 0 4px var(--red); }
|
||||
.art-dot-running { background: var(--blue); animation: pulse 1s infinite; }
|
||||
.art-dot-pending { background: var(--border); }
|
||||
.art-dot-skipped { background: var(--text-muted); }
|
||||
|
||||
@keyframes pulse {
|
||||
0%, 100% { opacity: 1; }
|
||||
50% { opacity: 0.4; }
|
||||
}
|
||||
|
||||
/* ── Progress ─────────────────────────────────────────────── */
|
||||
|
||||
.progress-bar {
|
||||
width: 100%;
|
||||
height: 6px;
|
||||
background: var(--bg4);
|
||||
border-radius: 3px;
|
||||
overflow: hidden;
|
||||
margin: 8px 0;
|
||||
}
|
||||
.progress-fill {
|
||||
height: 100%;
|
||||
border-radius: 3px;
|
||||
background: var(--blue);
|
||||
transition: width 0.4s ease;
|
||||
}
|
||||
.progress-fill.green { background: var(--green); }
|
||||
.progress-fill.yellow { background: var(--yellow); }
|
||||
.progress-fill.red { background: var(--red); }
|
||||
|
||||
.stats-row {
|
||||
display: flex;
|
||||
gap: 16px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.stat-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 2px;
|
||||
}
|
||||
.stat-value {
|
||||
font-size: 22px;
|
||||
font-weight: 700;
|
||||
color: var(--text);
|
||||
line-height: 1;
|
||||
}
|
||||
.stat-label {
|
||||
font-size: 11px;
|
||||
color: var(--text-muted);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
/* ── Video Table ──────────────────────────────────────────── */
|
||||
|
||||
.video-table-wrap {
|
||||
overflow-x: auto;
|
||||
border-radius: var(--radius-sm);
|
||||
border: 1px solid var(--border);
|
||||
}
|
||||
|
||||
.video-table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.video-table th {
|
||||
text-align: left;
|
||||
padding: 10px 12px;
|
||||
background: var(--bg3);
|
||||
color: var(--text-muted);
|
||||
font-size: 11px;
|
||||
font-weight: 700;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.5px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.video-table td {
|
||||
padding: 10px 12px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.video-table tr:last-child td { border-bottom: none; }
|
||||
.video-table tr:hover td { background: rgba(255,255,255,0.02); }
|
||||
.video-table tr.active-row td { background: rgba(74,158,255,0.06); }
|
||||
|
||||
.video-title-cell {
|
||||
max-width: 300px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.video-id-badge {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 11px;
|
||||
color: var(--text-muted);
|
||||
background: var(--bg3);
|
||||
padding: 2px 6px;
|
||||
border-radius: 3px;
|
||||
}
|
||||
|
||||
.artifact-pills {
|
||||
display: flex;
|
||||
gap: 4px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.art-pill {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 3px;
|
||||
padding: 2px 7px;
|
||||
border-radius: 10px;
|
||||
font-size: 11px;
|
||||
font-weight: 600;
|
||||
border: 1px solid var(--border);
|
||||
background: var(--bg3);
|
||||
color: var(--text-muted);
|
||||
white-space: nowrap;
|
||||
}
|
||||
.art-pill-done { border-color: rgba(34,204,102,0.4); background: rgba(34,204,102,0.08); color: var(--green); }
|
||||
.art-pill-failed { border-color: rgba(255,68,68,0.4); background: rgba(255,68,68,0.08); color: var(--red); }
|
||||
.art-pill-running { border-color: rgba(74,158,255,0.4); background: rgba(74,158,255,0.08); color: var(--blue); }
|
||||
.art-pill-pending { color: var(--text-muted); }
|
||||
|
||||
/* ── Log Panel ────────────────────────────────────────────── */
|
||||
|
||||
.log-panel {
|
||||
background: var(--bg);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-sm);
|
||||
height: 300px;
|
||||
overflow-y: auto;
|
||||
font-family: var(--font-mono);
|
||||
font-size: 12px;
|
||||
padding: 12px;
|
||||
}
|
||||
|
||||
.log-entry {
|
||||
display: flex;
|
||||
gap: 10px;
|
||||
padding: 2px 0;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
.log-ts { color: var(--text-muted); flex-shrink: 0; }
|
||||
.log-level { flex-shrink: 0; font-weight: 700; min-width: 40px; }
|
||||
.log-level-INFO { color: var(--blue); }
|
||||
.log-level-WARN { color: var(--yellow); }
|
||||
.log-level-ERROR { color: var(--red); }
|
||||
.log-level-DEBUG { color: var(--text-muted); }
|
||||
.log-msg { color: var(--text-dim); word-break: break-all; }
|
||||
|
||||
/* ── Modal ────────────────────────────────────────────────── */
|
||||
|
||||
.modal-overlay {
|
||||
position: fixed;
|
||||
inset: 0;
|
||||
background: rgba(0,0,0,0.7);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
z-index: 999;
|
||||
backdrop-filter: blur(4px);
|
||||
}
|
||||
|
||||
.modal {
|
||||
background: var(--bg2);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius);
|
||||
padding: 24px;
|
||||
width: 90%;
|
||||
max-width: 520px;
|
||||
max-height: 80vh;
|
||||
overflow-y: auto;
|
||||
box-shadow: var(--shadow);
|
||||
}
|
||||
|
||||
.modal-title {
|
||||
font-size: 16px;
|
||||
font-weight: 700;
|
||||
margin-bottom: 16px;
|
||||
color: var(--text);
|
||||
}
|
||||
|
||||
/* Folder browser */
|
||||
.folder-browser {
|
||||
background: var(--bg3);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-sm);
|
||||
max-height: 320px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.folder-entry {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
padding: 8px 12px;
|
||||
cursor: pointer;
|
||||
border-bottom: 1px solid var(--border);
|
||||
transition: background 0.1s;
|
||||
font-size: 13px;
|
||||
}
|
||||
.folder-entry:last-child { border-bottom: none; }
|
||||
.folder-entry:hover { background: var(--bg4); }
|
||||
.folder-entry.is-file { color: var(--text-muted); cursor: default; }
|
||||
.folder-entry .entry-icon { width: 18px; text-align: center; font-size: 15px; }
|
||||
|
||||
.folder-current {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 11px;
|
||||
color: var(--text-dim);
|
||||
padding: 8px 12px;
|
||||
border-bottom: 1px solid var(--border);
|
||||
background: var(--bg4);
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
/* ── Toast Notifications ─────────────────────────────────── */
|
||||
|
||||
.toast-container {
|
||||
position: fixed;
|
||||
bottom: 24px;
|
||||
right: 24px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 8px;
|
||||
z-index: 9999;
|
||||
}
|
||||
|
||||
.toast {
|
||||
background: var(--bg3);
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-sm);
|
||||
padding: 12px 16px;
|
||||
min-width: 260px;
|
||||
max-width: 400px;
|
||||
box-shadow: var(--shadow);
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
gap: 10px;
|
||||
animation: slide-in 0.2s ease;
|
||||
}
|
||||
.toast.success { border-left: 3px solid var(--green); }
|
||||
.toast.error { border-left: 3px solid var(--red); }
|
||||
.toast.info { border-left: 3px solid var(--blue); }
|
||||
.toast-msg { font-size: 13px; color: var(--text); flex: 1; }
|
||||
|
||||
@keyframes slide-in {
|
||||
from { transform: translateX(20px); opacity: 0; }
|
||||
to { transform: translateX(0); opacity: 1; }
|
||||
}
|
||||
|
||||
/* ── Settings ─────────────────────────────────────────────── */
|
||||
|
||||
.settings-grid {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 12px;
|
||||
}
|
||||
@media (max-width: 600px) { .settings-grid { grid-template-columns: 1fr; } }
|
||||
|
||||
/* ── Empty States ─────────────────────────────────────────── */
|
||||
|
||||
.empty-state {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 60px 24px;
|
||||
text-align: center;
|
||||
gap: 12px;
|
||||
color: var(--text-muted);
|
||||
}
|
||||
.empty-state-icon { font-size: 48px; }
|
||||
.empty-state-title { font-size: 16px; font-weight: 700; color: var(--text-dim); }
|
||||
.empty-state-body { font-size: 13px; max-width: 360px; }
|
||||
|
||||
/* ── Misc ─────────────────────────────────────────────────── */
|
||||
|
||||
.divider {
|
||||
border: none;
|
||||
border-top: 1px solid var(--border);
|
||||
margin: 16px 0;
|
||||
}
|
||||
|
||||
.section-title {
|
||||
font-size: 13px;
|
||||
font-weight: 700;
|
||||
color: var(--text-dim);
|
||||
margin-bottom: 12px;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
.text-muted { color: var(--text-muted); }
|
||||
.text-dim { color: var(--text-dim); }
|
||||
.text-green { color: var(--green); }
|
||||
.text-red { color: var(--red); }
|
||||
.text-blue { color: var(--blue); }
|
||||
.text-yellow { color: var(--yellow); }
|
||||
|
||||
.monospace { font-family: var(--font-mono); }
|
||||
|
||||
.flex-row { display: flex; align-items: center; gap: 8px; }
|
||||
.flex-1 { flex: 1; }
|
||||
.mt-8 { margin-top: 8px; }
|
||||
.mt-16 { margin-top: 16px; }
|
||||
.mb-8 { margin-bottom: 8px; }
|
||||
|
||||
.hidden { display: none !important; }
|
||||
|
||||
/* Spinner */
|
||||
.spinner {
|
||||
display: inline-block;
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
border: 2px solid rgba(255,255,255,0.2);
|
||||
border-top-color: #fff;
|
||||
border-radius: 50%;
|
||||
animation: spin 0.7s linear infinite;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
@keyframes spin { to { transform: rotate(360deg); } }
|
||||
|
||||
/* ── Job Control Bar ──────────────────────────────────────── */
|
||||
|
||||
.job-controls {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
padding: 12px 0;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.current-video-info {
|
||||
flex: 1;
|
||||
font-size: 12px;
|
||||
color: var(--text-dim);
|
||||
font-family: var(--font-mono);
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
/* Scrollbar */
|
||||
::-webkit-scrollbar { width: 6px; height: 6px; }
|
||||
::-webkit-scrollbar-track { background: var(--bg); }
|
||||
::-webkit-scrollbar-thumb { background: var(--bg4); border-radius: 3px; }
|
||||
::-webkit-scrollbar-thumb:hover { background: var(--border); }
|
||||
|
||||
/* View tabs */
|
||||
.view-tabs {
|
||||
display: flex;
|
||||
gap: 0;
|
||||
border-bottom: 1px solid var(--border);
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
.view-tab {
|
||||
padding: 8px 16px;
|
||||
background: none;
|
||||
border: none;
|
||||
color: var(--text-muted);
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
cursor: pointer;
|
||||
border-bottom: 2px solid transparent;
|
||||
margin-bottom: -1px;
|
||||
transition: all 0.15s;
|
||||
}
|
||||
.view-tab:hover { color: var(--text); }
|
||||
.view-tab.active { color: var(--blue); border-bottom-color: var(--blue); }
|
||||
Reference in New Issue
Block a user