forked from external-repos/ESP32-CAM-ONVIF
88 lines
3.3 KiB
HTML
88 lines
3.3 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<title>J0X-ESP-CAM Control Panel</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<link rel="stylesheet" href="/style.css">
|
|
</head>
|
|
<body>
|
|
<div id="login-overlay" class="overlay">
|
|
<div class="login-box">
|
|
<img src="/logo.png" alt="Logo" class="logo-large">
|
|
<h2>J0X-ESP-CAM</h2>
|
|
<form id="login-form" onsubmit="return login(event)">
|
|
<input type="text" id="username" placeholder="Username" autocomplete="username" required>
|
|
<input type="password" id="password" placeholder="Password" autocomplete="current-password" required>
|
|
<button type="submit" class="btn">Login</button>
|
|
<div id="login-error" class="error"></div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
<header>
|
|
<div class="header-bar">
|
|
<img src="/logo.png" alt="Logo" class="logo-small">
|
|
<span class="brand">J0X-ESP-CAM</span>
|
|
</div>
|
|
<div class="status" id="status">Connecting...</div>
|
|
</header>
|
|
<main>
|
|
<nav class="tabs">
|
|
<button class="tab-btn active" onclick="showPanel('live')">Live</button>
|
|
<button class="tab-btn" onclick="showPanel('camera')">Camera</button>
|
|
<button class="tab-btn" onclick="showPanel('sd')">SD Card</button>
|
|
<button class="tab-btn" onclick="showPanel('system')">System</button>
|
|
</nav>
|
|
<section id="panel-live" class="panel">
|
|
<h2>Live Preview</h2>
|
|
<img id="preview" class="video-preview" src="/stream" alt="Live Stream">
|
|
<div>
|
|
<button class="btn" onclick="snapshot()">Snapshot</button>
|
|
</div>
|
|
</section>
|
|
<section id="panel-camera" class="panel" style="display:none">
|
|
<h2>Camera Controls</h2>
|
|
<label>Resolution
|
|
<select id="resolution" onchange="setConfig('resolution', this.value)">
|
|
<option value="VGA">VGA</option>
|
|
<option value="QVGA">QVGA</option>
|
|
<option value="CIF">CIF</option>
|
|
</select>
|
|
</label>
|
|
<label>Brightness
|
|
<input type="range" min="-2" max="2" step="1" value="0" onchange="setConfig('brightness', this.value)">
|
|
</label>
|
|
<label>Contrast
|
|
<input type="range" min="-2" max="2" step="1" value="0" onchange="setConfig('contrast', this.value)">
|
|
</label>
|
|
<button class="btn" onclick="setConfig('flip', 1)">Flip</button>
|
|
<button class="btn" onclick="setConfig('rotate', 1)">Rotate</button>
|
|
</section>
|
|
<section id="panel-sd" class="panel" style="display:none">
|
|
<h2>SD Card Files</h2>
|
|
<div>
|
|
<button class="btn" onclick="refreshSD()">Refresh</button>
|
|
</div>
|
|
<table id="sd-table">
|
|
<thead>
|
|
<tr><th>File Name</th><th>Size</th><th>Action</th></tr>
|
|
</thead>
|
|
<tbody></tbody>
|
|
</table>
|
|
</section>
|
|
<section id="panel-system" class="panel" style="display:none">
|
|
<h2>Network & System</h2>
|
|
<div>RTSP URL: <span id="rtspUrl"></span></div>
|
|
<div>ONVIF Service: <span id="onvifUrl"></span></div>
|
|
<button class="btn" onclick="reboot()">Reboot</button>
|
|
<button class="btn" onclick="factoryReset()">Factory Reset</button>
|
|
<div id="motionStatus">Motion: Unknown</div>
|
|
</section>
|
|
</main>
|
|
<div class="footer">
|
|
Made with <span style="color:#e25555;">❤️</span> by <a herf="https://github.com/John-Varghese-EH/">J0X</a>
|
|
</div>
|
|
<script src="/app.js"></script>
|
|
</body>
|
|
</html>
|