asksuite-citrus 0.19.1 → 0.19.2
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/esm2022/lib/components/autocomplete/autocomplete.component.mjs +1 -7
- package/esm2022/lib/components/date-picker/date-picker-calendar/date-picker-calendar.component.mjs +13 -17
- package/esm2022/lib/components/date-picker/date-picker.component.mjs +3 -3
- package/fesm2022/asksuite-citrus.mjs +14 -24
- package/fesm2022/asksuite-citrus.mjs.map +1 -1
- package/lib/components/autocomplete/autocomplete.component.d.ts +0 -1
- package/lib/components/date-picker/date-picker-calendar/date-picker-calendar.component.d.ts +0 -1
- package/package.json +1 -1
@@ -596,7 +596,6 @@ class AutocompleteComponent {
|
|
596
596
|
this._destroy = inject(DestroyRef);
|
597
597
|
this.ITEMS_PER_PAGE = 40;
|
598
598
|
this._pageNumber = 1;
|
599
|
-
this._reachedEnd = false;
|
600
599
|
this._selectAllMessage = '';
|
601
600
|
this.multiple = false;
|
602
601
|
this.valueProp = '';
|
@@ -620,7 +619,6 @@ class AutocompleteComponent {
|
|
620
619
|
ngOnChanges(changes) {
|
621
620
|
if (changes['options']) {
|
622
621
|
this._pageNumber = 1;
|
623
|
-
this._reachedEnd = false;
|
624
622
|
this.paginatedFilteredOptions = [];
|
625
623
|
this.filteredOptions = changes['options'].currentValue;
|
626
624
|
this.updateValidation();
|
@@ -629,7 +627,6 @@ class AutocompleteComponent {
|
|
629
627
|
handleInputChange() {
|
630
628
|
this.inputControl.valueChanges.pipe(takeUntilDestroyed(this._destroy), debounceTime(300), tap(() => {
|
631
629
|
this._pageNumber = 1;
|
632
|
-
this._reachedEnd = false;
|
633
630
|
this.paginatedFilteredOptions = [];
|
634
631
|
}), map(value => this.filterFn ? this.filterFn(value || '') : [])).subscribe(items => {
|
635
632
|
this.filteredOptions = items;
|
@@ -779,9 +776,6 @@ class AutocompleteComponent {
|
|
779
776
|
this.paginatedFilteredOptions = [...this.paginatedFilteredOptions, ...nextPageItems];
|
780
777
|
this._pageNumber += 1;
|
781
778
|
}
|
782
|
-
else {
|
783
|
-
this._reachedEnd = true;
|
784
|
-
}
|
785
779
|
this.updateValidation();
|
786
780
|
this.change.detectChanges();
|
787
781
|
}
|
@@ -900,9 +894,6 @@ class DatePickerCalendarComponent {
|
|
900
894
|
this._weekDays = [];
|
901
895
|
this._days = [];
|
902
896
|
}
|
903
|
-
get shouldDisableNextMonth() {
|
904
|
-
return this.isFutureDate(this.displayDate.clone().add(1, 'month').unix());
|
905
|
-
}
|
906
897
|
get days() {
|
907
898
|
return this._days;
|
908
899
|
}
|
@@ -1052,34 +1043,31 @@ class DatePickerCalendarComponent {
|
|
1052
1043
|
}
|
1053
1044
|
selectDate(timestamp) {
|
1054
1045
|
const momentDate = moment.unix(timestamp);
|
1055
|
-
if (this.isRange)
|
1056
|
-
this.handleRangeSelect(momentDate);
|
1057
|
-
|
1058
|
-
else {
|
1059
|
-
this.handleSingleSelect(momentDate);
|
1060
|
-
}
|
1046
|
+
if (this.isRange)
|
1047
|
+
return this.handleRangeSelect(momentDate);
|
1048
|
+
this.handleSingleSelect(momentDate);
|
1061
1049
|
}
|
1062
1050
|
handleRangeSelect(selectedDate) {
|
1063
1051
|
const innerDate = this.innerDate;
|
1064
|
-
// First selection
|
1065
1052
|
if (!innerDate.from) {
|
1053
|
+
// First selection
|
1066
1054
|
innerDate.from = this.getDayFromMoment(selectedDate);
|
1067
1055
|
}
|
1068
|
-
// Second selection
|
1069
1056
|
else if (!innerDate.to) {
|
1057
|
+
// Second selection
|
1070
1058
|
const actualFrom = moment.unix(innerDate.from.timestamp);
|
1071
|
-
// Selected date is past the previous selected date
|
1072
1059
|
if (selectedDate.isBefore(actualFrom, 'day')) {
|
1060
|
+
// Selected date is past the previous selected date
|
1073
1061
|
innerDate.to = innerDate.from;
|
1074
1062
|
innerDate.from = this.getDayFromMoment(selectedDate);
|
1075
1063
|
}
|
1076
|
-
// Selected date is future of the previous selected date
|
1077
1064
|
else {
|
1065
|
+
// Selected date is future of the previous selected date
|
1078
1066
|
innerDate.to = this.getDayFromMoment(selectedDate);
|
1079
1067
|
}
|
1080
1068
|
}
|
1081
|
-
// Selection when both from and to are already selected
|
1082
1069
|
else {
|
1070
|
+
// Selection when both from and to are already selected
|
1083
1071
|
innerDate.from = this.getDayFromMoment(selectedDate);
|
1084
1072
|
innerDate.to = undefined;
|
1085
1073
|
}
|
@@ -1092,6 +1080,8 @@ class DatePickerCalendarComponent {
|
|
1092
1080
|
newRange.from = this.getDateFromDay(range.from);
|
1093
1081
|
if (range.to)
|
1094
1082
|
newRange.to = formatTo(moment.unix(range.to.timestamp));
|
1083
|
+
else
|
1084
|
+
newRange.to = formatTo(moment.unix(range.from.timestamp));
|
1095
1085
|
}
|
1096
1086
|
this.dateChange.emit(newRange);
|
1097
1087
|
}
|
@@ -1107,11 +1097,11 @@ class DatePickerCalendarComponent {
|
|
1107
1097
|
return date.isAfter(now);
|
1108
1098
|
}
|
1109
1099
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DatePickerCalendarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
1110
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: DatePickerCalendarComponent, selector: "ask-date-picker-calendar", inputs: { isRange: "isRange", disableFutureDate: "disableFutureDate", date: "date" }, outputs: { dateChange: "dateChange" }, ngImport: i0, template: "<div class=\"date-picker-calendar-container\">\n <header class=\"month-selector\">\n <button type=\"button\" class=\"selector-button\" (click)=\"incrementMonth(-1)\">\n <span class=\"material-icons icon\">chevron_left</span>\n </button>\n\n <span class=\"month-year-display\" data-testid=\"month-year-display\">{{ month }} {{ year }}</span>\n\n <button\n type=\"button\"\n class=\"selector-button\"\n
|
1100
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.1.6", type: DatePickerCalendarComponent, selector: "ask-date-picker-calendar", inputs: { isRange: "isRange", disableFutureDate: "disableFutureDate", date: "date" }, outputs: { dateChange: "dateChange" }, ngImport: i0, template: "<div class=\"date-picker-calendar-container\">\n <header class=\"month-selector\">\n <button type=\"button\" class=\"selector-button\" (click)=\"incrementMonth(-1)\">\n <span class=\"material-icons icon\">chevron_left</span>\n </button>\n\n <span class=\"month-year-display\" data-testid=\"month-year-display\">{{ month }} {{ year }}</span>\n\n <button\n type=\"button\"\n class=\"selector-button\"\n (click)=\"incrementMonth(1)\"\n >\n <span class=\"material-icons icon\">chevron_right</span>\n </button>\n </header>\n\n <main class=\"calendar\">\n <div class=\"week-days-header\">\n <span class=\"week-day\" *ngFor=\"let weekDay of weekDays\">{{ weekDay.name }}</span>\n </div>\n\n <div class=\"days-block\" data-testid=\"days-block\">\n <button\n *ngFor=\"let day of days\"\n (click)=\"selectDate(day.timestamp)\"\n [disabled]=\"day.isFuture\"\n [ngClass]=\"{\n 'day': true,\n 'another-month': monthNumber != day.month,\n 'selected': isDaySelected(day),\n 'first': isFirstSelectedDay(day),\n 'last': isLastSelectedDay(day),\n }\"\n >\n {{ day.day }}\n </button>\n </div>\n </main>\n</div>\n", styles: [":root{--asksuite-orange: #FF5724;--white: #FFF;--grey-50: #F5F7FA;--grey-100: #E4E7EB;--grey-200: #CBD2D9;--grey-300: #9AA5B1;--grey-400: #7B8794;--grey-500: #616E7C;--grey-600: #52606D;--grey-700: #3E4C59;--grey-800: #2A3042;--grey-900: #1F2933;--yellow-50: #FFF8E2;--yellow-200: #FFECB3;--success-green: #4BAF50;--warning-yellow: #FFC107;--error-red: #E8453E;--shadow: rgba(42, 48, 66, .1607843137);--lightblue-tag: #CDF9F3;--lavender-tag: #D4DAF3;--green-tag: #CEEEAA;--pink-tag: #FBC5FF;--orange-tag: #FED5C9;--purple-tag: #DDBFE5;--yellow-tag: #FFE0B2;--blue-tag: #B2E5FD;--brown-tag: #EFC89C;--whatsapp-green: #68B35D;--facebook-blue: #0084FF;--instagram-pink: #D53E91;--google-blue: #345DC8;--telegram-blue: #34AADF;--telephone-yellow: #FECB00;--primary-background: #FFF;--secondary-background: #EFF3F8;--hover-background: #F5F7FA;--divider-background: #E4E7EB;--font-color-100: #2A3042;--font-color-200: #616E7C;--font-color-300: #9AA5B1}:root{--font-default: $font-default;--font-code: $font-code}:root{--font-xs: $font-xs;--font-sm: $font-sm;--font-md: $font-md;--font-lg: $font-lg;--font-xl: $font-xl;--font-xxl: $font-xxl}:root{--font-weight-regular: $font-weight-regular;--font-weight-medium: $font-weight-medium}:root{--radii-px: $radii-px;--radii-xs: $radii-xs;--radii-sm: $radii-sm;--radii-md: $radii-md;--radii-lg: $radii-lg;--radii-full: $radii-full}.ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.scale-in-center{animation:scale-in-center .3s ease-in-out both}@keyframes scale-in-center{0%{transform:scale(0);opacity:1}to{transform:scale(1);opacity:1}}.scale-out-center{animation:scale-out-center .3s ease-in-out both}@keyframes scale-out-center{0%{transform:scale(1);opacity:1}to{transform:scale(0);opacity:1}}.ask-tooltip{background-color:#7b8794;color:#fff;padding:4px;border-radius:8px;position:relative}.ask-tooltip>div{text-align:center!important}.ask-tooltip:after{position:absolute;content:\"\";width:10px;height:10px;background-color:inherit}.ask-tooltip.-above{margin-bottom:4px}.ask-tooltip.-above:after{bottom:-5px;left:50%;transform:translate(-50%) rotate(45deg)}.ask-tooltip.-below{margin-top:4px}.ask-tooltip.-below:after{top:-5px;left:50%;transform:translate(-50%) rotate(45deg)}.ask-tooltip.-after,.ask-tooltip.-right{margin-left:4px}.ask-tooltip.-after:after,.ask-tooltip.-right:after{left:-5px;top:50%;transform:translateY(-50%) rotate(45deg)}.ask-tooltip.-before,.ask-tooltip.-left{margin-right:4px}.ask-tooltip.-before:after,.ask-tooltip.-left:after{right:-5px;top:50%;transform:translateY(-50%) rotate(45deg)}.ask-button{padding:8px 24px;border-radius:6px;border:none;outline:none;height:48px;font-size:1rem;transition:background-color .1s,box-shadow .1s;cursor:pointer;font-weight:500;background:white;color:var(--grey-500)}.ask-button:not(.-primary,.-secondary){box-shadow:0 1px 2px #2a304229}.ask-button:not(.-primary):hover:not(:disabled){box-shadow:0 0 6px #2a304229}.ask-button:hover:not(:disabled){box-shadow:0 0 6px #ff572466}.ask-button:active:not(:disabled){background-color:#f34915}.ask-button:disabled{cursor:not-allowed;background-color:#9aa5b1}.ask-button.-primary{background:#FF5724;color:#fff}.ask-modal-header{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:0 24px 9px}.ask-modal-body{flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;padding:20px 24px;max-height:65vh;display:block}.ask-modal-footer{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0)}.material-icons{font-family:Material Icons;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-feature-settings:\"liga\";-webkit-font-smoothing:antialiased}*{box-sizing:border-box}*,button,select,textarea{font-family:Inter,sans-serif;font-weight:400}input{font-size:1rem}.ask-badge{position:relative}.ask-badge>.badge{position:absolute;display:flex;justify-content:center;align-items:center;background-color:var(--bg-color);color:#fff;font-size:12px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;border-radius:50%;box-shadow:0 2px 6px -1px #00000080}.ask-badge>.badge.-primary{--bg-color: var(--asksuite-orange)}.ask-badge>.badge.-secondary{--bg-color: var(--grey-800)}.ask-badge>.badge.-top{top:-10px}.ask-badge>.badge.-bottom{bottom:-10px}.ask-badge>.badge.-left{left:-10px}.ask-badge>.badge.-right{right:-10px}.ask-badge>.badge.-small{width:18px;height:18px;font-size:10px}.ask-badge>.badge.-regular{width:22px;height:22px;font-size:11px}.ask-badge>.badge.-large{width:28px;height:28px;font-size:12px}.ask-dropdown-top-right{margin-left:8px}.ask-dropdown-top-left{margin-right:8px}.ask-dropdown-bottom-right,.ask-dropdown-bottom-left{margin-top:8px}.date-picker-calendar-container{display:flex;flex-direction:column;padding:16px;width:320px;-webkit-user-select:none;user-select:none}.month-selector{display:flex;align-items:center;justify-content:space-between;padding:4px;background-color:var(--secondary-background);border-radius:4px;text-transform:capitalize}.month-selector>.month-year-display{font-size:.75rem;color:var(--font-color-100);font-weight:500}.selector-button{display:flex;align-items:center;justify-content:center;width:20px;height:20px;background-color:var(--primary-background);box-shadow:0 1px 2px #2a304229;outline:none;border:none;border-radius:4px;cursor:pointer}.selector-button>.icon{color:var(--font-color-100);font-size:18px}.calendar{display:flex;flex-direction:column;padding:16px 32px}.week-days-header{display:grid;grid-template-rows:auto;grid-template-columns:repeat(7,auto);place-items:center;padding-bottom:8px;border-bottom:1px solid #E4E7EB}.week-days-header>.week-day{display:flex;align-items:center;justify-content:center;font-size:.75rem;line-height:1rem;width:100%;color:var(--font-color-100)}.days-block{display:grid;grid-template-rows:repeat(6,auto);grid-template-columns:repeat(7,auto);place-items:center;row-gap:4px;color:var(--font-color-200);padding-top:4px}.days-block>.day{display:flex;align-items:center;justify-content:center;text-align:center;font-size:.75rem;line-height:1rem;width:100%;height:31px;border:none;color:var(--font-color-200);background:none;border-radius:99999px;transition:.2s background-color,.2s color,.2s font-weight}.days-block>.day:disabled{text-decoration:line-through;color:var(--font-color-300)}.days-block>.day:disabled:hover{color:var(--font-color-300);background:none;cursor:not-allowed}.days-block>.day.another-month{color:var(--font-color-300)}.days-block>.day.selected,.days-block>.day:hover{color:#ff5724;background-color:#ff57241a;cursor:pointer}.days-block>.day.selected{border-radius:0;font-weight:500}.days-block>.day.selected.first{border-top-left-radius:99999px;border-bottom-left-radius:99999px}.days-block>.day.selected.last{border-top-right-radius:99999px;border-bottom-right-radius:99999px}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] }); }
|
1111
1101
|
}
|
1112
1102
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.6", ngImport: i0, type: DatePickerCalendarComponent, decorators: [{
|
1113
1103
|
type: Component,
|
1114
|
-
args: [{ selector: 'ask-date-picker-calendar', template: "<div class=\"date-picker-calendar-container\">\n <header class=\"month-selector\">\n <button type=\"button\" class=\"selector-button\" (click)=\"incrementMonth(-1)\">\n <span class=\"material-icons icon\">chevron_left</span>\n </button>\n\n <span class=\"month-year-display\" data-testid=\"month-year-display\">{{ month }} {{ year }}</span>\n\n <button\n type=\"button\"\n class=\"selector-button\"\n
|
1104
|
+
args: [{ selector: 'ask-date-picker-calendar', template: "<div class=\"date-picker-calendar-container\">\n <header class=\"month-selector\">\n <button type=\"button\" class=\"selector-button\" (click)=\"incrementMonth(-1)\">\n <span class=\"material-icons icon\">chevron_left</span>\n </button>\n\n <span class=\"month-year-display\" data-testid=\"month-year-display\">{{ month }} {{ year }}</span>\n\n <button\n type=\"button\"\n class=\"selector-button\"\n (click)=\"incrementMonth(1)\"\n >\n <span class=\"material-icons icon\">chevron_right</span>\n </button>\n </header>\n\n <main class=\"calendar\">\n <div class=\"week-days-header\">\n <span class=\"week-day\" *ngFor=\"let weekDay of weekDays\">{{ weekDay.name }}</span>\n </div>\n\n <div class=\"days-block\" data-testid=\"days-block\">\n <button\n *ngFor=\"let day of days\"\n (click)=\"selectDate(day.timestamp)\"\n [disabled]=\"day.isFuture\"\n [ngClass]=\"{\n 'day': true,\n 'another-month': monthNumber != day.month,\n 'selected': isDaySelected(day),\n 'first': isFirstSelectedDay(day),\n 'last': isLastSelectedDay(day),\n }\"\n >\n {{ day.day }}\n </button>\n </div>\n </main>\n</div>\n", styles: [":root{--asksuite-orange: #FF5724;--white: #FFF;--grey-50: #F5F7FA;--grey-100: #E4E7EB;--grey-200: #CBD2D9;--grey-300: #9AA5B1;--grey-400: #7B8794;--grey-500: #616E7C;--grey-600: #52606D;--grey-700: #3E4C59;--grey-800: #2A3042;--grey-900: #1F2933;--yellow-50: #FFF8E2;--yellow-200: #FFECB3;--success-green: #4BAF50;--warning-yellow: #FFC107;--error-red: #E8453E;--shadow: rgba(42, 48, 66, .1607843137);--lightblue-tag: #CDF9F3;--lavender-tag: #D4DAF3;--green-tag: #CEEEAA;--pink-tag: #FBC5FF;--orange-tag: #FED5C9;--purple-tag: #DDBFE5;--yellow-tag: #FFE0B2;--blue-tag: #B2E5FD;--brown-tag: #EFC89C;--whatsapp-green: #68B35D;--facebook-blue: #0084FF;--instagram-pink: #D53E91;--google-blue: #345DC8;--telegram-blue: #34AADF;--telephone-yellow: #FECB00;--primary-background: #FFF;--secondary-background: #EFF3F8;--hover-background: #F5F7FA;--divider-background: #E4E7EB;--font-color-100: #2A3042;--font-color-200: #616E7C;--font-color-300: #9AA5B1}:root{--font-default: $font-default;--font-code: $font-code}:root{--font-xs: $font-xs;--font-sm: $font-sm;--font-md: $font-md;--font-lg: $font-lg;--font-xl: $font-xl;--font-xxl: $font-xxl}:root{--font-weight-regular: $font-weight-regular;--font-weight-medium: $font-weight-medium}:root{--radii-px: $radii-px;--radii-xs: $radii-xs;--radii-sm: $radii-sm;--radii-md: $radii-md;--radii-lg: $radii-lg;--radii-full: $radii-full}.ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.scale-in-center{animation:scale-in-center .3s ease-in-out both}@keyframes scale-in-center{0%{transform:scale(0);opacity:1}to{transform:scale(1);opacity:1}}.scale-out-center{animation:scale-out-center .3s ease-in-out both}@keyframes scale-out-center{0%{transform:scale(1);opacity:1}to{transform:scale(0);opacity:1}}.ask-tooltip{background-color:#7b8794;color:#fff;padding:4px;border-radius:8px;position:relative}.ask-tooltip>div{text-align:center!important}.ask-tooltip:after{position:absolute;content:\"\";width:10px;height:10px;background-color:inherit}.ask-tooltip.-above{margin-bottom:4px}.ask-tooltip.-above:after{bottom:-5px;left:50%;transform:translate(-50%) rotate(45deg)}.ask-tooltip.-below{margin-top:4px}.ask-tooltip.-below:after{top:-5px;left:50%;transform:translate(-50%) rotate(45deg)}.ask-tooltip.-after,.ask-tooltip.-right{margin-left:4px}.ask-tooltip.-after:after,.ask-tooltip.-right:after{left:-5px;top:50%;transform:translateY(-50%) rotate(45deg)}.ask-tooltip.-before,.ask-tooltip.-left{margin-right:4px}.ask-tooltip.-before:after,.ask-tooltip.-left:after{right:-5px;top:50%;transform:translateY(-50%) rotate(45deg)}.ask-button{padding:8px 24px;border-radius:6px;border:none;outline:none;height:48px;font-size:1rem;transition:background-color .1s,box-shadow .1s;cursor:pointer;font-weight:500;background:white;color:var(--grey-500)}.ask-button:not(.-primary,.-secondary){box-shadow:0 1px 2px #2a304229}.ask-button:not(.-primary):hover:not(:disabled){box-shadow:0 0 6px #2a304229}.ask-button:hover:not(:disabled){box-shadow:0 0 6px #ff572466}.ask-button:active:not(:disabled){background-color:#f34915}.ask-button:disabled{cursor:not-allowed;background-color:#9aa5b1}.ask-button.-primary{background:#FF5724;color:#fff}.ask-modal-header{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:0 24px 9px}.ask-modal-body{flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;padding:20px 24px;max-height:65vh;display:block}.ask-modal-footer{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0)}.material-icons{font-family:Material Icons;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-feature-settings:\"liga\";-webkit-font-smoothing:antialiased}*{box-sizing:border-box}*,button,select,textarea{font-family:Inter,sans-serif;font-weight:400}input{font-size:1rem}.ask-badge{position:relative}.ask-badge>.badge{position:absolute;display:flex;justify-content:center;align-items:center;background-color:var(--bg-color);color:#fff;font-size:12px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;border-radius:50%;box-shadow:0 2px 6px -1px #00000080}.ask-badge>.badge.-primary{--bg-color: var(--asksuite-orange)}.ask-badge>.badge.-secondary{--bg-color: var(--grey-800)}.ask-badge>.badge.-top{top:-10px}.ask-badge>.badge.-bottom{bottom:-10px}.ask-badge>.badge.-left{left:-10px}.ask-badge>.badge.-right{right:-10px}.ask-badge>.badge.-small{width:18px;height:18px;font-size:10px}.ask-badge>.badge.-regular{width:22px;height:22px;font-size:11px}.ask-badge>.badge.-large{width:28px;height:28px;font-size:12px}.ask-dropdown-top-right{margin-left:8px}.ask-dropdown-top-left{margin-right:8px}.ask-dropdown-bottom-right,.ask-dropdown-bottom-left{margin-top:8px}.date-picker-calendar-container{display:flex;flex-direction:column;padding:16px;width:320px;-webkit-user-select:none;user-select:none}.month-selector{display:flex;align-items:center;justify-content:space-between;padding:4px;background-color:var(--secondary-background);border-radius:4px;text-transform:capitalize}.month-selector>.month-year-display{font-size:.75rem;color:var(--font-color-100);font-weight:500}.selector-button{display:flex;align-items:center;justify-content:center;width:20px;height:20px;background-color:var(--primary-background);box-shadow:0 1px 2px #2a304229;outline:none;border:none;border-radius:4px;cursor:pointer}.selector-button>.icon{color:var(--font-color-100);font-size:18px}.calendar{display:flex;flex-direction:column;padding:16px 32px}.week-days-header{display:grid;grid-template-rows:auto;grid-template-columns:repeat(7,auto);place-items:center;padding-bottom:8px;border-bottom:1px solid #E4E7EB}.week-days-header>.week-day{display:flex;align-items:center;justify-content:center;font-size:.75rem;line-height:1rem;width:100%;color:var(--font-color-100)}.days-block{display:grid;grid-template-rows:repeat(6,auto);grid-template-columns:repeat(7,auto);place-items:center;row-gap:4px;color:var(--font-color-200);padding-top:4px}.days-block>.day{display:flex;align-items:center;justify-content:center;text-align:center;font-size:.75rem;line-height:1rem;width:100%;height:31px;border:none;color:var(--font-color-200);background:none;border-radius:99999px;transition:.2s background-color,.2s color,.2s font-weight}.days-block>.day:disabled{text-decoration:line-through;color:var(--font-color-300)}.days-block>.day:disabled:hover{color:var(--font-color-300);background:none;cursor:not-allowed}.days-block>.day.another-month{color:var(--font-color-300)}.days-block>.day.selected,.days-block>.day:hover{color:#ff5724;background-color:#ff57241a;cursor:pointer}.days-block>.day.selected{border-radius:0;font-weight:500}.days-block>.day.selected.first{border-top-left-radius:99999px;border-bottom-left-radius:99999px}.days-block>.day.selected.last{border-top-right-radius:99999px;border-bottom-right-radius:99999px}\n"] }]
|
1115
1105
|
}], propDecorators: { isRange: [{
|
1116
1106
|
type: Input
|
1117
1107
|
}], disableFutureDate: [{
|
@@ -1144,8 +1134,8 @@ class DatePickerComponent {
|
|
1144
1134
|
{ label: PeriodLabel.YESTERDAY, getRange: () => ({ from: formatFrom(moment().subtract(1, 'day')), to: formatTo(moment().subtract(1, 'day')) }) },
|
1145
1135
|
{ label: PeriodLabel.LAST_7_DAYS, getRange: () => ({ from: formatFrom(moment().subtract(1, 'week')), to: formatTo(moment()) }) },
|
1146
1136
|
{ label: PeriodLabel.LAST_30_DAYS, getRange: () => ({ from: formatFrom(moment().subtract(30, 'days')), to: formatTo(moment()) }) },
|
1147
|
-
{ label: PeriodLabel.THIS_MONTH, getRange: () => ({ from: formatFrom(moment().startOf('month')), to: formatTo(moment().endOf('
|
1148
|
-
{ label: PeriodLabel.LAST_QUARTER, getRange: () => ({ from: formatFrom(moment().subtract(3, 'months')), to: formatTo(moment().endOf('
|
1137
|
+
{ label: PeriodLabel.THIS_MONTH, getRange: () => ({ from: formatFrom(moment().startOf('month')), to: formatTo(moment().endOf('day')) }) },
|
1138
|
+
{ label: PeriodLabel.LAST_QUARTER, getRange: () => ({ from: formatFrom(moment().subtract(3, 'months')), to: formatTo(moment().endOf('day')) }) },
|
1149
1139
|
{ label: PeriodLabel.CUSTOM_PERIOD, getRange: () => ({}), isCustomRange: true },
|
1150
1140
|
]; }
|
1151
1141
|
get filteredPeriods() {
|