@eric-emg/symphiq-components 1.2.544 → 1.2.545

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.
@@ -77795,8 +77795,35 @@ class ProfileSectionContentComponent {
77795
77795
  normalizedName.includes(m.metric?.toUpperCase() || ''));
77796
77796
  }
77797
77797
  if (metric) {
77798
- this.modalService.openMetricModal(metric, this.allCharts());
77798
+ const charts = this.chartsForMetric(metric);
77799
+ this.modalService.openMetricModal(metric, charts);
77800
+ }
77801
+ }
77802
+ chartsForMetric(metric) {
77803
+ const metricId = metric.performanceItemId;
77804
+ const metricName = metric.metric;
77805
+ if (!metricId && !metricName) {
77806
+ return [];
77807
+ }
77808
+ const allChartsArr = this.allCharts();
77809
+ const matchingCharts = [];
77810
+ const metricNameLower = metricName?.toLowerCase() || '';
77811
+ const metricNameNormalized = metricNameLower.replace(/\s+/g, '_');
77812
+ for (const chart of allChartsArr) {
77813
+ const chartId = chart.performanceItemId || '';
77814
+ const chartIdLower = chartId.toLowerCase();
77815
+ if (metricId) {
77816
+ const prefix = metricId + '_';
77817
+ if (chartId === metricId || chartId.startsWith(prefix)) {
77818
+ matchingCharts.push(chart);
77819
+ continue;
77820
+ }
77821
+ }
77822
+ if (metricName && chartIdLower.includes(metricNameNormalized)) {
77823
+ matchingCharts.push(chart);
77824
+ }
77799
77825
  }
77826
+ return matchingCharts;
77800
77827
  }
77801
77828
  getEffortBadgeClasses(effort) {
77802
77829
  if (!effort)
@@ -85742,7 +85769,7 @@ function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_7_Template(
85742
85769
  function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_13_Template(rf, ctx) { if (rf & 1) {
85743
85770
  const _r6 = i0.ɵɵgetCurrentView();
85744
85771
  i0.ɵɵelementStart(0, "symphiq-metric-executive-summary", 32);
85745
- i0.ɵɵlistener("topPrioritiesClick", function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_13_Template_symphiq_metric_executive_summary_topPrioritiesClick_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.handleMetricTopPrioritiesClick()); })("priorityDetailClick", function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_13_Template_symphiq_metric_executive_summary_priorityDetailClick_0_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.handleMetricPriorityDetailClick($event)); });
85772
+ i0.ɵɵlistener("topPrioritiesClick", function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_13_Template_symphiq_metric_executive_summary_topPrioritiesClick_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.handleMetricTopPrioritiesClick()); })("priorityDetailClick", function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_13_Template_symphiq_metric_executive_summary_priorityDetailClick_0_listener($event) { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.handleMetricPriorityDetailClick($event)); })("viewMetricDetailsClick", function CollapsibleAnalysisSectionGroupComponent_For_23_Conditional_13_Template_symphiq_metric_executive_summary_viewMetricDetailsClick_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.handleViewMetricDetailsClick()); });
85746
85773
  i0.ɵɵelementEnd();
85747
85774
  } if (rf & 2) {
85748
85775
  const ctx_r2 = i0.ɵɵnextContext(2);
@@ -86040,6 +86067,41 @@ class CollapsibleAnalysisSectionGroupComponent {
86040
86067
  this.modalService.navigateToTopPriorityDetail(event.priority, event.index, this.viewMode(), this.metricName(), totalCount);
86041
86068
  }
86042
86069
  }
