f7280be523
- Updated manifest to v1.1.0 with additional permissions (scripting, host_permissions) - Added web clipping context menu items (Clip Full Page, Clip Selection) - Enhanced background.js with PDF conversion using Chrome's printToPDF API - Updated content.js to capture full page HTML and selected content - Added new capture.js script for page capture utilities - Enhanced popup UI with mode toggle between "Send URL" and "Clip Page" - Added support for clipping full pages or selected content to PDF - Updated CSS for new mode buttons and clip section layout Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
78 lines
3.1 KiB
HTML
78 lines
3.1 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>DocuElevate</title>
|
|
<link rel="stylesheet" href="popup.css">
|
|
</head>
|
|
<body>
|
|
<div class="container">
|
|
<div class="header">
|
|
<img src="../icons/icon48.png" alt="DocuElevate" class="logo">
|
|
<h1>DocuElevate</h1>
|
|
</div>
|
|
|
|
<div id="config-section" class="section">
|
|
<h2>Configuration</h2>
|
|
<div class="form-group">
|
|
<label for="server-url">DocuElevate Server URL:</label>
|
|
<input type="url" id="server-url" placeholder="https://docuelevate.example.com" required>
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="session-cookie">Session Cookie (optional):</label>
|
|
<input type="text" id="session-cookie" placeholder="session=your_session_value">
|
|
<small>Required if authentication is enabled</small>
|
|
</div>
|
|
<button id="save-config" class="btn btn-primary">Save Configuration</button>
|
|
</div>
|
|
|
|
<div id="mode-section" class="section hidden">
|
|
<h2>Select Mode</h2>
|
|
<div class="mode-buttons">
|
|
<button id="mode-url" class="btn btn-mode active">Send URL</button>
|
|
<button id="mode-clip" class="btn btn-mode">Clip Page</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="send-section" class="section hidden">
|
|
<h2>Send URL to DocuElevate</h2>
|
|
<div class="info-box">
|
|
<p><strong>Current URL:</strong></p>
|
|
<p id="current-url" class="url-display"></p>
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="filename">Filename (optional):</label>
|
|
<input type="text" id="filename" placeholder="Leave blank to use URL filename">
|
|
</div>
|
|
<button id="send-file" class="btn btn-primary">Send to DocuElevate</button>
|
|
<button id="show-config" class="btn btn-secondary">Change Settings</button>
|
|
</div>
|
|
|
|
<div id="clip-section" class="section hidden">
|
|
<h2>Clip Web Page</h2>
|
|
<div class="info-box">
|
|
<p><strong>Page Title:</strong></p>
|
|
<p id="page-title" class="url-display"></p>
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="clip-filename">Filename (optional):</label>
|
|
<input type="text" id="clip-filename" placeholder="Leave blank to use page title">
|
|
<small>Will be saved as PDF</small>
|
|
</div>
|
|
<div class="clip-buttons">
|
|
<button id="clip-full-page" class="btn btn-primary">Clip Full Page</button>
|
|
<button id="clip-selection" class="btn btn-primary">Clip Selection</button>
|
|
</div>
|
|
<button id="show-config-from-clip" class="btn btn-secondary">Change Settings</button>
|
|
</div>
|
|
|
|
<div id="status-section" class="section hidden">
|
|
<div id="status-message"></div>
|
|
</div>
|
|
</div>
|
|
|
|
<script src="popup.js"></script>
|
|
</body>
|
|
</html>
|