axidio-styleguide-library1-v2 0.2.7 → 0.2.9

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.
@@ -3039,210 +3039,255 @@ class GuageChartComponent extends ComponentUniqueId {
3039
3039
  }
3040
3040
  ngOnInit() { }
3041
3041
  ngOnChanges() {
3042
- this.redrawChart();
3043
- }
3044
- onResized(_event) {
3045
- this.redrawChart();
3042
+ d3.select('#' + this.uniqueId).remove();
3043
+ this.initializeLineChart();
3046
3044
  }
3047
- /**
3048
- * Clears the previous SVG and redraws chart
3049
- */
3050
- redrawChart() {
3045
+ onResized(event) {
3051
3046
  d3.select('#' + this.uniqueId).remove();
3052
3047
  this.initializeLineChart();
3053
3048
  }
3054
- /**
3055
- * Main entry point for chart rendering
3056
- */
3049
+ /** -------------------------------
3050
+ * Main Initialization Function
3051
+ * ------------------------------*/
3057
3052
  initializeLineChart() {
3058
- this.prepareConfiguration();
3059
- const { data, metaData, colorMaps, data_ready, angleValue, radius } = this.processChartData();
3060
- const svg = this.createSvgContainer(radius);
3061
- this.drawArcs(svg, data_ready, colorMaps, metaData);
3062
- this.drawPointer(svg, metaData, data_ready, radius);
3063
- this.drawLabels(svg, data_ready, radius, metaData);
3064
- this.drawTexts(svg, metaData, radius);
3065
- }
3066
- /**
3067
- * Prepare chart configuration
3068
- */
3069
- prepareConfiguration() {
3053
+ const self = this;
3054
+ const { data, metaData } = this.chartData;
3055
+ const isRia = this.customChartConfiguration.isRia;
3056
+ this.setupChartConfiguration();
3057
+ const { colorMaps } = this.getColorMap(metaData);
3058
+ this.configureDataType(metaData);
3059
+ const data_ready = this.calculateDataReady(data);
3060
+ const { chartContainer, guagecontainer, width, height } = this.setupContainer();
3061
+ this.isHeaderVisible =
3062
+ this.chartConfiguration.isHeaderVisible ?? this.isHeaderVisible;
3063
+ const svg = this.createSvg(chartContainer, width, height);
3064
+ const radius = this.adjustDimensionsAndRadius(width, height);
3065
+ const angleValue = this.computeAngles(data_ready, data);
3066
+ const arc = this.createArc(radius, angleValue, data_ready);
3067
+ this.drawGaugeArcs(svg, arc, data_ready, colorMaps, metaData, isRia, data);
3068
+ this.drawPointer(svg, radius, metaData, data);
3069
+ this.drawLabels(svg, radius, data_ready, data, metaData);
3070
+ this.drawCenterTexts(svg, radius, metaData);
3071
+ this.centerSvg(svg, chartContainer, width, height);
3072
+ }
3073
+ /** -------------------------------
3074
+ * Modular Helper Functions
3075
+ * ------------------------------*/
3076
+ setupChartConfiguration() {
3070
3077
  for (const key in this.defaultConfiguration) {
3071
3078
  this.chartConfiguration[key] = ChartHelper.getValueByConfigurationType(key, this.defaultConfiguration, this.customChartConfiguration);
3072
3079
  }
3073
- if (this.chartConfiguration.isHeaderVisible !== undefined)
3074
- this.isHeaderVisible = this.chartConfiguration.isHeaderVisible;
3075
3080
  }
3076
- /**
3077
- * Process data, calculate colors and angles
3078
- */
3079
- processChartData() {
3080
- const metaData = this.chartData.metaData;
3081
- const data = this.chartData.data;
3082
- const colorType = metaData.colorType || 'high';
3081
+ getColorMap(metaData) {
3082
+ const colorType = metaData.colorType;
3083
3083
  const colorMaps = colorType === 'low'
3084
3084
  ? this.chartConfiguration.low_colorMap
3085
3085
  : this.chartConfiguration.high_colorMap;
3086
+ return { colorMaps };
3087
+ }
3088
+ configureDataType(metaData) {
3086
3089
  if (metaData.dataType) {
3087
- this.dataType = metaData.dataType === 'USD' ? '$ ' : metaData.dataType;
3088
- this.datatype_status = true;
3090
+ this.dataType = metaData.dataType;
3091
+ if (this.dataType === 'USD') {
3092
+ this.datatype_status = true;
3093
+ this.dataType = '$ ';
3094
+ }
3089
3095
  }
3090
- const data_ready = data.slice(0, -1).map((v, i) => data[i + 1] - v);
3091
- const total = d3.sum(data_ready);
3092
- const angleValue = data_ready.reduce((acc, curr, i) => {
3093
- const prev = acc[i - 1] || 0;
3094
- acc.push(prev + (curr / total) * 180);
3095
- return acc;
3096
- }, []);
3097
- const width = parseInt(d3.select(this.containerElt.nativeElement).style('width')) -
3098
- this.chartConfiguration.margin.left -
3099
- this.chartConfiguration.margin.right;
3100
- const height = parseInt(d3.select(this.guagecontainerElt.nativeElement).style('height')) -
3101
- this.chartConfiguration.margin.top -
3102
- this.chartConfiguration.margin.bottom -
3103
- 56;
3104
- const radius = Math.min(width, height) / 2;
3105
- return { data, metaData, colorMaps, data_ready, angleValue, radius };
3106
3096
  }
3107
- /**
3108
- * Create SVG base container
3109
- */
3110
- createSvgContainer(radius) {
3111
- const margin = this.chartConfiguration.margin;
3097
+ calculateDataReady(data) {
3098
+ const data_ready = [];
3099
+ data.forEach((_, i) => {
3100
+ if (i < data.length - 1) {
3101
+ data_ready.push(data[i + 1] - data[i]);
3102
+ }
3103
+ });
3104
+ return data_ready;
3105
+ }
3106
+ setupContainer() {
3112
3107
  const chartContainer = d3.select(this.containerElt.nativeElement);
3113
- const width = parseInt(chartContainer.style('width'));
3114
- const height = parseInt(chartContainer.style('height'));
3115
- const svg = chartContainer
3108
+ const guagecontainer = d3.select(this.guagecontainerElt.nativeElement);
3109
+ const margin = this.chartConfiguration.margin;
3110
+ const width = parseInt(chartContainer.style('width')) - margin.left - margin.right;
3111
+ const height = parseInt(guagecontainer.style('height')) -
3112
+ margin.top -
3113
+ margin.bottom -
3114
+ 56; // chart header height
3115
+ return { chartContainer, guagecontainer, width, height };
3116
+ }
3117
+ createSvg(chartContainer, width, height) {
3118
+ const margin = this.chartConfiguration.margin;
3119
+ return chartContainer
3116
3120
  .append('svg')
3117
3121
  .attr('id', this.uniqueId)
3118
- .attr('width', width)
3119
- .attr('height', height)
3122
+ .attr('width', width + margin.left + margin.right)
3123
+ .attr('height', height + margin.top + margin.bottom)
3120
3124
  .call(ChartHelper.responsivefy)
3121
- .append('g')
3122
- .attr('transform', `translate(${margin.left + radius}, ${margin.top + radius})`);
3123
- return svg;
3125
+ .append('g');
3124
3126
  }
3125
- /**
3126
- * Draw gauge arcs
3127
- */
3128
- drawArcs(svg, data_ready, colorMaps, metaData) {
3129
- const arc = d3
3127
+ adjustDimensionsAndRadius(width, height) {
3128
+ const radius = Math.min(width, height) / 2;
3129
+ if (this.chartConfiguration.isDrilldownChart) {
3130
+ this.chartConfiguration.currentValueWidthScaleFactor += 40;
3131
+ this.chartConfiguration.currentValueHeightScaleFactor += 20;
3132
+ }
3133
+ else if (window.innerWidth > 1400) {
3134
+ this.chartConfiguration.currentValueHeightScaleFactor += 15;
3135
+ this.chartConfiguration.currentValueWidthScaleFactor *= 2;
3136
+ }
3137
+ return radius;
3138
+ }
3139
+ computeAngles(data_ready, data) {
3140
+ const total = data_ready.reduce((sum, val) => sum + val, 0);
3141
+ const tempArray = [];
3142
+ data_ready.forEach((unit, i) => {
3143
+ const angle = (unit / total) * 180;
3144
+ tempArray.push(i === 0 ? angle : tempArray[i - 1] + angle);
3145
+ });
3146
+ return tempArray;
3147
+ }
3148
+ createArc(radius, angleValue, data_ready) {
3149
+ const self = this;
3150
+ const deg2rad = (deg) => (deg * Math.PI) / 180;
3151
+ return d3
3130
3152
  .arc()
3131
- .innerRadius(this.chartConfiguration.ringWidth +
3132
- this.chartConfiguration.ringInset -
3133
- 20)
3134
- .outerRadius(this.chartConfiguration.ringWidth + 40)
3135
- .startAngle((_, i) => this.deg2rad(this.chartConfiguration.minAngle + (i ? i * 60 : 0)))
3136
- .endAngle((_, i) => this.deg2rad(this.chartConfiguration.minAngle + (i + 1) * 60));
3137
- const isClickable = metaData.hasDrillDown && metaData.currentValue > 0;
3138
- svg
3153
+ .innerRadius(radius -
3154
+ self.chartConfiguration.ringWidth -
3155
+ self.chartConfiguration.ringInset)
3156
+ .outerRadius(radius)
3157
+ .startAngle((_, i) => deg2rad(i === 0
3158
+ ? self.chartConfiguration.minAngle
3159
+ : self.chartConfiguration.minAngle + angleValue[i - 1]))
3160
+ .endAngle((_, i) => deg2rad(i === data_ready.length - 1
3161
+ ? self.chartConfiguration.maxAngle
3162
+ : self.chartConfiguration.minAngle + angleValue[i]));
3163
+ }
3164
+ drawGaugeArcs(svg, arc, data_ready, colorMaps, metaData, isRia, data) {
3165
+ const self = this;
3166
+ const arcs = svg
3139
3167
  .append('g')
3140
3168
  .attr('class', 'arc')
3169
+ .attr('transform', this.centerTranslation(arc.outerRadius()()));
3170
+ arcs
3141
3171
  .selectAll('path')
3142
3172
  .data(data_ready)
3143
3173
  .enter()
3144
3174
  .append('path')
3145
3175
  .attr('fill', (_, i) => colorMaps[i])
3176
+ .style('cursor', () => metaData.currentValue > 0 && metaData.hasDrillDown && !isRia
3177
+ ? 'pointer'
3178
+ : 'default')
3146
3179
  .attr('d', arc)
3147
- .style('cursor', isClickable ? 'pointer' : 'default')
3148
- .on('click', (event, d) => {
3149
- if (isClickable)
3150
- this.handleClick(d);
3180
+ .on('click', (d) => {
3181
+ if (!metaData.hasDrillDown || metaData.currentValue === 0)
3182
+ return;
3183
+ const range = `${data[0]} and ${data[data.length - 1]}`;
3184
+ self.handleClick(range);
3151
3185
  });
3152
3186
  }
3153
- /**
3154
- * Draw the pointer/needle
3155
- */
3156
- drawPointer(svg, metaData, data_ready, radius) {
3157
- const pointerValue = metaData.currentValue - this.chartData.data[0];
3158
- const range = this.chartData.data[this.chartData.data.length - 1] -
3159
- this.chartData.data[0];
3160
- const pointerAngle = this.chartConfiguration.minAngle + (pointerValue / range) * 180;
3161
- const pointerHeadLength = Math.round(radius * this.chartConfiguration.pointerHeadLengthPercent);
3187
+ drawPointer(svg, radius, metaData, data) {
3188
+ const self = this;
3189
+ const pointerHeadLength = Math.round(radius * self.chartConfiguration.pointerHeadLengthPercent);
3162
3190
  const lineData = [
3163
- [this.chartConfiguration.pointerWidth / 2, 0],
3191
+ [self.chartConfiguration.pointerWidth / 2, 0],
3164
3192
  [0, -pointerHeadLength],
3165
- [-this.chartConfiguration.pointerWidth / 2, 0],
3166
- [0, this.chartConfiguration.pointerTailLength],
3167
- [this.chartConfiguration.pointerWidth / 2, 0],
3193
+ [-(self.chartConfiguration.pointerWidth / 2), 0],
3194
+ [0, self.chartConfiguration.pointerTailLength],
3195
+ [self.chartConfiguration.pointerWidth / 2, 0],
3168
3196
  ];
3169
- svg
3197
+ const pointerLine = d3.line();
3198
+ const pg = svg
3170
3199
  .append('g')
3200
+ .data([lineData])
3171
3201
  .attr('class', 'pointer')
3172
- .append('path')
3173
- .attr('d', d3.line()(lineData))
3174
- .attr('fill', this.chartConfiguration.pointerColor)
3175
- .attr('transform', `rotate(${pointerAngle}) translate(0, ${-radius +
3176
- this.chartConfiguration.ringWidth +
3177
- pointerHeadLength})`);
3178
- }
3179
- /**
3180
- * Draw numeric labels around gauge
3181
- */
3182
- drawLabels(svg, data_ready, radius, metaData) {
3183
- const data = this.chartData.data;
3202
+ .attr('transform', this.centerTranslation(radius));
3203
+ const pointerValue = metaData.currentValue - data[0];
3184
3204
  const range = data[data.length - 1] - data[0];
3185
- const labelArray = [{ name: data[0], value: 0 }];
3186
- data_ready.reduce((sum, val, i) => {
3187
- const newSum = sum + val;
3188
- labelArray.push({ name: data[i + 1], value: newSum });
3189
- return newSum;
3190
- }, 0);
3191
- const labelGroup = svg.append('g').attr('class', 'labels');
3192
- labelGroup
3193
- .selectAll('text')
3205
+ const pointerAngle = self.chartConfiguration.minAngle + (pointerValue / range) * 180;
3206
+ pg.append('path')
3207
+ .attr('d', pointerLine)
3208
+ .attr('fill', self.chartConfiguration.pointerColor)
3209
+ .attr('transform', `rotate(${pointerAngle}) translate(0,${-radius + self.chartConfiguration.ringWidth + pointerHeadLength})`);
3210
+ }
3211
+ drawLabels(svg, radius, data_ready, data, metaData) {
3212
+ const self = this;
3213
+ const range = data[data.length - 1] - data[0];
3214
+ const labelArray = this.buildLabelArray(data_ready, data);
3215
+ const lg = svg
3216
+ .append('g')
3217
+ .attr('class', 'label')
3218
+ .attr('transform', this.centerTranslation(radius));
3219
+ lg.selectAll('.bubble')
3194
3220
  .data(labelArray)
3195
3221
  .enter()
3196
- .append('text')
3222
+ .append('g')
3197
3223
  .attr('transform', (d) => {
3198
- const newAngle = this.chartConfiguration.minAngle + (d.value / range) * 180;
3199
- return `rotate(${newAngle}) translate(0, ${this.chartConfiguration.labelInset - radius - 20})`;
3224
+ const newAngle = self.chartConfiguration.minAngle + (d.value / range) * 180;
3225
+ return `rotate(${newAngle}) translate(0,${self.chartConfiguration.labelInset - radius - 20})`;
3200
3226
  })
3227
+ .append('text')
3201
3228
  .attr('fill', 'var(--chart-text-color)')
3202
- .style('font-size', '14px')
3229
+ .style('font-size', window.innerWidth < 1400 ? '12px' : '14px')
3203
3230
  .style('font-weight', '600')
3204
- .text((d) => metaData.dataType ? `${d.name}${metaData.dataType}` : d.name);
3231
+ .text((d) => (metaData.dataType ? d.name + metaData.dataType : d.name));
3205
3232
  }
3206
- /**
3207
- * Draw texts (value, status, date)
3208
- */
3209
- drawTexts(svg, metaData, radius) {
3210
- const topY = radius / 2 - 10;
3211
- const midY = topY + this.chartConfiguration.currentValueHeightScaleFactor;
3212
- const bottomY = midY + this.chartConfiguration.currentValueHeightScaleFactor;
3233
+ buildLabelArray(data_ready, data) {
3234
+ const labelArray = [{ name: data[0], value: 0 }];
3235
+ let count = 0;
3236
+ data_ready.forEach((unit, i) => {
3237
+ count += unit;
3238
+ labelArray.push({ name: data[i + 1], value: count });
3239
+ });
3240
+ return labelArray;
3241
+ }
3242
+ drawCenterTexts(svg, radius, metaData) {
3243
+ const self = this;
3244
+ const top = radius / 2 - 10;
3245
+ const mid = top + self.chartConfiguration.currentValueHeightScaleFactor;
3246
+ const bottom = mid + self.chartConfiguration.currentValueHeightScaleFactor;
3247
+ // current value
3213
3248
  svg
3214
3249
  .append('foreignObject')
3215
- .attr('transform', `translate(${radius - 50}, ${topY})`)
3216
- .attr('width', 100)
3217
- .attr('height', 40)
3250
+ .attr('transform', `translate(${radius - this.chartConfiguration.currentValueWidthScaleFactor / 2},${top})`)
3251
+ .attr('width', this.chartConfiguration.currentValueWidthScaleFactor + 8)
3252
+ .attr('height', this.chartConfiguration.currentValueHeightScaleFactor)
3218
3253
  .append('xhtml:div')
3219
3254
  .attr('class', 'value-display')
3220
- .html(`${metaData.currentValue}${metaData.dataType || ''}`);
3255
+ .html(metaData.currentValue + metaData.dataType);
3256
+ // status
3221
3257
  if (metaData.status) {
3258
+ const widthTemp = metaData.status.length > 4 ? 210 : 120;
3222
3259
  svg
3223
3260
  .append('foreignObject')
3224
- .attr('transform', `translate(${radius - 60}, ${midY})`)
3225
- .attr('width', 120)
3226
- .attr('height', 40)
3261
+ .attr('transform', `translate(${radius - widthTemp / 2},${mid})`)
3262
+ .attr('width', widthTemp)
3227
3263
  .append('xhtml:div')
3228
3264
  .attr('class', 'status-display')
3229
3265
  .html(metaData.status);
3230
3266
  }
3231
- if (metaData.dateRange) {
3232
- svg
3233
- .append('foreignObject')
3234
- .attr('transform', `translate(${radius - 105}, ${bottomY})`)
3235
- .attr('width', 210)
3236
- .attr('height', 40)
3237
- .append('xhtml:div')
3238
- .attr('class', 'daterange-display')
3239
- .html(`<span class="marginright-3"><i class="fa fa-calendar"></i></span>${metaData.dateRange}`);
3240
- }
3267
+ // date range
3268
+ svg
3269
+ .append('foreignObject')
3270
+ .attr('transform', `translate(${radius - 105},${bottom})`)
3271
+ .attr('width', 210)
3272
+ .append('xhtml:div')
3273
+ .attr('class', 'daterange-display')
3274
+ .html(metaData.dateRange
3275
+ ? `<span class="marginright-3"><i class="fa fa-calendar"></i></span><span>${metaData.dateRange}</span>`
3276
+ : '');
3241
3277
  }
3242
- /** Convert degrees to radians */
3243
- deg2rad(deg) {
3244
- return (deg * Math.PI) / 180;
3278
+ centerTranslation(radius) {
3279
+ return `translate(${radius},${radius})`;
3245
3280
  }
3281
+ centerSvg(svg, chartContainer, width, height) {
3282
+ const margin = this.chartConfiguration.margin;
3283
+ const containerMidWidth = parseInt(chartContainer.style('width')) / 2;
3284
+ const nodeHalfWidth = svg.node().getBoundingClientRect().width / 2;
3285
+ const updatedStartingPoint = containerMidWidth - nodeHalfWidth;
3286
+ svg.attr('transform', `translate(${updatedStartingPoint + margin.left},${margin.top})`);
3287
+ }
3288
+ /** -------------------------------
3289
+ * Event Handlers
3290
+ * ------------------------------*/
3246
3291
  handleClick(d) {
3247
3292
  this.clickEvent.emit(d);
3248
3293
  }
@@ -9808,14 +9853,14 @@ class PlainTrendComponent extends ComponentUniqueId {
9808
9853
  }
9809
9854
  }
9810
9855
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: PlainTrendComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
9811
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: PlainTrendComponent, selector: "lib-plain-trend", inputs: { chartData: "chartData", customChartConfiguration: "customChartConfiguration" }, outputs: { clickEvent: "clickEvent", headerMenuclickEvent: "headerMenuclickEvent" }, viewQueries: [{ propertyName: "containerElt", first: true, predicate: ["guagechartcontainer"], descendants: true, static: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div #piecontainer class=\"lib-chart-wrapper\" style=\"background-color: var(--card-bg);\">\r\n <lib-chart-header-v1\r\n *ngIf=\"isHeaderVisible\"\r\n [title]=\"chartData.metaData.title\"\r\n [hasDrillDown]=\"chartData.metaData.hasDrillDown\"\r\n [isEditEnabled]=\"chartData.metaData.isEditEnabled\"\r\n [menuOptions]=\"chartConfiguration.headerMenuOptions\"\r\n [selectedKpiTooltop]=\"chartConfiguration.selectedKpiTooltop\"\r\n [isria]=\"customChartConfiguration.isRia\"\r\n [isAlertEnabled]=\"isAlertEnabled\"\r\n (menuOptionClickEvent)=\"handleHeaderMenuClick($event)\"\r\n ></lib-chart-header-v1>\r\n\r\n <ng-container *ngIf=\"chartConfiguration.isToggleVisible && !isHeaderVisible && chartData.data.value > 0\">\r\n <lib-chart-header-v2\r\n [chartData]=\"chartData\"\r\n [chartConfiguration]=\"chartConfiguration\"\r\n (clickEvent)=\"handleClick($event)\"\r\n ></lib-chart-header-v2>\r\n </ng-container>\r\n\r\n <div\r\n #guagechartcontainer\r\n id=\"trendchartcontainer\"\r\n class=\"lib-chart-svg trendcontainer\"\r\n [style.height]=\"chartConfiguration.svgHeight\"\r\n >\r\n <div\r\n class=\"central-content\"\r\n [ngClass]=\"{\r\n 'central-content-non-drilldown-sizes': isHeaderVisible,\r\n 'central-content-drilldown-sizes': !isHeaderVisible,\r\n 'lib-justify-content-space-around': chartData.data.bgColor,\r\n 'lib-justify-content-center': !chartData.data.bgColor\r\n }\"\r\n (click)=\"handleClick(chartData.data.daterange)\"\r\n >\r\n <span\r\n class=\"value-style\"\r\n [ngClass]=\"{\r\n 'value-style-non-drilldown': isHeaderVisible,\r\n 'value-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.value | number: '1.0-2' }}\r\n </span>\r\n\r\n <span\r\n class=\"name-style\"\r\n [ngClass]=\"{\r\n 'name-style-non-drilldown': isHeaderVisible,\r\n 'name-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.name }}\r\n </span>\r\n\r\n <div\r\n *ngIf=\"chartData.data.bgColor\"\r\n class=\"direction-panel\"\r\n [ngClass]=\"{\r\n 'direction-panel-non-drilldown': isHeaderVisible,\r\n 'direction-panel-drilldown': !isHeaderVisible\r\n }\"\r\n [style.backgroundColor]=\"chartData.data.bgColor\"\r\n >\r\n <ng-container [ngSwitch]=\"chartData.data.valueDirection\">\r\n <img *ngSwitchCase=\"1\" class=\"trend-img\" src=\"/assets/up-trend.png\" alt=\"up\" />\r\n <img *ngSwitchCase=\"0\" class=\"trend-img\" src=\"/assets/sameline-trend.png\" alt=\"same\" />\r\n <img *ngSwitchCase=\"-1\" class=\"trend-img\" src=\"/assets/down-trend.png\" alt=\"down\" />\r\n </ng-container>\r\n </div>\r\n </div>\r\n\r\n <div\r\n class=\"date-range\"\r\n [ngClass]=\"{ 'date-range-drilldown': !isHeaderVisible }\"\r\n >\r\n <i class=\"fa fa-calendar marginright-3\"></i>\r\n {{ chartData.data.daterange }}\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".trendcontainer{display:flex!important;justify-content:center;align-items:center;flex-direction:column;position:relative;top:0;width:100%;height:100%;padding:1rem;box-sizing:border-box}.central-content{background:#f0f0f0;display:flex;align-items:center;justify-content:center;position:relative;box-shadow:0 1px 2px #0000001a,0 3px 10px #0000004d;border-radius:8px;padding:.5rem 1rem;text-align:center;transition:all .3s ease-in-out;max-width:90%;flex-wrap:wrap}.central-content-non-drilldown-sizes{height:auto;min-width:150px}.central-content-drilldown-sizes{min-width:300px;height:auto}.value-style,.name-style{font-weight:600;margin:.5rem;color:var(--pph-text-color)}.value-style-non-drilldown,.name-style-non-drilldown{font-size:20px}.value-style-drilldown,.name-style-drilldown{font-size:48px}.direction-panel{border-radius:8px;margin-right:5px;display:flex;justify-content:center;align-items:center}.direction-panel-non-drilldown{width:45px;height:45px}.direction-panel-drilldown{width:80px;height:80px}.trend-img{transform:scale(1.25)}.date-range{margin-top:1rem;font-size:16px;text-align:center}@media (max-width: 1024px){.central-content-drilldown-sizes{min-width:250px}.value-style-drilldown,.name-style-drilldown{font-size:36px}}@media (max-width: 768px){.central-content{flex-direction:column}.value-style-drilldown,.name-style-drilldown{font-size:28px}.date-range{font-size:14px}}@media (max-width: 480px){.central-content{min-width:200px;padding:.5rem}.value-style,.name-style{font-size:18px}.direction-panel{width:40px;height:40px}.trend-img{transform:scale(1)}.date-range{font-size:12px}}\n", ".lib-chart-wrapper{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;background:#fff 0% 0% no-repeat padding-box;position:relative}.lib-chart-wrapper-wo-shadow{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background){background-color:#2e3640}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background) .chart-title{color:#fff}.lib-chart-svg{width:100%}.lib-chart-header{text-align:center;background-color:#052340;color:#fff;width:100%;height:17%;word-spacing:.5px;line-height:1.8;font-weight:700;padding-top:2%;letter-spacing:0;font-size:1.2em}.lib-donut-chart-footer{width:100%;text-align:right}.lib-donut-label-text{font-size:.9em;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-weight:400;letter-spacing:0px;color:#000;opacity:1}.lib-donut-label-icon{display:inline-block;width:10px;height:10px;margin-right:20px;border-radius:3px}.lib-donut-label-item{font-weight:400;font-size:.85em;color:#2f2f2f}.lib-donut-justified-label-wrapper{width:100%;display:inline-block;text-align:center;list-style-type:none}.lib-donut-justified-label-item{font-weight:400;font-size:.85em;color:#2f2f2f;display:inline-block;text-align:left;padding:0 10px}.lib-donut-justified-label-icon{display:inline-block;width:10px;height:10px;margin-right:5px;border-radius:3px}.lib-no-background{background:none!important}.lib-display-hidden{display:none}.lib-ylabel-weeklyCharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:12px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.07px;text-transform:capitalize;color:#000}.lib-data-labels-weeklycharts{font-style:normal;font-variant:normal;font-weight:400;font-size:12px;line-height:14px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.06px;color:#000}.lib-data-labels-angled-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:9.5px;line-height:11px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:.4px;text-anchor:start}.lib-xaxis-labels-texts-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:11px;letter-spacing:-.05px;fill:#000}.lib-xaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:-1px;color:#000;opacity:1;text-transform:capitalize}.lib-white-space-nowrap{white-space:nowrap}.lib-xaxis-labels-texts-drilldown-alt{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:10px;letter-spacing:0px;color:#000;opacity:1;text-transform:capitalize}.lib-yaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:0px;color:#000!important;opacity:1}.lib-ylabel-drilldowncharts,.lib-xlabel-drilldowncharts{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:16px;letter-spacing:-.1px;color:#000!important;opacity:1}.lib-donut-justified-label-icon-drilldown{display:inline-block;width:14px;height:14px;margin-right:10px;border-radius:50%}.marginright-2{margin-right:2%}.margintop-5{margin-top:5%}.width-100{width:100%}.float-right{float:right}.marginBottom-10{margin-bottom:10px}.header-alt{align-items:center;margin-bottom:10px}input::placeholder{font-size:20px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:0px;color:#000;opacity:1}.padding-5{padding:5px}.hidden{visibility:hidden}.font-weight-bold{font-weight:900}.textalign-center{text-align:center}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.font-weight-600{font-weight:600}.marginRight-15{margin-right:15px}.marginRight-20{margin-right:20px}.switch{position:relative;display:inline-block;width:46px;height:24px;margin-left:5px;margin-right:5px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background-color:#2d5ca0;-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:\"\";height:18px;width:18px;right:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider.round{border-radius:18px}.slider.round:before{border-radius:50%}.slider1{position:absolute;cursor:pointer;inset:0;background-color:#015ba2cf;-webkit-transition:.4s;transition:.4s}.slider1:before{position:absolute;content:\"\";height:18px;width:18px;left:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider1.round1{border-radius:18px}.slider1.round1:before{border-radius:50%}.lib-display-flex{display:flex}.lib-align-items-center{align-items:center}.lib-flex-direction-column{flex-direction:column}.lib-justify-content-space-between{justify-content:space-between}.lib-justify-content-space-around{justify-content:space-around}.lib-justify-content-center{justify-content:center}.lib-justify-content-start{justify-content:start}.lib-justify-content-end{justify-content:end}.lib-ml-20{margin-left:20px}.lib-position-absolute{position:absolute}.lib-z-index-9{z-index:9}.marginright-3{margin-right:3px}@media (min-height: 900px){.lib-chart-wrapper{border-radius:8px}.header-font-size-1{font-size:18px!important}.font-size-1{font-size:14px!important}.font-size-2{font-size:16px!important}.font-size-3{font-size:14px!important}.font-size-4{font-size:22px!important}.font-size-5{font-size:24px!important}}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: ChartHeaderV1Component, selector: "lib-chart-header-v1", inputs: ["isAlertEnabled", "title", "menuOptions", "isEditEnabled", "isria", "hasDrillDown", "selectedKpiTooltop"], outputs: ["menuOptionClickEvent"] }, { kind: "component", type: ChartHeaderV2Component, selector: "lib-chart-header-v2", inputs: ["chartData", "chartConfiguration"], outputs: ["clickEvent", "zoomInZoomOutClick"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }], encapsulation: i0.ViewEncapsulation.None }); }
9856
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: PlainTrendComponent, selector: "lib-plain-trend", inputs: { chartData: "chartData", customChartConfiguration: "customChartConfiguration" }, outputs: { clickEvent: "clickEvent", headerMenuclickEvent: "headerMenuclickEvent" }, viewQueries: [{ propertyName: "containerElt", first: true, predicate: ["plaintrendcontainer"], descendants: true, static: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div #piecontainer class=\"lib-chart-wrapper\" style=\"background-color: var(--card-bg);\">\r\n <lib-chart-header-v1\r\n *ngIf=\"isHeaderVisible\"\r\n [title]=\"chartData.metaData.title\"\r\n [hasDrillDown]=\"chartData.metaData.hasDrillDown\"\r\n [isEditEnabled]=\"chartData.metaData.isEditEnabled\"\r\n [menuOptions]=\"chartConfiguration.headerMenuOptions\"\r\n [selectedKpiTooltop]=\"chartConfiguration.selectedKpiTooltop\"\r\n [isria]=\"customChartConfiguration.isRia\"\r\n [isAlertEnabled]=\"isAlertEnabled\"\r\n (menuOptionClickEvent)=\"handleHeaderMenuClick($event)\"\r\n ></lib-chart-header-v1>\r\n\r\n <ng-container *ngIf=\"chartConfiguration.isToggleVisible && !isHeaderVisible && chartData.data.value > 0\">\r\n <lib-chart-header-v2\r\n [chartData]=\"chartData\"\r\n [chartConfiguration]=\"chartConfiguration\"\r\n (clickEvent)=\"handleClick($event)\"\r\n ></lib-chart-header-v2>\r\n </ng-container>\r\n\r\n <div\r\n #plaintrendcontainer\r\n id=\"trendchartcontainer\"\r\n class=\"lib-chart-svg trendcontainer\"\r\n [style.height]=\"chartConfiguration.svgHeight\"\r\n >\r\n <div\r\n class=\"central-content\"\r\n [ngClass]=\"{\r\n 'central-content-non-drilldown-sizes': isHeaderVisible,\r\n 'central-content-drilldown-sizes': !isHeaderVisible,\r\n 'lib-justify-content-space-around': chartData.data.bgColor,\r\n 'lib-justify-content-center': !chartData.data.bgColor\r\n }\"\r\n (click)=\"handleClick(chartData.data.daterange)\"\r\n >\r\n <span\r\n class=\"value-style\"\r\n [ngClass]=\"{\r\n 'value-style-non-drilldown': isHeaderVisible,\r\n 'value-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.value | number: '1.0-2' }}\r\n </span>\r\n\r\n <span\r\n class=\"name-style\"\r\n [ngClass]=\"{\r\n 'name-style-non-drilldown': isHeaderVisible,\r\n 'name-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.name }}\r\n </span>\r\n\r\n <div\r\n *ngIf=\"chartData.data.bgColor\"\r\n class=\"direction-panel\"\r\n [ngClass]=\"{\r\n 'direction-panel-non-drilldown': isHeaderVisible,\r\n 'direction-panel-drilldown': !isHeaderVisible\r\n }\"\r\n [style.backgroundColor]=\"chartData.data.bgColor\"\r\n >\r\n <ng-container [ngSwitch]=\"chartData.data.valueDirection\">\r\n <img *ngSwitchCase=\"1\" class=\"trend-img\" src=\"/assets/up-trend.png\" alt=\"up\" />\r\n <img *ngSwitchCase=\"0\" class=\"trend-img\" src=\"/assets/sameline-trend.png\" alt=\"same\" />\r\n <img *ngSwitchCase=\"-1\" class=\"trend-img\" src=\"/assets/down-trend.png\" alt=\"down\" />\r\n </ng-container>\r\n </div>\r\n </div>\r\n\r\n <div\r\n class=\"date-range\"\r\n [ngClass]=\"{ 'date-range-drilldown': !isHeaderVisible }\"\r\n >\r\n <i class=\"fa fa-calendar marginright-3\"></i>\r\n {{ chartData.data.daterange }}\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".trendcontainer{display:flex!important;justify-content:center;align-items:center;flex-direction:column;position:relative;top:0;width:100%;height:100%;padding:1rem;box-sizing:border-box}.central-content{background:#f0f0f0;display:flex;align-items:center;justify-content:center;position:relative;box-shadow:0 1px 2px #0000001a,0 3px 10px #0000004d;border-radius:8px;padding:.5rem 1rem;text-align:center;transition:all .3s ease-in-out;max-width:90%;flex-wrap:wrap}.central-content-non-drilldown-sizes{height:auto;min-width:150px}.central-content-drilldown-sizes{min-width:300px;height:auto}.value-style,.name-style{font-weight:600;margin:.5rem;color:var(--pph-text-color)}.value-style-non-drilldown,.name-style-non-drilldown{font-size:20px}.value-style-drilldown,.name-style-drilldown{font-size:48px}.direction-panel{border-radius:8px;margin-right:5px;display:flex;justify-content:center;align-items:center}.direction-panel-non-drilldown{width:45px;height:45px}.direction-panel-drilldown{width:80px;height:80px}.trend-img{transform:scale(1.25)}.date-range{margin-top:1rem;font-size:16px;text-align:center}@media (max-width: 1024px){.central-content-drilldown-sizes{min-width:250px}.value-style-drilldown,.name-style-drilldown{font-size:36px}}@media (max-width: 768px){.central-content{flex-direction:column}.value-style-drilldown,.name-style-drilldown{font-size:28px}.date-range{font-size:14px}}@media (max-width: 480px){.central-content{min-width:200px;padding:.5rem}.value-style,.name-style{font-size:18px}.direction-panel{width:40px;height:40px}.trend-img{transform:scale(1)}.date-range{font-size:12px}}\n", ".lib-chart-wrapper{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;background:#fff 0% 0% no-repeat padding-box;position:relative}.lib-chart-wrapper-wo-shadow{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background){background-color:#2e3640}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background) .chart-title{color:#fff}.lib-chart-svg{width:100%}.lib-chart-header{text-align:center;background-color:#052340;color:#fff;width:100%;height:17%;word-spacing:.5px;line-height:1.8;font-weight:700;padding-top:2%;letter-spacing:0;font-size:1.2em}.lib-donut-chart-footer{width:100%;text-align:right}.lib-donut-label-text{font-size:.9em;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-weight:400;letter-spacing:0px;color:#000;opacity:1}.lib-donut-label-icon{display:inline-block;width:10px;height:10px;margin-right:20px;border-radius:3px}.lib-donut-label-item{font-weight:400;font-size:.85em;color:#2f2f2f}.lib-donut-justified-label-wrapper{width:100%;display:inline-block;text-align:center;list-style-type:none}.lib-donut-justified-label-item{font-weight:400;font-size:.85em;color:#2f2f2f;display:inline-block;text-align:left;padding:0 10px}.lib-donut-justified-label-icon{display:inline-block;width:10px;height:10px;margin-right:5px;border-radius:3px}.lib-no-background{background:none!important}.lib-display-hidden{display:none}.lib-ylabel-weeklyCharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:12px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.07px;text-transform:capitalize;color:#000}.lib-data-labels-weeklycharts{font-style:normal;font-variant:normal;font-weight:400;font-size:12px;line-height:14px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.06px;color:#000}.lib-data-labels-angled-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:9.5px;line-height:11px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:.4px;text-anchor:start}.lib-xaxis-labels-texts-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:11px;letter-spacing:-.05px;fill:#000}.lib-xaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:-1px;color:#000;opacity:1;text-transform:capitalize}.lib-white-space-nowrap{white-space:nowrap}.lib-xaxis-labels-texts-drilldown-alt{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:10px;letter-spacing:0px;color:#000;opacity:1;text-transform:capitalize}.lib-yaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:0px;color:#000!important;opacity:1}.lib-ylabel-drilldowncharts,.lib-xlabel-drilldowncharts{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:16px;letter-spacing:-.1px;color:#000!important;opacity:1}.lib-donut-justified-label-icon-drilldown{display:inline-block;width:14px;height:14px;margin-right:10px;border-radius:50%}.marginright-2{margin-right:2%}.margintop-5{margin-top:5%}.width-100{width:100%}.float-right{float:right}.marginBottom-10{margin-bottom:10px}.header-alt{align-items:center;margin-bottom:10px}input::placeholder{font-size:20px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:0px;color:#000;opacity:1}.padding-5{padding:5px}.hidden{visibility:hidden}.font-weight-bold{font-weight:900}.textalign-center{text-align:center}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.font-weight-600{font-weight:600}.marginRight-15{margin-right:15px}.marginRight-20{margin-right:20px}.switch{position:relative;display:inline-block;width:46px;height:24px;margin-left:5px;margin-right:5px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background-color:#2d5ca0;-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:\"\";height:18px;width:18px;right:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider.round{border-radius:18px}.slider.round:before{border-radius:50%}.slider1{position:absolute;cursor:pointer;inset:0;background-color:#015ba2cf;-webkit-transition:.4s;transition:.4s}.slider1:before{position:absolute;content:\"\";height:18px;width:18px;left:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider1.round1{border-radius:18px}.slider1.round1:before{border-radius:50%}.lib-display-flex{display:flex}.lib-align-items-center{align-items:center}.lib-flex-direction-column{flex-direction:column}.lib-justify-content-space-between{justify-content:space-between}.lib-justify-content-space-around{justify-content:space-around}.lib-justify-content-center{justify-content:center}.lib-justify-content-start{justify-content:start}.lib-justify-content-end{justify-content:end}.lib-ml-20{margin-left:20px}.lib-position-absolute{position:absolute}.lib-z-index-9{z-index:9}.marginright-3{margin-right:3px}@media (min-height: 900px){.lib-chart-wrapper{border-radius:8px}.header-font-size-1{font-size:18px!important}.font-size-1{font-size:14px!important}.font-size-2{font-size:16px!important}.font-size-3{font-size:14px!important}.font-size-4{font-size:22px!important}.font-size-5{font-size:24px!important}}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: ChartHeaderV1Component, selector: "lib-chart-header-v1", inputs: ["isAlertEnabled", "title", "menuOptions", "isEditEnabled", "isria", "hasDrillDown", "selectedKpiTooltop"], outputs: ["menuOptionClickEvent"] }, { kind: "component", type: ChartHeaderV2Component, selector: "lib-chart-header-v2", inputs: ["chartData", "chartConfiguration"], outputs: ["clickEvent", "zoomInZoomOutClick"] }, { kind: "pipe", type: i1.DecimalPipe, name: "number" }], encapsulation: i0.ViewEncapsulation.None }); }
9812
9857
  }
9813
9858
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: PlainTrendComponent, decorators: [{
9814
9859
  type: Component,
9815
- args: [{ selector: 'lib-plain-trend', encapsulation: ViewEncapsulation.None, template: "<div #piecontainer class=\"lib-chart-wrapper\" style=\"background-color: var(--card-bg);\">\r\n <lib-chart-header-v1\r\n *ngIf=\"isHeaderVisible\"\r\n [title]=\"chartData.metaData.title\"\r\n [hasDrillDown]=\"chartData.metaData.hasDrillDown\"\r\n [isEditEnabled]=\"chartData.metaData.isEditEnabled\"\r\n [menuOptions]=\"chartConfiguration.headerMenuOptions\"\r\n [selectedKpiTooltop]=\"chartConfiguration.selectedKpiTooltop\"\r\n [isria]=\"customChartConfiguration.isRia\"\r\n [isAlertEnabled]=\"isAlertEnabled\"\r\n (menuOptionClickEvent)=\"handleHeaderMenuClick($event)\"\r\n ></lib-chart-header-v1>\r\n\r\n <ng-container *ngIf=\"chartConfiguration.isToggleVisible && !isHeaderVisible && chartData.data.value > 0\">\r\n <lib-chart-header-v2\r\n [chartData]=\"chartData\"\r\n [chartConfiguration]=\"chartConfiguration\"\r\n (clickEvent)=\"handleClick($event)\"\r\n ></lib-chart-header-v2>\r\n </ng-container>\r\n\r\n <div\r\n #guagechartcontainer\r\n id=\"trendchartcontainer\"\r\n class=\"lib-chart-svg trendcontainer\"\r\n [style.height]=\"chartConfiguration.svgHeight\"\r\n >\r\n <div\r\n class=\"central-content\"\r\n [ngClass]=\"{\r\n 'central-content-non-drilldown-sizes': isHeaderVisible,\r\n 'central-content-drilldown-sizes': !isHeaderVisible,\r\n 'lib-justify-content-space-around': chartData.data.bgColor,\r\n 'lib-justify-content-center': !chartData.data.bgColor\r\n }\"\r\n (click)=\"handleClick(chartData.data.daterange)\"\r\n >\r\n <span\r\n class=\"value-style\"\r\n [ngClass]=\"{\r\n 'value-style-non-drilldown': isHeaderVisible,\r\n 'value-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.value | number: '1.0-2' }}\r\n </span>\r\n\r\n <span\r\n class=\"name-style\"\r\n [ngClass]=\"{\r\n 'name-style-non-drilldown': isHeaderVisible,\r\n 'name-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.name }}\r\n </span>\r\n\r\n <div\r\n *ngIf=\"chartData.data.bgColor\"\r\n class=\"direction-panel\"\r\n [ngClass]=\"{\r\n 'direction-panel-non-drilldown': isHeaderVisible,\r\n 'direction-panel-drilldown': !isHeaderVisible\r\n }\"\r\n [style.backgroundColor]=\"chartData.data.bgColor\"\r\n >\r\n <ng-container [ngSwitch]=\"chartData.data.valueDirection\">\r\n <img *ngSwitchCase=\"1\" class=\"trend-img\" src=\"/assets/up-trend.png\" alt=\"up\" />\r\n <img *ngSwitchCase=\"0\" class=\"trend-img\" src=\"/assets/sameline-trend.png\" alt=\"same\" />\r\n <img *ngSwitchCase=\"-1\" class=\"trend-img\" src=\"/assets/down-trend.png\" alt=\"down\" />\r\n </ng-container>\r\n </div>\r\n </div>\r\n\r\n <div\r\n class=\"date-range\"\r\n [ngClass]=\"{ 'date-range-drilldown': !isHeaderVisible }\"\r\n >\r\n <i class=\"fa fa-calendar marginright-3\"></i>\r\n {{ chartData.data.daterange }}\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".trendcontainer{display:flex!important;justify-content:center;align-items:center;flex-direction:column;position:relative;top:0;width:100%;height:100%;padding:1rem;box-sizing:border-box}.central-content{background:#f0f0f0;display:flex;align-items:center;justify-content:center;position:relative;box-shadow:0 1px 2px #0000001a,0 3px 10px #0000004d;border-radius:8px;padding:.5rem 1rem;text-align:center;transition:all .3s ease-in-out;max-width:90%;flex-wrap:wrap}.central-content-non-drilldown-sizes{height:auto;min-width:150px}.central-content-drilldown-sizes{min-width:300px;height:auto}.value-style,.name-style{font-weight:600;margin:.5rem;color:var(--pph-text-color)}.value-style-non-drilldown,.name-style-non-drilldown{font-size:20px}.value-style-drilldown,.name-style-drilldown{font-size:48px}.direction-panel{border-radius:8px;margin-right:5px;display:flex;justify-content:center;align-items:center}.direction-panel-non-drilldown{width:45px;height:45px}.direction-panel-drilldown{width:80px;height:80px}.trend-img{transform:scale(1.25)}.date-range{margin-top:1rem;font-size:16px;text-align:center}@media (max-width: 1024px){.central-content-drilldown-sizes{min-width:250px}.value-style-drilldown,.name-style-drilldown{font-size:36px}}@media (max-width: 768px){.central-content{flex-direction:column}.value-style-drilldown,.name-style-drilldown{font-size:28px}.date-range{font-size:14px}}@media (max-width: 480px){.central-content{min-width:200px;padding:.5rem}.value-style,.name-style{font-size:18px}.direction-panel{width:40px;height:40px}.trend-img{transform:scale(1)}.date-range{font-size:12px}}\n", ".lib-chart-wrapper{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;background:#fff 0% 0% no-repeat padding-box;position:relative}.lib-chart-wrapper-wo-shadow{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background){background-color:#2e3640}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background) .chart-title{color:#fff}.lib-chart-svg{width:100%}.lib-chart-header{text-align:center;background-color:#052340;color:#fff;width:100%;height:17%;word-spacing:.5px;line-height:1.8;font-weight:700;padding-top:2%;letter-spacing:0;font-size:1.2em}.lib-donut-chart-footer{width:100%;text-align:right}.lib-donut-label-text{font-size:.9em;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-weight:400;letter-spacing:0px;color:#000;opacity:1}.lib-donut-label-icon{display:inline-block;width:10px;height:10px;margin-right:20px;border-radius:3px}.lib-donut-label-item{font-weight:400;font-size:.85em;color:#2f2f2f}.lib-donut-justified-label-wrapper{width:100%;display:inline-block;text-align:center;list-style-type:none}.lib-donut-justified-label-item{font-weight:400;font-size:.85em;color:#2f2f2f;display:inline-block;text-align:left;padding:0 10px}.lib-donut-justified-label-icon{display:inline-block;width:10px;height:10px;margin-right:5px;border-radius:3px}.lib-no-background{background:none!important}.lib-display-hidden{display:none}.lib-ylabel-weeklyCharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:12px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.07px;text-transform:capitalize;color:#000}.lib-data-labels-weeklycharts{font-style:normal;font-variant:normal;font-weight:400;font-size:12px;line-height:14px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.06px;color:#000}.lib-data-labels-angled-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:9.5px;line-height:11px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:.4px;text-anchor:start}.lib-xaxis-labels-texts-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:11px;letter-spacing:-.05px;fill:#000}.lib-xaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:-1px;color:#000;opacity:1;text-transform:capitalize}.lib-white-space-nowrap{white-space:nowrap}.lib-xaxis-labels-texts-drilldown-alt{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:10px;letter-spacing:0px;color:#000;opacity:1;text-transform:capitalize}.lib-yaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:0px;color:#000!important;opacity:1}.lib-ylabel-drilldowncharts,.lib-xlabel-drilldowncharts{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:16px;letter-spacing:-.1px;color:#000!important;opacity:1}.lib-donut-justified-label-icon-drilldown{display:inline-block;width:14px;height:14px;margin-right:10px;border-radius:50%}.marginright-2{margin-right:2%}.margintop-5{margin-top:5%}.width-100{width:100%}.float-right{float:right}.marginBottom-10{margin-bottom:10px}.header-alt{align-items:center;margin-bottom:10px}input::placeholder{font-size:20px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:0px;color:#000;opacity:1}.padding-5{padding:5px}.hidden{visibility:hidden}.font-weight-bold{font-weight:900}.textalign-center{text-align:center}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.font-weight-600{font-weight:600}.marginRight-15{margin-right:15px}.marginRight-20{margin-right:20px}.switch{position:relative;display:inline-block;width:46px;height:24px;margin-left:5px;margin-right:5px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background-color:#2d5ca0;-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:\"\";height:18px;width:18px;right:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider.round{border-radius:18px}.slider.round:before{border-radius:50%}.slider1{position:absolute;cursor:pointer;inset:0;background-color:#015ba2cf;-webkit-transition:.4s;transition:.4s}.slider1:before{position:absolute;content:\"\";height:18px;width:18px;left:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider1.round1{border-radius:18px}.slider1.round1:before{border-radius:50%}.lib-display-flex{display:flex}.lib-align-items-center{align-items:center}.lib-flex-direction-column{flex-direction:column}.lib-justify-content-space-between{justify-content:space-between}.lib-justify-content-space-around{justify-content:space-around}.lib-justify-content-center{justify-content:center}.lib-justify-content-start{justify-content:start}.lib-justify-content-end{justify-content:end}.lib-ml-20{margin-left:20px}.lib-position-absolute{position:absolute}.lib-z-index-9{z-index:9}.marginright-3{margin-right:3px}@media (min-height: 900px){.lib-chart-wrapper{border-radius:8px}.header-font-size-1{font-size:18px!important}.font-size-1{font-size:14px!important}.font-size-2{font-size:16px!important}.font-size-3{font-size:14px!important}.font-size-4{font-size:22px!important}.font-size-5{font-size:24px!important}}\n"] }]
9860
+ args: [{ selector: 'lib-plain-trend', encapsulation: ViewEncapsulation.None, template: "<div #piecontainer class=\"lib-chart-wrapper\" style=\"background-color: var(--card-bg);\">\r\n <lib-chart-header-v1\r\n *ngIf=\"isHeaderVisible\"\r\n [title]=\"chartData.metaData.title\"\r\n [hasDrillDown]=\"chartData.metaData.hasDrillDown\"\r\n [isEditEnabled]=\"chartData.metaData.isEditEnabled\"\r\n [menuOptions]=\"chartConfiguration.headerMenuOptions\"\r\n [selectedKpiTooltop]=\"chartConfiguration.selectedKpiTooltop\"\r\n [isria]=\"customChartConfiguration.isRia\"\r\n [isAlertEnabled]=\"isAlertEnabled\"\r\n (menuOptionClickEvent)=\"handleHeaderMenuClick($event)\"\r\n ></lib-chart-header-v1>\r\n\r\n <ng-container *ngIf=\"chartConfiguration.isToggleVisible && !isHeaderVisible && chartData.data.value > 0\">\r\n <lib-chart-header-v2\r\n [chartData]=\"chartData\"\r\n [chartConfiguration]=\"chartConfiguration\"\r\n (clickEvent)=\"handleClick($event)\"\r\n ></lib-chart-header-v2>\r\n </ng-container>\r\n\r\n <div\r\n #plaintrendcontainer\r\n id=\"trendchartcontainer\"\r\n class=\"lib-chart-svg trendcontainer\"\r\n [style.height]=\"chartConfiguration.svgHeight\"\r\n >\r\n <div\r\n class=\"central-content\"\r\n [ngClass]=\"{\r\n 'central-content-non-drilldown-sizes': isHeaderVisible,\r\n 'central-content-drilldown-sizes': !isHeaderVisible,\r\n 'lib-justify-content-space-around': chartData.data.bgColor,\r\n 'lib-justify-content-center': !chartData.data.bgColor\r\n }\"\r\n (click)=\"handleClick(chartData.data.daterange)\"\r\n >\r\n <span\r\n class=\"value-style\"\r\n [ngClass]=\"{\r\n 'value-style-non-drilldown': isHeaderVisible,\r\n 'value-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.value | number: '1.0-2' }}\r\n </span>\r\n\r\n <span\r\n class=\"name-style\"\r\n [ngClass]=\"{\r\n 'name-style-non-drilldown': isHeaderVisible,\r\n 'name-style-drilldown': !isHeaderVisible\r\n }\"\r\n >\r\n {{ chartData.data.name }}\r\n </span>\r\n\r\n <div\r\n *ngIf=\"chartData.data.bgColor\"\r\n class=\"direction-panel\"\r\n [ngClass]=\"{\r\n 'direction-panel-non-drilldown': isHeaderVisible,\r\n 'direction-panel-drilldown': !isHeaderVisible\r\n }\"\r\n [style.backgroundColor]=\"chartData.data.bgColor\"\r\n >\r\n <ng-container [ngSwitch]=\"chartData.data.valueDirection\">\r\n <img *ngSwitchCase=\"1\" class=\"trend-img\" src=\"/assets/up-trend.png\" alt=\"up\" />\r\n <img *ngSwitchCase=\"0\" class=\"trend-img\" src=\"/assets/sameline-trend.png\" alt=\"same\" />\r\n <img *ngSwitchCase=\"-1\" class=\"trend-img\" src=\"/assets/down-trend.png\" alt=\"down\" />\r\n </ng-container>\r\n </div>\r\n </div>\r\n\r\n <div\r\n class=\"date-range\"\r\n [ngClass]=\"{ 'date-range-drilldown': !isHeaderVisible }\"\r\n >\r\n <i class=\"fa fa-calendar marginright-3\"></i>\r\n {{ chartData.data.daterange }}\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".trendcontainer{display:flex!important;justify-content:center;align-items:center;flex-direction:column;position:relative;top:0;width:100%;height:100%;padding:1rem;box-sizing:border-box}.central-content{background:#f0f0f0;display:flex;align-items:center;justify-content:center;position:relative;box-shadow:0 1px 2px #0000001a,0 3px 10px #0000004d;border-radius:8px;padding:.5rem 1rem;text-align:center;transition:all .3s ease-in-out;max-width:90%;flex-wrap:wrap}.central-content-non-drilldown-sizes{height:auto;min-width:150px}.central-content-drilldown-sizes{min-width:300px;height:auto}.value-style,.name-style{font-weight:600;margin:.5rem;color:var(--pph-text-color)}.value-style-non-drilldown,.name-style-non-drilldown{font-size:20px}.value-style-drilldown,.name-style-drilldown{font-size:48px}.direction-panel{border-radius:8px;margin-right:5px;display:flex;justify-content:center;align-items:center}.direction-panel-non-drilldown{width:45px;height:45px}.direction-panel-drilldown{width:80px;height:80px}.trend-img{transform:scale(1.25)}.date-range{margin-top:1rem;font-size:16px;text-align:center}@media (max-width: 1024px){.central-content-drilldown-sizes{min-width:250px}.value-style-drilldown,.name-style-drilldown{font-size:36px}}@media (max-width: 768px){.central-content{flex-direction:column}.value-style-drilldown,.name-style-drilldown{font-size:28px}.date-range{font-size:14px}}@media (max-width: 480px){.central-content{min-width:200px;padding:.5rem}.value-style,.name-style{font-size:18px}.direction-panel{width:40px;height:40px}.trend-img{transform:scale(1)}.date-range{font-size:12px}}\n", ".lib-chart-wrapper{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;background:#fff 0% 0% no-repeat padding-box;position:relative}.lib-chart-wrapper-wo-shadow{width:100%;height:100%;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background){background-color:#2e3640}.lib-chart-wrapper:hover .chart-header-v1:not(.header-no-background) .chart-title{color:#fff}.lib-chart-svg{width:100%}.lib-chart-header{text-align:center;background-color:#052340;color:#fff;width:100%;height:17%;word-spacing:.5px;line-height:1.8;font-weight:700;padding-top:2%;letter-spacing:0;font-size:1.2em}.lib-donut-chart-footer{width:100%;text-align:right}.lib-donut-label-text{font-size:.9em;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-weight:400;letter-spacing:0px;color:#000;opacity:1}.lib-donut-label-icon{display:inline-block;width:10px;height:10px;margin-right:20px;border-radius:3px}.lib-donut-label-item{font-weight:400;font-size:.85em;color:#2f2f2f}.lib-donut-justified-label-wrapper{width:100%;display:inline-block;text-align:center;list-style-type:none}.lib-donut-justified-label-item{font-weight:400;font-size:.85em;color:#2f2f2f;display:inline-block;text-align:left;padding:0 10px}.lib-donut-justified-label-icon{display:inline-block;width:10px;height:10px;margin-right:5px;border-radius:3px}.lib-no-background{background:none!important}.lib-display-hidden{display:none}.lib-ylabel-weeklyCharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:12px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.07px;text-transform:capitalize;color:#000}.lib-data-labels-weeklycharts{font-style:normal;font-variant:normal;font-weight:400;font-size:12px;line-height:14px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:-.06px;color:#000}.lib-data-labels-angled-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:9.5px;line-height:11px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:.4px;text-anchor:start}.lib-xaxis-labels-texts-weeklycharts{font-style:normal;font-variant:normal;font-weight:800;font-size:10px;line-height:11px;letter-spacing:-.05px;fill:#000}.lib-xaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:-1px;color:#000;opacity:1;text-transform:capitalize}.lib-white-space-nowrap{white-space:nowrap}.lib-xaxis-labels-texts-drilldown-alt{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:10px;letter-spacing:0px;color:#000;opacity:1;text-transform:capitalize}.lib-yaxis-labels-texts-drilldown{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:14px;letter-spacing:0px;color:#000!important;opacity:1}.lib-ylabel-drilldowncharts,.lib-xlabel-drilldowncharts{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;font-size:16px;letter-spacing:-.1px;color:#000!important;opacity:1}.lib-donut-justified-label-icon-drilldown{display:inline-block;width:14px;height:14px;margin-right:10px;border-radius:50%}.marginright-2{margin-right:2%}.margintop-5{margin-top:5%}.width-100{width:100%}.float-right{float:right}.marginBottom-10{margin-bottom:10px}.header-alt{align-items:center;margin-bottom:10px}input::placeholder{font-size:20px;font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto;letter-spacing:0px;color:#000;opacity:1}.padding-5{padding:5px}.hidden{visibility:hidden}.font-weight-bold{font-weight:900}.textalign-center{text-align:center}.cursor-pointer{cursor:pointer}.cursor-default{cursor:default}.font-weight-600{font-weight:600}.marginRight-15{margin-right:15px}.marginRight-20{margin-right:20px}.switch{position:relative;display:inline-block;width:46px;height:24px;margin-left:5px;margin-right:5px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background-color:#2d5ca0;-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:\"\";height:18px;width:18px;right:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider.round{border-radius:18px}.slider.round:before{border-radius:50%}.slider1{position:absolute;cursor:pointer;inset:0;background-color:#015ba2cf;-webkit-transition:.4s;transition:.4s}.slider1:before{position:absolute;content:\"\";height:18px;width:18px;left:3px;bottom:3px;background-color:#fff;-webkit-transition:.4s;transition:.4s}.slider1.round1{border-radius:18px}.slider1.round1:before{border-radius:50%}.lib-display-flex{display:flex}.lib-align-items-center{align-items:center}.lib-flex-direction-column{flex-direction:column}.lib-justify-content-space-between{justify-content:space-between}.lib-justify-content-space-around{justify-content:space-around}.lib-justify-content-center{justify-content:center}.lib-justify-content-start{justify-content:start}.lib-justify-content-end{justify-content:end}.lib-ml-20{margin-left:20px}.lib-position-absolute{position:absolute}.lib-z-index-9{z-index:9}.marginright-3{margin-right:3px}@media (min-height: 900px){.lib-chart-wrapper{border-radius:8px}.header-font-size-1{font-size:18px!important}.font-size-1{font-size:14px!important}.font-size-2{font-size:16px!important}.font-size-3{font-size:14px!important}.font-size-4{font-size:22px!important}.font-size-5{font-size:24px!important}}\n"] }]
9816
9861
  }], propDecorators: { containerElt: [{
9817
9862
  type: ViewChild,
9818
- args: ['guagechartcontainer', { static: true }]
9863
+ args: ['plaintrendcontainer', { static: true }]
9819
9864
  }], chartData: [{
9820
9865
  type: Input
9821
9866
  }], customChartConfiguration: [{