@onereach/ui-components 3.0.4-beta.2487.0 → 3.0.4-beta.2500.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/dist/bundled/v2/{OrDateTimePicker-11b6d4dd.js → OrDateTimePicker-5a379f88.js} +85 -19
- package/dist/bundled/v2/components/index.js +1 -1
- package/dist/bundled/v2/components/or-date-time-picker-v3/OrDateTimePicker.vue.d.ts +20 -1
- package/dist/bundled/v2/components/or-date-time-picker-v3/index.js +1 -1
- package/dist/bundled/v2/components/or-date-time-picker-v3/partials/or-date-time-picker-day-select/OrDateTimePickerDaySelect.vue.d.ts +12 -0
- package/dist/bundled/v2/components/or-date-time-picker-v3/partials/or-date-time-picker-month-select/OrDateTimePickerMonthSelect.vue.d.ts +12 -0
- package/dist/bundled/v2/components/or-date-time-picker-v3/partials/or-date-time-picker-time-select/OrDateTimePickerTimeSelect.vue.d.ts +12 -0
- package/dist/bundled/v2/index.js +2 -2
- package/dist/bundled/v3/{OrDateTimePicker.vue_vue_type_script_lang-b9bc77aa.js → OrDateTimePicker.vue_vue_type_script_lang-77c42110.js} +65 -8
- package/dist/bundled/v3/components/index.js +1 -1
- package/dist/bundled/v3/components/or-date-time-picker-v3/OrDateTimePicker.vue.d.ts +20 -1
- package/dist/bundled/v3/components/or-date-time-picker-v3/index.js +1 -1
- package/dist/bundled/v3/components/or-date-time-picker-v3/partials/or-date-time-picker-day-select/OrDateTimePickerDaySelect.vue.d.ts +12 -0
- package/dist/bundled/v3/components/or-date-time-picker-v3/partials/or-date-time-picker-month-select/OrDateTimePickerMonthSelect.vue.d.ts +12 -0
- package/dist/bundled/v3/components/or-date-time-picker-v3/partials/or-date-time-picker-time-select/OrDateTimePickerTimeSelect.vue.d.ts +12 -0
- package/dist/bundled/v3/index.js +26 -19
- package/dist/esm/v2/{OrDateTimePicker-7411ea1f.js → OrDateTimePicker-9b277e74.js} +88 -22
- package/dist/esm/v2/components/index.js +1 -1
- package/dist/esm/v2/components/or-date-time-picker-v3/OrDateTimePicker.vue.d.ts +20 -1
- package/dist/esm/v2/components/or-date-time-picker-v3/index.js +4 -4
- package/dist/esm/v2/components/or-date-time-picker-v3/partials/or-date-time-picker-day-select/OrDateTimePickerDaySelect.vue.d.ts +12 -0
- package/dist/esm/v2/components/or-date-time-picker-v3/partials/or-date-time-picker-month-select/OrDateTimePickerMonthSelect.vue.d.ts +12 -0
- package/dist/esm/v2/components/or-date-time-picker-v3/partials/or-date-time-picker-time-select/OrDateTimePickerTimeSelect.vue.d.ts +12 -0
- package/dist/esm/v2/index.js +1 -1
- package/dist/esm/v3/{OrDateTimePicker-966d5b1d.js → OrDateTimePicker-46b452b3.js} +91 -27
- package/dist/esm/v3/components/index.js +1 -1
- package/dist/esm/v3/components/or-date-time-picker-v3/OrDateTimePicker.vue.d.ts +20 -1
- package/dist/esm/v3/components/or-date-time-picker-v3/index.js +3 -3
- package/dist/esm/v3/components/or-date-time-picker-v3/partials/or-date-time-picker-day-select/OrDateTimePickerDaySelect.vue.d.ts +12 -0
- package/dist/esm/v3/components/or-date-time-picker-v3/partials/or-date-time-picker-month-select/OrDateTimePickerMonthSelect.vue.d.ts +12 -0
- package/dist/esm/v3/components/or-date-time-picker-v3/partials/or-date-time-picker-time-select/OrDateTimePickerTimeSelect.vue.d.ts +12 -0
- package/dist/esm/v3/index.js +1 -1
- package/package.json +2 -2
- package/src/components/or-date-time-picker-v3/OrDateTimePicker.stories3.ts +4 -0
- package/src/components/or-date-time-picker-v3/OrDateTimePicker.vue +88 -34
- package/src/components/or-date-time-picker-v3/partials/or-date-time-picker-day-select/OrDateTimePickerDaySelect.vue +7 -1
- package/src/components/or-date-time-picker-v3/partials/or-date-time-picker-day-select/styles.ts +3 -0
- package/src/components/or-date-time-picker-v3/partials/or-date-time-picker-month-select/OrDateTimePickerMonthSelect.vue +8 -1
- package/src/components/or-date-time-picker-v3/partials/or-date-time-picker-time-select/OrDateTimePickerTimeSelect.vue +8 -1
- package/src/components/or-date-time-picker-v3/styles.ts +5 -2
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { defineComponent, ref, computed, reactive, watch } from 'vue-demi';
|
|
2
|
-
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createElementVNode, Fragment, renderList, createBlock, withModifiers, withCtx, createTextVNode, toDisplayString, createVNode, renderSlot, resolveDirective, createCommentVNode, withDirectives, mergeProps, pushScopeId, popScopeId } from 'vue';
|
|
3
|
-
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
|
4
|
-
import { s as script$f, I as InputBoxSize } from './OrInputBox-901887a1.js';
|
|
5
2
|
import { D as DropdownClose, a as DropdownOpen } from './dropdown-open-e1f90e0a.js';
|
|
6
3
|
import { a as useIdAttribute, u as useControlAttributes } from './useIdAttribute-859439f0.js';
|
|
7
4
|
import '@vueuse/core';
|
|
@@ -9,12 +6,15 @@ import { u as useValidationAttributes } from './useValidationAttributes-d1abbe34
|
|
|
9
6
|
import { s as script$d } from './OrError-c01d0c29.js';
|
|
10
7
|
import { s as script$e } from './OrHint-06ab89d7.js';
|
|
11
8
|
import { s as script$a } from './OrIconButton-e3f4d060.js';
|
|
9
|
+
import { s as script$f, I as InputBoxSize } from './OrInputBox-901887a1.js';
|
|
12
10
|
import { s as script$8 } from './OrLabel-4da56db0.js';
|
|
13
11
|
import { s as script$g } from './OrPopover-3ac8f589.js';
|
|
14
12
|
import { s as script$7 } from './OrButton-5a850657.js';
|
|
13
|
+
import { resolveComponent, openBlock, createElementBlock, normalizeClass, createElementVNode, Fragment, renderList, createBlock, withModifiers, withCtx, createTextVNode, toDisplayString, createVNode, renderSlot, resolveDirective, createCommentVNode, withDirectives, mergeProps, pushScopeId, popScopeId } from 'vue';
|
|
15
14
|
import { s as script$9 } from './OrIcon-62793572.js';
|
|
16
15
|
import { s as script$c } from './OrMenuItem-dbee450f.js';
|
|
17
16
|
import { s as script$b } from './OrMenu-70cee836.js';
|
|
17
|
+
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
|
18
18
|
|
|
19
19
|
function useDefaultDate() {
|
|
20
20
|
return new Date().getUTCDate();
|
|
@@ -43,7 +43,9 @@ const DateTimePickerDaySelect = [
|
|
|
43
43
|
'px-md', 'py-md', 'gap-sm'];
|
|
44
44
|
const DateTimePickerDaySelectButtonGroup = [
|
|
45
45
|
// Layout
|
|
46
|
-
'grid', 'grid-cols-7'
|
|
46
|
+
'grid', 'grid-cols-7',
|
|
47
|
+
// Spacing
|
|
48
|
+
'gap-xs'];
|
|
47
49
|
const DateTimePickerDaySelectButtonGroupItem = [
|
|
48
50
|
// Box
|
|
49
51
|
'min-w-fit',
|
|
@@ -65,6 +67,10 @@ var script$6 = defineComponent({
|
|
|
65
67
|
modelValue: {
|
|
66
68
|
type: Date,
|
|
67
69
|
default: undefined
|
|
70
|
+
},
|
|
71
|
+
filter: {
|
|
72
|
+
type: Function,
|
|
73
|
+
default: undefined
|
|
68
74
|
}
|
|
69
75
|
},
|
|
70
76
|
emits: ['update:modelValue'],
|
|
@@ -133,12 +139,13 @@ function render$6(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
133
139
|
class: normalizeClass(_ctx.buttonGroupItemStyles),
|
|
134
140
|
variant: Number(value) === Number(_ctx.proxyModelValue) ? 'contained' : 'text',
|
|
135
141
|
color: Number(value) === Number(_ctx.proxyModelValue) ? 'primary' : 'inherit',
|
|
142
|
+
disabled: _ctx.filter && !_ctx.filter(value),
|
|
136
143
|
onClick: withModifiers($event => _ctx.proxyModelValue = value, ["stop"])
|
|
137
144
|
}, {
|
|
138
145
|
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatDay(value)), 1 /* TEXT */)]),
|
|
139
146
|
|
|
140
147
|
_: 2 /* DYNAMIC */
|
|
141
|
-
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "variant", "color", "onClick"]);
|
|
148
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "variant", "color", "disabled", "onClick"]);
|
|
142
149
|
}), 128 /* KEYED_FRAGMENT */))], 2 /* CLASS */)], 2 /* CLASS */);
|
|
143
150
|
}
|
|
144
151
|
|
|
@@ -222,6 +229,10 @@ var script$4 = defineComponent({
|
|
|
222
229
|
modelValue: {
|
|
223
230
|
type: Date,
|
|
224
231
|
default: undefined
|
|
232
|
+
},
|
|
233
|
+
filter: {
|
|
234
|
+
type: Function,
|
|
235
|
+
default: undefined
|
|
225
236
|
}
|
|
226
237
|
},
|
|
227
238
|
emits: ['update:modelValue'],
|
|
@@ -363,6 +374,7 @@ function render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
363
374
|
return openBlock(), createBlock(_component_OrMenuItem, {
|
|
364
375
|
key: Number(value),
|
|
365
376
|
selected: Number(value) === Number(_ctx.proxyModelValue),
|
|
377
|
+
disabled: _ctx.filter && !_ctx.filter(value),
|
|
366
378
|
onClick: withModifiers($event => {
|
|
367
379
|
_ctx.proxyModelValue = value;
|
|
368
380
|
_ctx.yearMenu.close();
|
|
@@ -371,7 +383,7 @@ function render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
371
383
|
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatYear(value)), 1 /* TEXT */)]),
|
|
372
384
|
|
|
373
385
|
_: 2 /* DYNAMIC */
|
|
374
|
-
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["selected", "onClick"]);
|
|
386
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["selected", "disabled", "onClick"]);
|
|
375
387
|
}), 128 /* KEYED_FRAGMENT */))]),
|
|
376
388
|
|
|
377
389
|
_: 1 /* STABLE */
|
|
@@ -383,6 +395,7 @@ function render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
383
395
|
return openBlock(), createBlock(_component_OrMenuItem, {
|
|
384
396
|
key: Number(value),
|
|
385
397
|
selected: Number(value) === Number(_ctx.proxyModelValue),
|
|
398
|
+
disabled: _ctx.filter && !_ctx.filter(value),
|
|
386
399
|
onClick: withModifiers($event => {
|
|
387
400
|
_ctx.proxyModelValue = value;
|
|
388
401
|
_ctx.monthMenu.close();
|
|
@@ -391,7 +404,7 @@ function render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
391
404
|
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatMonth(value)), 1 /* TEXT */)]),
|
|
392
405
|
|
|
393
406
|
_: 2 /* DYNAMIC */
|
|
394
|
-
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["selected", "onClick"]);
|
|
407
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["selected", "disabled", "onClick"]);
|
|
395
408
|
}), 128 /* KEYED_FRAGMENT */))]),
|
|
396
409
|
|
|
397
410
|
_: 1 /* STABLE */
|
|
@@ -518,6 +531,10 @@ var script$1 = defineComponent({
|
|
|
518
531
|
modelValue: {
|
|
519
532
|
type: Date,
|
|
520
533
|
default: undefined
|
|
534
|
+
},
|
|
535
|
+
filter: {
|
|
536
|
+
type: Function,
|
|
537
|
+
default: undefined
|
|
521
538
|
}
|
|
522
539
|
},
|
|
523
540
|
emits: ['update:modelValue'],
|
|
@@ -595,12 +612,13 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
595
612
|
class: normalizeClass(_ctx.buttonGroupItemStyles),
|
|
596
613
|
variant: Number(value) === Number(_ctx.proxyModelValue) ? 'contained' : 'text',
|
|
597
614
|
color: Number(value) === Number(_ctx.proxyModelValue) ? 'primary' : 'inherit',
|
|
615
|
+
disabled: _ctx.filter && !_ctx.filter(value),
|
|
598
616
|
onClick: withModifiers($event => _ctx.proxyModelValue = value, ["stop"])
|
|
599
617
|
}, {
|
|
600
618
|
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatHours(value)), 1 /* TEXT */)]),
|
|
601
619
|
|
|
602
620
|
_: 2 /* DYNAMIC */
|
|
603
|
-
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "variant", "color", "onClick"]);
|
|
621
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "variant", "color", "disabled", "onClick"]);
|
|
604
622
|
}), 128 /* KEYED_FRAGMENT */))], 2 /* CLASS */), createTextVNode(" : "), createElementVNode("div", {
|
|
605
623
|
class: normalizeClass(_ctx.buttonGroupStyles)
|
|
606
624
|
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.minutesOptions, value => {
|
|
@@ -609,12 +627,13 @@ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
609
627
|
class: normalizeClass(_ctx.buttonGroupItemStyles),
|
|
610
628
|
variant: Number(value) === Number(_ctx.proxyModelValue) ? 'contained' : 'text',
|
|
611
629
|
color: Number(value) === Number(_ctx.proxyModelValue) ? 'primary' : 'inherit',
|
|
630
|
+
disabled: _ctx.filter && !_ctx.filter(value),
|
|
612
631
|
onClick: withModifiers($event => _ctx.proxyModelValue = value, ["stop"])
|
|
613
632
|
}, {
|
|
614
633
|
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatMinutes(value)), 1 /* TEXT */)]),
|
|
615
634
|
|
|
616
635
|
_: 2 /* DYNAMIC */
|
|
617
|
-
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "variant", "color", "onClick"]);
|
|
636
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class", "variant", "color", "disabled", "onClick"]);
|
|
618
637
|
}), 128 /* KEYED_FRAGMENT */))], 2 /* CLASS */)], 2 /* CLASS */);
|
|
619
638
|
}
|
|
620
639
|
|
|
@@ -627,8 +646,10 @@ const DateTimePicker = [
|
|
|
627
646
|
// Spacing
|
|
628
647
|
'gap-xs'];
|
|
629
648
|
const DateTimePickerControl = [
|
|
649
|
+
// Layout
|
|
650
|
+
'layout-inline-row justify-center',
|
|
630
651
|
// Theme (focus)
|
|
631
|
-
'focus:theme-border-
|
|
652
|
+
'focus:theme-border-2-current', 'dark:focus:theme-border-2-current-dark', 'focus:theme-border-underline', 'dark:focus:theme-border-underline'];
|
|
632
653
|
|
|
633
654
|
var script = defineComponent({
|
|
634
655
|
name: 'OrDateTimePicker',
|
|
@@ -659,6 +680,10 @@ var script = defineComponent({
|
|
|
659
680
|
type: Date,
|
|
660
681
|
default: undefined
|
|
661
682
|
},
|
|
683
|
+
filter: {
|
|
684
|
+
type: Function,
|
|
685
|
+
default: undefined
|
|
686
|
+
},
|
|
662
687
|
size: {
|
|
663
688
|
type: String,
|
|
664
689
|
default: InputBoxSize.M
|
|
@@ -767,6 +792,34 @@ var script = defineComponent({
|
|
|
767
792
|
popoverInstance.close();
|
|
768
793
|
}
|
|
769
794
|
}
|
|
795
|
+
function formatDate(value) {
|
|
796
|
+
var _a;
|
|
797
|
+
return (_a = value === null || value === void 0 ? void 0 : value.toLocaleString('default', {
|
|
798
|
+
dateStyle: 'short',
|
|
799
|
+
timeZone: 'UTC'
|
|
800
|
+
})) !== null && _a !== void 0 ? _a : '--';
|
|
801
|
+
}
|
|
802
|
+
function formatTime(value) {
|
|
803
|
+
var _a;
|
|
804
|
+
return (_a = value === null || value === void 0 ? void 0 : value.toLocaleString('default', {
|
|
805
|
+
timeStyle: 'short',
|
|
806
|
+
timeZone: 'UTC'
|
|
807
|
+
})) !== null && _a !== void 0 ? _a : '--';
|
|
808
|
+
}
|
|
809
|
+
function formatDateAlt(value) {
|
|
810
|
+
var _a;
|
|
811
|
+
return (_a = value === null || value === void 0 ? void 0 : value.toLocaleString('default', {
|
|
812
|
+
dateStyle: 'medium',
|
|
813
|
+
timeZone: 'UTC'
|
|
814
|
+
})) !== null && _a !== void 0 ? _a : '--';
|
|
815
|
+
}
|
|
816
|
+
function formatTimeAlt(value) {
|
|
817
|
+
var _a;
|
|
818
|
+
return (_a = value === null || value === void 0 ? void 0 : value.toLocaleString('default', {
|
|
819
|
+
timeStyle: 'short',
|
|
820
|
+
timeZone: 'UTC'
|
|
821
|
+
})) !== null && _a !== void 0 ? _a : '--';
|
|
822
|
+
}
|
|
770
823
|
return {
|
|
771
824
|
root,
|
|
772
825
|
dateControl,
|
|
@@ -783,7 +836,11 @@ var script = defineComponent({
|
|
|
783
836
|
toggleDatePopover,
|
|
784
837
|
toggleTimePopover,
|
|
785
838
|
closeDatePopover,
|
|
786
|
-
closeTimePopover
|
|
839
|
+
closeTimePopover,
|
|
840
|
+
formatDate,
|
|
841
|
+
formatTime,
|
|
842
|
+
formatDateAlt,
|
|
843
|
+
formatTimeAlt
|
|
787
844
|
};
|
|
788
845
|
}
|
|
789
846
|
});
|
|
@@ -833,23 +890,23 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
833
890
|
readonly: _ctx.readonly,
|
|
834
891
|
disabled: _ctx.disabled
|
|
835
892
|
}, {
|
|
836
|
-
default: withCtx(() => [
|
|
893
|
+
default: withCtx(() => [createCommentVNode(" <input\n ref=\"dateControl\"\n v-dropdown-open=\"toggleDatePopover\"\n v-dropdown-close=\"closeDatePopover\"\n v-bind=\"controlAttributes\"\n :class=\"controlStyles\"\n :type=\"'text'\"\n :value=\"formatDate(proxyModelValue)\"\n :required=\"required\"\n :readonly=\"readonly\"\n :disabled=\"disabled\"\n > "), createCommentVNode(" <input\n ref=\"timeControl\"\n v-dropdown-open=\"toggleTimePopover\"\n v-dropdown-close=\"closeTimePopover\"\n v-bind=\"controlAttributes\"\n :class=\"controlStyles\"\n :type=\"'text'\"\n :value=\"formatTime(proxyModelValue)\"\n :required=\"required\"\n :readonly=\"readonly\"\n :disabled=\"disabled\"\n > "), withDirectives((openBlock(), createElementBlock("div", mergeProps({
|
|
837
894
|
ref: "dateControl"
|
|
838
895
|
}, _ctx.controlAttributes, {
|
|
839
896
|
class: _ctx.controlStyles,
|
|
840
|
-
|
|
897
|
+
contenteditable: true,
|
|
841
898
|
required: _ctx.required,
|
|
842
899
|
readonly: _ctx.readonly,
|
|
843
900
|
disabled: _ctx.disabled
|
|
844
|
-
}),
|
|
901
|
+
}), [createTextVNode(toDisplayString(_ctx.formatDate(_ctx.proxyModelValue)), 1 /* TEXT */)], 16 /* FULL_PROPS */, _hoisted_1)), [[_directive_dropdown_open, _ctx.toggleDatePopover], [_directive_dropdown_close, _ctx.closeDatePopover]]), withDirectives((openBlock(), createElementBlock("div", mergeProps({
|
|
845
902
|
ref: "timeControl"
|
|
846
903
|
}, _ctx.controlAttributes, {
|
|
847
904
|
class: _ctx.controlStyles,
|
|
848
|
-
|
|
905
|
+
contenteditable: true,
|
|
849
906
|
required: _ctx.required,
|
|
850
907
|
readonly: _ctx.readonly,
|
|
851
908
|
disabled: _ctx.disabled
|
|
852
|
-
}),
|
|
909
|
+
}), [createTextVNode(toDisplayString(_ctx.formatTime(_ctx.proxyModelValue)), 1 /* TEXT */)], 16 /* FULL_PROPS */, _hoisted_2)), [[_directive_dropdown_open, _ctx.toggleTimePopover], [_directive_dropdown_close, _ctx.closeTimePopover]]), createVNode(_component_OrPopover, {
|
|
853
910
|
ref: "datePopover",
|
|
854
911
|
variant: 'auto',
|
|
855
912
|
trigger: _ctx.dateControl,
|
|
@@ -859,23 +916,27 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
859
916
|
default: withCtx(() => [createVNode(_component_OrDateTimePickerMobileControl, {
|
|
860
917
|
label: "Date"
|
|
861
918
|
}, {
|
|
862
|
-
default: withCtx(() => [createTextVNode(
|
|
919
|
+
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatDateAlt(_ctx.draftModelValue)), 1 /* TEXT */)]),
|
|
920
|
+
|
|
863
921
|
_: 1 /* STABLE */
|
|
864
922
|
}), createVNode(_component_OrDateTimePickerMobileControl, {
|
|
865
923
|
label: "Time"
|
|
866
924
|
}, {
|
|
867
|
-
default: withCtx(() => [createTextVNode(
|
|
925
|
+
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatTimeAlt(_ctx.draftModelValue)), 1 /* TEXT */)]),
|
|
926
|
+
|
|
868
927
|
_: 1 /* STABLE */
|
|
869
928
|
})]),
|
|
870
929
|
|
|
871
930
|
_: 1 /* STABLE */
|
|
872
931
|
}), createVNode(_component_OrDateTimePickerMonthSelect, {
|
|
873
932
|
modelValue: _ctx.draftModelValue,
|
|
874
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => _ctx.draftModelValue = $event)
|
|
875
|
-
|
|
933
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => _ctx.draftModelValue = $event),
|
|
934
|
+
filter: _ctx.filter
|
|
935
|
+
}, null, 8 /* PROPS */, ["modelValue", "filter"]), createVNode(_component_OrDateTimePickerDaySelect, {
|
|
876
936
|
modelValue: _ctx.draftModelValue,
|
|
877
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => _ctx.draftModelValue = $event)
|
|
878
|
-
|
|
937
|
+
"onUpdate:modelValue": _cache[1] || (_cache[1] = $event => _ctx.draftModelValue = $event),
|
|
938
|
+
filter: _ctx.filter
|
|
939
|
+
}, null, 8 /* PROPS */, ["modelValue", "filter"]), createVNode(_component_OrDateTimePickerPopoverFooter, {
|
|
879
940
|
onResolve: _cache[2] || (_cache[2] = $event => {
|
|
880
941
|
_ctx.proxyModelValue = _ctx.draftModelValue;
|
|
881
942
|
_ctx.datePopover.close();
|
|
@@ -896,20 +957,23 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
896
957
|
default: withCtx(() => [createVNode(_component_OrDateTimePickerMobileControl, {
|
|
897
958
|
label: "Date"
|
|
898
959
|
}, {
|
|
899
|
-
default: withCtx(() => [createTextVNode(
|
|
960
|
+
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatDateAlt(_ctx.draftModelValue)), 1 /* TEXT */)]),
|
|
961
|
+
|
|
900
962
|
_: 1 /* STABLE */
|
|
901
963
|
}), createVNode(_component_OrDateTimePickerMobileControl, {
|
|
902
964
|
label: "Time"
|
|
903
965
|
}, {
|
|
904
|
-
default: withCtx(() => [createTextVNode(
|
|
966
|
+
default: withCtx(() => [createTextVNode(toDisplayString(_ctx.formatTimeAlt(_ctx.draftModelValue)), 1 /* TEXT */)]),
|
|
967
|
+
|
|
905
968
|
_: 1 /* STABLE */
|
|
906
969
|
})]),
|
|
907
970
|
|
|
908
971
|
_: 1 /* STABLE */
|
|
909
972
|
}), createVNode(_component_OrDateTimePickerTimeSelect, {
|
|
910
973
|
modelValue: _ctx.draftModelValue,
|
|
911
|
-
"onUpdate:modelValue": _cache[4] || (_cache[4] = $event => _ctx.draftModelValue = $event)
|
|
912
|
-
|
|
974
|
+
"onUpdate:modelValue": _cache[4] || (_cache[4] = $event => _ctx.draftModelValue = $event),
|
|
975
|
+
filter: _ctx.filter
|
|
976
|
+
}, null, 8 /* PROPS */, ["modelValue", "filter"]), createVNode(_component_OrDateTimePickerPopoverFooter, {
|
|
913
977
|
onResolve: _cache[5] || (_cache[5] = $event => {
|
|
914
978
|
_ctx.proxyModelValue = _ctx.draftModelValue;
|
|
915
979
|
_ctx.timePopover.close();
|
|
@@ -947,7 +1011,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
947
1011
|
}, 8 /* PROPS */, ["disabled"])) : createCommentVNode("v-if", true)], 2 /* CLASS */);
|
|
948
1012
|
}
|
|
949
1013
|
|
|
950
|
-
var css_248z = "\ninput[data-v-4ab76bac] {\n min-width: 0;\n background: none;\n outline: none;\n}\
|
|
1014
|
+
var css_248z = "\ninput[data-v-4ab76bac] {\n min-width: 0;\n background: none;\n outline: none;\n}\n";
|
|
951
1015
|
styleInject(css_248z);
|
|
952
1016
|
|
|
953
1017
|
script.render = render;
|
|
@@ -18,7 +18,7 @@ export { s as OrColorPicker, h as amber, n as black, b as blue, m as blueGrey, k
|
|
|
18
18
|
export { s as OrConfirm } from '../OrConfirm-f408faf5.js';
|
|
19
19
|
export { C as ConfirmType, s as OrConfirmV3 } from '../OrConfirm-ecb8c576.js';
|
|
20
20
|
export { D as DEFAULT_TEXT, s as OrDateTimePicker, a as OrDateTimePickerItemTypes, O as OrDateTimePickerTypes } from '../OrDateTimePicker-30749526.js';
|
|
21
|
-
export { s as OrDateTimePickerV3 } from '../OrDateTimePicker-
|
|
21
|
+
export { s as OrDateTimePickerV3 } from '../OrDateTimePicker-46b452b3.js';
|
|
22
22
|
export { I as DateTimePickerSize, I as InputBoxSize, a as InputBoxVariant, I as InputSize, s as OrInputBoxV3, I as SearchSize, I as SelectSize, I as TextareaSize } from '../OrInputBox-901887a1.js';
|
|
23
23
|
export { E as EmptyStateSize, s as OrEmptyStateV3 } from '../OrEmptyState-5349a1f9.js';
|
|
24
24
|
export { s as OrError } from '../OrError-f90296db.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PropType } from 'vue-demi';
|
|
2
|
-
import { DateTimePickerSize } from '
|
|
2
|
+
import { DateTimePickerSize } from './props';
|
|
3
3
|
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
4
4
|
root: import("@vue/composition-api").Ref<HTMLElement | undefined>;
|
|
5
5
|
dateControl: import("@vue/composition-api").Ref<HTMLInputElement | undefined>;
|
|
@@ -37,11 +37,19 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
37
37
|
toggleTimePopover: () => void;
|
|
38
38
|
closeDatePopover: () => void;
|
|
39
39
|
closeTimePopover: () => void;
|
|
40
|
+
formatDate: (value?: Date) => string;
|
|
41
|
+
formatTime: (value?: Date) => string;
|
|
42
|
+
formatDateAlt: (value?: Date) => string;
|
|
43
|
+
formatTimeAlt: (value?: Date) => string;
|
|
40
44
|
}> & import("@vue/composition-api").Data, {}, {}, {
|
|
41
45
|
modelValue: {
|
|
42
46
|
type: DateConstructor;
|
|
43
47
|
default: undefined;
|
|
44
48
|
};
|
|
49
|
+
filter: {
|
|
50
|
+
type: PropType<(value: Date) => boolean>;
|
|
51
|
+
default: undefined;
|
|
52
|
+
};
|
|
45
53
|
size: {
|
|
46
54
|
type: PropType<DateTimePickerSize>;
|
|
47
55
|
default: DateTimePickerSize;
|
|
@@ -79,6 +87,10 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
79
87
|
type: DateConstructor;
|
|
80
88
|
default: undefined;
|
|
81
89
|
};
|
|
90
|
+
filter: {
|
|
91
|
+
type: PropType<(value: Date) => boolean>;
|
|
92
|
+
default: undefined;
|
|
93
|
+
};
|
|
82
94
|
size: {
|
|
83
95
|
type: PropType<DateTimePickerSize>;
|
|
84
96
|
default: DateTimePickerSize;
|
|
@@ -112,6 +124,7 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
112
124
|
default: boolean;
|
|
113
125
|
};
|
|
114
126
|
}>> & Omit<import("vue").VueConstructor<import("vue").default>, never> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
127
|
+
filter: (value: Date) => boolean;
|
|
115
128
|
modelValue: Date;
|
|
116
129
|
size: DateTimePickerSize;
|
|
117
130
|
label: string;
|
|
@@ -160,7 +173,12 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
160
173
|
toggleTimePopover: () => void;
|
|
161
174
|
closeDatePopover: () => void;
|
|
162
175
|
closeTimePopover: () => void;
|
|
176
|
+
formatDate: (value?: Date) => string;
|
|
177
|
+
formatTime: (value?: Date) => string;
|
|
178
|
+
formatDateAlt: (value?: Date) => string;
|
|
179
|
+
formatTimeAlt: (value?: Date) => string;
|
|
163
180
|
}>, import("@vue/composition-api").Data, {}, {}, {}, {}, string[], {
|
|
181
|
+
filter: (value: Date) => boolean;
|
|
164
182
|
modelValue: Date;
|
|
165
183
|
size: DateTimePickerSize;
|
|
166
184
|
label: string;
|
|
@@ -173,6 +191,7 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
173
191
|
} & {} & {
|
|
174
192
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
175
193
|
}, {
|
|
194
|
+
filter: (value: Date) => boolean;
|
|
176
195
|
modelValue: Date;
|
|
177
196
|
size: DateTimePickerSize;
|
|
178
197
|
label: string;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
export { s as OrDateTimePickerV3 } from '../../OrDateTimePicker-
|
|
1
|
+
export { s as OrDateTimePickerV3 } from '../../OrDateTimePicker-46b452b3.js';
|
|
2
2
|
export { I as DateTimePickerSize } from '../../OrInputBox-901887a1.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
|
-
import 'vue';
|
|
5
|
-
import '../../style-inject.es-4c6f2515.js';
|
|
6
4
|
import '../../dropdown-open-e1f90e0a.js';
|
|
7
5
|
import '../../useIdAttribute-859439f0.js';
|
|
8
6
|
import '@vueuse/core';
|
|
9
7
|
import '../../useValidationAttributes-d1abbe34.js';
|
|
10
8
|
import '../../OrError-c01d0c29.js';
|
|
9
|
+
import 'vue';
|
|
11
10
|
import '../../OrHint-06ab89d7.js';
|
|
12
11
|
import '../../OrIconButton-e3f4d060.js';
|
|
13
12
|
import '../../OrIcon-62793572.js';
|
|
@@ -24,3 +23,4 @@ import '../../OrButton-5a850657.js';
|
|
|
24
23
|
import '../../OrLoader-b79022da.js';
|
|
25
24
|
import '../../OrMenuItem-dbee450f.js';
|
|
26
25
|
import '../../OrMenu-70cee836.js';
|
|
26
|
+
import '../../style-inject.es-4c6f2515.js';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { PropType } from 'vue-demi';
|
|
1
2
|
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
2
3
|
root: import("@vue/composition-api").Ref<HTMLElement | undefined>;
|
|
3
4
|
rootStyles: import("@vue/composition-api").ComputedRef<string[]>;
|
|
@@ -11,12 +12,21 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
11
12
|
type: DateConstructor;
|
|
12
13
|
default: undefined;
|
|
13
14
|
};
|
|
15
|
+
filter: {
|
|
16
|
+
type: PropType<(value: Date) => boolean>;
|
|
17
|
+
default: undefined;
|
|
18
|
+
};
|
|
14
19
|
}, import("@vue/composition-api").ExtractPropTypes<{
|
|
15
20
|
modelValue: {
|
|
16
21
|
type: DateConstructor;
|
|
17
22
|
default: undefined;
|
|
18
23
|
};
|
|
24
|
+
filter: {
|
|
25
|
+
type: PropType<(value: Date) => boolean>;
|
|
26
|
+
default: undefined;
|
|
27
|
+
};
|
|
19
28
|
}>> & Omit<import("vue").VueConstructor<import("vue").default>, never> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
29
|
+
filter: (value: Date) => boolean;
|
|
20
30
|
modelValue: Date;
|
|
21
31
|
} & {} & {
|
|
22
32
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
@@ -29,10 +39,12 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
29
39
|
dayOptions: import("@vue/composition-api").ComputedRef<Date[]>;
|
|
30
40
|
formatDay: (value: Date) => string;
|
|
31
41
|
}>, import("@vue/composition-api").Data, {}, {}, {}, {}, string[], {
|
|
42
|
+
filter: (value: Date) => boolean;
|
|
32
43
|
modelValue: Date;
|
|
33
44
|
} & {} & {
|
|
34
45
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
35
46
|
}, {
|
|
47
|
+
filter: (value: Date) => boolean;
|
|
36
48
|
modelValue: Date;
|
|
37
49
|
}, true>);
|
|
38
50
|
export default _default;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { PropType } from 'vue-demi';
|
|
1
2
|
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
2
3
|
root: import("@vue/composition-api").Ref<HTMLElement | undefined>;
|
|
3
4
|
yearButton: import("@vue/composition-api").Ref<import("@vue/composition-api").ComponentRenderProxy<{} & {}, import("@vue/composition-api").ShallowUnwrapRef<unknown>, unknown, import("@vue/composition-api").ComputedOptions, import("@vue/composition-api").MethodOptions, unknown, unknown, {
|
|
@@ -37,12 +38,21 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
37
38
|
type: DateConstructor;
|
|
38
39
|
default: undefined;
|
|
39
40
|
};
|
|
41
|
+
filter: {
|
|
42
|
+
type: PropType<(value: Date) => boolean>;
|
|
43
|
+
default: undefined;
|
|
44
|
+
};
|
|
40
45
|
}, import("@vue/composition-api").ExtractPropTypes<{
|
|
41
46
|
modelValue: {
|
|
42
47
|
type: DateConstructor;
|
|
43
48
|
default: undefined;
|
|
44
49
|
};
|
|
50
|
+
filter: {
|
|
51
|
+
type: PropType<(value: Date) => boolean>;
|
|
52
|
+
default: undefined;
|
|
53
|
+
};
|
|
45
54
|
}>> & Omit<import("vue").VueConstructor<import("vue").default>, never> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
55
|
+
filter: (value: Date) => boolean;
|
|
46
56
|
modelValue: Date;
|
|
47
57
|
} & {} & {
|
|
48
58
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
@@ -81,10 +91,12 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
81
91
|
formatYear: (value: Date) => string;
|
|
82
92
|
formatMonth: (value: Date) => string;
|
|
83
93
|
}>, import("@vue/composition-api").Data, {}, {}, {}, {}, string[], {
|
|
94
|
+
filter: (value: Date) => boolean;
|
|
84
95
|
modelValue: Date;
|
|
85
96
|
} & {} & {
|
|
86
97
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
87
98
|
}, {
|
|
99
|
+
filter: (value: Date) => boolean;
|
|
88
100
|
modelValue: Date;
|
|
89
101
|
}, true>);
|
|
90
102
|
export default _default;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { PropType } from 'vue-demi';
|
|
1
2
|
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
2
3
|
root: import("@vue/composition-api").Ref<HTMLElement | undefined>;
|
|
3
4
|
rootStyles: import("@vue/composition-api").ComputedRef<string[]>;
|
|
@@ -13,12 +14,21 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
13
14
|
type: DateConstructor;
|
|
14
15
|
default: undefined;
|
|
15
16
|
};
|
|
17
|
+
filter: {
|
|
18
|
+
type: PropType<(value: Date) => boolean>;
|
|
19
|
+
default: undefined;
|
|
20
|
+
};
|
|
16
21
|
}, import("@vue/composition-api").ExtractPropTypes<{
|
|
17
22
|
modelValue: {
|
|
18
23
|
type: DateConstructor;
|
|
19
24
|
default: undefined;
|
|
20
25
|
};
|
|
26
|
+
filter: {
|
|
27
|
+
type: PropType<(value: Date) => boolean>;
|
|
28
|
+
default: undefined;
|
|
29
|
+
};
|
|
21
30
|
}>> & Omit<import("vue").VueConstructor<import("vue").default>, never> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
31
|
+
filter: (value: Date) => boolean;
|
|
22
32
|
modelValue: Date;
|
|
23
33
|
} & {} & {
|
|
24
34
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
@@ -33,10 +43,12 @@ declare const _default: import("vue").ComponentOptions<import("vue").default, im
|
|
|
33
43
|
formatHours: (value: Date) => string;
|
|
34
44
|
formatMinutes: (value: Date) => string;
|
|
35
45
|
}>, import("@vue/composition-api").Data, {}, {}, {}, {}, string[], {
|
|
46
|
+
filter: (value: Date) => boolean;
|
|
36
47
|
modelValue: Date;
|
|
37
48
|
} & {} & {
|
|
38
49
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
39
50
|
}, {
|
|
51
|
+
filter: (value: Date) => boolean;
|
|
40
52
|
modelValue: Date;
|
|
41
53
|
}, true>);
|
|
42
54
|
export default _default;
|
package/dist/esm/v3/index.js
CHANGED
|
@@ -18,7 +18,7 @@ export { s as OrColorPicker, h as amber, n as black, b as blue, m as blueGrey, k
|
|
|
18
18
|
export { s as OrConfirm } from './OrConfirm-f408faf5.js';
|
|
19
19
|
export { C as ConfirmType, s as OrConfirmV3 } from './OrConfirm-ecb8c576.js';
|
|
20
20
|
export { D as DEFAULT_TEXT, s as OrDateTimePicker, a as OrDateTimePickerItemTypes, O as OrDateTimePickerTypes } from './OrDateTimePicker-30749526.js';
|
|
21
|
-
export { s as OrDateTimePickerV3 } from './OrDateTimePicker-
|
|
21
|
+
export { s as OrDateTimePickerV3 } from './OrDateTimePicker-46b452b3.js';
|
|
22
22
|
export { I as DateTimePickerSize, I as InputBoxSize, a as InputBoxVariant, I as InputSize, s as OrInputBoxV3, I as SearchSize, I as SelectSize, I as TextareaSize } from './OrInputBox-901887a1.js';
|
|
23
23
|
export { E as EmptyStateSize, s as OrEmptyStateV3 } from './OrEmptyState-5349a1f9.js';
|
|
24
24
|
export { s as OrError } from './OrError-f90296db.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@onereach/ui-components",
|
|
3
|
-
"version": "3.0.4-beta.
|
|
3
|
+
"version": "3.0.4-beta.2500.0",
|
|
4
4
|
"description": "Vue components library for v2/3",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"main": "./dist/auto/index.js",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@codemirror/lang-json": "6.0.0",
|
|
39
39
|
"@codemirror/lang-markdown": "6.0.1",
|
|
40
40
|
"@floating-ui/dom": "0.3.1",
|
|
41
|
-
"@onereach/styles": "^2.37.4-beta.
|
|
41
|
+
"@onereach/styles": "^2.37.4-beta.2500.0",
|
|
42
42
|
"@splidejs/splide": "4.0.6",
|
|
43
43
|
"@types/lodash": "4.14.173",
|
|
44
44
|
"@types/sortablejs": "1.10.7",
|