This commit is contained in:
Ty Clifford
2026-06-30 12:39:17 -04:00
parent 0fe5a92f90
commit 17ebaf21a3
18 changed files with 1789 additions and 143 deletions
+23 -24
View File
@@ -2,47 +2,46 @@
declare(strict_types=1);
require __DIR__ . '/../app/bootstrap.php';
app_db();
$pdo = app_db();
$pageTitle = 'Nutrition Tracking | Neon Health Tracker';
$activePage = 'nutrition';
$pageTitle = 'Medicine Catalog | Neon Medical Tracker';
$activePage = 'medicines';
$medicines = db_all($pdo, 'SELECT * FROM medication_catalog ORDER BY generic_name');
$photo = 'https://upload.wikimedia.org/wikipedia/commons/thumb/4/4f/A_large_mixed_salad.jpg/1024px-A_large_mixed_salad.jpg';
require __DIR__ . '/partials/site-header.php';
?>
<main>
<section class="detail-hero reverse">
<figure>
<img src="<?= htmlspecialchars($photo, ENT_QUOTES) ?>" alt="Large mixed salad with vegetables and protein">
<img src="<?= htmlspecialchars($photo, ENT_QUOTES) ?>" alt="Large mixed salad">
<figcaption>
Photo: <a href="https://commons.wikimedia.org/wiki/File:A_large_mixed_salad.jpg">A large mixed salad</a>
by Jmabel, <a href="https://creativecommons.org/licenses/by-sa/4.0/">CC BY-SA 4.0</a>.
</figcaption>
</figure>
<div>
<p class="site-eyebrow">Targets vs actuals</p>
<h1>Keep nutrition flexible without losing the plan.</h1>
<p>Set daily, weekly, or monthly goals for calories, protein, carbs, fat, and hydration. Log actual intake separately so deviations stay visible instead of buried.</p>
<a class="site-primary" href="/signup.php">Start a nutrition plan</a>
<p class="site-eyebrow">Medicine catalog</p>
<h1>Track medicines with source links beside every catalog entry.</h1>
<p>The starter catalog includes common medicines and links each one to RxNorm, MedlinePlus, PubMed, and ClinicalTrials.gov searches.</p>
<a class="site-primary" href="/tracker.php">Open medical tracker</a>
</div>
</section>
<section class="detail-grid">
<article>
<h2>Separate goals</h2>
<p>Nutrition goals can be attached to routines or kept independent for users who want to experiment.</p>
</article>
<article>
<h2>Macro balance</h2>
<p>Progress bars show how far actual logs are from the chosen target for the current planner range.</p>
</article>
<article>
<h2>Hydration</h2>
<p>Water targets stay beside macros so recovery and performance habits remain part of the daily flow.</p>
</article>
<article>
<h2>Range scaling</h2>
<p>Use daily, weekly, or monthly target scopes, with daily goals scaling when a broader target is not set.</p>
</article>
<?php foreach ($medicines as $medicine): ?>
<article>
<h2><?= htmlspecialchars(ucfirst($medicine['generic_name']), ENT_QUOTES) ?></h2>
<p><strong><?= htmlspecialchars($medicine['class_name'], ENT_QUOTES) ?></strong></p>
<p><?= htmlspecialchars($medicine['common_use'], ENT_QUOTES) ?></p>
<p><?= htmlspecialchars($medicine['tracking_note'], ENT_QUOTES) ?></p>
<div class="source-links">
<a href="<?= htmlspecialchars($medicine['rxnorm_url'], ENT_QUOTES) ?>">RxNorm</a>
<a href="<?= htmlspecialchars($medicine['medlineplus_url'], ENT_QUOTES) ?>">MedlinePlus</a>
<a href="<?= htmlspecialchars($medicine['pubmed_url'], ENT_QUOTES) ?>">PubMed</a>
<a href="<?= htmlspecialchars($medicine['clinicaltrials_url'], ENT_QUOTES) ?>">Studies</a>
</div>
</article>
<?php endforeach; ?>
</section>
</main>
<?php require __DIR__ . '/partials/site-footer.php'; ?>