cosey 0.4.14 → 0.4.16
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/components/audio-card/audio-card.vue.js +4 -0
- package/components/file-card/file-card.vue.js +4 -0
- package/components/image-card/image-card.d.ts +3 -0
- package/components/image-card/image-card.vue.d.ts +6 -0
- package/components/image-card/image-card.vue.js +3 -2
- package/components/image-card/index.d.ts +9 -0
- package/components/media-card/media-card.d.ts +4 -0
- package/components/media-card/media-card.js +3 -0
- package/components/media-card/media-card.vue.js +4 -0
- package/components/media-card-group/media-card-group.vue.js +4 -2
- package/components/video-card/video-card.vue.js +4 -0
- package/hooks/useUpsert.d.ts +2 -2
- package/hooks/useUpsert.js +4 -4
- package/locale/lang/ar.js +2 -2
- package/locale/lang/en.js +2 -2
- package/locale/lang/zh-cn.js +2 -2
- package/package.json +1 -1
|
@@ -19,6 +19,9 @@ export declare const imageProps: {
|
|
|
19
19
|
title: {
|
|
20
20
|
type: StringConstructor;
|
|
21
21
|
};
|
|
22
|
+
srcList: {
|
|
23
|
+
type: import("vue").PropType<string[]>;
|
|
24
|
+
};
|
|
22
25
|
fit: {
|
|
23
26
|
default: string;
|
|
24
27
|
type: import("vue").PropType<"" | "fill" | "contain" | "none" | "cover" | "scale-down">;
|
|
@@ -17,6 +17,9 @@ declare const __VLS_component: import("vue").DefineComponent<import("vue").Extra
|
|
|
17
17
|
title: {
|
|
18
18
|
type: StringConstructor;
|
|
19
19
|
};
|
|
20
|
+
srcList: {
|
|
21
|
+
type: import("vue").PropType<string[]>;
|
|
22
|
+
};
|
|
20
23
|
fit: {
|
|
21
24
|
default: string;
|
|
22
25
|
type: import("vue").PropType<"" | "fill" | "contain" | "none" | "cover" | "scale-down">;
|
|
@@ -133,6 +136,9 @@ declare const __VLS_component: import("vue").DefineComponent<import("vue").Extra
|
|
|
133
136
|
title: {
|
|
134
137
|
type: StringConstructor;
|
|
135
138
|
};
|
|
139
|
+
srcList: {
|
|
140
|
+
type: import("vue").PropType<string[]>;
|
|
141
|
+
};
|
|
136
142
|
fit: {
|
|
137
143
|
default: string;
|
|
138
144
|
type: import("vue").PropType<"" | "fill" | "contain" | "none" | "cover" | "scale-down">;
|
|
@@ -25,7 +25,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
25
25
|
} = stdin_default$1(prefixCls);
|
|
26
26
|
const imageRef = ref();
|
|
27
27
|
const mergedPreviewSrcList = computed(() => {
|
|
28
|
-
return props.previewSrcList?.length ? props.previewSrcList : props.src ? [props.src] : [];
|
|
28
|
+
return props.srcList?.length ? props.srcList : props.previewSrcList?.length ? props.previewSrcList : props.src ? [props.src] : [];
|
|
29
29
|
});
|
|
30
30
|
__expose({
|
|
31
31
|
view() {
|
|
@@ -48,7 +48,8 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
48
48
|
previewTeleported: true,
|
|
49
49
|
onShow,
|
|
50
50
|
onClose,
|
|
51
|
-
ref: imageRef
|
|
51
|
+
ref: imageRef,
|
|
52
|
+
initialIndex: Math.max(mergedPreviewSrcList.value.indexOf(props.src), 0)
|
|
52
53
|
});
|
|
53
54
|
});
|
|
54
55
|
const template = defineTemplate(() => {
|
|
@@ -17,6 +17,9 @@ declare const _ImageCard: {
|
|
|
17
17
|
title: {
|
|
18
18
|
type: StringConstructor;
|
|
19
19
|
};
|
|
20
|
+
srcList: {
|
|
21
|
+
type: import("vue").PropType<string[]>;
|
|
22
|
+
};
|
|
20
23
|
fit: {
|
|
21
24
|
default: string;
|
|
22
25
|
type: import("vue").PropType<"" | "fill" | "contain" | "none" | "cover" | "scale-down">;
|
|
@@ -160,6 +163,9 @@ declare const _ImageCard: {
|
|
|
160
163
|
title: {
|
|
161
164
|
type: StringConstructor;
|
|
162
165
|
};
|
|
166
|
+
srcList: {
|
|
167
|
+
type: import("vue").PropType<string[]>;
|
|
168
|
+
};
|
|
163
169
|
fit: {
|
|
164
170
|
default: string;
|
|
165
171
|
type: import("vue").PropType<"" | "fill" | "contain" | "none" | "cover" | "scale-down">;
|
|
@@ -294,6 +300,9 @@ declare const _ImageCard: {
|
|
|
294
300
|
title: {
|
|
295
301
|
type: StringConstructor;
|
|
296
302
|
};
|
|
303
|
+
srcList: {
|
|
304
|
+
type: import("vue").PropType<string[]>;
|
|
305
|
+
};
|
|
297
306
|
fit: {
|
|
298
307
|
default: string;
|
|
299
308
|
type: import("vue").PropType<"" | "fill" | "contain" | "none" | "cover" | "scale-down">;
|
|
@@ -5,6 +5,7 @@ export interface MediaCardBaseProps {
|
|
|
5
5
|
name?: string;
|
|
6
6
|
type?: 'image' | 'video' | 'audio' | (string & {});
|
|
7
7
|
title?: string;
|
|
8
|
+
srcList?: string[];
|
|
8
9
|
}
|
|
9
10
|
export declare const defaultMediaCardBaseProps: {
|
|
10
11
|
size: "middle";
|
|
@@ -26,6 +27,9 @@ export declare const mediaCardBaseProps: {
|
|
|
26
27
|
title: {
|
|
27
28
|
type: StringConstructor;
|
|
28
29
|
};
|
|
30
|
+
srcList: {
|
|
31
|
+
type: PropType<string[]>;
|
|
32
|
+
};
|
|
29
33
|
};
|
|
30
34
|
export interface MediaCardProps extends MediaCardBaseProps {
|
|
31
35
|
}
|
|
@@ -47,6 +47,7 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
47
47
|
}
|
|
48
48
|
return [];
|
|
49
49
|
});
|
|
50
|
+
const srcList = computed(() => mergedSrcset.value.map(item => item.src).filter(Boolean));
|
|
50
51
|
__expose();
|
|
51
52
|
return (_ctx, _cache) => {
|
|
52
53
|
return openBlock(), createElementBlock("div", {
|
|
@@ -56,8 +57,9 @@ var stdin_default = /* @__PURE__ */defineComponent({
|
|
|
56
57
|
key: i,
|
|
57
58
|
ref_for: true
|
|
58
59
|
}, item, {
|
|
59
|
-
size: _ctx.size
|
|
60
|
-
|
|
60
|
+
size: _ctx.size,
|
|
61
|
+
"src-list": srcList.value
|
|
62
|
+
}), null, 16, ["size", "src-list"]);
|
|
61
63
|
}), 128
|
|
62
64
|
/* KEYED_FRAGMENT */))], 2
|
|
63
65
|
/* CLASS */);
|
package/hooks/useUpsert.d.ts
CHANGED
|
@@ -3,8 +3,8 @@ export interface UseUpsertExposeOptions {
|
|
|
3
3
|
success?: () => any;
|
|
4
4
|
}
|
|
5
5
|
export interface UseUpsertExpose<Row extends Record<string, any>, Data = any> {
|
|
6
|
-
edit: (row: Row) => any;
|
|
7
|
-
add: () => any;
|
|
6
|
+
edit: (row: Row, ...args: any[]) => any;
|
|
7
|
+
add: (...args: any[]) => any;
|
|
8
8
|
setData: (data: Data) => UseUpsertExpose<Row, Data>;
|
|
9
9
|
setOptions: (options: UseUpsertExposeOptions) => any;
|
|
10
10
|
}
|
package/hooks/useUpsert.js
CHANGED
|
@@ -114,11 +114,11 @@ function useUpsert(options) {
|
|
|
114
114
|
function useOuterUpsert(options) {
|
|
115
115
|
const refKey = uuid();
|
|
116
116
|
const expose = useTemplateRef(refKey);
|
|
117
|
-
const add = () => {
|
|
118
|
-
expose.value?.add();
|
|
117
|
+
const add = (...args) => {
|
|
118
|
+
expose.value?.add(...args);
|
|
119
119
|
};
|
|
120
|
-
const edit = (row) => {
|
|
121
|
-
expose.value?.edit(row);
|
|
120
|
+
const edit = (row, ...args) => {
|
|
121
|
+
expose.value?.edit(row, ...args);
|
|
122
122
|
};
|
|
123
123
|
const setData = (data) => {
|
|
124
124
|
expose.value?.setData(data);
|
package/locale/lang/ar.js
CHANGED
|
@@ -55,8 +55,8 @@ var stdin_default = {
|
|
|
55
55
|
video: "\u0641\u064A\u062F\u064A\u0648"
|
|
56
56
|
},
|
|
57
57
|
table: {
|
|
58
|
-
export: "\
|
|
59
|
-
exportData: "\
|
|
58
|
+
export: "\u0635\u062F\u0650\u0651\u0631 \u0627\u0644\u0635\u0641\u062D\u0629 \u0627\u0644\u062D\u0627\u0644\u064A\u0629",
|
|
59
|
+
exportData: "\u0635\u062F\u0650\u0651\u0631 \u0627\u0644\u0628\u064A\u0627\u0646\u0627\u062A \u0645\u0646 \u0635\u0641\u062D\u0629",
|
|
60
60
|
exitFullScreen: "\u0627\u0644\u062E\u0631\u0648\u062C \u0645\u0646 \u0648\u0636\u0639 \u0645\u0644\u0621 \u0627\u0644\u0634\u0627\u0634\u0629",
|
|
61
61
|
fullScreen: "\u0645\u0644\u0621 \u0627\u0644\u0634\u0627\u0634\u0629",
|
|
62
62
|
columnSettings: "\u0625\u0639\u062F\u0627\u062F\u0627\u062A \u0627\u0644\u0623\u0639\u0645\u062F\u0629",
|
package/locale/lang/en.js
CHANGED
|
@@ -55,8 +55,8 @@ var stdin_default = {
|
|
|
55
55
|
video: "Video"
|
|
56
56
|
},
|
|
57
57
|
table: {
|
|
58
|
-
export: "Export",
|
|
59
|
-
exportData: "Export data",
|
|
58
|
+
export: "Export current page",
|
|
59
|
+
exportData: "Export current page data",
|
|
60
60
|
exitFullScreen: "Exit full screen",
|
|
61
61
|
fullScreen: "Full screen",
|
|
62
62
|
columnSettings: "Column Settings",
|
package/locale/lang/zh-cn.js
CHANGED
|
@@ -55,8 +55,8 @@ var stdin_default = {
|
|
|
55
55
|
video: "\u89C6\u9891"
|
|
56
56
|
},
|
|
57
57
|
table: {
|
|
58
|
-
export: "\u5BFC\u51FA",
|
|
59
|
-
exportData: "\u5BFC\u51FA\u6570\u636E",
|
|
58
|
+
export: "\u5BFC\u51FA\u5F53\u524D\u9875",
|
|
59
|
+
exportData: "\u5BFC\u51FA\u5F53\u524D\u9875\u6570\u636E",
|
|
60
60
|
exitFullScreen: "\u9000\u51FA\u5168\u5C4F",
|
|
61
61
|
fullScreen: "\u5168\u5C4F",
|
|
62
62
|
columnSettings: "\u5217\u8BBE\u7F6E",
|