86070
+ handleViewMetricDetailsClick() {
86071
+ console.log('[CollapsibleAnalysisSectionGroup] handleViewMetricDetailsClick called');
86072
+ const metricKey = this.metricExecutiveSummary()?.metric;
86073
+ console.log('[CollapsibleAnalysisSectionGroup] metricKey:', metricKey);
86074
+ if (!metricKey) {
86075
+ console.log('[CollapsibleAnalysisSectionGroup] No metricKey found');
86076
+ return;
86077
+ }
86078
+ const allMetrics = this.allMetrics();
86079
+ const metric = allMetrics.find(m => m.metric === metricKey);
86080
+ console.log('[CollapsibleAnalysisSectionGroup] Found metric:', !!metric);
86081
+ if (metric) {
86082
+ const allCharts = this.allCharts();
86083
+ const metricCharts = allCharts.filter(chart => {
86084
+ const chartId = chart.performanceItemId?.toLowerCase() || '';
86085
+ const metricId = metricKey.toLowerCase();
86086
+ return chartId.includes(metricId) || chartId.startsWith(metricId);
86087
+ });
86088
+ console.log('[CollapsibleAnalysisSectionGroup] Opening modal with metric and', metricCharts.length, 'charts');
86089
+ this.modalService.openMetricModal(metric, metricCharts);
86090
+ }
86091
+ else {
86092
+ const summary = this.metricExecutiveSummary();
86093
+ if (summary) {
86094
+ const constructedMetric = {
86095
+ metric: metricKey,
86096
+ currentValue: typeof summary.currentValue === 'string' ? parseFloat(summary.currentValue) || 0 : (summary.currentValue ?? 0),
86097
+ targetValue: typeof summary.targetValue === 'string' ? parseFloat(summary.targetValue) || 0 : (summary.targetValue ?? 0),
86098
+ description: summary.gradeRationale
86099
+ };
86100
+ console.log('[CollapsibleAnalysisSectionGroup] Opening modal with constructed metric');
86101
+ this.modalService.openMetricModal(constructedMetric, []);
86102
+ }
86103
+ }
86104
+ }
86043
86105
  formatDescription(description) {
86044
86106
  if (!description)
86045
86107
  return description;
@@ -86058,7 +86120,7 @@ class CollapsibleAnalysisSectionGroupComponent {
86058
86120
  });
86059
86121
  }
86060
86122
  static { this.ɵfac = function CollapsibleAnalysisSectionGroupComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CollapsibleAnalysisSectionGroupComponent)(); }; }
