@bounded-sh/client 0.0.102 → 0.0.104
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/auth/providers/offchain-auth-provider.d.ts +7 -9
- package/dist/{email-auth-provider-DCZ93FYg.js → email-auth-provider-CGhDN-8d.js} +2 -2
- package/dist/{email-auth-provider-DCZ93FYg.js.map → email-auth-provider-CGhDN-8d.js.map} +1 -1
- package/dist/{email-auth-provider-Ct3YA68i.mjs → email-auth-provider-CdBqgLWw.mjs} +2 -2
- package/dist/{email-auth-provider-Ct3YA68i.mjs.map → email-auth-provider-CdBqgLWw.mjs.map} +1 -1
- package/dist/{email-auth-provider-BJXeBUwp.mjs → email-auth-provider-DA2dPFXt.mjs} +2 -2
- package/dist/{email-auth-provider-BJXeBUwp.mjs.map → email-auth-provider-DA2dPFXt.mjs.map} +1 -1
- package/dist/{email-auth-provider-Cr3I4Po5.js → email-auth-provider-aMa0EDuc.js} +2 -2
- package/dist/{email-auth-provider-Cr3I4Po5.js.map → email-auth-provider-aMa0EDuc.js.map} +1 -1
- package/dist/{guest-auth-provider--Sqlucfr.js → guest-auth-provider-BT9JPOpp.js} +2 -2
- package/dist/{guest-auth-provider--Sqlucfr.js.map → guest-auth-provider-BT9JPOpp.js.map} +1 -1
- package/dist/{guest-auth-provider-CUo6sgop.mjs → guest-auth-provider-BiWPelOD.mjs} +2 -2
- package/dist/{guest-auth-provider-CUo6sgop.mjs.map → guest-auth-provider-BiWPelOD.mjs.map} +1 -1
- package/dist/{guest-auth-provider-CPj-w7_R.js → guest-auth-provider-Ca50pehK.js} +2 -2
- package/dist/{guest-auth-provider-CPj-w7_R.js.map → guest-auth-provider-Ca50pehK.js.map} +1 -1
- package/dist/{guest-auth-provider-DMtDTZeA.mjs → guest-auth-provider-pDVr5YRg.mjs} +2 -2
- package/dist/{guest-auth-provider-DMtDTZeA.mjs.map → guest-auth-provider-pDVr5YRg.mjs.map} +1 -1
- package/dist/{index-CaZx7sd8.mjs → index-DKkAO0g-.mjs} +16 -358
- package/dist/index-DKkAO0g-.mjs.map +1 -0
- package/dist/{index-Pyb2SLgv.js → index-DTBxbfUl.js} +16 -358
- package/dist/index-DTBxbfUl.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{index.native-3T0IcOed.mjs → index.native-Bl2W-Wsi.mjs} +15 -357
- package/dist/index.native-Bl2W-Wsi.mjs.map +1 -0
- package/dist/{index.native-PGrxu7RO.js → index.native-CNW3iAoP.js} +15 -357
- package/dist/index.native-CNW3iAoP.js.map +1 -0
- package/dist/index.native.js +1 -1
- package/dist/index.native.mjs +1 -1
- package/dist/{injected-evm-wallet-provider-U0XJu5HM.js → injected-evm-wallet-provider-B8PWHQdb.js} +2 -2
- package/dist/{injected-evm-wallet-provider-U0XJu5HM.js.map → injected-evm-wallet-provider-B8PWHQdb.js.map} +1 -1
- package/dist/{injected-evm-wallet-provider-B3Mtkdnu.mjs → injected-evm-wallet-provider-BPkcFSQX.mjs} +2 -2
- package/dist/{injected-evm-wallet-provider-B3Mtkdnu.mjs.map → injected-evm-wallet-provider-BPkcFSQX.mjs.map} +1 -1
- package/dist/{injected-evm-wallet-provider-BNu6Z-iN.js → injected-evm-wallet-provider-Cym2uENX.js} +2 -2
- package/dist/{injected-evm-wallet-provider-BNu6Z-iN.js.map → injected-evm-wallet-provider-Cym2uENX.js.map} +1 -1
- package/dist/{injected-evm-wallet-provider-C8rBnyO1.mjs → injected-evm-wallet-provider-HbgMQAbf.mjs} +2 -2
- package/dist/{injected-evm-wallet-provider-C8rBnyO1.mjs.map → injected-evm-wallet-provider-HbgMQAbf.mjs.map} +1 -1
- package/dist/{injected-wallet-provider-DR8xVudg.mjs → injected-wallet-provider-BGeNaoEY.mjs} +2 -2
- package/dist/{injected-wallet-provider-DR8xVudg.mjs.map → injected-wallet-provider-BGeNaoEY.mjs.map} +1 -1
- package/dist/{injected-wallet-provider-BnmYbm79.mjs → injected-wallet-provider-D39pzPTV.mjs} +2 -2
- package/dist/{injected-wallet-provider-BnmYbm79.mjs.map → injected-wallet-provider-D39pzPTV.mjs.map} +1 -1
- package/dist/{injected-wallet-provider-29eTkM-A.js → injected-wallet-provider-FY9JLEPR.js} +2 -2
- package/dist/{injected-wallet-provider-29eTkM-A.js.map → injected-wallet-provider-FY9JLEPR.js.map} +1 -1
- package/dist/{injected-wallet-provider-Cv9RELO6.js → injected-wallet-provider-oWtACL_7.js} +2 -2
- package/dist/{injected-wallet-provider-Cv9RELO6.js.map → injected-wallet-provider-oWtACL_7.js.map} +1 -1
- package/package.json +2 -2
- package/dist/index-CaZx7sd8.mjs.map +0 -1
- package/dist/index-Pyb2SLgv.js.map +0 -1
- package/dist/index.native-3T0IcOed.mjs.map +0 -1
- package/dist/index.native-PGrxu7RO.js.map +0 -1
|
@@ -213,10 +213,14 @@ function getPlatform() {
|
|
|
213
213
|
}
|
|
214
214
|
|
|
215
215
|
/**
|
|
216
|
-
* OffchainAuthProvider wraps a real auth provider (
|
|
216
|
+
* OffchainAuthProvider wraps a real auth provider (Turnkey, Phantom, ...) for the
|
|
217
|
+
* poofnet environment.
|
|
217
218
|
*
|
|
218
|
-
*
|
|
219
|
-
*
|
|
219
|
+
* Poofnet has no chain, but its onchain writes are still signed: the worker
|
|
220
|
+
* issues an unsendable approval message and verifies the wallet's signature
|
|
221
|
+
* before committing. So `signTransaction` and `signMessage` go straight to the
|
|
222
|
+
* wrapped wallet, whose own prompt is the only one the user sees. Only a raw
|
|
223
|
+
* submit - which needs a real cluster - is refused here.
|
|
220
224
|
*/
|
|
221
225
|
class OffchainAuthProvider {
|
|
222
226
|
constructor(wrappedProvider, config = {}) {
|
|
@@ -251,10 +255,7 @@ class OffchainAuthProvider {
|
|
|
251
255
|
return null;
|
|
252
256
|
}
|
|
253
257
|
async signTransaction(tx) {
|
|
254
|
-
|
|
255
|
-
await this.showUnsupportedTransactionModal();
|
|
256
|
-
}
|
|
257
|
-
throw new Error('Poofnet does not support real Solana transactions. Deploy your project to mainnet to use this feature.');
|
|
258
|
+
return this.wrappedProvider.signTransaction(tx);
|
|
258
259
|
}
|
|
259
260
|
/**
|
|
260
261
|
* Sign and submit transaction - not supported in poofnet environment.
|
|
@@ -279,21 +280,11 @@ class OffchainAuthProvider {
|
|
|
279
280
|
}
|
|
280
281
|
await this.wrappedProvider.exportWallet(address);
|
|
281
282
|
}
|
|
282
|
-
// ============ signMessage delegates to wrapped provider ============
|
|
283
283
|
async signMessage(message) {
|
|
284
284
|
var _a, _b, _c, _d, _e, _f;
|
|
285
285
|
(_b = (_a = this.config).onSigningStart) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
286
286
|
try {
|
|
287
|
-
// On RN (no DOM), auto-confirm — there's no modal to show.
|
|
288
|
-
// On web, show the confirmation modal.
|
|
289
|
-
if (getPlatform().hasDOM) {
|
|
290
|
-
const confirmed = await this.showTransactionModal(message);
|
|
291
|
-
if (!confirmed) {
|
|
292
|
-
throw new Error("Transaction rejected by user");
|
|
293
|
-
}
|
|
294
|
-
}
|
|
295
287
|
const signature = await this.wrappedProvider.signMessage(message);
|
|
296
|
-
// Callback: signing complete
|
|
297
288
|
(_d = (_c = this.config).onSigningComplete) === null || _d === void 0 ? void 0 : _d.call(_c, signature);
|
|
298
289
|
return signature;
|
|
299
290
|
}
|
|
@@ -384,99 +375,6 @@ class OffchainAuthProvider {
|
|
|
384
375
|
document.addEventListener("keydown", escHandler);
|
|
385
376
|
});
|
|
386
377
|
}
|
|
387
|
-
async showTransactionModal(message) {
|
|
388
|
-
return new Promise((resolve) => {
|
|
389
|
-
// Parse the transaction message for display
|
|
390
|
-
let parsed = {};
|
|
391
|
-
try {
|
|
392
|
-
parsed = JSON.parse(message);
|
|
393
|
-
}
|
|
394
|
-
catch (_a) {
|
|
395
|
-
// If not JSON, just show raw message
|
|
396
|
-
}
|
|
397
|
-
// Create modal container. Captured in this closure so every teardown
|
|
398
|
-
// path acts on exactly this prompt, never on a newer one that may have
|
|
399
|
-
// replaced a shared field.
|
|
400
|
-
const container = document.createElement("div");
|
|
401
|
-
container.id = "poofnet-tx-modal";
|
|
402
|
-
container.appendChild(this.buildTransactionModalContent(parsed, message));
|
|
403
|
-
document.body.appendChild(container);
|
|
404
|
-
// Add styles
|
|
405
|
-
const style = document.createElement("style");
|
|
406
|
-
style.textContent = this.getModalStyles();
|
|
407
|
-
container.appendChild(style);
|
|
408
|
-
// Mark all OTHER body children as inert to disable focus traps from
|
|
409
|
-
// other modals, recording only the ones this modal changed (skipping
|
|
410
|
-
// any already-inert) so cleanup restores exactly what we set and never
|
|
411
|
-
// re-enables app-owned inert regions.
|
|
412
|
-
const selfInerted = [];
|
|
413
|
-
document.body.childNodes.forEach((child) => {
|
|
414
|
-
if (child !== container &&
|
|
415
|
-
child instanceof HTMLElement &&
|
|
416
|
-
!child.hasAttribute("inert")) {
|
|
417
|
-
child.setAttribute("inert", "");
|
|
418
|
-
selfInerted.push(child);
|
|
419
|
-
}
|
|
420
|
-
});
|
|
421
|
-
// Animate in
|
|
422
|
-
requestAnimationFrame(() => {
|
|
423
|
-
const overlay = container.querySelector(".poofnet-modal-overlay");
|
|
424
|
-
const content = container.querySelector(".poofnet-modal-content");
|
|
425
|
-
if (overlay)
|
|
426
|
-
overlay.style.opacity = "1";
|
|
427
|
-
if (content) {
|
|
428
|
-
content.style.opacity = "1";
|
|
429
|
-
content.style.transform = "translateY(0)";
|
|
430
|
-
}
|
|
431
|
-
});
|
|
432
|
-
// Single idempotent teardown for every settlement path: removes the key
|
|
433
|
-
// handler, restores only self-added inert, and removes exactly this
|
|
434
|
-
// captured container after the exit animation.
|
|
435
|
-
let settled = false;
|
|
436
|
-
const escHandler = (e) => {
|
|
437
|
-
if (e.key === "Escape")
|
|
438
|
-
settle(false);
|
|
439
|
-
};
|
|
440
|
-
const cleanup = () => {
|
|
441
|
-
if (settled)
|
|
442
|
-
return;
|
|
443
|
-
settled = true;
|
|
444
|
-
document.removeEventListener("keydown", escHandler);
|
|
445
|
-
for (const el of selfInerted)
|
|
446
|
-
el.removeAttribute("inert");
|
|
447
|
-
const overlay = container.querySelector(".poofnet-modal-overlay");
|
|
448
|
-
const content = container.querySelector(".poofnet-modal-content");
|
|
449
|
-
if (overlay)
|
|
450
|
-
overlay.style.opacity = "0";
|
|
451
|
-
if (content) {
|
|
452
|
-
content.style.opacity = "0";
|
|
453
|
-
content.style.transform = "translateY(20px)";
|
|
454
|
-
}
|
|
455
|
-
setTimeout(() => container.remove(), 200);
|
|
456
|
-
};
|
|
457
|
-
const settle = (confirmed) => {
|
|
458
|
-
cleanup();
|
|
459
|
-
resolve(confirmed);
|
|
460
|
-
};
|
|
461
|
-
// Handle confirm
|
|
462
|
-
const confirmBtn = container.querySelector("#poofnet-confirm-btn");
|
|
463
|
-
confirmBtn === null || confirmBtn === void 0 ? void 0 : confirmBtn.addEventListener("click", () => settle(true));
|
|
464
|
-
// Handle cancel
|
|
465
|
-
const cancelBtn = container.querySelector("#poofnet-cancel-btn");
|
|
466
|
-
cancelBtn === null || cancelBtn === void 0 ? void 0 : cancelBtn.addEventListener("click", () => settle(false));
|
|
467
|
-
// Handle close button
|
|
468
|
-
const closeBtn = container.querySelector("#poofnet-close-btn");
|
|
469
|
-
closeBtn === null || closeBtn === void 0 ? void 0 : closeBtn.addEventListener("click", () => settle(false));
|
|
470
|
-
// Handle overlay click
|
|
471
|
-
const overlay = container.querySelector(".poofnet-modal-overlay");
|
|
472
|
-
overlay === null || overlay === void 0 ? void 0 : overlay.addEventListener("click", (e) => {
|
|
473
|
-
if (e.target === overlay)
|
|
474
|
-
settle(false);
|
|
475
|
-
});
|
|
476
|
-
// Handle escape key
|
|
477
|
-
document.addEventListener("keydown", escHandler);
|
|
478
|
-
});
|
|
479
|
-
}
|
|
480
378
|
createElement(tag, className, text) {
|
|
481
379
|
const el = document.createElement(tag);
|
|
482
380
|
if (className)
|
|
@@ -531,113 +429,6 @@ class OffchainAuthProvider {
|
|
|
531
429
|
footer.appendChild(close);
|
|
532
430
|
return overlay;
|
|
533
431
|
}
|
|
534
|
-
formatPath(path) {
|
|
535
|
-
const parts = path.split("/").filter(Boolean);
|
|
536
|
-
if (parts.length >= 2) {
|
|
537
|
-
return {
|
|
538
|
-
collection: parts[0],
|
|
539
|
-
documentId: parts[parts.length - 1],
|
|
540
|
-
};
|
|
541
|
-
}
|
|
542
|
-
return { collection: parts[0] || path, documentId: null };
|
|
543
|
-
}
|
|
544
|
-
formatFieldValue(value) {
|
|
545
|
-
if (value === null || value === undefined)
|
|
546
|
-
return "null";
|
|
547
|
-
if (typeof value === "string") {
|
|
548
|
-
return value.length > 30
|
|
549
|
-
? `"${value.slice(0, 30)}..."`
|
|
550
|
-
: `"${value}"`;
|
|
551
|
-
}
|
|
552
|
-
if (typeof value === "number" || typeof value === "boolean")
|
|
553
|
-
return String(value);
|
|
554
|
-
if (Array.isArray(value))
|
|
555
|
-
return `[${value.length} items]`;
|
|
556
|
-
if (typeof value === "object")
|
|
557
|
-
return `{${Object.keys(value).length} fields}`;
|
|
558
|
-
return String(value);
|
|
559
|
-
}
|
|
560
|
-
getActionDescription(type, collection, isNew) {
|
|
561
|
-
if (type === "delete")
|
|
562
|
-
return `Delete from ${collection}`;
|
|
563
|
-
return isNew ? `Create in ${collection}` : `Update ${collection}`;
|
|
564
|
-
}
|
|
565
|
-
buildTransactionModalContent(parsed, rawMessage) {
|
|
566
|
-
const instructions = parsed.instructions || [];
|
|
567
|
-
// Group instructions by type for summary
|
|
568
|
-
const sets = instructions.filter((i) => i.type === "set");
|
|
569
|
-
const deletes = instructions.filter((i) => i.type === "delete");
|
|
570
|
-
// Create summary text
|
|
571
|
-
let summaryText = "";
|
|
572
|
-
if (sets.length > 0 && deletes.length > 0) {
|
|
573
|
-
summaryText = `${sets.length} update${sets.length > 1 ? "s" : ""}, ${deletes.length} delete${deletes.length > 1 ? "s" : ""}`;
|
|
574
|
-
}
|
|
575
|
-
else if (sets.length > 0) {
|
|
576
|
-
summaryText = `${sets.length} update${sets.length > 1 ? "s" : ""}`;
|
|
577
|
-
}
|
|
578
|
-
else if (deletes.length > 0) {
|
|
579
|
-
summaryText = `${deletes.length} delete${deletes.length > 1 ? "s" : ""}`;
|
|
580
|
-
}
|
|
581
|
-
const { overlay, body, footer } = this.buildModalShell("🔐", "Confirm Transaction");
|
|
582
|
-
if (instructions.length > 0) {
|
|
583
|
-
if (summaryText) {
|
|
584
|
-
this.appendTextElement(body, "div", "poofnet-summary", summaryText);
|
|
585
|
-
}
|
|
586
|
-
const list = this.createElement("div", "poofnet-instructions-list");
|
|
587
|
-
for (const inst of instructions) {
|
|
588
|
-
list.appendChild(this.buildInstructionElement(inst));
|
|
589
|
-
}
|
|
590
|
-
body.appendChild(list);
|
|
591
|
-
}
|
|
592
|
-
else {
|
|
593
|
-
const section = this.createElement("div", "poofnet-section");
|
|
594
|
-
this.appendTextElement(section, "h3", "poofnet-section-title", "Message");
|
|
595
|
-
const raw = this.createElement("pre", "poofnet-raw-message", rawMessage.slice(0, 200) + (rawMessage.length > 200 ? "..." : ""));
|
|
596
|
-
section.appendChild(raw);
|
|
597
|
-
body.appendChild(section);
|
|
598
|
-
}
|
|
599
|
-
body.appendChild(this.buildInfoBox("This is a simulated transaction. No real fees will be charged."));
|
|
600
|
-
const cancel = this.createElement("button", "poofnet-btn poofnet-btn-cancel", "Cancel");
|
|
601
|
-
cancel.id = "poofnet-cancel-btn";
|
|
602
|
-
cancel.type = "button";
|
|
603
|
-
footer.appendChild(cancel);
|
|
604
|
-
const confirm = this.createElement("button", "poofnet-btn poofnet-btn-confirm", "Confirm");
|
|
605
|
-
confirm.id = "poofnet-confirm-btn";
|
|
606
|
-
confirm.type = "button";
|
|
607
|
-
footer.appendChild(confirm);
|
|
608
|
-
return overlay;
|
|
609
|
-
}
|
|
610
|
-
buildInstructionElement(inst) {
|
|
611
|
-
const { collection, documentId } = this.formatPath(inst.path);
|
|
612
|
-
const isDelete = inst.type === "delete";
|
|
613
|
-
const card = this.createElement("div", `poofnet-instruction ${isDelete ? "poofnet-action-delete" : "poofnet-action-set"}`);
|
|
614
|
-
const header = this.createElement("div", "poofnet-instruction-header");
|
|
615
|
-
this.appendTextElement(header, "span", "poofnet-instruction-icon", isDelete ? "🗑️" : "✏️");
|
|
616
|
-
this.appendTextElement(header, "span", "poofnet-instruction-action", isDelete ? "Delete" : "Save");
|
|
617
|
-
this.appendTextElement(header, "span", "poofnet-instruction-collection", collection);
|
|
618
|
-
card.appendChild(header);
|
|
619
|
-
if (documentId) {
|
|
620
|
-
this.appendTextElement(card, "div", "poofnet-instruction-id", `ID: ${documentId}`);
|
|
621
|
-
}
|
|
622
|
-
if (inst.data && !isDelete) {
|
|
623
|
-
const fieldKeys = Object.keys(inst.data).filter((key) => !key.startsWith("_"));
|
|
624
|
-
const visibleFields = fieldKeys.slice(0, 4);
|
|
625
|
-
if (visibleFields.length > 0) {
|
|
626
|
-
const fields = this.createElement("div", "poofnet-fields");
|
|
627
|
-
for (const key of visibleFields) {
|
|
628
|
-
const row = this.createElement("div", "poofnet-field");
|
|
629
|
-
this.appendTextElement(row, "span", "poofnet-field-key", `${key}:`);
|
|
630
|
-
this.appendTextElement(row, "span", "poofnet-field-value", this.formatFieldValue(inst.data[key]));
|
|
631
|
-
fields.appendChild(row);
|
|
632
|
-
}
|
|
633
|
-
if (fieldKeys.length > 4) {
|
|
634
|
-
this.appendTextElement(fields, "div", "poofnet-field-more", `+${fieldKeys.length - 4} more fields`);
|
|
635
|
-
}
|
|
636
|
-
card.appendChild(fields);
|
|
637
|
-
}
|
|
638
|
-
}
|
|
639
|
-
return card;
|
|
640
|
-
}
|
|
641
432
|
getModalStyles() {
|
|
642
433
|
return `
|
|
643
434
|
/* Ensure inert elements remain visible while being non-interactive */
|
|
@@ -734,130 +525,6 @@ class OffchainAuthProvider {
|
|
|
734
525
|
flex: 1;
|
|
735
526
|
}
|
|
736
527
|
|
|
737
|
-
.poofnet-summary {
|
|
738
|
-
font-size: 13px;
|
|
739
|
-
color: #6b7280;
|
|
740
|
-
margin-bottom: 12px;
|
|
741
|
-
text-align: center;
|
|
742
|
-
}
|
|
743
|
-
|
|
744
|
-
.poofnet-section {
|
|
745
|
-
margin-bottom: 16px;
|
|
746
|
-
}
|
|
747
|
-
|
|
748
|
-
.poofnet-section-title {
|
|
749
|
-
font-size: 12px;
|
|
750
|
-
font-weight: 600;
|
|
751
|
-
color: #666;
|
|
752
|
-
text-transform: uppercase;
|
|
753
|
-
letter-spacing: 0.5px;
|
|
754
|
-
margin: 0 0 8px;
|
|
755
|
-
}
|
|
756
|
-
|
|
757
|
-
.poofnet-instructions-list {
|
|
758
|
-
display: flex;
|
|
759
|
-
flex-direction: column;
|
|
760
|
-
gap: 10px;
|
|
761
|
-
}
|
|
762
|
-
|
|
763
|
-
.poofnet-instruction {
|
|
764
|
-
background: #f9fafb;
|
|
765
|
-
border-radius: 10px;
|
|
766
|
-
padding: 12px;
|
|
767
|
-
border-left: 3px solid #8b5cf6;
|
|
768
|
-
}
|
|
769
|
-
|
|
770
|
-
.poofnet-instruction.poofnet-action-delete {
|
|
771
|
-
border-left-color: #ef4444;
|
|
772
|
-
}
|
|
773
|
-
|
|
774
|
-
.poofnet-instruction-header {
|
|
775
|
-
display: flex;
|
|
776
|
-
align-items: center;
|
|
777
|
-
gap: 8px;
|
|
778
|
-
margin-bottom: 4px;
|
|
779
|
-
}
|
|
780
|
-
|
|
781
|
-
.poofnet-instruction-icon {
|
|
782
|
-
font-size: 16px;
|
|
783
|
-
flex-shrink: 0;
|
|
784
|
-
}
|
|
785
|
-
|
|
786
|
-
.poofnet-instruction-action {
|
|
787
|
-
font-size: 13px;
|
|
788
|
-
font-weight: 600;
|
|
789
|
-
color: #8b5cf6;
|
|
790
|
-
}
|
|
791
|
-
|
|
792
|
-
.poofnet-action-delete .poofnet-instruction-action {
|
|
793
|
-
color: #ef4444;
|
|
794
|
-
}
|
|
795
|
-
|
|
796
|
-
.poofnet-instruction-collection {
|
|
797
|
-
font-size: 13px;
|
|
798
|
-
font-weight: 500;
|
|
799
|
-
color: #374151;
|
|
800
|
-
}
|
|
801
|
-
|
|
802
|
-
.poofnet-instruction-id {
|
|
803
|
-
font-size: 11px;
|
|
804
|
-
color: #9ca3af;
|
|
805
|
-
font-family: monospace;
|
|
806
|
-
margin-bottom: 8px;
|
|
807
|
-
word-break: break-all;
|
|
808
|
-
}
|
|
809
|
-
|
|
810
|
-
.poofnet-fields {
|
|
811
|
-
background: white;
|
|
812
|
-
border-radius: 6px;
|
|
813
|
-
padding: 8px 10px;
|
|
814
|
-
margin-top: 8px;
|
|
815
|
-
}
|
|
816
|
-
|
|
817
|
-
.poofnet-field {
|
|
818
|
-
display: flex;
|
|
819
|
-
gap: 8px;
|
|
820
|
-
padding: 4px 0;
|
|
821
|
-
font-size: 12px;
|
|
822
|
-
border-bottom: 1px solid #f3f4f6;
|
|
823
|
-
}
|
|
824
|
-
|
|
825
|
-
.poofnet-field:last-child {
|
|
826
|
-
border-bottom: none;
|
|
827
|
-
}
|
|
828
|
-
|
|
829
|
-
.poofnet-field-key {
|
|
830
|
-
color: #6b7280;
|
|
831
|
-
font-weight: 500;
|
|
832
|
-
flex-shrink: 0;
|
|
833
|
-
}
|
|
834
|
-
|
|
835
|
-
.poofnet-field-value {
|
|
836
|
-
color: #374151;
|
|
837
|
-
word-break: break-all;
|
|
838
|
-
}
|
|
839
|
-
|
|
840
|
-
.poofnet-field-more {
|
|
841
|
-
font-size: 11px;
|
|
842
|
-
color: #9ca3af;
|
|
843
|
-
padding-top: 4px;
|
|
844
|
-
font-style: italic;
|
|
845
|
-
}
|
|
846
|
-
|
|
847
|
-
.poofnet-raw-message {
|
|
848
|
-
background: #f9fafb;
|
|
849
|
-
border-radius: 8px;
|
|
850
|
-
padding: 12px;
|
|
851
|
-
font-size: 11px;
|
|
852
|
-
font-family: monospace;
|
|
853
|
-
color: #4b5563;
|
|
854
|
-
white-space: pre-wrap;
|
|
855
|
-
word-break: break-all;
|
|
856
|
-
margin: 0;
|
|
857
|
-
max-height: 120px;
|
|
858
|
-
overflow-y: auto;
|
|
859
|
-
}
|
|
860
|
-
|
|
861
528
|
.poofnet-info-box {
|
|
862
529
|
display: flex;
|
|
863
530
|
align-items: center;
|
|
@@ -906,15 +573,6 @@ class OffchainAuthProvider {
|
|
|
906
573
|
.poofnet-btn-cancel:hover {
|
|
907
574
|
background: #e5e7eb;
|
|
908
575
|
}
|
|
909
|
-
|
|
910
|
-
.poofnet-btn-confirm {
|
|
911
|
-
background: #8b5cf6;
|
|
912
|
-
color: white;
|
|
913
|
-
}
|
|
914
|
-
|
|
915
|
-
.poofnet-btn-confirm:hover {
|
|
916
|
-
background: #7c3aed;
|
|
917
|
-
}
|
|
918
576
|
`;
|
|
919
577
|
}
|
|
920
578
|
}
|
|
@@ -6329,7 +5987,7 @@ async function getAuthProvider(config) {
|
|
|
6329
5987
|
// manager as legacy email sessions. Human login should be started
|
|
6330
5988
|
// with loginWithRedirect(); this provider is kept as the restore and
|
|
6331
5989
|
// logout surface for those sessions.
|
|
6332
|
-
currentAuthProvider = new (await Promise.resolve().then(function () { return require('./email-auth-provider-
|
|
5990
|
+
currentAuthProvider = new (await Promise.resolve().then(function () { return require('./email-auth-provider-aMa0EDuc.js'); })).EmailAuthProvider();
|
|
6333
5991
|
break;
|
|
6334
5992
|
case "phantom": {
|
|
6335
5993
|
// First-class Solana WALLET LOGIN (the poof/TaroBase-style "connect
|
|
@@ -6371,7 +6029,7 @@ async function getAuthProvider(config) {
|
|
|
6371
6029
|
// (bounded-login-widget.ts), so registration never counts as
|
|
6372
6030
|
// evidence the user has a wallet.
|
|
6373
6031
|
await ensureSolanaMobileWalletRegistered(config, configuredNetwork);
|
|
6374
|
-
const { InjectedWalletProvider } = await Promise.resolve().then(function () { return require('./injected-wallet-provider-
|
|
6032
|
+
const { InjectedWalletProvider } = await Promise.resolve().then(function () { return require('./injected-wallet-provider-oWtACL_7.js'); });
|
|
6375
6033
|
currentAuthProvider = new InjectedWalletProvider(resolveInjectedWalletConfig(config), rpcUrl, configuredNetwork);
|
|
6376
6034
|
break;
|
|
6377
6035
|
}
|
|
@@ -6384,7 +6042,7 @@ async function getAuthProvider(config) {
|
|
|
6384
6042
|
// Selecting authMethod:'evm-wallet' IS the opt-in — pass evmWalletConfig
|
|
6385
6043
|
// to point at a specific wallet or set chainId/domain.
|
|
6386
6044
|
const evmWalletConfig = ((_a = config.evmWalletConfig) !== null && _a !== void 0 ? _a : {});
|
|
6387
|
-
const { InjectedEvmWalletProvider } = await Promise.resolve().then(function () { return require('./injected-evm-wallet-provider-
|
|
6045
|
+
const { InjectedEvmWalletProvider } = await Promise.resolve().then(function () { return require('./injected-evm-wallet-provider-B8PWHQdb.js'); });
|
|
6388
6046
|
currentAuthProvider = new InjectedEvmWalletProvider(evmWalletConfig);
|
|
6389
6047
|
break;
|
|
6390
6048
|
}
|
|
@@ -6409,7 +6067,7 @@ async function getAuthProvider(config) {
|
|
|
6409
6067
|
break;
|
|
6410
6068
|
case "guest":
|
|
6411
6069
|
// Anonymous auth: a device-local ed25519 keypair signs the challenge.
|
|
6412
|
-
currentAuthProvider = new (await Promise.resolve().then(function () { return require('./guest-auth-provider-
|
|
6070
|
+
currentAuthProvider = new (await Promise.resolve().then(function () { return require('./guest-auth-provider-Ca50pehK.js'); })).GuestAuthProvider();
|
|
6413
6071
|
break;
|
|
6414
6072
|
}
|
|
6415
6073
|
if (!currentAuthProvider) {
|
|
@@ -6471,7 +6129,7 @@ async function signInAnonymously() {
|
|
|
6471
6129
|
// Lazy-load the guest provider so its ed25519/web3 dependencies stay out of
|
|
6472
6130
|
// the main bundle for data-only apps. Specifier is a static string literal
|
|
6473
6131
|
// so bundle-splitting can see it.
|
|
6474
|
-
const provider = new (await Promise.resolve().then(function () { return require('./guest-auth-provider-
|
|
6132
|
+
const provider = new (await Promise.resolve().then(function () { return require('./guest-auth-provider-Ca50pehK.js'); })).GuestAuthProvider();
|
|
6475
6133
|
setAuthLoading(true); // reflect "signing in…" while the guest keypair session is minted
|
|
6476
6134
|
// adoptSessionProvider awaits only getConfig() (already resolved here) and then
|
|
6477
6135
|
// runs every write - provider/method/config/marker/user - in one synchronous
|
|
@@ -6642,7 +6300,7 @@ function ensureSharedWalletLoginReady() {
|
|
|
6642
6300
|
if (!sharedWalletReady) {
|
|
6643
6301
|
sharedWalletReady = (async () => {
|
|
6644
6302
|
await core.getConfig();
|
|
6645
|
-
await Promise.resolve().then(function () { return require('./injected-wallet-provider-
|
|
6303
|
+
await Promise.resolve().then(function () { return require('./injected-wallet-provider-oWtACL_7.js'); });
|
|
6646
6304
|
})().catch((error) => {
|
|
6647
6305
|
sharedWalletReady = null;
|
|
6648
6306
|
throw error;
|
|
@@ -6745,7 +6403,7 @@ async function loginWithWallet(options) {
|
|
|
6745
6403
|
await ensureSharedWalletLoginReady();
|
|
6746
6404
|
else
|
|
6747
6405
|
await ensureWalletLoginReady();
|
|
6748
|
-
const { InjectedWalletProvider } = await Promise.resolve().then(function () { return require('./injected-wallet-provider-
|
|
6406
|
+
const { InjectedWalletProvider } = await Promise.resolve().then(function () { return require('./injected-wallet-provider-oWtACL_7.js'); });
|
|
6749
6407
|
// Keep the RAW wallet provider: the offchain wrapper forwards only a fixed
|
|
6750
6408
|
// set of methods, so cleanup below must speak to the provider that actually
|
|
6751
6409
|
// holds the config rather than to whatever is wrapping it.
|
|
@@ -11119,4 +10777,4 @@ exports.useAuth = useAuth;
|
|
|
11119
10777
|
exports.useBuildRun = useBuildRun;
|
|
11120
10778
|
exports.useQuery = useQuery;
|
|
11121
10779
|
exports.waitForAuthReady = waitForAuthReady;
|
|
11122
|
-
//# sourceMappingURL=index-
|
|
10780
|
+
//# sourceMappingURL=index-DTBxbfUl.js.map
|