@haiilo/catalyst 6.4.0 → 6.4.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/dist/catalyst/assets/fonts/SourceSans3VF-Italic.otf.woff +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Italic.otf.woff2 +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Italic.ttf.woff +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Italic.ttf.woff2 +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Upright.otf.woff +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Upright.otf.woff2 +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Upright.ttf.woff +0 -0
- package/dist/catalyst/assets/fonts/SourceSans3VF-Upright.ttf.woff2 +0 -0
- package/dist/catalyst/catalyst.esm.js +1 -1
- package/dist/catalyst/catalyst.esm.js.map +1 -1
- package/dist/catalyst/index.esm.js +2 -2
- package/dist/catalyst/p-8929f28a.js +2 -0
- package/dist/catalyst/p-8929f28a.js.map +1 -0
- package/dist/catalyst/{p-d3a118b5.entry.js → p-c48f897d.entry.js} +2 -2
- package/dist/catalyst/p-c48f897d.entry.js.map +1 -0
- package/dist/catalyst/{p-12fa3edc.js → p-f0bcebed.js} +1 -1
- package/dist/catalyst/{p-12fa3edc.js.map → p-f0bcebed.js.map} +1 -1
- package/dist/catalyst/scss/fonts/_fonts-mixins.scss +1 -1
- package/dist/catalyst/scss/fonts/_fonts.mixins.ss3v.scss +1 -1
- package/dist/cjs/cat-alert_26.cjs.entry.js +26 -5
- package/dist/cjs/cat-alert_26.cjs.entry.js.map +1 -1
- package/dist/cjs/catalyst.cjs.js +2 -2
- package/dist/cjs/catalyst.cjs.js.map +1 -1
- package/dist/cjs/{index-b4391019.js → index-6ec4ef6d.js} +1 -1
- package/dist/cjs/{index-b4391019.js.map → index-6ec4ef6d.js.map} +1 -1
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{of-d9fa1990.js → of-eda6baf8.js} +9 -2
- package/dist/cjs/of-eda6baf8.js.map +1 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Italic.otf.woff +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Italic.otf.woff2 +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Italic.ttf.woff +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Italic.ttf.woff2 +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Upright.otf.woff +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Upright.otf.woff2 +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Upright.ttf.woff +0 -0
- package/dist/collection/assets/fonts/SourceSans3VF-Upright.ttf.woff2 +0 -0
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/cat-datepicker/cat-datepicker.config.js +21 -2
- package/dist/collection/components/cat-datepicker/cat-datepicker.config.js.map +1 -1
- package/dist/collection/components/cat-datepicker/cat-datepicker.js +3 -1
- package/dist/collection/components/cat-datepicker/cat-datepicker.js.map +1 -1
- package/dist/collection/components/cat-datepicker-inline/cat-datepicker-inline.e2e.js +1 -0
- package/dist/collection/components/cat-datepicker-inline/cat-datepicker-inline.e2e.js.map +1 -1
- package/dist/collection/components/cat-datepicker-inline/cat-datepicker-inline.spec.js +1 -0
- package/dist/collection/components/cat-datepicker-inline/cat-datepicker-inline.spec.js.map +1 -1
- package/dist/collection/components/cat-i18n/cat-i18n-registry.js +8 -1
- package/dist/collection/components/cat-i18n/cat-i18n-registry.js.map +1 -1
- package/dist/collection/scss/fonts/_fonts-mixins.scss +1 -1
- package/dist/collection/scss/fonts/_fonts.mixins.ss3v.scss +1 -1
- package/dist/components/cat-datepicker.js +3 -1
- package/dist/components/cat-datepicker.js.map +1 -1
- package/dist/components/cat-datepicker.locale.js +21 -2
- package/dist/components/cat-datepicker.locale.js.map +1 -1
- package/dist/components/cat-i18n-registry.js +8 -1
- package/dist/components/cat-i18n-registry.js.map +1 -1
- package/dist/esm/cat-alert_26.entry.js +26 -5
- package/dist/esm/cat-alert_26.entry.js.map +1 -1
- package/dist/esm/catalyst.js +3 -3
- package/dist/esm/catalyst.js.map +1 -1
- package/dist/esm/{index-2c703aa8.js → index-b424aa97.js} +1 -1
- package/dist/esm/{index-2c703aa8.js.map → index-b424aa97.js.map} +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/loader.js +2 -2
- package/dist/esm/{of-5472d434.js → of-246f9b35.js} +9 -2
- package/dist/esm/of-246f9b35.js.map +1 -0
- package/dist/types/components/cat-i18n/cat-i18n-registry.d.ts +1 -1
- package/dist/types/stencil-public-runtime.d.ts +6 -0
- package/package.json +9 -9
- package/dist/catalyst/p-d3a118b5.entry.js.map +0 -1
- package/dist/catalyst/p-dd8ae83e.js +0 -2
- package/dist/catalyst/p-dd8ae83e.js.map +0 -1
- package/dist/cjs/of-d9fa1990.js.map +0 -1
- package/dist/esm/of-5472d434.js.map +0 -1
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const of = require('./of-
|
|
5
|
+
const index = require('./index-6ec4ef6d.js');
|
|
6
|
+
const of = require('./of-eda6baf8.js');
|
|
7
7
|
|
|
8
8
|
const ObjectUnsubscribedError = of.createErrorClass((_super) => function ObjectUnsubscribedErrorImpl() {
|
|
9
9
|
_super(this);
|
|
@@ -3999,6 +3999,7 @@ var weekSelect = of.createCommonjsModule(function (module, exports) {
|
|
|
3999
3999
|
function getConfig(options, more = {}) {
|
|
4000
4000
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
4001
4001
|
const plugins = options.mode === 'week' ? [new weekSelect({})] : [];
|
|
4002
|
+
const format = dateFormat(options.mode);
|
|
4002
4003
|
return {
|
|
4003
4004
|
...more,
|
|
4004
4005
|
locale: options.locale,
|
|
@@ -4006,7 +4007,7 @@ function getConfig(options, more = {}) {
|
|
|
4006
4007
|
altInput: true,
|
|
4007
4008
|
prevArrow: '←',
|
|
4008
4009
|
nextArrow: '→',
|
|
4009
|
-
dateFormat:
|
|
4010
|
+
dateFormat: format,
|
|
4010
4011
|
altFormat: options.format,
|
|
4011
4012
|
ariaDateFormat: options.format,
|
|
4012
4013
|
mode: options.mode === 'daterange' ? 'range' : 'single',
|
|
@@ -4023,9 +4024,27 @@ function getConfig(options, more = {}) {
|
|
|
4023
4024
|
flatpickr.calendarContainer.setAttribute(key, value);
|
|
4024
4025
|
}
|
|
4025
4026
|
},
|
|
4027
|
+
onClose: function (dates, _dateStr, instance) {
|
|
4028
|
+
if (options.mode === 'daterange' && dates.length < 2) {
|
|
4029
|
+
instance.clear();
|
|
4030
|
+
}
|
|
4031
|
+
},
|
|
4026
4032
|
onChange: (dates, dateStr, flatpickr) => {
|
|
4027
4033
|
let value = dateStr || undefined;
|
|
4028
|
-
if (options.mode === '
|
|
4034
|
+
if (options.mode === 'daterange') {
|
|
4035
|
+
if (dates.length < 2) {
|
|
4036
|
+
return;
|
|
4037
|
+
}
|
|
4038
|
+
else {
|
|
4039
|
+
const start = dates[0];
|
|
4040
|
+
const end = dates[1];
|
|
4041
|
+
end.setHours(23);
|
|
4042
|
+
end.setMinutes(59);
|
|
4043
|
+
end.setSeconds(59);
|
|
4044
|
+
value = `${flatpickr.formatDate(start, format)} - ${flatpickr.formatDate(end, format)}`;
|
|
4045
|
+
}
|
|
4046
|
+
}
|
|
4047
|
+
else if (options.mode === 'week') {
|
|
4029
4048
|
value = dates[0] ? flatpickr.config.getWeek(dates[0]).toString() : undefined;
|
|
4030
4049
|
}
|
|
4031
4050
|
options.applyChange(value);
|
|
@@ -4157,7 +4176,9 @@ const CatDatepickerFlat = class {
|
|
|
4157
4176
|
onValueChanged(value) {
|
|
4158
4177
|
if (value) {
|
|
4159
4178
|
this.pickr?.setDate(value, false);
|
|
4160
|
-
this.
|
|
4179
|
+
if (this.mode !== 'daterange' || value.includes(' - ')) {
|
|
4180
|
+
this.catChange.emit(value);
|
|
4181
|
+
}
|
|
4161
4182
|
}
|
|
4162
4183
|
else {
|
|
4163
4184
|
this.pickr?.clear(false);
|