feat: monthly stats panel in rotating insight banner (closes #100)
- Add PHP action 'monthly_stats' + getMonthlyStats() function: items consumed/added/wasted this month, trend vs prev month, top 5 categories and top 3 products by transaction count - Expand insight rotation from 2 → 3 phases (waste → nutrition → monthly) - Add _renderMonthlyStatsSection() following nutrition section styling: large indigo number, trend arrow with %, horizontal category bars animated on show, badges for added/wasted/top-product - Add ms-* CSS classes (bar chart layout matching nutr-* design) - Add stats_monthly translations in it/en/de/fr/es (10 keys each)
This commit is contained in:
+2
-1
@@ -169,10 +169,11 @@
|
||||
<div id="expired-list"></div>
|
||||
</div>
|
||||
|
||||
<!-- Anti-Waste Report Card + Nutrition Analysis (alternating, content rendered by JS) -->
|
||||
<!-- Anti-Waste Report Card + Nutrition Analysis + Monthly Stats (alternating, content rendered by JS) -->
|
||||
<div id="dashboard-insight-wrap" style="position:relative">
|
||||
<div id="waste-chart-section" style="display:none"></div>
|
||||
<div id="nutrition-section" style="display:none"></div>
|
||||
<div id="monthly-stats-section" style="display:none"></div>
|
||||
</div>
|
||||
|
||||
<!-- Alert for soonest expiring items -->
|
||||
|
||||
Reference in New Issue
Block a user