From 3112354d619a95aad5ff4d20e6de25bfbe52be0b Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Wed, 4 Dec 2024 10:15:43 +0700 Subject: [PATCH] Reconstructing segments when the donut data changes This restores functionality to the donut, which is currently broken on Live. I'm not sure how this was ever working updating the view when the data changes, but my guess is that the callers were destroying and recreating the component whenever the data changed, avoiding this issue. I would imagine it's better practice to not require this. --- .../src/xforge-common/donut-chart/donut-chart.component.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/SIL.XForge.Scripture/ClientApp/src/xforge-common/donut-chart/donut-chart.component.ts b/src/SIL.XForge.Scripture/ClientApp/src/xforge-common/donut-chart/donut-chart.component.ts index 006e89d7e9..a856e1d616 100644 --- a/src/SIL.XForge.Scripture/ClientApp/src/xforge-common/donut-chart/donut-chart.component.ts +++ b/src/SIL.XForge.Scripture/ClientApp/src/xforge-common/donut-chart/donut-chart.component.ts @@ -96,6 +96,7 @@ export class DonutChartComponent extends SubscriptionDisposable implements After this.oldData = this._data; } this._data = value; + this.constructSegments(); } }