Adds a green footer (matching nav colour) to all authenticated pages with a "Created by: CHNS.tech" link and a styled BMC button. CSP updated to allow buymeacoffee CDN domains. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
97 lines
3.5 KiB
HTML
97 lines
3.5 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Log Eggs — Yolkbook</title>
|
|
<link rel="icon" href="/favicon.svg" type="image/svg+xml">
|
|
<link rel="stylesheet" href="/css/style.css">
|
|
</head>
|
|
<body>
|
|
<nav class="nav">
|
|
<a class="nav-brand" href="/">🥚 <span>Yolkbook</span></a>
|
|
<ul class="nav-links">
|
|
<li><a href="/">Dashboard</a></li>
|
|
<li><a href="/log">Log Eggs</a></li>
|
|
<li><a href="/flock">Flock</a></li>
|
|
<li><a href="/budget">Budget</a></li>
|
|
<li><a href="/summary">Summary</a></li>
|
|
</ul>
|
|
</nav>
|
|
|
|
<main class="container">
|
|
<h1>Log Eggs</h1>
|
|
|
|
<div class="card">
|
|
<div id="msg" class="message"></div>
|
|
<form id="log-form">
|
|
<div class="form-grid">
|
|
<div class="form-group">
|
|
<label for="date">Date</label>
|
|
<input type="date" id="date" required>
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="eggs">Eggs Collected</label>
|
|
<input type="number" id="eggs" min="0" required placeholder="0">
|
|
</div>
|
|
<div class="form-group span-full">
|
|
<label for="notes">Notes (optional)</label>
|
|
<textarea id="notes" placeholder="Anything worth noting…"></textarea>
|
|
</div>
|
|
<div class="form-group">
|
|
<button type="submit" class="btn btn-primary">Save Entry</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
<!-- Date filter -->
|
|
<div class="card">
|
|
<div class="filter-bar">
|
|
<div class="form-group">
|
|
<label for="filter-start">From</label>
|
|
<input type="date" id="filter-start">
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="filter-end">To</label>
|
|
<input type="date" id="filter-end">
|
|
</div>
|
|
<button class="btn btn-primary" onclick="loadHistory()">Filter</button>
|
|
<button class="btn btn-ghost" onclick="clearFilter()">Clear</button>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="section-header">
|
|
<span class="text-muted" id="result-count"></span>
|
|
</div>
|
|
|
|
<div class="table-wrap">
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Date</th>
|
|
<th>Eggs</th>
|
|
<th>Notes</th>
|
|
<th></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody id="history-body">
|
|
<tr class="empty-row"><td colspan="4">Loading…</td></tr>
|
|
</tbody>
|
|
<tfoot id="history-foot"></tfoot>
|
|
</table>
|
|
</div>
|
|
</main>
|
|
|
|
<footer class="site-footer">
|
|
Created by: <a href="https://chns.tech" target="_blank" rel="noopener noreferrer">CHNS.tech</a>
|
|
<a href="https://www.buymeacoffee.com/CHNS" target="_blank" rel="noopener noreferrer" class="bmc-btn">🎉 Buy me an energy drink</a>
|
|
</footer>
|
|
|
|
<script src="/js/api.js?v=4"></script>
|
|
<script src="/js/auth.js?v=4"></script>
|
|
<script src="/js/log.js?v=4"></script>
|
|
<script src="/js/history.js?v=4"></script>
|
|
</body>
|
|
</html>
|