@eric-emg/symphiq-components 1.2.259 → 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.
- package/fesm2022/symphiq-components.mjs +17 -11
- package/fesm2022/symphiq-components.mjs.map +1 -1
- package/index.d.ts +1 -0
- package/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -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);
|
|
@@ -59996,9 +59998,9 @@ class InitialTargetSettingComponent {
|
|
|
59996
59998
|
i0.ɵɵadvance();
|
|
59997
59999
|
i0.ɵɵconditional(ctx.revenueChartData() ? 32 : 33);
|
|
59998
60000
|
i0.ɵɵadvance(2);
|
|
59999
|
-
i0.ɵɵclassProp("calculated-card-enter-active", ctx.
|
|
60001
|
+
i0.ɵɵclassProp("calculated-card-enter-active", ctx.displayedTargetRevenue() > 0);
|
|
60000
60002
|
i0.ɵɵadvance(2);
|
|
60001
|
-
i0.ɵɵconditional(ctx.
|
|
60003
|
+
i0.ɵɵconditional(ctx.displayedTargetRevenue() > 0 ? 36 : -1);
|
|
60002
60004
|
i0.ɵɵadvance();
|
|
60003
60005
|
i0.ɵɵconditional(ctx.calculationState() !== "results" ? 37 : -1);
|
|
60004
60006
|
i0.ɵɵadvance();
|
|
@@ -60204,9 +60206,9 @@ class InitialTargetSettingComponent {
|
|
|
60204
60206
|
</div>
|
|
60205
60207
|
</div>
|
|
60206
60208
|
|
|
60207
|
-
<div class="calculated-card-enter order-first lg:order-last" [class.calculated-card-enter-active]="
|
|
60209
|
+
<div class="calculated-card-enter order-first lg:order-last" [class.calculated-card-enter-active]="displayedTargetRevenue() > 0">
|
|
60208
60210
|
<div class="calculated-card-content">
|
|
60209
|
-
@if (
|
|
60211
|
+
@if (displayedTargetRevenue() > 0) {
|
|
60210
60212
|
<div [ngClass]="calculatedValuesCardClasses()" class="p-6 rounded-xl border-2"
|
|
60211
60213
|
[class.h-full]="calculationState() !== 'results' || detailsExpanded()">
|
|
60212
60214
|
<div>
|
|
@@ -60634,6 +60636,10 @@ class SymphiqRevenueCalculatorDashboardComponent {
|
|
|
60634
60636
|
this.isScrolled = signal(false, ...(ngDevMode ? [{ debugName: "isScrolled" }] : []));
|
|
60635
60637
|
this.isProgrammaticScroll = false;
|
|
60636
60638
|
this.isLightMode = computed(() => this.viewMode() === ViewModeEnum.LIGHT, ...(ngDevMode ? [{ debugName: "isLightMode" }] : []));
|
|
60639
|
+
this.hasAnyTargets = computed(() => {
|
|
60640
|
+
const targets = this.targets();
|
|
60641
|
+
return targets !== undefined && targets.length > 0;
|
|
60642
|
+
}, ...(ngDevMode ? [{ debugName: "hasAnyTargets" }] : []));
|
|
60637
60643
|
this.hasCurrentYearTargets = computed(() => {
|
|
60638
60644
|
const targets = this.targets() ?? [];
|
|
60639
60645
|
const metrics = this.funnelMetrics() ?? [];
|
|
@@ -60807,7 +60813,7 @@ class SymphiqRevenueCalculatorDashboardComponent {
|
|
|
60807
60813
|
i0.ɵɵadvance(3);
|
|
60808
60814
|
i0.ɵɵproperty("ngClass", ctx.isLightMode() ? "text-xl font-bold bg-gradient-to-r from-blue-600 to-purple-600 bg-clip-text text-transparent truncate" : "text-xl font-bold bg-gradient-to-r from-blue-400 to-purple-400 bg-clip-text text-transparent truncate");
|
|
60809
60815
|
i0.ɵɵadvance(2);
|
|
60810
|
-
i0.ɵɵproperty("viewMode", ctx.viewMode())("currentStepId", ctx.JourneyStepIdEnum.REVENUE_CALCULATOR)("showNextStepAction", ctx.
|
|
60816
|
+
i0.ɵɵproperty("viewMode", ctx.viewMode())("currentStepId", ctx.JourneyStepIdEnum.REVENUE_CALCULATOR)("showNextStepAction", ctx.hasAnyTargets())("forDemo", ctx.forDemo())("maxAccessibleStepId", ctx.maxAccessibleStepId());
|
|
60811
60817
|
i0.ɵɵadvance(3);
|
|
60812
60818
|
i0.ɵɵconditional(ctx.isLoading() ? 23 : ctx.dataLoadStatus() !== ctx.ShopDataLoadStatusEnum.FULLY_LOADED ? 24 : 25);
|
|
60813
60819
|
} }, dependencies: [CommonModule, i1$1.NgClass, JourneyProgressIndicatorComponent,
|
|
@@ -60896,7 +60902,7 @@ class SymphiqRevenueCalculatorDashboardComponent {
|
|
|
60896
60902
|
<symphiq-journey-progress-indicator
|
|
60897
60903
|
[viewMode]="viewMode()"
|
|
60898
60904
|
[currentStepId]="JourneyStepIdEnum.REVENUE_CALCULATOR"
|
|
60899
|
-
[showNextStepAction]="
|
|
60905
|
+
[showNextStepAction]="hasAnyTargets()"
|
|
60900
60906
|
[forDemo]="forDemo()"
|
|
60901
60907
|
[maxAccessibleStepId]="maxAccessibleStepId()"
|
|
60902
60908
|
(stepClick)="stepClick.emit($event)"
|