@eric-emg/symphiq-components 1.2.260 → 1.2.261
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -59344,7 +59344,7 @@ class InitialTargetSettingComponent {
|
|
|
59344
59344
|
return revenueMetric?.value ? parseFloat(revenueMetric.value) : 0;
|
|
59345
59345
|
}, ...(ngDevMode ? [{ debugName: "currentPaceProjection" }] : []));
|
|
59346
59346
|
this.gapToClose = computed(() => {
|
|
59347
|
-
const target = this.
|
|
59347
|
+
const target = this.displayedTargetRevenue();
|
|
59348
59348
|
const projection = this.currentPaceProjection();
|
|
59349
59349
|
if (target === 0 || projection === 0)
|
|
59350
59350
|
return { amount: 0, percentage: 0 };
|
|
@@ -59373,7 +59373,7 @@ class InitialTargetSettingComponent {
|
|
|
59373
59373
|
return ((target - prior) / prior) * 100;
|
|
59374
59374
|
}, ...(ngDevMode ? [{ debugName: "percentageIncrease" }] : []));
|
|
59375
59375
|
this.isTargetValid = computed(() => {
|
|
59376
|
-
return this.
|
|
59376
|
+
return this.displayedTargetRevenue() > this.priorYearRevenue();
|
|
59377
59377
|
}, ...(ngDevMode ? [{ debugName: "isTargetValid" }] : []));
|
|
59378
59378
|
this.displayedMetricCalculations = computed(() => {
|
|
59379
59379
|
const targets = this.targets();
|
|
@@ -59525,9 +59525,11 @@ class InitialTargetSettingComponent {
|
|
|
59525
59525
|
}
|
|
59526
59526
|
}, { allowSignalWrites: true });
|
|
59527
59527
|
effect(() => {
|
|
59528
|
-
const
|
|
59529
|
-
const
|
|
59530
|
-
const
|
|
59528
|
+
const targetRevenue = this.displayedTargetRevenue();
|
|
59529
|
+
const priorRevenue = this.priorYearRevenue();
|
|
59530
|
+
const isValid = targetRevenue > priorRevenue && priorRevenue > 0;
|
|
59531
|
+
const increaseAmount = targetRevenue - priorRevenue;
|
|
59532
|
+
const percentageGrowth = priorRevenue > 0 ? ((targetRevenue - priorRevenue) / priorRevenue) * 100 : 0;
|
|
59531
59533
|
const gap = this.gapToClose();
|
|
59532
59534
|
if (isValid && increaseAmount > 0) {
|
|
59533
59535
|
this.animateCountUp(increaseAmount, percentageGrowth, Math.abs(gap.amount), gap.percentage);
|