ChatGS / templates /command.html
sharmamohit8624's picture
Upload 2395 files
829f2ca verified
<!-- <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CHATGS + Exhibition Robot</title>
<link rel="icon" href="๐Ÿš€" type="image/icon type">
<link rel="stylesheet" type="text/css" href="/static/styles.css">
</head>
<body>
<div class="top-nav">
<h3 style="font-size: 40px;margin:auto;">Face Recognition</h3>
</div>
<nav class="nav">
<img class="nav-img" src="{{ url_for('static', filename='assets/NRSC.png') }}" alt="NRSC-ISRO logo">
<ul>
<li class="active"><a href="/" style="padding: 12px;">Home</a></li>
<br>
<li class="about"><a href="/about">About</a></li>
<br>
<li class="info"><a href="/info">Reservoirs Info</a></li>
<br>
<li class="qr"><a href="/qr">QR Scanner</a></li>
<br>
<li class="command"><a href="/command">Face Recognition</a></li>
<br>
<li class="tutorial"><a href="/voiceassistant">Voice Assistant</a></li>
</ul>
</nav>
<div class="center-container">
<!-- <div class="video-container">
<video autoplay muted loop id="background-video">
<source src="{{ url_for('static', filename='assets/video.mp4') }}" type="video/mp4">
Your browser does not support the video tag.
</video>
</div> -->
<!--
<img id="video_feed" src="{{ url_for('video_feed') }}" width="800" height="600">
<h2 id="recognized-name"></h2>
<img id="recognized" alt="Recognizing..." width="640" height="480">
<div class="conclusion-container">
<p id="response"></p>
</div>
<audio id="conversation" style="display: none;" autoplay controls></audio>
</div>
<script src="/static/command.js"></script>
<script>
document.getElementById('stop-video').addEventListener('click', async () => {
await fetch('/stop_video_feed', { method: 'GET' });
alert('Video feed stopped');
});
</script>
</body>
</html> --> -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CHATGS</title>
<link rel="icon" href="๐Ÿš€" type="image/icon type">
<link rel="stylesheet" type="text/css" href="/static/styles.css">
</head>
<body>
<div class="top-nav">
<h3 style="font-size: 40px;margin:auto;">Face Recognition</h3>
</div>
<nav class="nav">
<img class="nav-img" src="{{ url_for('static', filename='assets/NRSC.png') }}" alt="NRSC-ISRO logo">
<ul>
<li class="active" id="stop-video"><a href="/" style="padding: 12px;">Home</a></li>
<br>
<li class="about" id="stop-video"><a href="/about">About</a></li>
<br>
<li class="info" id="stop-video"><a href="/info">Reservoirs Info</a></li>
<br>
<li class="qr" id="stop-video"><a href="/qr">QR Scanner</a></li>
<br>
<li class="command" id="stop-video"><a href="/command">Face Recognition</a></li>
<br>
<li class="tutorial" id="stop-video"><a href="/voiceassistant">Voice Assistant</a></li><br>
<li class="climatemap" id="stop-video"><a href="/climatemap">Climate Map</a></li>
</ul>
</nav>
<div class="center-container">
<!-- <div class="video-container">
<video autoplay muted loop id="background-video">
<source src="{{ url_for('static', filename='assets/video.mp4') }}" type="video/mp4">
Your browser does not support the video tag.
</video>
</div> -->
<img id="video_feed" src="{{ url_for('video_feed') }}" width="800" height="600">
<h2 id="recognized-name"></h2>
<img id="recognized" alt="Recognizing..." width="640" height="480">
<div class="conclusion-container">
<p id="response"></p>
</div>
<audio id="conversation" autoplay controls></audio>
</div>
<script src="/static/command.js"></script>
<script>
// Select all the links inside the nav
const navLinks = document.querySelectorAll('.nav a');
// Add click event listener to each link
navLinks.forEach(link => {
link.addEventListener('click', async (event) => {
// Prevent the default link action
event.preventDefault();
// Send a request to stop the video feed
await fetch('/stop_video_feed', { method: 'GET' });
// After stopping the video feed, navigate to the clicked link's destination
window.location.href = event.target.href;
});
});
</script>
</body>
</html>