@fileverse-dev/dsheet 4.1.1-edit-mode-16 → 4.1.2-overhaul-1

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.
Files changed (63) hide show
  1. package/README.md +7 -9
  2. package/dist/{constants-B3rfAvvz.js → constants-5ZxHFftQ.js} +22 -79
  3. package/dist/constants.d.ts +2 -2
  4. package/dist/constants.js +3 -3
  5. package/dist/crypto-constants-CY-Whjwy.js +333 -0
  6. package/dist/editor/components/editor-workbook.d.ts +1 -5
  7. package/dist/editor/components/permission-chip.d.ts +1 -5
  8. package/dist/editor/contexts/editor-context.d.ts +2 -11
  9. package/dist/editor/dsheet-editor.d.ts +2 -3
  10. package/dist/editor/hooks/use-collab-awareness.d.ts +6 -3
  11. package/dist/editor/hooks/use-editor-data.d.ts +2 -2
  12. package/dist/editor/hooks/use-editor-sync.d.ts +2 -6
  13. package/dist/editor/types/comments.d.ts +11 -0
  14. package/dist/editor/types.d.ts +4 -30
  15. package/dist/editor/utils/apply-comment-markers.d.ts +3 -11
  16. package/dist/editor/utils/comment-anchors-ydoc.d.ts +32 -0
  17. package/dist/editor/utils/remap-comment-anchors.d.ts +26 -0
  18. package/dist/{executeStringFunction-CxsiamWG.js → executeStringFunction-adhsb5GH.js} +1152 -1107
  19. package/dist/formula.js +1 -1
  20. package/dist/{index-DQvYqAJz.js → index-DC_Tcoo4.js} +27654 -28038
  21. package/dist/index.d.ts +3 -4
  22. package/dist/index.es.js +52 -55
  23. package/dist/persistence-utils-DsM_MOB1.js +89 -0
  24. package/dist/persistence-utils.d.ts +0 -6
  25. package/dist/persistence.js +1 -1
  26. package/dist/sheet-engine/core/index.d.ts +1 -1
  27. package/dist/sheet-engine/core/settings.d.ts +40 -0
  28. package/dist/sheet-engine/core/utils/comment-anchor-move.d.ts +17 -0
  29. package/dist/sheet-engine/react/components/Toolbar/index.d.ts +0 -1
  30. package/dist/sheet-engine/react/components/Workbook/index.d.ts +0 -1
  31. package/dist/style.css +1 -1
  32. package/dist/sync-local/SyncManager.d.ts +9 -54
  33. package/dist/sync-local/index.d.ts +1 -1
  34. package/dist/sync-local/socketClient.d.ts +8 -75
  35. package/dist/sync-local/types/index.d.ts +15 -111
  36. package/dist/sync-local/useSyncManager.d.ts +0 -4
  37. package/dist/sync-local/utils/objectToFile.d.ts +1 -0
  38. package/dist/{use-xlsx-import-impl-DjiPGIoS.js → use-xlsx-import-impl-CcET8OCA.js} +148 -148
  39. package/dist/{xlsx-defined-names-Dr4_psg0.js → xlsx-defined-names-u1Jyf-M6.js} +2 -2
  40. package/dist/{xlsx-export-impl-D2YNoxJm.js → xlsx-export-impl-BjQj4U0N.js} +192 -188
  41. package/dist/{xlsx-hyperlink-inline-BkLFFNwP.js → xlsx-hyperlink-inline-D2-WOlOD.js} +2 -2
  42. package/package.json +2 -2
  43. package/dist/crypto-constants-ZTlAYRUf.js +0 -1165
  44. package/dist/editor/components/editor-workbook-controls.d.ts +0 -11
  45. package/dist/editor/components/permission-chip-model.d.ts +0 -34
  46. package/dist/editor/components/permission-chip.test.d.ts +0 -1
  47. package/dist/editor/hooks/collaboration-lifecycle.d.ts +0 -35
  48. package/dist/editor/hooks/collaboration-lifecycle.test.d.ts +0 -1
  49. package/dist/editor/utils/detach-workbook-data.d.ts +0 -8
  50. package/dist/editor/utils/detach-workbook-data.test.d.ts +0 -1
  51. package/dist/editor/utils/editor-handle.d.ts +0 -11
  52. package/dist/editor/utils/editor-handle.test.d.ts +0 -1
  53. package/dist/persistence-utils-BXFajzvq.js +0 -98
  54. package/dist/persistence-utils.test.d.ts +0 -1
  55. package/dist/sync-local/crypto/room-key.d.ts +0 -2
  56. package/dist/sync-local/crypto/room-key.test.d.ts +0 -1
  57. package/dist/sync-local/floor.d.ts +0 -8
  58. package/dist/sync-local/floor.test.d.ts +0 -1
  59. package/dist/sync-local/presence.d.ts +0 -13
  60. package/dist/sync-local/presence.test.d.ts +0 -1
  61. package/dist/sync-local/session-tools.d.ts +0 -31
  62. package/dist/sync-local/session-tools.test.d.ts +0 -1
  63. /package/dist/editor/{components/editor-workbook-controls.test.d.ts → utils/remap-comment-anchors.test.d.ts} +0 -0
