@bananapus/nana-sdk-core 2.38.2 → 2.40.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.
Files changed (89) hide show
  1. package/dist/cjs/review/heldWrite.d.ts +113 -0
  2. package/dist/cjs/review/heldWrite.d.ts.map +1 -0
  3. package/dist/cjs/review/heldWrite.js +569 -0
  4. package/dist/cjs/review/heldWrite.js.map +1 -0
  5. package/dist/cjs/review/index.d.ts +2 -0
  6. package/dist/cjs/review/index.d.ts.map +1 -1
  7. package/dist/cjs/review/index.js +2 -0
  8. package/dist/cjs/review/index.js.map +1 -1
  9. package/dist/cjs/review/messages.d.ts +30 -0
  10. package/dist/cjs/review/messages.d.ts.map +1 -1
  11. package/dist/cjs/review/messages.js +34 -1
  12. package/dist/cjs/review/messages.js.map +1 -1
  13. package/dist/cjs/review/react/HeldWritesNotice.d.ts +11 -0
  14. package/dist/cjs/review/react/HeldWritesNotice.d.ts.map +1 -0
  15. package/dist/cjs/review/react/HeldWritesNotice.js +22 -0
  16. package/dist/cjs/review/react/HeldWritesNotice.js.map +1 -0
  17. package/dist/cjs/review/react/index.d.ts +5 -0
  18. package/dist/cjs/review/react/index.d.ts.map +1 -0
  19. package/dist/cjs/review/react/index.js +21 -0
  20. package/dist/cjs/review/react/index.js.map +1 -0
  21. package/dist/cjs/review/react/useHeldWrite.d.ts +63 -0
  22. package/dist/cjs/review/react/useHeldWrite.d.ts.map +1 -0
  23. package/dist/cjs/review/react/useHeldWrite.js +107 -0
  24. package/dist/cjs/review/react/useHeldWrite.js.map +1 -0
  25. package/dist/cjs/review/react/useHeldWrites.d.ts +40 -0
  26. package/dist/cjs/review/react/useHeldWrites.d.ts.map +1 -0
  27. package/dist/cjs/review/react/useHeldWrites.js +95 -0
  28. package/dist/cjs/review/react/useHeldWrites.js.map +1 -0
  29. package/dist/cjs/review/react/useSavedAttempt.d.ts +54 -0
  30. package/dist/cjs/review/react/useSavedAttempt.d.ts.map +1 -0
  31. package/dist/cjs/review/react/useSavedAttempt.js +105 -0
  32. package/dist/cjs/review/react/useSavedAttempt.js.map +1 -0
  33. package/dist/cjs/review/savedAttempt.d.ts +180 -0
  34. package/dist/cjs/review/savedAttempt.d.ts.map +1 -0
  35. package/dist/cjs/review/savedAttempt.js +527 -0
  36. package/dist/cjs/review/savedAttempt.js.map +1 -0
  37. package/dist/cjs/review/writeHold.d.ts +94 -2
  38. package/dist/cjs/review/writeHold.d.ts.map +1 -1
  39. package/dist/cjs/review/writeHold.js +284 -43
  40. package/dist/cjs/review/writeHold.js.map +1 -1
  41. package/dist/cjs/review/writeRecovery.d.ts +58 -0
  42. package/dist/cjs/review/writeRecovery.d.ts.map +1 -1
  43. package/dist/cjs/review/writeRecovery.js +161 -2
  44. package/dist/cjs/review/writeRecovery.js.map +1 -1
  45. package/dist/esm/review/heldWrite.d.ts +113 -0
  46. package/dist/esm/review/heldWrite.d.ts.map +1 -0
  47. package/dist/esm/review/heldWrite.js +562 -0
  48. package/dist/esm/review/heldWrite.js.map +1 -0
  49. package/dist/esm/review/index.d.ts +2 -0
  50. package/dist/esm/review/index.d.ts.map +1 -1
  51. package/dist/esm/review/index.js +2 -0
  52. package/dist/esm/review/index.js.map +1 -1
  53. package/dist/esm/review/messages.d.ts +30 -0
  54. package/dist/esm/review/messages.d.ts.map +1 -1
  55. package/dist/esm/review/messages.js +32 -0
  56. package/dist/esm/review/messages.js.map +1 -1
  57. package/dist/esm/review/react/HeldWritesNotice.d.ts +11 -0
  58. package/dist/esm/review/react/HeldWritesNotice.d.ts.map +1 -0
  59. package/dist/esm/review/react/HeldWritesNotice.js +19 -0
  60. package/dist/esm/review/react/HeldWritesNotice.js.map +1 -0
  61. package/dist/esm/review/react/index.d.ts +5 -0
  62. package/dist/esm/review/react/index.d.ts.map +1 -0
  63. package/dist/esm/review/react/index.js +5 -0
  64. package/dist/esm/review/react/index.js.map +1 -0
  65. package/dist/esm/review/react/useHeldWrite.d.ts +63 -0
  66. package/dist/esm/review/react/useHeldWrite.d.ts.map +1 -0
  67. package/dist/esm/review/react/useHeldWrite.js +104 -0
  68. package/dist/esm/review/react/useHeldWrite.js.map +1 -0
  69. package/dist/esm/review/react/useHeldWrites.d.ts +40 -0
  70. package/dist/esm/review/react/useHeldWrites.d.ts.map +1 -0
  71. package/dist/esm/review/react/useHeldWrites.js +91 -0
  72. package/dist/esm/review/react/useHeldWrites.js.map +1 -0
  73. package/dist/esm/review/react/useSavedAttempt.d.ts +54 -0
  74. package/dist/esm/review/react/useSavedAttempt.d.ts.map +1 -0
  75. package/dist/esm/review/react/useSavedAttempt.js +102 -0
  76. package/dist/esm/review/react/useSavedAttempt.js.map +1 -0
  77. package/dist/esm/review/savedAttempt.d.ts +180 -0
  78. package/dist/esm/review/savedAttempt.d.ts.map +1 -0
  79. package/dist/esm/review/savedAttempt.js +524 -0
  80. package/dist/esm/review/savedAttempt.js.map +1 -0
  81. package/dist/esm/review/writeHold.d.ts +94 -2
  82. package/dist/esm/review/writeHold.d.ts.map +1 -1
  83. package/dist/esm/review/writeHold.js +285 -44
  84. package/dist/esm/review/writeHold.js.map +1 -1
  85. package/dist/esm/review/writeRecovery.d.ts +58 -0
  86. package/dist/esm/review/writeRecovery.d.ts.map +1 -1
  87. package/dist/esm/review/writeRecovery.js +160 -2
  88. package/dist/esm/review/writeRecovery.js.map +1 -1
  89. package/package.json +16 -2
