mis-crystal-design-system 18.0.25 → 18.1.0-signal-test
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/action-list/action-list.component.d.ts +17 -15
- package/async-search-dropdown/async-dropdown.component.d.ts +43 -61
- package/button/button.component.d.ts +35 -13
- package/button/button.directive.d.ts +10 -8
- package/button/button.directive.scss +13 -15
- package/checkbox/checkbox.component.d.ts +15 -12
- package/chip/chip.component.d.ts +9 -11
- package/datepicker_v2/models/dp-config.model.d.ts +1 -0
- package/datepicker_v2/tz-datepicker.directive.d.ts +15 -18
- package/datepicker_v2/tz-dp-container/tz-dp-container.component.d.ts +42 -21
- package/daterangepicker_v2/tz-daterangepicker.directive.d.ts +12 -14
- package/daterangepicker_v2/tz-drp-container/tz-drp-container.component.d.ts +46 -23
- package/drawer/drawer-body/drawer-body.component.d.ts +2 -2
- package/drawer/drawer.scss +1 -1
- package/dropdown/calculate-container-height.directive.d.ts +7 -8
- package/dropdown/dropdown.component.d.ts +41 -49
- package/dynamic-form/dynamic-form.component.d.ts +20 -16
- package/esm2022/action-list/action-list.component.mjs +113 -90
- package/esm2022/async-search-dropdown/async-dropdown.component.mjs +257 -327
- package/esm2022/button/button.component.mjs +56 -49
- package/esm2022/button/button.directive.mjs +36 -40
- package/esm2022/checkbox/checkbox.component.mjs +75 -70
- package/esm2022/chip/chip.component.mjs +20 -33
- package/esm2022/datepicker_v2/models/dp-config.model.mjs +1 -1
- package/esm2022/datepicker_v2/tz-datepicker.directive.mjs +42 -71
- package/esm2022/datepicker_v2/tz-dp-container/tz-dp-container.component.mjs +203 -173
- package/esm2022/datepicker_v2/utils/index.mjs +2 -1
- package/esm2022/daterangepicker_v2/tz-daterangepicker.directive.mjs +26 -51
- package/esm2022/daterangepicker_v2/tz-drp-container/tz-drp-container.component.mjs +283 -236
- package/esm2022/drawer/drawer-body/drawer-body.component.mjs +8 -7
- package/esm2022/dropdown/calculate-container-height.directive.mjs +25 -22
- package/esm2022/dropdown/dropdown.component.mjs +163 -187
- package/esm2022/dynamic-form/dynamic-form.component.mjs +119 -73
- package/esm2022/fab/fab.component.mjs +30 -34
- package/esm2022/filter/filter-panel/filter-panel.component.mjs +61 -59
- package/esm2022/input/directives/input/input.directive.mjs +22 -26
- package/esm2022/input/mis-input.component.mjs +42 -46
- package/esm2022/input-stepper/input-stepper/input-stepper.component.mjs +42 -52
- package/esm2022/loader/loader.component.mjs +8 -11
- package/esm2022/mobile-filter/mobile-filter.component.mjs +62 -62
- package/esm2022/modal/module-wrapper/module-wrapper.component.mjs +11 -9
- package/esm2022/multi-select-dropdown/multi-select-dropdown.component.mjs +235 -281
- package/esm2022/nested-multi-select-dropdown/nested-multi-select-dropdown.component.mjs +250 -287
- package/esm2022/phone-input/phone-input.component.mjs +21 -43
- package/esm2022/public-api.mjs +1 -1
- package/esm2022/radio-button/radio-button.component.mjs +15 -27
- package/esm2022/ske-loader/ske-loader.component.mjs +15 -29
- package/esm2022/slider/slider.component.mjs +23 -33
- package/esm2022/slider/slider.module.mjs +4 -11
- package/esm2022/snackbar/snackbar/snackbar.component.mjs +21 -15
- package/esm2022/snackbar/snackbar.service.mjs +3 -2
- package/esm2022/specificdatepicker/tz-sdp-container/tz-sdp-container.component.mjs +231 -344
- package/esm2022/specificdatepicker/tz-specificdatepicker.directive.mjs +77 -105
- package/esm2022/star-rating/star-rating.component.mjs +58 -72
- package/esm2022/switch/switch.component.mjs +34 -36
- package/esm2022/table/actions-cell/actions-cell.component.mjs +56 -55
- package/esm2022/table/custom-table-cell.directive.mjs +22 -18
- package/esm2022/table/filter/filter.component.mjs +60 -42
- package/esm2022/table/sort-icons.directive.mjs +16 -8
- package/esm2022/table/sub-table/sub-table.component.mjs +42 -45
- package/esm2022/table/table.component.mjs +182 -166
- package/esm2022/timepicker/timepicker.component.mjs +245 -160
- package/esm2022/timepicker/timepicker.directive.mjs +3 -2
- package/esm2022/timerangepicker/timerangepicker.component.mjs +200 -159
- package/esm2022/toast/toast.component.mjs +7 -8
- package/esm2022/toast/toast.data.service.mjs +15 -9
- package/esm2022/tooltip/tooltip-container/tooltip.component.mjs +12 -12
- package/esm2022/tooltip/tooltip.directive.mjs +4 -4
- package/esm2022/virtual-scroll/virtual-scroll.component.mjs +57 -59
- package/fab/fab.component.d.ts +12 -8
- package/fesm2022/mis-crystal-design-system-action-list.mjs +112 -89
- package/fesm2022/mis-crystal-design-system-action-list.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-async-search-dropdown.mjs +254 -325
- package/fesm2022/mis-crystal-design-system-async-search-dropdown.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-button.mjs +89 -86
- package/fesm2022/mis-crystal-design-system-button.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-checkbox.mjs +74 -69
- package/fesm2022/mis-crystal-design-system-checkbox.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-chip.mjs +19 -32
- package/fesm2022/mis-crystal-design-system-chip.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-datepicker_v2.mjs +243 -241
- package/fesm2022/mis-crystal-design-system-datepicker_v2.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-daterangepicker_v2.mjs +306 -284
- package/fesm2022/mis-crystal-design-system-daterangepicker_v2.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-drawer.mjs +7 -6
- package/fesm2022/mis-crystal-design-system-drawer.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-dropdown.mjs +184 -205
- package/fesm2022/mis-crystal-design-system-dropdown.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-dynamic-form.mjs +119 -73
- package/fesm2022/mis-crystal-design-system-dynamic-form.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-fab.mjs +29 -33
- package/fesm2022/mis-crystal-design-system-fab.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-filter.mjs +60 -58
- package/fesm2022/mis-crystal-design-system-filter.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-input-stepper.mjs +41 -51
- package/fesm2022/mis-crystal-design-system-input-stepper.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-input.mjs +62 -71
- package/fesm2022/mis-crystal-design-system-input.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-loader.mjs +7 -10
- package/fesm2022/mis-crystal-design-system-loader.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-mobile-filter.mjs +61 -61
- package/fesm2022/mis-crystal-design-system-mobile-filter.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-modal.mjs +10 -8
- package/fesm2022/mis-crystal-design-system-modal.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-multi-select-dropdown.mjs +233 -279
- package/fesm2022/mis-crystal-design-system-multi-select-dropdown.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-nested-multi-select-dropdown.mjs +249 -286
- package/fesm2022/mis-crystal-design-system-nested-multi-select-dropdown.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-phone-input.mjs +20 -42
- package/fesm2022/mis-crystal-design-system-phone-input.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-radio-button.mjs +14 -26
- package/fesm2022/mis-crystal-design-system-radio-button.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-ske-loader.mjs +14 -28
- package/fesm2022/mis-crystal-design-system-ske-loader.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-slider.mjs +25 -42
- package/fesm2022/mis-crystal-design-system-slider.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-snackbar.mjs +22 -15
- package/fesm2022/mis-crystal-design-system-snackbar.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-specificdatepicker.mjs +305 -446
- package/fesm2022/mis-crystal-design-system-specificdatepicker.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-star-rating.mjs +57 -71
- package/fesm2022/mis-crystal-design-system-star-rating.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-switch.mjs +33 -35
- package/fesm2022/mis-crystal-design-system-switch.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-table.mjs +368 -324
- package/fesm2022/mis-crystal-design-system-table.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-timepicker.mjs +246 -160
- package/fesm2022/mis-crystal-design-system-timepicker.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-timerangepicker.mjs +199 -158
- package/fesm2022/mis-crystal-design-system-timerangepicker.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-toast.mjs +19 -14
- package/fesm2022/mis-crystal-design-system-toast.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-tooltip.mjs +14 -14
- package/fesm2022/mis-crystal-design-system-tooltip.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system-virtual-scroll.mjs +57 -59
- package/fesm2022/mis-crystal-design-system-virtual-scroll.mjs.map +1 -1
- package/fesm2022/mis-crystal-design-system.mjs.map +1 -1
- package/filter/filter-panel/filter-panel.component.d.ts +14 -14
- package/input/directives/input/input.directive.d.ts +6 -10
- package/input/mis-input.component.d.ts +12 -13
- package/input/mis-input.component.scss +18 -18
- package/input-stepper/input-stepper/input-stepper.component.d.ts +8 -7
- package/loader/loader.component.d.ts +3 -6
- package/mobile-filter/mobile-filter.component.d.ts +15 -15
- package/modal/modal.scss +1 -1
- package/modal/module-wrapper/module-wrapper.component.d.ts +2 -3
- package/multi-select-dropdown/multi-select-dropdown.component.d.ts +89 -51
- package/nested-multi-select-dropdown/nested-multi-select-dropdown.component.d.ts +99 -56
- package/package.json +17 -23
- package/phone-input/phone-input.component.d.ts +16 -18
- package/radio-button/radio-button.component.d.ts +9 -11
- package/ske-loader/ske-loader.component.d.ts +8 -11
- package/slider/slider.component.d.ts +8 -11
- package/slider/slider.module.d.ts +1 -2
- package/snackbar/snackbar/snackbar.component.d.ts +3 -3
- package/specificdatepicker/tz-sdp-container/tz-sdp-container.component.d.ts +35 -35
- package/specificdatepicker/tz-specificdatepicker.directive.d.ts +24 -28
- package/star-rating/star-rating.component.d.ts +18 -18
- package/styles/mis-color-constants.scss +0 -204
- package/styles/mis-icons.scss +56 -56
- package/styles/mis-old-icon-styles.scss +21 -21
- package/switch/switch.component.d.ts +8 -10
- package/table/actions-cell/actions-cell.component.d.ts +14 -14
- package/table/custom-table-cell.directive.d.ts +3 -3
- package/table/filter/filter.component.d.ts +9 -9
- package/table/sub-table/sub-table.component.d.ts +5 -5
- package/table/table.component.d.ts +38 -35
- package/timepicker/timepicker.component.d.ts +29 -28
- package/timerangepicker/timerangepicker.component.d.ts +36 -33
- package/toast/toast.data.service.d.ts +1 -1
- package/tooltip/tooltip-container/tooltip.component.d.ts +4 -4
- package/virtual-scroll/virtual-scroll.component.d.ts +8 -9
- package/dynamic-theme/branding.types.d.ts +0 -84
- package/dynamic-theme/dynamic-theme.module.d.ts +0 -9
- package/dynamic-theme/dynamic-theme.service.d.ts +0 -89
- package/dynamic-theme/index.d.ts +0 -1
- package/dynamic-theme/public_api.d.ts +0 -3
- package/esm2022/dynamic-theme/branding.types.mjs +0 -93
- package/esm2022/dynamic-theme/dynamic-theme.module.mjs +0 -25
- package/esm2022/dynamic-theme/dynamic-theme.service.mjs +0 -193
- package/esm2022/dynamic-theme/index.mjs +0 -2
- package/esm2022/dynamic-theme/mis-crystal-design-system-dynamic-theme.mjs +0 -5
- package/esm2022/dynamic-theme/public_api.mjs +0 -4
- package/fesm2022/mis-crystal-design-system-dynamic-theme.mjs +0 -313
- package/fesm2022/mis-crystal-design-system-dynamic-theme.mjs.map +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { signal, input, output, effect, Component, ViewChild, ContentChild, HostListener, inject, ElementRef, computed, Directive, NgModule } from '@angular/core';
|
|
1
3
|
import * as i1 from '@angular/cdk/overlay';
|
|
2
4
|
import { ConnectionPositionPair, OverlayConfig, OverlayModule } from '@angular/cdk/overlay';
|
|
3
5
|
import { TemplatePortal } from '@angular/cdk/portal';
|
|
4
|
-
import * as i0 from '@angular/core';
|
|
5
|
-
import { EventEmitter, Component, Input, Output, ViewChild, ContentChild, HostListener, Directive, NgModule } from '@angular/core';
|
|
6
6
|
import * as i4 from '@angular/cdk/scrolling';
|
|
7
7
|
import { CdkVirtualScrollViewport, ScrollingModule } from '@angular/cdk/scrolling';
|
|
8
8
|
import * as i2 from '@angular/common';
|
|
@@ -28,17 +28,19 @@ const _c10 = (a0, a1, a2) => ({ width: a0, "display": a1, "flex-direction": a2 }
|
|
|
28
28
|
function DropdownComponent_img_3_Template(rf, ctx) { if (rf & 1) {
|
|
29
29
|
i0.ɵɵelement(0, "img", 12);
|
|
30
30
|
} if (rf & 2) {
|
|
31
|
+
let tmp_6_0;
|
|
31
32
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
32
|
-
i0.ɵɵproperty("width", 16)("height", 16)("src", ctx_r1.selectedItem == null ? null :
|
|
33
|
+
i0.ɵɵproperty("width", 16)("height", 16)("src", (tmp_6_0 = ctx_r1.selectedItem()) == null ? null : tmp_6_0.customIcon, i0.ɵɵsanitizeUrl);
|
|
33
34
|
} }
|
|
34
35
|
function DropdownComponent_p_5_Template(rf, ctx) { if (rf & 1) {
|
|
35
36
|
i0.ɵɵelementStart(0, "p", 13);
|
|
36
37
|
i0.ɵɵtext(1);
|
|
37
38
|
i0.ɵɵelementEnd();
|
|
38
39
|
} if (rf & 2) {
|
|
40
|
+
let tmp_4_0;
|
|
39
41
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
40
42
|
i0.ɵɵadvance();
|
|
41
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r1.multiLine ? ctx_r1.selectedItem == null ? null :
|
|
43
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.multiLine() ? (tmp_4_0 = ctx_r1.selectedItem()) == null ? null : tmp_4_0.label == null ? null : tmp_4_0.label.primaryText : ((tmp_4_0 = ctx_r1.selectedItem()) == null ? null : tmp_4_0.label) || ctx_r1.label(), " ");
|
|
42
44
|
} }
|
|
43
45
|
function DropdownComponent_ng_template_6_p_0_Template(rf, ctx) { if (rf & 1) {
|
|
44
46
|
i0.ɵɵelementStart(0, "p", 13);
|
|
@@ -47,21 +49,24 @@ function DropdownComponent_ng_template_6_p_0_Template(rf, ctx) { if (rf & 1) {
|
|
|
47
49
|
} if (rf & 2) {
|
|
48
50
|
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
49
51
|
i0.ɵɵadvance();
|
|
50
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r1.label, " ");
|
|
52
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.label(), " ");
|
|
51
53
|
} }
|
|
52
54
|
function DropdownComponent_ng_template_6_img_1_Template(rf, ctx) { if (rf & 1) {
|
|
53
55
|
i0.ɵɵelement(0, "img", 16);
|
|
54
56
|
} if (rf & 2) {
|
|
57
|
+
let tmp_5_0;
|
|
55
58
|
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
56
|
-
i0.ɵɵproperty("src", ctx_r1.selectedItem == null ? null :
|
|
59
|
+
i0.ɵɵproperty("src", (tmp_5_0 = ctx_r1.selectedItem()) == null ? null : tmp_5_0.icon, i0.ɵɵsanitizeUrl);
|
|
57
60
|
} }
|
|
58
61
|
function DropdownComponent_ng_template_6_Template(rf, ctx) { if (rf & 1) {
|
|
59
62
|
i0.ɵɵtemplate(0, DropdownComponent_ng_template_6_p_0_Template, 2, 1, "p", 14)(1, DropdownComponent_ng_template_6_img_1_Template, 1, 1, "img", 15);
|
|
60
63
|
} if (rf & 2) {
|
|
64
|
+
let tmp_4_0;
|
|
65
|
+
let tmp_5_0;
|
|
61
66
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
62
|
-
i0.ɵɵproperty("ngIf", !(ctx_r1.selectedItem == null ? null :
|
|
67
|
+
i0.ɵɵproperty("ngIf", !((tmp_4_0 = ctx_r1.selectedItem()) == null ? null : tmp_4_0.icon));
|
|
63
68
|
i0.ɵɵadvance();
|
|
64
|
-
i0.ɵɵproperty("ngIf", !!(ctx_r1.selectedItem == null ? null :
|
|
69
|
+
i0.ɵɵproperty("ngIf", !!((tmp_5_0 = ctx_r1.selectedItem()) == null ? null : tmp_5_0.icon));
|
|
65
70
|
} }
|
|
66
71
|
function DropdownComponent_ng_template_10_div_1__svg_svg_1_Template(rf, ctx) { if (rf & 1) {
|
|
67
72
|
i0.ɵɵnamespaceSVG();
|
|
@@ -89,12 +94,12 @@ function DropdownComponent_ng_template_10_div_1_Template(rf, ctx) { if (rf & 1)
|
|
|
89
94
|
} if (rf & 2) {
|
|
90
95
|
const ctx_r1 = i0.ɵɵnextContext(2);
|
|
91
96
|
i0.ɵɵadvance();
|
|
92
|
-
i0.ɵɵproperty("ngIf", !ctx_r1.isSearchInputFocused);
|
|
97
|
+
i0.ɵɵproperty("ngIf", !ctx_r1.isSearchInputFocused());
|
|
93
98
|
i0.ɵɵadvance();
|
|
94
|
-
i0.ɵɵproperty("ngModel", ctx_r1.searchInput)("ngStyle", i0.ɵɵpureFunction3(7, _c7, ctx_r1.isSearchInputFocused ? "12px" : "45px", ctx_r1.isSearchInputFocused ? "1px solid #0937B2" : "1px solid #e0e0e0", ctx_r1.isSearchInputFocused ? "45px" : "10px"))("tabIndex", 0)("placeholder", ctx_r1.isSearchInputFocused ? "" : ctx_r1.searchLabel);
|
|
95
|
-
i0.ɵɵattribute("aria-label", ctx_r1.searchLabel);
|
|
99
|
+
i0.ɵɵproperty("ngModel", ctx_r1.searchInput())("ngStyle", i0.ɵɵpureFunction3(7, _c7, ctx_r1.isSearchInputFocused() ? "12px" : "45px", ctx_r1.isSearchInputFocused() ? "1px solid #0937B2" : "1px solid #e0e0e0", ctx_r1.isSearchInputFocused() ? "45px" : "10px"))("tabIndex", 0)("placeholder", ctx_r1.isSearchInputFocused() ? "" : ctx_r1.searchLabel());
|
|
100
|
+
i0.ɵɵattribute("aria-label", ctx_r1.searchLabel());
|
|
96
101
|
i0.ɵɵadvance();
|
|
97
|
-
i0.ɵɵproperty("ngIf", ctx_r1.isSearchInputFocused);
|
|
102
|
+
i0.ɵɵproperty("ngIf", ctx_r1.isSearchInputFocused());
|
|
98
103
|
} }
|
|
99
104
|
function DropdownComponent_ng_template_10_div_2_Template(rf, ctx) { if (rf & 1) {
|
|
100
105
|
i0.ɵɵelementStart(0, "div", 30);
|
|
@@ -124,26 +129,23 @@ function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_di
|
|
|
124
129
|
} if (rf & 2) {
|
|
125
130
|
const item_r7 = i0.ɵɵnextContext(3).$implicit;
|
|
126
131
|
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
127
|
-
i0.ɵɵproperty("ngStyle", ctx_r1.getIconStyles(item_r7.icon, ctx_r1.activeItem));
|
|
128
132
|
i0.ɵɵadvance();
|
|
129
|
-
i0.ɵɵtextInterpolate1(" ", (item_r7 == null ? null : item_r7.label == null ? null : item_r7.label.secondaryText) ? item_r7 == null ? null : item_r7.label == null ? null : item_r7.label.secondaryText : ctx_r1.additionalInfoMessage, " ");
|
|
133
|
+
i0.ɵɵtextInterpolate1(" ", (item_r7 == null ? null : item_r7.label == null ? null : item_r7.label.secondaryText) ? item_r7 == null ? null : item_r7.label == null ? null : item_r7.label.secondaryText : ctx_r1.additionalInfoMessage(), " ");
|
|
130
134
|
} }
|
|
131
135
|
function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_0_Template(rf, ctx) { if (rf & 1) {
|
|
132
136
|
i0.ɵɵelementStart(0, "div", 8)(1, "span", 43);
|
|
133
137
|
i0.ɵɵtext(2);
|
|
134
138
|
i0.ɵɵelementEnd();
|
|
135
|
-
i0.ɵɵtemplate(3, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_0_span_3_Template, 2,
|
|
139
|
+
i0.ɵɵtemplate(3, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_0_span_3_Template, 2, 1, "span", 44);
|
|
136
140
|
i0.ɵɵelementEnd();
|
|
137
141
|
} if (rf & 2) {
|
|
138
142
|
const item_r7 = i0.ɵɵnextContext(2).$implicit;
|
|
139
143
|
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
140
|
-
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction3(
|
|
141
|
-
i0.ɵɵadvance();
|
|
142
|
-
i0.ɵɵ
|
|
143
|
-
i0.ɵɵadvance();
|
|
144
|
-
i0.ɵɵtextInterpolate(ctx_r1.multiLine ? item_r7 == null ? null : item_r7.label == null ? null : item_r7.label.primaryText : item_r7 == null ? null : item_r7.label);
|
|
144
|
+
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction3(3, _c10, item_r7.icon ? "90%" : "100%", ctx_r1.multiLine() ? "flex" : "inherit", ctx_r1.multiLine() ? "column" : "inherit"));
|
|
145
|
+
i0.ɵɵadvance(2);
|
|
146
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.multiLine() ? item_r7 == null ? null : item_r7.label == null ? null : item_r7.label.primaryText : item_r7 == null ? null : item_r7.label, " ");
|
|
145
147
|
i0.ɵɵadvance();
|
|
146
|
-
i0.ɵɵproperty("ngIf", ctx_r1.multiLine);
|
|
148
|
+
i0.ɵɵproperty("ngIf", ctx_r1.multiLine());
|
|
147
149
|
} }
|
|
148
150
|
function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_1_Template(rf, ctx) { if (rf & 1) {
|
|
149
151
|
i0.ɵɵelementStart(0, "div", 46);
|
|
@@ -155,11 +157,11 @@ function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_di
|
|
|
155
157
|
i0.ɵɵproperty("src", item_r7.icon, i0.ɵɵsanitizeUrl);
|
|
156
158
|
} }
|
|
157
159
|
function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_Template(rf, ctx) { if (rf & 1) {
|
|
158
|
-
i0.ɵɵtemplate(0, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_0_Template, 4,
|
|
160
|
+
i0.ɵɵtemplate(0, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_0_Template, 4, 7, "div", 41)(1, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_div_1_Template, 2, 1, "div", 42);
|
|
159
161
|
} if (rf & 2) {
|
|
160
162
|
const item_r7 = i0.ɵɵnextContext().$implicit;
|
|
161
163
|
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
162
|
-
i0.ɵɵproperty("ngIf", !ctx_r1.showOnlyIcon);
|
|
164
|
+
i0.ɵɵproperty("ngIf", !ctx_r1.showOnlyIcon());
|
|
163
165
|
i0.ɵɵadvance();
|
|
164
166
|
i0.ɵɵproperty("ngIf", item_r7.icon);
|
|
165
167
|
} }
|
|
@@ -170,10 +172,11 @@ function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_di
|
|
|
170
172
|
i0.ɵɵtemplate(1, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_container_1_Template, 2, 4, "ng-container", 39)(2, DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_div_1_ng_template_2_Template, 2, 2, "ng-template", null, 4, i0.ɵɵtemplateRefExtractor);
|
|
171
173
|
i0.ɵɵelementEnd();
|
|
172
174
|
} if (rf & 2) {
|
|
175
|
+
let tmp_11_0;
|
|
173
176
|
const item_r7 = ctx.$implicit;
|
|
174
177
|
const standardItem_r8 = i0.ɵɵreference(3);
|
|
175
178
|
const ctx_r1 = i0.ɵɵnextContext(4);
|
|
176
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction3(3, _c8, item_r7.disabled, ctx_r1.higlightSelectedValue && item_r7.value === (ctx_r1.selectedItem == null ? null :
|
|
179
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction3(3, _c8, item_r7.disabled, ctx_r1.higlightSelectedValue() && item_r7.value === ((tmp_11_0 = ctx_r1.selectedItem()) == null ? null : tmp_11_0.value), ctx_r1.showOnlyIcon()));
|
|
177
180
|
i0.ɵɵadvance();
|
|
178
181
|
i0.ɵɵproperty("ngIf", ctx_r1.customItem)("ngIfElse", standardItem_r8);
|
|
179
182
|
} }
|
|
@@ -183,7 +186,7 @@ function DropdownComponent_ng_template_10_div_4_cdk_virtual_scroll_viewport_2_Te
|
|
|
183
186
|
i0.ɵɵelementEnd();
|
|
184
187
|
} if (rf & 2) {
|
|
185
188
|
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
186
|
-
i0.ɵɵproperty("itemSize", ctx_r1.itemSizeForCdk || 36)("minBufferPx", 200)("maxBufferPx", 400);
|
|
189
|
+
i0.ɵɵproperty("itemSize", ctx_r1.itemSizeForCdk() || 36)("minBufferPx", 200)("maxBufferPx", 400);
|
|
187
190
|
i0.ɵɵadvance();
|
|
188
191
|
i0.ɵɵproperty("cdkVirtualForOf", ctx_r1.currentData);
|
|
189
192
|
} }
|
|
@@ -194,7 +197,7 @@ function DropdownComponent_ng_template_10_div_4_div_3_Template(rf, ctx) { if (rf
|
|
|
194
197
|
} if (rf & 2) {
|
|
195
198
|
const ctx_r1 = i0.ɵɵnextContext(3);
|
|
196
199
|
i0.ɵɵadvance();
|
|
197
|
-
i0.ɵɵtextInterpolate1(" ", ctx_r1.searchInput === "" ? ctx_r1.noDataMessage : "No results", " ");
|
|
200
|
+
i0.ɵɵtextInterpolate1(" ", ctx_r1.searchInput() === "" ? ctx_r1.noDataMessage() : "No results", " ");
|
|
198
201
|
} }
|
|
199
202
|
function DropdownComponent_ng_template_10_div_4_Template(rf, ctx) { if (rf & 1) {
|
|
200
203
|
i0.ɵɵelementStart(0, "div", 33, 3);
|
|
@@ -216,141 +219,150 @@ function DropdownComponent_ng_template_10_Template(rf, ctx) { if (rf & 1) {
|
|
|
216
219
|
i0.ɵɵelementEnd();
|
|
217
220
|
} if (rf & 2) {
|
|
218
221
|
const ctx_r1 = i0.ɵɵnextContext();
|
|
219
|
-
i0.ɵɵproperty("cdkTrapFocusAutoCapture", true)("ngStyle", i0.ɵɵpureFunction2(6, _c4, ctx_r1.dropdownListHeight, ctx_r1.dropdownListWidth));
|
|
222
|
+
i0.ɵɵproperty("cdkTrapFocusAutoCapture", true)("ngStyle", i0.ɵɵpureFunction2(6, _c4, ctx_r1.dropdownListHeight(), ctx_r1.dropdownListWidth()));
|
|
220
223
|
i0.ɵɵadvance();
|
|
221
|
-
i0.ɵɵproperty("ngIf", ctx_r1.searchEnabled);
|
|
224
|
+
i0.ɵɵproperty("ngIf", ctx_r1.searchEnabled());
|
|
222
225
|
i0.ɵɵadvance();
|
|
223
|
-
i0.ɵɵproperty("ngIf", ctx_r1.loading);
|
|
226
|
+
i0.ɵɵproperty("ngIf", ctx_r1.loading());
|
|
224
227
|
i0.ɵɵadvance();
|
|
225
|
-
i0.ɵɵproperty("ngIf", !ctx_r1.searchEnabled);
|
|
228
|
+
i0.ɵɵproperty("ngIf", !ctx_r1.searchEnabled());
|
|
226
229
|
i0.ɵɵadvance();
|
|
227
|
-
i0.ɵɵproperty("ngIf", !ctx_r1.loading);
|
|
230
|
+
i0.ɵɵproperty("ngIf", !ctx_r1.loading());
|
|
228
231
|
} }
|
|
229
232
|
class DropdownComponent {
|
|
230
233
|
set itemsContainer(container) {
|
|
231
234
|
this._itemsContainer = container;
|
|
232
|
-
if (container)
|
|
235
|
+
if (container)
|
|
233
236
|
this.measureAndUpdateHeight();
|
|
234
|
-
}
|
|
235
237
|
}
|
|
236
238
|
constructor(eRef, overlay, viewContainerRef, cdr) {
|
|
237
239
|
this.eRef = eRef;
|
|
238
240
|
this.overlay = overlay;
|
|
239
241
|
this.viewContainerRef = viewContainerRef;
|
|
240
242
|
this.cdr = cdr;
|
|
241
|
-
|
|
242
|
-
this.
|
|
243
|
-
this.
|
|
244
|
-
this.
|
|
245
|
-
this.
|
|
246
|
-
this.
|
|
247
|
-
this.dynamicHeight = "auto";
|
|
248
|
-
|
|
249
|
-
this.
|
|
250
|
-
|
|
251
|
-
this.
|
|
252
|
-
this.
|
|
253
|
-
this.
|
|
254
|
-
this.
|
|
255
|
-
this.
|
|
256
|
-
this.
|
|
257
|
-
this.
|
|
258
|
-
this.
|
|
259
|
-
this.
|
|
260
|
-
this.
|
|
261
|
-
this.
|
|
262
|
-
this.
|
|
263
|
-
this.
|
|
264
|
-
this.
|
|
265
|
-
this.
|
|
243
|
+
// Internal signals
|
|
244
|
+
this.isOpen = signal(false);
|
|
245
|
+
this.loading = signal(false);
|
|
246
|
+
this.isSearchInputFocused = signal(false);
|
|
247
|
+
this.searchInput = signal("");
|
|
248
|
+
this.searchData = signal([]);
|
|
249
|
+
this.dynamicHeight = signal("auto");
|
|
250
|
+
// ✅ Writable signal for internal data
|
|
251
|
+
this.internalData = signal([]);
|
|
252
|
+
// Inputs
|
|
253
|
+
this.data = input([]);
|
|
254
|
+
this.height = input("");
|
|
255
|
+
this.ariaLabel = input("");
|
|
256
|
+
this.width = input("");
|
|
257
|
+
this.label = input("Select");
|
|
258
|
+
this.itemSizeForCdk = input();
|
|
259
|
+
this.showOnlyIcon = input(false);
|
|
260
|
+
this.higlightSelectedValue = input(false);
|
|
261
|
+
this.dropdownListHeight = input("");
|
|
262
|
+
this.dropdownListWidth = input("");
|
|
263
|
+
this.dropdownListPosition = input("Left");
|
|
264
|
+
this.config = input();
|
|
265
|
+
this.searchEnabled = input(true);
|
|
266
|
+
this.selectedItem = input({ value: "", label: "" });
|
|
267
|
+
this.noDataMessage = input("No Data");
|
|
268
|
+
this.multiLine = input(false);
|
|
269
|
+
this.additionalInfoMessage = input("");
|
|
270
|
+
this.scrollIntoView = input(false);
|
|
271
|
+
this.searchLabel = input("Search Keyword");
|
|
272
|
+
this.customStyles = input({});
|
|
273
|
+
this.activeItem = input(false);
|
|
274
|
+
// Output
|
|
275
|
+
this.onChange = output();
|
|
266
276
|
this._itemsContainer = null;
|
|
277
|
+
// ✅ Keep internalData in sync with input data (and allow writes)
|
|
278
|
+
effect(() => {
|
|
279
|
+
this.internalData.set(this.data() || []);
|
|
280
|
+
}, { allowSignalWrites: true });
|
|
267
281
|
}
|
|
268
|
-
|
|
269
|
-
}
|
|
282
|
+
// ========== Core Logic ==========
|
|
270
283
|
measureAndUpdateHeight() {
|
|
271
|
-
if (!this.isOpen || !this._itemsContainer)
|
|
284
|
+
if (!this.isOpen() || !this._itemsContainer)
|
|
272
285
|
return;
|
|
273
|
-
const container = this._itemsContainer
|
|
274
|
-
const items = container
|
|
275
|
-
if (!items || items
|
|
276
|
-
this.dynamicHeight
|
|
286
|
+
const container = this._itemsContainer.nativeElement;
|
|
287
|
+
const items = container.querySelectorAll(".item");
|
|
288
|
+
if (!items || items.length === 0) {
|
|
289
|
+
this.dynamicHeight.set("50px");
|
|
277
290
|
return;
|
|
278
291
|
}
|
|
279
292
|
let totalMeasuredHeight = 0;
|
|
280
293
|
let maxItemHeight = 0;
|
|
281
|
-
Array.from(items)
|
|
294
|
+
Array.from(items)
|
|
295
|
+
.slice(0, Math.min(8, items.length))
|
|
296
|
+
.forEach((item) => {
|
|
282
297
|
const htmlItem = item;
|
|
283
|
-
let itemHeight = htmlItem
|
|
298
|
+
let itemHeight = htmlItem.offsetHeight || 0;
|
|
284
299
|
totalMeasuredHeight += itemHeight;
|
|
285
300
|
maxItemHeight = Math.max(maxItemHeight, itemHeight);
|
|
286
301
|
});
|
|
287
|
-
//Needed to handle the scrollbar coming for 2-3 items case
|
|
288
302
|
const containerPadding = 8;
|
|
289
303
|
const finalHeight = Math.max(50, Math.min(totalMeasuredHeight + containerPadding, 320));
|
|
290
|
-
this.dynamicHeight
|
|
304
|
+
this.dynamicHeight.set(this.dropdownListHeight() ? this.dropdownListHeight() : `${finalHeight}px`);
|
|
291
305
|
}
|
|
292
306
|
get currentData() {
|
|
293
|
-
return this.searchInput ? this.searchData : this.
|
|
307
|
+
return this.searchInput() ? this.searchData() : this.internalData();
|
|
294
308
|
}
|
|
295
309
|
get itemsContainerStyle() {
|
|
296
310
|
return {
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
};
|
|
301
|
-
}
|
|
302
|
-
getIconStyles(item, activeItem) {
|
|
303
|
-
return {
|
|
304
|
-
'color': item && activeItem ? '#0937B2' : '',
|
|
305
|
-
'font-weight': item && activeItem ? '700' : ''
|
|
311
|
+
height: this.dynamicHeight(),
|
|
312
|
+
"max-height": "320px",
|
|
313
|
+
"min-height": "50px",
|
|
306
314
|
};
|
|
307
315
|
}
|
|
308
316
|
setUpAsyncDataSearch() {
|
|
309
|
-
if (this.config) {
|
|
310
|
-
this.loading
|
|
311
|
-
this.config
|
|
312
|
-
|
|
313
|
-
|
|
317
|
+
if (this.config()) {
|
|
318
|
+
this.loading.set(true);
|
|
319
|
+
this.config()
|
|
320
|
+
?.dataStream()
|
|
321
|
+
?.pipe()
|
|
322
|
+
.subscribe((res) => {
|
|
323
|
+
this.internalData.set(res || []); // ✅ safe
|
|
324
|
+
this.loading.set(false);
|
|
314
325
|
setTimeout(() => this.measureAndUpdateHeight(), 60);
|
|
315
326
|
});
|
|
316
327
|
}
|
|
317
|
-
const index = this.
|
|
318
|
-
if (this.scrollIntoView && this.viewPort)
|
|
319
|
-
this.viewPort
|
|
320
|
-
|
|
321
|
-
filterByValue(array, string) {
|
|
322
|
-
return array?.filter(o => o?.label?.toLowerCase()?.includes(string?.toLowerCase()?.trim())) || [];
|
|
323
|
-
}
|
|
324
|
-
filterByPrimaryText(array, string) {
|
|
325
|
-
return array?.filter(o => o?.label?.primaryText?.toLowerCase()?.includes(string?.toLowerCase()?.trim())) || [];
|
|
328
|
+
const index = this.internalData()?.findIndex((dataItem) => dataItem?.value === this.selectedItem()?.value) || -1;
|
|
329
|
+
if (this.scrollIntoView() && this.viewPort) {
|
|
330
|
+
this.viewPort.scrollToIndex(index, "smooth");
|
|
331
|
+
}
|
|
326
332
|
}
|
|
327
333
|
searchInputOnChange(newValue) {
|
|
328
|
-
this.searchInput
|
|
334
|
+
this.searchInput.set(newValue);
|
|
329
335
|
if (newValue) {
|
|
330
|
-
this.searchData
|
|
336
|
+
this.searchData.set(this.multiLine()
|
|
337
|
+
? this.filterByPrimaryText(this.internalData(), newValue)
|
|
338
|
+
: this.filterByValue(this.internalData(), newValue));
|
|
331
339
|
}
|
|
332
340
|
else {
|
|
333
|
-
this.searchData
|
|
334
|
-
this.searchInput = "";
|
|
341
|
+
this.searchData.set([]);
|
|
335
342
|
}
|
|
336
343
|
requestAnimationFrame(() => this.measureAndUpdateHeight());
|
|
337
344
|
}
|
|
345
|
+
filterByValue(array, string) {
|
|
346
|
+
return (array?.filter((o) => o?.label?.toLowerCase()?.includes(string?.toLowerCase()?.trim())) || []);
|
|
347
|
+
}
|
|
348
|
+
filterByPrimaryText(array, string) {
|
|
349
|
+
return (array?.filter((o) => o?.label?.primaryText
|
|
350
|
+
?.toLowerCase()
|
|
351
|
+
?.includes(string?.toLowerCase()?.trim())) || []);
|
|
352
|
+
}
|
|
338
353
|
searchInputFocused(isFocused) {
|
|
339
|
-
this.isSearchInputFocused
|
|
354
|
+
this.isSearchInputFocused.set(isFocused);
|
|
340
355
|
}
|
|
341
356
|
searchInputCanceled(event) {
|
|
342
|
-
event
|
|
343
|
-
this.searchInput
|
|
344
|
-
this.isSearchInputFocused
|
|
357
|
+
event.stopPropagation();
|
|
358
|
+
this.searchInput.set("");
|
|
359
|
+
this.isSearchInputFocused.set(false);
|
|
345
360
|
requestAnimationFrame(() => this.measureAndUpdateHeight());
|
|
346
361
|
}
|
|
347
362
|
toggleDropdown() {
|
|
348
|
-
this.isOpen
|
|
349
|
-
if (this.isOpen) {
|
|
363
|
+
this.isOpen.set(!this.isOpen());
|
|
364
|
+
if (this.isOpen()) {
|
|
350
365
|
this.openDropdown(this.popupContainer, this.selectElement?.nativeElement);
|
|
351
|
-
setTimeout(() => {
|
|
352
|
-
this.measureAndUpdateHeight();
|
|
353
|
-
}, 100);
|
|
354
366
|
}
|
|
355
367
|
else {
|
|
356
368
|
this.onCancel();
|
|
@@ -359,18 +371,22 @@ class DropdownComponent {
|
|
|
359
371
|
openDropdown(template, origin) {
|
|
360
372
|
const positionsBottom = [
|
|
361
373
|
new ConnectionPositionPair({ originX: "start", originY: "bottom" }, { overlayX: "start", overlayY: "top" }, 0, 4),
|
|
362
|
-
new ConnectionPositionPair({ originX: "end", originY: "bottom" }, { overlayX: "end", overlayY: "top" }, 0, 4)
|
|
374
|
+
new ConnectionPositionPair({ originX: "end", originY: "bottom" }, { overlayX: "end", overlayY: "top" }, 0, 4),
|
|
363
375
|
];
|
|
364
376
|
const positionsTop = [
|
|
365
377
|
new ConnectionPositionPair({ originX: "start", originY: "top" }, { overlayX: "start", overlayY: "bottom" }, 0, -4),
|
|
366
|
-
new ConnectionPositionPair({ originX: "end", originY: "top" }, { overlayX: "end", overlayY: "bottom" }, 0, -4)
|
|
378
|
+
new ConnectionPositionPair({ originX: "end", originY: "top" }, { overlayX: "end", overlayY: "bottom" }, 0, -4),
|
|
367
379
|
];
|
|
368
380
|
const positionStrategy = this.overlay
|
|
369
381
|
.position()
|
|
370
382
|
.flexibleConnectedTo(origin)
|
|
371
383
|
.withPositions([
|
|
372
|
-
...(this.dropdownListPosition === "Right"
|
|
373
|
-
|
|
384
|
+
...(this.dropdownListPosition() === "Right"
|
|
385
|
+
? positionsBottom.reverse()
|
|
386
|
+
: positionsBottom),
|
|
387
|
+
...(this.dropdownListPosition() === "Right"
|
|
388
|
+
? positionsTop.reverse()
|
|
389
|
+
: positionsTop),
|
|
374
390
|
])
|
|
375
391
|
.withPush(true);
|
|
376
392
|
const configs = new OverlayConfig({
|
|
@@ -378,33 +394,35 @@ class DropdownComponent {
|
|
|
378
394
|
backdropClass: "cdk-overlay-transparent-backdrop",
|
|
379
395
|
scrollStrategy: this.overlay.scrollStrategies.block(),
|
|
380
396
|
positionStrategy,
|
|
381
|
-
width: origin?.clientWidth
|
|
397
|
+
width: origin?.clientWidth,
|
|
382
398
|
});
|
|
383
399
|
this.overlayRef = this.overlay.create(configs);
|
|
384
|
-
if (this.dropdownListWidth)
|
|
385
|
-
this.overlayRef
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
400
|
+
if (this.dropdownListWidth()) {
|
|
401
|
+
this.overlayRef.updateSize({ width: this.dropdownListWidth() });
|
|
402
|
+
}
|
|
403
|
+
if (this.dropdownListHeight()) {
|
|
404
|
+
this.overlayRef.updateSize({ height: this.dropdownListHeight() });
|
|
405
|
+
}
|
|
406
|
+
this.overlayRef.attach(new TemplatePortal(template, this.viewContainerRef));
|
|
407
|
+
this.overlayRef.backdropClick().subscribe(() => {
|
|
390
408
|
this.onCancel();
|
|
391
409
|
});
|
|
392
410
|
}
|
|
393
411
|
selectItem(item) {
|
|
394
|
-
this.onChange
|
|
412
|
+
this.onChange.emit(item);
|
|
395
413
|
this.toggleDropdown();
|
|
396
414
|
}
|
|
397
415
|
onCancel() {
|
|
398
|
-
this.isSearchInputFocused
|
|
399
|
-
this.isOpen
|
|
416
|
+
this.isSearchInputFocused.set(false);
|
|
417
|
+
this.isOpen.set(false);
|
|
400
418
|
this.overlayRef?.detach();
|
|
401
|
-
this.searchInput
|
|
402
|
-
this._itemsContainer = null;
|
|
419
|
+
this.searchInput.set("");
|
|
420
|
+
this._itemsContainer = null;
|
|
403
421
|
}
|
|
404
422
|
closeOnEsc(event) {
|
|
405
423
|
this.onCancel();
|
|
406
|
-
event
|
|
407
|
-
event
|
|
424
|
+
event.stopPropagation();
|
|
425
|
+
event.preventDefault();
|
|
408
426
|
}
|
|
409
427
|
static { this.ɵfac = function DropdownComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || DropdownComponent)(i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i1.Overlay), i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); }; }
|
|
410
428
|
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: DropdownComponent, selectors: [["mis-dropdown"]], contentQueries: function DropdownComponent_ContentQueries(rf, ctx, dirIndex) { if (rf & 1) {
|
|
@@ -415,17 +433,17 @@ class DropdownComponent {
|
|
|
415
433
|
} }, viewQuery: function DropdownComponent_Query(rf, ctx) { if (rf & 1) {
|
|
416
434
|
i0.ɵɵviewQuery(_c1, 5);
|
|
417
435
|
i0.ɵɵviewQuery(_c2, 5);
|
|
418
|
-
i0.ɵɵviewQuery(_c3, 5);
|
|
419
436
|
i0.ɵɵviewQuery(CdkVirtualScrollViewport, 5);
|
|
437
|
+
i0.ɵɵviewQuery(_c3, 5);
|
|
420
438
|
} if (rf & 2) {
|
|
421
439
|
let _t;
|
|
422
440
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.selectElement = _t.first);
|
|
423
441
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.popupContainer = _t.first);
|
|
424
|
-
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.itemsContainer = _t.first);
|
|
425
442
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.viewPort = _t.first);
|
|
443
|
+
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.itemsContainer = _t.first);
|
|
426
444
|
} }, hostBindings: function DropdownComponent_HostBindings(rf, ctx) { if (rf & 1) {
|
|
427
445
|
i0.ɵɵlistener("keyup.esc", function DropdownComponent_keyup_esc_HostBindingHandler($event) { return ctx.closeOnEsc($event); });
|
|
428
|
-
} }, inputs: { data: "data", height: "height", ariaLabel: "ariaLabel", width: "width", label: "label", itemSizeForCdk: "itemSizeForCdk", showOnlyIcon: "showOnlyIcon", higlightSelectedValue: "higlightSelectedValue", dropdownListHeight: "dropdownListHeight", dropdownListWidth: "dropdownListWidth", dropdownListPosition: "dropdownListPosition", config: "config", searchEnabled: "searchEnabled", selectedItem: "selectedItem", noDataMessage: "noDataMessage", multiLine: "multiLine", additionalInfoMessage: "additionalInfoMessage", scrollIntoView: "scrollIntoView", searchLabel: "searchLabel", customStyles: "customStyles", activeItem: "activeItem" }, outputs: { onChange: "onChange" }, decls: 12, vars: 16, consts: [["select", ""], ["showIcon", ""], ["popupContainer", ""], ["itemsContainer", ""], ["standardItem", ""], [1, "main-container", 3, "click", "keyup.enter", "ngStyle"], ["tabindex", "0", 1, "dropdown", 3, "keyup.enter", "click", "ngStyle", "ngClass"], ["class", "img-container", 3, "width", "height", "src", 4, "ngIf"], [1, "label", 3, "ngStyle"], ["class", "text", 4, "ngIf", "ngIfElse"], ["width", "20", "height", "20", "viewBox", "0 0 20 20", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 1, "handle", 3, "ngStyle"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M13.825 7.15845L10 10.9751L6.175 7.15845L5 8.33345L10 13.3334L15 8.33345L13.825 7.15845Z", "fill", "#181F33"], [1, "img-container", 3, "width", "height", "src"], [1, "text"], ["class", "text", 4, "ngIf"], ["class", "icon", "alt", "no img", 3, "src", 4, "ngIf"], ["alt", "no img", 1, "icon", 3, "src"], ["cdkTrapFocus", "", "tabindex", "0", "aria-label", "dropdown", 1, "popup-container", 3, "keyup.esc", "cdkTrapFocusAutoCapture", "ngStyle"], ["class", "search-container", 4, "ngIf"], ["class", "status-container", 4, "ngIf"], ["tabindex", "-1", "cdkFocusInitial", "", 4, "ngIf"], ["class", "items", 3, "ngStyle", 4, "ngIf"], [1, "search-container"], ["class", "search-icon", "width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 4, "ngIf"], [1, "search-input", 3, "ngModelChange", "focus", "ngModel", "ngStyle", "tabIndex", "placeholder"], ["class", "cancel-icon", "width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 3, "click", 4, "ngIf"], ["width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 1, "search-icon"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M4.21508 11.1456C4.21508 7.3179 7.33722 4.21165 11.1926 4.21165C15.048 4.21165 18.1702 7.3179 18.1702 11.1456C18.1702 12.6931 17.6599 14.1226 16.7972 15.2767L15.3685 16.7013C14.2044 17.5668 12.759 18.0796 11.1926 18.0796C7.33722 18.0796 4.21508 14.9734 4.21508 11.1456ZM15.9421 17.7835C14.6021 18.7329 12.9627 19.2913 11.1926 19.2913C6.66977 19.2913 3 15.6461 3 11.1456C3 6.64512 6.66977 3 11.1926 3C15.7155 3 19.3852 6.64512 19.3852 11.1456C19.3852 12.9371 18.8037 14.5931 17.8184 15.9375L19.8361 17.4048C20.6705 17.912 21.7554 18.6543 20.2454 20.215C18.7353 21.7756 18.0099 20.6663 17.4991 19.8364L15.9421 17.7835Z", "fill", "#6A737D"], ["width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 1, "cancel-icon", 3, "click"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M8.87446 7.32144C8.44588 6.89285 7.751 6.89285 7.32242 7.32144C6.89383 7.75002 6.89383 8.4449 7.32242 8.87349L10.4488 11.9999L7.32357 15.1252C6.89498 15.5538 6.89498 16.2486 7.32357 16.6772C7.75215 17.1058 8.44703 17.1058 8.87561 16.6772L12.0009 13.552L15.1261 16.6772C15.5547 17.1058 16.2496 17.1058 16.6781 16.6772C17.1067 16.2486 17.1067 15.5537 16.6781 15.1251L13.5529 11.9999L16.6793 8.87354C17.1079 8.44496 17.1079 7.75008 16.6793 7.3215C16.2507 6.89291 15.5558 6.89291 15.1273 7.3215L12.0009 10.4479L8.87446 7.32144Z", "fill", "#6A737D"], [1, "status-container"], [3, "mobileView"], ["tabindex", "-1", "cdkFocusInitial", ""], [1, "items", 3, "ngStyle"], ["class", "dropdown-viewport", 3, "itemSize", "minBufferPx", "maxBufferPx", 4, "ngIf"], ["class", "noData", 4, "ngIf"], [1, "dropdown-viewport", 3, "itemSize", "minBufferPx", "maxBufferPx"], ["class", "item", "tabindex", "0", "tabIndex", "0", 3, "ngClass", "click", "keyup.enter", 4, "cdkVirtualFor", "cdkVirtualForOf"], ["tabindex", "0", "tabIndex", "0", 1, "item", 3, "click", "keyup.enter", "ngClass"], [4, "ngIf", "ngIfElse"], [3, "ngTemplateOutlet", "ngTemplateOutletContext"], ["class", "label", 3, "ngStyle", 4, "ngIf"], ["class", "icon-container", 4, "ngIf"], [1, "primaryText"
|
|
446
|
+
} }, inputs: { data: [1, "data"], height: [1, "height"], ariaLabel: [1, "ariaLabel"], width: [1, "width"], label: [1, "label"], itemSizeForCdk: [1, "itemSizeForCdk"], showOnlyIcon: [1, "showOnlyIcon"], higlightSelectedValue: [1, "higlightSelectedValue"], dropdownListHeight: [1, "dropdownListHeight"], dropdownListWidth: [1, "dropdownListWidth"], dropdownListPosition: [1, "dropdownListPosition"], config: [1, "config"], searchEnabled: [1, "searchEnabled"], selectedItem: [1, "selectedItem"], noDataMessage: [1, "noDataMessage"], multiLine: [1, "multiLine"], additionalInfoMessage: [1, "additionalInfoMessage"], scrollIntoView: [1, "scrollIntoView"], searchLabel: [1, "searchLabel"], customStyles: [1, "customStyles"], activeItem: [1, "activeItem"] }, outputs: { onChange: "onChange" }, decls: 12, vars: 16, consts: [["select", ""], ["showIcon", ""], ["popupContainer", ""], ["itemsContainer", ""], ["standardItem", ""], [1, "main-container", 3, "click", "keyup.enter", "ngStyle"], ["tabindex", "0", 1, "dropdown", 3, "keyup.enter", "click", "ngStyle", "ngClass"], ["class", "img-container", 3, "width", "height", "src", 4, "ngIf"], [1, "label", 3, "ngStyle"], ["class", "text", 4, "ngIf", "ngIfElse"], ["width", "20", "height", "20", "viewBox", "0 0 20 20", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 1, "handle", 3, "ngStyle"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M13.825 7.15845L10 10.9751L6.175 7.15845L5 8.33345L10 13.3334L15 8.33345L13.825 7.15845Z", "fill", "#181F33"], [1, "img-container", 3, "width", "height", "src"], [1, "text"], ["class", "text", 4, "ngIf"], ["class", "icon", "alt", "no img", 3, "src", 4, "ngIf"], ["alt", "no img", 1, "icon", 3, "src"], ["cdkTrapFocus", "", "tabindex", "0", "aria-label", "dropdown", 1, "popup-container", 3, "keyup.esc", "cdkTrapFocusAutoCapture", "ngStyle"], ["class", "search-container", 4, "ngIf"], ["class", "status-container", 4, "ngIf"], ["tabindex", "-1", "cdkFocusInitial", "", 4, "ngIf"], ["class", "items", 3, "ngStyle", 4, "ngIf"], [1, "search-container"], ["class", "search-icon", "width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 4, "ngIf"], [1, "search-input", 3, "ngModelChange", "focus", "ngModel", "ngStyle", "tabIndex", "placeholder"], ["class", "cancel-icon", "width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 3, "click", 4, "ngIf"], ["width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 1, "search-icon"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M4.21508 11.1456C4.21508 7.3179 7.33722 4.21165 11.1926 4.21165C15.048 4.21165 18.1702 7.3179 18.1702 11.1456C18.1702 12.6931 17.6599 14.1226 16.7972 15.2767L15.3685 16.7013C14.2044 17.5668 12.759 18.0796 11.1926 18.0796C7.33722 18.0796 4.21508 14.9734 4.21508 11.1456ZM15.9421 17.7835C14.6021 18.7329 12.9627 19.2913 11.1926 19.2913C6.66977 19.2913 3 15.6461 3 11.1456C3 6.64512 6.66977 3 11.1926 3C15.7155 3 19.3852 6.64512 19.3852 11.1456C19.3852 12.9371 18.8037 14.5931 17.8184 15.9375L19.8361 17.4048C20.6705 17.912 21.7554 18.6543 20.2454 20.215C18.7353 21.7756 18.0099 20.6663 17.4991 19.8364L15.9421 17.7835Z", "fill", "#6A737D"], ["width", "24", "height", "24", "viewBox", "0 0 24 24", "fill", "none", "xmlns", "http://www.w3.org/2000/svg", 1, "cancel-icon", 3, "click"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M8.87446 7.32144C8.44588 6.89285 7.751 6.89285 7.32242 7.32144C6.89383 7.75002 6.89383 8.4449 7.32242 8.87349L10.4488 11.9999L7.32357 15.1252C6.89498 15.5538 6.89498 16.2486 7.32357 16.6772C7.75215 17.1058 8.44703 17.1058 8.87561 16.6772L12.0009 13.552L15.1261 16.6772C15.5547 17.1058 16.2496 17.1058 16.6781 16.6772C17.1067 16.2486 17.1067 15.5537 16.6781 15.1251L13.5529 11.9999L16.6793 8.87354C17.1079 8.44496 17.1079 7.75008 16.6793 7.3215C16.2507 6.89291 15.5558 6.89291 15.1273 7.3215L12.0009 10.4479L8.87446 7.32144Z", "fill", "#6A737D"], [1, "status-container"], [3, "mobileView"], ["tabindex", "-1", "cdkFocusInitial", ""], [1, "items", 3, "ngStyle"], ["class", "dropdown-viewport", 3, "itemSize", "minBufferPx", "maxBufferPx", 4, "ngIf"], ["class", "noData", 4, "ngIf"], [1, "dropdown-viewport", 3, "itemSize", "minBufferPx", "maxBufferPx"], ["class", "item", "tabindex", "0", "tabIndex", "0", 3, "ngClass", "click", "keyup.enter", 4, "cdkVirtualFor", "cdkVirtualForOf"], ["tabindex", "0", "tabIndex", "0", 1, "item", 3, "click", "keyup.enter", "ngClass"], [4, "ngIf", "ngIfElse"], [3, "ngTemplateOutlet", "ngTemplateOutletContext"], ["class", "label", 3, "ngStyle", 4, "ngIf"], ["class", "icon-container", 4, "ngIf"], [1, "primaryText"], ["class", "secondaryText", 4, "ngIf"], [1, "secondaryText"], [1, "icon-container"], [1, "noData"]], template: function DropdownComponent_Template(rf, ctx) { if (rf & 1) {
|
|
429
447
|
const _r1 = i0.ɵɵgetCurrentView();
|
|
430
448
|
i0.ɵɵelementStart(0, "div", 5);
|
|
431
449
|
i0.ɵɵlistener("click", function DropdownComponent_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.setUpAsyncDataSearch()); })("keyup.enter", function DropdownComponent_Template_div_keyup_enter_0_listener() { i0.ɵɵrestoreView(_r1); return i0.ɵɵresetView(ctx.setUpAsyncDataSearch()); });
|
|
@@ -441,127 +459,88 @@ class DropdownComponent {
|
|
|
441
459
|
i0.ɵɵelementEnd()()();
|
|
442
460
|
i0.ɵɵtemplate(10, DropdownComponent_ng_template_10_Template, 5, 9, "ng-template", null, 2, i0.ɵɵtemplateRefExtractor);
|
|
443
461
|
} if (rf & 2) {
|
|
462
|
+
let tmp_7_0;
|
|
463
|
+
let tmp_8_0;
|
|
444
464
|
const showIcon_r9 = i0.ɵɵreference(7);
|
|
445
|
-
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction2(9, _c4, ctx.height.length > 0 ? ctx.height : "", ctx.width.length > 0 ? ctx.width : ""));
|
|
465
|
+
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction2(9, _c4, ctx.height().length > 0 ? ctx.height() : "", ctx.width().length > 0 ? ctx.width() : ""));
|
|
446
466
|
i0.ɵɵadvance();
|
|
447
|
-
i0.ɵɵproperty("ngStyle", ctx.customStyles)("ngClass", ctx.isOpen ? "dropdown-port" : "");
|
|
448
|
-
i0.ɵɵattribute("aria-label", ctx.ariaLabel);
|
|
467
|
+
i0.ɵɵproperty("ngStyle", ctx.customStyles())("ngClass", ctx.isOpen() ? "dropdown-port" : "");
|
|
468
|
+
i0.ɵɵattribute("aria-label", ctx.ariaLabel());
|
|
449
469
|
i0.ɵɵadvance(2);
|
|
450
|
-
i0.ɵɵproperty("ngIf", ctx.selectedItem == null ? null :
|
|
470
|
+
i0.ɵɵproperty("ngIf", (tmp_7_0 = ctx.selectedItem()) == null ? null : tmp_7_0.customIcon);
|
|
451
471
|
i0.ɵɵadvance();
|
|
452
|
-
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction1(12, _c5, (ctx.selectedItem == null ? null :
|
|
472
|
+
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction1(12, _c5, ((tmp_8_0 = ctx.selectedItem()) == null ? null : tmp_8_0.customIcon) ? "calc(100% - 48px)" : "calc(100% - 32px)"));
|
|
453
473
|
i0.ɵɵadvance();
|
|
454
|
-
i0.ɵɵproperty("ngIf", !ctx.showOnlyIcon)("ngIfElse", showIcon_r9);
|
|
474
|
+
i0.ɵɵproperty("ngIf", !ctx.showOnlyIcon())("ngIfElse", showIcon_r9);
|
|
455
475
|
i0.ɵɵadvance(3);
|
|
456
|
-
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction1(14, _c6, ctx.isOpen ? "rotate(180deg)" : "rotate(0deg)"));
|
|
457
|
-
} }, dependencies: [i2.NgClass, i2.NgIf, i2.NgTemplateOutlet, i2.NgStyle, i3.DefaultValueAccessor, i3.NgControlStatus, i3.NgModel, i4.CdkFixedSizeVirtualScroll, i4.CdkVirtualForOf, i4.CdkVirtualScrollViewport, i5.LoaderComponent, i6.CdkTrapFocus], styles: ["[_ngcontent-%COMP%]:root{--pmry-200: #99BAF7;--pmry-100: #CBDDFB;--pmry-500: #0937B2;--pmry-400: #3C68D0;--pmry-600: #062A99;--pmry-700: #041F80;--pmry-300: #638FE7;--pmry-800: #021567;--pmry-900: #010F55;--sec-d-purple: #40447F;--sec-maroon: #6B034E;--sec-mud-red: #B23600;--sec-orange: #ED711C;--sec-purple: #815FD5;--sec-teal: #10ADAE;--sec-yellow: #D4900C;--sec-green: #547F40;--sec-bright-green: #27D22E;--sec-dark-teal: #035F6B;--sec-chocolate: #7C2F33;--sec-rube-pink: #C13D6D;--sec-cerulean: #0087B2;--sem-error: #B00020;--sem-info: #0091FF;--sem-warning: #FF9D00;--sem-success: #38AF49;--grey-bg-1: #FAFAFA;--grey-bg: #F5F5F5;--grey-seperators: #E0E0E0;--grey-disabled: #C8CDD3;--grey-hover: #F5F7FC;--grey-pressed: #E6EBF7;--grey-row: #F5F7FC;--dec-light-yellow: #F4E7C3;--dec-light-purple: #DACFF9;--dec-light-green: #E4F5E9;--dec-light-green2: #F1FFF3;--dec-light-pink: #FAE1EA;--dec-: #F4CBC1;--dec-lt-orange: #FAEFED;--dec-light-blue: #CFECF9;--dec-row-selection: #F1FDF8;--dec-row-selection2: #F2FBFF;--dec-row-lines: #D3E1E9;--text-white: #FFFFFF;--text-muted: #6A737D;--text-black: #181F33;--MR-solid-blue2:#C8D5F6;--MR-solid-purple:#C9C3FB;--MR-solid-orange:#EEAC9F;--MR-solid-green:#ACDADA;--MR-solid-brown:#E8C8AF;--MR-solid-yellow:#FFEFC7;--MR-solid-blue:#BBE6FF;--MR-solid-pink:#FFC6F2;--tr-hover:#F0F3FA;--tr-pressed:#DAE1F3;--brand-primary: #0937B2;--brand-primary-light: #3C68D0;--brand-primary-dark: #062A99;--brand-primary-darker: #041F80;--brand-primary-lighter: #638FE7;--brand-primary-lightest: #CBDDFB;--brand-primary-hover: #F0F3FA;--brand-primary-active: #DAE1F3;--brand-secondary: #ED711C;--brand-secondary-light: #F09E65;--brand-secondary-dark: #B23600;--brand-secondary-lighter: #FFC6F2;--brand-accent: #10ADAE;--brand-accent-light: #16CBBC;--brand-accent-dark: #035F6B;--brand-accent-lighter: #ACDADA;--brand-success: #38AF49;--brand-success-light: #4CAF50;--brand-success-dark: #216531;--brand-success-lighter: #E4F5E9;--brand-success-lightest: #F1FFF3;--brand-error: #B00020;--brand-error-light: #F04E4E;--brand-error-dark: #A60060;--brand-error-lighter: #FAE1EA;--brand-error-lightest: #FDF2F2;--brand-warning: #FF9D00;--brand-warning-light: #D4900C;--brand-warning-dark: #624000;--brand-warning-lighter: #F4E7C3;--brand-warning-lightest: #FAEFED;--brand-info: #0091FF;--brand-info-light: #35A1FF;--brand-info-dark: #0087B2;--brand-info-lighter: #CFECF9;--text-primary: #181F33;--text-secondary: #6A737D;--text-tertiary: #929DAB;--text-disabled: #929DAB;--text-primary-87: rgba(24, 31, 51, .87);--text-primary-60: rgba(24, 31, 51, .6);--text-primary-38: rgba(24, 31, 51, .38);--text-primary-12: rgba(24, 31, 51, .12);--bg-primary: #FFFFFF;--bg-secondary: #FAFAFA;--bg-tertiary: #F5F5F5;--bg-overlay: rgba(0, 0, 0, .32);--bg-overlay-light: rgba(0, 0, 0, .12);--bg-overlay-lighter: rgba(0, 0, 0, .08);--bg-overlay-lightest: rgba(0, 0, 0, .04);--border-primary: #E0E0E0;--border-secondary: #D6DCE2;--border-tertiary: #C8CDD3;--border-light: #F1F4F8;--border-primary-12: rgba(0, 0, 0, .12);--border-primary-08: rgba(0, 0, 0, .08);--border-primary-06: rgba(0, 0, 0, .06);--shadow-primary: rgba(0, 0, 0, .12);--shadow-secondary: rgba(0, 0, 0, .08);--shadow-tertiary: rgba(0, 0, 0, .04);--shadow-light: rgba(0, 0, 0, .06);--status-available: #929DAB;--status-unavailable: #CCD3DA;--status-hotseat: #857BFF;--status-multiteam: #10ADAE;--status-selected: #10ADAE;--status-upcoming: #D4900C;--status-room: #38AF49;--status-room-booked: #B23600;--status-room-unavailable: #181F33;--team-color-1: #F8C52E;--team-color-2: #FA8E20;--team-color-3: #987CDD;--team-color-4: #16CBBC;--team-color-5: #E65010;--team-color-6: #A60060;--team-color-7: #ED323B;--team-color-8: #35A1FF;--team-color-9: #80D348}.main-container[_ngcontent-%COMP%]{position:relative;display:flex;flex-wrap:wrap;justify-content:center;align-items:center;height:32px;width:256px;font-family:Lato,sans-serif!important}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;height:inherit;border:1px solid var(--border-primary, #E0E0E0);border-radius:6px;background-color:var(--bg-primary, #FFFFFF);cursor:pointer;display:flex;gap:4px;align-items:center;width:100%;box-sizing:border-box;padding:0 12px}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%]:hover, .main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%]:focus-visible{background-color:var(--brand-primary-hover, #F0F3FA);outline:none}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{box-sizing:border-box;display:flex;justify-content:flex-start;align-items:center;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:var(--text-primary, #181F33)}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{margin:0!important;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:var(--text-primary, #181F33)}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .count[_ngcontent-%COMP%]{background-color:var(--border-primary, #E0E0E0);border-radius:50%;padding:2px 7px;margin:0}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .handle[_ngcontent-%COMP%]{width:24px;height:24px;transition:.3s;position:absolute;right:12px;border-radius:50%;overflow:hidden}.main-container[_ngcontent-%COMP%] .dropdown-port[_ngcontent-%COMP%]{background:var(--brand-primary-active, #DAE1F3)}.popup-container[_ngcontent-%COMP%]{width:100%;max-height:340px;padding-bottom:0;border:1px solid var(--border-primary, #E0E0E0);border-radius:8px;background-color:var(--bg-primary, #FFFFFF);box-shadow:0 12px 24px #0000001f;display:flex;flex-direction:column;overflow:hidden;justify-content:space-between}.popup-container[_ngcontent-%COMP%]::-webkit-scrollbar{width:0;height:0}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%]{position:relative;box-sizing:border-box;padding:8px}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%] .search-icon[_ngcontent-%COMP%]{position:absolute;width:24px;height:24px;top:50%;transform:translateY(-50%);left:18px;z-index:1}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%] .search-input[_ngcontent-%COMP%]{height:40px;width:100%;padding:12px;border:1px solid var(--border-primary, #E0E0E0);box-sizing:border-box;border-radius:8px;outline:none;caret-color:var(--brand-primary, #0937B2);font-style:normal;font-weight:400;font-size:12px;line-height:18px;display:flex;align-items:center;letter-spacing:.2px;color:var(--text-primary, #181F33)}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%] .cancel-icon[_ngcontent-%COMP%]{position:absolute;cursor:pointer;width:24px;height:24px;top:50%;transform:translateY(-50%);right:18px;z-index:1}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%]{padding:0 0 8px 8px;overflow-y:auto}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%]::-webkit-scrollbar{width:5px;height:0}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:var(--text-tertiary, #929DAB);border-radius:10px}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .noData[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;height:44px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:var(--text-primary, #181F33)}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%]{height:100%}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]{cursor:pointer;display:flex;justify-content:flex-start;align-items:center;gap:10px;padding:4px 12px;border-radius:6px;min-height:40px;height:auto;letter-spacing:.2px;color:var(--text-primary, #181F33)}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]:hover, .popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]:focus-visible{background-color:var(--brand-primary-hover, #F0F3FA);outline:none}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{width:100%;line-height:20px;font-size:14px;font-style:normal;font-weight:400}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .primaryText[_ngcontent-%COMP%]{color:var(--text-primary, #181F33);font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .secondaryText[_ngcontent-%COMP%]{color:var(--text-secondary, #6A737D);font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .icon-container[_ngcontent-%COMP%]{width:10%;display:flex;justify-content:flex-end}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .icon-container[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:20px;height:20px}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%]{cursor:not-allowed!important}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%]:hover, .popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%]:focus-visible{background-color:transparent!important;outline:none!important}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] > span[_ngcontent-%COMP%]{color:var(--text-tertiary, #929DAB)!important;-webkit-user-select:none!important;user-select:none!important}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-selected[_ngcontent-%COMP%]{background-color:var(--brand-primary-active, #DAE1F3);outline:none}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .icon-only[_ngcontent-%COMP%]{justify-content:center!important}[_ngcontent-%COMP%]::-webkit-scrollbar{height:8px;width:8px;background:var(--bg-primary, #FFFFFF);border-radius:13px}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:var(--text-disabled, #C8CDD3);border-radius:13px;cursor:pointer}.status-container[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;height:128px}.status-container[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-align:center}"] }); }
|
|
476
|
+
i0.ɵɵproperty("ngStyle", i0.ɵɵpureFunction1(14, _c6, ctx.isOpen() ? "rotate(180deg)" : "rotate(0deg)"));
|
|
477
|
+
} }, dependencies: [i2.NgClass, i2.NgIf, i2.NgTemplateOutlet, i2.NgStyle, i3.DefaultValueAccessor, i3.NgControlStatus, i3.NgModel, i4.CdkFixedSizeVirtualScroll, i4.CdkVirtualForOf, i4.CdkVirtualScrollViewport, i5.LoaderComponent, i6.CdkTrapFocus], styles: [".main-container[_ngcontent-%COMP%]{position:relative;display:flex;flex-wrap:wrap;justify-content:center;align-items:center;height:32px;width:256px;font-family:Lato,sans-serif!important}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;height:inherit;border:1px solid #e0e0e0;border-radius:6px;background-color:#fff;cursor:pointer;display:flex;gap:4px;align-items:center;width:100%;box-sizing:border-box;padding:0 12px}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%]:hover, .main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%]:focus-visible{background-color:#f5f7fc;outline:none}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{box-sizing:border-box;display:flex;justify-content:flex-start;align-items:center;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{margin:0!important;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .count[_ngcontent-%COMP%]{background-color:#e0e0e0;border-radius:50%;padding:2px 7px;margin:0}.main-container[_ngcontent-%COMP%] .dropdown[_ngcontent-%COMP%] .handle[_ngcontent-%COMP%]{width:24px;height:24px;transition:.3s;position:absolute;right:12px;border-radius:50%;overflow:hidden}.main-container[_ngcontent-%COMP%] .dropdown-port[_ngcontent-%COMP%]{background:#e6ebf7}.popup-container[_ngcontent-%COMP%]{width:100%;max-height:340px;padding-bottom:0;border:1px solid #e0e0e0;border-radius:8px;background-color:#fff;box-shadow:0 12px 24px #0000001f;display:flex;flex-direction:column;overflow:hidden;justify-content:space-between}.popup-container[_ngcontent-%COMP%]::-webkit-scrollbar{width:0;height:0}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%]{position:relative;box-sizing:border-box;padding:8px}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%] .search-icon[_ngcontent-%COMP%]{position:absolute;width:24px;height:24px;top:50%;transform:translateY(-50%);left:18px;z-index:1}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%] .search-input[_ngcontent-%COMP%]{height:40px;width:100%;padding:12px;border:1px solid #e0e0e0;box-sizing:border-box;border-radius:8px;outline:none;caret-color:#0937b2;font-style:normal;font-weight:400;font-size:12px;line-height:18px;display:flex;align-items:center;letter-spacing:.2px;color:#181f33}.popup-container[_ngcontent-%COMP%] .search-container[_ngcontent-%COMP%] .cancel-icon[_ngcontent-%COMP%]{position:absolute;cursor:pointer;width:24px;height:24px;top:50%;transform:translateY(-50%);right:18px;z-index:1}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%]{padding:0 0 8px 8px;overflow-y:auto}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%]::-webkit-scrollbar{width:5px;height:0}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:#9aa7b4;border-radius:10px}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .noData[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;height:44px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%]{height:100%}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]{cursor:pointer;display:flex;justify-content:flex-start;align-items:center;gap:10px;padding:4px 12px;border-radius:6px;min-height:40px;height:auto;letter-spacing:.2px;color:#181f33}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]:hover, .popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%]:focus-visible{background-color:#f5f7fc;outline:none}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{width:100%;line-height:20px;font-size:14px;font-style:normal;font-weight:400}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .primaryText[_ngcontent-%COMP%]{color:#181f33;font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] .secondaryText[_ngcontent-%COMP%]{color:#6a737d;font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .icon-container[_ngcontent-%COMP%]{width:10%;display:flex;justify-content:flex-end}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .dropdown-viewport[_ngcontent-%COMP%] .item[_ngcontent-%COMP%] .icon-container[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:20px;height:20px}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%]{cursor:not-allowed!important}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%]:hover, .popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%]:focus-visible{background-color:transparent!important;outline:none!important}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-disabled[_ngcontent-%COMP%] .label[_ngcontent-%COMP%] > span[_ngcontent-%COMP%]{color:#929dab!important;-webkit-user-select:none!important;user-select:none!important}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .item-selected[_ngcontent-%COMP%]{background-color:#e0e6f6;outline:none}.popup-container[_ngcontent-%COMP%] .items[_ngcontent-%COMP%] .icon-only[_ngcontent-%COMP%]{justify-content:center!important}[_ngcontent-%COMP%]::-webkit-scrollbar{height:8px;width:8px;background:#fff;border-radius:13px}[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:#c8cdd3;border-radius:13px;cursor:pointer}.status-container[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;height:128px}.status-container[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-align:center}"] }); }
|
|
458
478
|
}
|
|
459
479
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DropdownComponent, [{
|
|
460
480
|
type: Component,
|
|
461
|
-
args: [{ selector: "mis-dropdown", template: "<div (click)=\"setUpAsyncDataSearch()\"\n(keyup.enter)=\"setUpAsyncDataSearch()\"\n class=\"main-container\"\n [ngStyle]=\"{\n height: height.length > 0 ? height : '',\n width: width.length > 0 ? width : ''\n }\"\n>\n <div\n class=\"dropdown\"\n #select\n tabindex=\"0\"\n (keyup.enter)=\"toggleDropdown()\"\n (click)=\"toggleDropdown()\"\n [ngStyle]=\"customStyles\"\n [attr.aria-label]=\"ariaLabel\"\n [ngClass]=\"isOpen ? 'dropdown-port': ''\"\n >\n <img class=\"img-container\" [width]=\"16\" [height]=\"16\" [src]=\"selectedItem?.customIcon\" *ngIf=\"selectedItem?.customIcon\">\n <div class=\"label\" [ngStyle]=\"{width: selectedItem?.customIcon ? 'calc(100% - 48px)' : 'calc(100% - 32px)'}\">\n <p class=\"text\" *ngIf=\"!showOnlyIcon; else showIcon\">\n {{ multiLine ? selectedItem?.label?.primaryText : selectedItem?.label || label }}\n </p>\n <ng-template #showIcon>\n <p class=\"text\" *ngIf=\"!selectedItem?.icon\">\n {{ label }}\n </p>\n <img class=\"icon\" *ngIf=\"!!selectedItem?.icon\" [src]=\"selectedItem?.icon\" alt=\"no img\" />\n </ng-template>\n </div>\n <svg\n class=\"handle\"\n [ngStyle]=\"{ transform: isOpen ? 'rotate(180deg)' : 'rotate(0deg)' }\"\n width=\"20\"\n height=\"20\"\n viewBox=\"0 0 20 20\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M13.825 7.15845L10 10.9751L6.175 7.15845L5 8.33345L10 13.3334L15 8.33345L13.825 7.15845Z\"\n fill=\"#181F33\"\n />\n </svg>\n </div>\n</div>\n<ng-template #popupContainer>\n <div\n class=\"popup-container\" cdkTrapFocus [cdkTrapFocusAutoCapture]=\"true\" tabindex=\"0\"\n [ngStyle]=\"{\n height: dropdownListHeight,\n width: dropdownListWidth\n }\"\n (keyup.esc)=\"closeOnEsc($event)\"\n aria-label=\"dropdown\"\n >\n <div *ngIf=\"searchEnabled\" class=\"search-container\">\n <svg\n *ngIf=\"!isSearchInputFocused\"\n class=\"search-icon\"\n width=\"24\"\n height=\"24\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M4.21508 11.1456C4.21508 7.3179 7.33722 4.21165 11.1926 4.21165C15.048 4.21165 18.1702 7.3179 18.1702 11.1456C18.1702 12.6931 17.6599 14.1226 16.7972 15.2767L15.3685 16.7013C14.2044 17.5668 12.759 18.0796 11.1926 18.0796C7.33722 18.0796 4.21508 14.9734 4.21508 11.1456ZM15.9421 17.7835C14.6021 18.7329 12.9627 19.2913 11.1926 19.2913C6.66977 19.2913 3 15.6461 3 11.1456C3 6.64512 6.66977 3 11.1926 3C15.7155 3 19.3852 6.64512 19.3852 11.1456C19.3852 12.9371 18.8037 14.5931 17.8184 15.9375L19.8361 17.4048C20.6705 17.912 21.7554 18.6543 20.2454 20.215C18.7353 21.7756 18.0099 20.6663 17.4991 19.8364L15.9421 17.7835Z\"\n fill=\"#6A737D\"\n />\n </svg>\n <input\n [ngModel]=\"searchInput\"\n [ngStyle]=\"{\n paddingLeft: isSearchInputFocused ? '12px' : '45px',\n border: isSearchInputFocused ? '1px solid #0937B2' : '1px solid #e0e0e0',\n paddingRight: isSearchInputFocused ? '45px' : '10px'\n }\"\n [tabIndex]=\"0\"\n (ngModelChange)=\"searchInputOnChange($event)\"\n [placeholder]=\"isSearchInputFocused ? '' : searchLabel\"\n (focus)=\"searchInputFocused(true)\"\n class=\"search-input\"\n [attr.aria-label]=\"searchLabel\"\n />\n <svg\n *ngIf=\"isSearchInputFocused\"\n class=\"cancel-icon\"\n (click)=\"searchInputCanceled($event)\"\n width=\"24\"\n height=\"24\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M8.87446 7.32144C8.44588 6.89285 7.751 6.89285 7.32242 7.32144C6.89383 7.75002 6.89383 8.4449 7.32242 8.87349L10.4488 11.9999L7.32357 15.1252C6.89498 15.5538 6.89498 16.2486 7.32357 16.6772C7.75215 17.1058 8.44703 17.1058 8.87561 16.6772L12.0009 13.552L15.1261 16.6772C15.5547 17.1058 16.2496 17.1058 16.6781 16.6772C17.1067 16.2486 17.1067 15.5537 16.6781 15.1251L13.5529 11.9999L16.6793 8.87354C17.1079 8.44496 17.1079 7.75008 16.6793 7.3215C16.2507 6.89291 15.5558 6.89291 15.1273 7.3215L12.0009 10.4479L8.87446 7.32144Z\"\n fill=\"#6A737D\"\n />\n </svg>\n </div>\n <div class=\"status-container\" *ngIf=\"loading\">\n <mis-loader [mobileView]=\"true\"></mis-loader>\n </div>\n <div tabindex=\"-1\" *ngIf=\"!searchEnabled\" cdkFocusInitial></div>\n <div class=\"items\" #itemsContainer [ngStyle]=\"itemsContainerStyle\" *ngIf=\"!loading \">\n <cdk-virtual-scroll-viewport *ngIf=\"currentData.length > 0\" \n [itemSize]=\"itemSizeForCdk || 36\" \n class=\"dropdown-viewport\"\n [minBufferPx]=\"200\"\n [maxBufferPx]=\"400\">\n <div\n class=\"item\"\n tabindex=\"0\"\n [ngClass]=\"{ 'item-disabled': item.disabled, 'item-selected': (higlightSelectedValue && item.value === selectedItem?.value), 'icon-only' : showOnlyIcon }\"\n (click)=\"item.disabled ? null : selectItem(item)\"\n (keyup.enter)=\"item.disabled ? null : selectItem(item)\"\n *cdkVirtualFor=\"let item of currentData; let i = index\"\n tabIndex=\"0\"\n >\n <ng-container *ngIf=\"customItem; else standardItem\">\n <ng-container\n [ngTemplateOutlet]=\"customItem\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n ></ng-container>\n </ng-container>\n <ng-template #standardItem>\n <div class=\"label\" *ngIf=\"!showOnlyIcon\" [ngStyle]=\"{ width: item.icon ? '90%' : '100%', 'display': multiLine ? 'flex': 'inherit', 'flex-direction': multiLine ? 'column': 'inherit' }\">\n <span class=\"primaryText\" [ngStyle]=\"getIconStyles(item.icon, activeItem)\">{{ multiLine ? item?.label?.primaryText : item?.label }}</span>\n <span class=\"secondaryText\" *ngIf=\"multiLine\" [ngStyle]=\"getIconStyles(item.icon, activeItem)\"> {{ item?.label?.secondaryText ? item?.label?.secondaryText : additionalInfoMessage }} </span>\n </div>\n <div class=\"icon-container\" *ngIf=\"item.icon\">\n <img class=\"icon\" [src]=\"item.icon\" alt=\"no img\" />\n </div>\n </ng-template>\n </div>\n </cdk-virtual-scroll-viewport>\n <div class=\"noData\" *ngIf=\"currentData.length === 0\">\n {{ searchInput === \"\" ? noDataMessage : \"No results\" }}\n </div>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--pmry-200: #99BAF7;--pmry-100: #CBDDFB;--pmry-500: #0937B2;--pmry-400: #3C68D0;--pmry-600: #062A99;--pmry-700: #041F80;--pmry-300: #638FE7;--pmry-800: #021567;--pmry-900: #010F55;--sec-d-purple: #40447F;--sec-maroon: #6B034E;--sec-mud-red: #B23600;--sec-orange: #ED711C;--sec-purple: #815FD5;--sec-teal: #10ADAE;--sec-yellow: #D4900C;--sec-green: #547F40;--sec-bright-green: #27D22E;--sec-dark-teal: #035F6B;--sec-chocolate: #7C2F33;--sec-rube-pink: #C13D6D;--sec-cerulean: #0087B2;--sem-error: #B00020;--sem-info: #0091FF;--sem-warning: #FF9D00;--sem-success: #38AF49;--grey-bg-1: #FAFAFA;--grey-bg: #F5F5F5;--grey-seperators: #E0E0E0;--grey-disabled: #C8CDD3;--grey-hover: #F5F7FC;--grey-pressed: #E6EBF7;--grey-row: #F5F7FC;--dec-light-yellow: #F4E7C3;--dec-light-purple: #DACFF9;--dec-light-green: #E4F5E9;--dec-light-green2: #F1FFF3;--dec-light-pink: #FAE1EA;--dec-: #F4CBC1;--dec-lt-orange: #FAEFED;--dec-light-blue: #CFECF9;--dec-row-selection: #F1FDF8;--dec-row-selection2: #F2FBFF;--dec-row-lines: #D3E1E9;--text-white: #FFFFFF;--text-muted: #6A737D;--text-black: #181F33;--MR-solid-blue2:#C8D5F6;--MR-solid-purple:#C9C3FB;--MR-solid-orange:#EEAC9F;--MR-solid-green:#ACDADA;--MR-solid-brown:#E8C8AF;--MR-solid-yellow:#FFEFC7;--MR-solid-blue:#BBE6FF;--MR-solid-pink:#FFC6F2;--tr-hover:#F0F3FA;--tr-pressed:#DAE1F3;--brand-primary: #0937B2;--brand-primary-light: #3C68D0;--brand-primary-dark: #062A99;--brand-primary-darker: #041F80;--brand-primary-lighter: #638FE7;--brand-primary-lightest: #CBDDFB;--brand-primary-hover: #F0F3FA;--brand-primary-active: #DAE1F3;--brand-secondary: #ED711C;--brand-secondary-light: #F09E65;--brand-secondary-dark: #B23600;--brand-secondary-lighter: #FFC6F2;--brand-accent: #10ADAE;--brand-accent-light: #16CBBC;--brand-accent-dark: #035F6B;--brand-accent-lighter: #ACDADA;--brand-success: #38AF49;--brand-success-light: #4CAF50;--brand-success-dark: #216531;--brand-success-lighter: #E4F5E9;--brand-success-lightest: #F1FFF3;--brand-error: #B00020;--brand-error-light: #F04E4E;--brand-error-dark: #A60060;--brand-error-lighter: #FAE1EA;--brand-error-lightest: #FDF2F2;--brand-warning: #FF9D00;--brand-warning-light: #D4900C;--brand-warning-dark: #624000;--brand-warning-lighter: #F4E7C3;--brand-warning-lightest: #FAEFED;--brand-info: #0091FF;--brand-info-light: #35A1FF;--brand-info-dark: #0087B2;--brand-info-lighter: #CFECF9;--text-primary: #181F33;--text-secondary: #6A737D;--text-tertiary: #929DAB;--text-disabled: #929DAB;--text-primary-87: rgba(24, 31, 51, .87);--text-primary-60: rgba(24, 31, 51, .6);--text-primary-38: rgba(24, 31, 51, .38);--text-primary-12: rgba(24, 31, 51, .12);--bg-primary: #FFFFFF;--bg-secondary: #FAFAFA;--bg-tertiary: #F5F5F5;--bg-overlay: rgba(0, 0, 0, .32);--bg-overlay-light: rgba(0, 0, 0, .12);--bg-overlay-lighter: rgba(0, 0, 0, .08);--bg-overlay-lightest: rgba(0, 0, 0, .04);--border-primary: #E0E0E0;--border-secondary: #D6DCE2;--border-tertiary: #C8CDD3;--border-light: #F1F4F8;--border-primary-12: rgba(0, 0, 0, .12);--border-primary-08: rgba(0, 0, 0, .08);--border-primary-06: rgba(0, 0, 0, .06);--shadow-primary: rgba(0, 0, 0, .12);--shadow-secondary: rgba(0, 0, 0, .08);--shadow-tertiary: rgba(0, 0, 0, .04);--shadow-light: rgba(0, 0, 0, .06);--status-available: #929DAB;--status-unavailable: #CCD3DA;--status-hotseat: #857BFF;--status-multiteam: #10ADAE;--status-selected: #10ADAE;--status-upcoming: #D4900C;--status-room: #38AF49;--status-room-booked: #B23600;--status-room-unavailable: #181F33;--team-color-1: #F8C52E;--team-color-2: #FA8E20;--team-color-3: #987CDD;--team-color-4: #16CBBC;--team-color-5: #E65010;--team-color-6: #A60060;--team-color-7: #ED323B;--team-color-8: #35A1FF;--team-color-9: #80D348}.main-container{position:relative;display:flex;flex-wrap:wrap;justify-content:center;align-items:center;height:32px;width:256px;font-family:Lato,sans-serif!important}.main-container .dropdown{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;height:inherit;border:1px solid var(--border-primary, #E0E0E0);border-radius:6px;background-color:var(--bg-primary, #FFFFFF);cursor:pointer;display:flex;gap:4px;align-items:center;width:100%;box-sizing:border-box;padding:0 12px}.main-container .dropdown:hover,.main-container .dropdown:focus-visible{background-color:var(--brand-primary-hover, #F0F3FA);outline:none}.main-container .dropdown .label{box-sizing:border-box;display:flex;justify-content:flex-start;align-items:center;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:var(--text-primary, #181F33)}.main-container .dropdown .label .text{margin:0!important;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:var(--text-primary, #181F33)}.main-container .dropdown .label .count{background-color:var(--border-primary, #E0E0E0);border-radius:50%;padding:2px 7px;margin:0}.main-container .dropdown .handle{width:24px;height:24px;transition:.3s;position:absolute;right:12px;border-radius:50%;overflow:hidden}.main-container .dropdown-port{background:var(--brand-primary-active, #DAE1F3)}.popup-container{width:100%;max-height:340px;padding-bottom:0;border:1px solid var(--border-primary, #E0E0E0);border-radius:8px;background-color:var(--bg-primary, #FFFFFF);box-shadow:0 12px 24px #0000001f;display:flex;flex-direction:column;overflow:hidden;justify-content:space-between}.popup-container::-webkit-scrollbar{width:0;height:0}.popup-container .search-container{position:relative;box-sizing:border-box;padding:8px}.popup-container .search-container .search-icon{position:absolute;width:24px;height:24px;top:50%;transform:translateY(-50%);left:18px;z-index:1}.popup-container .search-container .search-input{height:40px;width:100%;padding:12px;border:1px solid var(--border-primary, #E0E0E0);box-sizing:border-box;border-radius:8px;outline:none;caret-color:var(--brand-primary, #0937B2);font-style:normal;font-weight:400;font-size:12px;line-height:18px;display:flex;align-items:center;letter-spacing:.2px;color:var(--text-primary, #181F33)}.popup-container .search-container .cancel-icon{position:absolute;cursor:pointer;width:24px;height:24px;top:50%;transform:translateY(-50%);right:18px;z-index:1}.popup-container .items{padding:0 0 8px 8px;overflow-y:auto}.popup-container .items::-webkit-scrollbar{width:5px;height:0}.popup-container .items::-webkit-scrollbar-thumb{background:var(--text-tertiary, #929DAB);border-radius:10px}.popup-container .items .noData{display:flex;justify-content:center;align-items:center;height:44px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:var(--text-primary, #181F33)}.popup-container .items .dropdown-viewport{height:100%}.popup-container .items .dropdown-viewport .item{cursor:pointer;display:flex;justify-content:flex-start;align-items:center;gap:10px;padding:4px 12px;border-radius:6px;min-height:40px;height:auto;letter-spacing:.2px;color:var(--text-primary, #181F33)}.popup-container .items .dropdown-viewport .item:hover,.popup-container .items .dropdown-viewport .item:focus-visible{background-color:var(--brand-primary-hover, #F0F3FA);outline:none}.popup-container .items .dropdown-viewport .item .label{width:100%;line-height:20px;font-size:14px;font-style:normal;font-weight:400}.popup-container .items .dropdown-viewport .item .label .primaryText{color:var(--text-primary, #181F33);font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container .items .dropdown-viewport .item .label .secondaryText{color:var(--text-secondary, #6A737D);font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container .items .dropdown-viewport .item .icon-container{width:10%;display:flex;justify-content:flex-end}.popup-container .items .dropdown-viewport .item .icon-container .icon{width:20px;height:20px}.popup-container .items .item-disabled{cursor:not-allowed!important}.popup-container .items .item-disabled:hover,.popup-container .items .item-disabled:focus-visible{background-color:transparent!important;outline:none!important}.popup-container .items .item-disabled .label>span{color:var(--text-tertiary, #929DAB)!important;-webkit-user-select:none!important;user-select:none!important}.popup-container .items .item-selected{background-color:var(--brand-primary-active, #DAE1F3);outline:none}.popup-container .items .icon-only{justify-content:center!important}::-webkit-scrollbar{height:8px;width:8px;background:var(--bg-primary, #FFFFFF);border-radius:13px}::-webkit-scrollbar-thumb{background:var(--text-disabled, #C8CDD3);border-radius:13px;cursor:pointer}.status-container{display:flex;justify-content:center;align-items:center;height:128px}.status-container p{text-align:center}\n"] }]
|
|
462
|
-
}], () => [{ type: i0.ElementRef }, { type: i1.Overlay }, { type: i0.ViewContainerRef }, { type: i0.ChangeDetectorRef }], {
|
|
463
|
-
type: Input
|
|
464
|
-
}], height: [{
|
|
465
|
-
type: Input
|
|
466
|
-
}], ariaLabel: [{
|
|
467
|
-
type: Input
|
|
468
|
-
}], width: [{
|
|
469
|
-
type: Input
|
|
470
|
-
}], label: [{
|
|
471
|
-
type: Input
|
|
472
|
-
}], itemSizeForCdk: [{
|
|
473
|
-
type: Input
|
|
474
|
-
}], showOnlyIcon: [{
|
|
475
|
-
type: Input
|
|
476
|
-
}], higlightSelectedValue: [{
|
|
477
|
-
type: Input
|
|
478
|
-
}], dropdownListHeight: [{
|
|
479
|
-
type: Input
|
|
480
|
-
}], dropdownListWidth: [{
|
|
481
|
-
type: Input
|
|
482
|
-
}], dropdownListPosition: [{
|
|
483
|
-
type: Input
|
|
484
|
-
}], config: [{
|
|
485
|
-
type: Input
|
|
486
|
-
}], searchEnabled: [{
|
|
487
|
-
type: Input
|
|
488
|
-
}], selectedItem: [{
|
|
489
|
-
type: Input
|
|
490
|
-
}], noDataMessage: [{
|
|
491
|
-
type: Input
|
|
492
|
-
}], multiLine: [{
|
|
493
|
-
type: Input
|
|
494
|
-
}], additionalInfoMessage: [{
|
|
495
|
-
type: Input
|
|
496
|
-
}], scrollIntoView: [{
|
|
497
|
-
type: Input
|
|
498
|
-
}], searchLabel: [{
|
|
499
|
-
type: Input
|
|
500
|
-
}], customStyles: [{
|
|
501
|
-
type: Input
|
|
502
|
-
}], activeItem: [{
|
|
503
|
-
type: Input
|
|
504
|
-
}], onChange: [{
|
|
505
|
-
type: Output
|
|
506
|
-
}], selectElement: [{
|
|
481
|
+
args: [{ selector: "mis-dropdown", template: "<div (click)=\"setUpAsyncDataSearch()\"\n(keyup.enter)=\"setUpAsyncDataSearch()\"\n class=\"main-container\"\n [ngStyle]=\"{\n height: height().length > 0 ? height() : '',\n width: width().length > 0 ? width() : ''\n }\"\n>\n <div\n class=\"dropdown\"\n #select\n tabindex=\"0\"\n (keyup.enter)=\"toggleDropdown()\"\n (click)=\"toggleDropdown()\"\n [ngStyle]=\"customStyles()\"\n [attr.aria-label]=\"ariaLabel()\"\n [ngClass]=\"isOpen() ? 'dropdown-port': ''\"\n >\n <img class=\"img-container\" [width]=\"16\" [height]=\"16\" [src]=\"selectedItem()?.customIcon\" *ngIf=\"selectedItem()?.customIcon\">\n <div class=\"label\" [ngStyle]=\"{width: selectedItem()?.customIcon ? 'calc(100% - 48px)' : 'calc(100% - 32px)'}\">\n <p class=\"text\" *ngIf=\"!showOnlyIcon(); else showIcon\">\n {{ multiLine() ? selectedItem()?.label?.primaryText : selectedItem()?.label || label() }}\n </p>\n <ng-template #showIcon>\n <p class=\"text\" *ngIf=\"!selectedItem()?.icon\">\n {{ label() }}\n </p>\n <img class=\"icon\" *ngIf=\"!!selectedItem()?.icon\" [src]=\"selectedItem()?.icon\" alt=\"no img\" />\n </ng-template>\n </div>\n <svg\n class=\"handle\"\n [ngStyle]=\"{ transform: isOpen() ? 'rotate(180deg)' : 'rotate(0deg)' }\"\n width=\"20\"\n height=\"20\"\n viewBox=\"0 0 20 20\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M13.825 7.15845L10 10.9751L6.175 7.15845L5 8.33345L10 13.3334L15 8.33345L13.825 7.15845Z\"\n fill=\"#181F33\"\n />\n </svg>\n </div>\n</div>\n\n<ng-template #popupContainer>\n <div\n class=\"popup-container\" \n cdkTrapFocus \n [cdkTrapFocusAutoCapture]=\"true\" \n tabindex=\"0\"\n [ngStyle]=\"{\n height: dropdownListHeight(),\n width: dropdownListWidth()\n }\"\n (keyup.esc)=\"closeOnEsc($event)\"\n aria-label=\"dropdown\"\n >\n <div *ngIf=\"searchEnabled()\" class=\"search-container\">\n <svg\n *ngIf=\"!isSearchInputFocused()\"\n class=\"search-icon\"\n width=\"24\"\n height=\"24\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M4.21508 11.1456C4.21508 7.3179 7.33722 4.21165 11.1926 4.21165C15.048 4.21165 18.1702 7.3179 18.1702 11.1456C18.1702 12.6931 17.6599 14.1226 16.7972 15.2767L15.3685 16.7013C14.2044 17.5668 12.759 18.0796 11.1926 18.0796C7.33722 18.0796 4.21508 14.9734 4.21508 11.1456ZM15.9421 17.7835C14.6021 18.7329 12.9627 19.2913 11.1926 19.2913C6.66977 19.2913 3 15.6461 3 11.1456C3 6.64512 6.66977 3 11.1926 3C15.7155 3 19.3852 6.64512 19.3852 11.1456C19.3852 12.9371 18.8037 14.5931 17.8184 15.9375L19.8361 17.4048C20.6705 17.912 21.7554 18.6543 20.2454 20.215C18.7353 21.7756 18.0099 20.6663 17.4991 19.8364L15.9421 17.7835Z\"\n fill=\"#6A737D\"\n />\n </svg>\n <input\n [ngModel]=\"searchInput()\"\n [ngStyle]=\"{\n paddingLeft: isSearchInputFocused() ? '12px' : '45px',\n border: isSearchInputFocused() ? '1px solid #0937B2' : '1px solid #e0e0e0',\n paddingRight: isSearchInputFocused() ? '45px' : '10px'\n }\"\n [tabIndex]=\"0\"\n (ngModelChange)=\"searchInputOnChange($event)\"\n [placeholder]=\"isSearchInputFocused() ? '' : searchLabel()\"\n (focus)=\"searchInputFocused(true)\"\n class=\"search-input\"\n [attr.aria-label]=\"searchLabel()\"\n />\n <svg\n *ngIf=\"isSearchInputFocused()\"\n class=\"cancel-icon\"\n (click)=\"searchInputCanceled($event)\"\n width=\"24\"\n height=\"24\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M8.87446 7.32144C8.44588 6.89285 7.751 6.89285 7.32242 7.32144C6.89383 7.75002 6.89383 8.4449 7.32242 8.87349L10.4488 11.9999L7.32357 15.1252C6.89498 15.5538 6.89498 16.2486 7.32357 16.6772C7.75215 17.1058 8.44703 17.1058 8.87561 16.6772L12.0009 13.552L15.1261 16.6772C15.5547 17.1058 16.2496 17.1058 16.6781 16.6772C17.1067 16.2486 17.1067 15.5537 16.6781 15.1251L13.5529 11.9999L16.6793 8.87354C17.1079 8.44496 17.1079 7.75008 16.6793 7.3215C16.2507 6.89291 15.5558 6.89291 15.1273 7.3215L12.0009 10.4479L8.87446 7.32144Z\"\n fill=\"#6A737D\"\n />\n </svg>\n </div>\n <div class=\"status-container\" *ngIf=\"loading()\">\n <mis-loader [mobileView]=\"true\"></mis-loader>\n </div>\n <div tabindex=\"-1\" *ngIf=\"!searchEnabled()\" cdkFocusInitial></div>\n <div class=\"items\" #itemsContainer [ngStyle]=\"itemsContainerStyle\" *ngIf=\"!loading()\">\n <cdk-virtual-scroll-viewport *ngIf=\"currentData.length > 0\" \n [itemSize]=\"itemSizeForCdk() || 36\" \n class=\"dropdown-viewport\"\n [minBufferPx]=\"200\"\n [maxBufferPx]=\"400\">\n <div\n class=\"item\"\n tabindex=\"0\"\n [ngClass]=\"{ \n 'item-disabled': item.disabled, \n 'item-selected': (higlightSelectedValue() && item.value === selectedItem()?.value), \n 'icon-only': showOnlyIcon() \n }\"\n (click)=\"item.disabled ? null : selectItem(item)\"\n (keyup.enter)=\"item.disabled ? null : selectItem(item)\"\n *cdkVirtualFor=\"let item of currentData; let i = index\"\n tabIndex=\"0\"\n >\n <ng-container *ngIf=\"customItem; else standardItem\">\n <ng-container\n [ngTemplateOutlet]=\"customItem\"\n [ngTemplateOutletContext]=\"{ $implicit: item }\"\n ></ng-container>\n </ng-container>\n <ng-template #standardItem>\n <div class=\"label\" *ngIf=\"!showOnlyIcon()\" [ngStyle]=\"{ \n width: item.icon ? '90%' : '100%', \n 'display': multiLine() ? 'flex': 'inherit', \n 'flex-direction': multiLine() ? 'column': 'inherit' \n }\">\n <span class=\"primaryText\">\n {{ multiLine() ? item?.label?.primaryText : item?.label }}\n </span>\n <span class=\"secondaryText\" *ngIf=\"multiLine()\">\n {{ item?.label?.secondaryText ? item?.label?.secondaryText : additionalInfoMessage() }}\n </span>\n </div>\n <div class=\"icon-container\" *ngIf=\"item.icon\">\n <img class=\"icon\" [src]=\"item.icon\" alt=\"no img\" />\n </div>\n </ng-template>\n </div>\n </cdk-virtual-scroll-viewport>\n <div class=\"noData\" *ngIf=\"currentData.length === 0\">\n {{ searchInput() === \"\" ? noDataMessage() : \"No results\" }}\n </div>\n </div>\n </div>\n</ng-template>", styles: [".main-container{position:relative;display:flex;flex-wrap:wrap;justify-content:center;align-items:center;height:32px;width:256px;font-family:Lato,sans-serif!important}.main-container .dropdown{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;height:inherit;border:1px solid #e0e0e0;border-radius:6px;background-color:#fff;cursor:pointer;display:flex;gap:4px;align-items:center;width:100%;box-sizing:border-box;padding:0 12px}.main-container .dropdown:hover,.main-container .dropdown:focus-visible{background-color:#f5f7fc;outline:none}.main-container .dropdown .label{box-sizing:border-box;display:flex;justify-content:flex-start;align-items:center;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.main-container .dropdown .label .text{margin:0!important;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.main-container .dropdown .label .count{background-color:#e0e0e0;border-radius:50%;padding:2px 7px;margin:0}.main-container .dropdown .handle{width:24px;height:24px;transition:.3s;position:absolute;right:12px;border-radius:50%;overflow:hidden}.main-container .dropdown-port{background:#e6ebf7}.popup-container{width:100%;max-height:340px;padding-bottom:0;border:1px solid #e0e0e0;border-radius:8px;background-color:#fff;box-shadow:0 12px 24px #0000001f;display:flex;flex-direction:column;overflow:hidden;justify-content:space-between}.popup-container::-webkit-scrollbar{width:0;height:0}.popup-container .search-container{position:relative;box-sizing:border-box;padding:8px}.popup-container .search-container .search-icon{position:absolute;width:24px;height:24px;top:50%;transform:translateY(-50%);left:18px;z-index:1}.popup-container .search-container .search-input{height:40px;width:100%;padding:12px;border:1px solid #e0e0e0;box-sizing:border-box;border-radius:8px;outline:none;caret-color:#0937b2;font-style:normal;font-weight:400;font-size:12px;line-height:18px;display:flex;align-items:center;letter-spacing:.2px;color:#181f33}.popup-container .search-container .cancel-icon{position:absolute;cursor:pointer;width:24px;height:24px;top:50%;transform:translateY(-50%);right:18px;z-index:1}.popup-container .items{padding:0 0 8px 8px;overflow-y:auto}.popup-container .items::-webkit-scrollbar{width:5px;height:0}.popup-container .items::-webkit-scrollbar-thumb{background:#9aa7b4;border-radius:10px}.popup-container .items .noData{display:flex;justify-content:center;align-items:center;height:44px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.popup-container .items .dropdown-viewport{height:100%}.popup-container .items .dropdown-viewport .item{cursor:pointer;display:flex;justify-content:flex-start;align-items:center;gap:10px;padding:4px 12px;border-radius:6px;min-height:40px;height:auto;letter-spacing:.2px;color:#181f33}.popup-container .items .dropdown-viewport .item:hover,.popup-container .items .dropdown-viewport .item:focus-visible{background-color:#f5f7fc;outline:none}.popup-container .items .dropdown-viewport .item .label{width:100%;line-height:20px;font-size:14px;font-style:normal;font-weight:400}.popup-container .items .dropdown-viewport .item .label .primaryText{color:#181f33;font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container .items .dropdown-viewport .item .label .secondaryText{color:#6a737d;font-family:Lato;font-size:14px;line-height:20px;letter-spacing:.2px;white-space:normal;word-wrap:break-word}.popup-container .items .dropdown-viewport .item .icon-container{width:10%;display:flex;justify-content:flex-end}.popup-container .items .dropdown-viewport .item .icon-container .icon{width:20px;height:20px}.popup-container .items .item-disabled{cursor:not-allowed!important}.popup-container .items .item-disabled:hover,.popup-container .items .item-disabled:focus-visible{background-color:transparent!important;outline:none!important}.popup-container .items .item-disabled .label>span{color:#929dab!important;-webkit-user-select:none!important;user-select:none!important}.popup-container .items .item-selected{background-color:#e0e6f6;outline:none}.popup-container .items .icon-only{justify-content:center!important}::-webkit-scrollbar{height:8px;width:8px;background:#fff;border-radius:13px}::-webkit-scrollbar-thumb{background:#c8cdd3;border-radius:13px;cursor:pointer}.status-container{display:flex;justify-content:center;align-items:center;height:128px}.status-container p{text-align:center}\n"] }]
|
|
482
|
+
}], () => [{ type: i0.ElementRef }, { type: i1.Overlay }, { type: i0.ViewContainerRef }, { type: i0.ChangeDetectorRef }], { selectElement: [{
|
|
507
483
|
type: ViewChild,
|
|
508
484
|
args: ["select", { static: false }]
|
|
509
485
|
}], popupContainer: [{
|
|
510
486
|
type: ViewChild,
|
|
511
487
|
args: ["popupContainer", { static: false }]
|
|
512
|
-
}], itemsContainer: [{
|
|
513
|
-
type: ViewChild,
|
|
514
|
-
args: ["itemsContainer", { static: false }]
|
|
515
488
|
}], viewPort: [{
|
|
516
489
|
type: ViewChild,
|
|
517
490
|
args: [CdkVirtualScrollViewport]
|
|
518
491
|
}], customItem: [{
|
|
519
492
|
type: ContentChild,
|
|
520
493
|
args: ["misCustomItem", { static: false }]
|
|
494
|
+
}], itemsContainer: [{
|
|
495
|
+
type: ViewChild,
|
|
496
|
+
args: ["itemsContainer", { static: false }]
|
|
521
497
|
}], closeOnEsc: [{
|
|
522
498
|
type: HostListener,
|
|
523
|
-
args: ["keyup.esc", [
|
|
499
|
+
args: ["keyup.esc", ["$event"]]
|
|
524
500
|
}] }); })();
|
|
525
501
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(DropdownComponent, { className: "DropdownComponent" }); })();
|
|
526
502
|
|
|
527
503
|
class CalculateContainerHeightDirective {
|
|
528
|
-
constructor(
|
|
529
|
-
this.
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
504
|
+
constructor() {
|
|
505
|
+
this.items = input([]);
|
|
506
|
+
this.visibleItems = input(10);
|
|
507
|
+
this.el = inject(ElementRef);
|
|
508
|
+
this.itemHeight = computed(() => {
|
|
509
|
+
const firstItemElement = this.el.nativeElement.querySelector('.item');
|
|
510
|
+
return firstItemElement ? firstItemElement.getBoundingClientRect().height : 0;
|
|
511
|
+
});
|
|
512
|
+
this.heightEffect = effect(() => {
|
|
533
513
|
this.setContainerHeight();
|
|
534
|
-
}
|
|
514
|
+
});
|
|
535
515
|
}
|
|
536
516
|
setContainerHeight() {
|
|
537
|
-
const
|
|
538
|
-
const
|
|
539
|
-
|
|
517
|
+
const firstItemHeight = this.itemHeight();
|
|
518
|
+
const numberOfItems = this.items()?.length || 0;
|
|
519
|
+
if (firstItemHeight === 0) {
|
|
520
|
+
return;
|
|
521
|
+
}
|
|
540
522
|
let containerHeight = 0;
|
|
541
|
-
|
|
542
|
-
|
|
523
|
+
const maxScrollHeight = 200;
|
|
524
|
+
if (firstItemHeight * numberOfItems > maxScrollHeight) {
|
|
525
|
+
containerHeight = maxScrollHeight;
|
|
543
526
|
}
|
|
544
|
-
else if (numberOfItems <= this.visibleItems) {
|
|
527
|
+
else if (numberOfItems <= this.visibleItems()) {
|
|
545
528
|
containerHeight = firstItemHeight * numberOfItems;
|
|
546
529
|
}
|
|
547
530
|
else {
|
|
548
|
-
containerHeight = firstItemHeight * this.visibleItems;
|
|
531
|
+
containerHeight = firstItemHeight * this.visibleItems();
|
|
549
532
|
}
|
|
550
533
|
this.el.nativeElement.style.height = `${containerHeight}px`;
|
|
551
534
|
}
|
|
552
|
-
static { this.ɵfac = function CalculateContainerHeightDirective_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CalculateContainerHeightDirective)(
|
|
553
|
-
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: CalculateContainerHeightDirective, selectors: [["", "calculateContainerHeight", ""]], inputs: { items: "items", visibleItems: "visibleItems" } }); }
|
|
535
|
+
static { this.ɵfac = function CalculateContainerHeightDirective_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CalculateContainerHeightDirective)(); }; }
|
|
536
|
+
static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: CalculateContainerHeightDirective, selectors: [["", "calculateContainerHeight", ""]], inputs: { items: [1, "items"], visibleItems: [1, "visibleItems"] } }); }
|
|
554
537
|
}
|
|
555
538
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CalculateContainerHeightDirective, [{
|
|
556
539
|
type: Directive,
|
|
557
540
|
args: [{
|
|
558
541
|
selector: '[calculateContainerHeight]'
|
|
559
542
|
}]
|
|
560
|
-
}],
|
|
561
|
-
type: Input
|
|
562
|
-
}], visibleItems: [{
|
|
563
|
-
type: Input
|
|
564
|
-
}] }); })();
|
|
543
|
+
}], null, null); })();
|
|
565
544
|
|
|
566
545
|
class DropdownModule {
|
|
567
546
|
static forRoot() {
|