@stsdti/funky-ui-kit 1.8.8 → 1.8.9
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/funky-ui-kit.esm.js +16 -158
- package/dist/funky-ui-kit.esm.js.map +1 -1
- package/package.json +1 -1
- package/web-types.json +1 -1
package/dist/funky-ui-kit.esm.js
CHANGED
|
@@ -28476,159 +28476,10 @@ var AppDate_default = /*#__PURE__*/ _plugin_vue_export_helper_default({
|
|
|
28476
28476
|
};
|
|
28477
28477
|
}
|
|
28478
28478
|
}, [["__scopeId", "data-v-dbda72e2"]]);
|
|
28479
|
-
|
|
28480
|
-
|
|
28481
|
-
|
|
28482
|
-
|
|
28483
|
-
style: { "gap": "3px" }
|
|
28484
|
-
};
|
|
28485
|
-
var _hoisted_2$58 = [
|
|
28486
|
-
"disabled",
|
|
28487
|
-
"placeholder",
|
|
28488
|
-
"onBlur",
|
|
28489
|
-
"onKeydown",
|
|
28490
|
-
"onKeypress",
|
|
28491
|
-
"onPaste"
|
|
28492
|
-
];
|
|
28493
|
-
var _hoisted_3$41 = { key: 0 };
|
|
28494
|
-
var _hoisted_4$31 = {
|
|
28495
|
-
key: 1,
|
|
28496
|
-
class: "app-form-element-placeholder"
|
|
28497
|
-
};
|
|
28498
|
-
var _hoisted_5$23 = { class: "form-control-feedback form-control-feedback-end" };
|
|
28499
|
-
var _hoisted_6$14 = { class: "form-control-feedback-icon" };
|
|
28500
|
-
var _hoisted_7$7 = {
|
|
28501
|
-
key: 0,
|
|
28502
|
-
class: "ml-10"
|
|
28503
|
-
};
|
|
28504
|
-
var _sfc_main$114 = {
|
|
28505
|
-
__name: "AppDatePicker",
|
|
28506
|
-
props: /*@__PURE__*/ mergeModels({
|
|
28507
|
-
...appDatePickerProps_default,
|
|
28508
|
-
...appFormElementProps_default
|
|
28509
|
-
}, {
|
|
28510
|
-
"modelValue": { type: Date },
|
|
28511
|
-
"modelModifiers": {}
|
|
28512
|
-
}),
|
|
28513
|
-
emits: ["update:modelValue"],
|
|
28514
|
-
setup(__props) {
|
|
28515
|
-
const modelValue = useModel(__props, "modelValue");
|
|
28516
|
-
const inputValue = ref("");
|
|
28517
|
-
const isMenuOpen = ref(false);
|
|
28518
|
-
const props = __props;
|
|
28519
|
-
const { formElementProps, computedName, computedPlaceHolder } = useAppFormElement(props);
|
|
28520
|
-
const computedClass = computed(() => ({
|
|
28521
|
-
"app-date-picker": true,
|
|
28522
|
-
"disabled-element": props.disabled
|
|
28523
|
-
}));
|
|
28524
|
-
const computedFormats = computed(() => ({
|
|
28525
|
-
input: props.currentFormat,
|
|
28526
|
-
preview: props.currentFormat
|
|
28527
|
-
}));
|
|
28528
|
-
const isDayOfWeekVisible = computed(() => props.showDayOfWeek && modelValue.value);
|
|
28529
|
-
watch(modelValue, (newValue) => {
|
|
28530
|
-
inputValue.value = newValue ? format$1(newValue, props.currentFormat) : "";
|
|
28531
|
-
}, { immediate: true });
|
|
28532
|
-
const attemptToParseDate = (dateStr) => {
|
|
28533
|
-
if (!(0, import_lodash.isString)(dateStr)) return null;
|
|
28534
|
-
dateStr = dateStr.replace(/[.,\-\/]/g, ".");
|
|
28535
|
-
const formats = [props.currentFormat.replace("yyyy", "yy"), props.currentFormat];
|
|
28536
|
-
for (const format of formats) {
|
|
28537
|
-
const date = parse$2(dateStr, format, /* @__PURE__ */ new Date());
|
|
28538
|
-
if (!isNaN(date.getTime())) return date;
|
|
28539
|
-
}
|
|
28540
|
-
};
|
|
28541
|
-
const applyInputValue = () => {
|
|
28542
|
-
let parsedDate = attemptToParseDate(inputValue.value);
|
|
28543
|
-
parsedDate ? modelValue.value = parsedDate : clearValues();
|
|
28544
|
-
};
|
|
28545
|
-
const clearValues = () => {
|
|
28546
|
-
modelValue.value = null;
|
|
28547
|
-
inputValue.value = null;
|
|
28548
|
-
};
|
|
28549
|
-
const updateDate = (date) => {
|
|
28550
|
-
date.setHours(0);
|
|
28551
|
-
date.setMinutes(0);
|
|
28552
|
-
date.setSeconds(0);
|
|
28553
|
-
};
|
|
28554
|
-
useClickOutside({ isOpen: isMenuOpen });
|
|
28555
|
-
return (_ctx, _cache) => {
|
|
28556
|
-
const _component_app_date_picker_day_of_week = resolveComponent("app-date-picker-day-of-week");
|
|
28557
|
-
const _component_vue_date_picker = resolveComponent("vue-date-picker");
|
|
28558
|
-
return openBlock(), createBlock(AppFormElement_default, normalizeProps(guardReactiveProps(unref(formElementProps))), createSlots({
|
|
28559
|
-
default: withCtx(() => [createVNode(_component_vue_date_picker, mergeProps({
|
|
28560
|
-
modelValue: modelValue.value,
|
|
28561
|
-
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => modelValue.value = $event)
|
|
28562
|
-
}, _ctx.$attrs, {
|
|
28563
|
-
position: "left",
|
|
28564
|
-
"action-row": {
|
|
28565
|
-
showSelect: true,
|
|
28566
|
-
showCancel: true,
|
|
28567
|
-
showPreview: true
|
|
28568
|
-
},
|
|
28569
|
-
"auto-apply": true,
|
|
28570
|
-
class: computedClass.value,
|
|
28571
|
-
"disabled-dates": _ctx.disabledDates,
|
|
28572
|
-
disabled: _ctx.disabled,
|
|
28573
|
-
"enable-time-picker": false,
|
|
28574
|
-
locale: unref(locale),
|
|
28575
|
-
formats: computedFormats.value,
|
|
28576
|
-
name: unref(computedName),
|
|
28577
|
-
placeholder: unref(computedPlaceHolder),
|
|
28578
|
-
"text-input": _ctx.isTypeable,
|
|
28579
|
-
onDateUpdate: updateDate,
|
|
28580
|
-
onClosed: _cache[2] || (_cache[2] = ($event) => isMenuOpen.value = false),
|
|
28581
|
-
onOpen: _cache[3] || (_cache[3] = ($event) => isMenuOpen.value = true)
|
|
28582
|
-
}), {
|
|
28583
|
-
"dp-input": withCtx(({ value, isMenuOpen, onTab, onKeypress, onPaste }) => [createElementVNode("div", _hoisted_1$78, [
|
|
28584
|
-
_cache[5] || (_cache[5] = createElementVNode("i", { class: "ph-calendar-blank" }, null, -1)),
|
|
28585
|
-
isDayOfWeekVisible.value ? (openBlock(), createBlock(_component_app_date_picker_day_of_week, {
|
|
28586
|
-
key: 0,
|
|
28587
|
-
language: _ctx.currentLanguage,
|
|
28588
|
-
value: modelValue.value
|
|
28589
|
-
}, null, 8, ["language", "value"])) : createCommentVNode("", true),
|
|
28590
|
-
props.isTypeable ? withDirectives((openBlock(), createElementBlock("input", {
|
|
28591
|
-
key: 1,
|
|
28592
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inputValue.value = $event),
|
|
28593
|
-
class: "dp__input_readonly dp__input_icon_pad dp__input_reg borderless-input date-picker-input",
|
|
28594
|
-
type: "text",
|
|
28595
|
-
disabled: _ctx.disabled,
|
|
28596
|
-
placeholder: _ctx.placeholder,
|
|
28597
|
-
onBlur: ($event) => !isMenuOpen && applyInputValue(),
|
|
28598
|
-
onKeydown: [withKeys(applyInputValue, ["enter"]), withKeys(onTab, ["tab"])],
|
|
28599
|
-
onKeypress,
|
|
28600
|
-
onPaste
|
|
28601
|
-
}, null, 40, _hoisted_2$58)), [[vModelText, inputValue.value]]) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [modelValue.value ? (openBlock(), createElementBlock("span", _hoisted_3$41, toDisplayString(value), 1)) : (openBlock(), createElementBlock("span", _hoisted_4$31, toDisplayString(_ctx.placeholder), 1))], 64))
|
|
28602
|
-
])]),
|
|
28603
|
-
"clear-icon": withCtx(() => [createElementVNode("div", _hoisted_5$23, [createElementVNode("div", _hoisted_6$14, [createElementVNode("i", {
|
|
28604
|
-
class: "ph-x-circle app-cross-icon mb-15",
|
|
28605
|
-
onClick: withModifiers(clearValues, ["stop"])
|
|
28606
|
-
})])])]),
|
|
28607
|
-
_: 1
|
|
28608
|
-
}, 16, [
|
|
28609
|
-
"modelValue",
|
|
28610
|
-
"class",
|
|
28611
|
-
"disabled-dates",
|
|
28612
|
-
"disabled",
|
|
28613
|
-
"locale",
|
|
28614
|
-
"formats",
|
|
28615
|
-
"name",
|
|
28616
|
-
"placeholder",
|
|
28617
|
-
"text-input"
|
|
28618
|
-
]), _ctx.showEasyButtons && !_ctx.disabled ? (openBlock(), createElementBlock("div", _hoisted_7$7, [createVNode(_sfc_main$116, {
|
|
28619
|
-
modelValue: modelValue.value,
|
|
28620
|
-
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => modelValue.value = $event)
|
|
28621
|
-
}, null, 8, ["modelValue"])])) : createCommentVNode("", true)]),
|
|
28622
|
-
_: 2
|
|
28623
|
-
}, [renderList(Object.keys(_ctx.$slots), (slot) => {
|
|
28624
|
-
return {
|
|
28625
|
-
name: slot,
|
|
28626
|
-
fn: withCtx((scope) => [renderSlot(_ctx.$slots, slot, normalizeProps(guardReactiveProps(scope)))])
|
|
28627
|
-
};
|
|
28628
|
-
})]), 1040);
|
|
28629
|
-
};
|
|
28630
|
-
}
|
|
28631
|
-
};
|
|
28479
|
+
({
|
|
28480
|
+
...appDatePickerProps_default,
|
|
28481
|
+
...appFormElementProps_default
|
|
28482
|
+
});
|
|
28632
28483
|
//#endregion
|
|
28633
28484
|
//#region src/components/small/app-date-picker/AppDatePickerRange.vue
|
|
28634
28485
|
var _hoisted_1$77 = { class: "w-100" };
|
|
@@ -30332,6 +30183,10 @@ var _sfc_main$112 = {
|
|
|
30332
30183
|
width: {
|
|
30333
30184
|
type: [String, Number],
|
|
30334
30185
|
default: null
|
|
30186
|
+
},
|
|
30187
|
+
placement: {
|
|
30188
|
+
type: String,
|
|
30189
|
+
default: "bottom-start"
|
|
30335
30190
|
}
|
|
30336
30191
|
},
|
|
30337
30192
|
setup(__props) {
|
|
@@ -30347,7 +30202,7 @@ var _sfc_main$112 = {
|
|
|
30347
30202
|
else anchorEl.value = props.anchor;
|
|
30348
30203
|
}, { immediate: true });
|
|
30349
30204
|
const { x, y, strategy } = useFloating(anchorEl, floatingEl, {
|
|
30350
|
-
placement:
|
|
30205
|
+
placement: computed(() => props.placement),
|
|
30351
30206
|
strategy: "absolute",
|
|
30352
30207
|
whileElementsMounted: autoUpdate,
|
|
30353
30208
|
middleware: [
|
|
@@ -31209,10 +31064,12 @@ var _sfc_main$10 = {
|
|
|
31209
31064
|
onInput();
|
|
31210
31065
|
}, { immediate: true });
|
|
31211
31066
|
return (_ctx, _cache) => {
|
|
31067
|
+
const _component_app_date = resolveComponent("app-date");
|
|
31068
|
+
const _component_app_time = resolveComponent("app-time");
|
|
31212
31069
|
return openBlock(), createBlock(AppFormElement_default, normalizeProps(guardReactiveProps(unref(formElementProps))), {
|
|
31213
31070
|
"help-block": withCtx(() => [renderSlot(_ctx.$slots, "help-block")]),
|
|
31214
31071
|
default: withCtx(() => [createElementVNode("div", _hoisted_1$72, [
|
|
31215
|
-
createElementVNode("div", _hoisted_2$53, [createVNode(
|
|
31072
|
+
createElementVNode("div", _hoisted_2$53, [createVNode(_component_app_date, {
|
|
31216
31073
|
modelValue: localDate.value,
|
|
31217
31074
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => localDate.value = $event),
|
|
31218
31075
|
"current-format": "dd.MM.yyyy",
|
|
@@ -31224,7 +31081,7 @@ var _sfc_main$10 = {
|
|
|
31224
31081
|
"disabled",
|
|
31225
31082
|
"show-day-of-week"
|
|
31226
31083
|
])]),
|
|
31227
|
-
createElementVNode("div", _hoisted_3$36, [createVNode(
|
|
31084
|
+
createElementVNode("div", _hoisted_3$36, [createVNode(_component_app_time, {
|
|
31228
31085
|
ref: "timePicker",
|
|
31229
31086
|
modelValue: localTime.value,
|
|
31230
31087
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => localTime.value = $event),
|
|
@@ -137903,9 +137760,10 @@ function useTableModel({ props, emits, tableContext, formContext = null, model,
|
|
|
137903
137760
|
}
|
|
137904
137761
|
//#endregion
|
|
137905
137762
|
//#region src/index.js
|
|
137763
|
+
var components = { ...components_exports };
|
|
137906
137764
|
var plugin = { install(Vue, config) {
|
|
137907
|
-
for (const prop in
|
|
137908
|
-
const component =
|
|
137765
|
+
for (const prop in components) if (components.hasOwnProperty(prop)) {
|
|
137766
|
+
const component = components[prop];
|
|
137909
137767
|
Vue.component(prop, component);
|
|
137910
137768
|
}
|
|
137911
137769
|
if (!Vue.directive("tippy")) Vue.use(plugin$1);
|