@@ -0,0 +1,562 @@
1
+ import { hasSafeService, SAFE_PROPOSAL_AWAITING, waitForSafeExecutionHash, } from "../safeService.js";
2
+ import { HELD_AWAY_SUCCESS_LINE, HELD_CONFIRMING_LINE, HELD_EXPIRED_LINE, HELD_RELEASED_ELSEWHERE_LINE, HELD_RELEASED_LINE, HELD_SUCCESS_LINE, WRITE_HOLD_PENDING_LINE, WRITE_HOLD_REVERTED_LINE, } from "./messages.js";
3
+ import { WriteHeldError, } from "./writeHold.js";
4
+ /** How often a held write is asked again: 30 s by default, kept between 15 s and 60 s. */
5
+ export const HELD_POLL_MS = 30_000;
6
+ const MIN_POLL_MS = 15_000;
7
+ const MAX_POLL_MS = 60_000;
8
+ /** A follower's first looks, a few seconds apart, before it slows to the poll. */
9
+ const FAST_MS = 4_000;
10
+ const FAST_LOOKS = 15;
11
+ /** A direct write's confirming line gives way to the wallet's pending line after this long. */
12
+ const CONFIRMING_MS = 120_000;
13
+ const pollOf = (ms) => Math.min(MAX_POLL_MS, Math.max(MIN_POLL_MS, ms ?? HELD_POLL_MS));
14
+ function pause(ms, signal) {
15
+ return new Promise((resolve) => {
16
+ const timer = setTimeout(done, ms);
17
+ signal.addEventListener("abort", done, { once: true });
18
+ function done() {
19
+ clearTimeout(timer);
20
+ signal.removeEventListener("abort", done);
21
+ resolve();
22
+ }
23
+ });
24
+ }
25
+ /**
26
+ * Follow one held write to its end, whatever becomes of the flow that sent
27
+ * it: a direct transaction by its hold's own reads, a Safe proposal also by
28
+ * Safe's service, whose execution goes to the hold (`onExecuted`) and whose
29
+ * loss ends it unproven (`onUnproven`). It ends only when the hold is clear
30
+ * (an authenticated settlement or an exit) or `signal` aborts: never on its
31
+ * own reading of a receipt, a replacement or an expiry. The hold decides.
32
+ */
33
+ export async function followHeldWrite(handle, client, { signal, pollMs, fastMs = FAST_MS, }) {
34
+ const now = handle.peek();
35
+ if (now.status !== "clear" &&
36
+ now.record.safe &&
37
+ now.record.hash &&
38
+ !now.record.executed &&
39
+ hasSafeService(now.record.chainId)) {
40
+ const proposal = now.record.hash;
41
+ void waitForSafeExecutionHash(now.record.chainId, proposal, {
42
+ signal,
43
+ client: client,
44
+ })
45
+ .then((execution) => handle.onExecuted(client, execution), () => (signal.aborted ? null : handle.onUnproven(client, proposal)))
46
+ .catch(() => null);
47
+ }
48
+ for (let look = 0; !signal.aborted; look += 1) {
49
+ const state = await handle.state(client).catch(() => null);
50
+ if (state?.status === "clear")
51
+ return state;
52
+ await pause(look < FAST_LOOKS ? fastMs : pollOf(pollMs), signal);
53
+ }
54
+ return null;
55
+ }
56
+ /** Reservations seen confirming in this tab: a new view of one never shows it awaiting. */
57
+ const confirmed = new Set();
58
+ /** One follower per reservation in this tab, however many views show it. */
59
+ const followers = new Map();
60
+ function followShared(reservation, handle, client, pollMs) {
61
+ let shared = followers.get(reservation);
62
+ // A follower stopped by its last view, still ending, is never rejoined.
63
+ if (!shared || shared.stop.signal.aborted) {
64
+ const stop = new AbortController();
65
+ const ended = followHeldWrite(handle, client, {
66
+ signal: stop.signal,
67
+ pollMs,
68
+ }).finally(() => {
69
+ if (followers.get(reservation)?.stop === stop)
70
+ followers.delete(reservation);
71
+ });
72
+ shared = { views: 0, stop, ended };
73
+ followers.set(reservation, shared);
74
+ }
75
+ shared.views += 1;
76
+ const joined = shared;
77
+ return {
78
+ ended: joined.ended,
79
+ leave() {
80
+ joined.views -= 1;
81
+ if (joined.views === 0)
82
+ joined.stop.abort();
83
+ },
84
+ };
85
+ }
86
+ /**
87
+ * Whether `next` would hide an exit `shown` offers without the chain having
88
+ * been checked: an emission, a replay or a contended read
89
+ * (`checked: false`). Only a checked answer removes it.
90
+ */
91
+ export function hidesShownExit(shown, next) {
92
+ return (!!shown &&
93
+ shown.status !== "clear" &&
94
+ shown.exit &&
95
+ next.status !== "clear" &&
96
+ !next.exit &&
97
+ next.checked !== true);
98
+ }
99
+ /** The line for a settlement. */
100
+ export function settledLine(settled) {
101
+ return settled.result === "success"
102
+ ? HELD_SUCCESS_LINE
103
+ : settled.result === "expired"
104
+ ? HELD_EXPIRED_LINE
105
+ : WRITE_HOLD_REVERTED_LINE;
106
+ }
107
+ /**
108
+ * One held write's view, framework-free: its phase and line, the watch
109
+ * (the hold's own events, and a checked read on start, on focus and every
110
+ * poll while held), a shared follower for its hash, its exit, its send and
111
+ * the adoption of a previous deploy's record. Every app binds the same one
112
+ * (useHeldWrite in React), so the same action behaves the same everywhere.
113
+ *
114
+ * - A read the chain didn't check never hides an exit already shown.
115
+ * - Once confirming, a write never goes back to awaiting.
116
+ * - `onSettled` fires once, only for a settlement of what this view saw held.
117
+ * - A hold released without a settlement is `released`: by the user's exit
118
+ * here, or neutrally by another window.
119
+ */
120
+ export function createHeldWriteView(handle, options) {
121
+ const { client } = options;
122
+ let view = {
123
+ phase: "clear",
124
+ state: null,
125
+ line: null,
126
+ exit: false,
127
+ adopting: !!options.adopt,
128
+ };
129
+ const listeners = new Set();
130
+ /** The reservation this view saw held, and whether its exit here released it. */
131
+ let observed;
132
+ let wasHeld = false;
133
+ let exitedHere;
134
+ const delivered = new Set();
135
+ /** Every reservation this view saw held and hasn't delivered: each is delivered once, whatever is shown. */
136
+ const seen = new Set();
137
+ let following;
138
+ let running = false;
139
+ /** Each start and stop begins a new lifecycle: a read or receipt from an earlier one is dropped. */
140
+ let epoch = 0;
141
+ let live = true;
142
+ let adoption;
143
+ function set(next) {
144
+ view = { ...view, ...next };
145
+ for (const listener of listeners)
146
+ listener();
147
+ }
148
+ function stopFollowing() {
149
+ following?.leave();
150
+ following = undefined;
151
+ }
152
+ function follow(reservation) {
153
+ if (options.follow === false ||
154
+ !running ||
155
+ following?.reservation === reservation)
156
+ return;
157
+ stopFollowing();
158
+ const shared = followShared(reservation, handle, client, options.pollMs);
159
+ const mine = { reservation, leave: shared.leave };
160
+ following = mine;
161
+ const at = epoch;
162
+ void shared.ended.then((end) => {
163
+ if (following === mine)
164
+ following = undefined;
165
+ if (end && at === epoch)
166
+ apply(end);
167
+ });
168
+ }
169
+ /** Settlements this view saw, still to tell the app, by reservation: kept across a restart. */
170
+ const undelivered = new Map();
171
+ /**
172
+ * Tell the app of a settlement it saw held, once, while live. Only once its
173
+ * callback ran is it done, and a success acknowledged: a lifecycle change
174
+ * before then leaves it to the next start.
175
+ */
176
+ function deliver(settled, key) {
177
+ undelivered.set(key, settled);
178
+ if (!live)
179
+ return;
180
+ const at = epoch;
181
+ const done = (receipt) => {
182
+ if (at !== epoch || delivered.has(key))
183
+ return;
184
+ delivered.add(key);
185
+ undelivered.delete(key);
186
+ if ("hash" in settled)
187
+ told.add(settled.hash.toLowerCase());
188
+ // A send under way never saw it: it blocks that send, acknowledged or not.
189
+ if (settled.result === "success")
190
+ for (const during of sending)
191
+ during.add(key);
192
+ options.onSettled?.(settled, receipt);
193
+ present();
194
+ // Told: the hold marks it acknowledged, so no later visit asks again.
195
+ if ("hash" in settled &&
196
+ settled.result === "success" &&
197
+ !settled.acknowledged)
198
+ void handle.acknowledge(settled).catch(() => null);
199
+ };
200
+ if (!options.onSettled || !("hash" in settled)) {
201
+ done(null);
202
+ return;
203
+ }
204
+ void client.getTransactionReceipt({ hash: settled.hash }).then((receipt) => done(receipt), () => done(null));
205
+ }
206
+ /** The phase and line a held state shows, monotonic once confirming. */
207
+ function heldView(next) {
208
+ // A held state's reservation is its record's id.
209
+ const reservation = next.record.id;
210
+ const record = next.record;
211
+ if (next.status === "ran-executed" ||
212
+ (record.safe &&
213
+ (record.executed ||
214
+ record.executionHash !== undefined ||
215
+ (record.candidates?.length ?? 0) > 0)))
216
+ confirmed.add(reservation);
217
+ const base = {
218
+ state: next,
219
+ exit: next.exit,
220
+ warning: "warning" in next ? next.warning : undefined,
221
+ notice: next.notice,
222
+ settled: undefined,
223
+ releasedBy: undefined,
224
+ };
225
+ if (next.exit)
226
+ return { ...base, phase: "held", line: next.line };
227
+ if (next.status === "ran-executed")
228
+ return {
229
+ ...base,
230
+ phase: "confirming",
231
+ line: HELD_CONFIRMING_LINE,
232
+ };
233
+ if (next.status === "pending-known-hash") {
234
+ if (record.safe)
235
+ return confirmed.has(reservation)
236
+ ? {
237
+ ...base,
238
+ phase: "confirming",
239
+ line: HELD_CONFIRMING_LINE,
240
+ }
241
+ : {
242
+ ...base,
243
+ phase: "awaiting",
244
+ line: SAFE_PROPOSAL_AWAITING,
245
+ };
246
+ // A direct write: confirming, until the wallet has held it a while.
247
+ const since = Number(record.submittedAt ?? record.firstSeenAt);
248
+ const line = next.line === WRITE_HOLD_PENDING_LINE &&
249
+ !(Date.now() - since >= CONFIRMING_MS)
250
+ ? HELD_CONFIRMING_LINE
251
+ : next.line;
252
+ return { ...base, phase: "confirming", line };
253
+ }
254
+ return { ...base, phase: "held", line: next.line };
255
+ }
256
+ /** Take a hold state, through the one guard every source goes through. */
257
+ function apply(next) {
258
+ if (!next || hidesShownExit(view.state, next))
259
+ return;
260
+ if (next.status === "clear") {
261
+ const reservation = next.reservation;
262
+ const mine = wasHeld && (!reservation || reservation === observed);
263
+ stopFollowing();
264
+ if (next.settled && mine) {
265
+ seen.delete(observed);
266
+ deliver(next.settled, observed);
267
+ set({
268
+ phase: "settled",
269
+ state: next,
270
+ line: settledLine(next.settled),
271
+ warning: undefined,
272
+ notice: undefined,
273
+ exit: false,
274
+ settled: next.settled,
275
+ releasedBy: undefined,
276
+ });
277
+ }
278
+ else if (mine) {
279
+ const by = exitedHere === observed ? "user" : "other-tab";
280
+ set({
281
+ phase: "released",
282
+ state: next,
283
+ line: by === "user" ? HELD_RELEASED_LINE : HELD_RELEASED_ELSEWHERE_LINE,
284
+ warning: undefined,
285
+ notice: undefined,
286
+ exit: false,
287
+ settled: undefined,
288
+ releasedBy: by,
289
+ });
290
+ options.onReleased?.(by);
291
+ }
292
+ else if (view.phase === "settled" || view.phase === "released") {
293
+ // Already shown: kept, unless the gate below has another success.
294
+ }
295
+ else
296
+ set({
297
+ phase: "clear",
298
+ state: next,
299
+ line: null,
300
+ warning: undefined,
301
+ notice: undefined,
302
+ exit: false,
303
+ settled: next.settled,
304
+ });
305
+ if (mine)
306
+ seen.delete(observed);
307
+ wasHeld = false;
308
+ observed = undefined;
309
+ exitedHere = undefined;
310
+ collect();
311
+ present();
312
+ return;
313
+ }
314
+ const reservation = next.record.id;
315
+ if (observed !== reservation) {
316
+ observed = reservation;
317
+ exitedHere = undefined;
318
+ }
319
+ wasHeld = true;
320
+ seen.add(reservation);
321
+ set(heldView(next));
322
+ if (next.record.hash)
323
+ follow(reservation);
324
+ collect();
325
+ }
326
+ /** Deliver the settlement of every other reservation this view saw held. */
327
+ function collect() {
328
+ for (const reservation of [...seen]) {
329
+ if (reservation === observed)
330
+ continue;
331
+ const settled = handle.settlementOf(reservation);
332
+ if (!settled)
333
+ continue;
334
+ seen.delete(reservation);
335
+ deliver(settled, reservation);
336
+ }
337
+ }
338
+ /**
339
+ * The send gate, from current evidence alone: any unacknowledged success
340
+ * of the intent or an eligible legacy hold, but those `exempt`, or any
341
+ * success delivered `during` the send. It holds whatever is shown.
342
+ */
343
+ function unacknowledged(exempt, during) {
344
+ if (during.size || gate(exempt))
345
+ throw new Error(HELD_AWAY_SUCCESS_LINE);
346
+ }
347
+ /** Successes this view told the app of: their acknowledgement is under way. */
348
+ const told = new Set();
349
+ /** Per send under way, the successes delivered since it started. */
350
+ const sending = new Set();
351
+ /** The gate's success, but for one this view already told the app of. */
352
+ function gate(exempt = told) {
353
+ return handle.unacknowledgedSuccess((hash) => exempt.has(hash.toLowerCase()));
354
+ }
355
+ /**
356
+ * Show the gate's success as `succeeded` ("Send it again") once nothing is
357
+ * left to deliver, unless a hold is shown.
358
+ */
359
+ function present() {
360
+ const success = gate();
361
+ if (!success || undelivered.size)
362
+ return;
363
+ if (view.phase === "awaiting" ||
364
+ view.phase === "confirming" ||
365
+ view.phase === "held")
366
+ return;
367
+ // A success this view saw settle was told, so the gate never names it.
368
+ set({
369
+ phase: "succeeded",
370
+ state: view.state,
371
+ line: HELD_AWAY_SUCCESS_LINE,
372
+ warning: undefined,
373
+ notice: undefined,
374
+ exit: false,
375
+ settled: { result: "success", hash: success.hash },
376
+ releasedBy: undefined,
377
+ });
378
+ }
379
+ /** The gated answer, now. */
380
+ async function check() {
381
+ const at = epoch;
382
+ const next = await handle.state(client).catch(() => null);
383
+ if (at === epoch)
384
+ apply(next);
385
+ return view;
386
+ }
387
+ /** Move a previous deploy's record into the hold, once, before any send. */
388
+ function adopt() {
389
+ const provider = options.adopt;
390
+ if (!provider)
391
+ return Promise.resolve(true);
392
+ adoption ??= (async () => {
393
+ set({ adopting: true });
394
+ // Each answer is this lifecycle's only: a stopped view's late read
395
+ // applies nothing and acknowledges nothing.
396
+ const at = epoch;
397
+ const current = () => {
398
+ if (at !== epoch)
399
+ throw new Error("Stopped while adopting.");
400
+ };
401
+ const snapshot = await handle.state(client);
402
+ current();
403
+ apply(snapshot);
404
+ if (snapshot.status === "clear") {
405
+ const evidence = await provider();
406
+ current();
407
+ if (evidence) {
408
+ const state = await handle.adopt(snapshot, evidence, client);
409
+ current();
410
+ // Unread (the chain, or a lock another writer held): no send until it is.
411
+ if (state.declined === "unreadable")
412
+ throw new Error("The saved write couldn't be checked.");
413
+ apply(state);
414
+ if (state.status !== "clear" || state.settled)
415
+ options.onAdopted?.(state);
416
+ }
417
+ }
418
+ set({ adopting: false });
419
+ return true;
420
+ })().catch(() => {
421
+ // Unchecked: asked again on the next send.
422
+ adoption = undefined;
423
+ set({ adopting: false });
424
+ return false;
425
+ });
426
+ return adoption;
427
+ }
428
+ return {
429
+ get: () => view,
430
+ subscribe(listener) {
431
+ listeners.add(listener);
432
+ return () => void listeners.delete(listener);
433
+ },
434
+ check,
435
+ /**
436
+ * Start watching: the hold's events, a checked read now (after adoption),
437
+ * on focus and every poll while held. Returns the stop.
438
+ */
439
+ start() {
440
+ running = true;
441
+ live = true;
442
+ epoch += 1;
443
+ // Every settlement a stopped lifecycle never told is told now.
444
+ for (const [key, settled] of [...undelivered])
445
+ deliver(settled, key);
446
+ const unsubscribe = handle.subscribe(apply);
447
+ // An adoption a stopped lifecycle left unfinished runs again here.
448
+ void adopt()
449
+ .then((done) => (done || !running ? done : adopt()))
450
+ .then(() => (running ? check() : view));
451
+ const timer = setInterval(() => {
452
+ const held = view.phase === "awaiting" ||
453
+ view.phase === "confirming" ||
454
+ view.phase === "held";
455
+ const hidden = globalThis.document?.visibilityState === "hidden";
456
+ if (held && !hidden)
457
+ void check();
458
+ }, pollOf(options.pollMs));
459
+ const onFocus = () => void check();
460
+ globalThis.addEventListener?.("focus", onFocus);
461
+ return () => {
462
+ running = false;
463
+ live = false;
464
+ epoch += 1;
465
+ unsubscribe();
466
+ clearInterval(timer);
467
+ globalThis.removeEventListener?.("focus", onFocus);
468
+ stopFollowing();
469
+ };
470
+ },
471
+ /**
472
+ * The user checked their wallet: the exit the shown state offers, asked
473
+ * of the chain once more. True when released: the app reopens its review.
474
+ */
475
+ async exit() {
476
+ const shown = view.state;
477
+ if (!shown || shown.status === "clear" || !view.exit)
478
+ return false;
479
+ exitedHere = shown.record.id;
480
+ const ended = await handle.exit(shown, { checkedWallet: true }, client);
481
+ if (!ended.released)
482
+ exitedHere = undefined;
483
+ apply(ended.state);
484
+ return ended.released;
485
+ },
486
+ /**
487
+ * Send under the hold, once any adoption is done. A held write refuses
488
+ * with the hold's checked state shown.
489
+ */
490
+ async send(run) {
491
+ // Only a success told before this send is exempt, taken before any
492
+ // yield; one delivered after it starts was never seen, so it blocks.
493
+ const exempt = new Set(told);
494
+ const during = new Set();
495
+ sending.add(during);
496
+ const guard = () => unacknowledged(exempt, during);
497
+ try {
498
+ if (!(await adopt()))
499
+ throw new Error("Saved transactions are still being checked. Try again in a moment.");
500
+ guard();
501
+ // The send's own check may find one too: it says so before the wallet.
502
+ const unsubscribe = handle.subscribe(apply);
503
+ try {
504
+ const hash = await handle.send(client, async (gate) => {
505
+ guard();
506
+ return run({
507
+ ...gate,
508
+ // Asked again at the reservation itself, after any lock retries.
509
+ async beforeSend(actualCall) {
510
+ guard();
511
+ await gate.beforeSend(actualCall);
512
+ try {
513
+ guard();
514
+ }
515
+ catch (error) {
516
+ gate.onRejected();
517
+ throw error;
518
+ }
519
+ },
520
+ });
521
+ });
522
+ unsubscribe();
523
+ apply(handle.peek());
524
+ return hash;
525
+ }
526
+ catch (error) {
527
+ unsubscribe();
528
+ // Its own evidence, checked or not: a contended refusal hides no exit.
529
+ if (error instanceof WriteHeldError)
530
+ apply(error.state);
531
+ else if (view.phase !== "succeeded")
532
+ await check();
533
+ throw error;
534
+ }
535
+ }
536
+ finally {
537
+ sending.delete(during);
538
+ }
539
+ },
540
+ /**
541
+ * The user saw a success that settled while away and chose to send again:
542
+ * the hold marks it acknowledged, for every reader, and sends are allowed.
543
+ */
544
+ async acknowledge() {
545
+ const success = gate();
546
+ if (view.phase !== "succeeded" || !success)
547
+ return;
548
+ const at = epoch;
549
+ await handle.acknowledge({ result: success.result, hash: success.hash });
550
+ // Only that success's presentation ends: never a newer hold or its exit.
551
+ if (at === epoch &&
552
+ view.phase === "succeeded" &&
553
+ view.settled !== undefined &&
554
+ "hash" in view.settled &&
555
+ view.settled.hash === success.hash)
556
+ set({ phase: "clear", line: null, settled: undefined, state: null });
557
+ // Another success still unacknowledged is shown next.
558
+ present();
559
+ },
560
+ };
561
+ }
562
+ //# sourceMappingURL=heldWrite.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"heldWrite.js","sourceRoot":"","sources":["../../../src/review/heldWrite.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EACd,sBAAsB,EACtB,wBAAwB,GACzB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,sBAAsB,EACtB,oBAAoB,EACpB,iBAAiB,EACjB,4BAA4B,EAC5B,kBAAkB,EAClB,iBAAiB,EACjB,uBAAuB,EACvB,wBAAwB,GACzB,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,cAAc,GAMf,MAAM,gBAAgB,CAAC;AAmDxB,0FAA0F;AAC1F,MAAM,CAAC,MAAM,YAAY,GAAG,MAAM,CAAC;AACnC,MAAM,WAAW,GAAG,MAAM,CAAC;AAC3B,MAAM,WAAW,GAAG,MAAM,CAAC;AAC3B,kFAAkF;AAClF,MAAM,OAAO,GAAG,KAAK,CAAC;AACtB,MAAM,UAAU,GAAG,EAAE,CAAC;AACtB,+FAA+F;AAC/F,MAAM,aAAa,GAAG,OAAO,CAAC;AAE9B,MAAM,MAAM,GAAG,CAAC,EAAW,EAAE,EAAE,CAC7B,IAAI,CAAC,GAAG,CAAC,WAAW,EAAE,IAAI,CAAC,GAAG,CAAC,WAAW,EAAE,EAAE,IAAI,YAAY,CAAC,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K,EAAE,IAAI,EAAE,CAAC,CAAC;YACvE,sDAAsD;YACtD,OAAO,EAAE,CAAC;QACZ,CAAC;KACF,CAAC;AACJ,CAAC"}
@@ -9,4 +9,6 @@ export * from "./writeRecovery.js";
9
9
  export * from "./writeHold.js";
