mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-09-22 11:13:26 +00:00
fix: acknowledge alert button not updating count (addresses #380)
- Fixed reactivity issue with alertStats computation in SolidJS - Properly access store values to ensure count updates when alerts are acknowledged - Changed from Object.values() to mapping over keys for proper store reactivity
This commit is contained in:
@@ -732,7 +732,9 @@ function OverviewTab(props: {
|
||||
|
||||
// Get alert stats from actual active alerts
|
||||
const alertStats = createMemo(() => {
|
||||
const alerts = Object.values(props.activeAlerts);
|
||||
// Access the store properly for reactivity
|
||||
const alertIds = Object.keys(props.activeAlerts);
|
||||
const alerts = alertIds.map(id => props.activeAlerts[id]);
|
||||
return {
|
||||
active: alerts.filter(a => !a.acknowledged).length,
|
||||
acknowledged: alerts.filter(a => a.acknowledged).length,
|
||||
|
||||
Reference in New Issue
Block a user