@fileverse-dev/dsheet 4.0.5-edit-mode-13 → 4.0.5-edit-mode-15
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/{constants-CRFfbkoQ.js → constants-exC_CJ-T.js} +88 -31
- package/dist/constants.d.ts +2 -2
- package/dist/constants.js +3 -3
- package/dist/{index-SD570TY0.js → index-nS5nX5Q7.js} +3267 -3293
- package/dist/index.es.js +2 -2
- package/dist/sync-local/presence.d.ts +2 -0
- package/dist/sync-local/socketClient.d.ts +1 -0
- package/dist/{use-xlsx-import-impl-DYqbWGKI.js → use-xlsx-import-impl-BneI1B7o.js} +3 -3
- package/dist/{xlsx-defined-names-23YzHCIr.js → xlsx-defined-names-BOrtrHWX.js} +1 -1
- package/dist/{xlsx-export-impl-hYSXSJi0.js → xlsx-export-impl-DNyX6q9a.js} +3 -3
- package/dist/{xlsx-hyperlink-inline-C6xGZ4JM.js → xlsx-hyperlink-inline-7zGlO4ea.js} +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,67 @@
|
|
|
1
|
-
import { E as
|
|
2
|
-
const
|
|
1
|
+
import { E as l, S as u } from "./crypto-constants-ZTlAYRUf.js";
|
|
2
|
+
const a = "#9CA3AF", s = [
|
|
3
|
+
"#30bced",
|
|
4
|
+
"#6eeb83",
|
|
5
|
+
"#fa69d1",
|
|
6
|
+
"#ecd444",
|
|
7
|
+
"#ee6352",
|
|
8
|
+
"#db3041",
|
|
9
|
+
"#0ad7f2",
|
|
10
|
+
"#1bff39"
|
|
11
|
+
];
|
|
12
|
+
function h(o) {
|
|
13
|
+
const t = /* @__PURE__ */ new Map();
|
|
14
|
+
return o.forEach((r) => {
|
|
15
|
+
const i = r == null ? void 0 : r.socketId, e = r == null ? void 0 : r.user;
|
|
16
|
+
typeof i == "string" && e && t.set(i, {
|
|
17
|
+
name: e.name ?? "",
|
|
18
|
+
color: e.color ?? a,
|
|
19
|
+
isEns: e.isEns ?? ""
|
|
20
|
+
});
|
|
21
|
+
}), t;
|
|
22
|
+
}
|
|
23
|
+
function S(o, t) {
|
|
24
|
+
const r = o.map((e) => {
|
|
25
|
+
const n = t.get(e);
|
|
26
|
+
return n ? {
|
|
27
|
+
clientId: e,
|
|
28
|
+
name: n.name,
|
|
29
|
+
color: n.color,
|
|
30
|
+
isEns: n.isEns,
|
|
31
|
+
isPlaceholder: !1
|
|
32
|
+
} : {
|
|
33
|
+
clientId: e,
|
|
34
|
+
name: "",
|
|
35
|
+
color: a,
|
|
36
|
+
isEns: "",
|
|
37
|
+
isPlaceholder: !0
|
|
38
|
+
};
|
|
39
|
+
});
|
|
40
|
+
r.sort((e, n) => !!e.isPlaceholder != !!n.isPlaceholder ? e.isPlaceholder ? 1 : -1 : String(e.clientId).localeCompare(String(n.clientId)));
|
|
41
|
+
const i = /* @__PURE__ */ new Set();
|
|
42
|
+
return r.filter((e) => e.isPlaceholder || !e.name ? !0 : i.has(e.name) ? !1 : (i.add(e.name), !0));
|
|
43
|
+
}
|
|
44
|
+
function _(o, t) {
|
|
45
|
+
const r = new Set(
|
|
46
|
+
o.filter(({ isPlaceholder: e, name: n }) => !e && n).map(({ name: e }) => e)
|
|
47
|
+
);
|
|
48
|
+
t.forEach((e, n) => {
|
|
49
|
+
r.has(n) || t.delete(n);
|
|
50
|
+
});
|
|
51
|
+
const i = /* @__PURE__ */ new Set();
|
|
52
|
+
return o.forEach((e) => {
|
|
53
|
+
if (e.isPlaceholder || !e.name) return;
|
|
54
|
+
let n = t.get(e.name);
|
|
55
|
+
(!n || i.has(n)) && (n = s.find((c) => !i.has(c)) ?? n ?? s[t.size % s.length], t.set(e.name, n)), i.add(n), e.color = n;
|
|
56
|
+
}), o;
|
|
57
|
+
}
|
|
58
|
+
function g(o, t) {
|
|
59
|
+
return o.slice().sort().map((r) => {
|
|
60
|
+
const i = t.get(r);
|
|
61
|
+
return i ? `${r}:${i.name}:${i.isEns}` : `${r}:?`;
|
|
62
|
+
}).join("|");
|
|
63
|
+
}
|
|
64
|
+
const p = l, C = u, w = [
|
|
3
65
|
{
|
|
4
66
|
id: "0",
|
|
5
67
|
name: "Sheet1",
|
|
@@ -7,7 +69,7 @@ const E = a, d = n, f = [
|
|
|
7
69
|
config: {},
|
|
8
70
|
order: 0
|
|
9
71
|
}
|
|
10
|
-
],
|
|
72
|
+
], A = [
|
|
11
73
|
"undo",
|
|
12
74
|
"redo",
|
|
13
75
|
"format-painter",
|
|
@@ -45,7 +107,7 @@ const E = a, d = n, f = [
|
|
|
45
107
|
"quick-formula",
|
|
46
108
|
"dataVerification",
|
|
47
109
|
"search"
|
|
48
|
-
],
|
|
110
|
+
], L = [
|
|
49
111
|
"cut",
|
|
50
112
|
"copy",
|
|
51
113
|
"paste",
|
|
@@ -82,7 +144,7 @@ const E = a, d = n, f = [
|
|
|
82
144
|
"freeze-row",
|
|
83
145
|
"|",
|
|
84
146
|
"clear-format"
|
|
85
|
-
],
|
|
147
|
+
], R = [
|
|
86
148
|
"cut",
|
|
87
149
|
"copy",
|
|
88
150
|
"paste",
|
|
@@ -119,41 +181,36 @@ const E = a, d = n, f = [
|
|
|
119
181
|
"freeze-column",
|
|
120
182
|
"|",
|
|
121
183
|
"clear-format"
|
|
122
|
-
],
|
|
184
|
+
], O = {
|
|
123
185
|
height: null,
|
|
124
186
|
isShow: !1,
|
|
125
187
|
left: null,
|
|
126
188
|
top: null,
|
|
127
189
|
value: "",
|
|
128
190
|
width: null
|
|
129
|
-
},
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
"#fa69d1",
|
|
133
|
-
"#ecd444",
|
|
134
|
-
"#ee6352",
|
|
135
|
-
"#db3041",
|
|
136
|
-
"#0ad7f2",
|
|
137
|
-
"#1bff39"
|
|
138
|
-
];
|
|
139
|
-
function c(e) {
|
|
140
|
-
return r[e % r.length];
|
|
191
|
+
}, d = "#5298FF";
|
|
192
|
+
function f(o) {
|
|
193
|
+
return s[o % s.length];
|
|
141
194
|
}
|
|
142
|
-
function
|
|
195
|
+
function E() {
|
|
143
196
|
return "#" + Math.floor(Math.random() * 16777215).toString(16).padStart(6, "0");
|
|
144
197
|
}
|
|
145
|
-
function
|
|
146
|
-
return
|
|
198
|
+
function P(o, t, r) {
|
|
199
|
+
return t || (o ? d : r != null ? f(r) : E());
|
|
147
200
|
}
|
|
148
201
|
export {
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
E,
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
202
|
+
O as C,
|
|
203
|
+
w as D,
|
|
204
|
+
p as E,
|
|
205
|
+
R as H,
|
|
206
|
+
C as S,
|
|
207
|
+
A as T,
|
|
208
|
+
_ as a,
|
|
209
|
+
h as b,
|
|
210
|
+
s as c,
|
|
211
|
+
L as d,
|
|
212
|
+
d as e,
|
|
213
|
+
g as i,
|
|
214
|
+
S as m,
|
|
215
|
+
P as p
|
|
159
216
|
};
|
package/dist/constants.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { ERROR_MESSAGES_FLAG, SERVICES_API_KEY, } from './editor/constants/shared-constants';
|
|
2
|
+
export { COLLAB_PRESENCE_COLORS } from './sync-local/presence';
|
|
2
3
|
export declare const ENS_PRESENCE_COLOR = "#5298FF";
|
|
3
|
-
|
|
4
|
-
/** ENS brand color, else `color`, else palette by `clientId`, else random. */
|
|
4
|
+
/** Explicit awareness color, else ENS brand color, palette, or random fallback. */
|
|
5
5
|
export declare function presenceColor(isEns: boolean | undefined, color?: string, clientId?: number): string;
|
package/dist/constants.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { c as R, e as _, E as C, S as s, p as O } from "./constants-exC_CJ-T.js";
|
|
2
2
|
export {
|
|
3
3
|
R as COLLAB_PRESENCE_COLORS,
|
|
4
4
|
_ as ENS_PRESENCE_COLOR,
|
|
5
5
|
C as ERROR_MESSAGES_FLAG,
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
s as SERVICES_API_KEY,
|
|
7
|
+
O as presenceColor
|
|
8
8
|
};
|