86061
- static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CollapsibleAnalysisSectionGroupComponent, selectors: [["symphiq-collapsible-analysis-section-group"]], inputs: { sections: [1, "sections"], viewMode: [1, "viewMode"], executiveSummary: [1, "executiveSummary"], focusAreaExecutiveSummary: [1, "focusAreaExecutiveSummary"], metricExecutiveSummary: [1, "metricExecutiveSummary"], metricName: [1, "metricName"], allGoals: [1, "allGoals"], allMetrics: [1, "allMetrics"], allCharts: [1, "allCharts"], allInsights: [1, "allInsights"], businessProfile: [1, "businessProfile"] }, decls: 24, vars: 12, consts: [[1, "rounded-2xl", "border", "shadow-lg", "overflow-hidden", 3, "ngClass"], [1, "px-6", "py-5", "border-b", 3, "ngClass"], [1, "flex", "items-center", "justify-between"], [1, "flex", "items-center", "gap-3"], [1, "p-2.5", "rounded-lg", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-5", "h-5"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M19 11H5m14 0a2 2 0 012 2v6a2 2 0 01-2 2H5a2 2 0 01-2-2v-6a2 2 0 012-2m14 0V9a2 2 0 00-2-2M5 11V9a2 2 0 012-2m0 0V5a2 2 0 012-2h6a2 2 0 012 2v2M7 7h10"], [1, "text-xl", "font-bold", 3, "ngClass"], [1, "text-sm", "mt-0.5", 3, "ngClass"], [1, "p-6", 3, "ngClass"], [1, "mb-6", "p-4", "rounded-xl", "border", "flex", "items-start", "gap-3", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-5", "h-5", "flex-shrink-0", "mt-0.5", 3, "ngClass"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"], [1, "flex-1"], [1, "font-semibold", "text-sm", "mb-1", 3, "ngClass"], [1, "text-sm", "leading-relaxed", 3, "ngClass"], [1, "space-y-3"], [1, "rounded-xl", "border", "overflow-hidden", "transition-all", "duration-200", 3, "id", "ngClass"], ["type", "button", 1, "cursor-pointer", "w-full", "px-5", "py-4", "flex", "items-center", "justify-between", "gap-4", "text-left", "transition-colors", "duration-200", 3, "click", "ngClass"], [1, "flex", "items-center", "gap-3", "flex-1", "min-w-0"], [1, "p-2", "rounded-lg", "flex-shrink-0", "transition-colors", "duration-200", 3, "ngClass"], [1, "flex-1", "min-w-0"], [1, "font-semibold", "transition-colors", "duration-200", 3, "ngClass"], [1, "text-sm", "mt-0.5", "line-clamp-1", "transition-colors", "duration-200", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-5", "h-5", "flex-shrink-0", "transition-transform", "duration-200", 3, "ngClass"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M19 9l-7 7-7-7"], [1, "grid", "transition-[grid-template-rows]", "duration-300", "ease-in-out"], [1, "overflow-hidden"], [1, "border-t", "p-6", 3, "ngClass"], [3, "viewMode", "summary", "metricName", "allGoals"], [3, "viewMode", "summary", "allGoals"], ["size", "w-4 h-4", 3, "icon"], [3, "topPrioritiesClick", "priorityDetailClick", "viewMode", "summary", "metricName", "allGoals"], [3, "topPrioritiesClick", "priorityDetailClick", "viewMode", "summary", "allGoals"], [1, "mb-6"], [3, "section", "viewMode", "sectionIndex", "executiveSummary", "allGoals", "allMetrics", "allCharts", "allInsights", "businessProfile"], [1, "relative"], [1, "text-sm", "leading-relaxed", "whitespace-pre-line", 3, "ngClass"], [1, "clear-both"], [1, "mb-6", "lg:float-left", "lg:mr-6", "lg:mb-4", "lg:max-w-[50%]"], [1, "mb-6", "lg:float-right", "lg:ml-6", "lg:mb-4", "lg:max-w-[50%]"], [3, "visual", "viewMode"]], template: function CollapsibleAnalysisSectionGroupComponent_Template(rf, ctx) { if (rf & 1) {
86123
+ static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: CollapsibleAnalysisSectionGroupComponent, selectors: [["symphiq-collapsible-analysis-section-group"]], inputs: { sections: [1, "sections"], viewMode: [1, "viewMode"], executiveSummary: [1, "executiveSummary"], focusAreaExecutiveSummary: [1, "focusAreaExecutiveSummary"], metricExecutiveSummary: [1, "metricExecutiveSummary"], metricName: [1, "metricName"], allGoals: [1, "allGoals"], allMetrics: [1, "allMetrics"], allCharts: [1, "allCharts"], allInsights: [1, "allInsights"], businessProfile: [1, "businessProfile"] }, decls: 24, vars: 12, consts: [[1, "rounded-2xl", "border", "shadow-lg", "overflow-hidden", 3, "ngClass"], [1, "px-6", "py-5", "border-b", 3, "ngClass"], [1, "flex", "items-center", "justify-between"], [1, "flex", "items-center", "gap-3"], [1, "p-2.5", "rounded-lg", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-5", "h-5"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M19 11H5m14 0a2 2 0 012 2v6a2 2 0 01-2 2H5a2 2 0 01-2-2v-6a2 2 0 012-2m14 0V9a2 2 0 00-2-2M5 11V9a2 2 0 012-2m0 0V5a2 2 0 012-2h6a2 2 0 012 2v2M7 7h10"], [1, "text-xl", "font-bold", 3, "ngClass"], [1, "text-sm", "mt-0.5", 3, "ngClass"], [1, "p-6", 3, "ngClass"], [1, "mb-6", "p-4", "rounded-xl", "border", "flex", "items-start", "gap-3", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-5", "h-5", "flex-shrink-0", "mt-0.5", 3, "ngClass"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"], [1, "flex-1"], [1, "font-semibold", "text-sm", "mb-1", 3, "ngClass"], [1, "text-sm", "leading-relaxed", 3, "ngClass"], [1, "space-y-3"], [1, "rounded-xl", "border", "overflow-hidden", "transition-all", "duration-200", 3, "id", "ngClass"], ["type", "button", 1, "cursor-pointer", "w-full", "px-5", "py-4", "flex", "items-center", "justify-between", "gap-4", "text-left", "transition-colors", "duration-200", 3, "click", "ngClass"], [1, "flex", "items-center", "gap-3", "flex-1", "min-w-0"], [1, "p-2", "rounded-lg", "flex-shrink-0", "transition-colors", "duration-200", 3, "ngClass"], [1, "flex-1", "min-w-0"], [1, "font-semibold", "transition-colors", "duration-200", 3, "ngClass"], [1, "text-sm", "mt-0.5", "line-clamp-1", "transition-colors", "duration-200", 3, "ngClass"], ["fill", "none", "stroke", "currentColor", "viewBox", "0 0 24 24", 1, "w-5", "h-5", "flex-shrink-0", "transition-transform", "duration-200", 3, "ngClass"], ["stroke-linecap", "round", "stroke-linejoin", "round", "stroke-width", "2", "d", "M19 9l-7 7-7-7"], [1, "grid", "transition-[grid-template-rows]", "duration-300", "ease-in-out"], [1, "overflow-hidden"], [1, "border-t", "p-6", 3, "ngClass"], [3, "viewMode", "summary", "metricName", "allGoals"], [3, "viewMode", "summary", "allGoals"], ["size", "w-4 h-4", 3, "icon"], [3, "topPrioritiesClick", "priorityDetailClick", "viewMetricDetailsClick", "viewMode", "summary", "metricName", "allGoals"], [3, "topPrioritiesClick", "priorityDetailClick", "viewMode", "summary", "allGoals"], [1, "mb-6"], [3, "section", "viewMode", "sectionIndex", "executiveSummary", "allGoals", "allMetrics", "allCharts", "allInsights", "businessProfile"], [1, "relative"], [1, "text-sm", "leading-relaxed", "whitespace-pre-line", 3, "ngClass"], [1, "clear-both"], [1, "mb-6", "lg:float-left", "lg:mr-6", "lg:mb-4", "lg:max-w-[50%]"], [1, "mb-6", "lg:float-right", "lg:ml-6", "lg:mb-4", "lg:max-w-[50%]"], [3, "visual", "viewMode"]], template: function CollapsibleAnalysisSectionGroupComponent_Template(rf, ctx) { if (rf & 1) {
86062
86124
  i0.ɵɵelementStart(0, "div", 0)(1, "div", 1)(2, "div", 2)(3, "div", 3)(4, "div", 4);
86063
86125
  i0.ɵɵnamespaceSVG();
86064
86126
  i0.ɵɵelementStart(5, "svg", 5);
@@ -86208,6 +86270,7 @@ class CollapsibleAnalysisSectionGroupComponent {
86208
86270
  [allGoals]="allGoals()"
86209
86271
  (topPrioritiesClick)="handleMetricTopPrioritiesClick()"
86210
86272
  (priorityDetailClick)="handleMetricPriorityDetailClick($event)"
86273
+ (viewMetricDetailsClick)="handleViewMetricDetailsClick()"
86211
86274
  />
86212
86275
  } @else if (section.id === 'focus-area-executive-summary' && focusAreaExecutiveSummary()) {
86213
86276
  <symphiq-focus-area-executive-summary
@@ -86276,7 +86339,7 @@ class CollapsibleAnalysisSectionGroupComponent {
86276
86339
  `
86277
86340
  }]
86278
86341
  }], null, { sections: [{ type: i0.Input, args: [{ isSignal: true, alias: "sections", required: false }] }], viewMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "viewMode", required: false }] }], executiveSummary: [{ type: i0.Input, args: [{ isSignal: true, alias: "executiveSummary", required: false }] }], focusAreaExecutiveSummary: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusAreaExecutiveSummary", required: false }] }], metricExecutiveSummary: [{ type: i0.Input, args: [{ isSignal: true, alias: "metricExecutiveSummary", required: false }] }], metricName: [{ type: i0.Input, args: [{ isSignal: true, alias: "metricName", required: false }] }], allGoals: [{ type: i0.Input, args: [{ isSignal: true, alias: "allGoals", required: false }] }], allMetrics: [{ type: i0.Input, args: [{ isSignal: true, alias: "allMetrics", required: false }] }], allCharts: [{ type: i0.Input, args: [{ isSignal: true, alias: "allCharts", required: false }] }], allInsights: [{ type: i0.Input, args: [{ isSignal: true, alias: "allInsights", required: false }] }], businessProfile: [{ type: i0.Input, args: [{ isSignal: true, alias: "businessProfile", required: false }] }] }); })();
86279
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(CollapsibleAnalysisSectionGroupComponent, { className: "CollapsibleAnalysisSectionGroupComponent", filePath: "lib/components/profile-analysis-shop-dashboard/cards/collapsible-analysis-section-group.component.ts", lineNumber: 172 }); })();
86342
+ (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(CollapsibleAnalysisSectionGroupComponent, { className: "CollapsibleAnalysisSectionGroupComponent", filePath: "lib/components/profile-analysis-shop-dashboard/cards/collapsible-analysis-section-group.component.ts", lineNumber: 173 }); })();
86280
86343
 
86281
86344
  const _forTrack0$g = ($index, $item) => $item.code;
86282
86345
  function BillingCurrencySelectorCardComponent_For_15_Template(rf, ctx) { if (rf & 1) {