@katlux/toolkit 0.1.0-beta.50 → 0.1.0-beta.52
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/module.json +1 -1
- package/dist/runtime/components/KButton/KButton.global.d.vue.ts +1 -1
- package/dist/runtime/components/KButton/KButton.global.vue.d.ts +1 -1
- package/dist/runtime/components/KButton/KButton.logic.d.ts +1 -1
- package/dist/runtime/components/KCheckbox/KCheckbox.global.d.vue.ts +21 -0
- package/dist/runtime/components/KCheckbox/KCheckbox.global.vue +3 -1
- package/dist/runtime/components/KCheckbox/KCheckbox.global.vue.d.ts +21 -0
- package/dist/runtime/components/KCheckbox/KCheckbox.logic.d.ts +11 -0
- package/dist/runtime/components/KCheckbox/KCheckbox.logic.js +9 -0
- package/dist/runtime/components/KCombobox/KCombobox.global.d.vue.ts +47 -6
- package/dist/runtime/components/KCombobox/KCombobox.global.vue +9 -3
- package/dist/runtime/components/KCombobox/KCombobox.global.vue.d.ts +47 -6
- package/dist/runtime/components/KCombobox/KCombobox.logic.d.ts +25 -3
- package/dist/runtime/components/KCombobox/KCombobox.logic.js +61 -6
- package/dist/runtime/components/KCompositeInput/KCompositeInput.global.d.vue.ts +29 -9
- package/dist/runtime/components/KCompositeInput/KCompositeInput.global.vue +2 -21
- package/dist/runtime/components/KCompositeInput/KCompositeInput.global.vue.d.ts +29 -9
- package/dist/runtime/components/KCompositeInput/KCompositeInput.logic.d.ts +15 -4
- package/dist/runtime/components/KCompositeInput/KCompositeInput.logic.js +16 -5
- package/dist/runtime/components/KDatatable/KDataIterator.global.d.vue.ts +1 -1
- package/dist/runtime/components/KDatatable/KDataIterator.global.vue.d.ts +1 -1
- package/dist/runtime/components/KDatePicker/KDatePicker.global.d.vue.ts +22 -1
- package/dist/runtime/components/KDatePicker/KDatePicker.global.vue +3 -1
- package/dist/runtime/components/KDatePicker/KDatePicker.global.vue.d.ts +22 -1
- package/dist/runtime/components/KDatePicker/KDatePicker.logic.d.ts +11 -0
- package/dist/runtime/components/KDatePicker/KDatePicker.logic.js +9 -0
- package/dist/runtime/components/KDateTimePicker/KDateTimePicker.global.d.vue.ts +22 -1
- package/dist/runtime/components/KDateTimePicker/KDateTimePicker.global.vue +3 -1
- package/dist/runtime/components/KDateTimePicker/KDateTimePicker.global.vue.d.ts +22 -1
- package/dist/runtime/components/KDateTimePicker/KDateTimePicker.logic.d.ts +11 -0
- package/dist/runtime/components/KDateTimePicker/KDateTimePicker.logic.js +9 -0
- package/dist/runtime/components/KHourPicker/KHourPicker.global.d.vue.ts +21 -0
- package/dist/runtime/components/KHourPicker/KHourPicker.global.vue +3 -1
- package/dist/runtime/components/KHourPicker/KHourPicker.global.vue.d.ts +21 -0
- package/dist/runtime/components/KHourPicker/KHourPicker.logic.d.ts +12 -0
- package/dist/runtime/components/KHourPicker/KHourPicker.logic.js +9 -0
- package/dist/runtime/components/KLoader/KLoader.global.d.vue.ts +1 -1
- package/dist/runtime/components/KLoader/KLoader.global.vue.d.ts +1 -1
- package/dist/runtime/components/KMaskTextbox/KMaskTextbox.global.d.vue.ts +21 -0
- package/dist/runtime/components/KMaskTextbox/KMaskTextbox.global.vue +3 -1
- package/dist/runtime/components/KMaskTextbox/KMaskTextbox.global.vue.d.ts +21 -0
- package/dist/runtime/components/KMaskTextbox/KMaskTextbox.logic.d.ts +11 -0
- package/dist/runtime/components/KMaskTextbox/KMaskTextbox.logic.js +9 -0
- package/dist/runtime/components/KRadiobox/KRadiobox.global.d.vue.ts +21 -0
- package/dist/runtime/components/KRadiobox/KRadiobox.global.vue +3 -1
- package/dist/runtime/components/KRadiobox/KRadiobox.global.vue.d.ts +21 -0
- package/dist/runtime/components/KRadiobox/KRadiobox.logic.d.ts +11 -0
- package/dist/runtime/components/KRadiobox/KRadiobox.logic.js +9 -0
- package/dist/runtime/components/KTextarea/KTextarea.global.d.vue.ts +21 -0
- package/dist/runtime/components/KTextarea/KTextarea.global.vue +3 -1
- package/dist/runtime/components/KTextarea/KTextarea.global.vue.d.ts +21 -0
- package/dist/runtime/components/KTextarea/KTextarea.logic.d.ts +11 -0
- package/dist/runtime/components/KTextarea/KTextarea.logic.js +9 -0
- package/dist/runtime/components/KTextbox/KTextbox.global.d.vue.ts +20 -0
- package/dist/runtime/components/KTextbox/KTextbox.global.vue +3 -1
- package/dist/runtime/components/KTextbox/KTextbox.global.vue.d.ts +20 -0
- package/dist/runtime/components/KTextbox/KTextbox.logic.d.ts +11 -0
- package/dist/runtime/components/KTextbox/KTextbox.logic.js +9 -0
- package/dist/runtime/components/KToast/KToast.global.d.vue.ts +57 -0
- package/dist/runtime/components/KToast/KToast.global.vue +32 -0
- package/dist/runtime/components/KToast/KToast.global.vue.d.ts +57 -0
- package/dist/runtime/components/KToast/KToast.logic.d.ts +34 -0
- package/dist/runtime/components/KToast/KToast.logic.js +47 -0
- package/dist/runtime/components/KTree/KTree.global.d.vue.ts +1 -1
- package/dist/runtime/components/KTree/KTree.global.vue.d.ts +1 -1
- package/dist/runtime/components/KTreePicker/KTreePicker.global.d.vue.ts +35 -6
- package/dist/runtime/components/KTreePicker/KTreePicker.global.vue +8 -1
- package/dist/runtime/components/KTreePicker/KTreePicker.global.vue.d.ts +35 -6
- package/dist/runtime/components/KTreePicker/KTreePicker.logic.d.ts +17 -0
- package/dist/runtime/components/KTreePicker/KTreePicker.logic.js +18 -1
- package/dist/runtime/presets/default/assets/scss/index.css +27 -0
- package/dist/runtime/presets/default/assets/scss/index.scss +30 -0
- package/dist/runtime/presets/default/components/KCheckbox/KCheckbox.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KCheckbox/KCheckbox.vue +10 -6
- package/dist/runtime/presets/default/components/KCheckbox/KCheckbox.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KCombobox/KCombobox.d.vue.ts +4 -2
- package/dist/runtime/presets/default/components/KCombobox/KCombobox.vue +25 -21
- package/dist/runtime/presets/default/components/KCombobox/KCombobox.vue.d.ts +4 -2
- package/dist/runtime/presets/default/components/KCompositeInput/KCompositeInput.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KCompositeInput/KCompositeInput.vue +91 -79
- package/dist/runtime/presets/default/components/KCompositeInput/KCompositeInput.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KDatePicker/KDatePicker.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KDatePicker/KDatePicker.vue +13 -1
- package/dist/runtime/presets/default/components/KDatePicker/KDatePicker.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KDateTimePicker/KDateTimePicker.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KDateTimePicker/KDateTimePicker.vue +12 -1
- package/dist/runtime/presets/default/components/KDateTimePicker/KDateTimePicker.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KHourPicker/KHourPicker.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KHourPicker/KHourPicker.vue +4 -0
- package/dist/runtime/presets/default/components/KHourPicker/KHourPicker.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KLoader/KLoader.vue +13 -2
- package/dist/runtime/presets/default/components/KMaskTextbox/KMaskTextbox.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KMaskTextbox/KMaskTextbox.vue +4 -0
- package/dist/runtime/presets/default/components/KMaskTextbox/KMaskTextbox.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KRadiobox/KRadiobox.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KRadiobox/KRadiobox.vue +10 -6
- package/dist/runtime/presets/default/components/KRadiobox/KRadiobox.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KTextarea/KTextarea.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KTextarea/KTextarea.vue +5 -1
- package/dist/runtime/presets/default/components/KTextarea/KTextarea.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KTextbox/KTextbox.d.vue.ts +2 -0
- package/dist/runtime/presets/default/components/KTextbox/KTextbox.vue +7 -3
- package/dist/runtime/presets/default/components/KTextbox/KTextbox.vue.d.ts +2 -0
- package/dist/runtime/presets/default/components/KToast/KToast.d.vue.ts +17 -0
- package/dist/runtime/presets/default/components/KToast/KToast.vue +118 -0
- package/dist/runtime/presets/default/components/KToast/KToast.vue.d.ts +17 -0
- package/dist/runtime/presets/default/components/KTreePicker/KTreePicker.d.vue.ts +4 -0
- package/dist/runtime/presets/default/components/KTreePicker/KTreePicker.vue +11 -1
- package/dist/runtime/presets/default/components/KTreePicker/KTreePicker.vue.d.ts +4 -0
- package/package.json +1 -1
|
@@ -9,24 +9,6 @@ import KCompositeInputDefault from "../../presets/default/components/KCompositeI
|
|
|
9
9
|
import { CFlatClientDataProvider } from "@katlux/providers";
|
|
10
10
|
const props = defineProps(KCompositeInputDefaultProps);
|
|
11
11
|
const emit = defineEmits(["update:selectionValue", "update:inputValue", "update:modelValue"]);
|
|
12
|
-
const internalDataProvider = shallowRef(null);
|
|
13
|
-
function updateDataProvider(items) {
|
|
14
|
-
if (Array.isArray(items)) {
|
|
15
|
-
const provider = new CFlatClientDataProvider();
|
|
16
|
-
provider.setData(items.map((item) => {
|
|
17
|
-
if (typeof item === "string") {
|
|
18
|
-
return { [props.labelField || "label"]: item, [props.valueField || "value"]: item };
|
|
19
|
-
}
|
|
20
|
-
return item;
|
|
21
|
-
}));
|
|
22
|
-
internalDataProvider.value = provider;
|
|
23
|
-
} else {
|
|
24
|
-
internalDataProvider.value = items;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
watch(() => props.items, (newItems) => {
|
|
28
|
-
updateDataProvider(newItems);
|
|
29
|
-
}, { immediate: true });
|
|
30
12
|
const {
|
|
31
13
|
internalSelectionValue,
|
|
32
14
|
internalInputValue,
|
|
@@ -36,12 +18,11 @@ const {
|
|
|
36
18
|
const presetComponent = usePresetComponent("KCompositeInput", KCompositeInputDefault);
|
|
37
19
|
const templateProps = computed(() => ({
|
|
38
20
|
...props,
|
|
39
|
-
dataProvider: internalDataProvider.value,
|
|
40
21
|
selectionValue: internalSelectionValue.value,
|
|
41
22
|
inputValue: internalInputValue.value,
|
|
42
23
|
modelValue: props.modelValue,
|
|
43
|
-
// Determine if searchbox is needed
|
|
44
|
-
searchbox:
|
|
24
|
+
// Determine if searchbox is needed
|
|
25
|
+
searchbox: props.searchbox
|
|
45
26
|
}));
|
|
46
27
|
function updateSelection(val) {
|
|
47
28
|
internalSelectionValue.value = val;
|
|
@@ -12,8 +12,8 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
12
12
|
type: import("vue").PropType<import("./KCompositeInput.logic.js").ICompositeItem[]>;
|
|
13
13
|
default: () => never[];
|
|
14
14
|
};
|
|
15
|
-
|
|
16
|
-
type: import("vue").PropType<
|
|
15
|
+
dataProvider: {
|
|
16
|
+
type: import("vue").PropType<import("@katlux/providers").ADataProvider>;
|
|
17
17
|
required: boolean;
|
|
18
18
|
};
|
|
19
19
|
type: {
|
|
@@ -60,6 +60,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
60
60
|
type: StringConstructor;
|
|
61
61
|
default: undefined;
|
|
62
62
|
};
|
|
63
|
+
validation: {
|
|
64
|
+
type: import("vue").PropType<KCompositeInputProps["validation"]>;
|
|
65
|
+
default: null;
|
|
66
|
+
validator: (value: string) => boolean;
|
|
67
|
+
};
|
|
68
|
+
validationText: {
|
|
69
|
+
type: StringConstructor;
|
|
70
|
+
default: string;
|
|
71
|
+
};
|
|
63
72
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
64
73
|
"update:modelValue": (value: import("./KCompositeInput.logic.js").ICompositeItem[]) => any;
|
|
65
74
|
"update:selectionValue": (value: any) => any;
|
|
@@ -77,8 +86,8 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
77
86
|
type: import("vue").PropType<import("./KCompositeInput.logic.js").ICompositeItem[]>;
|
|
78
87
|
default: () => never[];
|
|
79
88
|
};
|
|
80
|
-
|
|
81
|
-
type: import("vue").PropType<
|
|
89
|
+
dataProvider: {
|
|
90
|
+
type: import("vue").PropType<import("@katlux/providers").ADataProvider>;
|
|
82
91
|
required: boolean;
|
|
83
92
|
};
|
|
84
93
|
type: {
|
|
@@ -125,25 +134,36 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
125
134
|
type: StringConstructor;
|
|
126
135
|
default: undefined;
|
|
127
136
|
};
|
|
137
|
+
validation: {
|
|
138
|
+
type: import("vue").PropType<KCompositeInputProps["validation"]>;
|
|
139
|
+
default: null;
|
|
140
|
+
validator: (value: string) => boolean;
|
|
141
|
+
};
|
|
142
|
+
validationText: {
|
|
143
|
+
type: StringConstructor;
|
|
144
|
+
default: string;
|
|
145
|
+
};
|
|
128
146
|
}>> & Readonly<{
|
|
129
147
|
"onUpdate:modelValue"?: ((value: import("./KCompositeInput.logic.js").ICompositeItem[]) => any) | undefined;
|
|
130
148
|
"onUpdate:selectionValue"?: ((value: any) => any) | undefined;
|
|
131
149
|
"onUpdate:inputValue"?: ((value: any) => any) | undefined;
|
|
132
150
|
}>, {
|
|
133
151
|
type: import("./KCompositeInput.logic.js").CompositeInputType;
|
|
152
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
153
|
+
validationText: string;
|
|
134
154
|
modelValue: import("./KCompositeInput.logic.js").ICompositeItem[];
|
|
155
|
+
searchbox: boolean;
|
|
156
|
+
labelField: string;
|
|
157
|
+
placeholder: string;
|
|
158
|
+
teleportTo: string;
|
|
159
|
+
valueField: string;
|
|
135
160
|
inputType: "number" | "text" | "url" | "search" | "password" | "email" | "tel" | undefined;
|
|
136
161
|
selectionValue: string | number | Record<string, any> | unknown[];
|
|
137
162
|
inputValue: string | number | Record<string, any> | unknown[];
|
|
138
163
|
selectionSide: import("./KCompositeInput.logic.js").SelectionSide;
|
|
139
164
|
mask: string;
|
|
140
|
-
labelField: string;
|
|
141
|
-
valueField: string;
|
|
142
|
-
placeholder: string;
|
|
143
165
|
inputPlaceholder: string;
|
|
144
|
-
searchbox: boolean;
|
|
145
166
|
showClear: boolean;
|
|
146
|
-
teleportTo: string;
|
|
147
167
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
148
168
|
declare const _default: typeof __VLS_export;
|
|
149
169
|
export default _default;
|
|
@@ -10,7 +10,7 @@ export interface KCompositeInputProps {
|
|
|
10
10
|
selectionValue: any;
|
|
11
11
|
inputValue: any;
|
|
12
12
|
modelValue?: ICompositeItem[];
|
|
13
|
-
|
|
13
|
+
dataProvider: ADataProvider;
|
|
14
14
|
type?: CompositeInputType;
|
|
15
15
|
selectionSide?: SelectionSide;
|
|
16
16
|
inputType?: 'text' | 'password' | 'email' | 'url' | 'tel' | 'search' | 'number';
|
|
@@ -22,6 +22,8 @@ export interface KCompositeInputProps {
|
|
|
22
22
|
searchbox?: boolean;
|
|
23
23
|
showClear?: boolean;
|
|
24
24
|
teleportTo?: string;
|
|
25
|
+
validation?: 'success' | 'warning' | 'error' | null;
|
|
26
|
+
validationText?: string;
|
|
25
27
|
}
|
|
26
28
|
export interface KCompositeInputEmits {
|
|
27
29
|
(e: 'update:selectionValue', value: any): void;
|
|
@@ -41,8 +43,8 @@ export declare const KCompositeInputDefaultProps: {
|
|
|
41
43
|
type: PropType<ICompositeItem[]>;
|
|
42
44
|
default: () => never[];
|
|
43
45
|
};
|
|
44
|
-
|
|
45
|
-
type: PropType<
|
|
46
|
+
dataProvider: {
|
|
47
|
+
type: PropType<ADataProvider>;
|
|
46
48
|
required: boolean;
|
|
47
49
|
};
|
|
48
50
|
type: {
|
|
@@ -89,6 +91,15 @@ export declare const KCompositeInputDefaultProps: {
|
|
|
89
91
|
type: StringConstructor;
|
|
90
92
|
default: undefined;
|
|
91
93
|
};
|
|
94
|
+
validation: {
|
|
95
|
+
type: PropType<KCompositeInputProps["validation"]>;
|
|
96
|
+
default: null;
|
|
97
|
+
validator: (value: string) => boolean;
|
|
98
|
+
};
|
|
99
|
+
validationText: {
|
|
100
|
+
type: StringConstructor;
|
|
101
|
+
default: string;
|
|
102
|
+
};
|
|
92
103
|
};
|
|
93
104
|
export declare function useKCompositeInputLogic(props: KCompositeInputProps, emit: KCompositeInputEmits): {
|
|
94
105
|
internalSelectionValue: import("vue").WritableComputedRef<any, any>;
|
|
@@ -96,7 +107,7 @@ export declare function useKCompositeInputLogic(props: KCompositeInputProps, emi
|
|
|
96
107
|
selectionProps: import("vue").ComputedRef<{
|
|
97
108
|
modelValue: any;
|
|
98
109
|
'onUpdate:modelValue': (val: any) => any;
|
|
99
|
-
|
|
110
|
+
dataProvider: ADataProvider;
|
|
100
111
|
labelField: string | undefined;
|
|
101
112
|
valueField: string | undefined;
|
|
102
113
|
placeholder: string | undefined;
|
|
@@ -12,8 +12,8 @@ export const KCompositeInputDefaultProps = {
|
|
|
12
12
|
type: Array,
|
|
13
13
|
default: () => []
|
|
14
14
|
},
|
|
15
|
-
|
|
16
|
-
type:
|
|
15
|
+
dataProvider: {
|
|
16
|
+
type: Object,
|
|
17
17
|
required: true
|
|
18
18
|
},
|
|
19
19
|
type: {
|
|
@@ -59,6 +59,15 @@ export const KCompositeInputDefaultProps = {
|
|
|
59
59
|
teleportTo: {
|
|
60
60
|
type: String,
|
|
61
61
|
default: void 0
|
|
62
|
+
},
|
|
63
|
+
validation: {
|
|
64
|
+
type: String,
|
|
65
|
+
default: null,
|
|
66
|
+
validator: (value) => [null, "success", "warning", "error"].includes(value)
|
|
67
|
+
},
|
|
68
|
+
validationText: {
|
|
69
|
+
type: String,
|
|
70
|
+
default: ""
|
|
62
71
|
}
|
|
63
72
|
};
|
|
64
73
|
export function useKCompositeInputLogic(props, emit) {
|
|
@@ -71,8 +80,10 @@ export function useKCompositeInputLogic(props, emit) {
|
|
|
71
80
|
const resolvedSelectionItem = computed(() => {
|
|
72
81
|
if (props.selectionValue === null || props.selectionValue === void 0) return null;
|
|
73
82
|
if (typeof props.selectionValue === "object") return props.selectionValue;
|
|
74
|
-
if (
|
|
75
|
-
|
|
83
|
+
if (props.dataProvider && typeof props.dataProvider === "object") {
|
|
84
|
+
const provider = props.dataProvider;
|
|
85
|
+
const data = provider.allData?.value || provider.pageData?.value || [];
|
|
86
|
+
return data.find((item) => getSelectionKey(item) === props.selectionValue) || props.selectionValue;
|
|
76
87
|
}
|
|
77
88
|
return props.selectionValue;
|
|
78
89
|
});
|
|
@@ -123,7 +134,7 @@ export function useKCompositeInputLogic(props, emit) {
|
|
|
123
134
|
const selectionProps = computed(() => ({
|
|
124
135
|
modelValue: internalSelectionValue.value,
|
|
125
136
|
"onUpdate:modelValue": (val) => internalSelectionValue.value = val,
|
|
126
|
-
|
|
137
|
+
dataProvider: props.dataProvider,
|
|
127
138
|
labelField: props.labelField,
|
|
128
139
|
valueField: props.valueField,
|
|
129
140
|
placeholder: props.placeholder,
|
|
@@ -11,9 +11,9 @@ interface Props {
|
|
|
11
11
|
page?: number;
|
|
12
12
|
}
|
|
13
13
|
declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {
|
|
14
|
-
bulkActions: IKDatatableAction[];
|
|
15
14
|
search: string;
|
|
16
15
|
loading: boolean;
|
|
16
|
+
bulkActions: IKDatatableAction[];
|
|
17
17
|
visibleFields: Array<string> | null;
|
|
18
18
|
rowActions: IKDatatableAction[];
|
|
19
19
|
itemsPerPage: number;
|
|
@@ -11,9 +11,9 @@ interface Props {
|
|
|
11
11
|
page?: number;
|
|
12
12
|
}
|
|
13
13
|
declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {
|
|
14
|
-
bulkActions: IKDatatableAction[];
|
|
15
14
|
search: string;
|
|
16
15
|
loading: boolean;
|
|
16
|
+
bulkActions: IKDatatableAction[];
|
|
17
17
|
visibleFields: Array<string> | null;
|
|
18
18
|
rowActions: IKDatatableAction[];
|
|
19
19
|
itemsPerPage: number;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type KDatePickerProps } from './KDatePicker.logic.js';
|
|
1
2
|
declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
3
|
format: {
|
|
3
4
|
type: StringConstructor;
|
|
@@ -31,6 +32,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
31
32
|
type: import("vue").PropType<string>;
|
|
32
33
|
default: undefined;
|
|
33
34
|
};
|
|
35
|
+
validation: {
|
|
36
|
+
type: import("vue").PropType<KDatePickerProps["validation"]>;
|
|
37
|
+
default: null;
|
|
38
|
+
validator: (value: string) => boolean;
|
|
39
|
+
};
|
|
40
|
+
validationText: {
|
|
41
|
+
type: StringConstructor;
|
|
42
|
+
default: string;
|
|
43
|
+
};
|
|
34
44
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
35
45
|
"update:modelValue": (value: string | Date) => any;
|
|
36
46
|
"update:maskedModel": (value: string) => any;
|
|
@@ -70,6 +80,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
70
80
|
type: import("vue").PropType<string>;
|
|
71
81
|
default: undefined;
|
|
72
82
|
};
|
|
83
|
+
validation: {
|
|
84
|
+
type: import("vue").PropType<KDatePickerProps["validation"]>;
|
|
85
|
+
default: null;
|
|
86
|
+
validator: (value: string) => boolean;
|
|
87
|
+
};
|
|
88
|
+
validationText: {
|
|
89
|
+
type: StringConstructor;
|
|
90
|
+
default: string;
|
|
91
|
+
};
|
|
73
92
|
}>> & Readonly<{
|
|
74
93
|
"onUpdate:modelValue"?: ((value: string | Date) => any) | undefined;
|
|
75
94
|
"onUpdate:maskedModel"?: ((value: string) => any) | undefined;
|
|
@@ -79,9 +98,11 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
79
98
|
}>, {
|
|
80
99
|
isOpen: boolean;
|
|
81
100
|
day: string | Date;
|
|
101
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
102
|
+
validationText: string;
|
|
82
103
|
modelValue: string | Date;
|
|
83
|
-
showClear: boolean;
|
|
84
104
|
teleportTo: string;
|
|
105
|
+
showClear: boolean;
|
|
85
106
|
format: string;
|
|
86
107
|
calendarDefinedDays: import("../KCalendar/types.js").IDefinedDay[];
|
|
87
108
|
calendarMarkedDays: import("../KCalendar/types.js").IMarkedDay[];
|
|
@@ -26,7 +26,9 @@ const templateProps = computed(() => ({
|
|
|
26
26
|
textboxClicked,
|
|
27
27
|
onClear: handleClear,
|
|
28
28
|
dateSelected: handleDateSelected,
|
|
29
|
-
teleportTo: props.teleportTo
|
|
29
|
+
teleportTo: props.teleportTo,
|
|
30
|
+
validation: props.validation,
|
|
31
|
+
validationText: props.validationText
|
|
30
32
|
}));
|
|
31
33
|
const handleClear = () => {
|
|
32
34
|
_date.value = "";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type KDatePickerProps } from './KDatePicker.logic.js';
|
|
1
2
|
declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
3
|
format: {
|
|
3
4
|
type: StringConstructor;
|
|
@@ -31,6 +32,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
31
32
|
type: import("vue").PropType<string>;
|
|
32
33
|
default: undefined;
|
|
33
34
|
};
|
|
35
|
+
validation: {
|
|
36
|
+
type: import("vue").PropType<KDatePickerProps["validation"]>;
|
|
37
|
+
default: null;
|
|
38
|
+
validator: (value: string) => boolean;
|
|
39
|
+
};
|
|
40
|
+
validationText: {
|
|
41
|
+
type: StringConstructor;
|
|
42
|
+
default: string;
|
|
43
|
+
};
|
|
34
44
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
35
45
|
"update:modelValue": (value: string | Date) => any;
|
|
36
46
|
"update:maskedModel": (value: string) => any;
|
|
@@ -70,6 +80,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
70
80
|
type: import("vue").PropType<string>;
|
|
71
81
|
default: undefined;
|
|
72
82
|
};
|
|
83
|
+
validation: {
|
|
84
|
+
type: import("vue").PropType<KDatePickerProps["validation"]>;
|
|
85
|
+
default: null;
|
|
86
|
+
validator: (value: string) => boolean;
|
|
87
|
+
};
|
|
88
|
+
validationText: {
|
|
89
|
+
type: StringConstructor;
|
|
90
|
+
default: string;
|
|
91
|
+
};
|
|
73
92
|
}>> & Readonly<{
|
|
74
93
|
"onUpdate:modelValue"?: ((value: string | Date) => any) | undefined;
|
|
75
94
|
"onUpdate:maskedModel"?: ((value: string) => any) | undefined;
|
|
@@ -79,9 +98,11 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
79
98
|
}>, {
|
|
80
99
|
isOpen: boolean;
|
|
81
100
|
day: string | Date;
|
|
101
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
102
|
+
validationText: string;
|
|
82
103
|
modelValue: string | Date;
|
|
83
|
-
showClear: boolean;
|
|
84
104
|
teleportTo: string;
|
|
105
|
+
showClear: boolean;
|
|
85
106
|
format: string;
|
|
86
107
|
calendarDefinedDays: import("../KCalendar/types.js").IDefinedDay[];
|
|
87
108
|
calendarMarkedDays: import("../KCalendar/types.js").IMarkedDay[];
|
|
@@ -9,6 +9,8 @@ export interface KDatePickerProps {
|
|
|
9
9
|
calendarDefinedDays: IDefinedDay[];
|
|
10
10
|
calendarMarkedDays: IMarkedDay[];
|
|
11
11
|
teleportTo?: string;
|
|
12
|
+
validation?: 'success' | 'warning' | 'error' | null;
|
|
13
|
+
validationText?: string;
|
|
12
14
|
}
|
|
13
15
|
export declare const KDatePickerDefaultProps: {
|
|
14
16
|
format: {
|
|
@@ -43,6 +45,15 @@ export declare const KDatePickerDefaultProps: {
|
|
|
43
45
|
type: PropType<string>;
|
|
44
46
|
default: undefined;
|
|
45
47
|
};
|
|
48
|
+
validation: {
|
|
49
|
+
type: PropType<KDatePickerProps["validation"]>;
|
|
50
|
+
default: null;
|
|
51
|
+
validator: (value: string) => boolean;
|
|
52
|
+
};
|
|
53
|
+
validationText: {
|
|
54
|
+
type: StringConstructor;
|
|
55
|
+
default: string;
|
|
56
|
+
};
|
|
46
57
|
};
|
|
47
58
|
export declare function useKDatePickerLogic(props: KDatePickerProps): {
|
|
48
59
|
_date: import("vue").Ref<string | Date, string | Date>;
|
|
@@ -31,6 +31,15 @@ export const KDatePickerDefaultProps = {
|
|
|
31
31
|
teleportTo: {
|
|
32
32
|
type: String,
|
|
33
33
|
default: void 0
|
|
34
|
+
},
|
|
35
|
+
validation: {
|
|
36
|
+
type: String,
|
|
37
|
+
default: null,
|
|
38
|
+
validator: (value) => [null, "success", "warning", "error"].includes(value)
|
|
39
|
+
},
|
|
40
|
+
validationText: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: ""
|
|
34
43
|
}
|
|
35
44
|
};
|
|
36
45
|
export function useKDatePickerLogic(props) {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type KDateTimePickerProps } from './KDateTimePicker.logic.js';
|
|
1
2
|
declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
3
|
format: {
|
|
3
4
|
type: StringConstructor;
|
|
@@ -39,6 +40,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
39
40
|
type: import("vue").PropType<string>;
|
|
40
41
|
default: undefined;
|
|
41
42
|
};
|
|
43
|
+
validation: {
|
|
44
|
+
type: import("vue").PropType<KDateTimePickerProps["validation"]>;
|
|
45
|
+
default: null;
|
|
46
|
+
validator: (value: string) => boolean;
|
|
47
|
+
};
|
|
48
|
+
validationText: {
|
|
49
|
+
type: StringConstructor;
|
|
50
|
+
default: string;
|
|
51
|
+
};
|
|
42
52
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
43
53
|
"update:modelValue": (value: string | Date) => any;
|
|
44
54
|
"update:maskedModel": (value: string) => any;
|
|
@@ -85,6 +95,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
85
95
|
type: import("vue").PropType<string>;
|
|
86
96
|
default: undefined;
|
|
87
97
|
};
|
|
98
|
+
validation: {
|
|
99
|
+
type: import("vue").PropType<KDateTimePickerProps["validation"]>;
|
|
100
|
+
default: null;
|
|
101
|
+
validator: (value: string) => boolean;
|
|
102
|
+
};
|
|
103
|
+
validationText: {
|
|
104
|
+
type: StringConstructor;
|
|
105
|
+
default: string;
|
|
106
|
+
};
|
|
88
107
|
}>> & Readonly<{
|
|
89
108
|
"onUpdate:modelValue"?: ((value: string | Date) => any) | undefined;
|
|
90
109
|
"onUpdate:maskedModel"?: ((value: string) => any) | undefined;
|
|
@@ -93,9 +112,11 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
93
112
|
}>, {
|
|
94
113
|
isOpen: boolean;
|
|
95
114
|
day: string | Date;
|
|
115
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
116
|
+
validationText: string;
|
|
96
117
|
modelValue: string | Date;
|
|
97
|
-
showClear: boolean;
|
|
98
118
|
teleportTo: string;
|
|
119
|
+
showClear: boolean;
|
|
99
120
|
format: string;
|
|
100
121
|
calendarDefinedDays: import("../KCalendar/types.js").IDefinedDay[];
|
|
101
122
|
calendarMarkedDays: import("../KCalendar/types.js").IMarkedDay[];
|
|
@@ -32,7 +32,9 @@ const templateProps = computed(() => ({
|
|
|
32
32
|
onClear: handleClear,
|
|
33
33
|
dateSelected,
|
|
34
34
|
timeSelected,
|
|
35
|
-
teleportTo: props.teleportTo
|
|
35
|
+
teleportTo: props.teleportTo,
|
|
36
|
+
validation: props.validation,
|
|
37
|
+
validationText: props.validationText
|
|
36
38
|
}));
|
|
37
39
|
const handleClear = () => {
|
|
38
40
|
_date.value = "";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type KDateTimePickerProps } from './KDateTimePicker.logic.js';
|
|
1
2
|
declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
3
|
format: {
|
|
3
4
|
type: StringConstructor;
|
|
@@ -39,6 +40,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
39
40
|
type: import("vue").PropType<string>;
|
|
40
41
|
default: undefined;
|
|
41
42
|
};
|
|
43
|
+
validation: {
|
|
44
|
+
type: import("vue").PropType<KDateTimePickerProps["validation"]>;
|
|
45
|
+
default: null;
|
|
46
|
+
validator: (value: string) => boolean;
|
|
47
|
+
};
|
|
48
|
+
validationText: {
|
|
49
|
+
type: StringConstructor;
|
|
50
|
+
default: string;
|
|
51
|
+
};
|
|
42
52
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
43
53
|
"update:modelValue": (value: string | Date) => any;
|
|
44
54
|
"update:maskedModel": (value: string) => any;
|
|
@@ -85,6 +95,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
85
95
|
type: import("vue").PropType<string>;
|
|
86
96
|
default: undefined;
|
|
87
97
|
};
|
|
98
|
+
validation: {
|
|
99
|
+
type: import("vue").PropType<KDateTimePickerProps["validation"]>;
|
|
100
|
+
default: null;
|
|
101
|
+
validator: (value: string) => boolean;
|
|
102
|
+
};
|
|
103
|
+
validationText: {
|
|
104
|
+
type: StringConstructor;
|
|
105
|
+
default: string;
|
|
106
|
+
};
|
|
88
107
|
}>> & Readonly<{
|
|
89
108
|
"onUpdate:modelValue"?: ((value: string | Date) => any) | undefined;
|
|
90
109
|
"onUpdate:maskedModel"?: ((value: string) => any) | undefined;
|
|
@@ -93,9 +112,11 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
93
112
|
}>, {
|
|
94
113
|
isOpen: boolean;
|
|
95
114
|
day: string | Date;
|
|
115
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
116
|
+
validationText: string;
|
|
96
117
|
modelValue: string | Date;
|
|
97
|
-
showClear: boolean;
|
|
98
118
|
teleportTo: string;
|
|
119
|
+
showClear: boolean;
|
|
99
120
|
format: string;
|
|
100
121
|
calendarDefinedDays: import("../KCalendar/types.js").IDefinedDay[];
|
|
101
122
|
calendarMarkedDays: import("../KCalendar/types.js").IMarkedDay[];
|
|
@@ -11,6 +11,8 @@ export interface KDateTimePickerProps {
|
|
|
11
11
|
calendarDefinedDays?: IDefinedDay[];
|
|
12
12
|
calendarMarkedDays?: IMarkedDay[];
|
|
13
13
|
teleportTo?: string;
|
|
14
|
+
validation?: 'success' | 'warning' | 'error' | null;
|
|
15
|
+
validationText?: string;
|
|
14
16
|
}
|
|
15
17
|
export declare const KDateTimePickerDefaultProps: {
|
|
16
18
|
format: {
|
|
@@ -53,6 +55,15 @@ export declare const KDateTimePickerDefaultProps: {
|
|
|
53
55
|
type: PropType<string>;
|
|
54
56
|
default: undefined;
|
|
55
57
|
};
|
|
58
|
+
validation: {
|
|
59
|
+
type: PropType<KDateTimePickerProps["validation"]>;
|
|
60
|
+
default: null;
|
|
61
|
+
validator: (value: string) => boolean;
|
|
62
|
+
};
|
|
63
|
+
validationText: {
|
|
64
|
+
type: StringConstructor;
|
|
65
|
+
default: string;
|
|
66
|
+
};
|
|
56
67
|
};
|
|
57
68
|
export declare function useKDateTimePickerLogic(props: KDateTimePickerProps): {
|
|
58
69
|
_date: import("vue").Ref<string | Date, string | Date>;
|
|
@@ -39,6 +39,15 @@ export const KDateTimePickerDefaultProps = {
|
|
|
39
39
|
teleportTo: {
|
|
40
40
|
type: String,
|
|
41
41
|
default: void 0
|
|
42
|
+
},
|
|
43
|
+
validation: {
|
|
44
|
+
type: String,
|
|
45
|
+
default: null,
|
|
46
|
+
validator: (value) => [null, "success", "warning", "error"].includes(value)
|
|
47
|
+
},
|
|
48
|
+
validationText: {
|
|
49
|
+
type: String,
|
|
50
|
+
default: ""
|
|
42
51
|
}
|
|
43
52
|
};
|
|
44
53
|
export function useKDateTimePickerLogic(props) {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type KHourPickerProps } from './KHourPicker.logic.js';
|
|
1
2
|
declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
3
|
step: {
|
|
3
4
|
type: NumberConstructor;
|
|
@@ -35,6 +36,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
35
36
|
type: BooleanConstructor;
|
|
36
37
|
default: boolean;
|
|
37
38
|
};
|
|
39
|
+
validation: {
|
|
40
|
+
type: import("vue").PropType<KHourPickerProps["validation"]>;
|
|
41
|
+
default: null;
|
|
42
|
+
validator: (value: string) => boolean;
|
|
43
|
+
};
|
|
44
|
+
validationText: {
|
|
45
|
+
type: StringConstructor;
|
|
46
|
+
default: string;
|
|
47
|
+
};
|
|
38
48
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
39
49
|
"update:modelValue": (value: string) => any;
|
|
40
50
|
"update:isOpen": (value: boolean) => any;
|
|
@@ -75,12 +85,23 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
75
85
|
type: BooleanConstructor;
|
|
76
86
|
default: boolean;
|
|
77
87
|
};
|
|
88
|
+
validation: {
|
|
89
|
+
type: import("vue").PropType<KHourPickerProps["validation"]>;
|
|
90
|
+
default: null;
|
|
91
|
+
validator: (value: string) => boolean;
|
|
92
|
+
};
|
|
93
|
+
validationText: {
|
|
94
|
+
type: StringConstructor;
|
|
95
|
+
default: string;
|
|
96
|
+
};
|
|
78
97
|
}>> & Readonly<{
|
|
79
98
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
80
99
|
"onUpdate:isOpen"?: ((value: boolean) => any) | undefined;
|
|
81
100
|
}>, {
|
|
82
101
|
isOpen: boolean;
|
|
83
102
|
disabled: boolean;
|
|
103
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
104
|
+
validationText: string;
|
|
84
105
|
modelValue: string;
|
|
85
106
|
placeholder: string;
|
|
86
107
|
showClear: boolean;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type KHourPickerProps } from './KHourPicker.logic.js';
|
|
1
2
|
declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
3
|
step: {
|
|
3
4
|
type: NumberConstructor;
|
|
@@ -35,6 +36,15 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
35
36
|
type: BooleanConstructor;
|
|
36
37
|
default: boolean;
|
|
37
38
|
};
|
|
39
|
+
validation: {
|
|
40
|
+
type: import("vue").PropType<KHourPickerProps["validation"]>;
|
|
41
|
+
default: null;
|
|
42
|
+
validator: (value: string) => boolean;
|
|
43
|
+
};
|
|
44
|
+
validationText: {
|
|
45
|
+
type: StringConstructor;
|
|
46
|
+
default: string;
|
|
47
|
+
};
|
|
38
48
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
39
49
|
"update:modelValue": (value: string) => any;
|
|
40
50
|
"update:isOpen": (value: boolean) => any;
|
|
@@ -75,12 +85,23 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
75
85
|
type: BooleanConstructor;
|
|
76
86
|
default: boolean;
|
|
77
87
|
};
|
|
88
|
+
validation: {
|
|
89
|
+
type: import("vue").PropType<KHourPickerProps["validation"]>;
|
|
90
|
+
default: null;
|
|
91
|
+
validator: (value: string) => boolean;
|
|
92
|
+
};
|
|
93
|
+
validationText: {
|
|
94
|
+
type: StringConstructor;
|
|
95
|
+
default: string;
|
|
96
|
+
};
|
|
78
97
|
}>> & Readonly<{
|
|
79
98
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
80
99
|
"onUpdate:isOpen"?: ((value: boolean) => any) | undefined;
|
|
81
100
|
}>, {
|
|
82
101
|
isOpen: boolean;
|
|
83
102
|
disabled: boolean;
|
|
103
|
+
validation: "error" | "success" | "warning" | null | undefined;
|
|
104
|
+
validationText: string;
|
|
84
105
|
modelValue: string;
|
|
85
106
|
placeholder: string;
|
|
86
107
|
showClear: boolean;
|