cps-ui-kit 0.18.0 → 0.20.0

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.
@@ -6,6 +6,9 @@ import { Subscription } from 'rxjs';
6
6
  import * as i1 from '@angular/forms';
7
7
  import { FormsModule } from '@angular/forms';
8
8
  import { isEqual, find } from 'lodash-es';
9
+ import * as i3 from 'primeng/tree';
10
+ import { TreeModule } from 'primeng/tree';
11
+ import * as i4 from 'primeng/api';
9
12
  import * as i2$1 from 'primeng/calendar';
10
13
  import { CalendarModule } from 'primeng/calendar';
11
14
 
@@ -253,25 +256,20 @@ class CpsProgressLinearComponent {
253
256
  this.bgColor = 'white';
254
257
  this.opacity = 1;
255
258
  this.radius = 0;
256
- this.cvtWidth = '';
257
- this.cvtHeight = '';
258
- this.cvtRadius = '';
259
- this.cvtColor = '';
260
- this.cvtBgColor = '';
261
259
  }
262
260
  ngOnInit() {
263
- this.cvtWidth = convertSize(this.width);
264
- this.cvtHeight = convertSize(this.height);
265
- this.cvtRadius = convertSize(this.radius);
266
- this.cvtColor = getCSSColor(this.color);
267
- this.cvtBgColor = getCSSColor(this.bgColor);
261
+ this.width = convertSize(this.width);
262
+ this.height = convertSize(this.height);
263
+ this.radius = convertSize(this.radius);
264
+ this.color = getCSSColor(this.color);
265
+ this.bgColor = getCSSColor(this.bgColor);
268
266
  }
269
267
  }
270
268
  CpsProgressLinearComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsProgressLinearComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
271
- CpsProgressLinearComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: CpsProgressLinearComponent, isStandalone: true, selector: "cps-progress-linear", inputs: { width: "width", height: "height", color: "color", bgColor: "bgColor", opacity: "opacity", radius: "radius" }, ngImport: i0, template: "<div\n class=\"cps-progress-linear\"\n [ngStyle]=\"{\n 'max-width': cvtWidth,\n height: cvtHeight,\n 'border-radius': cvtRadius,\n background: cvtBgColor\n }\">\n <div\n class=\"cps-progress-linear-line inc\"\n [style.background]=\"cvtColor\"\n [style.opacity]=\"opacity\"></div>\n <div\n class=\"cps-progress-linear-line dec\"\n [style.background]=\"cvtColor\"\n [style.opacity]=\"opacity\"></div>\n</div>\n", styles: [":host{width:100%}:host .cps-progress-linear{position:relative;overflow-x:hidden}:host .cps-progress-linear-line{position:absolute;height:inherit;left:-5%;top:0}:host .cps-progress-linear .inc{animation:increase 2s infinite}:host .cps-progress-linear .dec{animation:decrease 2s .5s infinite}@keyframes increase{0%{left:-5%;width:5%}to{left:130%;width:100%}}@keyframes decrease{0%{left:-80%;width:80%}to{left:110%;width:10%}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }] });
269
+ CpsProgressLinearComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: CpsProgressLinearComponent, isStandalone: true, selector: "cps-progress-linear", inputs: { width: "width", height: "height", color: "color", bgColor: "bgColor", opacity: "opacity", radius: "radius" }, ngImport: i0, template: "<div\n class=\"cps-progress-linear\"\n [ngStyle]=\"{\n 'max-width': width,\n height: height,\n 'border-radius': radius,\n background: bgColor\n }\">\n <div\n class=\"cps-progress-linear-line inc\"\n [style.background]=\"color\"\n [style.opacity]=\"opacity\"></div>\n <div\n class=\"cps-progress-linear-line dec\"\n [style.background]=\"color\"\n [style.opacity]=\"opacity\"></div>\n</div>\n", styles: [":host{width:100%}:host .cps-progress-linear{position:relative;overflow-x:hidden}:host .cps-progress-linear-line{position:absolute;height:inherit;left:-5%;top:0}:host .cps-progress-linear .inc{animation:increase 2s infinite}:host .cps-progress-linear .dec{animation:decrease 2s .5s infinite}@keyframes increase{0%{left:-5%;width:5%}to{left:130%;width:100%}}@keyframes decrease{0%{left:-80%;width:80%}to{left:110%;width:10%}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }] });
272
270
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsProgressLinearComponent, decorators: [{
273
271
  type: Component,
274
- args: [{ standalone: true, imports: [CommonModule], selector: 'cps-progress-linear', template: "<div\n class=\"cps-progress-linear\"\n [ngStyle]=\"{\n 'max-width': cvtWidth,\n height: cvtHeight,\n 'border-radius': cvtRadius,\n background: cvtBgColor\n }\">\n <div\n class=\"cps-progress-linear-line inc\"\n [style.background]=\"cvtColor\"\n [style.opacity]=\"opacity\"></div>\n <div\n class=\"cps-progress-linear-line dec\"\n [style.background]=\"cvtColor\"\n [style.opacity]=\"opacity\"></div>\n</div>\n", styles: [":host{width:100%}:host .cps-progress-linear{position:relative;overflow-x:hidden}:host .cps-progress-linear-line{position:absolute;height:inherit;left:-5%;top:0}:host .cps-progress-linear .inc{animation:increase 2s infinite}:host .cps-progress-linear .dec{animation:decrease 2s .5s infinite}@keyframes increase{0%{left:-5%;width:5%}to{left:130%;width:100%}}@keyframes decrease{0%{left:-80%;width:80%}to{left:110%;width:10%}}\n"] }]
272
+ args: [{ standalone: true, imports: [CommonModule], selector: 'cps-progress-linear', template: "<div\n class=\"cps-progress-linear\"\n [ngStyle]=\"{\n 'max-width': width,\n height: height,\n 'border-radius': radius,\n background: bgColor\n }\">\n <div\n class=\"cps-progress-linear-line inc\"\n [style.background]=\"color\"\n [style.opacity]=\"opacity\"></div>\n <div\n class=\"cps-progress-linear-line dec\"\n [style.background]=\"color\"\n [style.opacity]=\"opacity\"></div>\n</div>\n", styles: [":host{width:100%}:host .cps-progress-linear{position:relative;overflow-x:hidden}:host .cps-progress-linear-line{position:absolute;height:inherit;left:-5%;top:0}:host .cps-progress-linear .inc{animation:increase 2s infinite}:host .cps-progress-linear .dec{animation:decrease 2s .5s infinite}@keyframes increase{0%{left:-5%;width:5%}to{left:130%;width:100%}}@keyframes decrease{0%{left:-80%;width:80%}to{left:110%;width:10%}}\n"] }]
275
273
  }], propDecorators: { width: [{
276
274
  type: Input
277
275
  }], height: [{
@@ -719,7 +717,7 @@ class CpsSelectComponent {
719
717
  selected.scrollIntoView({
720
718
  behavior: 'instant',
721
719
  block: 'nearest',
722
- inline: 'start'
720
+ inline: 'center'
723
721
  });
724
722
  }
725
723
  }
@@ -794,7 +792,7 @@ class CpsSelectComponent {
794
792
  if (elRect.top < parentRect.top || elRect.bottom > parentRect.bottom) {
795
793
  el.scrollIntoView({
796
794
  block: 'nearest',
797
- inline: 'start'
795
+ inline: 'center'
798
796
  });
799
797
  }
800
798
  }
@@ -1007,6 +1005,468 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
1007
1005
  args: ['selectContainer']
1008
1006
  }] } });
1009
1007
 
