@gridsheet/vue-core 2.0.0-0.rc.2 → 2.0.0-rc.5-0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/GridSheet.vue.d.ts +6 -6
- package/dist/index.js +27 -26
- package/package.json +2 -2
package/dist/GridSheet.vue.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { HubType, CellsByAddressType, OptionsType, TableRef } from '@gridsheet/preact-core';
|
|
2
1
|
import { Ref } from 'vue';
|
|
2
|
+
import { CellsByAddressType, OptionsType, HubType, Connector } from '@gridsheet/preact-core';
|
|
3
3
|
|
|
4
4
|
interface RefObject<T> {
|
|
5
5
|
readonly current: T | null;
|
|
@@ -17,8 +17,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
17
17
|
type: () => HubType | Ref<HubType>;
|
|
18
18
|
default: null;
|
|
19
19
|
};
|
|
20
|
-
|
|
21
|
-
type: () => RefObject<
|
|
20
|
+
connector: {
|
|
21
|
+
type: () => RefObject<Connector | null>;
|
|
22
22
|
default: null;
|
|
23
23
|
};
|
|
24
24
|
options: {
|
|
@@ -48,8 +48,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
48
48
|
type: () => HubType | Ref<HubType>;
|
|
49
49
|
default: null;
|
|
50
50
|
};
|
|
51
|
-
|
|
52
|
-
type: () => RefObject<
|
|
51
|
+
connector: {
|
|
52
|
+
type: () => RefObject<Connector | null>;
|
|
53
53
|
default: null;
|
|
54
54
|
};
|
|
55
55
|
options: {
|
|
@@ -67,7 +67,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
67
67
|
}>> & Readonly<{}>, {
|
|
68
68
|
sheetName: string;
|
|
69
69
|
hub: HubType | Ref<HubType, HubType>;
|
|
70
|
-
|
|
70
|
+
connector: RefObject<Connector | null>;
|
|
71
71
|
options: OptionsType;
|
|
72
72
|
className: string;
|
|
73
73
|
style: any;
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { render as
|
|
1
|
+
import { render as i, h as s, GridSheet as f, createHub as d } from "@gridsheet/preact-core";
|
|
2
2
|
export * from "@gridsheet/preact-core";
|
|
3
|
-
import { defineComponent as
|
|
4
|
-
const
|
|
3
|
+
import { defineComponent as h, ref as b, onMounted as m, isRef as c, watch as a, onBeforeUnmount as p, createElementBlock as _, openBlock as v, shallowRef as y } from "vue";
|
|
4
|
+
const O = h({
|
|
5
5
|
name: "GridSheet",
|
|
6
6
|
props: {
|
|
7
7
|
initialCells: {
|
|
@@ -16,7 +16,7 @@ const y = d({
|
|
|
16
16
|
type: Object,
|
|
17
17
|
default: null
|
|
18
18
|
},
|
|
19
|
-
|
|
19
|
+
connector: {
|
|
20
20
|
type: Object,
|
|
21
21
|
default: null
|
|
22
22
|
},
|
|
@@ -34,58 +34,59 @@ const y = d({
|
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
36
|
setup(e) {
|
|
37
|
-
const r =
|
|
37
|
+
const r = b(null);
|
|
38
38
|
let t = null;
|
|
39
39
|
function u() {
|
|
40
|
+
const { tableRef: o, ...l } = e;
|
|
40
41
|
return {
|
|
41
|
-
...
|
|
42
|
-
hub:
|
|
42
|
+
...l,
|
|
43
|
+
hub: c(e.hub) ? e.hub.value : e.hub
|
|
43
44
|
};
|
|
44
45
|
}
|
|
45
46
|
function n() {
|
|
46
|
-
r.value && (t = r.value,
|
|
47
|
-
|
|
47
|
+
r.value && (t = r.value, i(
|
|
48
|
+
s(f, u()),
|
|
48
49
|
t
|
|
49
50
|
));
|
|
50
51
|
}
|
|
51
|
-
return
|
|
52
|
-
n(),
|
|
52
|
+
return m(() => {
|
|
53
|
+
n(), c(e.hub) ? a(
|
|
53
54
|
() => e.hub.value,
|
|
54
55
|
n,
|
|
55
56
|
{ deep: !1 }
|
|
56
|
-
) :
|
|
57
|
+
) : a(
|
|
57
58
|
() => e.hub,
|
|
58
59
|
n,
|
|
59
60
|
{ deep: !1 }
|
|
60
61
|
);
|
|
61
|
-
}),
|
|
62
|
+
}), p(() => {
|
|
62
63
|
t && (t.innerHTML = "");
|
|
63
64
|
}), {
|
|
64
65
|
container: r
|
|
65
66
|
};
|
|
66
67
|
}
|
|
67
|
-
}),
|
|
68
|
+
}), j = (e, r) => {
|
|
68
69
|
const t = e.__vccOpts || e;
|
|
69
70
|
for (const [u, n] of r)
|
|
70
71
|
t[u] = n;
|
|
71
72
|
return t;
|
|
72
|
-
},
|
|
73
|
-
function
|
|
74
|
-
return
|
|
73
|
+
}, S = { ref: "container" };
|
|
74
|
+
function g(e, r, t, u, n, o) {
|
|
75
|
+
return v(), _("div", S, null, 512);
|
|
75
76
|
}
|
|
76
|
-
const
|
|
77
|
-
function
|
|
78
|
-
const r =
|
|
79
|
-
function n(
|
|
80
|
-
Object.assign(u,
|
|
77
|
+
const G = /* @__PURE__ */ j(O, [["render", g]]);
|
|
78
|
+
function k(e = {}) {
|
|
79
|
+
const r = d(e), t = y(r), { wire: u } = t.value;
|
|
80
|
+
function n(o) {
|
|
81
|
+
Object.assign(u, o), u.ready && requestAnimationFrame(() => t.value = { ...t.value });
|
|
81
82
|
}
|
|
82
|
-
return u.transmit = n,
|
|
83
|
+
return u.transmit = n, a(
|
|
83
84
|
() => e,
|
|
84
|
-
(
|
|
85
|
+
(o) => n(o),
|
|
85
86
|
{ deep: !0 }
|
|
86
87
|
), t;
|
|
87
88
|
}
|
|
88
89
|
export {
|
|
89
|
-
|
|
90
|
-
|
|
90
|
+
G as GridSheet,
|
|
91
|
+
k as useHub
|
|
91
92
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gridsheet/vue-core",
|
|
3
|
-
"version": "2.0.0-
|
|
3
|
+
"version": "2.0.0-rc.5-0",
|
|
4
4
|
"description": "Spreadsheet component for Vue 3",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"vue": "^3.3.0"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@gridsheet/preact-core": "^2.0.0-rc.
|
|
22
|
+
"@gridsheet/preact-core": "^2.0.0-rc.5"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@vitejs/plugin-vue": "^5.2.4",
|