150 lines
8.0 KiB
HTML
150 lines
8.0 KiB
HTML
<!DOCTYPE html>
|
|
<html data-bs-theme="light" lang="en">
|
|
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
|
|
<title>{% block title %}Yaris OBD{% endblock %}</title>
|
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
<link href="https://fonts.googleapis.com/css2?family=Racing+Sans+One&display=swap" rel="stylesheet">
|
|
<link rel="stylesheet" href="{{ url_for('static', filename='bootstrap/css/bootstrap.min.css') }}">
|
|
<link rel="stylesheet" href="{{ url_for('static', filename='yaris.css') }}">
|
|
<link rel="stylesheet" href="{{ url_for('static', filename='fonts/fontawesome-all.min.css') }}">
|
|
{% block styles %}{% endblock %}
|
|
</head>
|
|
|
|
<body id="page-top">
|
|
|
|
{# ── Desktop sidebar ─────────────────────────────────────────────────── #}
|
|
<nav id="app-sidebar" class="app-sidebar d-none d-md-flex flex-column">
|
|
<a class="sidebar-brand" href="{{ url_for('index') }}" aria-label="Home">
|
|
<span class="sidebar-brand-logo">YARIS-OBD</span>
|
|
</a>
|
|
<hr class="sidebar-divider">
|
|
<ul class="nav flex-column flex-grow-1">
|
|
<li class="nav-item">
|
|
<a class="nav-link{% if request.endpoint == 'index' %} active{% endif %}" href="{{ url_for('index') }}">
|
|
<i class="fas fa-tachometer-alt fa-fw"></i><span>Dashboard</span>
|
|
</a>
|
|
</li>
|
|
<li class="nav-item">
|
|
<a class="nav-link{% if request.endpoint == 'dash' %} active{% endif %}" href="{{ url_for('dash') }}">
|
|
<i class="fas fa-video fa-fw"></i><span>Dashcam</span>
|
|
</a>
|
|
</li>
|
|
<li class="nav-item">
|
|
<a class="nav-link{% if request.endpoint == 'history' %} active{% endif %}" href="{{ url_for('history') }}">
|
|
<i class="fas fa-route fa-fw"></i><span>Trip history</span>
|
|
</a>
|
|
</li>
|
|
<li class="nav-item">
|
|
<a class="nav-link{% if request.endpoint == 'dtc' %} active{% endif %}" href="{{ url_for('dtc') }}">
|
|
<i class="fas fa-exclamation-triangle fa-fw"></i><span>DTC</span>
|
|
</a>
|
|
</li>
|
|
<li class="nav-item">
|
|
<a class="nav-link{% if request.endpoint == 'status_page' %} active{% endif %}" href="{{ url_for('status_page') }}">
|
|
<i class="fas fa-heartbeat fa-fw"></i><span>Status</span>
|
|
</a>
|
|
</li>
|
|
<li class="nav-item">
|
|
<a class="nav-link{% if request.endpoint == 'settings' %} active{% endif %}" href="{{ url_for('settings') }}">
|
|
<i class="fas fa-cog fa-fw"></i><span>Settings</span>
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
<button class="sidebar-collapse-btn" id="sidebarToggle" type="button" aria-label="Collapse sidebar">
|
|
<i class="fas fa-chevron-left"></i>
|
|
</button>
|
|
</nav>
|
|
|
|
{# ── Main content area ────────────────────────────────────────────────── #}
|
|
<div id="content-wrapper">
|
|
|
|
{# Top bar #}
|
|
<nav class="topbar navbar navbar-light bg-white shadow-sm">
|
|
<div class="container-fluid px-3 gap-2">
|
|
{# Mobile: logo on left #}
|
|
<a class="navbar-brand d-flex d-md-none align-items-center gap-2 text-decoration-none" href="{{ url_for('index') }}">
|
|
<span class="sidebar-brand-logo" style="font-size:1.2rem;color:#fff;">YARIS-OBD</span>
|
|
</a>
|
|
<div class="ms-auto d-flex align-items-center gap-2">
|
|
<div class="dropdown">
|
|
<button class="btn btn-link position-relative p-2" id="alert-toggle" type="button"
|
|
data-bs-toggle="dropdown" aria-expanded="false" aria-label="System alerts">
|
|
<i class="fas fa-bell fa-fw text-secondary"></i>
|
|
<span id="alert-count" class="position-absolute badge rounded-pill bg-danger" style="top:2px;right:2px;font-size:.6rem;min-width:1.1em;padding:.2em .35em;" hidden></span>
|
|
</button>
|
|
<div class="dropdown-menu dropdown-menu-end shadow" id="alert-menu" aria-labelledby="alert-toggle">
|
|
<h6 class="dropdown-header">System alerts</h6>
|
|
<div id="alert-notifications">
|
|
<div class="dropdown-item-text text-muted small">Loading…</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<span class="text-muted small d-none d-sm-inline">{{ account.name }}</span>
|
|
<img class="rounded-circle border" style="width:2rem;height:2rem;object-fit:cover;"
|
|
src="{{ url_for('static', filename=account.avatar_path) }}" alt="">
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
|
|
<main class="container-fluid px-3 px-md-4 main-content">
|
|
{% block content %}{% endblock %}
|
|
</main>
|
|
|
|
<footer class="bg-white border-top text-center py-3 small text-muted d-none d-md-block">
|
|
© vroom vroom yaris de course 2023
|
|
<span class="mx-1">·</span>
|
|
<a href="https://github.com/quoije/yaris-obd" class="text-muted text-decoration-none" target="_blank" rel="noopener" title="GitHub repository">
|
|
<i class="fab fa-github fa-fw"></i> GitHub
|
|
</a>
|
|
</footer>
|
|
</div>
|
|
|
|
{# ── Mobile bottom navigation bar ─────────────────────────────────────── #}
|
|
<nav class="mobile-bottom-nav d-flex d-md-none" aria-label="Main navigation">
|
|
<a class="mobile-nav-item{% if request.endpoint == 'index' %} active{% endif %}" href="{{ url_for('index') }}">
|
|
<i class="fas fa-tachometer-alt"></i>
|
|
<span>Dashboard</span>
|
|
</a>
|
|
<a class="mobile-nav-item{% if request.endpoint == 'dash' %} active{% endif %}" href="{{ url_for('dash') }}">
|
|
<i class="fas fa-video"></i>
|
|
<span>Dashcam</span>
|
|
</a>
|
|
<a class="mobile-nav-item{% if request.endpoint == 'history' %} active{% endif %}" href="{{ url_for('history') }}">
|
|
<i class="fas fa-route"></i>
|
|
<span>History</span>
|
|
</a>
|
|
<a class="mobile-nav-item{% if request.endpoint == 'dtc' %} active{% endif %}" href="{{ url_for('dtc') }}">
|
|
<i class="fas fa-exclamation-triangle"></i>
|
|
<span>DTC</span>
|
|
</a>
|
|
<a class="mobile-nav-item{% if request.endpoint == 'status_page' %} active{% endif %}" href="{{ url_for('status_page') }}">
|
|
<i class="fas fa-heartbeat"></i>
|
|
<span>Status</span>
|
|
</a>
|
|
<a class="mobile-nav-item{% if request.endpoint == 'settings' %} active{% endif %}" href="{{ url_for('settings') }}">
|
|
<i class="fas fa-cog"></i>
|
|
<span>Settings</span>
|
|
</a>
|
|
</nav>
|
|
|
|
<script src="{{ url_for('static', filename='bootstrap/js/bootstrap.min.js') }}"></script>
|
|
<script src="{{ url_for('static', filename='js/bs-init.js') }}"></script>
|
|
<script src="{{ url_for('static', filename='js/theme.js') }}"></script>
|
|
<script src="{{ url_for('static', filename='js/data-list.js') }}"></script>
|
|
<script src="{{ url_for('static', filename='js/alerts.js') }}"></script>
|
|
|
|
{# ── Shared confirmation helper ────────────────────────────────────────── #}
|
|
<script>
|
|
window.confirmDelete = function(message) {
|
|
return Promise.resolve(window.confirm(message));
|
|
};
|
|
</script>
|
|
{% block scripts %}{% endblock %}
|
|
</body>
|
|
|
|
</html>
|