@eric-emg/symphiq-components 1.2.350 → 1.2.351

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.
@@ -89102,36 +89102,17 @@ class SymphiqProfileAnalysisDashboardComponent {
89102
89102
  return this.accountSignal()?.chargebeeItemPricePeriodUnit || ChargebeeItemPricePeriodUnitEnum.YEAR;
89103
89103
  }, ...(ngDevMode ? [{ debugName: "selectedPeriodUnit" }] : []));
89104
89104
  this.showPlanSelection = computed(() => {
89105
- const hasCurrency = this.hasBillingCurrency();
89106
- const isActive = this.isSubscriptionActive();
89107
- const hasPlans = this.planCardInfos() && this.planCardInfos().length > 0;
89108
- const result = hasCurrency && !isActive && hasPlans;
89109
- console.log('[ProfileAnalysisDashboard] showPlanSelection computed:', {
89110
- hasBillingCurrency: hasCurrency,
89111
- isSubscriptionActive: isActive,
89112
- hasPlans,
89113
- result
89114
- });
89115
- return result;
89105
+ return this.hasBillingCurrency() && !this.isSubscriptionActive() && this.planCardInfos() && this.planCardInfos().length > 0;
89116
89106
  }, ...(ngDevMode ? [{ debugName: "showPlanSelection" }] : []));
89117
89107
  this.accountSignal = signal(undefined, ...(ngDevMode ? [{ debugName: "accountSignal" }] : []));
89118
89108
  this.accountInputEffect = effect(() => {
89119
- const accountInput = this.account();
89120
- console.log('[ProfileAnalysisDashboard] account input effect triggered:', {
89121
- subscriptionStatus: accountInput?.subscriptionStatus,
89122
- billingCurrencyCode: accountInput?.billingCurrencyCode,
89123
- isActive: accountInput ? ChargebeeSubscriptionStatusEnumUtil.isActive(accountInput.subscriptionStatus) : false
89124
- });
89125
- this.accountSignal.set(accountInput);
89109
+ this.accountSignal.set(this.account());
89126
89110
  }, ...(ngDevMode ? [{ debugName: "accountInputEffect", allowSignalWrites: true }] : [{ allowSignalWrites: true }]));
89127
89111
  this.isSubscriptionActive = computed(() => {
89128
89112
  const account = this.accountSignal();
89129
- const isActive = account ? (ChargebeeSubscriptionStatusEnumUtil.isActive(account.subscriptionStatus) ?? false) : false;
89130
- console.log('[ProfileAnalysisDashboard] isSubscriptionActive computed:', {
89131
- subscriptionStatus: account?.subscriptionStatus,
89132
- isActive
89133
- });
89134
- return isActive;
89113
+ if (!account)
89114
+ return false;
89115
+ return ChargebeeSubscriptionStatusEnumUtil.isActive(account.subscriptionStatus) ?? false;
89135
89116
  }, ...(ngDevMode ? [{ debugName: "isSubscriptionActive" }] : []));
89136
89117
  this.hasBillingCurrency = computed(() => {
89137
89118
  const account = this.accountSignal();
@@ -89524,35 +89505,15 @@ class SymphiqProfileAnalysisDashboardComponent {
89524
89505
  }
89525
89506
  }
89526
89507
  ngOnChanges(changes) {
89527
- console.log('[ProfileAnalysisDashboard] ngOnChanges called with keys:', Object.keys(changes));
89528
- // Update the signal whenever funnelAnalysis input changes
89529
89508
  if (changes['funnelAnalysis']) {
89530
89509
  this.funnelAnalysisSignal.set(this.funnelAnalysis());
89531
89510
  }
89532
- // Update account signal when account input changes
89533
89511
  if (changes['account']) {
89534
- const prevAccount = changes['account'].previousValue;
89535
- const currAccount = changes['account'].currentValue;
89536
- console.log('[ProfileAnalysisDashboard] account input changed:', {
89537
- previousSubscriptionStatus: prevAccount?.subscriptionStatus,
89538
- currentSubscriptionStatus: currAccount?.subscriptionStatus,
89539
- previousBillingCurrency: prevAccount?.billingCurrencyCode,
89540
- currentBillingCurrency: currAccount?.billingCurrencyCode,
89541
- isFirstChange: changes['account'].firstChange,
89542
- sameReference: prevAccount === currAccount
89543
- });
89544
89512
  this.accountSignal.set(this.account());
89545
- console.log('[ProfileAnalysisDashboard] accountSignal updated, isSubscriptionActive:', this.isSubscriptionActive());
89546
89513
  }
89547
89514
  }
89548
89515
  ngOnInit() {
89549
- console.log('[ProfileAnalysisDashboard] ngOnInit called with account:', {
89550
- subscriptionStatus: this.account()?.subscriptionStatus,
89551
- billingCurrencyCode: this.account()?.billingCurrencyCode
89552
- });
89553
- // Set the signal with the funnelAnalysis data
89554
89516
  this.funnelAnalysisSignal.set(this.funnelAnalysis());
89555
- // Set account signal (effect also does this, but ensure it's set on init)
89556
89517
  this.accountSignal.set(this.account());
89557
89518
  // Index business profile recommendations into ProfileContextService
89558
89519
  // This enables detailed recommendation lookup for goal business insights