flow-extension/popup.html
type-two fc3e668504 feat: Prompt Mode / DL Mode split in the popup
- DL Mode button: one click harvests everything on screen (click ⋮ -> hover
  Download -> click 1K, verified per tile), click again to stop after current
  tile; no queue involved, no server reporting for manual runs
- Prompt Mode = the existing queue runner, relabelled
- harvestActive synced to storage so the popup button reflects state

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-08 09:22:06 +10:00

94 lines
3.3 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Flow Auto-Pilot</title>
<link rel="stylesheet" href="popup.css">
</head>
<body>
<div class="app-container">
<!-- Header -->
<header class="app-header">
<div class="logo-area">
<span class="logo-icon"></span>
<div class="logo-text">
<h1>Flow Auto-Pilot</h1>
<span class="subtext">Labs FX Integration</span>
</div>
</div>
<div class="status-indicator" id="global-status">
<span class="dot"></span>
<span class="status-label">Idle</span>
</div>
</header>
<!-- Main Control Panel -->
<main class="control-panel">
<!-- Connection Input -->
<div class="form-group">
<label for="server-url">Local Server URL</label>
<div class="input-with-button">
<input type="url" id="server-url" value="http://localhost:8017" placeholder="http://localhost:8017">
</div>
</div>
<!-- Action Buttons: Prompt Mode runs the queue; DL Mode grabs what's on screen -->
<div class="actions" style="display:flex;gap:8px">
<button id="toggle-btn" class="btn btn-primary start-state" style="flex:1">▶ Prompt Mode</button>
<button id="dl-btn" class="btn btn-primary start-state" style="flex:1">⬇ DL Mode</button>
</div>
<label class="form-group" style="display:flex;align-items:center;gap:8px;cursor:pointer">
<input type="checkbox" id="auto-start"> Auto-start when the Flow tab opens
</label>
<!-- Console / Activity Logs -->
<div class="console-section">
<div class="console-header">
<span>Activity Log</span>
<button id="clear-logs" class="btn-text">Clear</button>
</div>
<div class="console-body" id="log-console">
<div class="log-entry system-log">[System] Extension loaded. Click Start to begin.</div>
</div>
</div>
<!-- Collapsible Settings -->
<details class="advanced-settings">
<summary>Advanced Selector Adjustments</summary>
<div class="settings-content">
<p class="settings-info">Customize targets if the page layout changes. Leave blank for auto-detection.</p>
<div class="form-group">
<label for="sel-prompt">Prompt Input Selector</label>
<input type="text" id="sel-prompt" placeholder="Auto-detect (textarea / editable div)">
</div>
<div class="form-group">
<label for="sel-generate">Submit Button Selector</label>
<input type="text" id="sel-generate" placeholder="Auto-detect (→ arrow / send)">
</div>
<div class="form-group">
<label for="sel-model">Results / Media Selector</label>
<input type="text" id="sel-model" placeholder="Auto-detect (media library container)">
</div>
<div class="form-group">
<label for="poll-interval">Polling Interval (ms)</label>
<input type="number" id="poll-interval" value="4000" min="1000" step="500">
</div>
</div>
</details>
</main>
<!-- Footer -->
<footer class="app-footer">
<span>Active Tab Automation</span>
<span class="version">v1.0.0</span>
</footer>
</div>
<script src="popup.js"></script>
</body>
</html>