1008
+ class CpsTreeSelectComponent {
1009
+ set options(options) {
1010
+ if (options === null || options === void 0 ? void 0 : options.some((o) => o.inner)) {
1011
+ this._options = options;
1012
+ return;
1013
+ }
1014
+ this._options = this._toInnerOptions(options);
1015
+ }
1016
+ get options() {
1017
+ return this._options;
1018
+ }
1019
+ set value(value) {
1020
+ this._value = value;
1021
+ this.onChange(value);
1022
+ }
1023
+ get value() {
1024
+ return this._value;
1025
+ }
1026
+ constructor(_control, cdRef) {
1027
+ this._control = _control;
1028
+ this.cdRef = cdRef;
1029
+ this.label = '';
1030
+ this.placeholder = 'Please select';
1031
+ this.hint = '';
1032
+ this.multiple = false;
1033
+ this.disabled = false;
1034
+ this.width = '100%';
1035
+ this.chips = true;
1036
+ this.closableChips = true;
1037
+ this.clearable = false;
1038
+ this.openOnClear = true;
1039
+ this.optionLabel = 'label';
1040
+ this.optionInfo = 'info';
1041
+ this.hideDetails = false;
1042
+ this.persistentClear = false;
1043
+ this.prefixIcon = '';
1044
+ this.prefixIconSize = '18px';
1045
+ this.loading = false;
1046
+ this.virtualScroll = false;
1047
+ this._value = undefined;
1048
+ this.valueChanged = new EventEmitter();
1049
+ this._statusChangesSubscription = new Subscription();
1050
+ this._options = [];
1051
+ this.optionsMap = new Map();
1052
+ this.originalOptionsMap = new Map();
1053
+ this.virtualListHeight = 240;
1054
+ this.virtualScrollItemSize = 40;
1055
+ this.error = '';
1056
+ this.cvtWidth = '';
1057
+ this.isOpened = false;
1058
+ this.optionFocused = false;
1059
+ // eslint-disable-next-line @typescript-eslint/no-empty-function
1060
+ this.onChange = (value) => { };
1061
+ // eslint-disable-next-line @typescript-eslint/no-empty-function
1062
+ this.onTouched = () => { };
1063
+ if (this._control) {
1064
+ this._control.valueAccessor = this;
1065
+ }
1066
+ }
1067
+ ngOnInit() {
1068
+ var _a, _b;
1069
+ this.cvtWidth = convertSize(this.width);
1070
+ if (!this._value) {
1071
+ if (this.multiple) {
1072
+ this._value = [];
1073
+ this.treeSelection = [];
1074
+ }
1075
+ }
1076
+ else {
1077
+ this.treeSelection = this._valueToTreeSelection(this.value);
1078
+ }
1079
+ this._statusChangesSubscription = (_b = (_a = this._control) === null || _a === void 0 ? void 0 : _a.statusChanges) === null || _b === void 0 ? void 0 : _b.subscribe(() => {
1080
+ this._checkErrors();
1081
+ });
1082
+ }
1083
+ ngAfterViewInit() {
1084
+ this._initContainerClickListener();
1085
+ this.recalcVirtualListHeight();
1086
+ this.cdRef.detectChanges();
1087
+ }
1088
+ ngOnDestroy() {
1089
+ var _a;
1090
+ (_a = this._statusChangesSubscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
1091
+ if (this.treeContainerElement)
1092
+ this.treeContainerElement.removeEventListener('click', this._handleOnContainerClick.bind(this));
1093
+ }
1094
+ _initContainerClickListener() {
1095
+ var _a, _b, _c;
1096
+ this.treeContainerElement =
1097
+ (_c = (_b = (_a = this.treeList) === null || _a === void 0 ? void 0 : _a.el) === null || _b === void 0 ? void 0 : _b.nativeElement) === null || _c === void 0 ? void 0 : _c.querySelector('.p-tree-container');
1098
+ if (this.treeContainerElement) {
1099
+ this.treeContainerElement.addEventListener('click', this._handleOnContainerClick.bind(this));
1100
+ }
1101
+ }
1102
+ _handleOnContainerClick(event) {
1103
+ var _a, _b;
1104
+ function getParentWithClass(element, className) {
1105
+ let currentElement = element;
1106
+ while (currentElement) {
1107
+ if (currentElement.classList.contains(className)) {
1108
+ return currentElement;
1109
+ }
1110
+ currentElement = currentElement.parentElement;
1111
+ }
1112
+ return null;
1113
+ }
1114
+ this.optionFocused = true;
1115
+ const parent = event.target.classList.contains('p-treenode-content')
1116
+ ? event.target
1117
+ : getParentWithClass(event.target, 'p-treenode-content');
1118
+ if ((_b = (_a = parent === null || parent === void 0 ? void 0 : parent.parentElement) === null || _a === void 0 ? void 0 : _a.classList) === null || _b === void 0 ? void 0 : _b.contains('cps-tree-node-fully-expandable')) {
1119
+ this.onClickFullyExpandable(event, parent.parentElement);
1120
+ }
1121
+ }
1122
+ registerOnChange(fn) {
1123
+ this.onChange = fn;
1124
+ }
1125
+ registerOnTouched(fn) {
1126
+ this.onTouched = fn;
1127
+ }
1128
+ writeValue(value) {
1129
+ this.value = value;
1130
+ }
1131
+ updateValue(value) {
1132
+ this.writeValue(value);
1133
+ this.onChange(value);
1134
+ this.valueChanged.emit(value);
1135
+ }
1136
+ onSelectNode() {
1137
+ var _a;
1138
+ if (!this.multiple) {
1139
+ this._toggleOptions((_a = this.selectContainer) === null || _a === void 0 ? void 0 : _a.nativeElement, false);
1140
+ }
1141
+ }
1142
+ onClickOutside(dd) {
1143
+ this._toggleOptions(dd, false);
1144
+ }
1145
+ onBoxClick(dd) {
1146
+ this._toggleOptions(dd);
1147
+ }
1148
+ onKeyDown(event, dd) {
1149
+ event.preventDefault();
1150
+ const code = event.keyCode;
1151
+ // escape
1152
+ if (code === 27) {
1153
+ this._toggleOptions(dd, false);
1154
+ }
1155
+ // click down arrow
1156
+ else if ([40].includes(code)) {
1157
+ this._initArrowsNavigaton();
1158
+ }
1159
+ }
1160
+ onClickFullyExpandable(event, elem) {
1161
+ const key = this._getHTMLElementKey(elem);
1162
+ if (!key)
1163
+ return;
1164
+ const treeNode = this.options.find((o) => o.key === key);
1165
+ if (!treeNode)
1166
+ return;
1167
+ treeNode.expanded = !treeNode.expanded;
1168
+ this._updateOptions();
1169
+ setTimeout(() => {
1170
+ this.recalcVirtualListHeight();
1171
+ });
1172
+ }
1173
+ _getHTMLElementKey(elem) {
1174
+ if (!(elem === null || elem === void 0 ? void 0 : elem.classList))
1175
+ return '';
1176
+ const classList = [...elem.classList];
1177
+ const key = classList.find((className) => {
1178
+ return className.startsWith('key-');
1179
+ });
1180
+ if (!key)
1181
+ return '';
1182
+ return key.replace('key-', '');
1183
+ }
1184
+ treeSelectionChanged(selection) {
1185
+ this.updateValue(this._treeSelectionToValue(selection));
1186
+ }
1187
+ recalcVirtualListHeight() {
1188
+ var _a, _b;
1189
+ if (!this.virtualScroll)
1190
+ return;
1191
+ const currentLen = ((_b = (_a = this.treeList) === null || _a === void 0 ? void 0 : _a.serializedValue) === null || _b === void 0 ? void 0 : _b.length) || 0;
1192
+ this.virtualListHeight = Math.min(this.virtualScrollItemSize * currentLen, 240);
1193
+ }
1194
+ _toggleOptions(dd, show) {
1195
+ if (this.disabled || !dd)
1196
+ return;
1197
+ if (typeof show === 'boolean') {
1198
+ if (show)
1199
+ dd.classList.add('active');
1200
+ else
1201
+ dd.classList.remove('active');
1202
+ }
1203
+ else
1204
+ dd.classList.toggle('active');
1205
+ this.isOpened = dd.classList.contains('active');
1206
+ this.optionFocused = false;
1207
+ if (this.isOpened && this.treeSelection) {
1208
+ this._expandToNodes(this.multiple ? this.treeSelection : [this.treeSelection]);
1209
+ this._updateOptions();
1210
+ setTimeout(() => {
1211
+ var _a, _b;
1212
+ this.recalcVirtualListHeight();
1213
+ const selected = this.selectContainer.nativeElement.querySelector('.p-highlight');
1214
+ if (selected) {
1215
+ selected.scrollIntoView({
1216
+ behavior: 'instant',
1217
+ block: 'nearest',
1218
+ inline: 'center'
1219
+ });
1220
+ }
1221
+ else if (this.virtualScroll && this.treeSelection) {
1222
+ let key = '';
1223
+ if (this.multiple) {
1224
+ if (this.treeSelection.length > 0)
1225
+ key = this.treeSelection[0].key;
1226
+ }
1227
+ else
1228
+ key = this.treeSelection.key;
1229
+ if (key) {
1230
+ const idx = ((_b = (_a = this.treeList) === null || _a === void 0 ? void 0 : _a.serializedValue) === null || _b === void 0 ? void 0 : _b.findIndex((v) => v.node.key === key)) || -1;
1231
+ if (idx >= 0)
1232
+ this.treeList.scrollToVirtualIndex(idx);
1233
+ }
1234
+ }
1235
+ });
1236
+ }
1237
+ }
1238
+ remove(option) {
1239
+ if (!this.multiple)
1240
+ return;
1241
+ this.treeSelection = this.treeSelection.filter((v) => !isEqual(v, option));
1242
+ this.updateValue(this._treeSelectionToValue(this.treeSelection));
1243
+ }
1244
+ _initArrowsNavigaton() {
1245
+ var _a;
1246
+ if (!this.isOpened)
1247
+ return;
1248
+ if (!this.optionFocused) {
1249
+ const firstElem = (_a = this.treeContainerElement) === null || _a === void 0 ? void 0 : _a.querySelector('.p-treenode-content');
1250
+ if (firstElem)
1251
+ firstElem.focus();
1252
+ this.optionFocused = true;
1253
+ }
1254
+ }
1255
+ clear(dd, event) {
1256
+ var _a;
1257
+ event.stopPropagation();
1258
+ if ((!this.multiple && this.treeSelection) ||
1259
+ (this.multiple && ((_a = this.treeSelection) === null || _a === void 0 ? void 0 : _a.length) > 0)) {
1260
+ if (this.openOnClear) {
1261
+ this._toggleOptions(dd, true);
1262
+ }
1263
+ const val = this.multiple ? [] : undefined;
1264
+ this.treeSelection = val;
1265
+ this.updateValue(val);
1266
+ }
1267
+ this.optionFocused = false;
1268
+ }
1269
+ _checkErrors() {
1270
+ var _a, _b, _c;
1271
+ const errors = (_a = this._control) === null || _a === void 0 ? void 0 : _a.errors;
1272
+ if (!((_c = (_b = this._control) === null || _b === void 0 ? void 0 : _b.control) === null || _c === void 0 ? void 0 : _c.touched) || !errors) {
1273
+ this.error = '';
1274
+ return;
1275
+ }
1276
+ if ('required' in errors) {
1277
+ this.error = 'Field is required';
1278
+ return;
1279
+ }
1280
+ const errArr = Object.values(errors);
1281
+ if (errArr.length < 1) {
1282
+ this.error = '';
1283
+ return;
1284
+ }
1285
+ const message = errArr.find((msg) => typeof msg === 'string');
1286
+ this.error = message || 'Unknown error';
1287
+ }
1288
+ // eslint-disable-next-line @typescript-eslint/no-empty-function
1289
+ setDisabledState(disabled) { }
1290
+ onBlur() {
1291
+ var _a, _b;
1292
+ (_b = (_a = this._control) === null || _a === void 0 ? void 0 : _a.control) === null || _b === void 0 ? void 0 : _b.markAsTouched();
1293
+ this._checkErrors();
1294
+ }
1295
+ focus() {
1296
+ var _a, _b, _c;
1297
+ (_b = (_a = this.selectContainer) === null || _a === void 0 ? void 0 : _a.nativeElement) === null || _b === void 0 ? void 0 : _b.focus();
1298
+ this._toggleOptions((_c = this.selectContainer) === null || _c === void 0 ? void 0 : _c.nativeElement, true);
1299
+ }
1300
+ _expandToNodes(nodes) {
1301
+ function getParentKey(key) {
1302
+ const lastSeparatorIndex = key.lastIndexOf('-');
1303
+ if (lastSeparatorIndex !== -1) {
1304
+ return key.substring(0, lastSeparatorIndex);
1305
+ }
1306
+ return '';
1307
+ }
1308
+ nodes.forEach((node) => {
1309
+ const parentNodeKey = getParentKey(node.key);
1310
+ const parentNode = this.optionsMap.get(parentNodeKey) || null;
1311
+ if (parentNode) {
1312
+ parentNode.expanded = true;
1313
+ this._expandToNodes([parentNode]);
1314
+ }
1315
+ });
1316
+ }
1317
+ _toInnerOptions(_options) {
1318
+ function mapOption(o, optionLabel, optionInfo, key, originalOptionsMap) {
1319
+ const inner = {
1320
+ inner: true,
1321
+ label: o[optionLabel],
1322
+ info: o[optionInfo],
1323
+ key,
1324
+ styleClass: 'key-' + key
1325
+ };
1326
+ if (o.type === 'directory') {
1327
+ inner.type = 'directory';
1328
+ inner.selectable = false;
1329
+ inner.styleClass += ' cps-tree-node-fully-expandable';
1330
+ }
1331
+ if (o.children) {
1332
+ inner.children = o.children.map((c, index) => {
1333
+ return mapOption(c, optionLabel, optionInfo, key + '-' + index, originalOptionsMap);
1334
+ });
1335
+ }
1336
+ originalOptionsMap.set(key, o);
1337
+ return inner;
1338
+ }
1339
+ const res = _options.map((option, index) => {
1340
+ return mapOption(option, this.optionLabel, this.optionInfo, '' + index, this.originalOptionsMap);
1341
+ });
1342
+ this.optionsMap = this._buildOptionsMap(res);
1343
+ return res;
1344
+ }
1345
+ _buildOptionsMap(options) {
1346
+ const nodeMap = new Map();
1347
+ for (const option of options) {
1348
+ nodeMap.set(option.key, option);
1349
+ if (option.children) {
1350
+ const childNodeMap = this._buildOptionsMap(option.children);
1351
+ childNodeMap.forEach((value, key) => nodeMap.set(key, value));
1352
+ }
1353
+ }
1354
+ return nodeMap;
1355
+ }
1356
+ _treeSelectionToValue(selection) {
1357
+ if (!selection)
1358
+ return this.multiple ? [] : undefined;
1359
+ if (this.multiple) {
1360
+ return selection.map((s) => this.originalOptionsMap.get(s.key));
1361
+ }
1362
+ else {
1363
+ return this.originalOptionsMap.get(selection.key);
1364
+ }
1365
+ }
1366
+ _valueToTreeSelection(value) {
1367
+ function getKey(v, map) {
1368
+ for (const [key, val] of map.entries()) {
1369
+ if (isEqual(v, val)) {
1370
+ return key;
1371
+ }
1372
+ }
1373
+ return '';
1374
+ }
1375
+ if (!value)
1376
+ return this.multiple ? [] : undefined;
1377
+ if (this.multiple) {
1378
+ const res = [];
1379
+ value.forEach((v) => {
1380
+ const key = getKey(v, this.originalOptionsMap);
1381
+ if (key)
1382
+ res.push(this.optionsMap.get(key));
1383
+ });
1384
+ return res;
1385
+ }
1386
+ else {
1387
+ const key = getKey(value, this.originalOptionsMap);
1388
+ return key ? this.optionsMap.get(key) : undefined;
1389
+ }
1390
+ }
1391
+ // this is a fix of primeng change detection bug when virtual scroller is enabled
1392
+ _updateOptions() {
1393
+ if (!this.virtualScroll)
1394
+ return;
1395
+ this.options = [...this.options];
1396
+ }
1397
+ }
1398
+ CpsTreeSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsTreeSelectComponent, deps: [{ token: i1.NgControl, optional: true, self: true }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1399
+ CpsTreeSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: CpsTreeSelectComponent, isStandalone: true, selector: "cps-tree-select", inputs: { label: "label", placeholder: "placeholder", hint: "hint", multiple: "multiple", disabled: "disabled", width: "width", chips: "chips", closableChips: "closableChips", clearable: "clearable", openOnClear: "openOnClear", optionLabel: "optionLabel", optionInfo: "optionInfo", hideDetails: "hideDetails", persistentClear: "persistentClear", prefixIcon: "prefixIcon", prefixIconSize: "prefixIconSize", loading: "loading", virtualScroll: "virtualScroll", options: "options", _value: ["value", "_value"] }, outputs: { valueChanged: "valueChanged" }, providers: [LabelByValuePipe, CombineLabelsPipe], viewQueries: [{ propertyName: "selectContainer", first: true, predicate: ["selectContainer"], descendants: true }, { propertyName: "treeList", first: true, predicate: ["treeList"], descendants: true }], ngImport: i0, template: "<div\n [ngStyle]=\"{ width: cvtWidth }\"\n class=\"cps-treeselect\"\n tabindex=\"0\"\n [ngClass]=\"{ disabled: disabled, error: error }\"\n #selectContainer\n (keydown)=\"onKeyDown($event, selectContainer)\"\n (blur)=\"onBlur()\">\n <label *ngIf=\"label\" class=\"cps-treeselect-label\">{{ label }} </label>\n <div\n class=\"cps-treeselect-container\"\n [class.focused]=\"isOpened\"\n [ngClass]=\"{\n 'persistent-clear': persistentClear\n }\"\n (clickOutside)=\"onClickOutside(selectContainer)\">\n <div class=\"cps-treeselect-box\" (click)=\"onBoxClick(selectContainer)\">\n <div class=\"cps-treeselect-box-left\">\n <cps-icon\n *ngIf=\"prefixIcon\"\n [icon]=\"prefixIcon\"\n [size]=\"prefixIconSize\"\n class=\"prefix-icon\">\n </cps-icon>\n <div\n class=\"cps-treeselect-box-placeholder\"\n *ngIf=\"\n (!treeSelection && !multiple) ||\n (treeSelection?.length < 1 && multiple)\n \">\n {{ placeholder }}\n </div>\n <div\n class=\"cps-treeselect-box-items\"\n *ngIf=\"\n (treeSelection && !multiple) ||\n (treeSelection?.length > 0 && multiple)\n \">\n <span *ngIf=\"!multiple\" class=\"single-item\">\n {{ treeSelection.label }}</span\n >\n <div *ngIf=\"multiple && !chips\" class=\"text-group\">\n <span class=\"text-group-item\">\n {{\n treeSelection | combineLabels : options : '' : 'label' : true\n }}\n </span>\n </div>\n\n <div *ngIf=\"multiple && chips\" class=\"chips-group\">\n <cps-chip\n *ngFor=\"let val of treeSelection\"\n [disabled]=\"disabled\"\n [closable]=\"closableChips\"\n (closed)=\"remove(val)\"\n [label]=\"val.label\">\n </cps-chip>\n </div>\n </div>\n </div>\n <span class=\"cps-treeselect-box-icons\">\n <span\n *ngIf=\"clearable && !disabled\"\n [style.visibility]=\"\n persistentClear ||\n (!persistentClear &&\n ((multiple && treeSelection?.length) ||\n (!multiple && treeSelection)))\n ? 'visible'\n : 'hidden'\n \"\n class=\"cps-treeselect-box-clear-icon\">\n <cps-icon\n icon=\"delete\"\n size=\"small\"\n (click)=\"clear(selectContainer, $event)\"></cps-icon>\n </span>\n <span class=\"cps-treeselect-box-chevron\">\n <cps-icon\n icon=\"chevron-down\"\n size=\"small\"\n color=\"text-dark\"></cps-icon>\n </span>\n </span>\n </div>\n\n <div class=\"cps-treeselect-options\">\n <p-tree\n #treeList\n [virtualScroll]=\"virtualScroll\"\n [virtualScrollItemSize]=\"virtualScrollItemSize\"\n [virtualScrollOptions]=\"{ numToleratedItems: 3 }\"\n [scrollHeight]=\"virtualListHeight + 'px'\"\n (onNodeSelect)=\"onSelectNode()\"\n (onNodeExpand)=\"recalcVirtualListHeight()\"\n (onNodeCollapse)=\"recalcVirtualListHeight()\"\n [value]=\"options\"\n [(selection)]=\"treeSelection\"\n (selectionChange)=\"treeSelectionChanged($event)\"\n [metaKeySelection]=\"multiple ? false : true\"\n [selectionMode]=\"multiple ? 'multiple' : 'single'\">\n <ng-template let-node pTemplate=\"directory\">\n <span class=\"cps-treeselect-directory-elem\">{{ node.label }}</span>\n </ng-template>\n <ng-template let-node pTemplate=\"default\">\n <span class=\"cps-treeselect-option\">\n <span class=\"cps-treeselect-option-left\">\n <span *ngIf=\"multiple\" class=\"cps-treeselect-option-check\">\n </span>\n <span class=\"cps-treeselect-option-label\">{{ node.label }}</span>\n </span>\n <span class=\"cps-treeselect-option-info\">{{ node.info }}</span>\n </span>\n </ng-template>\n </p-tree>\n </div>\n <cps-progress-linear\n *ngIf=\"loading\"\n height=\"3\"\n radius=\"4\"\n opacity=\"0.3\"\n class=\"treeselect-progress-bar\"\n bgColor=\"transparent\">\n </cps-progress-linear>\n </div>\n <div *ngIf=\"!error && !hideDetails\" class=\"cps-treeselect-hint\">\n {{ hint }}\n </div>\n <div *ngIf=\"error && !hideDetails\" class=\"cps-treeselect-error\">\n {{ error }}\n </div>\n</div>\n", styles: [":host{display:flex}:host .cps-treeselect{position:relative;width:100%;outline:none;font-family:Source Sans Pro,sans-serif;display:grid}:host .cps-treeselect-container{position:relative}:host .cps-treeselect-container .treeselect-progress-bar{position:absolute;bottom:1px;padding:0 1px}:host .cps-treeselect.active .cps-treeselect-options{display:block}:host .cps-treeselect.active .cps-treeselect-box{border:1px solid var(--cps-color-calm)}:host .cps-treeselect.active .cps-treeselect-box .cps-treeselect-box-left .prefix-icon{color:var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-label{display:inline-block;margin-bottom:.2rem;color:var(--cps-color-text-dark);font-size:.875rem}:host .cps-treeselect .persistent-clear .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon,:host .cps-treeselect .cps-treeselect-container.focused .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon,:host .cps-treeselect .cps-treeselect-container:hover .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon{opacity:.5}:host .cps-treeselect .cps-treeselect-box{overflow:hidden;justify-content:space-between;min-height:38px;width:100%;cursor:pointer;background:white;font-size:1rem;outline:none;padding:0 12px;border-radius:4px;align-items:center;display:flex;border:1px solid var(--cps-color-text-lightest);transition-duration:.2s}:host .cps-treeselect .cps-treeselect-box-placeholder{color:var(--cps-color-text-lightest);font-style:italic}:host .cps-treeselect .cps-treeselect-box-items{margin-top:3px;margin-bottom:3px}:host .cps-treeselect .cps-treeselect-box-items .text-group,:host .cps-treeselect .cps-treeselect-box-items .single-item{color:var(--cps-color-text-dark);padding-top:3px;padding-bottom:3px}:host .cps-treeselect .cps-treeselect-box-items .chips-group cps-chip{padding-bottom:3px;padding-top:3px;padding-right:4px}:host .cps-treeselect .cps-treeselect-box-items .text-group-item{line-height:1.5}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-left{display:inline-flex;align-items:center}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-left .prefix-icon{margin-right:.5rem;color:var(--cps-color-text-dark)}:host .cps-treeselect .cps-treeselect-box:hover{border:1px solid var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-box:hover .cps-treeselect-box-left .prefix-icon{color:var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons{display:flex}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon{display:flex;color:var(--cps-color-calm);margin-left:8px}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon{opacity:0;transition-duration:.2s}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon:hover{opacity:1!important}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-chevron{display:flex;margin-left:8px;transition-duration:.2s}:host .cps-treeselect.active .cps-treeselect-box-chevron{top:22px;transform:rotate(180deg)}:host .cps-treeselect .cps-treeselect-options{z-index:1001;position:absolute;width:100%;background:white;box-shadow:0 5px 20px #0000000d;border-radius:4px;overflow-x:hidden;display:none;max-height:242px;overflow-y:auto;box-shadow:0 2px 4px -1px #0003,0 4px 5px #00000024,0 1px 10px #0000001f}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree{border:1px solid #dee2e6;background:#ffffff;color:var(--cps-color-text-dark);padding:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option{margin-right:8px;display:flex;align-items:center;justify-content:space-between}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-left{display:flex;align-items:center;margin-right:8px}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-check{background-color:transparent;border:0;width:16px;height:16px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0,0,.2,.1),background-color 90ms cubic-bezier(0,0,.2,.1);margin-right:8px;opacity:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-check:after{color:var(--cps-color-calm);top:4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box;position:absolute;content:\"\";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0,0,.2,.1)}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-info{margin-left:6px;color:var(--cps-color-text-light)}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-component{font-family:Source Sans Pro,sans-serif;font-size:14px;font-weight:400}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-wrapper{overflow:auto}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-container{margin:0;padding:0;list-style-type:none;overflow:auto}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content{transition:box-shadow .2s;padding:.25rem}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-treenode-content{display:flex;align-items:center}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-treenode-content .p-treenode-label{width:100%}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content .p-tree-toggler{margin-right:.5rem;width:2rem;height:2rem;color:var(--cps-color-text-light);border:0 none;background:transparent;border-radius:50%;transition:background-color .2s,color .2s,box-shadow .2s}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content:not(.p-highlight):hover{background:#f8f4f5}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content:focus{outline:0 none;outline-offset:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content:not(.p-highlight):focus{background-color:#f8f4f5}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content.p-highlight{background:#efe4e7;color:var(--cps-color-calm);font-weight:600}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content.p-highlight .cps-treeselect-option-check{opacity:1}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-toggler{outline:0 none;outline-offset:0;cursor:pointer;-webkit-user-select:none;user-select:none;display:inline-flex;align-items:center;justify-content:center;overflow:hidden;position:relative;flex-shrink:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-toggler :hover{color:var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-tree-node-fully-expandable>.p-treenode-content:hover .p-tree-toggler{color:var(--cps-color-calm)!important}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-treenode-children{padding:0 0 0 1rem}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-treenode-children{margin:0;padding:0;list-style-type:none}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-tree-node-fully-expandable{cursor:pointer;-webkit-user-select:none;user-select:none}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-directory-elem{font-weight:700;font-size:16px}:host .cps-treeselect .cps-treeselect-hint{color:var(--cps-color-text-mild);font-size:.75rem;min-height:1.125rem;cursor:default;margin-top:.2rem}:host .cps-treeselect .cps-treeselect-error{color:#c33;font-weight:700;font-size:.75rem;min-height:1.125rem;cursor:default;margin-top:.2rem}:host .cps-treeselect.disabled{pointer-events:none}:host .cps-treeselect.disabled .cps-treeselect-box{background:#f7f7f7}:host .cps-treeselect.disabled .cps-treeselect-box-items{color:var(--cps-color-text-light)}:host .cps-treeselect.disabled .cps-treeselect-box-items .text-group,:host .cps-treeselect.disabled .cps-treeselect-box-items .single-item{color:var(--cps-color-text-light)}:host .cps-treeselect.disabled .cps-treeselect-label{color:var(--cps-color-text-mild)}:host .cps-treeselect.error .cps-treeselect-box{border-color:#c33!important;background:#fef3f2!important}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: TreeModule }, { kind: "component", type: i3.Tree, selector: "p-tree", inputs: ["value", "selectionMode", "selection", "style", "styleClass", "contextMenu", "layout", "draggableScope", "droppableScope", "draggableNodes", "droppableNodes", "metaKeySelection", "propagateSelectionUp", "propagateSelectionDown", "loading", "loadingIcon", "emptyMessage", "ariaLabel", "togglerAriaLabel", "ariaLabelledBy", "validateDrop", "filter", "filterBy", "filterMode", "filterPlaceholder", "filteredNodes", "filterLocale", "scrollHeight", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "indentation", "_templateMap", "trackBy", "virtualNodeHeight"], outputs: ["selectionChange", "onNodeSelect", "onNodeUnselect", "onNodeExpand", "onNodeCollapse", "onNodeContextMenuSelect", "onNodeDrop", "onLazyLoad", "onScroll", "onScrollIndexChange", "onFilter"] }, { kind: "directive", type: i4.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: ClickOutsideDirective, selector: "[clickOutside]", inputs: ["skipTargets"], outputs: ["clickOutside"] }, { kind: "component", type: CpsIconComponent, selector: "cps-icon", inputs: ["icon", "size", "color"] }, { kind: "component", type: CpsChipComponent, selector: "cps-chip", inputs: ["label", "icon", "iconPosition", "closable", "disabled"], outputs: ["closed"] }, { kind: "component", type: CpsProgressLinearComponent, selector: "cps-progress-linear", inputs: ["width", "height", "color", "bgColor", "opacity", "radius"] }, { kind: "pipe", type: CombineLabelsPipe, name: "combineLabels" }] });
1400
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsTreeSelectComponent, decorators: [{
1401
+ type: Component,
1402
+ args: [{ standalone: true, imports: [
1403
+ CommonModule,
1404
+ FormsModule,
1405
+ TreeModule,
1406
+ ClickOutsideDirective,
1407
+ CpsIconComponent,
1408
+ CpsChipComponent,
1409
+ CpsProgressLinearComponent,
1410
+ LabelByValuePipe,
1411
+ CombineLabelsPipe
1412
+ ], providers: [LabelByValuePipe, CombineLabelsPipe], selector: 'cps-tree-select', template: "<div\n [ngStyle]=\"{ width: cvtWidth }\"\n class=\"cps-treeselect\"\n tabindex=\"0\"\n [ngClass]=\"{ disabled: disabled, error: error }\"\n #selectContainer\n (keydown)=\"onKeyDown($event, selectContainer)\"\n (blur)=\"onBlur()\">\n <label *ngIf=\"label\" class=\"cps-treeselect-label\">{{ label }} </label>\n <div\n class=\"cps-treeselect-container\"\n [class.focused]=\"isOpened\"\n [ngClass]=\"{\n 'persistent-clear': persistentClear\n }\"\n (clickOutside)=\"onClickOutside(selectContainer)\">\n <div class=\"cps-treeselect-box\" (click)=\"onBoxClick(selectContainer)\">\n <div class=\"cps-treeselect-box-left\">\n <cps-icon\n *ngIf=\"prefixIcon\"\n [icon]=\"prefixIcon\"\n [size]=\"prefixIconSize\"\n class=\"prefix-icon\">\n </cps-icon>\n <div\n class=\"cps-treeselect-box-placeholder\"\n *ngIf=\"\n (!treeSelection && !multiple) ||\n (treeSelection?.length < 1 && multiple)\n \">\n {{ placeholder }}\n </div>\n <div\n class=\"cps-treeselect-box-items\"\n *ngIf=\"\n (treeSelection && !multiple) ||\n (treeSelection?.length > 0 && multiple)\n \">\n <span *ngIf=\"!multiple\" class=\"single-item\">\n {{ treeSelection.label }}</span\n >\n <div *ngIf=\"multiple && !chips\" class=\"text-group\">\n <span class=\"text-group-item\">\n {{\n treeSelection | combineLabels : options : '' : 'label' : true\n }}\n </span>\n </div>\n\n <div *ngIf=\"multiple && chips\" class=\"chips-group\">\n <cps-chip\n *ngFor=\"let val of treeSelection\"\n [disabled]=\"disabled\"\n [closable]=\"closableChips\"\n (closed)=\"remove(val)\"\n [label]=\"val.label\">\n </cps-chip>\n </div>\n </div>\n </div>\n <span class=\"cps-treeselect-box-icons\">\n <span\n *ngIf=\"clearable && !disabled\"\n [style.visibility]=\"\n persistentClear ||\n (!persistentClear &&\n ((multiple && treeSelection?.length) ||\n (!multiple && treeSelection)))\n ? 'visible'\n : 'hidden'\n \"\n class=\"cps-treeselect-box-clear-icon\">\n <cps-icon\n icon=\"delete\"\n size=\"small\"\n (click)=\"clear(selectContainer, $event)\"></cps-icon>\n </span>\n <span class=\"cps-treeselect-box-chevron\">\n <cps-icon\n icon=\"chevron-down\"\n size=\"small\"\n color=\"text-dark\"></cps-icon>\n </span>\n </span>\n </div>\n\n <div class=\"cps-treeselect-options\">\n <p-tree\n #treeList\n [virtualScroll]=\"virtualScroll\"\n [virtualScrollItemSize]=\"virtualScrollItemSize\"\n [virtualScrollOptions]=\"{ numToleratedItems: 3 }\"\n [scrollHeight]=\"virtualListHeight + 'px'\"\n (onNodeSelect)=\"onSelectNode()\"\n (onNodeExpand)=\"recalcVirtualListHeight()\"\n (onNodeCollapse)=\"recalcVirtualListHeight()\"\n [value]=\"options\"\n [(selection)]=\"treeSelection\"\n (selectionChange)=\"treeSelectionChanged($event)\"\n [metaKeySelection]=\"multiple ? false : true\"\n [selectionMode]=\"multiple ? 'multiple' : 'single'\">\n <ng-template let-node pTemplate=\"directory\">\n <span class=\"cps-treeselect-directory-elem\">{{ node.label }}</span>\n </ng-template>\n <ng-template let-node pTemplate=\"default\">\n <span class=\"cps-treeselect-option\">\n <span class=\"cps-treeselect-option-left\">\n <span *ngIf=\"multiple\" class=\"cps-treeselect-option-check\">\n </span>\n <span class=\"cps-treeselect-option-label\">{{ node.label }}</span>\n </span>\n <span class=\"cps-treeselect-option-info\">{{ node.info }}</span>\n </span>\n </ng-template>\n </p-tree>\n </div>\n <cps-progress-linear\n *ngIf=\"loading\"\n height=\"3\"\n radius=\"4\"\n opacity=\"0.3\"\n class=\"treeselect-progress-bar\"\n bgColor=\"transparent\">\n </cps-progress-linear>\n </div>\n <div *ngIf=\"!error && !hideDetails\" class=\"cps-treeselect-hint\">\n {{ hint }}\n </div>\n <div *ngIf=\"error && !hideDetails\" class=\"cps-treeselect-error\">\n {{ error }}\n </div>\n</div>\n", styles: [":host{display:flex}:host .cps-treeselect{position:relative;width:100%;outline:none;font-family:Source Sans Pro,sans-serif;display:grid}:host .cps-treeselect-container{position:relative}:host .cps-treeselect-container .treeselect-progress-bar{position:absolute;bottom:1px;padding:0 1px}:host .cps-treeselect.active .cps-treeselect-options{display:block}:host .cps-treeselect.active .cps-treeselect-box{border:1px solid var(--cps-color-calm)}:host .cps-treeselect.active .cps-treeselect-box .cps-treeselect-box-left .prefix-icon{color:var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-label{display:inline-block;margin-bottom:.2rem;color:var(--cps-color-text-dark);font-size:.875rem}:host .cps-treeselect .persistent-clear .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon,:host .cps-treeselect .cps-treeselect-container.focused .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon,:host .cps-treeselect .cps-treeselect-container:hover .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon{opacity:.5}:host .cps-treeselect .cps-treeselect-box{overflow:hidden;justify-content:space-between;min-height:38px;width:100%;cursor:pointer;background:white;font-size:1rem;outline:none;padding:0 12px;border-radius:4px;align-items:center;display:flex;border:1px solid var(--cps-color-text-lightest);transition-duration:.2s}:host .cps-treeselect .cps-treeselect-box-placeholder{color:var(--cps-color-text-lightest);font-style:italic}:host .cps-treeselect .cps-treeselect-box-items{margin-top:3px;margin-bottom:3px}:host .cps-treeselect .cps-treeselect-box-items .text-group,:host .cps-treeselect .cps-treeselect-box-items .single-item{color:var(--cps-color-text-dark);padding-top:3px;padding-bottom:3px}:host .cps-treeselect .cps-treeselect-box-items .chips-group cps-chip{padding-bottom:3px;padding-top:3px;padding-right:4px}:host .cps-treeselect .cps-treeselect-box-items .text-group-item{line-height:1.5}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-left{display:inline-flex;align-items:center}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-left .prefix-icon{margin-right:.5rem;color:var(--cps-color-text-dark)}:host .cps-treeselect .cps-treeselect-box:hover{border:1px solid var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-box:hover .cps-treeselect-box-left .prefix-icon{color:var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons{display:flex}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon{display:flex;color:var(--cps-color-calm);margin-left:8px}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon{opacity:0;transition-duration:.2s}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-clear-icon cps-icon:hover{opacity:1!important}:host .cps-treeselect .cps-treeselect-box .cps-treeselect-box-icons .cps-treeselect-box-chevron{display:flex;margin-left:8px;transition-duration:.2s}:host .cps-treeselect.active .cps-treeselect-box-chevron{top:22px;transform:rotate(180deg)}:host .cps-treeselect .cps-treeselect-options{z-index:1001;position:absolute;width:100%;background:white;box-shadow:0 5px 20px #0000000d;border-radius:4px;overflow-x:hidden;display:none;max-height:242px;overflow-y:auto;box-shadow:0 2px 4px -1px #0003,0 4px 5px #00000024,0 1px 10px #0000001f}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree{border:1px solid #dee2e6;background:#ffffff;color:var(--cps-color-text-dark);padding:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option{margin-right:8px;display:flex;align-items:center;justify-content:space-between}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-left{display:flex;align-items:center;margin-right:8px}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-check{background-color:transparent;border:0;width:16px;height:16px;cursor:pointer;display:inline-block;vertical-align:middle;box-sizing:border-box;position:relative;flex-shrink:0;transition:border-color 90ms cubic-bezier(0,0,.2,.1),background-color 90ms cubic-bezier(0,0,.2,.1);margin-right:8px;opacity:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-check:after{color:var(--cps-color-calm);top:4px;left:1px;width:8px;height:3px;border-left:2px solid currentColor;transform:rotate(-45deg);opacity:1;box-sizing:content-box;position:absolute;content:\"\";border-bottom:2px solid currentColor;transition:opacity 90ms cubic-bezier(0,0,.2,.1)}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-option-info{margin-left:6px;color:var(--cps-color-text-light)}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-component{font-family:Source Sans Pro,sans-serif;font-size:14px;font-weight:400}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-wrapper{overflow:auto}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-container{margin:0;padding:0;list-style-type:none;overflow:auto}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content{transition:box-shadow .2s;padding:.25rem}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-treenode-content{display:flex;align-items:center}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-treenode-content .p-treenode-label{width:100%}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content .p-tree-toggler{margin-right:.5rem;width:2rem;height:2rem;color:var(--cps-color-text-light);border:0 none;background:transparent;border-radius:50%;transition:background-color .2s,color .2s,box-shadow .2s}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content:not(.p-highlight):hover{background:#f8f4f5}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content:focus{outline:0 none;outline-offset:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content:not(.p-highlight):focus{background-color:#f8f4f5}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content.p-highlight{background:#efe4e7;color:var(--cps-color-calm);font-weight:600}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-tree-container .p-treenode .p-treenode-content.p-highlight .cps-treeselect-option-check{opacity:1}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-toggler{outline:0 none;outline-offset:0;cursor:pointer;-webkit-user-select:none;user-select:none;display:inline-flex;align-items:center;justify-content:center;overflow:hidden;position:relative;flex-shrink:0}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree-toggler :hover{color:var(--cps-color-calm)}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-tree-node-fully-expandable>.p-treenode-content:hover .p-tree-toggler{color:var(--cps-color-calm)!important}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-tree .p-treenode-children{padding:0 0 0 1rem}:host .cps-treeselect .cps-treeselect-options ::ng-deep .p-treenode-children{margin:0;padding:0;list-style-type:none}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-tree-node-fully-expandable{cursor:pointer;-webkit-user-select:none;user-select:none}:host .cps-treeselect .cps-treeselect-options ::ng-deep .cps-treeselect-directory-elem{font-weight:700;font-size:16px}:host .cps-treeselect .cps-treeselect-hint{color:var(--cps-color-text-mild);font-size:.75rem;min-height:1.125rem;cursor:default;margin-top:.2rem}:host .cps-treeselect .cps-treeselect-error{color:#c33;font-weight:700;font-size:.75rem;min-height:1.125rem;cursor:default;margin-top:.2rem}:host .cps-treeselect.disabled{pointer-events:none}:host .cps-treeselect.disabled .cps-treeselect-box{background:#f7f7f7}:host .cps-treeselect.disabled .cps-treeselect-box-items{color:var(--cps-color-text-light)}:host .cps-treeselect.disabled .cps-treeselect-box-items .text-group,:host .cps-treeselect.disabled .cps-treeselect-box-items .single-item{color:var(--cps-color-text-light)}:host .cps-treeselect.disabled .cps-treeselect-label{color:var(--cps-color-text-mild)}:host .cps-treeselect.error .cps-treeselect-box{border-color:#c33!important;background:#fef3f2!important}\n"] }]
1413
+ }], ctorParameters: function () {
1414
+ return [{ type: i1.NgControl, decorators: [{
1415
+ type: Self
1416
+ }, {
1417
+ type: Optional
1418
+ }] }, { type: i0.ChangeDetectorRef }];
1419
+ }, propDecorators: { label: [{
1420
+ type: Input
1421
+ }], placeholder: [{
1422
+ type: Input
1423
+ }], hint: [{
1424
+ type: Input
1425
+ }], multiple: [{
1426
+ type: Input
1427
+ }], disabled: [{
1428
+ type: Input
1429
+ }], width: [{
1430
+ type: Input
1431
+ }], chips: [{
1432
+ type: Input
1433
+ }], closableChips: [{
1434
+ type: Input
1435
+ }], clearable: [{
1436
+ type: Input
1437
+ }], openOnClear: [{
1438
+ type: Input
1439
+ }], optionLabel: [{
1440
+ type: Input
1441
+ }], optionInfo: [{
1442
+ type: Input
1443
+ }], hideDetails: [{
1444
+ type: Input
1445
+ }], persistentClear: [{
1446
+ type: Input
1447
+ }], prefixIcon: [{
1448
+ type: Input
1449
+ }], prefixIconSize: [{
1450
+ type: Input
1451
+ }], loading: [{
1452
+ type: Input
1453
+ }], virtualScroll: [{
1454
+ type: Input
1455
+ }], options: [{
1456
+ type: Input
1457
+ }], _value: [{
1458
+ type: Input,
1459
+ args: ['value']
1460
+ }], valueChanged: [{
1461
+ type: Output
1462
+ }], selectContainer: [{
1463
+ type: ViewChild,
1464
+ args: ['selectContainer']
1465
+ }], treeList: [{
1466
+ type: ViewChild,
1467
+ args: ['treeList']
1468
+ }] } });
1469
+
1010
1470
  class CpsAutocompleteComponent {
1011
1471
  get value() {
1012
1472
  return this._value;
@@ -1256,7 +1716,7 @@ class CpsAutocompleteComponent {
1256
1716
  selected.scrollIntoView({
1257
1717
  behavior: 'instant',
1258
1718
  block: 'nearest',
1259
- inline: 'start'
1719
+ inline: 'center'
1260
1720
  });
1261
1721
  }
1262
1722
  }
@@ -1333,7 +1793,7 @@ class CpsAutocompleteComponent {
1333
1793
  if (elRect.top < parentRect.top || elRect.bottom > parentRect.bottom) {
1334
1794
  el.scrollIntoView({
1335
1795
  block: 'nearest',
1336
- inline: 'start'
1796
+ inline: 'center'
1337
1797
  });
1338
1798
  }
1339
1799
  }
@@ -1944,6 +2404,31 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
1944
2404
  type: Output
1945
2405
  }] } });