10
10
  export * from "./writeIntent.js";
11
11
  export * from "./intents.js";
12
+ export * from "./heldWrite.js";
13
+ export * from "./savedAttempt.js";
12
14
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/review/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/review/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC"}
@@ -9,4 +9,6 @@ export * from "./writeRecovery.js";
9
9
  export * from "./writeHold.js";
10
10
  export * from "./writeIntent.js";
11
11
  export * from "./intents.js";
12
+ export * from "./heldWrite.js";
13
+ export * from "./savedAttempt.js";
12
14
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/review/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/review/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC"}
@@ -61,5 +61,35 @@ export declare const WRITE_HOLD_SAFE_UNPROVEN_LINE = "This Safe transaction coul
61
61
  export declare const WRITE_HOLD_MINED_LINE = "Your transaction is onchain, but its result can't be read yet.";
62
62
  /** A send whose review went stale because another window's attempt of the same write ended meanwhile. */
63
63
  export declare const WRITE_HOLD_STALE_REVIEW_LINE = "This was just sent from another window. Review it again to send another.";
64
+ /** The one line while a sent write, direct or through a Safe, is being confirmed. */
65
+ export declare const HELD_CONFIRMING_LINE = "Confirming your transaction.";
66
+ /** A held write the user released with their exit: they can send it again. */
67
+ export declare const HELD_RELEASED_LINE = "Released. You can send it again.";
68
+ /** A held write another window released: neutral, never a result. */
69
+ export declare const HELD_RELEASED_ELSEWHERE_LINE = "This was released in another window.";
70
+ /** The exit button where the review follows on its own. */
71
+ export declare const HELD_EXIT_LABEL = "I checked my wallet";
72
+ /** The exit button where only the hold is released (an app-wide notice). */
73
+ export declare const HELD_RELEASE_LABEL = "I checked my wallet. Release it";
74
+ /** A held write settled with success on authenticated evidence. */
75
+ export declare const HELD_SUCCESS_LINE = "Your transaction went through.";
76
+ /** A held Safe proposal proven expired before it ran. */
77
+ export declare const HELD_EXPIRED_LINE = "Your Safe proposal expired before it ran.";
78
+ /** A success the hold settled while the user was away: shown until they say to send again. */
79
+ export declare const HELD_AWAY_SUCCESS_LINE = "This went through while you were away.";
80
+ /** The one action on a success settled while away: acknowledge it, then send. */
81
+ export declare const HELD_SEND_AGAIN_LABEL = "Send it again";
82
+ /** A saved attempt that can't be shown here: absence of evidence is never permission to send. */
83
+ export declare const SAVED_ATTEMPT_CHECK_LINE = "This transaction may already be in your wallet, and it cannot be confirmed from here.";
84
+ /** The warning under it. */
85
+ export declare const SAVED_ATTEMPT_CHECK_WARNING = "Check your wallet and the explorer first. Continuing can send it twice.";
86
+ /** The one check action's label: "I checked it. Review it again." or the flow's next step ("Create again"). */
87
+ export declare function checkedItLabel(next?: string): string;
88
+ /** Under a retirement that lasts in this tab alone (`durable: false`). */
89
+ export declare const SAVED_ATTEMPT_TAB_ONLY_LINE = "This applies to this tab only.";
90
+ /** When the browser has storage but can't read it: the warned exit's line. */
91
+ export declare const SAVED_ATTEMPT_UNREADABLE_LINE = "This browser can't read its saved transactions. Check your wallet before sending again.";
92
+ /** The warned exit's label, offered only after a check action found storage unreadable. */
93
+ export declare const SAVED_ATTEMPT_CONTINUE_ANYWAY_LABEL = "I checked my wallet. Continue anyway";
64
94
  export {};
65
95
  //# sourceMappingURL=messages.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../../src/review/messages.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,4FAA4F;AAC5F,KAAK,aAAa,GAA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