@antify/template-module 0.0.3 → 0.0.5
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/buttons/ActionButton.d.vue.ts +8 -3
- package/dist/runtime/components/buttons/ActionButton.vue +46 -11
- package/dist/runtime/components/buttons/ActionButton.vue.d.ts +8 -3
- package/dist/runtime/components/buttons/CreateButton.d.vue.ts +18 -2
- package/dist/runtime/components/buttons/CreateButton.vue +16 -11
- package/dist/runtime/components/buttons/CreateButton.vue.d.ts +18 -2
- package/dist/runtime/components/buttons/DeleteButton.d.vue.ts +18 -2
- package/dist/runtime/components/buttons/DeleteButton.vue +15 -10
- package/dist/runtime/components/buttons/DeleteButton.vue.d.ts +18 -2
- package/dist/runtime/components/buttons/DuplicateButton.d.vue.ts +18 -2
- package/dist/runtime/components/buttons/DuplicateButton.vue +15 -10
- package/dist/runtime/components/buttons/DuplicateButton.vue.d.ts +18 -2
- package/dist/runtime/components/buttons/EditButton.d.vue.ts +18 -2
- package/dist/runtime/components/buttons/EditButton.vue +15 -10
- package/dist/runtime/components/buttons/EditButton.vue.d.ts +18 -2
- package/dist/runtime/components/buttons/SaveAndNewButton.d.vue.ts +18 -2
- package/dist/runtime/components/buttons/SaveAndNewButton.vue +16 -11
- package/dist/runtime/components/buttons/SaveAndNewButton.vue.d.ts +18 -2
- package/dist/runtime/components/buttons/SaveButton.d.vue.ts +18 -1
- package/dist/runtime/components/buttons/SaveButton.vue +16 -10
- package/dist/runtime/components/buttons/SaveButton.vue.d.ts +18 -1
- package/dist/runtime/components/crud/CrudDetailActions.d.vue.ts +16 -2
- package/dist/runtime/components/crud/CrudDetailActions.vue +35 -5
- package/dist/runtime/components/crud/CrudDetailActions.vue.d.ts +16 -2
- package/dist/runtime/components/crud/CrudDetailNav.d.vue.ts +10 -2
- package/dist/runtime/components/crud/CrudDetailNav.vue +18 -2
- package/dist/runtime/components/crud/CrudDetailNav.vue.d.ts +10 -2
- package/dist/runtime/components/crud/CrudTableFilter.d.vue.ts +9 -1
- package/dist/runtime/components/crud/CrudTableFilter.vue +19 -3
- package/dist/runtime/components/crud/CrudTableFilter.vue.d.ts +9 -1
- package/dist/runtime/components/dialogs/DeleteDialog.vue +12 -12
- package/dist/runtime/composables/useUiClient.js +14 -4
- package/dist/runtime/plugins/template-module.js +9 -3
- package/dist/runtime/utils.d.ts +1 -1
- package/dist/runtime/utils.js +6 -2
- package/package.json +3 -1
|
@@ -24,8 +24,10 @@ defineProps({
|
|
|
24
24
|
expanded: { type: Boolean, required: false },
|
|
25
25
|
canSave: { type: Boolean, required: false, default: true },
|
|
26
26
|
tooltipPosition: { type: String, required: false },
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
tooltipState: { type: String, required: false },
|
|
28
|
+
tooltipMessage: { type: String, required: false },
|
|
29
|
+
disabledTooltipMessage: { type: String, required: false },
|
|
30
|
+
invalidPermissionTooltipMessage: { type: String, required: false }
|
|
29
31
|
});
|
|
30
32
|
</script>
|
|
31
33
|
|
|
@@ -44,6 +46,9 @@ defineProps({
|
|
|
44
46
|
:has-permission="canSave"
|
|
45
47
|
:tooltip-position="tooltipPosition"
|
|
46
48
|
:tooltip-state="tooltipState"
|
|
49
|
+
:tooltip-message="tooltipMessage"
|
|
50
|
+
:disabled-tooltip-message="disabledTooltipMessage"
|
|
51
|
+
:invalid-permission-tooltip-message="invalidPermissionTooltipMessage"
|
|
47
52
|
data-e2e="save-and-new-button"
|
|
48
53
|
@click="$emit('click')"
|
|
49
54
|
@blur="$emit('blur')"
|
|
@@ -55,16 +60,16 @@ defineProps({
|
|
|
55
60
|
Speichern und neu
|
|
56
61
|
</template>
|
|
57
62
|
|
|
58
|
-
<template #
|
|
59
|
-
<
|
|
60
|
-
|
|
61
|
-
{{ saveTooltipMessage }}
|
|
62
|
-
</template>
|
|
63
|
+
<template #tooltipContent>
|
|
64
|
+
<slot name="tooltipContent" />
|
|
65
|
+
</template>
|
|
63
66
|
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
67
|
+
<template #disabledTooltipContent>
|
|
68
|
+
<slot name="disabledTooltipContent" />
|
|
69
|
+
</template>
|
|
70
|
+
|
|
71
|
+
<template #invalidPermissionTooltipContent>
|
|
72
|
+
<slot name="invalidPermissionTooltipContent" />
|
|
68
73
|
</template>
|
|
69
74
|
</ActionButton>
|
|
70
75
|
</template>
|
|
@@ -8,10 +8,20 @@ type __VLS_Props = {
|
|
|
8
8
|
expanded?: boolean;
|
|
9
9
|
canSave?: boolean;
|
|
10
10
|
tooltipPosition?: Position;
|
|
11
|
-
saveTooltipMessage?: string;
|
|
12
11
|
tooltipState?: InputState;
|
|
12
|
+
tooltipMessage?: string;
|
|
13
|
+
disabledTooltipMessage?: string;
|
|
14
|
+
invalidPermissionTooltipMessage?: string;
|
|
13
15
|
};
|
|
14
|
-
declare
|
|
16
|
+
declare var __VLS_13: {}, __VLS_16: {}, __VLS_19: {};
|
|
17
|
+
type __VLS_Slots = {} & {
|
|
18
|
+
tooltipContent?: (props: typeof __VLS_13) => any;
|
|
19
|
+
} & {
|
|
20
|
+
disabledTooltipContent?: (props: typeof __VLS_16) => any;
|
|
21
|
+
} & {
|
|
22
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_19) => any;
|
|
23
|
+
};
|
|
24
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
15
25
|
blur: (...args: any[]) => void;
|
|
16
26
|
click: (...args: any[]) => void;
|
|
17
27
|
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
@@ -21,5 +31,11 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {
|
|
|
21
31
|
iconVariant: boolean;
|
|
22
32
|
canSave: boolean;
|
|
23
33
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
34
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
24
35
|
declare const _default: typeof __VLS_export;
|
|
25
36
|
export default _default;
|
|
37
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
38
|
+
new (): {
|
|
39
|
+
$slots: S;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
@@ -10,8 +10,19 @@ type __VLS_Props = {
|
|
|
10
10
|
tooltipPosition?: Position;
|
|
11
11
|
saveTooltipMessage?: string;
|
|
12
12
|
tooltipState?: InputState;
|
|
13
|
+
tooltipMessage?: string;
|
|
14
|
+
disabledTooltipMessage?: string;
|
|
15
|
+
invalidPermissionTooltipMessage?: string;
|
|
13
16
|
};
|
|
14
|
-
declare
|
|
17
|
+
declare var __VLS_13: {}, __VLS_16: {}, __VLS_19: {};
|
|
18
|
+
type __VLS_Slots = {} & {
|
|
19
|
+
tooltipContent?: (props: typeof __VLS_13) => any;
|
|
20
|
+
} & {
|
|
21
|
+
disabledTooltipContent?: (props: typeof __VLS_16) => any;
|
|
22
|
+
} & {
|
|
23
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_19) => any;
|
|
24
|
+
};
|
|
25
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
15
26
|
blur: (...args: any[]) => void;
|
|
16
27
|
click: (...args: any[]) => void;
|
|
17
28
|
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
@@ -21,5 +32,11 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {
|
|
|
21
32
|
iconVariant: boolean;
|
|
22
33
|
canSave: boolean;
|
|
23
34
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
35
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
24
36
|
declare const _default: typeof __VLS_export;
|
|
25
37
|
export default _default;
|
|
38
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
39
|
+
new (): {
|
|
40
|
+
$slots: S;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
@@ -24,7 +24,10 @@ defineProps({
|
|
|
24
24
|
canSave: { type: Boolean, required: false, default: true },
|
|
25
25
|
tooltipPosition: { type: String, required: false },
|
|
26
26
|
saveTooltipMessage: { type: String, required: false },
|
|
27
|
-
tooltipState: { type: String, required: false }
|
|
27
|
+
tooltipState: { type: String, required: false },
|
|
28
|
+
tooltipMessage: { type: String, required: false },
|
|
29
|
+
disabledTooltipMessage: { type: String, required: false },
|
|
30
|
+
invalidPermissionTooltipMessage: { type: String, required: false }
|
|
28
31
|
});
|
|
29
32
|
</script>
|
|
30
33
|
|
|
@@ -42,6 +45,9 @@ defineProps({
|
|
|
42
45
|
:has-permission="canSave"
|
|
43
46
|
:tooltip-position="tooltipPosition"
|
|
44
47
|
:tooltip-state="tooltipState"
|
|
48
|
+
:tooltip-message="tooltipMessage"
|
|
49
|
+
:disabled-tooltip-message="disabledTooltipMessage"
|
|
50
|
+
:invalid-permission-tooltip-message="invalidPermissionTooltipMessage"
|
|
45
51
|
data-e2e="save-button"
|
|
46
52
|
@click="$emit('click')"
|
|
47
53
|
@blur="$emit('blur')"
|
|
@@ -53,16 +59,16 @@ defineProps({
|
|
|
53
59
|
Speichern
|
|
54
60
|
</template>
|
|
55
61
|
|
|
56
|
-
<template #
|
|
57
|
-
<
|
|
58
|
-
|
|
59
|
-
{{ saveTooltipMessage }}
|
|
60
|
-
</template>
|
|
62
|
+
<template #tooltipContent>
|
|
63
|
+
<slot name="tooltipContent" />
|
|
64
|
+
</template>
|
|
61
65
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
+
<template #disabledTooltipContent>
|
|
67
|
+
<slot name="disabledTooltipContent" />
|
|
68
|
+
</template>
|
|
69
|
+
|
|
70
|
+
<template #invalidPermissionTooltipContent>
|
|
71
|
+
<slot name="invalidPermissionTooltipContent" />
|
|
66
72
|
</template>
|
|
67
73
|
</ActionButton>
|
|
68
74
|
</template>
|
|
@@ -10,8 +10,19 @@ type __VLS_Props = {
|
|
|
10
10
|
tooltipPosition?: Position;
|
|
11
11
|
saveTooltipMessage?: string;
|
|
12
12
|
tooltipState?: InputState;
|
|
13
|
+
tooltipMessage?: string;
|
|
14
|
+
disabledTooltipMessage?: string;
|
|
15
|
+
invalidPermissionTooltipMessage?: string;
|
|
13
16
|
};
|
|
14
|
-
declare
|
|
17
|
+
declare var __VLS_13: {}, __VLS_16: {}, __VLS_19: {};
|
|
18
|
+
type __VLS_Slots = {} & {
|
|
19
|
+
tooltipContent?: (props: typeof __VLS_13) => any;
|
|
20
|
+
} & {
|
|
21
|
+
disabledTooltipContent?: (props: typeof __VLS_16) => any;
|
|
22
|
+
} & {
|
|
23
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_19) => any;
|
|
24
|
+
};
|
|
25
|
+
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
15
26
|
blur: (...args: any[]) => void;
|
|
16
27
|
click: (...args: any[]) => void;
|
|
17
28
|
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
@@ -21,5 +32,11 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {
|
|
|
21
32
|
iconVariant: boolean;
|
|
22
33
|
canSave: boolean;
|
|
23
34
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
35
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
24
36
|
declare const _default: typeof __VLS_export;
|
|
25
37
|
export default _default;
|
|
38
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
39
|
+
new (): {
|
|
40
|
+
$slots: S;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
@@ -6,8 +6,10 @@ type __VLS_Props = {
|
|
|
6
6
|
tooltipState?: InputState;
|
|
7
7
|
saveTooltipMessage?: string;
|
|
8
8
|
saveAndNewTooltipMessage?: string;
|
|
9
|
+
disabledTooltipMessage?: string;
|
|
10
|
+
invalidPermissionTooltipMessage?: string;
|
|
9
11
|
};
|
|
10
|
-
declare var __VLS_1: {}, __VLS_11: {}, __VLS_13: {},
|
|
12
|
+
declare var __VLS_1: {}, __VLS_11: {}, __VLS_13: {}, __VLS_24: {}, __VLS_27: {}, __VLS_30: {}, __VLS_41: {}, __VLS_44: {}, __VLS_47: {}, __VLS_49: {};
|
|
11
13
|
type __VLS_Slots = {} & {
|
|
12
14
|
'buttons-left'?: (props: typeof __VLS_1) => any;
|
|
13
15
|
} & {
|
|
@@ -15,7 +17,19 @@ type __VLS_Slots = {} & {
|
|
|
15
17
|
} & {
|
|
16
18
|
'buttons-right'?: (props: typeof __VLS_13) => any;
|
|
17
19
|
} & {
|
|
18
|
-
|
|
20
|
+
saveAndNewTooltipContent?: (props: typeof __VLS_24) => any;
|
|
21
|
+
} & {
|
|
22
|
+
saveAndNewDisabledTooltipContent?: (props: typeof __VLS_27) => any;
|
|
23
|
+
} & {
|
|
24
|
+
saveAndNewInvalidPermissionTooltipContent?: (props: typeof __VLS_30) => any;
|
|
25
|
+
} & {
|
|
26
|
+
saveTooltipContent?: (props: typeof __VLS_41) => any;
|
|
27
|
+
} & {
|
|
28
|
+
saveDisabledTooltipContent?: (props: typeof __VLS_44) => any;
|
|
29
|
+
} & {
|
|
30
|
+
saveInvalidPermissionTooltipContent?: (props: typeof __VLS_47) => any;
|
|
31
|
+
} & {
|
|
32
|
+
'after-buttons-right'?: (props: typeof __VLS_49) => any;
|
|
19
33
|
};
|
|
20
34
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
21
35
|
save: (...args: any[]) => void;
|
|
@@ -21,7 +21,9 @@ defineProps({
|
|
|
21
21
|
canSave: { type: Boolean, required: false, default: true },
|
|
22
22
|
tooltipState: { type: String, required: false },
|
|
23
23
|
saveTooltipMessage: { type: String, required: false },
|
|
24
|
-
saveAndNewTooltipMessage: { type: String, required: false }
|
|
24
|
+
saveAndNewTooltipMessage: { type: String, required: false },
|
|
25
|
+
disabledTooltipMessage: { type: String, required: false },
|
|
26
|
+
invalidPermissionTooltipMessage: { type: String, required: false }
|
|
25
27
|
});
|
|
26
28
|
</script>
|
|
27
29
|
|
|
@@ -52,19 +54,47 @@ defineProps({
|
|
|
52
54
|
:skeleton="skeleton"
|
|
53
55
|
:disabled="disabled"
|
|
54
56
|
:can-save="canSave"
|
|
55
|
-
:
|
|
57
|
+
:tooltip-message="saveTooltipMessage"
|
|
58
|
+
:disabled-tooltip-message="disabledTooltipMessage"
|
|
59
|
+
:invalid-permission-tooltip-message="invalidPermissionTooltipMessage"
|
|
56
60
|
:tooltip-state="tooltipState"
|
|
57
61
|
@click="$emit('save-and-new')"
|
|
58
|
-
|
|
62
|
+
>
|
|
63
|
+
<template #tooltipContent>
|
|
64
|
+
<slot name="saveAndNewTooltipContent" />
|
|
65
|
+
</template>
|
|
66
|
+
|
|
67
|
+
<template #disabledTooltipContent>
|
|
68
|
+
<slot name="saveAndNewDisabledTooltipContent" />
|
|
69
|
+
</template>
|
|
70
|
+
|
|
71
|
+
<template #invalidPermissionTooltipContent>
|
|
72
|
+
<slot name="saveAndNewInvalidPermissionTooltipContent" />
|
|
73
|
+
</template>
|
|
74
|
+
</SaveAndNewButton>
|
|
59
75
|
|
|
60
76
|
<SaveButton
|
|
61
77
|
:skeleton="skeleton"
|
|
62
78
|
:disabled="disabled"
|
|
63
79
|
:can-save="canSave"
|
|
64
|
-
:
|
|
80
|
+
:tooltip-message="saveAndNewTooltipMessage"
|
|
81
|
+
:disabled-tooltip-message="disabledTooltipMessage"
|
|
82
|
+
:invalid-permission-tooltip-message="invalidPermissionTooltipMessage"
|
|
65
83
|
:tooltip-state="tooltipState"
|
|
66
84
|
@click="$emit('save')"
|
|
67
|
-
|
|
85
|
+
>
|
|
86
|
+
<template #tooltipContent>
|
|
87
|
+
<slot name="saveTooltipContent" />
|
|
88
|
+
</template>
|
|
89
|
+
|
|
90
|
+
<template #disabledTooltipContent>
|
|
91
|
+
<slot name="saveDisabledTooltipContent" />
|
|
92
|
+
</template>
|
|
93
|
+
|
|
94
|
+
<template #invalidPermissionTooltipContent>
|
|
95
|
+
<slot name="saveInvalidPermissionTooltipContent" />
|
|
96
|
+
</template>
|
|
97
|
+
</SaveButton>
|
|
68
98
|
</slot>
|
|
69
99
|
<slot name="after-buttons-right" />
|
|
70
100
|
</div>
|
|
@@ -6,8 +6,10 @@ type __VLS_Props = {
|
|
|
6
6
|
tooltipState?: InputState;
|
|
7
7
|
saveTooltipMessage?: string;
|
|
8
8
|
saveAndNewTooltipMessage?: string;
|
|
9
|
+
disabledTooltipMessage?: string;
|
|
10
|
+
invalidPermissionTooltipMessage?: string;
|
|
9
11
|
};
|
|
10
|
-
declare var __VLS_1: {}, __VLS_11: {}, __VLS_13: {},
|
|
12
|
+
declare var __VLS_1: {}, __VLS_11: {}, __VLS_13: {}, __VLS_24: {}, __VLS_27: {}, __VLS_30: {}, __VLS_41: {}, __VLS_44: {}, __VLS_47: {}, __VLS_49: {};
|
|
11
13
|
type __VLS_Slots = {} & {
|
|
12
14
|
'buttons-left'?: (props: typeof __VLS_1) => any;
|
|
13
15
|
} & {
|
|
@@ -15,7 +17,19 @@ type __VLS_Slots = {} & {
|
|
|
15
17
|
} & {
|
|
16
18
|
'buttons-right'?: (props: typeof __VLS_13) => any;
|
|
17
19
|
} & {
|
|
18
|
-
|
|
20
|
+
saveAndNewTooltipContent?: (props: typeof __VLS_24) => any;
|
|
21
|
+
} & {
|
|
22
|
+
saveAndNewDisabledTooltipContent?: (props: typeof __VLS_27) => any;
|
|
23
|
+
} & {
|
|
24
|
+
saveAndNewInvalidPermissionTooltipContent?: (props: typeof __VLS_30) => any;
|
|
25
|
+
} & {
|
|
26
|
+
saveTooltipContent?: (props: typeof __VLS_41) => any;
|
|
27
|
+
} & {
|
|
28
|
+
saveDisabledTooltipContent?: (props: typeof __VLS_44) => any;
|
|
29
|
+
} & {
|
|
30
|
+
saveInvalidPermissionTooltipContent?: (props: typeof __VLS_47) => any;
|
|
31
|
+
} & {
|
|
32
|
+
'after-buttons-right'?: (props: typeof __VLS_49) => any;
|
|
19
33
|
};
|
|
20
34
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
21
35
|
save: (...args: any[]) => void;
|
|
@@ -7,9 +7,11 @@ type __VLS_Props = {
|
|
|
7
7
|
showDeleteButton?: boolean;
|
|
8
8
|
skeleton?: boolean;
|
|
9
9
|
deleteTooltipMessage?: string;
|
|
10
|
+
disabledTooltipMessage?: string;
|
|
11
|
+
invalidPermissionTooltipMessage?: string;
|
|
10
12
|
tooltipState?: InputState;
|
|
11
13
|
};
|
|
12
|
-
declare var __VLS_1: {}, __VLS_8: {}, __VLS_10: {},
|
|
14
|
+
declare var __VLS_1: {}, __VLS_8: {}, __VLS_10: {}, __VLS_21: {}, __VLS_24: {}, __VLS_27: {}, __VLS_29: {};
|
|
13
15
|
type __VLS_Slots = {} & {
|
|
14
16
|
tabs?: (props: typeof __VLS_1) => any;
|
|
15
17
|
} & {
|
|
@@ -17,7 +19,13 @@ type __VLS_Slots = {} & {
|
|
|
17
19
|
} & {
|
|
18
20
|
'before-delete-button'?: (props: typeof __VLS_10) => any;
|
|
19
21
|
} & {
|
|
20
|
-
|
|
22
|
+
tooltipContent?: (props: typeof __VLS_21) => any;
|
|
23
|
+
} & {
|
|
24
|
+
disabledTooltipContent?: (props: typeof __VLS_24) => any;
|
|
25
|
+
} & {
|
|
26
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_27) => any;
|
|
27
|
+
} & {
|
|
28
|
+
'after-delete-button'?: (props: typeof __VLS_29) => any;
|
|
21
29
|
};
|
|
22
30
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
23
31
|
delete: (...args: any[]) => void;
|
|
@@ -20,6 +20,8 @@ defineProps({
|
|
|
20
20
|
showDeleteButton: { type: Boolean, required: false, default: true },
|
|
21
21
|
skeleton: { type: Boolean, required: false, default: false },
|
|
22
22
|
deleteTooltipMessage: { type: String, required: false },
|
|
23
|
+
disabledTooltipMessage: { type: String, required: false },
|
|
24
|
+
invalidPermissionTooltipMessage: { type: String, required: false },
|
|
23
25
|
tooltipState: { type: String, required: false }
|
|
24
26
|
});
|
|
25
27
|
const dialogOpen = ref(false);
|
|
@@ -46,11 +48,25 @@ const dialogOpen = ref(false);
|
|
|
46
48
|
:disabled="deleteButtonDisabled || !canDelete"
|
|
47
49
|
:skeleton="skeleton"
|
|
48
50
|
:can-delete="canDelete"
|
|
49
|
-
:
|
|
51
|
+
:tooltip-message="deleteTooltipMessage"
|
|
52
|
+
:disabled-tooltip-message="disabledTooltipMessage"
|
|
53
|
+
:invalid-permission-tooltip-message="invalidPermissionTooltipMessage"
|
|
50
54
|
:invalid-permission-tooltip-position="Position.left"
|
|
51
55
|
:tooltip-state="tooltipState"
|
|
52
56
|
@click="() => dialogOpen = true"
|
|
53
|
-
|
|
57
|
+
>
|
|
58
|
+
<template #tooltipContent>
|
|
59
|
+
<slot name="tooltipContent" />
|
|
60
|
+
</template>
|
|
61
|
+
|
|
62
|
+
<template #disabledTooltipContent>
|
|
63
|
+
<slot name="disabledTooltipContent" />
|
|
64
|
+
</template>
|
|
65
|
+
|
|
66
|
+
<template #invalidPermissionTooltipContent>
|
|
67
|
+
<slot name="invalidPermissionTooltipContent" />
|
|
68
|
+
</template>
|
|
69
|
+
</DeleteButton>
|
|
54
70
|
|
|
55
71
|
<slot name="after-delete-button" />
|
|
56
72
|
</slot>
|
|
@@ -7,9 +7,11 @@ type __VLS_Props = {
|
|
|
7
7
|
showDeleteButton?: boolean;
|
|
8
8
|
skeleton?: boolean;
|
|
9
9
|
deleteTooltipMessage?: string;
|
|
10
|
+
disabledTooltipMessage?: string;
|
|
11
|
+
invalidPermissionTooltipMessage?: string;
|
|
10
12
|
tooltipState?: InputState;
|
|
11
13
|
};
|
|
12
|
-
declare var __VLS_1: {}, __VLS_8: {}, __VLS_10: {},
|
|
14
|
+
declare var __VLS_1: {}, __VLS_8: {}, __VLS_10: {}, __VLS_21: {}, __VLS_24: {}, __VLS_27: {}, __VLS_29: {};
|
|
13
15
|
type __VLS_Slots = {} & {
|
|
14
16
|
tabs?: (props: typeof __VLS_1) => any;
|
|
15
17
|
} & {
|
|
@@ -17,7 +19,13 @@ type __VLS_Slots = {} & {
|
|
|
17
19
|
} & {
|
|
18
20
|
'before-delete-button'?: (props: typeof __VLS_10) => any;
|
|
19
21
|
} & {
|
|
20
|
-
|
|
22
|
+
tooltipContent?: (props: typeof __VLS_21) => any;
|
|
23
|
+
} & {
|
|
24
|
+
disabledTooltipContent?: (props: typeof __VLS_24) => any;
|
|
25
|
+
} & {
|
|
26
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_27) => any;
|
|
27
|
+
} & {
|
|
28
|
+
'after-delete-button'?: (props: typeof __VLS_29) => any;
|
|
21
29
|
};
|
|
22
30
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
23
31
|
delete: (...args: any[]) => void;
|
|
@@ -10,15 +10,23 @@ type __VLS_Props = {
|
|
|
10
10
|
skeleton?: boolean;
|
|
11
11
|
searchPlaceholderText?: string;
|
|
12
12
|
createTooltipMessage?: string;
|
|
13
|
+
disabledTooltipMessage?: string;
|
|
14
|
+
invalidPermissionTooltipMessage?: string;
|
|
13
15
|
tooltipState?: InputState;
|
|
14
16
|
};
|
|
15
|
-
declare var __VLS_1: {}, __VLS_29: {}, __VLS_31: {};
|
|
17
|
+
declare var __VLS_1: {}, __VLS_29: {}, __VLS_31: {}, __VLS_42: {}, __VLS_45: {}, __VLS_48: {};
|
|
16
18
|
type __VLS_Slots = {} & {
|
|
17
19
|
filter?: (props: typeof __VLS_1) => any;
|
|
18
20
|
} & {
|
|
19
21
|
dropdownContent?: (props: typeof __VLS_29) => any;
|
|
20
22
|
} & {
|
|
21
23
|
buttons?: (props: typeof __VLS_31) => any;
|
|
24
|
+
} & {
|
|
25
|
+
tooltipContent?: (props: typeof __VLS_42) => any;
|
|
26
|
+
} & {
|
|
27
|
+
disabledTooltipContent?: (props: typeof __VLS_45) => any;
|
|
28
|
+
} & {
|
|
29
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_48) => any;
|
|
22
30
|
};
|
|
23
31
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
24
32
|
search: (...args: any[]) => void;
|
|
@@ -33,6 +33,8 @@ const props = defineProps({
|
|
|
33
33
|
skeleton: { type: Boolean, required: false, default: false },
|
|
34
34
|
searchPlaceholderText: { type: String, required: false },
|
|
35
35
|
createTooltipMessage: { type: String, required: false },
|
|
36
|
+
disabledTooltipMessage: { type: String, required: false },
|
|
37
|
+
invalidPermissionTooltipMessage: { type: String, required: false },
|
|
36
38
|
tooltipState: { type: String, required: false }
|
|
37
39
|
});
|
|
38
40
|
const emit = defineEmits([
|
|
@@ -129,7 +131,7 @@ watch(searchInputRef, (val) => {
|
|
|
129
131
|
</template>
|
|
130
132
|
</AntDropdown>
|
|
131
133
|
|
|
132
|
-
<!-- Temporary solution: Use backlayer instead of on click outside to solve the problem with popover over other popover -->
|
|
134
|
+
<!-- Temporary solution: Use backlayer instead of on click outside to solve the problem with popover over other popover -->
|
|
133
135
|
<div
|
|
134
136
|
v-if="showDropdown"
|
|
135
137
|
class="inset-0 absolute w-full h-full z-20"
|
|
@@ -143,10 +145,24 @@ watch(searchInputRef, (val) => {
|
|
|
143
145
|
:skeleton="skeleton"
|
|
144
146
|
:can-create="canCreate"
|
|
145
147
|
:invalid-permission-tooltip-position="Position.left"
|
|
146
|
-
:
|
|
148
|
+
:tooltip-message="createTooltipMessage"
|
|
149
|
+
:disabled-tooltip-message="disabledTooltipMessage"
|
|
150
|
+
:invalid-permission-tooltip-message="invalidPermissionTooltipMessage"
|
|
147
151
|
:tooltip-state="tooltipState"
|
|
148
152
|
@click="() => emit('create')"
|
|
149
|
-
|
|
153
|
+
>
|
|
154
|
+
<template #tooltipContent>
|
|
155
|
+
<slot name="tooltipContent" />
|
|
156
|
+
</template>
|
|
157
|
+
|
|
158
|
+
<template #disabledTooltipContent>
|
|
159
|
+
<slot name="disabledTooltipContent" />
|
|
160
|
+
</template>
|
|
161
|
+
|
|
162
|
+
<template #invalidPermissionTooltipContent>
|
|
163
|
+
<slot name="invalidPermissionTooltipContent" />
|
|
164
|
+
</template>
|
|
165
|
+
</CreateButton>
|
|
150
166
|
</slot>
|
|
151
167
|
</div>
|
|
152
168
|
</div>
|
|
@@ -10,15 +10,23 @@ type __VLS_Props = {
|
|
|
10
10
|
skeleton?: boolean;
|
|
11
11
|
searchPlaceholderText?: string;
|
|
12
12
|
createTooltipMessage?: string;
|
|
13
|
+
disabledTooltipMessage?: string;
|
|
14
|
+
invalidPermissionTooltipMessage?: string;
|
|
13
15
|
tooltipState?: InputState;
|
|
14
16
|
};
|
|
15
|
-
declare var __VLS_1: {}, __VLS_29: {}, __VLS_31: {};
|
|
17
|
+
declare var __VLS_1: {}, __VLS_29: {}, __VLS_31: {}, __VLS_42: {}, __VLS_45: {}, __VLS_48: {};
|
|
16
18
|
type __VLS_Slots = {} & {
|
|
17
19
|
filter?: (props: typeof __VLS_1) => any;
|
|
18
20
|
} & {
|
|
19
21
|
dropdownContent?: (props: typeof __VLS_29) => any;
|
|
20
22
|
} & {
|
|
21
23
|
buttons?: (props: typeof __VLS_31) => any;
|
|
24
|
+
} & {
|
|
25
|
+
tooltipContent?: (props: typeof __VLS_42) => any;
|
|
26
|
+
} & {
|
|
27
|
+
disabledTooltipContent?: (props: typeof __VLS_45) => any;
|
|
28
|
+
} & {
|
|
29
|
+
invalidPermissionTooltipContent?: (props: typeof __VLS_48) => any;
|
|
22
30
|
};
|
|
23
31
|
declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
24
32
|
search: (...args: any[]) => void;
|
|
@@ -45,19 +45,19 @@ function confirmDialog() {
|
|
|
45
45
|
<div
|
|
46
46
|
class="bg-base-100 gap-2 text-for-white-bg-font flex w-full justify-end"
|
|
47
47
|
>
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
48
|
+
<AntButton
|
|
49
|
+
:state="State.base"
|
|
50
|
+
@click="closeDialog"
|
|
51
|
+
>
|
|
52
|
+
Abbrechen
|
|
53
|
+
</AntButton>
|
|
54
54
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
55
|
+
<DeleteButton
|
|
56
|
+
filled
|
|
57
|
+
@click="confirmDialog"
|
|
58
|
+
>
|
|
59
|
+
Löschen
|
|
60
|
+
</DeleteButton>
|
|
61
61
|
</div>
|
|
62
62
|
</template>
|
|
63
63
|
</AntDialog>
|
|
@@ -8,8 +8,12 @@ import {
|
|
|
8
8
|
reactive,
|
|
9
9
|
ref
|
|
10
10
|
} from "#imports";
|
|
11
|
-
import {
|
|
12
|
-
|
|
11
|
+
import {
|
|
12
|
+
InputState
|
|
13
|
+
} from "@antify/ui";
|
|
14
|
+
import {
|
|
15
|
+
watchOnce
|
|
16
|
+
} from "@vueuse/core";
|
|
13
17
|
async function handleNotFoundResponse(response, fallbackUrl) {
|
|
14
18
|
if (response._data?.notFound) {
|
|
15
19
|
useNuxtApp().$templateModule.toaster.toastError("Entity not found. Maybe an other user deleted it.");
|
|
@@ -18,7 +22,11 @@ async function handleNotFoundResponse(response, fallbackUrl) {
|
|
|
18
22
|
}
|
|
19
23
|
function handleResponseError(error) {
|
|
20
24
|
if (error.value) {
|
|
21
|
-
throw createError({
|
|
25
|
+
throw createError({
|
|
26
|
+
...error.value?.data,
|
|
27
|
+
statusCode: 500,
|
|
28
|
+
fatal: true
|
|
29
|
+
});
|
|
22
30
|
}
|
|
23
31
|
}
|
|
24
32
|
function isFormDisabled(status) {
|
|
@@ -28,7 +36,9 @@ function isFormDisabled(status) {
|
|
|
28
36
|
return status.value === "pending";
|
|
29
37
|
}
|
|
30
38
|
function queryChanged(from, to, queryToWatch) {
|
|
31
|
-
const _queryToWatch = Array.isArray(queryToWatch) ? queryToWatch : [
|
|
39
|
+
const _queryToWatch = Array.isArray(queryToWatch) ? queryToWatch : [
|
|
40
|
+
queryToWatch
|
|
41
|
+
];
|
|
32
42
|
const changes = Object.keys(to).reduce((acc, key) => {
|
|
33
43
|
if (to[key] !== from[key]) {
|
|
34
44
|
acc[key] = to[key];
|
|
@@ -1,6 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import {
|
|
2
|
+
defineNuxtPlugin
|
|
3
|
+
} from "#app";
|
|
4
|
+
import {
|
|
5
|
+
FontAwesomeIcon
|
|
6
|
+
} from "@fortawesome/vue-fontawesome";
|
|
7
|
+
import {
|
|
8
|
+
useToaster
|
|
9
|
+
} from "@antify/ui";
|
|
4
10
|
export default defineNuxtPlugin((nuxtApp) => {
|
|
5
11
|
const toaster = useToaster();
|
|
6
12
|
nuxtApp.vueApp.component("FaIcon", FontAwesomeIcon);
|
package/dist/runtime/utils.d.ts
CHANGED
package/dist/runtime/utils.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antify/template-module",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
@@ -33,6 +33,8 @@
|
|
|
33
33
|
"@nuxt/module-builder": "latest",
|
|
34
34
|
"@nuxtjs/storybook": "8.3.5",
|
|
35
35
|
"@storybook/addon-essentials": "8.6.15",
|
|
36
|
+
"@storybook/addon-interactions": "8.6.15",
|
|
37
|
+
"@storybook/addon-links": "8.6.15",
|
|
36
38
|
"@storybook/vue3": "8.6.15",
|
|
37
39
|
"@stylistic/eslint-plugin": "^2.11.0",
|
|
38
40
|
"autoprefixer": "^10.4.20",
|