@unicitylabs/sphere-sdk 0.14.0-dev.5 → 0.14.0-dev.6
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/connect/index.cjs +1 -1
- package/dist/connect/index.cjs.map +1 -1
- package/dist/connect/index.js +1 -1
- package/dist/connect/index.js.map +1 -1
- package/dist/core/index.cjs +303 -35
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +21 -0
- package/dist/core/index.d.ts +21 -0
- package/dist/core/index.js +303 -35
- package/dist/core/index.js.map +1 -1
- package/dist/impl/browser/connect/index.cjs +1 -1
- package/dist/impl/browser/connect/index.cjs.map +1 -1
- package/dist/impl/browser/connect/index.js +1 -1
- package/dist/impl/browser/connect/index.js.map +1 -1
- package/dist/impl/wallet-api-v2/index.cjs +7 -0
- package/dist/impl/wallet-api-v2/index.cjs.map +1 -1
- package/dist/impl/wallet-api-v2/index.d.cts +3 -0
- package/dist/impl/wallet-api-v2/index.d.ts +3 -0
- package/dist/impl/wallet-api-v2/index.js +7 -0
- package/dist/impl/wallet-api-v2/index.js.map +1 -1
- package/dist/index.cjs +303 -35
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +21 -0
- package/dist/index.d.ts +21 -0
- package/dist/index.js +303 -35
- package/dist/index.js.map +1 -1
- package/dist/modules/payments-v2/index.cjs +300 -35
- package/dist/modules/payments-v2/index.cjs.map +1 -1
- package/dist/modules/payments-v2/index.d.cts +45 -2
- package/dist/modules/payments-v2/index.d.ts +45 -2
- package/dist/modules/payments-v2/index.js +298 -35
- package/dist/modules/payments-v2/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -2767,6 +2767,7 @@ var WalletApiSession = class {
|
|
|
2767
2767
|
reseedChain = Promise.resolve();
|
|
2768
2768
|
reseedsPending = 0;
|
|
2769
2769
|
handlers = /* @__PURE__ */ new Map();
|
|
2770
|
+
statusHandlers = /* @__PURE__ */ new Set();
|
|
2770
2771
|
socket = null;
|
|
2771
2772
|
started = false;
|
|
2772
2773
|
stopped = false;
|
|
@@ -2917,10 +2918,16 @@ var WalletApiSession = class {
|
|
|
2917
2918
|
status() {
|
|
2918
2919
|
return this.lastStatus ?? "offline";
|
|
2919
2920
|
}
|
|
2921
|
+
/** Transition feed off the existing emitStatus point (FacadeSession.subscribeStatus). */
|
|
2922
|
+
subscribeStatus(handler) {
|
|
2923
|
+
this.statusHandlers.add(handler);
|
|
2924
|
+
return () => this.statusHandlers.delete(handler);
|
|
2925
|
+
}
|
|
2920
2926
|
emitStatus(status) {
|
|
2921
2927
|
if (this.stopped || this.lastStatus === status) return;
|
|
2922
2928
|
this.lastStatus = status;
|
|
2923
2929
|
this.deps.emitStatus(status);
|
|
2930
|
+
for (const handler of this.statusHandlers) handler(status);
|
|
2924
2931
|
}
|
|
2925
2932
|
async connect() {
|
|
2926
2933
|
if (this.stopped) return;
|