eco-vue-js 0.23.1 → 0.24.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/assets/icons/IconInfo.js +27 -0
- package/dist/components/Button/WButtonSelection.vue.d.ts +5 -1
- package/dist/components/Button/WButtonSelection.vue.d.ts.map +1 -1
- package/dist/components/Button/WButtonSelection.vue_vue_type_script_setup_true_lang.js +68 -48
- package/dist/components/Button/WButtonSelectionAction.vue.d.ts +2 -0
- package/dist/components/Button/WButtonSelectionAction.vue.d.ts.map +1 -1
- package/dist/components/Button/WButtonSelectionAction.vue_vue_type_script_setup_true_lang.js +2 -1
- package/dist/components/Button/WButtonTab.vue.d.ts +1 -1
- package/dist/components/Button/WButtonTab.vue.d.ts.map +1 -1
- package/dist/components/Button/WButtonTab.vue_vue_type_script_setup_true_lang.js +14 -7
- package/dist/components/FieldWrapper/WFieldWrapper.vue.d.ts.map +1 -1
- package/dist/components/FieldWrapper/WFieldWrapper.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/InfiniteList/components/InfiniteListHeaderPadding.vue.d.ts.map +1 -1
- package/dist/components/InfiniteList/components/InfiniteListHeaderPadding.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/components/InfoCard/WInfoCard.vue.d.ts +2 -0
- package/dist/components/InfoCard/WInfoCard.vue.d.ts.map +1 -1
- package/dist/components/InfoCard/WInfoCard.vue_vue_type_script_setup_true_lang.js +5 -8
- package/dist/components/Input/WInput.vue.d.ts +5 -5
- package/dist/components/Input/WInput.vue.d.ts.map +1 -1
- package/dist/components/Input/WInput.vue_vue_type_script_setup_true_lang.js +10 -7
- package/dist/components/Input/WInputAsync.vue.d.ts +5 -5
- package/dist/components/Input/WInputAsync.vue.d.ts.map +1 -1
- package/dist/components/Input/WInputAsync.vue_vue_type_script_setup_true_lang.js +5 -1
- package/dist/components/Input/WInputOptions.vue.d.ts +3 -3
- package/dist/components/Input/WInputOptions.vue.d.ts.map +1 -1
- package/dist/components/Input/WInputOptions.vue_vue_type_script_setup_true_lang.js +8 -2
- package/dist/components/Input/WInputSuggest.vue.d.ts +5 -5
- package/dist/components/Input/WInputSuggest.vue.d.ts.map +1 -1
- package/dist/components/Input/WInputSuggest.vue_vue_type_script_setup_true_lang.js +4 -0
- package/dist/components/Input/models/useInputAsync.d.ts +2 -2
- package/dist/components/Input/models/useInputAsync.d.ts.map +1 -1
- package/dist/components/Input/models/useInputAsync.js +3 -3
- package/dist/components/Input/types.d.ts +9 -6
- package/dist/components/Input/types.d.ts.map +1 -1
- package/dist/components/List/WList.vue.d.ts +2 -0
- package/dist/components/List/WList.vue.d.ts.map +1 -1
- package/dist/components/List/WList.vue_vue_type_script_setup_true_lang.js +17 -9
- package/dist/components/List/WListFilter.vue.d.ts +2 -0
- package/dist/components/List/WListFilter.vue.d.ts.map +1 -1
- package/dist/components/List/WListFilter.vue_vue_type_script_setup_true_lang.js +3 -0
- package/dist/components/List/WListHeaderItem.vue.d.ts.map +1 -1
- package/dist/components/List/WListHeaderItem.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/List/components/HeaderSort.vue.d.ts.map +1 -1
- package/dist/components/List/components/HeaderSort.vue_vue_type_script_setup_true_lang.js +14 -9
- package/dist/components/List/components/ListFilterChip.vue.d.ts +24 -0
- package/dist/components/List/components/ListFilterChip.vue.d.ts.map +1 -0
- package/dist/components/List/components/ListFilterChip.vue.js +5 -0
- package/dist/components/List/components/ListFilterChip.vue_vue_type_script_setup_true_lang.js +77 -0
- package/dist/components/List/components/ListFilterGlobal.vue.d.ts +1 -0
- package/dist/components/List/components/ListFilterGlobal.vue.d.ts.map +1 -1
- package/dist/components/List/components/ListFilterGlobal.vue_vue_type_script_setup_true_lang.js +1 -0
- package/dist/components/List/components/ListFilterGlobalItem.vue.d.ts +7 -1
- package/dist/components/List/components/ListFilterGlobalItem.vue.d.ts.map +1 -1
- package/dist/components/List/components/ListFilterGlobalItem.vue_vue_type_script_setup_true_lang.js +16 -7
- package/dist/components/List/components/ListFilterLocal.vue.d.ts +1 -0
- package/dist/components/List/components/ListFilterLocal.vue.d.ts.map +1 -1
- package/dist/components/List/components/ListFilterLocal.vue_vue_type_script_setup_true_lang.js +186 -26
- package/dist/components/List/components/ListFilterLocalItem.vue.d.ts +3 -0
- package/dist/components/List/components/ListFilterLocalItem.vue.d.ts.map +1 -1
- package/dist/components/List/components/ListFilterLocalItem.vue_vue_type_script_setup_true_lang.js +37 -32
- package/dist/components/List/components/ListFilterSearch.vue_vue_type_script_setup_true_lang.js +2 -6
- package/dist/components/List/components/ListToolbar.vue.d.ts +1 -0
- package/dist/components/List/components/ListToolbar.vue.d.ts.map +1 -1
- package/dist/components/List/components/ListToolbar.vue_vue_type_script_setup_true_lang.js +99 -76
- package/dist/components/List/components/ListToolbarFilter.vue.d.ts +14 -0
- package/dist/components/List/components/ListToolbarFilter.vue.d.ts.map +1 -0
- package/dist/components/List/components/ListToolbarFilter.vue.js +5 -0
- package/dist/components/List/components/ListToolbarFilter.vue_vue_type_script_setup_true_lang.js +14 -0
- package/dist/components/List/models/toolbar.d.ts +4 -0
- package/dist/components/List/models/toolbar.d.ts.map +1 -0
- package/dist/components/List/models/toolbar.js +5 -0
- package/dist/components/List/types.d.ts +2 -0
- package/dist/components/List/types.d.ts.map +1 -1
- package/dist/components/List/use/useListConfig.d.ts.map +1 -1
- package/dist/components/List/use/useListConfig.js +9 -1
- package/dist/components/Nav/WNavItem.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/Select/WSelectAsyncSingle.vue.d.ts.map +1 -1
- package/dist/components/Select/WSelectAsyncSingle.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/Select/WSelectSingle.vue.d.ts.map +1 -1
- package/dist/components/Select/WSelectSingle.vue_vue_type_script_setup_true_lang.js +1 -1
- package/dist/components/Select/types.d.ts +1 -1
- package/dist/components/Select/types.d.ts.map +1 -1
- package/dist/components/Slider/WSlider.vue.d.ts.map +1 -1
- package/dist/components/Slider/WSlider.vue_vue_type_script_setup_true_lang.js +1 -2
- package/dist/components/Slider/WSliderRange.vue.d.ts.map +1 -1
- package/dist/components/Slider/WSliderRange.vue_vue_type_script_setup_true_lang.js +3 -4
- package/dist/components/Tabs/WTabs.vue.d.ts.map +1 -1
- package/dist/components/Tabs/WTabs.vue_vue_type_script_setup_true_lang.js +5 -1
- package/dist/components/Tabs/types.d.ts +3 -1
- package/dist/components/Tabs/types.d.ts.map +1 -1
- package/dist/main.d.ts +2 -0
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +4 -2
- package/dist/utils/queryCache.d.ts +5 -0
- package/dist/utils/queryCache.d.ts.map +1 -1
- package/dist/utils/queryCache.js +18 -1
- package/dist/utils/useClearValue.d.ts +4 -0
- package/dist/utils/useClearValue.d.ts.map +1 -0
- package/dist/{components/Select/models → utils}/useClearValue.js +3 -3
- package/dist/utils/useDefaultQuery.d.ts +7 -1
- package/dist/utils/useDefaultQuery.d.ts.map +1 -1
- package/dist/utils/useDefaultQuery.js +20 -9
- package/dist/utils/utils.d.ts.map +1 -1
- package/dist/utils/utils.js +13 -5
- package/docs/components/click-outside.md +1 -1
- package/docs/components/info-card.md +1 -0
- package/docs/components/input.md +13 -9
- package/docs/components/list.md +12 -2
- package/docs/components/tabs.md +5 -3
- package/docs/icons.md +2 -2
- package/docs/llms.txt +1 -1
- package/docs/recipes/list-with-fields.md +34 -21
- package/package.json +4 -1
- package/tailwind-base/css/default.css +9 -0
- package/tailwind-base/css/internal-variables.css +5 -0
- package/dist/components/Select/models/useClearValue.d.ts +0 -5
- package/dist/components/Select/models/useClearValue.d.ts.map +0 -1
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { createElementBlock, createElementVNode, openBlock } from "vue";
|
|
2
|
+
//#region src/assets/icons/IconInfo.svg?component
|
|
3
|
+
var _hoisted_1 = {
|
|
4
|
+
width: "20",
|
|
5
|
+
height: "20",
|
|
6
|
+
viewBox: "0 0 24 24",
|
|
7
|
+
fill: "none",
|
|
8
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
9
|
+
};
|
|
10
|
+
function render(_ctx, _cache) {
|
|
11
|
+
return openBlock(), createElementBlock("svg", _hoisted_1, [..._cache[0] || (_cache[0] = [createElementVNode("path", {
|
|
12
|
+
d: "M12 2c5.5 0 10 4.5 10 10s-4.5 10-10 10S2 17.5 2 12 6.5 2 12 2m0 14v-5",
|
|
13
|
+
stroke: "currentcolor",
|
|
14
|
+
"stroke-linecap": "round",
|
|
15
|
+
"stroke-linejoin": "round",
|
|
16
|
+
"stroke-width": "1.5"
|
|
17
|
+
}, null, -1), createElementVNode("path", {
|
|
18
|
+
d: "M12 8z",
|
|
19
|
+
stroke: "currentcolor",
|
|
20
|
+
"stroke-linecap": "round",
|
|
21
|
+
"stroke-linejoin": "round",
|
|
22
|
+
"stroke-width": "2"
|
|
23
|
+
}, null, -1)])]);
|
|
24
|
+
}
|
|
25
|
+
var IconInfo_default = { render };
|
|
26
|
+
//#endregion
|
|
27
|
+
export { IconInfo_default as default, render };
|
|
@@ -23,8 +23,12 @@ type __VLS_Slots = {
|
|
|
23
23
|
cssClass: string;
|
|
24
24
|
visibleCount: number;
|
|
25
25
|
}) => VNode[];
|
|
26
|
+
/** Filters at the start of the bar while nothing is selected. The actions then move to the end, beside `settings`, and the selection replaces the filters. */
|
|
27
|
+
filter?: () => VNode[];
|
|
26
28
|
/** Content at the end of the bar while nothing is selected, such as list settings. */
|
|
27
|
-
settings?: (
|
|
29
|
+
settings?: (props: {
|
|
30
|
+
isFilterShown: boolean;
|
|
31
|
+
}) => VNode[];
|
|
28
32
|
};
|
|
29
33
|
declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
30
34
|
"clear:selection": () => any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WButtonSelection.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonSelection.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"WButtonSelection.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonSelection.vue"],"names":[],"mappings":"AAsFA;AAoOA,OAAO,EAAC,KAAK,KAAK,EAAiG,MAAM,KAAK,CAAA;AAW9H,KAAK,WAAW,GAAG;IACf,0FAA0F;IAC1F,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,kFAAkF;IAClF,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,mHAAmH;IACnH,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB,CAAC;AAyGJ,KAAK,WAAW,GAAG;IACjB;;;OAGG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE;QAAC,cAAc,EAAE,MAAM,GAAG,SAAS,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,YAAY,EAAE,MAAM,CAAA;KAAC,KAAK,KAAK,EAAE,CAAA;IAC1G,6KAA6K;IAC7K,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE;QAAC,cAAc,EAAE,MAAM,GAAG,SAAS,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAC;QAAC,YAAY,EAAE,MAAM,CAAA;KAAC,KAAK,KAAK,EAAE,CAAA;IACvG,8JAA8J;IAC9J,MAAM,CAAC,EAAE,MAAM,KAAK,EAAE,CAAA;IACtB,sFAAsF;IACtF,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE;QAAC,aAAa,EAAE,OAAO,CAAA;KAAC,KAAK,KAAK,EAAE,CAAA;CACxD,CAAC;AA6OF,QAAA,MAAM,UAAU;;;;;WAvWJ,MAAM;oBAEG,MAAM;mBAEP,MAAM;6EAuWxB,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AAWzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
|
@@ -3,16 +3,12 @@ import IconMore_default from "../../assets/icons/IconMore.js";
|
|
|
3
3
|
import WDropdownAdaptive_default from "../DropdownMenu/WDropdownAdaptive.vue.js";
|
|
4
4
|
import WButtonSelectionAction_default from "./WButtonSelectionAction.vue.js";
|
|
5
5
|
import WButtonSelectionState_default from "./WButtonSelectionState.vue.js";
|
|
6
|
-
import { computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, guardReactiveProps, inject, markRaw, mergeProps, normalizeProps, onBeforeUnmount, onMounted, onUpdated, openBlock, provide, ref, renderSlot, toDisplayString, unref, useTemplateRef, withCtx } from "vue";
|
|
6
|
+
import { computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, guardReactiveProps, inject, markRaw, mergeProps, normalizeClass, normalizeProps, normalizeStyle, onBeforeUnmount, onMounted, onUpdated, openBlock, provide, ref, renderSlot, toDisplayString, unref, useSlots, useTemplateRef, vShow, withCtx, withDirectives } from "vue";
|
|
7
7
|
//#region src/components/Button/WButtonSelection.vue?vue&type=script&setup=true&lang.ts
|
|
8
|
-
var _hoisted_1 = { class: "
|
|
9
|
-
var _hoisted_2 = {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
};
|
|
13
|
-
var _hoisted_3 = { class: "py-2 grid" };
|
|
14
|
-
var _hoisted_4 = { class: "tone-primary text-tone font-semibold" };
|
|
15
|
-
var _hoisted_5 = { class: "sm-not:text-xs" };
|
|
8
|
+
var _hoisted_1 = { class: "py-2 grid" };
|
|
9
|
+
var _hoisted_2 = { class: "tone-primary text-tone font-semibold" };
|
|
10
|
+
var _hoisted_3 = { class: "sm-not:text-xs" };
|
|
11
|
+
var cellClass = "[--w-input-height:var(--w-list-toolbar-height,var(--w-list-toolbar-inherited-height))] [--w-button-height:var(--w-list-toolbar-height,var(--w-list-toolbar-inherited-height))]";
|
|
16
12
|
var WButtonSelection_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
|
|
17
13
|
__name: "WButtonSelection",
|
|
18
14
|
props: {
|
|
@@ -33,6 +29,7 @@ var WButtonSelection_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/
|
|
|
33
29
|
const isOverflowing = ref(false);
|
|
34
30
|
const widths = /* @__PURE__ */ new WeakMap();
|
|
35
31
|
let moreWidth = 0;
|
|
32
|
+
const actionsMinWidth = ref(0);
|
|
36
33
|
const isShown = (element) => element.getClientRects().length > 0;
|
|
37
34
|
const update = () => {
|
|
38
35
|
const row = rowRef.value;
|
|
@@ -50,7 +47,9 @@ var WButtonSelection_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/
|
|
|
50
47
|
return;
|
|
51
48
|
}
|
|
52
49
|
const available = row.clientWidth;
|
|
53
|
-
|
|
50
|
+
const total = items.reduce((sum, element) => sum + widths.get(element), 0);
|
|
51
|
+
actionsMinWidth.value = Math.ceil(more ? moreWidth : total);
|
|
52
|
+
if (total <= available || !more) {
|
|
54
53
|
visibleCount.value = Infinity;
|
|
55
54
|
isOverflowing.value = false;
|
|
56
55
|
return;
|
|
@@ -80,47 +79,68 @@ var WButtonSelection_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/
|
|
|
80
79
|
observer?.disconnect();
|
|
81
80
|
observer = null;
|
|
82
81
|
});
|
|
82
|
+
const slots = useSlots();
|
|
83
|
+
const isFilterShown = computed(() => !!slots.filter && !props.selectedCount);
|
|
83
84
|
return (_ctx, _cache) => {
|
|
84
|
-
return openBlock(), createElementBlock("div",
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
"
|
|
98
|
-
|
|
99
|
-
class: ["shrink-0 border-l border-solid border-line", { hidden: !isOverflowing.value }]
|
|
100
|
-
}, { "data-selection-more": "" }, { onClick: _cache[0] || (_cache[0] = ($event) => isOpen.value = !isOpen.value) }), null, 16, [
|
|
101
|
-
"icon",
|
|
102
|
-
"aria-expanded",
|
|
103
|
-
"disable-message",
|
|
104
|
-
"class"
|
|
105
|
-
])]),
|
|
106
|
-
header: withCtx(() => [..._cache[3] || (_cache[3] = [createTextVNode(" More ", -1)])]),
|
|
107
|
-
content: withCtx(() => [createElementVNode("div", _hoisted_3, [renderSlot(_ctx.$slots, "more", normalizeProps(guardReactiveProps({
|
|
85
|
+
return openBlock(), createElementBlock("div", {
|
|
86
|
+
class: normalizeClass(["list:left---left-inner list:w---width-inner list:sticky grid w-full pb-3 [--w-list-toolbar-inherited-height:var(--w-input-height,2.75rem)]", {
|
|
87
|
+
"grid-cols-[1fr_auto]": !isFilterShown.value,
|
|
88
|
+
"w-selection-filter-grid": isFilterShown.value
|
|
89
|
+
}]),
|
|
90
|
+
style: normalizeStyle(actionsMinWidth.value ? { "--w-selection-actions-width": `${actionsMinWidth.value}px` } : void 0)
|
|
91
|
+
}, [
|
|
92
|
+
_ctx.$slots.filter ? withDirectives((openBlock(), createElementBlock("div", {
|
|
93
|
+
key: 0,
|
|
94
|
+
class: normalizeClass([cellClass, "min-w-0 sm:mr-12 sm-not:col-span-full sm-not:mr-0 sm-not:mb-2 sm-not:px-(--w-list-padding,1rem)"])
|
|
95
|
+
}, [renderSlot(_ctx.$slots, "filter")], 512)), [[vShow, isFilterShown.value]]) : createCommentVNode("", true),
|
|
96
|
+
createElementVNode("div", {
|
|
97
|
+
ref: "row",
|
|
98
|
+
class: normalizeClass(["flex min-w-0", [cellClass, { "justify-end": isFilterShown.value }]])
|
|
99
|
+
}, [renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({
|
|
108
100
|
disableMessage: disableMessageValue.value,
|
|
109
|
-
cssClass: "",
|
|
101
|
+
cssClass: "shrink-0 first-not:border-l border-solid border-line",
|
|
110
102
|
visibleCount: visibleCount.value
|
|
111
|
-
})))
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
103
|
+
}))), _ctx.$slots.more ? (openBlock(), createBlock(WDropdownAdaptive_default, {
|
|
104
|
+
key: 0,
|
|
105
|
+
"is-open": isOpen.value,
|
|
106
|
+
"close-on-click": "",
|
|
107
|
+
onClose: _cache[1] || (_cache[1] = ($event) => isOpen.value = false)
|
|
108
|
+
}, {
|
|
109
|
+
toggle: withCtx(() => [createVNode(WButtonSelectionAction_default, mergeProps({
|
|
110
|
+
title: "More",
|
|
111
|
+
icon: markRaw(unref(IconMore_default)),
|
|
112
|
+
"aria-expanded": isOpen.value,
|
|
113
|
+
"disable-message": isFilterShown.value ? void 0 : disableMessageValue.value,
|
|
114
|
+
class: ["shrink-0 border-solid border-line", {
|
|
115
|
+
hidden: !isOverflowing.value,
|
|
116
|
+
"border-l": !isFilterShown.value || visibleCount.value !== 0
|
|
117
|
+
}]
|
|
118
|
+
}, { "data-selection-more": "" }, { onClick: _cache[0] || (_cache[0] = ($event) => isOpen.value = !isOpen.value) }), null, 16, [
|
|
119
|
+
"icon",
|
|
120
|
+
"aria-expanded",
|
|
121
|
+
"disable-message",
|
|
122
|
+
"class"
|
|
123
|
+
])]),
|
|
124
|
+
header: withCtx(() => [..._cache[3] || (_cache[3] = [createTextVNode(" More ", -1)])]),
|
|
125
|
+
content: withCtx(() => [createElementVNode("div", _hoisted_1, [renderSlot(_ctx.$slots, "more", normalizeProps(guardReactiveProps({
|
|
126
|
+
disableMessage: disableMessageValue.value,
|
|
127
|
+
cssClass: "",
|
|
128
|
+
visibleCount: visibleCount.value
|
|
129
|
+
})))])]),
|
|
130
|
+
_: 3
|
|
131
|
+
}, 8, ["is-open"])) : createCommentVNode("", true)], 2),
|
|
132
|
+
createElementVNode("div", { class: normalizeClass(cellClass) }, [__props.selectedCount ? (openBlock(), createBlock(WButtonSelectionState_default, {
|
|
133
|
+
key: 0,
|
|
134
|
+
onClick: _cache[2] || (_cache[2] = ($event) => _ctx.$emit("clear:selection"))
|
|
135
|
+
}, {
|
|
136
|
+
default: withCtx(() => [
|
|
137
|
+
_cache[4] || (_cache[4] = createElementVNode("span", { class: "sm-not:hidden" }, "Selected\xA0", -1)),
|
|
138
|
+
createElementVNode("span", _hoisted_2, toDisplayString(unref(numberFormatter).format(__props.selectedCount)), 1),
|
|
139
|
+
createElementVNode("span", _hoisted_3, "\xA0" + toDisplayString(__props.title) + toDisplayString(__props.selectedCount === 1 ? "" : "s"), 1)
|
|
140
|
+
]),
|
|
141
|
+
_: 1
|
|
142
|
+
})) : renderSlot(_ctx.$slots, "settings", normalizeProps(guardReactiveProps({ isFilterShown: isFilterShown.value })), void 0, void 0, 1)])
|
|
143
|
+
], 6);
|
|
124
144
|
};
|
|
125
145
|
}
|
|
126
146
|
});
|
|
@@ -28,6 +28,8 @@ type __VLS_Props = {
|
|
|
28
28
|
replace?: boolean;
|
|
29
29
|
};
|
|
30
30
|
type __VLS_Slots = {
|
|
31
|
+
/** Slot for absolute positioned content, like counter */
|
|
32
|
+
default?: () => void;
|
|
31
33
|
/** Rich content of the tooltip, replacing `disableMessage` or `tooltipText`. */
|
|
32
34
|
tooltip?: () => void;
|
|
33
35
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WButtonSelectionAction.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonSelectionAction.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"WButtonSelectionAction.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonSelectionAction.vue"],"names":[],"mappings":"AA2EA;AAAA,OAmIO,KAAK,EAAC,SAAS,EAAC,MAAM,eAAe,CAAA;AAS5C,KAAK,WAAW,GAAG;IACjB,sEAAsE;IACtE,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,wEAAwE;IACxE,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,0BAA0B;IAC1B,IAAI,EAAE,YAAY,CAAA;IAClB,wFAAwF;IACxF,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,2BAA2B;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,6DAA6D;IAC7D,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,0DAA0D;IAC1D,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,oBAAoB;IACpB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,sFAAsF;IACtF,EAAE,CAAC,EAAE,SAAS,CAAC,IAAI,CAAC,CAAA;IACpB,4FAA4F;IAC5F,GAAG,CAAC,EAAE,MAAM,qBAAqB,CAAA;IACjC,kCAAkC;IAClC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,sCAAsC;IACtC,MAAM,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,CAAA;IAChD,2EAA2E;IAC3E,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,CAAC;AASF,KAAK,WAAW,GAAG;IACjB,yDAAyD;IACzD,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,gFAAgF;IAChF,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB,CAAC;AAiOF,QAAA,MAAM,UAAU;;;;kFAGd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
package/dist/components/Button/WButtonSelectionAction.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -66,7 +66,8 @@ var WButtonSelectionAction_vue_vue_type_script_setup_true_lang_default = /*@__PU
|
|
|
66
66
|
fn: withCtx(() => [renderSlot(_ctx.$slots, "tooltip")]),
|
|
67
67
|
key: "0"
|
|
68
68
|
} : void 0]), 1032, ["text"])) : createCommentVNode("", true),
|
|
69
|
-
!__props.disabled && !__props.disableMessage && !__props.loading && !unref(overlay) ? (openBlock(), createBlock(WShine_default, { key: 2 })) : createCommentVNode("", true)
|
|
69
|
+
!__props.disabled && !__props.disableMessage && !__props.loading && !unref(overlay) ? (openBlock(), createBlock(WShine_default, { key: 2 })) : createCommentVNode("", true),
|
|
70
|
+
renderSlot(_ctx.$slots, "default")
|
|
70
71
|
]),
|
|
71
72
|
_: 3
|
|
72
73
|
}, 16, [
|
|
@@ -23,7 +23,7 @@ type __VLS_Props = {
|
|
|
23
23
|
showHasValue?: boolean;
|
|
24
24
|
/** Scrolls a title that doesn't fit into view on hover. */
|
|
25
25
|
enableOverflow?: boolean;
|
|
26
|
-
/** Number shown in
|
|
26
|
+
/** Number shown in a badge after the title, tinted while the tab is open. */
|
|
27
27
|
count?: number;
|
|
28
28
|
};
|
|
29
29
|
type __VLS_Slots = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WButtonTab.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonTab.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"WButtonTab.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonTab.vue"],"names":[],"mappings":"AAgJA;AAgNA,KAAK,WAAW,GAAG;IACjB,uEAAuE;IACvE,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,oDAAoD;IACpD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,oFAAoF;IACpF,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,qCAAqC;IACrC,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,6BAA6B;IAC7B,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,wDAAwD;IACxD,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,kFAAkF;IAClF,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,kEAAkE;IAClE,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,2DAA2D;IAC3D,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,4EAA4E;IAC5E,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,2DAA2D;IAC3D,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,6EAA6E;IAC7E,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAC;AASF,KAAK,WAAW,GAAG;IACjB,+EAA+E;IAC/E,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE;QAAC,UAAU,CAAC,EAAE,OAAO,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAC,KAAK,IAAI,CAAA;IACvF,uDAAuD;IACvD,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE;QAAC,UAAU,CAAC,EAAE,OAAO,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;QAAC,QAAQ,CAAC,EAAE,OAAO,CAAA;KAAC,KAAK,IAAI,CAAA;CACzF,CAAC;AAgVF,QAAA,MAAM,UAAU;;;;kFAGd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
|
@@ -34,7 +34,7 @@ var WButtonTab_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defin
|
|
|
34
34
|
return (_ctx, _cache) => {
|
|
35
35
|
return openBlock(), createElementBlock("button", {
|
|
36
36
|
disabled: __props.disabled,
|
|
37
|
-
class: normalizeClass(["w-ripple-trigger grid select-none grid-cols-[auto_1fr] font-semibold outline-none
|
|
37
|
+
class: normalizeClass(["w-ripple-trigger grid select-none grid-cols-[auto_1fr] font-semibold outline-none", {
|
|
38
38
|
"tone-primary text-tone": !__props.hasError && __props.active,
|
|
39
39
|
"tone-negative text-tone": __props.hasError,
|
|
40
40
|
"tone-positive text-tone": !__props.active && !__props.hasError && __props.hasValue && __props.showHasValue,
|
|
@@ -73,11 +73,18 @@ var WButtonTab_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defin
|
|
|
73
73
|
}])
|
|
74
74
|
}, [
|
|
75
75
|
createElementVNode("div", { class: normalizeClass(["whitespace-nowrap px-3", { "sm-not:pl---inner-margin": __props.side }]) }, [(openBlock(), createBlock(resolveDynamicComponent(__props.enableOverflow ? WTextOverflow_default : WEmptyComponent_default), null, {
|
|
76
|
-
default: withCtx(() => [
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
76
|
+
default: withCtx(() => [
|
|
77
|
+
__props.icon !== void 0 ? (openBlock(), createBlock(Suspense, { key: 0 }, {
|
|
78
|
+
fallback: withCtx(() => [..._cache[1] || (_cache[1] = [createElementVNode("svg", { class: "square-[1.25em] -mt-1 inline" }, [createElementVNode("g")], -1)])]),
|
|
79
|
+
default: withCtx(() => [(openBlock(), createBlock(resolveDynamicComponent(__props.icon), { class: "square-[1.25em] -mt-1 inline" }))]),
|
|
80
|
+
_: 1
|
|
81
|
+
})) : createCommentVNode("", true),
|
|
82
|
+
createTextVNode(" " + toDisplayString(__props.title) + " ", 1),
|
|
83
|
+
__props.count !== void 0 ? (openBlock(), createElementBlock("span", {
|
|
84
|
+
key: 1,
|
|
85
|
+
class: normalizeClass(["ml-0.5 inline-block min-w-[1.75em] rounded-full px-1.5 text-center text-xs/5 tabular-nums", __props.active && !__props.hasError ? "bg-tone-soft" : "bg-surface-muted text-description"])
|
|
86
|
+
}, toDisplayString(unref(numberFormatter).format(__props.count)), 3)) : createCommentVNode("", true)
|
|
87
|
+
]),
|
|
81
88
|
_: 1
|
|
82
89
|
}))], 2),
|
|
83
90
|
__props.statusIcon ? (openBlock(), createBlock(WStatusIcon_default, {
|
|
@@ -100,7 +107,7 @@ var WButtonTab_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defin
|
|
|
100
107
|
}, {
|
|
101
108
|
default: withCtx(() => [__props.hasChanges ? (openBlock(), createElementBlock("div", {
|
|
102
109
|
key: 0,
|
|
103
|
-
class: normalizeClass(["square-2 absolute right-1 top-1 rounded-full
|
|
110
|
+
class: normalizeClass(["square-2 absolute right-1 top-1 rounded-full", {
|
|
104
111
|
"tone-info bg-tone-fill": !__props.hasError,
|
|
105
112
|
"tone-negative bg-tone-fill": __props.hasError
|
|
106
113
|
}])
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WFieldWrapper.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/FieldWrapper/WFieldWrapper.vue"],"names":[],"mappings":"AAqLA;AAkUA,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,SAAS,CAAA;AAE9C,OAAO,EAAkB,KAAK,KAAK,EAAuE,MAAM,KAAK,CAAA;AAerH,KAAK,WAAW,GAAG,iBAAiB,GAAG;IACnC,uJAAuJ;IACvJ,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB,CAAC;AAyGJ,KAAK,WAAW,GAAG;IACjB,iCAAiC;IACjC,KAAK,CAAC,EAAE,MAAM,KAAK,EAAE,CAAA;IACrB,+CAA+C;IAC/C,QAAQ,EAAE,MAAM,KAAK,EAAE,CAAA;IACvB,yCAAyC;IACzC,KAAK,CAAC,EAAE,MAAM,KAAK,EAAE,CAAA;IACrB,qDAAqD;IACrD,MAAM,EAAE,MAAM,KAAK,EAAE,CAAA;IACrB,2JAA2J;IAC3J,KAAK,EAAE,CAAC,KAAK,EAAE;QAAC,EAAE,EAAE,MAAM,CAAC;QAAC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AAsG;IACtG,OAAO,EAAE,CAAC,KAAK,EAAE;QAAC,EAAE,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,OAAO,CAAC;QAAC,UAAU,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;QAAC,UAAU,EAAE,OAAO,CAAA;KAAC,KAAK,KAAK,EAAE,CAAA;CACvH,CAAC;AA4XF,QAAA,MAAM,UAAU;sBAtdO,cAAc,GAAG,IAAI;yBA2BhB,MAAM,eAAc,MAAM;;;;;;;;;;;6EAgcpD,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AAWzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
|
@@ -15,7 +15,7 @@ var _hoisted_2 = {
|
|
|
15
15
|
};
|
|
16
16
|
var _hoisted_3 = {
|
|
17
17
|
key: 0,
|
|
18
|
-
class: "square-2 absolute right-0 top-0 rounded-full bg-(--has-changes-bg)
|
|
18
|
+
class: "square-2 absolute right-0 top-0 rounded-full bg-(--has-changes-bg)"
|
|
19
19
|
};
|
|
20
20
|
var _hoisted_4 = {
|
|
21
21
|
key: 2,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InfiniteListHeaderPadding.vue.d.ts","sourceRoot":"","sources":["../../../../../src/components/InfiniteList/components/InfiniteListHeaderPadding.vue"],"names":[],"mappings":"AAGA;
|
|
1
|
+
{"version":3,"file":"InfiniteListHeaderPadding.vue.d.ts","sourceRoot":"","sources":["../../../../../src/components/InfiniteList/components/InfiniteListHeaderPadding.vue"],"names":[],"mappings":"AAGA;AAsCA,KAAK,WAAW,GAAG;IACjB,cAAc,EAAE,OAAO,GAAG,IAAI,CAAA;IAC9B,YAAY,EAAE,MAAM,CAAA;CACrB,CAAC;AAqCF,QAAA,IAAI,OAAO,IAAW,CAAE;AACxB,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,OAAO,KAAK,GAAG,CAAA;CAAE,CAAC;AAC/C,QAAA,MAAM,UAAU,kSAEd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
|
@@ -15,8 +15,7 @@ var InfiniteListHeaderPadding_vue_vue_type_script_setup_true_lang_default = /*@_
|
|
|
15
15
|
if (!props.isIntersecting && props.headerHeight) updateHeaderPadding(props.headerHeight);
|
|
16
16
|
else updateHeaderPadding(0);
|
|
17
17
|
};
|
|
18
|
-
watch(() => props.isIntersecting, updateHeaderHeight);
|
|
19
|
-
watch(() => props.headerHeight, updateHeaderHeight);
|
|
18
|
+
watch(() => [props.isIntersecting, props.headerHeight], updateHeaderHeight);
|
|
20
19
|
onUnmounted(() => {
|
|
21
20
|
updateHeaderPadding(0);
|
|
22
21
|
});
|
|
@@ -8,6 +8,8 @@ type __VLS_Props = {
|
|
|
8
8
|
icon?: SVGComponent;
|
|
9
9
|
/** Color scheme of the background and icon. Defaults to `SECONDARY`. */
|
|
10
10
|
semanticType?: SemanticType;
|
|
11
|
+
/** Class to apply to icon */
|
|
12
|
+
iconClass?: string;
|
|
11
13
|
};
|
|
12
14
|
type __VLS_Slots = {
|
|
13
15
|
/** Text of the card, next to the icon. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WInfoCard.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/InfoCard/WInfoCard.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"WInfoCard.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/InfoCard/WInfoCard.vue"],"names":[],"mappings":"AA4BA;AAiEA,OAAO,EAAC,YAAY,EAAC,MAAM,sBAAsB,CAAA;AAIjD,KAAK,WAAW,GAAG;IACjB,+DAA+D;IAC/D,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,sBAAsB;IACtB,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,2GAA2G;IAC3G,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,wEAAwE;IACxE,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,6BAA6B;IAC7B,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAC;AAGF,KAAK,WAAW,GAAG;IACjB,0CAA0C;IAC1C,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,uCAAuC;IACvC,GAAG,CAAC,EAAE,MAAM,IAAI,CAAA;IAChB,wDAAwD;IACxD,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;CACpB,CAAC;AA2EF,QAAA,MAAM,UAAU,kSAEd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SemanticType } from "../../utils/SemanticType.js";
|
|
2
2
|
import { useOverlayFrame } from "../../utils/Overlay.js";
|
|
3
|
-
import
|
|
3
|
+
import IconInfo_default from "../../assets/icons/IconInfo.js";
|
|
4
4
|
import { infoCardIconSemanticTypeMap, infoCardSemanticTypeMap } from "./models/utils.js";
|
|
5
5
|
import { createBlock, createCommentVNode, createElementBlock, createElementVNode, defineComponent, normalizeClass, openBlock, renderSlot, resolveDynamicComponent, unref } from "vue";
|
|
6
6
|
//#region src/components/InfoCard/WInfoCard.vue?vue&type=script&setup=true&lang.ts
|
|
@@ -12,7 +12,8 @@ var WInfoCard_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ define
|
|
|
12
12
|
noBg: { type: Boolean },
|
|
13
13
|
noIcon: { type: Boolean },
|
|
14
14
|
icon: {},
|
|
15
|
-
semanticType: {}
|
|
15
|
+
semanticType: {},
|
|
16
|
+
iconClass: {}
|
|
16
17
|
},
|
|
17
18
|
setup(__props) {
|
|
18
19
|
const frame = useOverlayFrame();
|
|
@@ -23,13 +24,9 @@ var WInfoCard_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ define
|
|
|
23
24
|
[unref(infoCardSemanticTypeMap)[__props.semanticType ?? unref(SemanticType).SECONDARY]]: !__props.noBg
|
|
24
25
|
}]) }, [
|
|
25
26
|
renderSlot(_ctx.$slots, "top"),
|
|
26
|
-
createElementVNode("div", _hoisted_1, [!__props.noIcon ? (openBlock(), createBlock(resolveDynamicComponent(__props.icon ?? unref(
|
|
27
|
+
createElementVNode("div", _hoisted_1, [!__props.noIcon ? (openBlock(), createBlock(resolveDynamicComponent(__props.icon ?? unref(IconInfo_default)), {
|
|
27
28
|
key: 0,
|
|
28
|
-
class: normalizeClass(["square-[1.5em]
|
|
29
|
-
[unref(infoCardIconSemanticTypeMap)[__props.semanticType ?? unref(SemanticType).SECONDARY]]: true,
|
|
30
|
-
"rotate-180": !__props.icon && __props.semanticType !== unref(SemanticType).WARNING && __props.semanticType !== unref(SemanticType).NEGATIVE,
|
|
31
|
-
"**:stroke-2": !__props.icon
|
|
32
|
-
}])
|
|
29
|
+
class: normalizeClass(["square-[1.5em]", [unref(infoCardIconSemanticTypeMap)[__props.semanticType ?? unref(SemanticType).SECONDARY], __props.iconClass]])
|
|
33
30
|
}, null, 8, ["class"])) : createCommentVNode("", true), createElementVNode("div", _hoisted_2, [renderSlot(_ctx.$slots, "default")])]),
|
|
34
31
|
renderSlot(_ctx.$slots, "bottom")
|
|
35
32
|
], 2);
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { InputProps, WrapSelection } from './types';
|
|
1
|
+
import { InputClearValue, InputProps, WrapSelection } from './types';
|
|
2
2
|
import { ShowMessage } from '../FieldWrapper/use/useFieldSaved';
|
|
3
3
|
import { CaretOffset } from './models/utils';
|
|
4
|
-
declare const __VLS_export: <Type extends InputType = "text">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
5
|
-
props: import('vue').PublicProps & __VLS_PrettifyLocal<InputProps<Type> & {
|
|
4
|
+
declare const __VLS_export: <Type extends InputType = "text", ClearValue extends InputClearValue = "">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
5
|
+
props: import('vue').PublicProps & __VLS_PrettifyLocal<InputProps<Type, ClearValue> & {
|
|
6
6
|
onBlur?: ((value: FocusEvent) => any) | undefined;
|
|
7
7
|
onClick?: ((value: MouseEvent) => any) | undefined;
|
|
8
8
|
onFocus?: ((value: FocusEvent | undefined) => any) | undefined;
|
|
9
9
|
onMousedown?: ((value: MouseEvent) => any) | undefined;
|
|
10
10
|
onPaste?: (() => any) | undefined;
|
|
11
|
-
"onUpdate:model-value"?: ((value: ((Type extends "number" ? number : string) & {}) | undefined) => any) | undefined;
|
|
11
|
+
"onUpdate:model-value"?: ((value: ((Type extends "number" ? number : string) & {}) | Extract<ClearValue, null> | undefined) => any) | undefined;
|
|
12
12
|
"onClick:clear"?: (() => any) | undefined;
|
|
13
13
|
onRendered?: ((taggedList: HTMLElement[]) => any) | undefined;
|
|
14
14
|
"onKeypress:enter"?: ((value: KeyboardEvent) => any) | undefined;
|
|
@@ -65,7 +65,7 @@ declare const __VLS_export: <Type extends InputType = "text">(__VLS_props: NonNu
|
|
|
65
65
|
bottom?: () => void;
|
|
66
66
|
};
|
|
67
67
|
emit: {
|
|
68
|
-
(e: "update:model-value", value:
|
|
68
|
+
(e: "update:model-value", value: ((Type extends "number" ? number : string) & {}) | Extract<ClearValue, null> | undefined): void;
|
|
69
69
|
(e: "keypress:enter", value: KeyboardEvent): void;
|
|
70
70
|
(e: "keypress:up", value: KeyboardEvent): void;
|
|
71
71
|
(e: "keypress:down", value: KeyboardEvent): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/WInput.vue"],"names":[],"mappings":"AA0XA;
|
|
1
|
+
{"version":3,"file":"WInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/WInput.vue"],"names":[],"mappings":"AA0XA;AA42BA,OAAO,KAAK,EAAC,eAAe,EAAE,UAAU,EAAY,aAAa,EAAC,MAAM,SAAS,CAAA;AACjF,OAAO,KAAK,EAAC,WAAW,EAAC,MAAM,mCAAmC,CAAA;AAoBlE,OAAO,EAAC,KAAK,WAAW,EAAC,MAAM,gBAAgB,CAAA;AAI/C,QAAA,MAAM,YAAY,GAAK,IAAI,SAAS,SAAS,GAAG,MAAM,EAAE,UAAU,SAAS,eAAe,GAAG,EAAE,EAC9F,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,gBAAgB,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW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,GAAG,IAAI;YAE7C,aAAa,SAAS,aAAa,GAAG,IAAI;YAE1C,eAAe,SAAS,aAAa,GAAG,IAAI;YAE5C,iBAAiB,SAAS,aAAa,GAAG,IAAI;YAE9C,aAAa,GAAG,IAAI;YAEpB,OAAO,SAAS,UAAU,GAAG,SAAS,GAAG,IAAI;YAE7C,MAAM,SAAS,UAAU,GAAG,IAAI;YAEhC,OAAO,SAAS,UAAU,GAAG,IAAI;YAEjC,WAAW,SAAS,UAAU,GAAG,IAAI;YAErC,cAAc,SAAS,KAAK,GAAG,IAAI;YAEnC,OAAO,GAAG,IAAI;YAEd,UAAU,cAAc,WAAW,EAAE,GAAG,IAAI;;EAk+C9C,KACQ,OAAO,KAAK,EAAE,KAAK,GAAG;IAAE,KAAK,CAAC,EAAE,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAA;CAAI,CAAC;wBACpE,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,mBAAmB,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,GAAG,GAAG;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG;KAAG,CAAC,IAAI,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,CAAC,GAAG,EAAE,CAAC"}
|
|
@@ -8,6 +8,7 @@ import WFieldWrapper_default from "../FieldWrapper/WFieldWrapper.vue.js";
|
|
|
8
8
|
import { isDragging } from "../../utils/preventDragFile.js";
|
|
9
9
|
import FilePickerSvg_default from "../FilePicker/components/FilePickerSvg.vue.js";
|
|
10
10
|
import IconCheckSecret_default from "../../assets/icons/IconCheckSecret.js";
|
|
11
|
+
import { useClearValue } from "../../utils/useClearValue.js";
|
|
11
12
|
import InputActions_default from "./components/InputActions.vue.js";
|
|
12
13
|
import { buildLines } from "./models/buildLines.js";
|
|
13
14
|
import { useInputAsync } from "./models/useInputAsync.js";
|
|
@@ -70,6 +71,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
70
71
|
textSecure: { type: Boolean },
|
|
71
72
|
placeholderSecure: { type: Boolean },
|
|
72
73
|
allowClear: { type: Boolean },
|
|
74
|
+
clearValue: {},
|
|
73
75
|
allowPaste: { type: Boolean },
|
|
74
76
|
hideInput: { type: Boolean },
|
|
75
77
|
noWrap: { type: Boolean },
|
|
@@ -134,6 +136,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
134
136
|
const InputToolbar = defineAsyncComponent(() => import("./components/InputToolbar.vue.js"));
|
|
135
137
|
const props = __props;
|
|
136
138
|
const emit = __emit;
|
|
139
|
+
const getClearValue = useClearValue(props, "");
|
|
137
140
|
const { isReadonly, isDisabled } = useComponentStates(props);
|
|
138
141
|
const fieldWrapperRef = useTemplateRef("fieldWrapper");
|
|
139
142
|
const contentRef = useTemplateRef("content");
|
|
@@ -246,8 +249,9 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
246
249
|
};
|
|
247
250
|
const updateModelValue = (value, noDebounce = false) => {
|
|
248
251
|
if (props.loading || isDisabled.value || isReadonly.value || props.unclickable) return;
|
|
252
|
+
if (value === "") value = getClearValue();
|
|
249
253
|
let newValue;
|
|
250
|
-
if (props.type === "number") newValue = typeof value === "string"
|
|
254
|
+
if (props.type === "number") newValue = typeof value === "string" ? value.length ? Number.parseFloat(value) : void 0 : value;
|
|
251
255
|
else newValue = value;
|
|
252
256
|
if (!props.textSecure) addToHistory(newValue, noDebounce);
|
|
253
257
|
if (asyncState.isAsync.value) asyncState.value.value = newValue;
|
|
@@ -288,8 +292,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
288
292
|
};
|
|
289
293
|
const clearValue = () => {
|
|
290
294
|
if (isDisabled.value || isReadonly.value || props.unclickable) return;
|
|
291
|
-
|
|
292
|
-
else updateModelValue(void 0, true);
|
|
295
|
+
updateModelValue(getClearValue(), true);
|
|
293
296
|
emit("click:clear");
|
|
294
297
|
};
|
|
295
298
|
const focus = () => {
|
|
@@ -559,7 +562,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
559
562
|
}]) }, null, 8, ["class"])])) : createCommentVNode("", true),
|
|
560
563
|
createElementVNode("div", { class: normalizeClass(["flex-1", {
|
|
561
564
|
"w-full": !__props.hideInput && !_ctx.$slots.prefix,
|
|
562
|
-
"w-option-has-bg-input": _ctx.$slots.prefix,
|
|
565
|
+
"w-option-has-bg-input": _ctx.$slots.prefix && !__props.unclickable,
|
|
563
566
|
"resize-y": __props.resize && __props.textarea,
|
|
564
567
|
"resize-none": !__props.resize && __props.textarea,
|
|
565
568
|
"w-option": !__props.textarea && _ctx.$slots.prefix && !__props.hideInput,
|
|
@@ -568,7 +571,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
568
571
|
"text-accent/50": unref(isDisabled),
|
|
569
572
|
"scrollbar-width-thin min-h-(--w-textarea-height,10rem) w-full overflow-auto overscroll-contain": __props.textarea,
|
|
570
573
|
"h-(--w-textarea-height,10rem)": __props.textarea && __props.resize,
|
|
571
|
-
"absolute": __props.hideInput,
|
|
574
|
+
"absolute": __props.hideInput || __props.unclickable,
|
|
572
575
|
"opacity-0": __props.textSecure && __props.modelValue === true && (!unref(asyncState).isAsync.value || !unref(asyncState).value.value) && !focused
|
|
573
576
|
}]) }, [createElementVNode("div", _hoisted_5, [
|
|
574
577
|
renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps({
|
|
@@ -581,7 +584,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
581
584
|
ref: "input",
|
|
582
585
|
"aria-labelledby": __props.textarea ? `${id}-label` : void 0,
|
|
583
586
|
class: normalizeClass(["w-input min-h-full flex-1 basis-auto appearance-none border-none bg-inherit outline-0 placeholder:text-description disabled:cursor-not-allowed", {
|
|
584
|
-
"w-0 max-w-0": __props.hideInput,
|
|
587
|
+
"w-0 max-w-0": __props.hideInput || __props.unclickable,
|
|
585
588
|
"text-secure w-input-whitespace-pre-wrap break-all": __props.textSecure && !isSecureVisible.value,
|
|
586
589
|
"[-webkit-text-fill-color:transparent]": __props.textTransparent,
|
|
587
590
|
"sm-not:text-base": !__props.unclickable,
|
|
@@ -589,7 +592,7 @@ var WInput_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineCom
|
|
|
589
592
|
"py---w-option-padding": __props.textarea
|
|
590
593
|
}]),
|
|
591
594
|
value: gateValue(unref(asyncState).isAsync.value ? unref(asyncState).value.value : __props.modelValue),
|
|
592
|
-
placeholder: hasNoValue.value ? __props.placeholder : void 0,
|
|
595
|
+
placeholder: hasNoValue.value && !__props.unclickable ? __props.placeholder : void 0,
|
|
593
596
|
type: __props.type ?? "text",
|
|
594
597
|
name: __props.name,
|
|
595
598
|
disabled: unref(isDisabled),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { InputAsyncProps } from './types';
|
|
2
|
-
declare const __VLS_export: <Type extends InputType = "text">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
3
|
-
props: import('vue').PublicProps & __VLS_PrettifyLocal<InputAsyncProps<Type> & {
|
|
4
|
-
"onUpdate:model-value"?: ((value: ((Type extends "number" ? number : string) & {}) | undefined) => any) | undefined;
|
|
1
|
+
import { InputAsyncProps, InputClearValue } from './types';
|
|
2
|
+
declare const __VLS_export: <Type extends InputType = "text", ClearValue extends InputClearValue = "">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
3
|
+
props: import('vue').PublicProps & __VLS_PrettifyLocal<InputAsyncProps<Type, ClearValue> & {
|
|
4
|
+
"onUpdate:model-value"?: ((value: ((Type extends "number" ? number : string) & {}) | Extract<ClearValue, null> | undefined) => any) | undefined;
|
|
5
5
|
}> & (typeof globalThis extends {
|
|
6
6
|
__VLS_PROPS_FALLBACK: infer P;
|
|
7
7
|
} ? P : {});
|
|
@@ -24,7 +24,7 @@ declare const __VLS_export: <Type extends InputType = "text">(__VLS_props: NonNu
|
|
|
24
24
|
focused: boolean;
|
|
25
25
|
}) => void;
|
|
26
26
|
};
|
|
27
|
-
emit: (e: "update:model-value", value:
|
|
27
|
+
emit: (e: "update:model-value", value: ((Type extends "number" ? number : string) & {}) | Extract<ClearValue, null> | undefined) => void;
|
|
28
28
|
}>) => import('vue').VNode & {
|
|
29
29
|
__ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
|
|
30
30
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WInputAsync.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/WInputAsync.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"WInputAsync.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/WInputAsync.vue"],"names":[],"mappings":"AAsDA;AA4HA,OAAO,KAAK,EAAC,eAAe,EAAE,eAAe,EAAC,MAAM,SAAS,CAAA;AAQ7D,QAAA,MAAM,YAAY,GAAK,IAAI,SAAS,SAAS,GAAG,MAAM,EAAE,UAAU,SAAS,eAAe,GAAG,EAAE,EAC9F,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW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put_default from "./WInput.vue.js";
|
|
2
|
-
import { createBlock, createSlots, defineComponent, guardReactiveProps, mergeProps, normalizeProps, openBlock, ref, renderSlot, watch, withCtx } from "vue";
|
|
3
|
+
import { createBlock, createSlots, defineComponent, guardReactiveProps, mergeProps, normalizeProps, openBlock, ref, renderSlot, unref, watch, withCtx } from "vue";
|
|
3
4
|
//#region src/components/Input/WInputAsync.vue?vue&type=script&setup=true&lang.ts
|
|
4
5
|
var WInputAsync_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent({
|
|
5
6
|
inheritAttrs: false,
|
|
@@ -35,6 +36,7 @@ var WInputAsync_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defi
|
|
|
35
36
|
textSecure: { type: Boolean },
|
|
36
37
|
placeholderSecure: { type: Boolean },
|
|
37
38
|
allowClear: { type: Boolean },
|
|
39
|
+
clearValue: {},
|
|
38
40
|
allowPaste: { type: Boolean },
|
|
39
41
|
hideInput: { type: Boolean },
|
|
40
42
|
noWrap: { type: Boolean },
|
|
@@ -78,6 +80,7 @@ var WInputAsync_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defi
|
|
|
78
80
|
emits: ["update:model-value"],
|
|
79
81
|
setup(__props, { emit: __emit }) {
|
|
80
82
|
const props = __props;
|
|
83
|
+
const getClearValue = useClearValue(props, "");
|
|
81
84
|
const emit = __emit;
|
|
82
85
|
const errorMessageValue = ref();
|
|
83
86
|
const getErrorMessage = (value) => {
|
|
@@ -96,6 +99,7 @@ var WInputAsync_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defi
|
|
|
96
99
|
return (_ctx, _cache) => {
|
|
97
100
|
return openBlock(), createBlock(WInput_default, mergeProps({ ref: "input" }, {
|
|
98
101
|
...props,
|
|
102
|
+
clearValue: unref(getClearValue)(),
|
|
99
103
|
async: true,
|
|
100
104
|
errorMessage: errorMessageValue.value ?? __props.errorMessage
|
|
101
105
|
}, {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { InputOptionsProps } from './types';
|
|
1
|
+
import { InputClearValue, InputOptionsProps } from './types';
|
|
2
2
|
declare const __VLS_export: <Type extends InputType = "text", Option extends Record<string, any> & {
|
|
3
3
|
id: number;
|
|
4
4
|
} = Record<string, any> & {
|
|
5
5
|
id: number;
|
|
6
|
-
}>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
7
|
-
props: import('vue').PublicProps & __VLS_PrettifyLocal<InputOptionsProps<Type, Option> & {
|
|
6
|
+
}, ClearValue extends InputClearValue = "">(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
7
|
+
props: import('vue').PublicProps & __VLS_PrettifyLocal<InputOptionsProps<Type, Option, ClearValue> & {
|
|
8
8
|
"onUpdate:model-value"?: ((value: (Type extends "number" ? number : string) | null) => any) | undefined;
|
|
9
9
|
}> & (typeof globalThis extends {
|
|
10
10
|
__VLS_PROPS_FALLBACK: infer P;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WInputOptions.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/WInputOptions.vue"],"names":[],"mappings":"AAgFA;
|
|
1
|
+
{"version":3,"file":"WInputOptions.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/WInputOptions.vue"],"names":[],"mappings":"AAgFA;AA4NA,OAAO,KAAK,EAAC,eAAe,EAAE,iBAAiB,EAAC,MAAM,SAAS,CAAA;AAW/D,QAAA,MAAM,YAAY,GAAK,IAAI,SAAS,SAAS,G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