ablok-components 0.3.67 → 0.3.69
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/ablok-components.css +1 -1
- package/dist/ablok-components.umd.js +2 -2
- package/dist/components/molecules/media-thumbnails/media-thumbnails.vue.js +6 -6
- package/dist/components/molecules/upload-group/upload-group.vue.d.ts +19 -1
- package/dist/components/molecules/upload-group/upload-group.vue.js +49 -43
- package/dist/components/organisms/asset-uploader/asset-uploader.vue.d.ts +48 -0
- package/dist/components/organisms/asset-uploader/asset-uploader.vue.js +63 -29
- package/dist/components/organisms/asset-uploader/asset-uploader.vue2.js +4 -0
- package/dist/components/organisms/preset-uploader/preset-uploader.vue.d.ts +257 -0
- package/dist/components/organisms/preset-uploader/preset-uploader.vue.js +542 -0
- package/dist/components/organisms/preset-uploader/preset-uploader.vue3.js +5 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +59 -57
- package/package.json +1 -1
- package/dist/components/organisms/asset-uploader/asset-uploader.vue3.js +0 -5
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as h, ref as _, openBlock as t, createElementBlock as i, createVNode as s, withCtx as b, createElementVNode as y, normalizeClass as o, Fragment as g, renderList as k, createBlock as C, toDisplayString as v, createCommentVNode as V } from "vue";
|
|
2
2
|
import $ from "../../templates/base-carousel/base-carousel.vue.js";
|
|
3
3
|
/* empty css */
|
|
4
4
|
import m from "../../atoms/base-image/base-image.vue.js";
|
|
@@ -12,7 +12,7 @@ const x = { class: "media-thumbnails" }, B = ["onClick", "title"], j = {
|
|
|
12
12
|
}, w = {
|
|
13
13
|
key: 2,
|
|
14
14
|
class: "img-container"
|
|
15
|
-
}, I = /* @__PURE__ */
|
|
15
|
+
}, I = /* @__PURE__ */ h({
|
|
16
16
|
__name: "media-thumbnails",
|
|
17
17
|
props: {
|
|
18
18
|
modelValue: {
|
|
@@ -32,11 +32,11 @@ const x = { class: "media-thumbnails" }, B = ["onClick", "title"], j = {
|
|
|
32
32
|
},
|
|
33
33
|
stacked: {
|
|
34
34
|
type: Boolean,
|
|
35
|
-
default: !
|
|
35
|
+
default: !1
|
|
36
36
|
},
|
|
37
37
|
showCount: {
|
|
38
38
|
type: Boolean,
|
|
39
|
-
default: !
|
|
39
|
+
default: !1
|
|
40
40
|
}
|
|
41
41
|
},
|
|
42
42
|
emits: ["update:modelValue", "select"],
|
|
@@ -63,8 +63,8 @@ const x = { class: "media-thumbnails" }, B = ["onClick", "title"], j = {
|
|
|
63
63
|
key: 1,
|
|
64
64
|
class: o(["img-container img-container--multi", { "img-container--stacked": a.stacked }])
|
|
65
65
|
}, [
|
|
66
|
-
(t(!0), i(g, null, k(e.item.items, (n,
|
|
67
|
-
key:
|
|
66
|
+
(t(!0), i(g, null, k(e.item.items, (n, f) => (t(), C(m, {
|
|
67
|
+
key: f,
|
|
68
68
|
src: n.thumbnail || n.src,
|
|
69
69
|
class: "img-fluid"
|
|
70
70
|
}, null, 8, ["src"]))), 128)),
|
|
@@ -1,4 +1,16 @@
|
|
|
1
|
-
declare
|
|
1
|
+
declare function __VLS_template(): {
|
|
2
|
+
attrs: Partial<{}>;
|
|
3
|
+
slots: {
|
|
4
|
+
'item-overlay'?(_: {
|
|
5
|
+
item: any;
|
|
6
|
+
index: number;
|
|
7
|
+
}): any;
|
|
8
|
+
};
|
|
9
|
+
refs: {};
|
|
10
|
+
rootEl: HTMLDivElement;
|
|
11
|
+
};
|
|
12
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
13
|
+
declare const __VLS_component: import('../../../../vue/dist/vue.esm-bundler.js').DefineComponent<import('../../../../vue/dist/vue.esm-bundler.js').ExtractPropTypes<{
|
|
2
14
|
modelValue: {
|
|
3
15
|
type: {
|
|
4
16
|
(arrayLength: number): String[];
|
|
@@ -172,4 +184,10 @@ declare const _default: import('../../../../vue/dist/vue.esm-bundler.js').Define
|
|
|
172
184
|
maxImageWidth: number;
|
|
173
185
|
useImageUpload: boolean;
|
|
174
186
|
}, {}, {}, {}, string, import('../../../../vue/dist/vue.esm-bundler.js').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
187
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
175
188
|
export default _default;
|
|
189
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
190
|
+
new (): {
|
|
191
|
+
$slots: S;
|
|
192
|
+
};
|
|
193
|
+
};
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { defineComponent as v, ref as x, computed as k, watch as w, nextTick as
|
|
2
|
-
import { uniqueId as
|
|
3
|
-
import { sanitizeHtml as
|
|
4
|
-
import
|
|
1
|
+
import { defineComponent as v, ref as x, computed as k, watch as w, nextTick as S, openBlock as s, createElementBlock as f, unref as V, createCommentVNode as $, createElementVNode as l, createVNode as d, withCtx as m, createBlock as p, withModifiers as z, renderSlot as F } from "vue";
|
|
2
|
+
import { uniqueId as h } from "../../../utilities/helpers.js";
|
|
3
|
+
import { sanitizeHtml as N } from "../../../composables/useSanitize.js";
|
|
4
|
+
import B from "../../templates/sortable-list/sortable-list.vue.js";
|
|
5
5
|
/* empty css */
|
|
6
|
-
import
|
|
6
|
+
import I from "../image-upload/image-upload.vue.js";
|
|
7
7
|
/* empty css */
|
|
8
|
-
import
|
|
8
|
+
import T from "../file-upload/file-upload.vue.js";
|
|
9
9
|
/* empty css */
|
|
10
10
|
import c from "../../atoms/svg-icon/svg-icon.vue.js";
|
|
11
11
|
/* empty css */
|
|
12
|
-
const
|
|
12
|
+
const W = { class: "upload-group" }, C = ["innerHTML"], R = { class: "upload-group__list" }, U = { class: "img-container" }, H = ["src"], M = { class: "item-overlay" }, P = ["onClick"], j = {
|
|
13
13
|
role: "button",
|
|
14
14
|
class: "img-thumbnail d-flex justify-content-center align-items-center"
|
|
15
|
-
},
|
|
15
|
+
}, q = {
|
|
16
16
|
role: "button",
|
|
17
17
|
class: "img-thumbnail d-flex justify-content-center align-items-center"
|
|
18
|
-
},
|
|
18
|
+
}, _ = /* @__PURE__ */ v({
|
|
19
19
|
__name: "upload-group",
|
|
20
20
|
props: {
|
|
21
21
|
modelValue: {
|
|
@@ -24,11 +24,11 @@ const T = { class: "upload-group" }, W = ["innerHTML"], C = { class: "upload-gro
|
|
|
24
24
|
},
|
|
25
25
|
name: {
|
|
26
26
|
type: String,
|
|
27
|
-
default: () =>
|
|
27
|
+
default: () => h()
|
|
28
28
|
},
|
|
29
29
|
id: {
|
|
30
30
|
type: String,
|
|
31
|
-
default: () =>
|
|
31
|
+
default: () => h()
|
|
32
32
|
},
|
|
33
33
|
label: {
|
|
34
34
|
type: String,
|
|
@@ -81,51 +81,57 @@ const T = { class: "upload-group" }, W = ["innerHTML"], C = { class: "upload-gro
|
|
|
81
81
|
aspectRatio: Number
|
|
82
82
|
},
|
|
83
83
|
emits: ["update:modelValue"],
|
|
84
|
-
setup(e, { emit:
|
|
85
|
-
const
|
|
84
|
+
setup(e, { emit: b }) {
|
|
85
|
+
const g = e, u = b, n = x(""), o = k({
|
|
86
86
|
get() {
|
|
87
|
-
return
|
|
87
|
+
return g.modelValue;
|
|
88
88
|
},
|
|
89
89
|
set(t) {
|
|
90
90
|
u("update:modelValue", t);
|
|
91
91
|
}
|
|
92
92
|
});
|
|
93
|
-
function
|
|
93
|
+
function y(t) {
|
|
94
94
|
o.value.splice(t, 1), u("update:modelValue", o.value);
|
|
95
95
|
}
|
|
96
|
-
return w(
|
|
97
|
-
t && a !== t && (u("update:modelValue", [...o.value, t]), await
|
|
98
|
-
}), (t, a) => (s(),
|
|
99
|
-
e.label ? (s(),
|
|
96
|
+
return w(n, async (t, a) => {
|
|
97
|
+
t && a !== t && (u("update:modelValue", [...o.value, t]), await S(), n.value = "");
|
|
98
|
+
}), (t, a) => (s(), f("div", W, [
|
|
99
|
+
e.label ? (s(), f("label", {
|
|
100
100
|
key: 0,
|
|
101
|
-
innerHTML:
|
|
102
|
-
}, null, 8,
|
|
103
|
-
|
|
104
|
-
d(
|
|
101
|
+
innerHTML: V(N)(e.label)
|
|
102
|
+
}, null, 8, C)) : $("", !0),
|
|
103
|
+
l("div", R, [
|
|
104
|
+
d(B, {
|
|
105
105
|
modelValue: o.value,
|
|
106
106
|
"onUpdate:modelValue": a[2] || (a[2] = (i) => o.value = i),
|
|
107
107
|
vertical: !1,
|
|
108
108
|
class: "mb-3"
|
|
109
109
|
}, {
|
|
110
|
-
"list-item": m(({ item: i, index:
|
|
111
|
-
|
|
112
|
-
|
|
110
|
+
"list-item": m(({ item: i, index: r }) => [
|
|
111
|
+
l("div", U, [
|
|
112
|
+
l("img", {
|
|
113
113
|
src: `${i}${e.previewWidth ? `?width=${e.previewWidth}` : ""}`,
|
|
114
114
|
class: "img-thumbnail"
|
|
115
|
-
}, null, 8,
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
115
|
+
}, null, 8, H),
|
|
116
|
+
l("div", M, [
|
|
117
|
+
l("button", {
|
|
118
|
+
onClick: z((E) => y(r), ["prevent"]),
|
|
119
|
+
class: "btn btn--close"
|
|
120
|
+
}, [
|
|
121
|
+
d(c, { symbol: "x" })
|
|
122
|
+
], 8, P),
|
|
123
|
+
F(t.$slots, "item-overlay", {
|
|
124
|
+
item: i,
|
|
125
|
+
index: r
|
|
126
|
+
})
|
|
127
|
+
])
|
|
122
128
|
])
|
|
123
129
|
]),
|
|
124
130
|
"list-append": m(() => [
|
|
125
|
-
e.useImageUpload ? (s(),
|
|
131
|
+
e.useImageUpload ? (s(), p(I, {
|
|
126
132
|
key: 0,
|
|
127
|
-
src:
|
|
128
|
-
"onUpdate:src": a[0] || (a[0] = (i) =>
|
|
133
|
+
src: n.value,
|
|
134
|
+
"onUpdate:src": a[0] || (a[0] = (i) => n.value = i),
|
|
129
135
|
endpoint: e.endpoint,
|
|
130
136
|
"custom-fetch": e.customFetch,
|
|
131
137
|
"to-data-url": !e.endpoint,
|
|
@@ -139,15 +145,15 @@ const T = { class: "upload-group" }, W = ["innerHTML"], C = { class: "upload-gro
|
|
|
139
145
|
"aspect-ratio": e.aspectRatio
|
|
140
146
|
}, {
|
|
141
147
|
button: m(() => [
|
|
142
|
-
|
|
148
|
+
l("span", j, [
|
|
143
149
|
d(c, { symbol: "plus" })
|
|
144
150
|
])
|
|
145
151
|
]),
|
|
146
152
|
_: 1
|
|
147
|
-
}, 8, ["src", "endpoint", "custom-fetch", "to-data-url", "auth-token", "disabled", "base-response-path", "accept", "max-file-size", "max-image-width", "aspect-ratio"])) : (s(),
|
|
153
|
+
}, 8, ["src", "endpoint", "custom-fetch", "to-data-url", "auth-token", "disabled", "base-response-path", "accept", "max-file-size", "max-image-width", "aspect-ratio"])) : (s(), p(T, {
|
|
148
154
|
key: 1,
|
|
149
|
-
src:
|
|
150
|
-
"onUpdate:src": a[1] || (a[1] = (i) =>
|
|
155
|
+
src: n.value,
|
|
156
|
+
"onUpdate:src": a[1] || (a[1] = (i) => n.value = i),
|
|
151
157
|
multiple: !1,
|
|
152
158
|
endpoint: e.endpoint,
|
|
153
159
|
"custom-fetch": e.customFetch,
|
|
@@ -160,19 +166,19 @@ const T = { class: "upload-group" }, W = ["innerHTML"], C = { class: "upload-gro
|
|
|
160
166
|
"max-image-width": e.maxImageWidth
|
|
161
167
|
}, {
|
|
162
168
|
button: m(() => [
|
|
163
|
-
|
|
169
|
+
l("span", q, [
|
|
164
170
|
d(c, { symbol: "plus" })
|
|
165
171
|
])
|
|
166
172
|
]),
|
|
167
173
|
_: 1
|
|
168
174
|
}, 8, ["src", "endpoint", "custom-fetch", "to-data-url", "auth-token", "disabled", "base-response-path", "accept", "max-file-size", "max-image-width"]))
|
|
169
175
|
]),
|
|
170
|
-
_:
|
|
176
|
+
_: 3
|
|
171
177
|
}, 8, ["modelValue"])
|
|
172
178
|
])
|
|
173
179
|
]));
|
|
174
180
|
}
|
|
175
181
|
});
|
|
176
182
|
export {
|
|
177
|
-
|
|
183
|
+
_ as default
|
|
178
184
|
};
|
|
@@ -96,6 +96,29 @@ declare const _default: import('../../../../vue/dist/vue.esm-bundler.js').Define
|
|
|
96
96
|
default: number;
|
|
97
97
|
};
|
|
98
98
|
aspectRatio: NumberConstructor;
|
|
99
|
+
showTypeDropdown: {
|
|
100
|
+
type: BooleanConstructor;
|
|
101
|
+
default: boolean;
|
|
102
|
+
};
|
|
103
|
+
typeOptions: {
|
|
104
|
+
type: {
|
|
105
|
+
(arrayLength: number): string[];
|
|
106
|
+
(...items: string[]): string[];
|
|
107
|
+
new (arrayLength: number): string[];
|
|
108
|
+
new (...items: string[]): string[];
|
|
109
|
+
isArray(arg: any): arg is any[];
|
|
110
|
+
readonly prototype: any[];
|
|
111
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
112
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
113
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
114
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
115
|
+
of<T>(...items: T[]): T[];
|
|
116
|
+
fromAsync<T>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T | PromiseLike<T>> | ArrayLike<T | PromiseLike<T>>): Promise<T[]>;
|
|
117
|
+
fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>, index: number) => U, thisArg?: any): Promise<Awaited<U>[]>;
|
|
118
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
119
|
+
};
|
|
120
|
+
default: () => string[];
|
|
121
|
+
};
|
|
99
122
|
}>, {}, {}, {}, {}, import('../../../../vue/dist/vue.esm-bundler.js').ComponentOptionsMixin, import('../../../../vue/dist/vue.esm-bundler.js').ComponentOptionsMixin, {
|
|
100
123
|
"update:modelValue": (...args: any[]) => void;
|
|
101
124
|
}, string, import('../../../../vue/dist/vue.esm-bundler.js').PublicProps, Readonly<import('../../../../vue/dist/vue.esm-bundler.js').ExtractPropTypes<{
|
|
@@ -187,6 +210,29 @@ declare const _default: import('../../../../vue/dist/vue.esm-bundler.js').Define
|
|
|
187
210
|
default: number;
|
|
188
211
|
};
|
|
189
212
|
aspectRatio: NumberConstructor;
|
|
213
|
+
showTypeDropdown: {
|
|
214
|
+
type: BooleanConstructor;
|
|
215
|
+
default: boolean;
|
|
216
|
+
};
|
|
217
|
+
typeOptions: {
|
|
218
|
+
type: {
|
|
219
|
+
(arrayLength: number): string[];
|
|
220
|
+
(...items: string[]): string[];
|
|
221
|
+
new (arrayLength: number): string[];
|
|
222
|
+
new (...items: string[]): string[];
|
|
223
|
+
isArray(arg: any): arg is any[];
|
|
224
|
+
readonly prototype: any[];
|
|
225
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
226
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
227
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
228
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
229
|
+
of<T>(...items: T[]): T[];
|
|
230
|
+
fromAsync<T>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T | PromiseLike<T>> | ArrayLike<T | PromiseLike<T>>): Promise<T[]>;
|
|
231
|
+
fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>, index: number) => U, thisArg?: any): Promise<Awaited<U>[]>;
|
|
232
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
233
|
+
};
|
|
234
|
+
default: () => string[];
|
|
235
|
+
};
|
|
190
236
|
}>> & Readonly<{
|
|
191
237
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
192
238
|
}>, {
|
|
@@ -206,5 +252,7 @@ declare const _default: import('../../../../vue/dist/vue.esm-bundler.js').Define
|
|
|
206
252
|
maxImageWidth: number;
|
|
207
253
|
useImageUpload: boolean;
|
|
208
254
|
mediaTypeMap: Record<string, any>;
|
|
255
|
+
showTypeDropdown: boolean;
|
|
256
|
+
typeOptions: string[];
|
|
209
257
|
}, {}, {}, {}, string, import('../../../../vue/dist/vue.esm-bundler.js').ComponentProvideOptions, true, {}, HTMLDivElement>;
|
|
210
258
|
export default _default;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { uniqueId as
|
|
3
|
-
import
|
|
1
|
+
import { defineComponent as y, computed as f, openBlock as n, createElementBlock as i, unref as g, createCommentVNode as h, createVNode as p, createSlots as b, withCtx as V } from "vue";
|
|
2
|
+
import { uniqueId as s } from "../../../utilities/helpers.js";
|
|
3
|
+
import v from "../../molecules/upload-group/upload-group.vue.js";
|
|
4
4
|
/* empty css */
|
|
5
|
-
import
|
|
6
|
-
|
|
5
|
+
import w from "../../molecules/input-dropdown/input-dropdown.vue.js";
|
|
6
|
+
/* empty css */
|
|
7
|
+
import { sanitizeHtml as S } from "../../../composables/useSanitize.js";
|
|
8
|
+
const T = { class: "asset-uploader" }, k = ["innerHTML"], F = /* @__PURE__ */ y({
|
|
7
9
|
__name: "asset-uploader",
|
|
8
10
|
props: {
|
|
9
11
|
modelValue: {
|
|
@@ -12,11 +14,11 @@ const b = { class: "asset-uploader" }, v = ["innerHTML"], k = /* @__PURE__ */ p(
|
|
|
12
14
|
},
|
|
13
15
|
name: {
|
|
14
16
|
type: String,
|
|
15
|
-
default: () =>
|
|
17
|
+
default: () => s()
|
|
16
18
|
},
|
|
17
19
|
id: {
|
|
18
20
|
type: String,
|
|
19
|
-
default: () =>
|
|
21
|
+
default: () => s()
|
|
20
22
|
},
|
|
21
23
|
type: {
|
|
22
24
|
type: String,
|
|
@@ -79,33 +81,51 @@ const b = { class: "asset-uploader" }, v = ["innerHTML"], k = /* @__PURE__ */ p(
|
|
|
79
81
|
type: Number,
|
|
80
82
|
default: 0
|
|
81
83
|
},
|
|
82
|
-
aspectRatio: Number
|
|
84
|
+
aspectRatio: Number,
|
|
85
|
+
showTypeDropdown: {
|
|
86
|
+
type: Boolean,
|
|
87
|
+
default: !1
|
|
88
|
+
},
|
|
89
|
+
typeOptions: {
|
|
90
|
+
type: Array,
|
|
91
|
+
default: () => [
|
|
92
|
+
"background",
|
|
93
|
+
"overlay",
|
|
94
|
+
"object"
|
|
95
|
+
]
|
|
96
|
+
}
|
|
83
97
|
},
|
|
84
98
|
emits: ["update:modelValue"],
|
|
85
|
-
setup(e, { emit:
|
|
86
|
-
const
|
|
99
|
+
setup(e, { emit: r }) {
|
|
100
|
+
const a = e, m = r, u = f({
|
|
87
101
|
get() {
|
|
88
|
-
return
|
|
102
|
+
return a.modelValue.map((o) => o.src);
|
|
89
103
|
},
|
|
90
|
-
set(
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
104
|
+
set(o) {
|
|
105
|
+
m("update:modelValue", o.map((l, t) => {
|
|
106
|
+
const d = a.showTypeDropdown && a.modelValue[t]?.type || a.type;
|
|
107
|
+
return {
|
|
108
|
+
mediaType: a.modelValue[t] && a.modelValue[t].mediaType || l.includes("data:image") ? l.includes("data:image/svg") ? "Svg" : "Image" : a.mediaTypeMap[l.split(".")[1]],
|
|
109
|
+
src: l,
|
|
110
|
+
name: a.modelValue[t] && a.modelValue[t].name || `${a.name}-${t}`,
|
|
111
|
+
...d ? { type: d } : {}
|
|
112
|
+
};
|
|
113
|
+
}));
|
|
99
114
|
}
|
|
100
115
|
});
|
|
101
|
-
|
|
102
|
-
|
|
116
|
+
function c(o, l) {
|
|
117
|
+
m("update:modelValue", a.modelValue.map(
|
|
118
|
+
(t, d) => d === o ? { ...t, type: l } : t
|
|
119
|
+
));
|
|
120
|
+
}
|
|
121
|
+
return (o, l) => (n(), i("div", T, [
|
|
122
|
+
e.label ? (n(), i("label", {
|
|
103
123
|
key: 0,
|
|
104
|
-
innerHTML:
|
|
105
|
-
}, null, 8,
|
|
106
|
-
|
|
107
|
-
modelValue:
|
|
108
|
-
"onUpdate:modelValue":
|
|
124
|
+
innerHTML: g(S)(e.label)
|
|
125
|
+
}, null, 8, k)) : h("", !0),
|
|
126
|
+
p(v, {
|
|
127
|
+
modelValue: u.value,
|
|
128
|
+
"onUpdate:modelValue": l[0] || (l[0] = (t) => u.value = t),
|
|
109
129
|
endpoint: e.endpoint,
|
|
110
130
|
"custom-fetch": e.customFetch,
|
|
111
131
|
"auth-token": e.authToken,
|
|
@@ -117,10 +137,24 @@ const b = { class: "asset-uploader" }, v = ["innerHTML"], k = /* @__PURE__ */ p(
|
|
|
117
137
|
"use-image-upload": e.useImageUpload,
|
|
118
138
|
"max-image-width": e.maxImageWidth,
|
|
119
139
|
"aspect-ratio": e.aspectRatio
|
|
120
|
-
},
|
|
140
|
+
}, b({ _: 2 }, [
|
|
141
|
+
e.showTypeDropdown ? {
|
|
142
|
+
name: "item-overlay",
|
|
143
|
+
fn: V(({ index: t }) => [
|
|
144
|
+
p(w, {
|
|
145
|
+
name: `${e.name}-type-${t}`,
|
|
146
|
+
options: e.typeOptions,
|
|
147
|
+
"model-value": e.modelValue[t]?.type || null,
|
|
148
|
+
placeholder: "type",
|
|
149
|
+
"onUpdate:modelValue": (d) => c(t, d)
|
|
150
|
+
}, null, 8, ["name", "options", "model-value", "onUpdate:modelValue"])
|
|
151
|
+
]),
|
|
152
|
+
key: "0"
|
|
153
|
+
} : void 0
|
|
154
|
+
]), 1032, ["modelValue", "endpoint", "custom-fetch", "auth-token", "disabled", "preview-width", "base-response-path", "accept", "max-file-size", "use-image-upload", "max-image-width", "aspect-ratio"])
|
|
121
155
|
]));
|
|
122
156
|
}
|
|
123
157
|
});
|
|
124
158
|
export {
|
|
125
|
-
|
|
159
|
+
F as default
|
|
126
160
|
};
|