1946
2406
 
2407
+ class CpsProgressCircularComponent {
2408
+ constructor() {
2409
+ this.diameter = 40;
2410
+ this.strokeWidth = 4;
2411
+ this.color = 'calm';
2412
+ }
2413
+ ngOnInit() {
2414
+ this.diameter = convertSize(this.diameter);
2415
+ this.strokeWidth = convertSize(this.strokeWidth);
2416
+ this.color = getCSSColor(this.color);
2417
+ }
2418
+ }
2419
+ CpsProgressCircularComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsProgressCircularComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2420
+ CpsProgressCircularComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: CpsProgressCircularComponent, isStandalone: true, selector: "cps-progress-circular", inputs: { diameter: "diameter", strokeWidth: "strokeWidth", color: "color" }, ngImport: i0, template: "<div\n class=\"cps-progress-circular\"\n [style.width]=\"diameter\"\n [style.border]=\"strokeWidth + ' solid ' + color\"></div>\n", styles: [":host{display:inline-block}:host .cps-progress-circular{box-sizing:border-box;aspect-ratio:1;border-radius:50%;border-right-color:transparent!important;border-bottom:unset!important;animation:cps-progress-circular-animation .8s linear infinite}@keyframes cps-progress-circular-animation{to{transform:rotate(360deg)}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }] });
2421
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsProgressCircularComponent, decorators: [{
2422
+ type: Component,
2423
+ args: [{ standalone: true, imports: [CommonModule], selector: 'cps-progress-circular', template: "<div\n class=\"cps-progress-circular\"\n [style.width]=\"diameter\"\n [style.border]=\"strokeWidth + ' solid ' + color\"></div>\n", styles: [":host{display:inline-block}:host .cps-progress-circular{box-sizing:border-box;aspect-ratio:1;border-radius:50%;border-right-color:transparent!important;border-bottom:unset!important;animation:cps-progress-circular-animation .8s linear infinite}@keyframes cps-progress-circular-animation{to{transform:rotate(360deg)}}\n"] }]
2424
+ }], propDecorators: { diameter: [{
2425
+ type: Input
2426
+ }], strokeWidth: [{
2427
+ type: Input
2428
+ }], color: [{
2429
+ type: Input
2430
+ }] } });
2431
+
1947
2432
  class CpsDatepickerComponent {
1948
2433
  set value(value) {
1949
2434
  this._value = value;
@@ -2305,10 +2790,10 @@ class CpsTextareaComponent {
2305
2790
  }
2306
2791
  }
2307
2792
  CpsTextareaComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsTextareaComponent, deps: [{ token: i1.NgControl, optional: true, self: true }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
2308
- CpsTextareaComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: CpsTextareaComponent, isStandalone: true, selector: "cps-textarea", inputs: { label: "label", placeholder: "placeholder", rows: "rows", cols: "cols", autofocus: "autofocus", hint: "hint", disabled: "disabled", width: "width", clearable: "clearable", hideDetails: "hideDetails", persistentClear: "persistentClear", error: "error", resizable: "resizable", value: "value" }, outputs: { valueChanged: "valueChanged", focused: "focused", prefixIconClicked: "prefixIconClicked", blurred: "blurred" }, ngImport: i0, template: "<div class=\"cps-textarea-container\" [ngStyle]=\"{ width: cvtWidth }\">\n <label\n class=\"cps-textarea-label-text\"\n [ngClass]=\"{ 'cps-textarea-label-text-disabled': disabled }\"\n >{{ label }}</label\n >\n\n <div\n class=\"cps-textarea-wrap\"\n [ngClass]=\"{\n 'cps-textarea-wrap-error': error,\n clearable: clearable,\n 'persistent-clear': persistentClear\n }\">\n <textarea\n [cols]=\"cols\"\n [rows]=\"rows\"\n [autofocus]=\"autofocus\"\n [disabled]=\"disabled\"\n [placeholder]=\"placeholder\"\n [value]=\"value\"\n [ngStyle]=\"{\n width: cvtWidth,\n resize: resizable\n }\"\n (blur)=\"onBlur()\"\n (focus)=\"onFocus()\"\n (input)=\"updateValueEvent($event)\"></textarea>\n\n <span\n *ngIf=\"clearable && !disabled\"\n [style.visibility]=\"\n persistentClear || (!persistentClear && value) ? 'visible' : 'hidden'\n \"\n class=\"clear-btn\">\n <cps-icon icon=\"delete\" size=\"small\" (click)=\"clear()\"></cps-icon>\n </span>\n <div *ngIf=\"!error && !hideDetails\" class=\"cps-textarea-hint-text\">\n {{ hint }}\n </div>\n <div *ngIf=\"error && !hideDetails\" class=\"cps-textarea-error-text\">\n {{ error }}\n </div>\n </div>\n</div>\n", styles: [":host{display:flex}:host .cps-textarea-container{width:100%;gap:.2rem!important;display:flex!important;flex-direction:column!important;font-family:Source Sans Pro,sans-serif}:host .cps-textarea-container .cps-textarea-wrap{position:relative;overflow:hidden}:host .cps-textarea-container .cps-textarea-wrap:hover textarea:enabled{border:1px solid var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap-error textarea{border-color:#c33!important}:host .cps-textarea-container .cps-textarea-wrap-error textarea:not(:focus){background:#fef3f2!important}:host .cps-textarea-container .cps-textarea-wrap textarea{font-family:Source Sans Pro,sans-serif;font-size:1rem;color:var(--cps-color-text-dark);background:#ffffff;padding:.375rem .75rem;line-height:1.5;min-height:38px;border:1px solid var(--cps-color-text-lightest);transition-property:border-color;transition-duration:.2s;-webkit-appearance:none;appearance:none;border-radius:4px;width:100%}:host .cps-textarea-container .cps-textarea-wrap textarea:focus{border:1px solid var(--cps-color-calm);outline:0}:host .cps-textarea-container .cps-textarea-wrap textarea:disabled{color:var(--cps-color-text-light);background-color:#f7f7f7;opacity:1;pointer-events:none}:host .cps-textarea-container .cps-textarea-wrap textarea:focus+.clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap:hover .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap .clear-btn{position:absolute;top:.75rem;right:.75rem;cursor:pointer;color:var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon{opacity:0;transition-duration:.2s}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon:hover{opacity:1!important}:host .cps-textarea-container .persistent-clear .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .clearable>textarea{padding-right:2.2rem}:host .cps-textarea-container .cps-textarea-hint-text{color:var(--cps-color-text-mild);font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-error-text{color:#c33;font-weight:700;font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-label-text{color:var(--cps-color-text-dark);font-size:.875rem}:host .cps-textarea-container .cps-textarea-label-text-disabled{color:var(--cps-color-text-mild)}:host .cps-textarea-container ::placeholder{font-family:Source Sans Pro,sans-serif;color:var(--cps-color-text-lightest);font-style:italic;opacity:1}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: CpsIconComponent, selector: "cps-icon", inputs: ["icon", "size", "color"] }] });
2793
+ CpsTextareaComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.9", type: CpsTextareaComponent, isStandalone: true, selector: "cps-textarea", inputs: { label: "label", placeholder: "placeholder", rows: "rows", cols: "cols", autofocus: "autofocus", hint: "hint", disabled: "disabled", width: "width", clearable: "clearable", hideDetails: "hideDetails", persistentClear: "persistentClear", error: "error", resizable: "resizable", value: "value" }, outputs: { valueChanged: "valueChanged", focused: "focused", prefixIconClicked: "prefixIconClicked", blurred: "blurred" }, ngImport: i0, template: "<div class=\"cps-textarea-container\" [ngStyle]=\"{ width: cvtWidth }\">\n <label\n class=\"cps-textarea-label-text\"\n [ngClass]=\"{ 'cps-textarea-label-text-disabled': disabled }\"\n >{{ label }}</label\n >\n\n <div\n class=\"cps-textarea-wrap\"\n [ngClass]=\"{\n 'cps-textarea-wrap-error': error,\n clearable: clearable,\n 'persistent-clear': persistentClear\n }\">\n <textarea\n [cols]=\"cols\"\n [rows]=\"rows\"\n [autofocus]=\"autofocus\"\n [disabled]=\"disabled\"\n [placeholder]=\"placeholder\"\n [value]=\"value\"\n [ngStyle]=\"{\n width: cvtWidth,\n resize: resizable\n }\"\n (blur)=\"onBlur()\"\n (focus)=\"onFocus()\"\n (input)=\"updateValueEvent($event)\"></textarea>\n\n <span\n *ngIf=\"clearable && !disabled\"\n [style.visibility]=\"\n persistentClear || (!persistentClear && value) ? 'visible' : 'hidden'\n \"\n class=\"clear-btn\">\n <cps-icon icon=\"delete\" size=\"small\" (click)=\"clear()\"></cps-icon>\n </span>\n </div>\n <div *ngIf=\"!error && !hideDetails\" class=\"cps-textarea-hint-text\">\n {{ hint }}\n </div>\n <div *ngIf=\"error && !hideDetails\" class=\"cps-textarea-error-text\">\n {{ error }}\n </div>\n</div>\n", styles: [":host{display:flex}:host .cps-textarea-container{width:100%;gap:.2rem!important;display:flex!important;flex-direction:column!important;font-family:Source Sans Pro,sans-serif}:host .cps-textarea-container .cps-textarea-wrap{position:relative;overflow:hidden}:host .cps-textarea-container .cps-textarea-wrap:hover textarea:enabled{border:1px solid var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap-error textarea{border-color:#c33!important}:host .cps-textarea-container .cps-textarea-wrap-error textarea:not(:focus){background:#fef3f2!important}:host .cps-textarea-container .cps-textarea-wrap textarea{display:block;font-family:Source Sans Pro,sans-serif;font-size:1rem;color:var(--cps-color-text-dark);background:#ffffff;padding:.375rem .75rem;line-height:1.5;min-height:38px;border:1px solid var(--cps-color-text-lightest);transition-property:border-color;transition-duration:.2s;-webkit-appearance:none;appearance:none;border-radius:4px;width:100%}:host .cps-textarea-container .cps-textarea-wrap textarea:focus{border:1px solid var(--cps-color-calm);outline:0}:host .cps-textarea-container .cps-textarea-wrap textarea:disabled{color:var(--cps-color-text-light);background-color:#f7f7f7;opacity:1;pointer-events:none}:host .cps-textarea-container .cps-textarea-wrap textarea:focus+.clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap:hover .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap .clear-btn{position:absolute;top:.75rem;right:.75rem;cursor:pointer;color:var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon{opacity:0;transition-duration:.2s}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon:hover{opacity:1!important}:host .cps-textarea-container .persistent-clear .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .clearable>textarea{padding-right:2.2rem}:host .cps-textarea-container .cps-textarea-hint-text{color:var(--cps-color-text-mild);font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-error-text{color:#c33;font-weight:700;font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-label-text{color:var(--cps-color-text-dark);font-size:.875rem}:host .cps-textarea-container .cps-textarea-label-text-disabled{color:var(--cps-color-text-mild)}:host .cps-textarea-container ::placeholder{font-family:Source Sans Pro,sans-serif;color:var(--cps-color-text-lightest);font-style:italic;opacity:1}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: CpsIconComponent, selector: "cps-icon", inputs: ["icon", "size", "color"] }] });
2309
2794
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: CpsTextareaComponent, decorators: [{
2310
2795
  type: Component,
2311
- args: [{ standalone: true, selector: 'cps-textarea', imports: [CommonModule, CpsIconComponent], template: "<div class=\"cps-textarea-container\" [ngStyle]=\"{ width: cvtWidth }\">\n <label\n class=\"cps-textarea-label-text\"\n [ngClass]=\"{ 'cps-textarea-label-text-disabled': disabled }\"\n >{{ label }}</label\n >\n\n <div\n class=\"cps-textarea-wrap\"\n [ngClass]=\"{\n 'cps-textarea-wrap-error': error,\n clearable: clearable,\n 'persistent-clear': persistentClear\n }\">\n <textarea\n [cols]=\"cols\"\n [rows]=\"rows\"\n [autofocus]=\"autofocus\"\n [disabled]=\"disabled\"\n [placeholder]=\"placeholder\"\n [value]=\"value\"\n [ngStyle]=\"{\n width: cvtWidth,\n resize: resizable\n }\"\n (blur)=\"onBlur()\"\n (focus)=\"onFocus()\"\n (input)=\"updateValueEvent($event)\"></textarea>\n\n <span\n *ngIf=\"clearable && !disabled\"\n [style.visibility]=\"\n persistentClear || (!persistentClear && value) ? 'visible' : 'hidden'\n \"\n class=\"clear-btn\">\n <cps-icon icon=\"delete\" size=\"small\" (click)=\"clear()\"></cps-icon>\n </span>\n <div *ngIf=\"!error && !hideDetails\" class=\"cps-textarea-hint-text\">\n {{ hint }}\n </div>\n <div *ngIf=\"error && !hideDetails\" class=\"cps-textarea-error-text\">\n {{ error }}\n </div>\n </div>\n</div>\n", styles: [":host{display:flex}:host .cps-textarea-container{width:100%;gap:.2rem!important;display:flex!important;flex-direction:column!important;font-family:Source Sans Pro,sans-serif}:host .cps-textarea-container .cps-textarea-wrap{position:relative;overflow:hidden}:host .cps-textarea-container .cps-textarea-wrap:hover textarea:enabled{border:1px solid var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap-error textarea{border-color:#c33!important}:host .cps-textarea-container .cps-textarea-wrap-error textarea:not(:focus){background:#fef3f2!important}:host .cps-textarea-container .cps-textarea-wrap textarea{font-family:Source Sans Pro,sans-serif;font-size:1rem;color:var(--cps-color-text-dark);background:#ffffff;padding:.375rem .75rem;line-height:1.5;min-height:38px;border:1px solid var(--cps-color-text-lightest);transition-property:border-color;transition-duration:.2s;-webkit-appearance:none;appearance:none;border-radius:4px;width:100%}:host .cps-textarea-container .cps-textarea-wrap textarea:focus{border:1px solid var(--cps-color-calm);outline:0}:host .cps-textarea-container .cps-textarea-wrap textarea:disabled{color:var(--cps-color-text-light);background-color:#f7f7f7;opacity:1;pointer-events:none}:host .cps-textarea-container .cps-textarea-wrap textarea:focus+.clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap:hover .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap .clear-btn{position:absolute;top:.75rem;right:.75rem;cursor:pointer;color:var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon{opacity:0;transition-duration:.2s}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon:hover{opacity:1!important}:host .cps-textarea-container .persistent-clear .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .clearable>textarea{padding-right:2.2rem}:host .cps-textarea-container .cps-textarea-hint-text{color:var(--cps-color-text-mild);font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-error-text{color:#c33;font-weight:700;font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-label-text{color:var(--cps-color-text-dark);font-size:.875rem}:host .cps-textarea-container .cps-textarea-label-text-disabled{color:var(--cps-color-text-mild)}:host .cps-textarea-container ::placeholder{font-family:Source Sans Pro,sans-serif;color:var(--cps-color-text-lightest);font-style:italic;opacity:1}\n"] }]
2796
+ args: [{ standalone: true, selector: 'cps-textarea', imports: [CommonModule, CpsIconComponent], template: "<div class=\"cps-textarea-container\" [ngStyle]=\"{ width: cvtWidth }\">\n <label\n class=\"cps-textarea-label-text\"\n [ngClass]=\"{ 'cps-textarea-label-text-disabled': disabled }\"\n >{{ label }}</label\n >\n\n <div\n class=\"cps-textarea-wrap\"\n [ngClass]=\"{\n 'cps-textarea-wrap-error': error,\n clearable: clearable,\n 'persistent-clear': persistentClear\n }\">\n <textarea\n [cols]=\"cols\"\n [rows]=\"rows\"\n [autofocus]=\"autofocus\"\n [disabled]=\"disabled\"\n [placeholder]=\"placeholder\"\n [value]=\"value\"\n [ngStyle]=\"{\n width: cvtWidth,\n resize: resizable\n }\"\n (blur)=\"onBlur()\"\n (focus)=\"onFocus()\"\n (input)=\"updateValueEvent($event)\"></textarea>\n\n <span\n *ngIf=\"clearable && !disabled\"\n [style.visibility]=\"\n persistentClear || (!persistentClear && value) ? 'visible' : 'hidden'\n \"\n class=\"clear-btn\">\n <cps-icon icon=\"delete\" size=\"small\" (click)=\"clear()\"></cps-icon>\n </span>\n </div>\n <div *ngIf=\"!error && !hideDetails\" class=\"cps-textarea-hint-text\">\n {{ hint }}\n </div>\n <div *ngIf=\"error && !hideDetails\" class=\"cps-textarea-error-text\">\n {{ error }}\n </div>\n</div>\n", styles: [":host{display:flex}:host .cps-textarea-container{width:100%;gap:.2rem!important;display:flex!important;flex-direction:column!important;font-family:Source Sans Pro,sans-serif}:host .cps-textarea-container .cps-textarea-wrap{position:relative;overflow:hidden}:host .cps-textarea-container .cps-textarea-wrap:hover textarea:enabled{border:1px solid var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap-error textarea{border-color:#c33!important}:host .cps-textarea-container .cps-textarea-wrap-error textarea:not(:focus){background:#fef3f2!important}:host .cps-textarea-container .cps-textarea-wrap textarea{display:block;font-family:Source Sans Pro,sans-serif;font-size:1rem;color:var(--cps-color-text-dark);background:#ffffff;padding:.375rem .75rem;line-height:1.5;min-height:38px;border:1px solid var(--cps-color-text-lightest);transition-property:border-color;transition-duration:.2s;-webkit-appearance:none;appearance:none;border-radius:4px;width:100%}:host .cps-textarea-container .cps-textarea-wrap textarea:focus{border:1px solid var(--cps-color-calm);outline:0}:host .cps-textarea-container .cps-textarea-wrap textarea:disabled{color:var(--cps-color-text-light);background-color:#f7f7f7;opacity:1;pointer-events:none}:host .cps-textarea-container .cps-textarea-wrap textarea:focus+.clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap:hover .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .cps-textarea-wrap .clear-btn{position:absolute;top:.75rem;right:.75rem;cursor:pointer;color:var(--cps-color-calm)}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon{opacity:0;transition-duration:.2s}:host .cps-textarea-container .cps-textarea-wrap .clear-btn cps-icon:hover{opacity:1!important}:host .cps-textarea-container .persistent-clear .clear-btn cps-icon{opacity:.5}:host .cps-textarea-container .clearable>textarea{padding-right:2.2rem}:host .cps-textarea-container .cps-textarea-hint-text{color:var(--cps-color-text-mild);font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-error-text{color:#c33;font-weight:700;font-size:.75rem;min-height:1.125rem;cursor:default}:host .cps-textarea-container .cps-textarea-label-text{color:var(--cps-color-text-dark);font-size:.875rem}:host .cps-textarea-container .cps-textarea-label-text-disabled{color:var(--cps-color-text-mild)}:host .cps-textarea-container ::placeholder{font-family:Source Sans Pro,sans-serif;color:var(--cps-color-text-lightest);font-style:italic;opacity:1}\n"] }]
2312
2797
  }], ctorParameters: function () {
2313
2798
  return [{ type: i1.NgControl, decorators: [{
2314
2799
  type: Self
@@ -2470,5 +2955,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImpor
2470
2955
  * Generated bundle index. Do not edit.
2471
2956
  */
2472
2957
 
2473
- export { CpsAutocompleteComponent, CpsButtonComponent, CpsButtonToggleComponent, CpsCheckboxComponent, CpsChipComponent, CpsDatepickerComponent, CpsExpansionPanelComponent, CpsIconComponent, CpsInputComponent, CpsLoaderComponent, CpsProgressLinearComponent, CpsRadioComponent, CpsSelectComponent, CpsTagComponent, CpsTextareaComponent, getCSSColor, getCpsColors, getTextColor, iconNames };
2958
+ export { CpsAutocompleteComponent, CpsButtonComponent, CpsButtonToggleComponent, CpsCheckboxComponent, CpsChipComponent, CpsDatepickerComponent, CpsExpansionPanelComponent, CpsIconComponent, CpsInputComponent, CpsLoaderComponent, CpsProgressCircularComponent, CpsProgressLinearComponent, CpsRadioComponent, CpsSelectComponent, CpsTagComponent, CpsTextareaComponent, CpsTreeSelectComponent, getCSSColor, getCpsColors, getTextColor, iconNames };
2474
2959
  //# sourceMappingURL=cps-ui-kit.mjs.map