package/README.md CHANGED
@@ -1,21 +1,19 @@
1
- # Fileverse DSheet
1
+ # Fileverse dSheets
2
2
 
3
3
  [![NPM](https://img.shields.io/npm/v/@fileverse-dev/dsheet)](https://www.npmjs.com/package/@fileverse-dev/dsheet)
4
4
  [![TypeScript](https://img.shields.io/badge/TypeScript-Ready-blue.svg)](https://www.typescriptlang.org/)
5
5
 
6
- [dsheets.new](http://dsheets.new/) is your decentralised alternative to google sheets & excel. Use it to read, manipulate, and even write onchain data, in real-time. Built on the same middleware as ddocs.new, the app is privacy-first, self-sovereign, and gives you full control over your data <3
6
+ [dsheets.new](http://dsheets.new/) is your end-to-end encrypted alternative to Google Sheets & Excel. Use it to read, manipulate, and even write financial data, in real-time. Built on the same middleware as ddocs.new, the app is privacy-focused, sovereign, and gives you full control over your data.
7
7
 
8
- ## 👩‍🏭 Features:
8
+ ## 𓆣 Features include:
9
9
  - End-to-end encryption
10
10
  - Local & peer-to-peer storage
11
- - Query live data from APIs & smart contracts
12
- - Write onchain: simulate + submit transactions (V0.3)
11
+ - Query live data from APIs & even smart contracts
12
+ - Enable dark mode and other color themes
13
13
  - Use a familiar spreadsheets interface & functions (VLOOKUP, INDEX, MATCH…)
14
- - Granular access permissions (email, wallet, ENS)
14
+ - Granular access permissions (e.g., give view, comment, edit, suggest access to specific email addresses)
15
15
 
16
- [**Try Live Demo →**](https://fileverse-dsheet.vercel.app/)
17
-
18
- ![image](https://github.com/user-attachments/assets/b3953811-3e02-43ac-9e8e-ee0c3923a22f)
16
+ <img width="1532" height="974" alt="dsheetsnew" src="https://github.com/user-attachments/assets/8bd67463-e999-41f4-b414-9d017fbf9466" />
19
17
 
20
18
 
21
19
  ## Installation
@@ -1,5 +1,5 @@
1
- import { E as l, S as u } from "./crypto-constants-ZTlAYRUf.js";
2
- const h = l, S = u, _ = [
1
+ import { E as a, S as n } from "./crypto-constants-CY-Whjwy.js";
2
+ const E = a, d = n, f = [
3
3
  {
4
4
  id: "0",
5
5
  name: "Sheet1",
@@ -7,7 +7,7 @@ const h = l, S = u, _ = [
7
7
  config: {},
8
8
  order: 0
9
9
  }
10
- ], g = [
10
+ ], m = [
11
11
  "undo",
12
12
  "redo",
13
13
  "format-painter",
@@ -45,7 +45,7 @@ const h = l, S = u, _ = [
45
45
  "quick-formula",
46
46
  "dataVerification",
47
47
  "search"
48
- ], p = [
48
+ ], u = [
49
49
  "cut",
50
50
  "copy",
51
51
  "paste",
@@ -82,7 +82,7 @@ const h = l, S = u, _ = [
82
82
  "freeze-row",
83
83
  "|",
84
84
  "clear-format"
85
- ], C = [
85
+ ], S = [
86
86
  "cut",
87
87
  "copy",
88
88
  "paste",
@@ -119,14 +119,14 @@ const h = l, S = u, _ = [
119
119
  "freeze-column",
120
120
  "|",
121
121
  "clear-format"
122
- ], w = {
122
+ ], _ = {
123
123
  height: null,
124
124
  isShow: !1,
125
125
  left: null,
126
126
  top: null,
127
127
  value: "",
128
128
  width: null
129
- }, a = "#9CA3AF", s = [
129
+ }, l = "#5298FF", r = [
130
130
  "#30bced",
131
131
  "#6eeb83",
132
132
  "#fa69d1",
@@ -136,81 +136,24 @@ const h = l, S = u, _ = [
136
136
  "#0ad7f2",
137
137
  "#1bff39"
138
138
  ];
139
- function A(o) {
140
- const t = /* @__PURE__ */ new Map();
141
- return o.forEach((r) => {
142
- const i = r == null ? void 0 : r.socketId, e = r == null ? void 0 : r.user;
143
- typeof i == "string" && e && t.set(i, {
144
- name: e.name ?? "",
145
- color: e.color ?? a,
146
- isEns: e.isEns ?? ""
147
- });
148
- }), t;
139
+ function c(e) {
140
+ return r[e % r.length];
149
141
  }
150
- function L(o, t) {
151
- const r = o.map((e) => {
152
- const n = t.get(e);
153
- return n ? {
154
- clientId: e,
155
- name: n.name,
156
- color: n.color,
157
- isEns: n.isEns,
158
- isPlaceholder: !1
159
- } : {
160
- clientId: e,
161
- name: "",
162
- color: a,
163
- isEns: "",
164
- isPlaceholder: !0
165
- };
166
- });
167
- r.sort((e, n) => !!e.isPlaceholder != !!n.isPlaceholder ? e.isPlaceholder ? 1 : -1 : String(e.clientId).localeCompare(String(n.clientId)));
168
- const i = /* @__PURE__ */ new Set();
169
- return r.filter((e) => e.isPlaceholder || !e.name ? !0 : i.has(e.name) ? !1 : (i.add(e.name), !0));
170
- }
171
- function R(o, t) {
172
- const r = new Set(
173
- o.filter(({ isPlaceholder: e, name: n }) => !e && n).map(({ name: e }) => e)
174
- );
175
- t.forEach((e, n) => {
176
- r.has(n) || t.delete(n);
177
- });
178
- const i = /* @__PURE__ */ new Set();
179
- return o.forEach((e) => {
180
- if (e.isPlaceholder || !e.name) return;
181
- let n = t.get(e.name);
182
- (!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;
183
- }), o;
184
- }
185
- function O(o, t) {
186
- return o.slice().sort().map((r) => {
187
- const i = t.get(r);
188
- return i ? `${r}:${i.name}:${i.isEns}` : `${r}:?`;
189
- }).join("|");
190
- }
191
- const d = "#5298FF";
192
- function f(o) {
193
- return s[o % s.length];
194
- }
195
- function E() {
142
+ function i() {
196
143
  return "#" + Math.floor(Math.random() * 16777215).toString(16).padStart(6, "0");
197
144
  }
198
- function P(o, t, r) {
199
- return t || (o ? d : r != null ? f(r) : E());
145
+ function h(e, o, t) {
146
+ return e ? l : o ?? (t != null ? c(t) : i());
200
147
  }
201
148
  export {
202
- w as C,
203
- _ as D,
204
- h as E,
205
- C as H,
206
- S,
207
- g as T,
208
- R as a,
209
- A as b,
210
- s as c,
211
- p as d,
212
- d as e,
213
- O as i,
214
- L as m,
215
- P as p
149
+ _ as C,
150
+ f as D,
151
+ E,
152
+ S as H,
153
+ d as S,
154
+ m as T,
155
+ r as a,
156
+ u as b,
157
+ l as c,
158
+ h as p
216
159
  };
@@ -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';
3
2
  export declare const ENS_PRESENCE_COLOR = "#5298FF";
4
- /** Explicit awareness color, else ENS brand color, palette, or random fallback. */
3
+ export declare const COLLAB_PRESENCE_COLORS: readonly ["#30bced", "#6eeb83", "#fa69d1", "#ecd444", "#ee6352", "#db3041", "#0ad7f2", "#1bff39"];
4
+ /** ENS brand color, else `color`, else palette by `clientId`, else random. */
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 { c as R, e as _, E as C, S as s, p as O } from "./constants-B3rfAvvz.js";
1
+ import { a as R, c as _, E as C, S as a, p as s } from "./constants-5ZxHFftQ.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
- s as SERVICES_API_KEY,
7
- O as presenceColor
6
+ a as SERVICES_API_KEY,
7
+ s as presenceColor
8
8
  };
@@ -0,0 +1,333 @@
1
+ var y = Object.create, u = Object.defineProperty, _ = Object.getOwnPropertyDescriptor, m = Object.getOwnPropertyNames, v = Object.getPrototypeOf, E = Object.prototype.hasOwnProperty, c = (n, e) => function() {
2
+ return e || (0, n[m(n)[0]])((e = { exports: {} }).exports, e), e.exports;
3
+ }, f = (n, e, i, a) => {
4
+ if (e && typeof e == "object" || typeof e == "function")
5
+ for (let t of m(e))
6
+ !E.call(n, t) && t !== i && u(n, t, { get: () => e[t], enumerable: !(a = _(e, t)) || a.enumerable });
7
+ return n;
8
+ }, b = (n, e, i) => (i = n != null ? y(v(n)) : {}, f(
9
+ // If the importer is in node compatibility mode or this is not an ESM
10
+ // file that has been converted to a CommonJS file using a Babel-
11
+ // compatible transform (i.e. "__esModule" has not been set), then set
12
+ // "default" to the CommonJS "module.exports" for node compatibility.
13
+ u(i, "default", { value: n, enumerable: !0 }),
14
+ n
15
+ )), x = c({
16
+ "node_modules/jwt-decode/lib/atob.js"(n, e) {
17
+ var i = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
18
+ function a(r) {
19
+ this.message = r;
20
+ }
21
+ a.prototype = new Error(), a.prototype.name = "InvalidCharacterError";
22
+ function t(r) {
23
+ var o = String(r).replace(/=+$/, "");
24
+ if (o.length % 4 == 1)
25
+ throw new a("'atob' failed: The string to be decoded is not correctly encoded.");
26
+ for (
27
+ var s = 0, d, l, g = 0, p = "";
28
+ // get next character
29
+ l = o.charAt(g++);
30
+ // character found in table? initialize bit storage and add its ascii value;
31
+ ~l && (d = s % 4 ? d * 64 + l : l, // and if not first of each 4 characters,
32
+ // convert the first 8 bits to one ascii character
33
+ s++ % 4) ? p += String.fromCharCode(255 & d >> (-2 * s & 6)) : 0
34
+ )
35
+ l = i.indexOf(l);
36
+ return p;
37
+ }
38
+ e.exports = typeof window < "u" && window.atob && window.atob.bind(window) || t;
39
+ }
40
+ }), O = c({
41
+ "node_modules/jwt-decode/lib/base64_url_decode.js"(n, e) {
42
+ var i = x();
43
+ function a(t) {
44
+ return decodeURIComponent(i(t).replace(/(.)/g, function(r, o) {
45
+ var s = o.charCodeAt(0).toString(16).toUpperCase();
46
+ return s.length < 2 && (s = "0" + s), "%" + s;
47
+ }));
48
+ }
49
+ e.exports = function(t) {
50
+ var r = t.replace(/-/g, "+").replace(/_/g, "/");
51
+ switch (r.length % 4) {
52
+ case 0:
53
+ break;
54
+ case 2:
55
+ r += "==";
56
+ break;
57
+ case 3:
58
+ r += "=";
59
+ break;
60
+ default:
61
+ throw "Illegal base64url string!";
62
+ }
63
+ try {
64
+ return a(r);
65
+ } catch {
66
+ return i(r);
67
+ }
68
+ };
69
+ }
70
+ }), w = c({
71
+ "node_modules/jwt-decode/lib/index.js"(n, e) {
72
+ var i = O();
73
+ function a(t) {
74
+ this.message = t;
75
+ }
76
+ a.prototype = new Error(), a.prototype.name = "InvalidTokenError", e.exports = function(t, r) {
77
+ if (typeof t != "string")
78
+ throw new a("Invalid token specified");
79
+ r = r || {};
80
+ var o = r.header === !0 ? 0 : 1;
81
+ try {
82
+ return JSON.parse(i(t.split(".")[o]));
83
+ } catch (s) {
84
+ throw new a("Invalid token specified: " + s.message);
85
+ }
86
+ }, e.exports.InvalidTokenError = a;
87
+ }
88
+ }), k = c({
89
+ "node_modules/jwt-check-expiration/src/index.js"(n, e) {
90
+ var i = w(), a = (t) => {
91
+ if (typeof t != "string" || !t) throw new Error("Invalid token provided");
92
+ let r = !1;
93
+ const { exp: o } = i(t);
94
+ return (/* @__PURE__ */ new Date()).getTime() / 1e3 > o && (r = !0), r;
95
+ };
96
+ e.exports.isJwtExpired = a;
97
+ }
98
+ }), I = {
99
+ INVALID_API_KEY: "INVALID_API_KEY",
100
+ RATE_LIMIT: "RATE_LIMIT",
101
+ DEFAULT: "DEFAULT",
102
+ MISSING_KEY: "MISSING_KEY",
103
+ INVALID_PARAM: "INVALID_PARAM",
104
+ NETWORK_ERROR: "NETWORK_ERROR",
105
+ ENS: "ENS"
106
+ }, h = {
107
+ Etherscan: "Etherscan",
108
+ Coingecko: "Coingecko",
109
+ Safe: "Safe",
110
+ Basescan: "Basescan",
111
+ Gnosisscan: "Gnosisscan",
112
+ Firefly: "Firefly",
113
+ GnosisPay: "GnosisPay",
114
+ Neynar: "Neynar",
115
+ Defillama: "Defillama",
116
+ DuneSim: "DuneSim"
117
+ }, A = {
118
+ API_KEY: h.Etherscan,
119
+ LOGO: "https://raw.githubusercontent.com/ethereum/ethereum-org/master/dist/favicon.ico",
120
+ BRAND_COLOR: "#F6F7F8",
121
+ BRAND_SECONDARY_COLOR: "#21325B",
122
+ n: "EOA",
123
+ t: 20,
124
+ d: "Fetches address data like transactions, balances, or portfolio info from multiple supported chains.",
125
+ a: "Dynamically queries blockchain data such as transactions and balances by resolving time ranges to block ranges and supporting pagination.",
126
+ p: [
127
+ {
128
+ name: "addresses",
129
+ detail: "One or more addresses (comma-separated) to query.",
130
+ example: '"vitalik.eth"',
131
+ require: "m",
132
+ type: "string"
133
+ },
134
+ {
135
+ name: "categories",
136
+ detail: 'Type of data to fetch. Supported values: "txns", "balance".',
137
+ example: '"txns"',
138
+ require: "m",
139
+ type: "string"
140
+ },
141
+ {
142
+ name: "chain",
143
+ detail: 'Blockchain network(s) to query. Supported values: "ethereum", "gnosis", "base". Accepts comma-separated values.',
144
+ example: '"ethereum"',
145
+ require: "m",
146
+ type: "string"
147
+ },
148
+ {
149
+ name: "startTime",
150
+ detail: "Used to calculate starting block for transaction queries.",
151
+ example: '"01/01/2024"',
152
+ require: "m",
153
+ type: "string"
154
+ },
155
+ {
156
+ name: "endTime",
157
+ detail: "Used to calculate ending block for transaction queries.",
158
+ example: '"01/06/2024"',
159
+ require: "m",
160
+ type: "string"
161
+ },
162
+ {
163
+ name: "page",
164
+ detail: "The page number for paginated transaction results. Only used when category is 'txns'. Default is 1",
165
+ example: "1",
166
+ require: "o",
167
+ type: "number"
168
+ },
169
+ {
170
+ name: "offset",
171
+ detail: "The number of results to return per page (limit). Only used when category is 'txns'. Default is 10",
172
+ example: "10",
173
+ require: "o",
174
+ type: "number"
175
+ },
176
+ {
177
+ name: "columnsName",
178
+ detail: "Filter columns by name in output. Comma separated list.",
179
+ example: '"address,blockNumber"',
180
+ require: "o",
181
+ type: "string"
182
+ }
183
+ ],
184
+ examples: [{
185
+ title: "EOA",
186
+ argumentString: '"vitalik.eth", "txns", "ethereum", "01/01/2023", "01/05/2024", 1, 2',
187
+ description: "returns the transaction history for the address vitalik.eth on the Ethereum blockchain between January 1, 2023 and January 5, 2024, returning page 1 with 2 transactions per page."
188
+ }, {
189
+ title: "EOA",
190
+ argumentString: '"vitalik.eth", "balance", "gnosis"',
191
+ description: "returns the balance for the address vitalik.eth on the Gnosis blockchain."
192
+ }]
193
+ }, S = {
194
+ API_KEY: h.Etherscan,
195
+ LOGO: "https://etherscan.io/images/favicon3.ico",
196
+ BRAND_COLOR: "#F6F7F8",
197
+ BRAND_SECONDARY_COLOR: "#21325B",
198
+ n: "ETHERSCAN",
199
+ t: 20,
200
+ d: "Returns blockchain transaction history for the given address",
201
+ a: "Retrieves blockchain data for a given chain and address from Etherscan, including txns, token/nft transfers, and gas metrics.",
202
+ p: [
203
+ {
204
+ name: "type",
205
+ detail: "The type of data to retrieve. Can be 'all-txns', 'token-txns', 'nft-txns', or 'gas'.",
206
+ example: '"all-txns"',
207
+ require: "m",
208
+ type: "string"
209
+ },
210
+ {
211
+ name: "chain",
212
+ detail: "The chain name (e.g. 'ethereum', 'base', 'gnosis').",
213
+ example: '"ethereum"',
214
+ require: "m",
215
+ type: "string"
216
+ },
217
+ {
218
+ name: "address",
219
+ detail: "Wallet address / Ens name to query",
220
+ example: '"vitalik.eth"',
221
+ require: "m",
222
+ type: "string"
223
+ },
224
+ {
225
+ name: "startDate",
226
+ detail: "Used to filter block range.",
227
+ example: '"01/01/2024"',
228
+ require: "o",
229
+ type: "string"
230
+ },
231
+ {
232
+ name: "endDate",
233
+ detail: "Used to filter block range.",
234
+ example: '"01/07/2025"',
235
+ require: "o",
236
+ type: "string"
237
+ },
238
+ {
239
+ name: "columnsName",
240
+ detail: "Filter columns by name in output. Comma separated list.",
241
+ example: '"blockNumber,timeStamp"',
242
+ require: "o",
243
+ type: "string"
244
+ }
245
+ ],
246
+ examples: [
247
+ {
248
+ title: "ETHERSCAN",
249
+ argumentString: '"all-txns", "ethereum", "vitalik.eth"',
250
+ description: "returns the complete transaction history for the address vitalik.eth on the Ethereum blockchain."
251
+ },
252
+ {
253
+ title: "ETHERSCAN",
254
+ argumentString: '"token-txns", "gnosis", "vitalik.eth", "01/01/2024", "01/05/2024"',
255
+ description: "returns the token transaction history for the address vitalik.eth on the Gnosis blockchain between January 1, 2024 and January 5, 2024."
256
+ }
257
+ ]
258
+ }, R = [
259
+ A,
260
+ S
261
+ // UNISWAP_metadata,
262
+ // COINGECKO_metadata,
263
+ // DEFILLAMA_metadata,
264
+ // BASE_metadata,
265
+ // GNOSIS_metadata,
266
+ // PNL_metadata,
267
+ // SAFE_metadata,
268
+ // BLOCKSCOUT_metadata,
269
+ // AAVE_metadata,
270
+ // FIREFLY_metadata,
271
+ // SMARTCONTRACT_metadata,
272
+ // TALLY_metadata,
273
+ // DUNESIM_metadata,
274
+ // PRICE_metadata,
275
+ // WALLET_metadata,
276
+ // YIELD_metadata,
277
+ // CIRCLES_metadata
278
+ // GNOSISPAY_metadata,
279
+ /*{
280
+ LOGO: 'https://raw.githubusercontent.com/mritunjayz/github-storage/refs/heads/main/ploymarket.png',
281
+ n: 'POLYMARKET',
282
+ t: 20,
283
+ d: 'Query prediction market positions, shares, and odds for future event outcomes on Polymarket. (Comming soon)',
284
+ a: 'Query prediction market positions, shares, and odds for future event outcomes on Polymarket. (Comming soon)',
285
+ p: []
286
+ },
287
+ {
288
+ LOGO: 'https://raw.githubusercontent.com/mritunjayz/github-storage/refs/heads/main/privacy.png',
289
+ n: 'PRIVACYPOOL',
290
+ t: 20,
291
+ d: 'Access deposit/withdraw stats and compliance-safe anonymized transfers using zk-based Privacy Pools. (Comming soon)',
292
+ a: 'Access deposit/withdraw stats and compliance-safe anonymized transfers using zk-based Privacy Pools. (Comming soon)',
293
+ p: []
294
+ },
295
+ {
296
+ LOGO: 'https://raw.githubusercontent.com/mritunjayz/github-storage/refs/heads/main/rotki.png',
297
+ n: 'ROTKI',
298
+ t: 20,
299
+ d: 'Pull portfolio, asset, and tax-related data from Rotki for crypto accounting and reporting. (Comming soon)',
300
+ a: 'Pull portfolio, asset, and tax-related data from Rotki for crypto accounting and reporting. (Comming soon)',
301
+ p: []
302
+ },
303
+ {
304
+ LOGO: 'https://raw.githubusercontent.com/mritunjayz/github-storage/refs/heads/main/meerkat.png',
305
+ n: 'MEERKAT',
306
+ t: 20,
307
+ d: 'Query onchain proofs for tickets, attendance, speaker roles, and reactions. (Comming soon)',
308
+ a: 'Query onchain proofs for tickets, attendance, speaker roles, and reactions. (Comming soon)',
309
+ p: []
310
+ },
311
+ {
312
+ LOGO: 'https://raw.githubusercontent.com/mritunjayz/github-storage/refs/heads/main/artemis.png',
313
+ n: 'ARTEMIS',
314
+ t: 20,
315
+ d: 'Query onchain financial metrics, developer activity, and market insights across protocols and sectors. (Comming soon)',
316
+ a: 'Query onchain financial metrics, developer activity, and market insights across protocols and sectors. (Comming soon)',
317
+ p: []
318
+ },
319
+ {
320
+ LOGO: 'https://raw.githubusercontent.com/mritunjayz/github-storage/refs/heads/main/MYANIMELIST.png',
321
+ n: 'MYANIMELIST',
322
+ t: 20,
323
+ d: 'Kawaiii, comming soon. Hello Keith! (Comming soon)',
324
+ a: 'Kawaiii, comming soon. Hello Keith! (Comming soon)',
325
+ p: []
326
+ }*/
327
+ ];
328
+ b(k());
329
+ export {
330
+ I as E,
331
+ R as F,
332
+ h as S
333
+ };
@@ -1,7 +1,7 @@
1
1
  import { default as React } from 'react';
2
2
  import { SidebarPortalRegistryHandle, SidebarPortalRenderer } from '../../sheet-engine/react';
3
3
  import { ThemeKey } from '../../sheet-engine/core/theme';
4
- import { OnboardingHandlerType, DSheetPermissionMode } from '../types';
4
+ import { OnboardingHandlerType } from '../types';
5
5
  import { CommentsConfig } from '../types/comments';
6
6
 
7
7
  type OnboardingHandler = OnboardingHandlerType;
@@ -24,10 +24,6 @@ interface EditorWorkbookProps {
24
24
  sidebarActivePanel?: string | null;
25
25
  sidebarPortalRegistry?: SidebarPortalRegistryHandle | null;
26
26
  sidebarPortalRenderers?: Record<string, SidebarPortalRenderer>;
27
- permissionMode?: DSheetPermissionMode | null;
28
- onEnterEdit?: () => void;
29
- onSignInToComment?: () => void;
30
- onViewerModeChange?: (mode: 'comment' | 'view') => void;
31
27
  theme?: ThemeKey;
32
28
  }
33
29
  export declare const EditorWorkbook: React.NamedExoticComponent<EditorWorkbookProps>;
@@ -1,11 +1,7 @@
1
1
  import { default as React } from 'react';
2
- import { DSheetPermissionMode } from '../types';
3
2
 
4
3
  interface PermissionChipProps {
5
- mode: DSheetPermissionMode;
6
- onEnterEdit?: () => void;
7
- onSignInToComment?: () => void;
8
- onViewerModeChange?: (mode: 'comment' | 'view') => void;
4
+ allowComments: boolean;
9
5
  }
10
6
  export declare const PermissionChip: React.FC<PermissionChipProps>;
11
7
  export {};
@@ -1,7 +1,7 @@
1
1
  import { default as React } from 'react';
2
2
  import { LiveQueryData, Sheet, WorkbookInstance } from '../../sheet-engine/react';
3
3
  import { IndexeddbPersistence } from 'y-indexeddb';
4
- import { SheetUpdateData, DataBlockEvent, DSheetEditorHandle } from '../types';
4
+ import { SheetUpdateData, DataBlockEvent } from '../types';
5
5
  import { CommentsConfig } from '../types/comments';
6
6
  import { ApiKeyStorage } from '../utils/api-key-storage';
7
7
  import { OpenApiKeyModalFn } from '../utils/data-block-error-handler';
@@ -32,7 +32,6 @@ export interface EditorContextType {
32
32
  }>>;
33
33
  refreshIndexedDB: () => Promise<void>;
34
34
  sheetEditorRef: React.MutableRefObject<WorkbookInstance | null>;
35
- setSheetEditorRef: React.RefCallback<WorkbookInstance>;
36
35
  ydocRef: React.MutableRefObject<Y.Doc | null>;
37
36
  persistenceRef: React.MutableRefObject<IndexeddbPersistence | null>;
38
37
  sheetData: Sheet[];
@@ -46,7 +45,6 @@ export interface EditorContextType {
46
45
  setForceSheetRender: React.Dispatch<React.SetStateAction<number>>;
47
46
  syncStatus: 'initializing' | 'syncing' | 'synced' | 'error';
48
47
  collabEnabled?: boolean;
49
- isLiveCollabSession: boolean;
50
48
  collabIsOwner?: boolean;
51
49
  collabState?: CollabState;
52
50
  isCollabReady?: boolean;
@@ -81,8 +79,7 @@ interface EditorProviderProps {
81
79
  onContentUpdate?: () => void;
82
80
  onChange?: (data: SheetUpdateData, encodedUpdate?: string) => void;
83
81
  collaboration?: CollaborationProps;
84
- externalEditorRef?: React.Ref<DSheetEditorHandle>;
85
- legacyEditorRef?: React.Ref<DSheetEditorHandle>;
82
+ externalEditorRef?: React.MutableRefObject<WorkbookInstance | null>;
86
83
  commentsConfig?: CommentsConfig;
87
84
  editorStateRef?: React.MutableRefObject<{
88
85
  refreshIndexedDB: () => Promise<void>;
@@ -90,10 +87,6 @@ interface EditorProviderProps {
90
87
  mergeContent: (encodedState: string) => DSheetContentSnapshot;
91
88
  terminateSession?: () => void;
92
89
  updateCollaboratorName?: (name: string) => void;
93
- updateSessionTitle?: (args: {
94
- encryptedTitle: string;
95
- documentTitle: string;
96
- }) => void;
97
90
  rehydrateAfterCollabSync?: (reason?: string) => boolean;
98
91
  } | null>;
99
92
  enableLiveQuery?: boolean;
@@ -102,8 +95,6 @@ interface EditorProviderProps {
102
95
  onDataBlockEvent?: (event: DataBlockEvent) => void;
103
96
  smartContracts?: SmartContractConfig;
104
97
  onContentSyncStatusChange?: (status: 'initializing' | 'syncing' | 'synced' | 'error') => void;
105
- onCollaborationInitializationComplete?: (result: 'ready' | 'error') => void;
106
- onIndexedDbError?: (error: Error) => void;
107
98
  }
108
99
  export declare const EditorProvider: React.FC<EditorProviderProps>;
109
100
  export declare const useEditor: () => EditorContextType;
@@ -1,5 +1,4 @@
1
- import { default as React } from 'react';
2
- import { DSheetEditorHandle, DsheetProps } from './types';
1
+ import { DsheetProps } from './types';
3
2
 
4
3
  /**
5
4
  * SpreadsheetEditor component that provides a collaborative spreadsheet interface
@@ -8,5 +7,5 @@ import { DSheetEditorHandle, DsheetProps } from './types';
8
7
  * @param props - Component properties
9
8
  * @returns The SpreadsheetEditor component
10
9
  */
11
- declare const SpreadsheetEditor: React.ForwardRefExoticComponent<DsheetProps & React.RefAttributes<DSheetEditorHandle>>;
10
+ declare const SpreadsheetEditor: ({ isReadOnly, allowSheetDownload, renderNavbar, enableIndexeddbSync, dsheetId, portalContent, onContentUpdate, onChange, username, selectedTemplate, toggleTemplateSidebar, isTemplateOpen, onboardingComplete, onboardingCompleteLocalStorageKey, onboardingHandler, commentsConfig, setFetchingURLData, setShowFetchURLModal, setInputFetchURLDataBlock, sheetEditorRef: externalSheetEditorRef, onDuneChartEmbed, onSheetCountChange, isAuthorized, getDocumentTitle, updateDocumentTitle, editorStateRef, setSelectedTemplate, isNewSheet, liveQueryRefreshRate, enableLiveQuery, collaboration, customPanels, apiKeyStorage, onDataBlockEvent, smartContracts, theme, onContentSyncStatusChange, }: DsheetProps) => JSX.Element;
12
11
  export default SpreadsheetEditor;
@@ -1,14 +1,17 @@
1
1
  import { Awareness } from 'y-protocols/awareness';
2
2
  import { WorkbookInstance } from '../../sheet-engine/react';
3
+ import { CollabUser } from '../../sync-local/types';
3
4
 
4
5
  /**
5
6
  * Reads remote cursor positions from Yjs awareness and keeps Fortune sheet's
6
7
  * native presence list in sync. Fortune renders colored cell borders + username
7
8
  * labels automatically via context.presences[].
8
9
  *
9
- * The host collaborator roster is emitted by SocketClient from the
10
- * authoritative server room-members list. This hook owns only cell cursors.
10
+ * Also emits the full collaborator list (including the local user) via
11
+ * `onCollaboratorsChange` so host apps can render navbar chips. This mirrors
12
+ * ddoc's editor-layer awareness handler, which maps awareness.states →
13
+ * `{ clientId, ...user }` and fires on every awareness update + once on mount.
11
14
  */
12
- export declare const useCollabAwareness: (awareness: Awareness | null | undefined, sheetEditorRef: React.MutableRefObject<WorkbookInstance | null>) => {
15
+ export declare const useCollabAwareness: (awareness: Awareness | null | undefined, sheetEditorRef: React.MutableRefObject<WorkbookInstance | null>, onCollaboratorsChange?: (collaborators: CollabUser[]) => void) => {
13
16
  localColor: "#30bced" | "#6eeb83" | "#fa69d1" | "#ecd444" | "#ee6352" | "#db3041" | "#0ad7f2" | "#1bff39";
14
17
  };