@sixbell-telco/sdk 1.2.1 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +93 -0
- package/README.md +210 -70
- package/_index.css +232 -55
- package/assets/styles/toast.css +8 -0
- package/components/data-table/expandable/expandable.component.d.ts +129 -0
- package/components/{forms/datepicker → data-table}/index.d.ts +1 -1
- package/components/data-table/public-api.d.ts +7 -0
- package/components/data-table/selection/selection.component.d.ts +41 -0
- package/components/data-table/sortable-header/sortable-header.component.d.ts +61 -0
- package/components/data-table/src/data-table-context.service.d.ts +18 -0
- package/components/data-table/src/data-table.component.d.ts +158 -0
- package/components/data-table/src/models.d.ts +58 -0
- package/components/data-table/sub-component-toggle/index.d.ts +1 -0
- package/components/data-table/sub-component-toggle/sub-component-toggle.component.d.ts +12 -0
- package/components/dropdown/dropdown-group/dropdown-group.component.d.ts +1 -1
- package/components/dropdown/dropdown-item-checkbox/dropdown-item-checkbox.component.d.ts +2 -2
- package/components/dropdown/dropdown-item-radio/dropdown-item-radio.component.d.ts +2 -2
- package/components/dropdown-menu/bar/dropdown-menu-bar-item-checkbox/dropdown-menu-bar-item-checkbox.component.d.ts +2 -2
- package/components/dropdown-menu/bar/dropdown-menu-bar-item-radio/dropdown-menu-bar-item-radio.component.d.ts +2 -2
- package/components/forms/date-picker/constants/date-picker.constants.d.ts +13 -0
- package/components/forms/date-picker/index.d.ts +5 -0
- package/components/forms/date-picker/public-api.d.ts +3 -0
- package/components/forms/date-picker/src/date-picker.component.d.ts +323 -0
- package/components/forms/date-picker/types/date-picker.types.d.ts +39 -0
- package/components/overlay/index.d.ts +5 -0
- package/components/overlay/overlay-content/overlay-content.component.d.ts +23 -0
- package/components/overlay/overlay-trigger/overlay-trigger.component.d.ts +48 -0
- package/components/overlay/public-api.d.ts +3 -0
- package/components/overlay/src/overlay.component.d.ts +158 -0
- package/components/paginator/components/pagination-item/pagination-item.component.d.ts +8 -3
- package/components/paginator/pipes/pagination.pipe.d.ts +40 -0
- package/components/paginator/public-api.d.ts +1 -0
- package/components/paginator/src/paginator.component.d.ts +14 -12
- package/components/sonner/index.d.ts +5 -0
- package/components/sonner/public-api.d.ts +2 -0
- package/components/sonner/src/sonner.component.d.ts +39 -0
- package/components/sonner/toaster/index.d.ts +5 -0
- package/components/sonner/toaster/public-api.d.ts +1 -0
- package/components/sonner/toaster/src/toaster.component.d.ts +89 -0
- package/components/table/src/table.component.d.ts +9 -6
- package/components/toast/public-api.d.ts +9 -0
- package/components/toast/services/toast.service.d.ts +3 -0
- package/components/toast/toast-message/toast-message.component.d.ts +3 -0
- package/components/toast/toasts-container/toasts-container.component.d.ts +3 -0
- package/fesm2022/sixbell-telco-sdk-components-data-table-sub-component-toggle.mjs +103 -0
- package/fesm2022/sixbell-telco-sdk-components-data-table-sub-component-toggle.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-data-table.mjs +1091 -0
- package/fesm2022/sixbell-telco-sdk-components-data-table.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-bar.mjs +6 -6
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-bar.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs +12 -10
- package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs +4 -5
- package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-date-picker.mjs +885 -0
- package/fesm2022/sixbell-telco-sdk-components-forms-date-picker.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-forms-form-error.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-forms-form-error.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs +3 -3
- package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-overlay.mjs +408 -0
- package/fesm2022/sixbell-telco-sdk-components-overlay.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-paginator.mjs +150 -35
- package/fesm2022/sixbell-telco-sdk-components-paginator.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-sonner-toaster.mjs +132 -0
- package/fesm2022/sixbell-telco-sdk-components-sonner-toaster.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-sonner.mjs +179 -0
- package/fesm2022/sixbell-telco-sdk-components-sonner.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-table.mjs +15 -6
- package/fesm2022/sixbell-telco-sdk-components-table.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-toast.mjs +14 -0
- package/fesm2022/sixbell-telco-sdk-components-toast.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-utils-date.mjs +242 -0
- package/fesm2022/sixbell-telco-sdk-utils-date.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-utils-sync.mjs +84 -0
- package/fesm2022/sixbell-telco-sdk-utils-sync.mjs.map +1 -0
- package/package.json +77 -47
- package/utils/date/index.d.ts +5 -0
- package/utils/date/public-api.d.ts +1 -0
- package/utils/date/src/date-utils.d.ts +125 -0
- package/utils/sync/index.d.ts +5 -0
- package/utils/sync/public-api.d.ts +1 -0
- package/utils/sync/src/sync.d.ts +37 -0
- package/components/forms/datepicker/public-api.d.ts +0 -2
- package/components/forms/datepicker/src/datepicker-format-month.pipe.d.ts +0 -10
- package/components/forms/datepicker/src/datepicker.component.d.ts +0 -54
- package/fesm2022/sixbell-telco-sdk-components-forms-datepicker.mjs +0 -212
- package/fesm2022/sixbell-telco-sdk-components-forms-datepicker.mjs.map +0 -1
|
@@ -1,212 +0,0 @@
|
|
|
1
|
-
import * as i0 from '@angular/core';
|
|
2
|
-
import { Pipe, input, computed, model, output, effect, Component } from '@angular/core';
|
|
3
|
-
import 'dayjs/locale/es';
|
|
4
|
-
import 'dayjs/locale/pt';
|
|
5
|
-
import * as i1 from '@angular/common';
|
|
6
|
-
import { CommonModule } from '@angular/common';
|
|
7
|
-
import { FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
8
|
-
import { InputComponent } from '@sixbell-telco/sdk/components/forms/input';
|
|
9
|
-
import { IconComponent } from '@sixbell-telco/sdk/components/icon';
|
|
10
|
-
import { matKeyboardArrowLeftOutline, matKeyboardArrowRightOutline } from '@sixbell-telco/sdk/components/icon/material/outline';
|
|
11
|
-
import dayjs from 'dayjs';
|
|
12
|
-
import customParseFormat from 'dayjs/plugin/customParseFormat';
|
|
13
|
-
import isBetween from 'dayjs/plugin/isBetween';
|
|
14
|
-
import isoWeek from 'dayjs/plugin/isoWeek';
|
|
15
|
-
|
|
16
|
-
class DatepickerFormatMonthPipe {
|
|
17
|
-
transform(value, language = 'es') {
|
|
18
|
-
// capitalize the first letter of the month
|
|
19
|
-
return value.locale(language).format('MMMM').charAt(0).toUpperCase() + value.format('MMMM YYYY').slice(1);
|
|
20
|
-
}
|
|
21
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: DatepickerFormatMonthPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
22
|
-
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "19.2.0", ngImport: i0, type: DatepickerFormatMonthPipe, isStandalone: true, name: "datepickerFormatMonth" });
|
|
23
|
-
}
|
|
24
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: DatepickerFormatMonthPipe, decorators: [{
|
|
25
|
-
type: Pipe,
|
|
26
|
-
args: [{
|
|
27
|
-
name: 'datepickerFormatMonth',
|
|
28
|
-
standalone: true,
|
|
29
|
-
}]
|
|
30
|
-
}] });
|
|
31
|
-
|
|
32
|
-
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
33
|
-
class DatepickerComponent {
|
|
34
|
-
iconArrowLeft = matKeyboardArrowLeftOutline;
|
|
35
|
-
iconArrowRight = matKeyboardArrowRightOutline;
|
|
36
|
-
format = input('DD/MM/YYYY');
|
|
37
|
-
language = input('es');
|
|
38
|
-
weekFromLanguage = computed(() => {
|
|
39
|
-
if (this.language() === 'en') {
|
|
40
|
-
return ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'];
|
|
41
|
-
}
|
|
42
|
-
else if (this.language() === 'pt') {
|
|
43
|
-
return ['Seg', 'Ter', 'Qua', 'Qui', 'Sex', 'Sáb', 'Dom'];
|
|
44
|
-
}
|
|
45
|
-
else {
|
|
46
|
-
return ['Lun', 'Mar', 'Mié', 'Jue', 'Vie', 'Sáb', 'Dom'];
|
|
47
|
-
}
|
|
48
|
-
});
|
|
49
|
-
label = input('');
|
|
50
|
-
range = input(null); // example: [1, 'month']
|
|
51
|
-
minDate = input(null);
|
|
52
|
-
maxDate = input(null);
|
|
53
|
-
disableUntil = input('');
|
|
54
|
-
disableFrom = input('');
|
|
55
|
-
current = model(dayjs().locale(this.language()).format(this.format()));
|
|
56
|
-
dateUpdated = output();
|
|
57
|
-
synchronizedPickersEffect = effect(() => {
|
|
58
|
-
if (this.minDate() || this.maxDate()) {
|
|
59
|
-
this.refresh();
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
daysOfMonth = [];
|
|
63
|
-
monthAndYearLabel = dayjs().locale(this.language());
|
|
64
|
-
isOpen = false;
|
|
65
|
-
// Form control properties
|
|
66
|
-
parentForm = input(null);
|
|
67
|
-
formControlName = input('');
|
|
68
|
-
get formField() {
|
|
69
|
-
if (!this.parentForm())
|
|
70
|
-
return null;
|
|
71
|
-
return this.parentForm()?.get(this.formControlName());
|
|
72
|
-
}
|
|
73
|
-
// ControlValueAccessor attributes
|
|
74
|
-
onControlChange = () => { };
|
|
75
|
-
onControlTouch = () => { };
|
|
76
|
-
disabled = model(false);
|
|
77
|
-
// ControlValueAccessor methods
|
|
78
|
-
writeValue(obj) {
|
|
79
|
-
this.current.set(obj);
|
|
80
|
-
}
|
|
81
|
-
registerOnChange(fn) {
|
|
82
|
-
this.onControlChange = fn;
|
|
83
|
-
}
|
|
84
|
-
registerOnTouched(fn) {
|
|
85
|
-
this.onControlTouch = fn;
|
|
86
|
-
}
|
|
87
|
-
setDisabledState(isDisabled) {
|
|
88
|
-
this.disabled.set(isDisabled);
|
|
89
|
-
}
|
|
90
|
-
constructor() {
|
|
91
|
-
dayjs.extend(isoWeek);
|
|
92
|
-
dayjs.extend(customParseFormat);
|
|
93
|
-
dayjs.extend(isBetween);
|
|
94
|
-
}
|
|
95
|
-
ngOnInit() {
|
|
96
|
-
if (this.current()) {
|
|
97
|
-
this.getDaysFromDate(dayjs(this.current(), this.format()).locale(this.language()).month() + 1, dayjs(this.current(), this.format()).locale(this.language()).year());
|
|
98
|
-
}
|
|
99
|
-
else {
|
|
100
|
-
const d = new Date();
|
|
101
|
-
this.getDaysFromDate(d.getMonth() + 1, d.getFullYear());
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
toggleDatepicker() {
|
|
105
|
-
if (this.range()) {
|
|
106
|
-
this.refresh();
|
|
107
|
-
}
|
|
108
|
-
this.isOpen = !this.isOpen;
|
|
109
|
-
this.onControlTouch();
|
|
110
|
-
}
|
|
111
|
-
getDaysFromDate(month, year) {
|
|
112
|
-
const startDate = dayjs(`${year}/${month}/01`).locale(this.language());
|
|
113
|
-
const endDate = startDate.clone().endOf('month');
|
|
114
|
-
this.monthAndYearLabel = startDate;
|
|
115
|
-
const diffDays = endDate.diff(startDate, 'days', true);
|
|
116
|
-
const numberDays = Math.round(diffDays);
|
|
117
|
-
const days = Object.keys([...Array(numberDays)]).map((a) => {
|
|
118
|
-
const d = parseInt(a) + 1;
|
|
119
|
-
const day = dayjs(`${year}-${month}-${d}`).locale(this.language());
|
|
120
|
-
const range = this.range();
|
|
121
|
-
const dateRange = this.minDate() ?? this.maxDate() ?? '';
|
|
122
|
-
return {
|
|
123
|
-
name: day.format('dddd'),
|
|
124
|
-
value: d, // Change the value to a number
|
|
125
|
-
indexWeek: day.isoWeekday(),
|
|
126
|
-
disabled: range ? this.shouldDisableDayByRange(day, dateRange, range[0], range[1]) : this.shouldDisableDay(day),
|
|
127
|
-
date: day.format(this.format()),
|
|
128
|
-
};
|
|
129
|
-
});
|
|
130
|
-
this.daysOfMonth = days;
|
|
131
|
-
}
|
|
132
|
-
shouldDisableDayByRange(day, from, quantity, unit) {
|
|
133
|
-
if (!from) {
|
|
134
|
-
return false;
|
|
135
|
-
}
|
|
136
|
-
if (this.maxDate()) {
|
|
137
|
-
// If maxDate is true, disables all dates AFTER 'from' date
|
|
138
|
-
return !day.isBetween(dayjs(from, this.format()).locale(this.language()).subtract(quantity, unit), dayjs(from, this.format()).locale(this.language()), null, '[]');
|
|
139
|
-
}
|
|
140
|
-
if (this.minDate()) {
|
|
141
|
-
// If minDate is true, disables all dates BEFORE 'from' date
|
|
142
|
-
return !day.isBetween(dayjs(from, this.format()).locale(this.language()), dayjs(from, this.format()).locale(this.language()).add(quantity, unit), null, '[]');
|
|
143
|
-
}
|
|
144
|
-
// Disables all dates BEFORE and AFTER 'from' date
|
|
145
|
-
return !day.isBetween(dayjs(from, this.format()).locale(this.language()).subtract(quantity, unit), dayjs(from, this.format()).locale(this.language()).add(quantity, unit), null, '[]');
|
|
146
|
-
}
|
|
147
|
-
shouldDisableDay(day) {
|
|
148
|
-
if (this.disableUntil() && this.disableFrom()) {
|
|
149
|
-
return !day.isBetween(dayjs(this.disableUntil(), this.format()).locale(this.language()).subtract(1, 'day'), dayjs(this.disableFrom(), this.format()).locale(this.language()).add(1, 'day'));
|
|
150
|
-
}
|
|
151
|
-
if (this.disableUntil() && !this.disableFrom()) {
|
|
152
|
-
return day.isBefore(dayjs(this.disableUntil(), this.format()).locale(this.language()));
|
|
153
|
-
}
|
|
154
|
-
if (this.disableFrom() && !this.disableUntil()) {
|
|
155
|
-
return day.isAfter(dayjs(this.disableFrom(), this.format()).locale(this.language()));
|
|
156
|
-
}
|
|
157
|
-
return false;
|
|
158
|
-
}
|
|
159
|
-
refresh() {
|
|
160
|
-
// Used to force a refresh on the calendar
|
|
161
|
-
this.changeMonth(true);
|
|
162
|
-
this.changeMonth(false);
|
|
163
|
-
}
|
|
164
|
-
changeMonth(flag) {
|
|
165
|
-
if (flag) {
|
|
166
|
-
const prevDate = this.monthAndYearLabel.clone().subtract(1, 'month');
|
|
167
|
-
this.getDaysFromDate(prevDate.format('MM'), prevDate.format('YYYY'));
|
|
168
|
-
}
|
|
169
|
-
else {
|
|
170
|
-
const nextDate = this.monthAndYearLabel.clone().add(1, 'month');
|
|
171
|
-
this.getDaysFromDate(nextDate.format('MM'), nextDate.format('YYYY'));
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
handleSelectDay(day) {
|
|
175
|
-
if (day.disabled)
|
|
176
|
-
return;
|
|
177
|
-
const monthYear = this.monthAndYearLabel.format('YYYY-MM');
|
|
178
|
-
const parsedDay = `${monthYear}-${day.value}`;
|
|
179
|
-
const date = dayjs(parsedDay).locale(this.language()).format(this.format());
|
|
180
|
-
this.current.set(date);
|
|
181
|
-
this.dateUpdated.emit(date);
|
|
182
|
-
this.onControlChange(date);
|
|
183
|
-
if (!this.range()) {
|
|
184
|
-
this.toggleDatepicker();
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: DatepickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
188
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.0", type: DatepickerComponent, isStandalone: true, selector: "st-datepicker", inputs: { format: { classPropertyName: "format", publicName: "format", isSignal: true, isRequired: false, transformFunction: null }, language: { classPropertyName: "language", publicName: "language", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, range: { classPropertyName: "range", publicName: "range", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, disableUntil: { classPropertyName: "disableUntil", publicName: "disableUntil", isSignal: true, isRequired: false, transformFunction: null }, disableFrom: { classPropertyName: "disableFrom", publicName: "disableFrom", isSignal: true, isRequired: false, transformFunction: null }, current: { classPropertyName: "current", publicName: "current", isSignal: true, isRequired: false, transformFunction: null }, parentForm: { classPropertyName: "parentForm", publicName: "parentForm", isSignal: true, isRequired: false, transformFunction: null }, formControlName: { classPropertyName: "formControlName", publicName: "formControlName", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { current: "currentChange", dateUpdated: "dateUpdated", disabled: "disabledChange" }, providers: [
|
|
189
|
-
{
|
|
190
|
-
provide: NG_VALUE_ACCESSOR,
|
|
191
|
-
useExisting: DatepickerComponent,
|
|
192
|
-
multi: true,
|
|
193
|
-
},
|
|
194
|
-
], ngImport: i0, template: "<!-- eslint-disable @angular-eslint/template/click-events-have-key-events -->\n<!-- eslint-disable @angular-eslint/template/interactive-supports-focus -->\n<st-input (click)=\"toggleDatepicker()\" [(value)]=\"current\" [readonly]=\"true\" [label]=\"label()\" />\n<div class=\"datepicker-container\">\n\t<div [class]=\"isOpen ? 'calendar-wrapper active' : 'calendar-wrapper inactive'\">\n\t\t<div class=\"calendar-header\">\n\t\t\t<button (click)=\"changeMonth(true)\" class=\"btn-prev\">\n\t\t\t\t<!-- <img src=\"assets/icons/calendar/left.svg\" /> -->\n\t\t\t\t<st-icon class=\"text-secondary-content\" [icon]=\"iconArrowLeft\" color=\"inherit\">></st-icon>\n\t\t\t</button>\n\t\t\t<h1>{{ monthAndYearLabel | datepickerFormatMonth: language() }}</h1>\n\t\t\t<button (click)=\"changeMonth(false)\" class=\"btn-next\">\n\t\t\t\t<!-- <img src=\"assets/icons/calendar/right.svg\" /> -->\n\t\t\t\t<st-icon class=\"text-secondary-content\" [icon]=\"iconArrowRight\" color=\"inherit\"></st-icon>\n\t\t\t</button>\n\t\t</div>\n\t\t<ol class=\"days\">\n\t\t\t@for (day of weekFromLanguage(); track day) {\n\t\t\t\t<li class=\"day-name\">{{ day | slice: 0 : 1 }}</li>\n\t\t\t}\n\n\t\t\t@for (day of daysOfMonth; track day.value) {\n\t\t\t\t<li\n\t\t\t\t\tclass=\"day\"\n\t\t\t\t\t(click)=\"handleSelectDay(day)\"\n\t\t\t\t\t[ngClass]=\"{ active: day.date === current(), disabled: day.disabled }\"\n\t\t\t\t\t[style.gridColumnStart]=\"$first ? day.indexWeek : 'auto'\"\n\t\t\t\t>\n\t\t\t\t\t<span>{{ day.value }}</span>\n\t\t\t\t</li>\n\t\t\t}\n\t\t</ol>\n\t</div>\n</div>\n", styles: [".datepicker-container{position:relative}.calendar-wrapper{padding:20px;border:solid 1px #eaeaea;background:#fff;box-shadow:0 4px 15px #0000001a;border-radius:15px;position:absolute;top:5px;left:0;z-index:9999;max-width:280px}.calendar-wrapper.active{display:block}.calendar-wrapper.inactive{display:none}.calendar-header{display:flex;width:100%;justify-content:space-between;align-items:center;align-content:center;padding:10px 0 0;margin-bottom:10px}.calendar-header h1{width:100%;font-style:normal;font-weight:500;font-size:15px;line-height:18px;color:#777675;text-align:center;font-family:Roboto,sans-serif}.calendar-header button{cursor:pointer;background-color:transparent;border:0;width:40px;display:flex;justify-content:center;align-items:center}.days{list-style:none;display:grid;grid-template-columns:repeat(7,34px);margin:0;padding:0;gap:0}.days .day-name{font-weight:700;margin-bottom:2px;padding:4px;text-align:center;font-style:normal;font-size:15px;color:#4dd6ed;margin-top:10px}.days .day{display:flex;justify-content:center;align-items:center;width:100%;height:34px;padding:.25rem;font-size:15px;cursor:pointer;color:#636363}.days .day:hover{font-weight:600;background:#4dd6ed;border-radius:50%;color:#fff}.days .day.disabled{color:#ccc}.days .day.active{font-weight:600;background:#4dd6ed;border-radius:50%;color:#fff}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "pipe", type: i1.SlicePipe, name: "slice" }, { kind: "ngmodule", type: FormsModule }, { kind: "component", type: InputComponent, selector: "st-input", inputs: ["variant", "size", "label", "type", "name", "placeholder", "readonly", "focus", "justNumbers", "ghost", "value", "parentForm", "formControlName", "disabled", "debounceTime"], outputs: ["valueChange", "disabledChange", "enterPressed", "blurred", "valueDebounced"] }, { kind: "pipe", type: DatepickerFormatMonthPipe, name: "datepickerFormatMonth" }, { kind: "component", type: IconComponent, selector: "st-icon", inputs: ["color", "size", "icon"] }] });
|
|
195
|
-
}
|
|
196
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.0", ngImport: i0, type: DatepickerComponent, decorators: [{
|
|
197
|
-
type: Component,
|
|
198
|
-
args: [{ selector: 'st-datepicker', imports: [CommonModule, FormsModule, InputComponent, DatepickerFormatMonthPipe, IconComponent], providers: [
|
|
199
|
-
{
|
|
200
|
-
provide: NG_VALUE_ACCESSOR,
|
|
201
|
-
useExisting: DatepickerComponent,
|
|
202
|
-
multi: true,
|
|
203
|
-
},
|
|
204
|
-
], template: "<!-- eslint-disable @angular-eslint/template/click-events-have-key-events -->\n<!-- eslint-disable @angular-eslint/template/interactive-supports-focus -->\n<st-input (click)=\"toggleDatepicker()\" [(value)]=\"current\" [readonly]=\"true\" [label]=\"label()\" />\n<div class=\"datepicker-container\">\n\t<div [class]=\"isOpen ? 'calendar-wrapper active' : 'calendar-wrapper inactive'\">\n\t\t<div class=\"calendar-header\">\n\t\t\t<button (click)=\"changeMonth(true)\" class=\"btn-prev\">\n\t\t\t\t<!-- <img src=\"assets/icons/calendar/left.svg\" /> -->\n\t\t\t\t<st-icon class=\"text-secondary-content\" [icon]=\"iconArrowLeft\" color=\"inherit\">></st-icon>\n\t\t\t</button>\n\t\t\t<h1>{{ monthAndYearLabel | datepickerFormatMonth: language() }}</h1>\n\t\t\t<button (click)=\"changeMonth(false)\" class=\"btn-next\">\n\t\t\t\t<!-- <img src=\"assets/icons/calendar/right.svg\" /> -->\n\t\t\t\t<st-icon class=\"text-secondary-content\" [icon]=\"iconArrowRight\" color=\"inherit\"></st-icon>\n\t\t\t</button>\n\t\t</div>\n\t\t<ol class=\"days\">\n\t\t\t@for (day of weekFromLanguage(); track day) {\n\t\t\t\t<li class=\"day-name\">{{ day | slice: 0 : 1 }}</li>\n\t\t\t}\n\n\t\t\t@for (day of daysOfMonth; track day.value) {\n\t\t\t\t<li\n\t\t\t\t\tclass=\"day\"\n\t\t\t\t\t(click)=\"handleSelectDay(day)\"\n\t\t\t\t\t[ngClass]=\"{ active: day.date === current(), disabled: day.disabled }\"\n\t\t\t\t\t[style.gridColumnStart]=\"$first ? day.indexWeek : 'auto'\"\n\t\t\t\t>\n\t\t\t\t\t<span>{{ day.value }}</span>\n\t\t\t\t</li>\n\t\t\t}\n\t\t</ol>\n\t</div>\n</div>\n", styles: [".datepicker-container{position:relative}.calendar-wrapper{padding:20px;border:solid 1px #eaeaea;background:#fff;box-shadow:0 4px 15px #0000001a;border-radius:15px;position:absolute;top:5px;left:0;z-index:9999;max-width:280px}.calendar-wrapper.active{display:block}.calendar-wrapper.inactive{display:none}.calendar-header{display:flex;width:100%;justify-content:space-between;align-items:center;align-content:center;padding:10px 0 0;margin-bottom:10px}.calendar-header h1{width:100%;font-style:normal;font-weight:500;font-size:15px;line-height:18px;color:#777675;text-align:center;font-family:Roboto,sans-serif}.calendar-header button{cursor:pointer;background-color:transparent;border:0;width:40px;display:flex;justify-content:center;align-items:center}.days{list-style:none;display:grid;grid-template-columns:repeat(7,34px);margin:0;padding:0;gap:0}.days .day-name{font-weight:700;margin-bottom:2px;padding:4px;text-align:center;font-style:normal;font-size:15px;color:#4dd6ed;margin-top:10px}.days .day{display:flex;justify-content:center;align-items:center;width:100%;height:34px;padding:.25rem;font-size:15px;cursor:pointer;color:#636363}.days .day:hover{font-weight:600;background:#4dd6ed;border-radius:50%;color:#fff}.days .day.disabled{color:#ccc}.days .day.active{font-weight:600;background:#4dd6ed;border-radius:50%;color:#fff}\n"] }]
|
|
205
|
-
}], ctorParameters: () => [] });
|
|
206
|
-
|
|
207
|
-
/**
|
|
208
|
-
* Generated bundle index. Do not edit.
|
|
209
|
-
*/
|
|
210
|
-
|
|
211
|
-
export { DatepickerComponent, DatepickerFormatMonthPipe };
|
|
212
|
-
//# sourceMappingURL=sixbell-telco-sdk-components-forms-datepicker.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sixbell-telco-sdk-components-forms-datepicker.mjs","sources":["../../../projects/sdk/components/forms/datepicker/src/datepicker-format-month.pipe.ts","../../../projects/sdk/components/forms/datepicker/src/datepicker.component.ts","../../../projects/sdk/components/forms/datepicker/src/datepicker.component.html","../../../projects/sdk/components/forms/datepicker/sixbell-telco-sdk-components-forms-datepicker.ts"],"sourcesContent":["import { Pipe, PipeTransform } from '@angular/core';\nimport dayjs from 'dayjs';\nimport 'dayjs/locale/es';\nimport 'dayjs/locale/pt';\n\n@Pipe({\n\tname: 'datepickerFormatMonth',\n\tstandalone: true,\n})\nexport class DatepickerFormatMonthPipe implements PipeTransform {\n\ttransform(value: dayjs.Dayjs, language: string = 'es'): string {\n\t\t// capitalize the first letter of the month\n\t\treturn value.locale(language).format('MMMM').charAt(0).toUpperCase() + value.format('MMMM YYYY').slice(1);\n\t}\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { CommonModule } from '@angular/common';\nimport { Component, computed, effect, input, model, OnInit, output } from '@angular/core';\nimport { ControlValueAccessor, FormControl, FormGroup, FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { InputComponent } from '@sixbell-telco/sdk/components/forms/input';\nimport { IconComponent } from '@sixbell-telco/sdk/components/icon';\nimport { matKeyboardArrowLeftOutline, matKeyboardArrowRightOutline } from '@sixbell-telco/sdk/components/icon/material/outline';\nimport dayjs from 'dayjs';\nimport 'dayjs/locale/es';\nimport 'dayjs/locale/pt';\nimport customParseFormat from 'dayjs/plugin/customParseFormat';\nimport isBetween from 'dayjs/plugin/isBetween';\nimport isoWeek from 'dayjs/plugin/isoWeek';\nimport { DatepickerFormatMonthPipe } from './datepicker-format-month.pipe';\n\ntype DayOfMonth = {\n\tname: string;\n\tvalue: number;\n\tindexWeek: number;\n\tdisabled: boolean;\n\tdate: string;\n};\n\n@Component({\n\tselector: 'st-datepicker',\n\ttemplateUrl: './datepicker.component.html',\n\tstyleUrls: ['./datepicker.component.scss'],\n\timports: [CommonModule, FormsModule, InputComponent, DatepickerFormatMonthPipe, IconComponent],\n\tproviders: [\n\t\t{\n\t\t\tprovide: NG_VALUE_ACCESSOR,\n\t\t\tuseExisting: DatepickerComponent,\n\t\t\tmulti: true,\n\t\t},\n\t],\n})\nexport class DatepickerComponent implements OnInit, ControlValueAccessor {\n\ticonArrowLeft = matKeyboardArrowLeftOutline;\n\ticonArrowRight = matKeyboardArrowRightOutline;\n\n\tformat = input<string>('DD/MM/YYYY');\n\tlanguage = input<string>('es');\n\n\tweekFromLanguage = computed(() => {\n\t\tif (this.language() === 'en') {\n\t\t\treturn ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'];\n\t\t} else if (this.language() === 'pt') {\n\t\t\treturn ['Seg', 'Ter', 'Qua', 'Qui', 'Sex', 'Sáb', 'Dom'];\n\t\t} else {\n\t\t\treturn ['Lun', 'Mar', 'Mié', 'Jue', 'Vie', 'Sáb', 'Dom'];\n\t\t}\n\t});\n\n\tlabel = input<string>('');\n\trange = input<[number, dayjs.ManipulateType] | null>(null); // example: [1, 'month']\n\tminDate = input<string | null>(null);\n\tmaxDate = input<string | null>(null);\n\tdisableUntil = input<string>('');\n\tdisableFrom = input<string>('');\n\n\tcurrent = model<string>(dayjs().locale(this.language()).format(this.format()));\n\tdateUpdated = output<string>();\n\tsynchronizedPickersEffect = effect(() => {\n\t\tif (this.minDate() || this.maxDate()) {\n\t\t\tthis.refresh();\n\t\t}\n\t});\n\n\tdaysOfMonth: DayOfMonth[] = [];\n\tmonthAndYearLabel: dayjs.Dayjs = dayjs().locale(this.language());\n\tisOpen: boolean = false;\n\n\t// Form control properties\n\tparentForm = input<FormGroup | null>(null);\n\tformControlName = input<string>('');\n\n\tget formField(): FormControl | null {\n\t\tif (!this.parentForm()) return null;\n\t\treturn this.parentForm()?.get(this.formControlName()) as FormControl;\n\t}\n\t// ControlValueAccessor attributes\n\tprivate onControlChange: any = () => {};\n\tprivate onControlTouch: any = () => {};\n\tdisabled = model<boolean>(false);\n\n\t// ControlValueAccessor methods\n\twriteValue(obj: string): void {\n\t\tthis.current.set(obj);\n\t}\n\n\tregisterOnChange(fn: any): void {\n\t\tthis.onControlChange = fn;\n\t}\n\n\tregisterOnTouched(fn: any): void {\n\t\tthis.onControlTouch = fn;\n\t}\n\n\tsetDisabledState(isDisabled: boolean): void {\n\t\tthis.disabled.set(isDisabled);\n\t}\n\n\tconstructor() {\n\t\tdayjs.extend(isoWeek);\n\t\tdayjs.extend(customParseFormat);\n\t\tdayjs.extend(isBetween);\n\t}\n\n\tngOnInit(): void {\n\t\tif (this.current()) {\n\t\t\tthis.getDaysFromDate(\n\t\t\t\tdayjs(this.current(), this.format()).locale(this.language()).month() + 1,\n\t\t\t\tdayjs(this.current(), this.format()).locale(this.language()).year(),\n\t\t\t);\n\t\t} else {\n\t\t\tconst d = new Date();\n\t\t\tthis.getDaysFromDate(d.getMonth() + 1, d.getFullYear());\n\t\t}\n\t}\n\n\ttoggleDatepicker() {\n\t\tif (this.range()) {\n\t\t\tthis.refresh();\n\t\t}\n\t\tthis.isOpen = !this.isOpen;\n\t\tthis.onControlTouch();\n\t}\n\n\tprivate getDaysFromDate(month: string | number, year: string | number) {\n\t\tconst startDate = dayjs(`${year}/${month}/01`).locale(this.language());\n\t\tconst endDate = startDate.clone().endOf('month');\n\t\tthis.monthAndYearLabel = startDate;\n\n\t\tconst diffDays = endDate.diff(startDate, 'days', true);\n\t\tconst numberDays = Math.round(diffDays);\n\n\t\tconst days: DayOfMonth[] = Object.keys([...Array(numberDays)]).map((a: string) => {\n\t\t\tconst d = parseInt(a) + 1;\n\t\t\tconst day = dayjs(`${year}-${month}-${d}`).locale(this.language());\n\n\t\t\tconst range = this.range();\n\t\t\tconst dateRange = this.minDate() ?? this.maxDate() ?? '';\n\n\t\t\treturn {\n\t\t\t\tname: day.format('dddd'),\n\t\t\t\tvalue: d, // Change the value to a number\n\t\t\t\tindexWeek: day.isoWeekday(),\n\t\t\t\tdisabled: range ? this.shouldDisableDayByRange(day, dateRange, range[0], range[1]) : this.shouldDisableDay(day),\n\t\t\t\tdate: day.format(this.format()),\n\t\t\t};\n\t\t});\n\n\t\tthis.daysOfMonth = days;\n\t}\n\n\tprivate shouldDisableDayByRange(day: dayjs.Dayjs, from: string, quantity: number, unit: dayjs.ManipulateType) {\n\t\tif (!from) {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (this.maxDate()) {\n\t\t\t// If maxDate is true, disables all dates AFTER 'from' date\n\t\t\treturn !day.isBetween(\n\t\t\t\tdayjs(from, this.format()).locale(this.language()).subtract(quantity, unit),\n\t\t\t\tdayjs(from, this.format()).locale(this.language()),\n\t\t\t\tnull,\n\t\t\t\t'[]',\n\t\t\t);\n\t\t}\n\n\t\tif (this.minDate()) {\n\t\t\t// If minDate is true, disables all dates BEFORE 'from' date\n\t\t\treturn !day.isBetween(\n\t\t\t\tdayjs(from, this.format()).locale(this.language()),\n\t\t\t\tdayjs(from, this.format()).locale(this.language()).add(quantity, unit),\n\t\t\t\tnull,\n\t\t\t\t'[]',\n\t\t\t);\n\t\t}\n\n\t\t// Disables all dates BEFORE and AFTER 'from' date\n\t\treturn !day.isBetween(\n\t\t\tdayjs(from, this.format()).locale(this.language()).subtract(quantity, unit),\n\t\t\tdayjs(from, this.format()).locale(this.language()).add(quantity, unit),\n\t\t\tnull,\n\t\t\t'[]',\n\t\t);\n\t}\n\n\tprivate shouldDisableDay(day: dayjs.Dayjs) {\n\t\tif (this.disableUntil() && this.disableFrom()) {\n\t\t\treturn !day.isBetween(\n\t\t\t\tdayjs(this.disableUntil(), this.format()).locale(this.language()).subtract(1, 'day'),\n\t\t\t\tdayjs(this.disableFrom(), this.format()).locale(this.language()).add(1, 'day'),\n\t\t\t);\n\t\t}\n\n\t\tif (this.disableUntil() && !this.disableFrom()) {\n\t\t\treturn day.isBefore(dayjs(this.disableUntil(), this.format()).locale(this.language()));\n\t\t}\n\n\t\tif (this.disableFrom() && !this.disableUntil()) {\n\t\t\treturn day.isAfter(dayjs(this.disableFrom(), this.format()).locale(this.language()));\n\t\t}\n\n\t\treturn false;\n\t}\n\n\tprivate refresh() {\n\t\t// Used to force a refresh on the calendar\n\t\tthis.changeMonth(true);\n\t\tthis.changeMonth(false);\n\t}\n\n\tchangeMonth(flag: boolean) {\n\t\tif (flag) {\n\t\t\tconst prevDate = this.monthAndYearLabel.clone().subtract(1, 'month');\n\t\t\tthis.getDaysFromDate(prevDate.format('MM'), prevDate.format('YYYY'));\n\t\t} else {\n\t\t\tconst nextDate = this.monthAndYearLabel.clone().add(1, 'month');\n\t\t\tthis.getDaysFromDate(nextDate.format('MM'), nextDate.format('YYYY'));\n\t\t}\n\t}\n\n\thandleSelectDay(day: DayOfMonth) {\n\t\tif (day.disabled) return;\n\n\t\tconst monthYear = this.monthAndYearLabel.format('YYYY-MM');\n\t\tconst parsedDay = `${monthYear}-${day.value}`;\n\t\tconst date = dayjs(parsedDay).locale(this.language()).format(this.format());\n\t\tthis.current.set(date);\n\t\tthis.dateUpdated.emit(date);\n\t\tthis.onControlChange(date);\n\t\tif (!this.range()) {\n\t\t\tthis.toggleDatepicker();\n\t\t}\n\t}\n}\n","<!-- eslint-disable @angular-eslint/template/click-events-have-key-events -->\n<!-- eslint-disable @angular-eslint/template/interactive-supports-focus -->\n<st-input (click)=\"toggleDatepicker()\" [(value)]=\"current\" [readonly]=\"true\" [label]=\"label()\" />\n<div class=\"datepicker-container\">\n\t<div [class]=\"isOpen ? 'calendar-wrapper active' : 'calendar-wrapper inactive'\">\n\t\t<div class=\"calendar-header\">\n\t\t\t<button (click)=\"changeMonth(true)\" class=\"btn-prev\">\n\t\t\t\t<!-- <img src=\"assets/icons/calendar/left.svg\" /> -->\n\t\t\t\t<st-icon class=\"text-secondary-content\" [icon]=\"iconArrowLeft\" color=\"inherit\">></st-icon>\n\t\t\t</button>\n\t\t\t<h1>{{ monthAndYearLabel | datepickerFormatMonth: language() }}</h1>\n\t\t\t<button (click)=\"changeMonth(false)\" class=\"btn-next\">\n\t\t\t\t<!-- <img src=\"assets/icons/calendar/right.svg\" /> -->\n\t\t\t\t<st-icon class=\"text-secondary-content\" [icon]=\"iconArrowRight\" color=\"inherit\"></st-icon>\n\t\t\t</button>\n\t\t</div>\n\t\t<ol class=\"days\">\n\t\t\t@for (day of weekFromLanguage(); track day) {\n\t\t\t\t<li class=\"day-name\">{{ day | slice: 0 : 1 }}</li>\n\t\t\t}\n\n\t\t\t@for (day of daysOfMonth; track day.value) {\n\t\t\t\t<li\n\t\t\t\t\tclass=\"day\"\n\t\t\t\t\t(click)=\"handleSelectDay(day)\"\n\t\t\t\t\t[ngClass]=\"{ active: day.date === current(), disabled: day.disabled }\"\n\t\t\t\t\t[style.gridColumnStart]=\"$first ? day.indexWeek : 'auto'\"\n\t\t\t\t>\n\t\t\t\t\t<span>{{ day.value }}</span>\n\t\t\t\t</li>\n\t\t\t}\n\t\t</ol>\n\t</div>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;MASa,yBAAyB,CAAA;AACrC,IAAA,SAAS,CAAC,KAAkB,EAAE,QAAA,GAAmB,IAAI,EAAA;;AAEpD,QAAA,OAAO,KAAK,CA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