mis-crystal-design-system 14.0.46 → 14.0.49
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/async-search-dropdown/async-dropdown.component.d.ts +3 -0
- package/async-search-dropdown/async-dropdown.module.d.ts +2 -1
- package/datepicker_v2/datepicker.module.d.ts +2 -1
- package/datepicker_v2/tz-datepicker.directive.d.ts +2 -0
- package/datepicker_v2/tz-dp-container/tz-dp-container.component.d.ts +2 -0
- package/daterangepicker_v2/daterangepicker.module.d.ts +2 -1
- package/daterangepicker_v2/tz-daterangepicker.directive.d.ts +2 -0
- package/daterangepicker_v2/tz-drp-container/tz-drp-container.component.d.ts +2 -0
- package/dropdown/dropdown.component.d.ts +1 -0
- package/dropdown/dropdown.module.d.ts +2 -1
- package/dynamic-form/dynamic-form.component.d.ts +1 -1
- package/esm2020/async-search-dropdown/async-dropdown.component.mjs +75 -47
- package/esm2020/async-search-dropdown/async-dropdown.module.mjs +5 -4
- package/esm2020/checkbox/checkbox.component.mjs +4 -4
- package/esm2020/chip/chip.component.mjs +14 -14
- package/esm2020/datepicker_v2/datepicker.module.mjs +5 -4
- package/esm2020/datepicker_v2/tz-datepicker.directive.mjs +21 -2
- package/esm2020/datepicker_v2/tz-dp-container/tz-dp-container.component.mjs +55 -40
- package/esm2020/daterangepicker_v2/daterangepicker.module.mjs +5 -4
- package/esm2020/daterangepicker_v2/tz-daterangepicker.directive.mjs +21 -2
- package/esm2020/daterangepicker_v2/tz-drp-container/tz-drp-container.component.mjs +90 -68
- package/esm2020/dropdown/dropdown.component.mjs +52 -38
- package/esm2020/dropdown/dropdown.module.mjs +5 -4
- package/esm2020/dynamic-form/dynamic-form.component.mjs +164 -155
- package/esm2020/mobile-filter/mobile-filter.component.mjs +18 -16
- package/esm2020/radio-button/radio-button.component.mjs +4 -4
- package/esm2020/table/table.component.mjs +2 -2
- package/fesm2015/mis-crystal-design-system-async-search-dropdown.mjs +80 -49
- package/fesm2015/mis-crystal-design-system-async-search-dropdown.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-checkbox.mjs +3 -3
- package/fesm2015/mis-crystal-design-system-checkbox.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-chip.mjs +13 -13
- package/fesm2015/mis-crystal-design-system-chip.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-datepicker_v2.mjs +80 -43
- package/fesm2015/mis-crystal-design-system-datepicker_v2.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-daterangepicker_v2.mjs +115 -71
- package/fesm2015/mis-crystal-design-system-daterangepicker_v2.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-dropdown.mjs +57 -40
- package/fesm2015/mis-crystal-design-system-dropdown.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-dynamic-form.mjs +163 -154
- package/fesm2015/mis-crystal-design-system-dynamic-form.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-mobile-filter.mjs +17 -15
- package/fesm2015/mis-crystal-design-system-mobile-filter.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-radio-button.mjs +3 -3
- package/fesm2015/mis-crystal-design-system-radio-button.mjs.map +1 -1
- package/fesm2015/mis-crystal-design-system-table.mjs +2 -2
- package/fesm2015/mis-crystal-design-system-table.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-async-search-dropdown.mjs +78 -49
- package/fesm2020/mis-crystal-design-system-async-search-dropdown.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-checkbox.mjs +3 -3
- package/fesm2020/mis-crystal-design-system-checkbox.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-chip.mjs +13 -13
- package/fesm2020/mis-crystal-design-system-chip.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-datepicker_v2.mjs +78 -43
- package/fesm2020/mis-crystal-design-system-datepicker_v2.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-daterangepicker_v2.mjs +113 -71
- package/fesm2020/mis-crystal-design-system-daterangepicker_v2.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-dropdown.mjs +55 -40
- package/fesm2020/mis-crystal-design-system-dropdown.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-dynamic-form.mjs +163 -154
- package/fesm2020/mis-crystal-design-system-dynamic-form.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-mobile-filter.mjs +17 -15
- package/fesm2020/mis-crystal-design-system-mobile-filter.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-radio-button.mjs +3 -3
- package/fesm2020/mis-crystal-design-system-radio-button.mjs.map +1 -1
- package/fesm2020/mis-crystal-design-system-table.mjs +2 -2
- package/fesm2020/mis-crystal-design-system-table.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -4,15 +4,15 @@ import * as i1 from '@angular/common';
|
|
|
4
4
|
import { CommonModule } from '@angular/common';
|
|
5
5
|
|
|
6
6
|
function ChipComponent_img_1_Template(rf, ctx) { if (rf & 1) {
|
|
7
|
-
i0.ɵɵelement(0, "img",
|
|
7
|
+
i0.ɵɵelement(0, "img", 5);
|
|
8
8
|
} if (rf & 2) {
|
|
9
9
|
const ctx_r0 = i0.ɵɵnextContext();
|
|
10
10
|
i0.ɵɵproperty("src", ctx_r0.iconUrl, i0.ɵɵsanitizeUrl);
|
|
11
11
|
} }
|
|
12
12
|
function ChipComponent_div_4_Template(rf, ctx) { if (rf & 1) {
|
|
13
|
-
i0.ɵɵelementStart(0, "div",
|
|
14
|
-
i0.ɵɵelement(1, "div",
|
|
15
|
-
i0.ɵɵelementStart(2, "span",
|
|
13
|
+
i0.ɵɵelementStart(0, "div", 6);
|
|
14
|
+
i0.ɵɵelement(1, "div", 7);
|
|
15
|
+
i0.ɵɵelementStart(2, "span", 8);
|
|
16
16
|
i0.ɵɵtext(3);
|
|
17
17
|
i0.ɵɵelementEnd()();
|
|
18
18
|
} if (rf & 2) {
|
|
@@ -22,11 +22,11 @@ function ChipComponent_div_4_Template(rf, ctx) { if (rf & 1) {
|
|
|
22
22
|
} }
|
|
23
23
|
function ChipComponent_span_5_Template(rf, ctx) { if (rf & 1) {
|
|
24
24
|
const _r4 = i0.ɵɵgetCurrentView();
|
|
25
|
-
i0.ɵɵelementStart(0, "span",
|
|
26
|
-
i0.ɵɵlistener("
|
|
25
|
+
i0.ɵɵelementStart(0, "span", 9);
|
|
26
|
+
i0.ɵɵlistener("keyup.enter", function ChipComponent_span_5_Template_span_keyup_enter_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r3 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r3.cancel.emit(ctx_r3.value)); })("click", function ChipComponent_span_5_Template_span_click_0_listener() { i0.ɵɵrestoreView(_r4); const ctx_r5 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r5.cancel.emit(ctx_r5.value)); });
|
|
27
27
|
i0.ɵɵnamespaceSVG();
|
|
28
|
-
i0.ɵɵelementStart(1, "svg",
|
|
29
|
-
i0.ɵɵelement(2, "path",
|
|
28
|
+
i0.ɵɵelementStart(1, "svg", 10);
|
|
29
|
+
i0.ɵɵelement(2, "path", 11);
|
|
30
30
|
i0.ɵɵelementEnd()();
|
|
31
31
|
} }
|
|
32
32
|
const _c0 = function (a0, a1, a2, a3) { return { small: a0, medium: a1, "small-m": a2, "medium-m": a3 }; };
|
|
@@ -43,14 +43,14 @@ class ChipComponent {
|
|
|
43
43
|
ngOnInit() { }
|
|
44
44
|
}
|
|
45
45
|
ChipComponent.ɵfac = function ChipComponent_Factory(t) { return new (t || ChipComponent)(); };
|
|
46
|
-
ChipComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ChipComponent, selectors: [["mis-chip"]], inputs: { label: "label", value: "value", size: "size", iconUrl: "iconUrl", count: "count", dismissible: "dismissible" }, outputs: { cancel: "cancel" }, decls: 6, vars: 10, consts: [["id", "chip-container", 3, "ngClass"], ["alt", "", 3, "src", 4, "ngIf"], ["id", "count-container", 4, "ngIf"], ["id", "close-icon", 3, "click", 4, "ngIf"], ["alt", "", 3, "src"], ["id", "count-container"], ["id", "separator"], ["id", "count-text"], ["id", "close-icon", 3, "click"], ["width", "16", "height", "16", "viewBox", "0 0 16 16", "fill", "none", "xmlns", "http://www.w3.org/2000/svg"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M5.49931 4.25725C5.15643 3.91437 4.60052 3.91437 4.25765 4.25725C3.91477 4.60012 3.91477 5.15604 4.25765 5.49891L6.75868 7.99994L4.25827 10.5004C3.91539 10.8432 3.91539 11.3991 4.25827 11.742C4.60114 12.0849 5.15706 12.0849 5.49993 11.742L8.00034 9.24161L10.5007 11.742C10.8436 12.0849 11.3995 12.0849 11.7424 11.742C12.0853 11.3991 12.0853 10.8432 11.7424 10.5003L9.24201 7.99995L11.743 5.49893C12.0859 5.15606 12.0859 4.60014 11.743 4.25727C11.4001 3.91439 10.8442 3.91439 10.5014 4.25727L8.00034 6.75828L5.49931 4.25725Z", "fill", "#181F33"]], template: function ChipComponent_Template(rf, ctx) { if (rf & 1) {
|
|
46
|
+
ChipComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ChipComponent, selectors: [["mis-chip"]], inputs: { label: "label", value: "value", size: "size", iconUrl: "iconUrl", count: "count", dismissible: "dismissible" }, outputs: { cancel: "cancel" }, decls: 6, vars: 10, consts: [["id", "chip-container", "tabindex", "0", 3, "ngClass"], ["alt", "chip icon", 3, "src", 4, "ngIf"], ["tabindex", "0"], ["id", "count-container", 4, "ngIf"], ["tabindex", "0", "id", "close-icon", "aria-label", "remove chip", 3, "keyup.enter", "click", 4, "ngIf"], ["alt", "chip icon", 3, "src"], ["id", "count-container"], ["id", "separator"], ["id", "count-text"], ["tabindex", "0", "id", "close-icon", "aria-label", "remove chip", 3, "keyup.enter", "click"], ["width", "16", "height", "16", "viewBox", "0 0 16 16", "fill", "none", "xmlns", "http://www.w3.org/2000/svg"], ["fill-rule", "evenodd", "clip-rule", "evenodd", "d", "M5.49931 4.25725C5.15643 3.91437 4.60052 3.91437 4.25765 4.25725C3.91477 4.60012 3.91477 5.15604 4.25765 5.49891L6.75868 7.99994L4.25827 10.5004C3.91539 10.8432 3.91539 11.3991 4.25827 11.742C4.60114 12.0849 5.15706 12.0849 5.49993 11.742L8.00034 9.24161L10.5007 11.742C10.8436 12.0849 11.3995 12.0849 11.7424 11.742C12.0853 11.3991 12.0853 10.8432 11.7424 10.5003L9.24201 7.99995L11.743 5.49893C12.0859 5.15606 12.0859 4.60014 11.743 4.25727C11.4001 3.91439 10.8442 3.91439 10.5014 4.25727L8.00034 6.75828L5.49931 4.25725Z", "fill", "#181F33"]], template: function ChipComponent_Template(rf, ctx) { if (rf & 1) {
|
|
47
47
|
i0.ɵɵelementStart(0, "div", 0);
|
|
48
48
|
i0.ɵɵtemplate(1, ChipComponent_img_1_Template, 1, 1, "img", 1);
|
|
49
|
-
i0.ɵɵelementStart(2, "span");
|
|
49
|
+
i0.ɵɵelementStart(2, "span", 2);
|
|
50
50
|
i0.ɵɵtext(3);
|
|
51
51
|
i0.ɵɵelementEnd();
|
|
52
|
-
i0.ɵɵtemplate(4, ChipComponent_div_4_Template, 4, 1, "div",
|
|
53
|
-
i0.ɵɵtemplate(5, ChipComponent_span_5_Template, 3, 0, "span",
|
|
52
|
+
i0.ɵɵtemplate(4, ChipComponent_div_4_Template, 4, 1, "div", 3);
|
|
53
|
+
i0.ɵɵtemplate(5, ChipComponent_span_5_Template, 3, 0, "span", 4);
|
|
54
54
|
i0.ɵɵelementEnd();
|
|
55
55
|
} if (rf & 2) {
|
|
56
56
|
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction4(5, _c0, ctx.size === "Small", ctx.size === "Medium", ctx.size === "Small-M", ctx.size === "Medium-M"));
|
|
@@ -65,7 +65,7 @@ ChipComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: ChipComponent
|
|
|
65
65
|
} }, dependencies: [i1.NgClass, i1.NgIf], styles: ["#chip-container[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;font-family:Lato,sans-serif!important;background-color:#e0e0e0;box-sizing:border-box;cursor:default}#chip-container[_ngcontent-%COMP%]:hover{background:#d7d9de}img[_ngcontent-%COMP%]{margin-right:4px}#close-icon[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center;margin-left:4px;cursor:pointer}#count-container[_ngcontent-%COMP%]{display:flex;height:100%;justify-content:center;align-items:center}#separator[_ngcontent-%COMP%]{height:100%;width:1px;background-color:#c8cdd3;margin:0 8px}#count-text[_ngcontent-%COMP%]{font-weight:700;letter-spacing:.25px}.small[_ngcontent-%COMP%]{height:24px;padding:4px 8px;border-radius:7px;font-style:normal;font-weight:700;font-size:12px;line-height:16px;letter-spacing:.7px;color:#181f33}.medium[_ngcontent-%COMP%]{height:32px;padding:6px 12px;border-radius:16px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.small-m[_ngcontent-%COMP%]{height:20px;padding:4px 8px;border-radius:10px;font-style:normal;font-weight:400;font-size:11px;line-height:12px;letter-spacing:.1px;color:#181f33}.medium-m[_ngcontent-%COMP%]{height:24px;padding:4px 12px;border-radius:12px;font-style:normal;font-weight:400;font-size:12px;line-height:16px;letter-spacing:.25px;color:#181f33}"] });
|
|
66
66
|
(function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ChipComponent, [{
|
|
67
67
|
type: Component,
|
|
68
|
-
args: [{ selector: "mis-chip", template: "<div\n id=\"chip-container\"\n [ngClass]=\"{\n small: size === 'Small',\n medium: size === 'Medium',\n 'small-m': size === 'Small-M',\n 'medium-m': size === 'Medium-M'\n }\"\n>\n <img *ngIf=\"iconUrl && iconUrl.length > 0\" [src]=\"iconUrl\" alt=\"\" />\n <span>{{ label }}</span>\n <div *ngIf=\"count != null || count != undefined\" id=\"count-container\">\n <div id=\"separator\"></div>\n <span id=\"count-text\">{{ count }}</span>\n </div>\n <span *ngIf=\"dismissible\" id=\"close-icon\" (click)=\"cancel.emit(value)\">\n <svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M5.49931 4.25725C5.15643 3.91437 4.60052 3.91437 4.25765 4.25725C3.91477 4.60012 3.91477 5.15604 4.25765 5.49891L6.75868 7.99994L4.25827 10.5004C3.91539 10.8432 3.91539 11.3991 4.25827 11.742C4.60114 12.0849 5.15706 12.0849 5.49993 11.742L8.00034 9.24161L10.5007 11.742C10.8436 12.0849 11.3995 12.0849 11.7424 11.742C12.0853 11.3991 12.0853 10.8432 11.7424 10.5003L9.24201 7.99995L11.743 5.49893C12.0859 5.15606 12.0859 4.60014 11.743 4.25727C11.4001 3.91439 10.8442 3.91439 10.5014 4.25727L8.00034 6.75828L5.49931 4.25725Z\"\n fill=\"#181F33\"\n />\n </svg>\n </span>\n</div>\n", styles: ["#chip-container{display:flex;justify-content:center;align-items:center;font-family:Lato,sans-serif!important;background-color:#e0e0e0;box-sizing:border-box;cursor:default}#chip-container:hover{background:#d7d9de}img{margin-right:4px}#close-icon{display:flex;justify-content:center;align-items:center;margin-left:4px;cursor:pointer}#count-container{display:flex;height:100%;justify-content:center;align-items:center}#separator{height:100%;width:1px;background-color:#c8cdd3;margin:0 8px}#count-text{font-weight:700;letter-spacing:.25px}.small{height:24px;padding:4px 8px;border-radius:7px;font-style:normal;font-weight:700;font-size:12px;line-height:16px;letter-spacing:.7px;color:#181f33}.medium{height:32px;padding:6px 12px;border-radius:16px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.small-m{height:20px;padding:4px 8px;border-radius:10px;font-style:normal;font-weight:400;font-size:11px;line-height:12px;letter-spacing:.1px;color:#181f33}.medium-m{height:24px;padding:4px 12px;border-radius:12px;font-style:normal;font-weight:400;font-size:12px;line-height:16px;letter-spacing:.25px;color:#181f33}\n"] }]
|
|
68
|
+
args: [{ selector: "mis-chip", template: "<div\n id=\"chip-container\"\n tabindex=\"0\"\n [ngClass]=\"{\n small: size === 'Small',\n medium: size === 'Medium',\n 'small-m': size === 'Small-M',\n 'medium-m': size === 'Medium-M'\n }\"\n>\n <img *ngIf=\"iconUrl && iconUrl.length > 0\" [src]=\"iconUrl\" alt=\"chip icon\" />\n <span tabindex=\"0\">{{ label }}</span>\n <div *ngIf=\"count != null || count != undefined\" id=\"count-container\">\n <div id=\"separator\"></div>\n <span id=\"count-text\">{{ count }}</span>\n </div>\n <span *ngIf=\"dismissible\" tabindex=\"0\" id=\"close-icon\" aria-label=\"remove chip\" (keyup.enter)=\"cancel.emit(value)\" (click)=\"cancel.emit(value)\">\n <svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M5.49931 4.25725C5.15643 3.91437 4.60052 3.91437 4.25765 4.25725C3.91477 4.60012 3.91477 5.15604 4.25765 5.49891L6.75868 7.99994L4.25827 10.5004C3.91539 10.8432 3.91539 11.3991 4.25827 11.742C4.60114 12.0849 5.15706 12.0849 5.49993 11.742L8.00034 9.24161L10.5007 11.742C10.8436 12.0849 11.3995 12.0849 11.7424 11.742C12.0853 11.3991 12.0853 10.8432 11.7424 10.5003L9.24201 7.99995L11.743 5.49893C12.0859 5.15606 12.0859 4.60014 11.743 4.25727C11.4001 3.91439 10.8442 3.91439 10.5014 4.25727L8.00034 6.75828L5.49931 4.25725Z\"\n fill=\"#181F33\"\n />\n </svg>\n </span>\n</div>\n", styles: ["#chip-container{display:flex;justify-content:center;align-items:center;font-family:Lato,sans-serif!important;background-color:#e0e0e0;box-sizing:border-box;cursor:default}#chip-container:hover{background:#d7d9de}img{margin-right:4px}#close-icon{display:flex;justify-content:center;align-items:center;margin-left:4px;cursor:pointer}#count-container{display:flex;height:100%;justify-content:center;align-items:center}#separator{height:100%;width:1px;background-color:#c8cdd3;margin:0 8px}#count-text{font-weight:700;letter-spacing:.25px}.small{height:24px;padding:4px 8px;border-radius:7px;font-style:normal;font-weight:700;font-size:12px;line-height:16px;letter-spacing:.7px;color:#181f33}.medium{height:32px;padding:6px 12px;border-radius:16px;font-style:normal;font-weight:400;font-size:14px;line-height:20px;letter-spacing:.2px;color:#181f33}.small-m{height:20px;padding:4px 8px;border-radius:10px;font-style:normal;font-weight:400;font-size:11px;line-height:12px;letter-spacing:.1px;color:#181f33}.medium-m{height:24px;padding:4px 12px;border-radius:12px;font-style:normal;font-weight:400;font-size:12px;line-height:16px;letter-spacing:.25px;color:#181f33}\n"] }]
|
|
69
69
|
}], function () { return []; }, { label: [{
|
|
70
70
|
type: Input
|
|
71
71
|
}], value: [{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mis-crystal-design-system-chip.mjs","sources":["../../../projects/mis-components/chip/chip.component.html","../../../projects/mis-components/chip/chip.component.ts","../../../projects/mis-components/chip/chip.module.ts","../../../projects/mis-components/chip/mis-crystal-design-system-chip.ts"],"sourcesContent":["<div\n id=\"chip-container\"\n [ngClass]=\"{\n small: size === 'Small',\n medium: size === 'Medium',\n 'small-m': size === 'Small-M',\n 'medium-m': size === 'Medium-M'\n }\"\n>\n <img *ngIf=\"iconUrl && iconUrl.length > 0\" [src]=\"iconUrl\" alt=\"\" />\n <span>{{ label }}</span>\n <div *ngIf=\"count != null || count != undefined\" id=\"count-container\">\n <div id=\"separator\"></div>\n <span id=\"count-text\">{{ count }}</span>\n </div>\n <span *ngIf=\"dismissible\" id=\"close-icon\" (click)=\"cancel.emit(value)\">\n <svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M5.49931 4.25725C5.15643 3.91437 4.60052 3.91437 4.25765 4.25725C3.91477 4.60012 3.91477 5.15604 4.25765 5.49891L6.75868 7.99994L4.25827 10.5004C3.91539 10.8432 3.91539 11.3991 4.25827 11.742C4.60114 12.0849 5.15706 12.0849 5.49993 11.742L8.00034 9.24161L10.5007 11.742C10.8436 12.0849 11.3995 12.0849 11.7424 11.742C12.0853 11.3991 12.0853 10.8432 11.7424 10.5003L9.24201 7.99995L11.743 5.49893C12.0859 5.15606 12.0859 4.60014 11.743 4.25727C11.4001 3.91439 10.8442 3.91439 10.5014 4.25727L8.00034 6.75828L5.49931 4.25725Z\"\n fill=\"#181F33\"\n />\n </svg>\n </span>\n</div>\n","import { Component, Input, OnInit, Output, EventEmitter } from \"@angular/core\";\n\n@Component({\n selector: \"mis-chip\",\n templateUrl: \"chip.component.html\",\n styleUrls: [\"chip.component.scss\"]\n})\nexport class ChipComponent implements OnInit {\n @Input() label: string = \"\";\n @Input() value: any = \"\";\n @Input() size: \"Small\" | \"Medium\" | \"Small-M\" | \"Medium-M\" = \"Medium\";\n @Input() iconUrl: string | null = null;\n @Input() count: number | null | undefined = null;\n @Input() dismissible: boolean = false;\n\n @Output() cancel = new EventEmitter<any>();\n constructor() {}\n ngOnInit() {}\n}\n","import { NgModule, ModuleWithProviders } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\nimport { ChipComponent } from \"./chip.component\";\n\n@NgModule({\n declarations: [ChipComponent],\n imports: [CommonModule],\n exports: [ChipComponent]\n})\nexport class ChipModule {\n static forRoot(): ModuleWithProviders<ChipModule> {\n return { ngModule: ChipModule, providers: [] };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"mis-crystal-design-system-chip.mjs","sources":["../../../projects/mis-components/chip/chip.component.html","../../../projects/mis-components/chip/chip.component.ts","../../../projects/mis-components/chip/chip.module.ts","../../../projects/mis-components/chip/mis-crystal-design-system-chip.ts"],"sourcesContent":["<div\n id=\"chip-container\"\n tabindex=\"0\"\n [ngClass]=\"{\n small: size === 'Small',\n medium: size === 'Medium',\n 'small-m': size === 'Small-M',\n 'medium-m': size === 'Medium-M'\n }\"\n>\n <img *ngIf=\"iconUrl && iconUrl.length > 0\" [src]=\"iconUrl\" alt=\"chip icon\" />\n <span tabindex=\"0\">{{ label }}</span>\n <div *ngIf=\"count != null || count != undefined\" id=\"count-container\">\n <div id=\"separator\"></div>\n <span id=\"count-text\">{{ count }}</span>\n </div>\n <span *ngIf=\"dismissible\" tabindex=\"0\" id=\"close-icon\" aria-label=\"remove chip\" (keyup.enter)=\"cancel.emit(value)\" (click)=\"cancel.emit(value)\">\n <svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M5.49931 4.25725C5.15643 3.91437 4.60052 3.91437 4.25765 4.25725C3.91477 4.60012 3.91477 5.15604 4.25765 5.49891L6.75868 7.99994L4.25827 10.5004C3.91539 10.8432 3.91539 11.3991 4.25827 11.742C4.60114 12.0849 5.15706 12.0849 5.49993 11.742L8.00034 9.24161L10.5007 11.742C10.8436 12.0849 11.3995 12.0849 11.7424 11.742C12.0853 11.3991 12.0853 10.8432 11.7424 10.5003L9.24201 7.99995L11.743 5.49893C12.0859 5.15606 12.0859 4.60014 11.743 4.25727C11.4001 3.91439 10.8442 3.91439 10.5014 4.25727L8.00034 6.75828L5.49931 4.25725Z\"\n fill=\"#181F33\"\n />\n </svg>\n </span>\n</div>\n","import { Component, Input, OnInit, Output, EventEmitter } from \"@angular/core\";\n\n@Component({\n selector: \"mis-chip\",\n templateUrl: \"chip.component.html\",\n styleUrls: [\"chip.component.scss\"]\n})\nexport class ChipComponent implements OnInit {\n @Input() label: string = \"\";\n @Input() value: any = \"\";\n @Input() size: \"Small\" | \"Medium\" | \"Small-M\" | \"Medium-M\" = \"Medium\";\n @Input() iconUrl: string | null = null;\n @Input() count: number | null | undefined = null;\n @Input() dismissible: boolean = false;\n\n @Output() cancel = new EventEmitter<any>();\n constructor() {}\n ngOnInit() {}\n}\n","import { NgModule, ModuleWithProviders } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\nimport { ChipComponent } from \"./chip.component\";\n\n@NgModule({\n declarations: [ChipComponent],\n imports: [CommonModule],\n exports: [ChipComponent]\n})\nexport class ChipModule {\n static forRoot(): ModuleWithProviders<ChipModule> {\n return { ngModule: ChipModule, providers: [] };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"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"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { InjectionToken, Component, Inject, EventEmitter, Injector, Directive, Self, Optional, Input, Output,
|
|
2
|
+
import { InjectionToken, Component, Inject, HostListener, EventEmitter, Injector, Directive, Self, Optional, Input, Output, NgModule } from '@angular/core';
|
|
3
3
|
import { parseZone, tz } from 'moment-timezone';
|
|
4
4
|
import * as i1 from 'mis-crystal-design-system/toast';
|
|
5
5
|
import { ToastModule } from 'mis-crystal-design-system/toast';
|
|
@@ -7,6 +7,8 @@ import * as i2 from '@angular/common';
|
|
|
7
7
|
import { CommonModule } from '@angular/common';
|
|
8
8
|
import * as i3 from 'mis-crystal-design-system/button';
|
|
9
9
|
import { ButtonModule } from 'mis-crystal-design-system/button';
|
|
10
|
+
import * as i4 from '@angular/cdk/a11y';
|
|
11
|
+
import { A11yModule } from '@angular/cdk/a11y';
|
|
10
12
|
import * as i2$1 from '@angular/cdk/overlay';
|
|
11
13
|
import { OverlayConfig, OverlayModule } from '@angular/cdk/overlay';
|
|
12
14
|
import { ComponentPortal } from '@angular/cdk/portal';
|
|
@@ -64,8 +66,8 @@ const getMonth = (index) => {
|
|
|
64
66
|
};
|
|
65
67
|
|
|
66
68
|
const _c0 = function (a0) { return { "current-day": a0 }; };
|
|
67
|
-
function
|
|
68
|
-
i0.ɵɵelementStart(0, "div",
|
|
69
|
+
function TzDpContainerComponent_div_13_Template(rf, ctx) { if (rf & 1) {
|
|
70
|
+
i0.ɵɵelementStart(0, "div", 13)(1, "span", 14);
|
|
69
71
|
i0.ɵɵtext(2);
|
|
70
72
|
i0.ɵɵelementEnd()();
|
|
71
73
|
} if (rf & 2) {
|
|
@@ -76,23 +78,24 @@ function TzDpContainerComponent_div_12_Template(rf, ctx) { if (rf & 1) {
|
|
|
76
78
|
i0.ɵɵtextInterpolate(weekDay_r3.label);
|
|
77
79
|
} }
|
|
78
80
|
const _c1 = function (a0, a1, a2) { return { "current-day": a0, "selected-day": a1, "disabled-day": a2 }; };
|
|
79
|
-
function
|
|
80
|
-
i0.ɵɵelementStart(0, "span",
|
|
81
|
+
function TzDpContainerComponent_div_15_span_1_Template(rf, ctx) { if (rf & 1) {
|
|
82
|
+
i0.ɵɵelementStart(0, "span", 17);
|
|
81
83
|
i0.ɵɵtext(1);
|
|
82
84
|
i0.ɵɵelementEnd();
|
|
83
85
|
} if (rf & 2) {
|
|
84
86
|
const day_r4 = i0.ɵɵnextContext().$implicit;
|
|
85
87
|
const ctx_r5 = i0.ɵɵnextContext();
|
|
86
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction3(
|
|
88
|
+
i0.ɵɵproperty("tabindex", day_r4.isDisabledDay ? -1 : 0)("ngClass", i0.ɵɵpureFunction3(4, _c1, day_r4.isCurrentDay, !ctx_r5.localSelectedDate ? day_r4.isSelectedDay : day_r4 === ctx_r5.localSelectedDate, day_r4.isDisabledDay));
|
|
89
|
+
i0.ɵɵattribute("aria-label", ctx_r5.retractDayMonth(day_r4.date, ctx_r5.currentMonth, ctx_r5.currentYearNumber));
|
|
87
90
|
i0.ɵɵadvance(1);
|
|
88
91
|
i0.ɵɵtextInterpolate1(" ", day_r4.date, " ");
|
|
89
92
|
} }
|
|
90
93
|
const _c2 = function (a0, a1, a2) { return { "selected-day": a0, "disabled-day": a1, "is-valid-date": a2 }; };
|
|
91
|
-
function
|
|
94
|
+
function TzDpContainerComponent_div_15_Template(rf, ctx) { if (rf & 1) {
|
|
92
95
|
const _r8 = i0.ɵɵgetCurrentView();
|
|
93
|
-
i0.ɵɵelementStart(0, "div",
|
|
94
|
-
i0.ɵɵlistener("click", function
|
|
95
|
-
i0.ɵɵtemplate(1,
|
|
96
|
+
i0.ɵɵelementStart(0, "div", 15);
|
|
97
|
+
i0.ɵɵlistener("click", function TzDpContainerComponent_div_15_Template_div_click_0_listener() { const restoredCtx = i0.ɵɵrestoreView(_r8); const day_r4 = restoredCtx.$implicit; const ctx_r7 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r7.selectDay(day_r4)); })("keyup.enter", function TzDpContainerComponent_div_15_Template_div_keyup_enter_0_listener() { const restoredCtx = i0.ɵɵrestoreView(_r8); const day_r4 = restoredCtx.$implicit; const ctx_r9 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r9.selectDay(day_r4)); });
|
|
98
|
+
i0.ɵɵtemplate(1, TzDpContainerComponent_div_15_span_1_Template, 2, 8, "span", 16);
|
|
96
99
|
i0.ɵɵelementEnd();
|
|
97
100
|
} if (rf & 2) {
|
|
98
101
|
const day_r4 = ctx.$implicit;
|
|
@@ -101,14 +104,14 @@ function TzDpContainerComponent_div_14_Template(rf, ctx) { if (rf & 1) {
|
|
|
101
104
|
i0.ɵɵadvance(1);
|
|
102
105
|
i0.ɵɵproperty("ngIf", day_r4.date > 0);
|
|
103
106
|
} }
|
|
104
|
-
function
|
|
105
|
-
const
|
|
106
|
-
i0.ɵɵelementStart(0, "div",
|
|
107
|
-
i0.ɵɵlistener("click", function
|
|
107
|
+
function TzDpContainerComponent_div_16_Template(rf, ctx) { if (rf & 1) {
|
|
108
|
+
const _r11 = i0.ɵɵgetCurrentView();
|
|
109
|
+
i0.ɵɵelementStart(0, "div", 18)(1, "button", 19);
|
|
110
|
+
i0.ɵɵlistener("click", function TzDpContainerComponent_div_16_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r11); const ctx_r10 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r10.cancelDatePicker()); });
|
|
108
111
|
i0.ɵɵtext(2, "Cancel");
|
|
109
112
|
i0.ɵɵelementEnd();
|
|
110
|
-
i0.ɵɵelementStart(3, "button",
|
|
111
|
-
i0.ɵɵlistener("click", function
|
|
113
|
+
i0.ɵɵelementStart(3, "button", 20);
|
|
114
|
+
i0.ɵɵlistener("click", function TzDpContainerComponent_div_16_Template_button_click_3_listener() { i0.ɵɵrestoreView(_r11); const ctx_r12 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r12.applyDate()); });
|
|
112
115
|
i0.ɵɵtext(4, "Apply");
|
|
113
116
|
i0.ɵɵelementEnd()();
|
|
114
117
|
} if (rf & 2) {
|
|
@@ -149,6 +152,9 @@ class TzDpContainerComponent {
|
|
|
149
152
|
};
|
|
150
153
|
}
|
|
151
154
|
}
|
|
155
|
+
retractDayMonth(day, month, year) {
|
|
156
|
+
return `${day} ${month} ${year}`;
|
|
157
|
+
}
|
|
152
158
|
ngOnInit() {
|
|
153
159
|
this.currentDateInstance();
|
|
154
160
|
this.calculateMinMaxDays();
|
|
@@ -246,59 +252,69 @@ class TzDpContainerComponent {
|
|
|
246
252
|
this.cancelDatePicker();
|
|
247
253
|
}
|
|
248
254
|
}
|
|
255
|
+
closeOnEsc() {
|
|
256
|
+
this.cancelDatePicker();
|
|
257
|
+
}
|
|
249
258
|
cancelDatePicker() {
|
|
250
259
|
this.data.dateChange("");
|
|
251
260
|
}
|
|
252
261
|
}
|
|
253
262
|
TzDpContainerComponent.ɵfac = function TzDpContainerComponent_Factory(t) { return new (t || TzDpContainerComponent)(i0.ɵɵdirectiveInject(CONTAINER_DATA), i0.ɵɵdirectiveInject(i1.ToastService)); };
|
|
254
|
-
TzDpContainerComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: TzDpContainerComponent, selectors: [["mis-tz-dp"]],
|
|
255
|
-
i0.ɵɵ
|
|
256
|
-
|
|
263
|
+
TzDpContainerComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: TzDpContainerComponent, selectors: [["mis-tz-dp"]], hostBindings: function TzDpContainerComponent_HostBindings(rf, ctx) { if (rf & 1) {
|
|
264
|
+
i0.ɵɵlistener("keydown.esc", function TzDpContainerComponent_keydown_esc_HostBindingHandler() { return ctx.closeOnEsc(); });
|
|
265
|
+
} }, decls: 17, vars: 13, consts: [["aria-label", "date picker", "cdkTrapFocus", "", 1, "datepicker-container", 3, "ngClass", "cdkTrapFocusAutoCapture"], ["tabindex", "-1", "cdkFocusInitial", ""], [1, "datepicker-container__header"], ["tabindex", "0", "aria-label", "Previous Month", 1, "datepicker-container__arrow__icon", 3, "ngClass", "click", "keyup.enter"], ["width", "20", "height", "16", "viewBox", "0 0 20 16", "fill", "none", "xmlns", "http://www.w3.org/2000/svg"], ["d", "M19.7071 8.70711C20.0976 8.31658 20.0976 7.68342 19.7071 7.29289L13.3431 0.928933C12.9526 0.538409 12.3195 0.538409 11.9289 0.928933C11.5384 1.31946 11.5384 1.95262 11.9289 2.34315L17.5858 8L11.9289 13.6569C11.5384 14.0474 11.5384 14.6805 11.9289 15.0711C12.3195 15.4616 12.9526 15.4616 13.3431 15.0711L19.7071 8.70711ZM-8.74228e-08 9L19 9L19 7L8.74228e-08 7L-8.74228e-08 9Z", "fill", "#181F33"], ["tabindex", "0", "aria-label", "Next Month", 1, "datepicker-container__arrow__icon", 3, "ngClass", "click", "keyup.enter"], [1, "datepicker-container__body"], [1, "datepicker-container__weekdays"], ["class", "datepicker-container__weekday", 4, "ngFor", "ngForOf"], [1, "datepicker-container__days"], ["class", "datepicker-container__day", 3, "ngClass", "click", "keyup.enter", 4, "ngFor", "ngForOf"], ["class", "datepicker-container__footer", 4, "ngIf"], [1, "datepicker-container__weekday"], [3, "ngClass"], [1, "datepicker-container__day", 3, "ngClass", "click", "keyup.enter"], [3, "tabindex", "ngClass", 4, "ngIf"], [3, "tabindex", "ngClass"], [1, "datepicker-container__footer"], ["mis-button", "", "size", "md", "type", "'none'", 3, "click"], ["mis-button", "", "size", "md", "type", "primary", 3, "disabled", "click"]], template: function TzDpContainerComponent_Template(rf, ctx) { if (rf & 1) {
|
|
266
|
+
i0.ɵɵelementStart(0, "div", 0);
|
|
267
|
+
i0.ɵɵelement(1, "div", 1);
|
|
268
|
+
i0.ɵɵelementStart(2, "div", 2)(3, "div", 3);
|
|
269
|
+
i0.ɵɵlistener("click", function TzDpContainerComponent_Template_div_click_3_listener() { return !ctx.isPreviousMonthDisabled && ctx.navigateMonth("PREVIOUS"); })("keyup.enter", function TzDpContainerComponent_Template_div_keyup_enter_3_listener() { return !ctx.isPreviousMonthDisabled && ctx.navigateMonth("PREVIOUS"); });
|
|
257
270
|
i0.ɵɵnamespaceSVG();
|
|
258
|
-
i0.ɵɵelementStart(
|
|
259
|
-
i0.ɵɵelement(
|
|
271
|
+
i0.ɵɵelementStart(4, "svg", 4);
|
|
272
|
+
i0.ɵɵelement(5, "path", 5);
|
|
260
273
|
i0.ɵɵelementEnd()();
|
|
261
274
|
i0.ɵɵnamespaceHTML();
|
|
262
|
-
i0.ɵɵelementStart(
|
|
263
|
-
i0.ɵɵtext(
|
|
275
|
+
i0.ɵɵelementStart(6, "span");
|
|
276
|
+
i0.ɵɵtext(7);
|
|
264
277
|
i0.ɵɵelementEnd();
|
|
265
|
-
i0.ɵɵelementStart(
|
|
266
|
-
i0.ɵɵlistener("click", function
|
|
278
|
+
i0.ɵɵelementStart(8, "div", 6);
|
|
279
|
+
i0.ɵɵlistener("click", function TzDpContainerComponent_Template_div_click_8_listener() { return !ctx.isNextMonthDisabled && ctx.navigateMonth("NEXT"); })("keyup.enter", function TzDpContainerComponent_Template_div_keyup_enter_8_listener() { return !ctx.isNextMonthDisabled && ctx.navigateMonth("NEXT"); });
|
|
267
280
|
i0.ɵɵnamespaceSVG();
|
|
268
|
-
i0.ɵɵelementStart(
|
|
269
|
-
i0.ɵɵelement(
|
|
281
|
+
i0.ɵɵelementStart(9, "svg", 4);
|
|
282
|
+
i0.ɵɵelement(10, "path", 5);
|
|
270
283
|
i0.ɵɵelementEnd()()();
|
|
271
284
|
i0.ɵɵnamespaceHTML();
|
|
272
|
-
i0.ɵɵelementStart(
|
|
273
|
-
i0.ɵɵtemplate(
|
|
285
|
+
i0.ɵɵelementStart(11, "div", 7)(12, "div", 8);
|
|
286
|
+
i0.ɵɵtemplate(13, TzDpContainerComponent_div_13_Template, 3, 4, "div", 9);
|
|
274
287
|
i0.ɵɵelementEnd();
|
|
275
|
-
i0.ɵɵelementStart(
|
|
276
|
-
i0.ɵɵtemplate(
|
|
288
|
+
i0.ɵɵelementStart(14, "div", 10);
|
|
289
|
+
i0.ɵɵtemplate(15, TzDpContainerComponent_div_15_Template, 2, 6, "div", 11);
|
|
277
290
|
i0.ɵɵelementEnd()();
|
|
278
|
-
i0.ɵɵtemplate(
|
|
291
|
+
i0.ɵɵtemplate(16, TzDpContainerComponent_div_16_Template, 5, 1, "div", 12);
|
|
279
292
|
i0.ɵɵelementEnd();
|
|
280
293
|
} if (rf & 2) {
|
|
281
|
-
i0.ɵɵproperty("ngClass", ctx.data.disableBoxShadow ? "remove-box-shadow" : "");
|
|
282
|
-
i0.ɵɵadvance(
|
|
283
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(
|
|
294
|
+
i0.ɵɵproperty("ngClass", ctx.data.disableBoxShadow ? "remove-box-shadow" : "")("cdkTrapFocusAutoCapture", true);
|
|
295
|
+
i0.ɵɵadvance(3);
|
|
296
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(9, _c3, ctx.isPreviousMonthDisabled));
|
|
284
297
|
i0.ɵɵadvance(4);
|
|
285
298
|
i0.ɵɵtextInterpolate2(" ", ctx.currentMonth, " ", ctx.currentYearNumber, " ");
|
|
286
299
|
i0.ɵɵadvance(1);
|
|
287
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(
|
|
300
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(11, _c3, ctx.isNextMonthDisabled));
|
|
288
301
|
i0.ɵɵadvance(5);
|
|
289
302
|
i0.ɵɵproperty("ngForOf", ctx.weekDays);
|
|
290
303
|
i0.ɵɵadvance(2);
|
|
291
304
|
i0.ɵɵproperty("ngForOf", ctx.currentMonthDates);
|
|
292
305
|
i0.ɵɵadvance(1);
|
|
293
306
|
i0.ɵɵproperty("ngIf", ctx.data.dpConfig.showApplyButton);
|
|
294
|
-
} }, dependencies: [i2.NgClass, i2.NgForOf, i2.NgIf, i3.ButtonDirective], styles: [".datepicker-container[_ngcontent-%COMP%]{background:#ffffff;border:1px solid #e0e0e0;box-shadow:0 12px 24px #0000001f,0 4px 8px #0000001f;border-radius:12px;display:flex;flex-direction:column;font-family:Lato;-webkit-user-select:none;user-select:none;box-sizing:border-box;width:290px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%]{display:flex;height:32px;margin:16px;justify-content:space-between;align-items:center;width:258px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:16px;font-style:normal;font-weight:700;line-height:24px;letter-spacing:.2px;text-align:center}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon[_ngcontent-%COMP%]{height:20px;width:20px;display:flex;align-items:center;justify-content:center;border-radius:4px;padding:4px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon.disabled-month[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon[_ngcontent-%COMP%]:not(.disabled-month):hover{cursor:pointer;background-color:#cbddfb}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon[_ngcontent-%COMP%]:nth-child(1){transform:rotate(180deg)}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%]{width:258px;height:100%;margin:0 16px 16px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%]{width:100%;display:flex;padding-bottom:10px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%] .datepicker-container__weekday[_ngcontent-%COMP%]{width:36px;height:18px;text-align:center}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%] .datepicker-container__weekday[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:12px;font-style:normal;font-weight:400;line-height:18px;letter-spacing:.2px;text-align:center;color:#c7c7c7}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%] .datepicker-container__weekday[_ngcontent-%COMP%] span.current-day[_ngcontent-%COMP%]{font-weight:700;letter-spacing:.25px;color:#181f33}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:2px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%]{width:34px;height:34px;display:flex;align-items:center;justify-content:center;border-radius:4px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.selected-day[_ngcontent-%COMP%]{background-color:#0937b2;cursor:pointer}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.disabled-day[_ngcontent-%COMP%]{cursor:default}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.disabled-day[_ngcontent-%COMP%]:hover{background-color:transparent}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.is-valid-date[_ngcontent-%COMP%]:not(.disabled-day):not(.selected-day):hover{background-color:#cbddfb;cursor:pointer}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.is-valid-date[_ngcontent-%COMP%]:not(.disabled-day):not(.selected-day):hover span.selected-day[_ngcontent-%COMP%]{color:#181f33!important}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:.2px;text-align:center;color:#181f33}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span.current-day[_ngcontent-%COMP%]{font-weight:700;letter-spacing:.25px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span.selected-day[_ngcontent-%COMP%]{color:#fff}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span.disabled-day[_ngcontent-%COMP%]{color:#c7c7c7}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__footer[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:8px;bottom:0;align-items:center;position:sticky;padding:16px;border-top:1px solid #e0e0e0}.remove-box-shadow[_ngcontent-%COMP%]{box-shadow:none!important;border:none!important;border-radius:0!important}"] });
|
|
307
|
+
} }, dependencies: [i2.NgClass, i2.NgForOf, i2.NgIf, i3.ButtonDirective, i4.CdkTrapFocus], styles: [".datepicker-container[_ngcontent-%COMP%]{background:#ffffff;border:1px solid #e0e0e0;box-shadow:0 12px 24px #0000001f,0 4px 8px #0000001f;border-radius:12px;display:flex;flex-direction:column;font-family:Lato;-webkit-user-select:none;user-select:none;box-sizing:border-box;width:290px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%]{display:flex;height:32px;margin:16px;justify-content:space-between;align-items:center;width:258px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:16px;font-style:normal;font-weight:700;line-height:24px;letter-spacing:.2px;text-align:center}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon[_ngcontent-%COMP%]{height:20px;width:20px;display:flex;align-items:center;justify-content:center;border-radius:4px;padding:4px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon.disabled-month[_ngcontent-%COMP%]{opacity:.5;cursor:not-allowed}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon[_ngcontent-%COMP%]:not(.disabled-month):hover{cursor:pointer;background-color:#cbddfb}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__header[_ngcontent-%COMP%] .datepicker-container__arrow__icon[_ngcontent-%COMP%]:nth-child(1){transform:rotate(180deg)}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%]{width:258px;height:100%;margin:0 16px 16px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%]{width:100%;display:flex;padding-bottom:10px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%] .datepicker-container__weekday[_ngcontent-%COMP%]{width:36px;height:18px;text-align:center}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%] .datepicker-container__weekday[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:12px;font-style:normal;font-weight:400;line-height:18px;letter-spacing:.2px;text-align:center;color:#c7c7c7}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__weekdays[_ngcontent-%COMP%] .datepicker-container__weekday[_ngcontent-%COMP%] span.current-day[_ngcontent-%COMP%]{font-weight:700;letter-spacing:.25px;color:#181f33}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:2px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%]{width:34px;height:34px;display:flex;align-items:center;justify-content:center;border-radius:4px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.selected-day[_ngcontent-%COMP%]{background-color:#0937b2;cursor:pointer}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.disabled-day[_ngcontent-%COMP%]{cursor:default}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.disabled-day[_ngcontent-%COMP%]:hover{background-color:transparent}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.is-valid-date[_ngcontent-%COMP%]:not(.disabled-day):not(.selected-day):hover{background-color:#cbddfb;cursor:pointer}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day.is-valid-date[_ngcontent-%COMP%]:not(.disabled-day):not(.selected-day):hover span.selected-day[_ngcontent-%COMP%]{color:#181f33!important}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:.2px;text-align:center;color:#181f33}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span.current-day[_ngcontent-%COMP%]{font-weight:700;letter-spacing:.25px}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span.selected-day[_ngcontent-%COMP%]{color:#fff}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__body[_ngcontent-%COMP%] .datepicker-container__days[_ngcontent-%COMP%] .datepicker-container__day[_ngcontent-%COMP%] span.disabled-day[_ngcontent-%COMP%]{color:#c7c7c7}.datepicker-container[_ngcontent-%COMP%] .datepicker-container__footer[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:8px;bottom:0;align-items:center;position:sticky;padding:16px;border-top:1px solid #e0e0e0}.remove-box-shadow[_ngcontent-%COMP%]{box-shadow:none!important;border:none!important;border-radius:0!important}"] });
|
|
295
308
|
(function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TzDpContainerComponent, [{
|
|
296
309
|
type: Component,
|
|
297
|
-
args: [{ selector: "mis-tz-dp", template: "<div class=\"datepicker-container\" [ngClass]=\"data.disableBoxShadow?'remove-box-shadow':''\">\n <div class=\"datepicker-container__header\">\n <div\n class=\"datepicker-container__arrow__icon\"\n (click)=\"!isPreviousMonthDisabled && navigateMonth('PREVIOUS')\"\n [ngClass]=\"{\n 'disabled-month': isPreviousMonthDisabled\n }\"\n >\n <svg width=\"20\" height=\"16\" viewBox=\"0 0 20 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n d=\"M19.7071 8.70711C20.0976 8.31658 20.0976 7.68342 19.7071 7.29289L13.3431 0.928933C12.9526 0.538409 12.3195 0.538409 11.9289 0.928933C11.5384 1.31946 11.5384 1.95262 11.9289 2.34315L17.5858 8L11.9289 13.6569C11.5384 14.0474 11.5384 14.6805 11.9289 15.0711C12.3195 15.4616 12.9526 15.4616 13.3431 15.0711L19.7071 8.70711ZM-8.74228e-08 9L19 9L19 7L8.74228e-08 7L-8.74228e-08 9Z\"\n fill=\"#181F33\"\n ></path>\n </svg>\n </div>\n <span> {{ currentMonth }} {{ currentYearNumber }} </span>\n <div\n class=\"datepicker-container__arrow__icon\"\n (click)=\"!isNextMonthDisabled && navigateMonth('NEXT')\"\n [ngClass]=\"{\n 'disabled-month': isNextMonthDisabled\n }\"\n >\n <svg width=\"20\" height=\"16\" viewBox=\"0 0 20 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n d=\"M19.7071 8.70711C20.0976 8.31658 20.0976 7.68342 19.7071 7.29289L13.3431 0.928933C12.9526 0.538409 12.3195 0.538409 11.9289 0.928933C11.5384 1.31946 11.5384 1.95262 11.9289 2.34315L17.5858 8L11.9289 13.6569C11.5384 14.0474 11.5384 14.6805 11.9289 15.0711C12.3195 15.4616 12.9526 15.4616 13.3431 15.0711L19.7071 8.70711ZM-8.74228e-08 9L19 9L19 7L8.74228e-08 7L-8.74228e-08 9Z\"\n fill=\"#181F33\"\n ></path>\n </svg>\n </div>\n </div>\n <div class=\"datepicker-container__body\">\n <div class=\"datepicker-container__weekdays\">\n <div class=\"datepicker-container__weekday\" *ngFor=\"let weekDay of weekDays\">\n <span [ngClass]=\"{ 'current-day': weekDay.isCurrentDay }\">{{ weekDay.label }}</span>\n </div>\n </div>\n <div class=\"datepicker-container__days\">\n <div\n class=\"datepicker-container__day\"\n [ngClass]=\"{\n 'selected-day': !localSelectedDate ? day.isSelectedDay : day === localSelectedDate,\n 'disabled-day': day.isDisabledDay,\n 'is-valid-date': day.date > 0 && !day.isSelectedDay\n }\"\n *ngFor=\"let day of currentMonthDates\"\n (click)=\"selectDay(day)\"\n >\n <span\n *ngIf=\"day.date > 0\"\n [ngClass]=\"{\n 'current-day': day.isCurrentDay,\n 'selected-day': !localSelectedDate ? day.isSelectedDay : day === localSelectedDate,\n 'disabled-day': day.isDisabledDay\n }\"\n >\n {{ day.date }}\n </span>\n </div>\n </div>\n </div>\n <div class=\"datepicker-container__footer\" *ngIf=\"data.dpConfig.showApplyButton\">\n <button mis-button size=\"md\" type=\"'none'\" (click)=\"cancelDatePicker()\">Cancel</button>\n <button mis-button size=\"md\" type=\"primary\" (click)=\"applyDate()\" [disabled]=\"!(data.date || localSelectedDate)\">Apply</button>\n </div>\n</div>\n", styles: [".datepicker-container{background:#ffffff;border:1px solid #e0e0e0;box-shadow:0 12px 24px #0000001f,0 4px 8px #0000001f;border-radius:12px;display:flex;flex-direction:column;font-family:Lato;-webkit-user-select:none;user-select:none;box-sizing:border-box;width:290px}.datepicker-container .datepicker-container__header{display:flex;height:32px;margin:16px;justify-content:space-between;align-items:center;width:258px}.datepicker-container .datepicker-container__header span{font-size:16px;font-style:normal;font-weight:700;line-height:24px;letter-spacing:.2px;text-align:center}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon{height:20px;width:20px;display:flex;align-items:center;justify-content:center;border-radius:4px;padding:4px}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon.disabled-month{opacity:.5;cursor:not-allowed}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon:not(.disabled-month):hover{cursor:pointer;background-color:#cbddfb}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon:nth-child(1){transform:rotate(180deg)}.datepicker-container .datepicker-container__body{width:258px;height:100%;margin:0 16px 16px}.datepicker-container .datepicker-container__body .datepicker-container__weekdays{width:100%;display:flex;padding-bottom:10px}.datepicker-container .datepicker-container__body .datepicker-container__weekdays .datepicker-container__weekday{width:36px;height:18px;text-align:center}.datepicker-container .datepicker-container__body .datepicker-container__weekdays .datepicker-container__weekday span{font-size:12px;font-style:normal;font-weight:400;line-height:18px;letter-spacing:.2px;text-align:center;color:#c7c7c7}.datepicker-container .datepicker-container__body .datepicker-container__weekdays .datepicker-container__weekday span.current-day{font-weight:700;letter-spacing:.25px;color:#181f33}.datepicker-container .datepicker-container__body .datepicker-container__days{display:flex;flex-wrap:wrap;gap:2px}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day{width:34px;height:34px;display:flex;align-items:center;justify-content:center;border-radius:4px}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.selected-day{background-color:#0937b2;cursor:pointer}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.disabled-day{cursor:default}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.disabled-day:hover{background-color:transparent}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.is-valid-date:not(.disabled-day):not(.selected-day):hover{background-color:#cbddfb;cursor:pointer}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.is-valid-date:not(.disabled-day):not(.selected-day):hover span.selected-day{color:#181f33!important}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span{font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:.2px;text-align:center;color:#181f33}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span.current-day{font-weight:700;letter-spacing:.25px}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span.selected-day{color:#fff}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span.disabled-day{color:#c7c7c7}.datepicker-container .datepicker-container__footer{display:flex;justify-content:flex-end;gap:8px;bottom:0;align-items:center;position:sticky;padding:16px;border-top:1px solid #e0e0e0}.remove-box-shadow{box-shadow:none!important;border:none!important;border-radius:0!important}\n"] }]
|
|
310
|
+
args: [{ selector: "mis-tz-dp", template: "<div class=\"datepicker-container\" [ngClass]=\"data.disableBoxShadow?'remove-box-shadow':''\" aria-label=\"date picker\" cdkTrapFocus [cdkTrapFocusAutoCapture]=\"true\">\n <div tabindex=\"-1\" cdkFocusInitial></div>\n <div class=\"datepicker-container__header\">\n <div\n class=\"datepicker-container__arrow__icon\"\n (click)=\"!isPreviousMonthDisabled && navigateMonth('PREVIOUS')\"\n tabindex=\"0\"\n aria-label=\"Previous Month\"\n (keyup.enter)=\"!isPreviousMonthDisabled && navigateMonth('PREVIOUS')\"\n [ngClass]=\"{\n 'disabled-month': isPreviousMonthDisabled\n }\"\n >\n <svg width=\"20\" height=\"16\" viewBox=\"0 0 20 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n d=\"M19.7071 8.70711C20.0976 8.31658 20.0976 7.68342 19.7071 7.29289L13.3431 0.928933C12.9526 0.538409 12.3195 0.538409 11.9289 0.928933C11.5384 1.31946 11.5384 1.95262 11.9289 2.34315L17.5858 8L11.9289 13.6569C11.5384 14.0474 11.5384 14.6805 11.9289 15.0711C12.3195 15.4616 12.9526 15.4616 13.3431 15.0711L19.7071 8.70711ZM-8.74228e-08 9L19 9L19 7L8.74228e-08 7L-8.74228e-08 9Z\"\n fill=\"#181F33\"\n ></path>\n </svg>\n </div>\n <span> {{ currentMonth }} {{ currentYearNumber }} </span>\n <div\n class=\"datepicker-container__arrow__icon\"\n (click)=\"!isNextMonthDisabled && navigateMonth('NEXT')\"\n tabindex=\"0\"\n aria-label=\"Next Month\"\n (keyup.enter)=\"!isNextMonthDisabled && navigateMonth('NEXT')\"\n [ngClass]=\"{\n 'disabled-month': isNextMonthDisabled\n }\"\n >\n <svg width=\"20\" height=\"16\" viewBox=\"0 0 20 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n d=\"M19.7071 8.70711C20.0976 8.31658 20.0976 7.68342 19.7071 7.29289L13.3431 0.928933C12.9526 0.538409 12.3195 0.538409 11.9289 0.928933C11.5384 1.31946 11.5384 1.95262 11.9289 2.34315L17.5858 8L11.9289 13.6569C11.5384 14.0474 11.5384 14.6805 11.9289 15.0711C12.3195 15.4616 12.9526 15.4616 13.3431 15.0711L19.7071 8.70711ZM-8.74228e-08 9L19 9L19 7L8.74228e-08 7L-8.74228e-08 9Z\"\n fill=\"#181F33\"\n ></path>\n </svg>\n </div>\n </div>\n <div class=\"datepicker-container__body\">\n <div class=\"datepicker-container__weekdays\">\n <div class=\"datepicker-container__weekday\" *ngFor=\"let weekDay of weekDays\">\n <span [ngClass]=\"{ 'current-day': weekDay.isCurrentDay }\">{{ weekDay.label }}</span>\n </div>\n </div>\n <div class=\"datepicker-container__days\">\n <div\n class=\"datepicker-container__day\"\n [ngClass]=\"{\n 'selected-day': !localSelectedDate ? day.isSelectedDay : day === localSelectedDate,\n 'disabled-day': day.isDisabledDay,\n 'is-valid-date': day.date > 0 && !day.isSelectedDay\n }\"\n *ngFor=\"let day of currentMonthDates\"\n (click)=\"selectDay(day)\"\n (keyup.enter)=\"selectDay(day)\"\n >\n <span\n *ngIf=\"day.date > 0\"\n [tabindex]=\"day.isDisabledDay ? -1 : 0\"\n [ngClass]=\"{\n 'current-day': day.isCurrentDay,\n 'selected-day': !localSelectedDate ? day.isSelectedDay : day === localSelectedDate,\n 'disabled-day': day.isDisabledDay\n }\"\n [attr.aria-label]=\"retractDayMonth(day.date, currentMonth, currentYearNumber)\"\n >\n {{ day.date }}\n </span>\n </div>\n </div>\n </div>\n <div class=\"datepicker-container__footer\" *ngIf=\"data.dpConfig.showApplyButton\">\n <button mis-button size=\"md\" type=\"'none'\" (click)=\"cancelDatePicker()\">Cancel</button>\n <button mis-button size=\"md\" type=\"primary\" (click)=\"applyDate()\" [disabled]=\"!(data.date || localSelectedDate)\">Apply</button>\n </div>\n</div>\n", styles: [".datepicker-container{background:#ffffff;border:1px solid #e0e0e0;box-shadow:0 12px 24px #0000001f,0 4px 8px #0000001f;border-radius:12px;display:flex;flex-direction:column;font-family:Lato;-webkit-user-select:none;user-select:none;box-sizing:border-box;width:290px}.datepicker-container .datepicker-container__header{display:flex;height:32px;margin:16px;justify-content:space-between;align-items:center;width:258px}.datepicker-container .datepicker-container__header span{font-size:16px;font-style:normal;font-weight:700;line-height:24px;letter-spacing:.2px;text-align:center}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon{height:20px;width:20px;display:flex;align-items:center;justify-content:center;border-radius:4px;padding:4px}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon.disabled-month{opacity:.5;cursor:not-allowed}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon:not(.disabled-month):hover{cursor:pointer;background-color:#cbddfb}.datepicker-container .datepicker-container__header .datepicker-container__arrow__icon:nth-child(1){transform:rotate(180deg)}.datepicker-container .datepicker-container__body{width:258px;height:100%;margin:0 16px 16px}.datepicker-container .datepicker-container__body .datepicker-container__weekdays{width:100%;display:flex;padding-bottom:10px}.datepicker-container .datepicker-container__body .datepicker-container__weekdays .datepicker-container__weekday{width:36px;height:18px;text-align:center}.datepicker-container .datepicker-container__body .datepicker-container__weekdays .datepicker-container__weekday span{font-size:12px;font-style:normal;font-weight:400;line-height:18px;letter-spacing:.2px;text-align:center;color:#c7c7c7}.datepicker-container .datepicker-container__body .datepicker-container__weekdays .datepicker-container__weekday span.current-day{font-weight:700;letter-spacing:.25px;color:#181f33}.datepicker-container .datepicker-container__body .datepicker-container__days{display:flex;flex-wrap:wrap;gap:2px}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day{width:34px;height:34px;display:flex;align-items:center;justify-content:center;border-radius:4px}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.selected-day{background-color:#0937b2;cursor:pointer}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.disabled-day{cursor:default}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.disabled-day:hover{background-color:transparent}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.is-valid-date:not(.disabled-day):not(.selected-day):hover{background-color:#cbddfb;cursor:pointer}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day.is-valid-date:not(.disabled-day):not(.selected-day):hover span.selected-day{color:#181f33!important}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span{font-size:14px;font-style:normal;font-weight:400;line-height:20px;letter-spacing:.2px;text-align:center;color:#181f33}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span.current-day{font-weight:700;letter-spacing:.25px}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span.selected-day{color:#fff}.datepicker-container .datepicker-container__body .datepicker-container__days .datepicker-container__day span.disabled-day{color:#c7c7c7}.datepicker-container .datepicker-container__footer{display:flex;justify-content:flex-end;gap:8px;bottom:0;align-items:center;position:sticky;padding:16px;border-top:1px solid #e0e0e0}.remove-box-shadow{box-shadow:none!important;border:none!important;border-radius:0!important}\n"] }]
|
|
298
311
|
}], function () { return [{ type: undefined, decorators: [{
|
|
299
312
|
type: Inject,
|
|
300
313
|
args: [CONTAINER_DATA]
|
|
301
|
-
}] }, { type: i1.ToastService }]; },
|
|
314
|
+
}] }, { type: i1.ToastService }]; }, { closeOnEsc: [{
|
|
315
|
+
type: HostListener,
|
|
316
|
+
args: ["keydown.esc"]
|
|
317
|
+
}] }); })();
|
|
302
318
|
|
|
303
319
|
class TzDatepickerDirective {
|
|
304
320
|
constructor(control, element, overlay, viewContainerRef) {
|
|
@@ -344,6 +360,19 @@ class TzDatepickerDirective {
|
|
|
344
360
|
this.open();
|
|
345
361
|
}
|
|
346
362
|
}
|
|
363
|
+
toggleDatePickerOnEnter() {
|
|
364
|
+
if (this.isOpen) {
|
|
365
|
+
this.close();
|
|
366
|
+
}
|
|
367
|
+
else {
|
|
368
|
+
this.open();
|
|
369
|
+
}
|
|
370
|
+
}
|
|
371
|
+
closeOnEsc() {
|
|
372
|
+
if (this.isOpen) {
|
|
373
|
+
this.close();
|
|
374
|
+
}
|
|
375
|
+
}
|
|
347
376
|
open() {
|
|
348
377
|
this.dpConfig = {
|
|
349
378
|
format: DATE_FORMAT,
|
|
@@ -412,7 +441,7 @@ class TzDatepickerDirective {
|
|
|
412
441
|
}
|
|
413
442
|
TzDatepickerDirective.ɵfac = function TzDatepickerDirective_Factory(t) { return new (t || TzDatepickerDirective)(i0.ɵɵdirectiveInject(i1$1.NgControl, 10), i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i2$1.Overlay), i0.ɵɵdirectiveInject(i0.ViewContainerRef)); };
|
|
414
443
|
TzDatepickerDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: TzDatepickerDirective, selectors: [["input", "misTzDp", ""]], hostBindings: function TzDatepickerDirective_HostBindings(rf, ctx) { if (rf & 1) {
|
|
415
|
-
i0.ɵɵlistener("click", function TzDatepickerDirective_click_HostBindingHandler() { return ctx.toggleDatePicker(); });
|
|
444
|
+
i0.ɵɵlistener("click", function TzDatepickerDirective_click_HostBindingHandler() { return ctx.toggleDatePicker(); })("keydown.enter", function TzDatepickerDirective_keydown_enter_HostBindingHandler() { return ctx.toggleDatePickerOnEnter(); })("keydown.esc", function TzDatepickerDirective_keydown_esc_HostBindingHandler() { return ctx.closeOnEsc(); });
|
|
416
445
|
} }, inputs: { dpConfig: "dpConfig", selectedDate: "selectedDate", datesDisabled: "datesDisabled", dateMessages: "dateMessages", positionX: "positionX", positionY: "positionY", offsetX: "offsetX", offsetY: "offsetY", allowBookingOnDisabledDay: "allowBookingOnDisabledDay", disableBoxShadow: "disableBoxShadow", disableOverLay: "disableOverLay", openElement: "openElement" }, outputs: { dateChange: "dateChange" }, features: [i0.ɵɵNgOnChangesFeature] });
|
|
417
446
|
(function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TzDatepickerDirective, [{
|
|
418
447
|
type: Directive,
|
|
@@ -452,22 +481,28 @@ TzDatepickerDirective.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: TzDat
|
|
|
452
481
|
}], toggleDatePicker: [{
|
|
453
482
|
type: HostListener,
|
|
454
483
|
args: ["click"]
|
|
484
|
+
}], toggleDatePickerOnEnter: [{
|
|
485
|
+
type: HostListener,
|
|
486
|
+
args: ["keydown.enter"]
|
|
487
|
+
}], closeOnEsc: [{
|
|
488
|
+
type: HostListener,
|
|
489
|
+
args: ["keydown.esc"]
|
|
455
490
|
}] }); })();
|
|
456
491
|
|
|
457
492
|
class DatepickerModuleV2 {
|
|
458
493
|
}
|
|
459
494
|
DatepickerModuleV2.ɵfac = function DatepickerModuleV2_Factory(t) { return new (t || DatepickerModuleV2)(); };
|
|
460
495
|
DatepickerModuleV2.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: DatepickerModuleV2 });
|
|
461
|
-
DatepickerModuleV2.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule, OverlayModule, ToastModule.forRoot(), ButtonModule] });
|
|
496
|
+
DatepickerModuleV2.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule, OverlayModule, ToastModule.forRoot(), ButtonModule, A11yModule] });
|
|
462
497
|
(function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DatepickerModuleV2, [{
|
|
463
498
|
type: NgModule,
|
|
464
499
|
args: [{
|
|
465
500
|
declarations: [TzDpContainerComponent, TzDatepickerDirective],
|
|
466
|
-
imports: [CommonModule, OverlayModule, ToastModule.forRoot(), ButtonModule],
|
|
501
|
+
imports: [CommonModule, OverlayModule, ToastModule.forRoot(), ButtonModule, A11yModule],
|
|
467
502
|
exports: [TzDpContainerComponent, TzDatepickerDirective]
|
|
468
503
|
}]
|
|
469
504
|
}], null, null); })();
|
|
470
|
-
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(DatepickerModuleV2, { declarations: [TzDpContainerComponent, TzDatepickerDirective], imports: [CommonModule, OverlayModule, i1.ToastModule, ButtonModule], exports: [TzDpContainerComponent, TzDatepickerDirective] }); })();
|
|
505
|
+
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(DatepickerModuleV2, { declarations: [TzDpContainerComponent, TzDatepickerDirective], imports: [CommonModule, OverlayModule, i1.ToastModule, ButtonModule, A11yModule], exports: [TzDpContainerComponent, TzDatepickerDirective] }); })();
|
|
471
506
|
|
|
472
507
|
/**
|
|
473
508
|
* Generated bundle index. Do not edit.
|