feat: add food detail pages for OFF and custom meal sources
Extend the nutrition detail page to support OpenFoodFacts items (looked up by barcode) and custom meals (with ingredient breakdown). All food diary cards and search results now link to detail pages regardless of source.
This commit is contained in:
@@ -434,7 +434,7 @@
|
||||
</div>
|
||||
<span class="fs-result-cal">{item.calories}<small> kcal</small></span>
|
||||
</button>
|
||||
{#if showDetailLinks && (item.source === 'bls' || item.source === 'usda')}
|
||||
{#if showDetailLinks && (item.source === 'bls' || item.source === 'usda' || item.source === 'off')}
|
||||
<a class="fs-detail-link" href="/fitness/{s.nutrition}/food/{item.source}/{item.id}" aria-label="View details">
|
||||
<ExternalLink size={13} />
|
||||
</a>
|
||||
|
||||
Reference in New Issue
Block a user