@bounded-sh/client 0.0.56 → 0.0.57
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/REACT_NATIVE.md +31 -8
- package/dist/auth/bounded-login-widget.d.ts +25 -0
- package/dist/auth/bounded-widget-modal.d.ts +33 -0
- package/dist/auth/index.d.ts +42 -0
- package/dist/auth/oidc-auth.d.ts +18 -0
- package/dist/auth/providers/wallet-login-finalize.d.ts +17 -0
- package/dist/auth/providers/wallet-standard-discovery.d.ts +23 -0
- package/dist/auth/providers/wallet-standard-tx.d.ts +7 -0
- package/dist/auth/turnkey-auth.d.ts +17 -0
- package/dist/auth/turnkey-signer-bridge.d.ts +32 -0
- package/dist/auth/turnkey-wallet-widget.d.ts +17 -0
- package/dist/{email-auth-provider-4Df8dFOh.js → email-auth-provider-8k8iBIQL.js} +2 -2
- package/dist/{email-auth-provider-4Df8dFOh.js.map → email-auth-provider-8k8iBIQL.js.map} +1 -1
- package/dist/{email-auth-provider-CZ-xYVln.js → email-auth-provider-BlJI-8w9.js} +2 -2
- package/dist/{email-auth-provider-CZ-xYVln.js.map → email-auth-provider-BlJI-8w9.js.map} +1 -1
- package/dist/{email-auth-provider-By6SL0YS.mjs → email-auth-provider-Bmah1GWS.mjs} +2 -2
- package/dist/{email-auth-provider-By6SL0YS.mjs.map → email-auth-provider-Bmah1GWS.mjs.map} +1 -1
- package/dist/{email-auth-provider-BqX-o_sJ.mjs → email-auth-provider-CfNSS8Du.mjs} +2 -2
- package/dist/{email-auth-provider-BqX-o_sJ.mjs.map → email-auth-provider-CfNSS8Du.mjs.map} +1 -1
- package/dist/{guest-auth-provider-D9A4SU4z.js → guest-auth-provider-BRjJV8Zq.js} +2 -2
- package/dist/{guest-auth-provider-D9A4SU4z.js.map → guest-auth-provider-BRjJV8Zq.js.map} +1 -1
- package/dist/{guest-auth-provider-DWcdRvLW.js → guest-auth-provider-BjfjrpdW.js} +2 -2
- package/dist/{guest-auth-provider-DWcdRvLW.js.map → guest-auth-provider-BjfjrpdW.js.map} +1 -1
- package/dist/{guest-auth-provider-Q2wbjdHM.mjs → guest-auth-provider-D6h4eAtx.mjs} +2 -2
- package/dist/{guest-auth-provider-6bqnyX79.mjs.map → guest-auth-provider-D6h4eAtx.mjs.map} +1 -1
- package/dist/{guest-auth-provider-6bqnyX79.mjs → guest-auth-provider-DxhZ5sWN.mjs} +2 -2
- package/dist/{guest-auth-provider-Q2wbjdHM.mjs.map → guest-auth-provider-DxhZ5sWN.mjs.map} +1 -1
- package/dist/{index--jrXqxte.mjs → index-C7rOe6B2.mjs} +1572 -17
- package/dist/index-C7rOe6B2.mjs.map +1 -0
- package/dist/{index-B_uRc6gn.js → index-CnObYQhV.js} +1576 -16
- package/dist/index-CnObYQhV.js.map +1 -0
- package/dist/index.d.ts +7 -1
- package/dist/index.js +6 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{index.native-CTVEq0VY.mjs → index.native-CQiw9baS.mjs} +83 -12
- package/dist/index.native-CQiw9baS.mjs.map +1 -0
- package/dist/{index.native-BqK-14S8.js → index.native-hu3o3zXU.js} +82 -10
- package/dist/index.native-hu3o3zXU.js.map +1 -0
- package/dist/index.native.d.ts +2 -0
- package/dist/index.native.js +2 -1
- package/dist/index.native.js.map +1 -1
- package/dist/index.native.mjs +1 -1
- package/dist/{injected-evm-wallet-provider-xZ01LIw2.js → injected-evm-wallet-provider-CcwS6p3o.js} +2 -2
- package/dist/{injected-evm-wallet-provider-xZ01LIw2.js.map → injected-evm-wallet-provider-CcwS6p3o.js.map} +1 -1
- package/dist/{injected-evm-wallet-provider-BZPmj8bC.mjs → injected-evm-wallet-provider-DCGnUedJ.mjs} +2 -2
- package/dist/{injected-evm-wallet-provider-BZPmj8bC.mjs.map → injected-evm-wallet-provider-DCGnUedJ.mjs.map} +1 -1
- package/dist/{injected-evm-wallet-provider-BCR37kRN.mjs → injected-evm-wallet-provider-DIWeWiAN.mjs} +2 -2
- package/dist/{injected-evm-wallet-provider-BCR37kRN.mjs.map → injected-evm-wallet-provider-DIWeWiAN.mjs.map} +1 -1
- package/dist/{injected-evm-wallet-provider-CXfQT5sm.js → injected-evm-wallet-provider-Xbt2CUPi.js} +2 -2
- package/dist/{injected-evm-wallet-provider-CXfQT5sm.js.map → injected-evm-wallet-provider-Xbt2CUPi.js.map} +1 -1
- package/dist/{injected-wallet-provider-eMZ8tjas.js → injected-wallet-provider-7ep-jcal.js} +2 -2
- package/dist/{injected-wallet-provider-eMZ8tjas.js.map → injected-wallet-provider-7ep-jcal.js.map} +1 -1
- package/dist/{injected-wallet-provider-ClI_h_fy.js → injected-wallet-provider-B_jQFifE.js} +2 -2
- package/dist/{injected-wallet-provider-ClI_h_fy.js.map → injected-wallet-provider-B_jQFifE.js.map} +1 -1
- package/dist/{injected-wallet-provider-1IRUHyB3.mjs → injected-wallet-provider-Bps6a9IP.mjs} +2 -2
- package/dist/{injected-wallet-provider-1IRUHyB3.mjs.map → injected-wallet-provider-Bps6a9IP.mjs.map} +1 -1
- package/dist/{injected-wallet-provider-DHQGI0Yl.mjs → injected-wallet-provider-CFnqSsHy.mjs} +2 -2
- package/dist/{injected-wallet-provider-DHQGI0Yl.mjs.map → injected-wallet-provider-CFnqSsHy.mjs.map} +1 -1
- package/dist/wallet-standard-tx-C1HJFLjC.js +30 -0
- package/dist/wallet-standard-tx-C1HJFLjC.js.map +1 -0
- package/dist/wallet-standard-tx-DBliTUWH.mjs +27 -0
- package/dist/wallet-standard-tx-DBliTUWH.mjs.map +1 -0
- package/package.json +9 -3
- package/dist/index--jrXqxte.mjs.map +0 -1
- package/dist/index-B_uRc6gn.js.map +0 -1
- package/dist/index.native-BqK-14S8.js.map +0 -1
- package/dist/index.native-CTVEq0VY.mjs.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
export { init, getCurrentUser, onAuthStateChanged, onAuthLoadingChanged, getAuthLoading, login, logout, } from "./global";
|
|
2
2
|
export type { LoginOptions, LogoutOptions } from "./global";
|
|
3
3
|
export { getConfig } from "@bounded-sh/core";
|
|
4
|
-
export { getAuthProvider, signInAnonymously, loginWithPrivy } from "./auth";
|
|
4
|
+
export { getAuthProvider, signInAnonymously, loginWithPrivy, loginWithWallet } from "./auth";
|
|
5
5
|
export { loginWithRedirect, completeLoginFromRedirect, loginWithPopup, completeLoginInPopup } from "./auth";
|
|
6
6
|
export type { HostedAuthMethod, OidcLoginOptions, PopupLoginOptions } from "./auth";
|
|
7
|
+
export { openBoundedWidget } from "./auth/bounded-login-widget";
|
|
8
|
+
export type { BoundedWidgetOptions } from "./auth/bounded-login-widget";
|
|
7
9
|
export { get, getMany, docId, set, setMany, setFile, getFiles, search, queryAggregate, runQuery, runQueryMany, runExpression, runExpressionMany, signMessage, signTransaction, signAndSubmitTransaction, count, aggregate, GetOptions, SearchOptions, SetOptions, CountOptions, AggregateOptions, AggregateOperation, AggregateResult, AggregateSpec, AggregateRow, QueryAggregateOptions, } from "@bounded-sh/core";
|
|
8
10
|
export type { GetOptions as BoundedGetOptions } from "@bounded-sh/core";
|
|
9
11
|
export { subscribe } from "@bounded-sh/core";
|
|
@@ -23,6 +25,10 @@ export * from "./builds";
|
|
|
23
25
|
export { apps } from "./builds/apps";
|
|
24
26
|
export type { AppListItem, CreatedApp, CreateAppOptions } from "./builds/apps";
|
|
25
27
|
export { deserializeTransaction } from "./auth/providers/sol/sol-utils";
|
|
28
|
+
export { signSolanaMessageViaTurnkey, getOrCreateTurnkeyWallet } from "./auth/turnkey-signer-bridge";
|
|
29
|
+
export type { TurnkeySignResult, TurnkeyWallet } from "./auth/turnkey-signer-bridge";
|
|
30
|
+
export { startTurnkeyEmailLogin } from "./auth/turnkey-auth";
|
|
31
|
+
export type { TurnkeyEmailLoginHandle } from "./auth/turnkey-auth";
|
|
26
32
|
export { getIdToken } from "./utils";
|
|
27
33
|
export { setPlatform, getPlatform } from "./platform";
|
|
28
34
|
export type { PlatformAdapter, StorageAdapter } from "./platform";
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-CnObYQhV.js');
|
|
4
4
|
var core = require('@bounded-sh/core');
|
|
5
5
|
require('react');
|
|
6
6
|
|
|
@@ -28,18 +28,23 @@ exports.getAuthLoading = index.getAuthLoading;
|
|
|
28
28
|
exports.getAuthProvider = index.getAuthProvider;
|
|
29
29
|
exports.getCurrentUser = index.getCurrentUser;
|
|
30
30
|
exports.getIdToken = index.getIdToken;
|
|
31
|
+
exports.getOrCreateTurnkeyWallet = index.getOrCreateTurnkeyWallet;
|
|
31
32
|
exports.getPlatform = index.getPlatform;
|
|
32
33
|
exports.init = index.init;
|
|
33
34
|
exports.login = index.login;
|
|
34
35
|
exports.loginWithPopup = index.loginWithPopup;
|
|
35
36
|
exports.loginWithPrivy = index.loginWithPrivy;
|
|
36
37
|
exports.loginWithRedirect = index.loginWithRedirect;
|
|
38
|
+
exports.loginWithWallet = index.loginWithWallet;
|
|
37
39
|
exports.logout = index.logout;
|
|
38
40
|
exports.onAuthLoadingChanged = index.onAuthLoadingChanged;
|
|
39
41
|
exports.onAuthStateChanged = index.onAuthStateChanged;
|
|
42
|
+
exports.openBoundedWidget = index.openBoundedWidget;
|
|
40
43
|
exports.requestEip6963Providers = index.requestEip6963Providers;
|
|
41
44
|
exports.setPlatform = index.setPlatform;
|
|
42
45
|
exports.signInAnonymously = index.signInAnonymously;
|
|
46
|
+
exports.signSolanaMessageViaTurnkey = index.signSolanaMessageViaTurnkey;
|
|
47
|
+
exports.startTurnkeyEmailLogin = index.startTurnkeyEmailLogin;
|
|
43
48
|
exports.useAuth = index.useAuth;
|
|
44
49
|
exports.useBuildRun = index.useBuildRun;
|
|
45
50
|
exports.useQuery = index.useQuery;
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { $ as BUILD_DELEGATED_REVIEW_CAPABILITY_SCHEMA, _ as BUILD_REVIEW_CAPABILITY_REFRESH_SCHEMA, Z as BUILD_REVIEW_CAPABILITY_SCHEMA, T as BuildsApiError, Y as FAILURE_REASONS, U as NON_TERMINAL_STATES, P as OffchainAuthProvider, X as PARK_REASONS, Q as PrivyExpoProvider, W as RUN_STATES, V as TERMINAL_STATES, I as apps, S as builds, A as completeLoginFromRedirect, C as completeLoginInPopup, k as defaultInjectedEvmProvider, d as defaultInjectedProvider, J as deserializeTransaction, q as getAuthLoading, v as getAuthProvider, m as getCurrentUser, N as getIdToken, L as getOrCreateTurnkeyWallet, g as getPlatform, l as init, t as login, B as loginWithPopup, x as loginWithPrivy, z as loginWithRedirect, y as loginWithWallet, u as logout, p as onAuthLoadingChanged, o as onAuthStateChanged, D as openBoundedWidget, R as requestEip6963Providers, O as setPlatform, w as signInAnonymously, K as signSolanaMessageViaTurnkey, M as startTurnkeyEmailLogin, F as useAuth, H as useBuildRun, G as useQuery } from './index-C7rOe6B2.mjs';
|
|
2
2
|
export * from '@bounded-sh/core';
|
|
3
3
|
export { BoundedDeclineError, DECLINE_EVENT_NAME, RATE_LIMIT_EVENT_NAME, ScopedClientReadOnlyError, aggregate, count, createClient, deriveDecline, dispatchDeclineEvent, dispatchRateLimitEvent, docId, get, getConfig, getFiles, getMany, queryAggregate, runExpression, runExpressionMany, runQuery, runQueryMany, search, set, setFile, setMany, signAndSubmitTransaction, signMessage, signTransaction, subscribe } from '@bounded-sh/core';
|
|
4
4
|
import 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { assertCanonicalBoundedRuntimeWriteCalldata, getActiveSessionManager, getConfig, WebSessionManager, ReactNativeSessionManager, revokeSession, init as init$1, reconnectWithNewAuth, deriveUserIdentityFromIdToken, getIdToken as getIdToken$1, convertRemainingAccounts, buildSetDocumentsTransaction, genAuthNonce, genSolanaMessage, createSessionWithSignature } from '@bounded-sh/core';
|
|
1
|
+
import { assertCanonicalBoundedRuntimeWriteCalldata, getActiveSessionManager, getConfig, WebSessionManager, ReactNativeSessionManager, revokeSession, init as init$1, reconnectWithNewAuth, deriveUserIdentityFromIdToken, subscribe, getIdToken as getIdToken$1, convertRemainingAccounts, buildSetDocumentsTransaction, genAuthNonce, genSolanaMessage, createSessionWithSignature } from '@bounded-sh/core';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -3809,6 +3809,11 @@ function appendHostedLoginHints(params, opts) {
|
|
|
3809
3809
|
const provider = normalizeMethod(opts.provider);
|
|
3810
3810
|
if (provider)
|
|
3811
3811
|
params.set('bounded_provider', provider);
|
|
3812
|
+
// login_hint: an identifier (usually an email) to prefill on the hosted page.
|
|
3813
|
+
// Kept short and free of control chars; the hosted page validates before use.
|
|
3814
|
+
const hint = String(opts.loginHint || '').trim();
|
|
3815
|
+
if (hint && hint.length <= 320 && !/[\s<>"']/.test(hint))
|
|
3816
|
+
params.set('login_hint', hint);
|
|
3812
3817
|
// Standard OIDC prompt (e.g. 'login' to force a fresh sign-in / account choice).
|
|
3813
3818
|
const prompt = normalizeMethod(opts.prompt);
|
|
3814
3819
|
if (prompt)
|
|
@@ -4443,7 +4448,7 @@ async function getAuthProvider(config) {
|
|
|
4443
4448
|
// manager as legacy email sessions. Human login should be started
|
|
4444
4449
|
// with loginWithRedirect(); this provider is kept as the restore and
|
|
4445
4450
|
// logout surface for those sessions.
|
|
4446
|
-
currentAuthProvider = new (await import('./email-auth-provider-
|
|
4451
|
+
currentAuthProvider = new (await import('./email-auth-provider-CfNSS8Du.mjs')).EmailAuthProvider();
|
|
4447
4452
|
break;
|
|
4448
4453
|
case "wallet":
|
|
4449
4454
|
case "phantom": {
|
|
@@ -4462,7 +4467,7 @@ async function getAuthProvider(config) {
|
|
|
4462
4467
|
if (!isWalletLoginEnabled(config)) {
|
|
4463
4468
|
throw walletLoginNotEnabledError(authMethod);
|
|
4464
4469
|
}
|
|
4465
|
-
const { InjectedWalletProvider } = await import('./injected-wallet-provider-
|
|
4470
|
+
const { InjectedWalletProvider } = await import('./injected-wallet-provider-Bps6a9IP.mjs');
|
|
4466
4471
|
currentAuthProvider = new InjectedWalletProvider(resolveInjectedWalletConfig(config), rpcUrl, configuredNetwork);
|
|
4467
4472
|
break;
|
|
4468
4473
|
}
|
|
@@ -4475,7 +4480,7 @@ async function getAuthProvider(config) {
|
|
|
4475
4480
|
// Selecting authMethod:'evm-wallet' IS the opt-in — pass evmWalletConfig
|
|
4476
4481
|
// to point at a specific wallet or set chainId/domain.
|
|
4477
4482
|
const evmWalletConfig = ((_a = config.evmWalletConfig) !== null && _a !== void 0 ? _a : {});
|
|
4478
|
-
const { InjectedEvmWalletProvider } = await import('./injected-evm-wallet-provider-
|
|
4483
|
+
const { InjectedEvmWalletProvider } = await import('./injected-evm-wallet-provider-DCGnUedJ.mjs');
|
|
4479
4484
|
currentAuthProvider = new InjectedEvmWalletProvider(evmWalletConfig);
|
|
4480
4485
|
break;
|
|
4481
4486
|
}
|
|
@@ -4503,7 +4508,7 @@ async function getAuthProvider(config) {
|
|
|
4503
4508
|
break;
|
|
4504
4509
|
case "guest":
|
|
4505
4510
|
// Anonymous auth: a device-local ed25519 keypair signs the challenge.
|
|
4506
|
-
currentAuthProvider = new (await import('./guest-auth-provider-
|
|
4511
|
+
currentAuthProvider = new (await import('./guest-auth-provider-DxhZ5sWN.mjs')).GuestAuthProvider();
|
|
4507
4512
|
break;
|
|
4508
4513
|
}
|
|
4509
4514
|
if (!currentAuthProvider) {
|
|
@@ -4559,7 +4564,7 @@ async function signInAnonymously() {
|
|
|
4559
4564
|
// Lazy-load the guest provider so its ed25519/web3 dependencies stay out of
|
|
4560
4565
|
// the main bundle for data-only apps. Specifier is a static string literal
|
|
4561
4566
|
// so bundle-splitting can see it.
|
|
4562
|
-
const provider = new (await import('./guest-auth-provider-
|
|
4567
|
+
const provider = new (await import('./guest-auth-provider-DxhZ5sWN.mjs')).GuestAuthProvider();
|
|
4563
4568
|
setAuthLoading(true); // reflect "signing in…" while the guest keypair session is minted
|
|
4564
4569
|
const commit = (user) => {
|
|
4565
4570
|
// No await/interleaving inside this block: provider/method/config/marker
|
|
@@ -5003,17 +5008,17 @@ function setAuthProviderInstance(provider) {
|
|
|
5003
5008
|
authProviderInstance = provider;
|
|
5004
5009
|
}
|
|
5005
5010
|
|
|
5006
|
-
var _a$
|
|
5011
|
+
var _a$2;
|
|
5007
5012
|
// Whether we're in a server-side rendering context (no hooks allowed).
|
|
5008
5013
|
// React Native has no `window` but DOES support hooks.
|
|
5009
5014
|
// We detect Node SSR specifically via process.versions.node to avoid
|
|
5010
5015
|
// false positives from Node 21+ which defines `navigator` globally.
|
|
5011
|
-
const isSSR$
|
|
5016
|
+
const isSSR$2 = typeof window === 'undefined'
|
|
5012
5017
|
&& typeof process !== 'undefined'
|
|
5013
|
-
&& !!((_a$
|
|
5018
|
+
&& !!((_a$2 = process.versions) === null || _a$2 === void 0 ? void 0 : _a$2.node);
|
|
5014
5019
|
function useAuth() {
|
|
5015
5020
|
// Provide a fallback so server render doesn't break
|
|
5016
|
-
if (isSSR$
|
|
5021
|
+
if (isSSR$2) {
|
|
5017
5022
|
return {
|
|
5018
5023
|
login: async (_options) => undefined,
|
|
5019
5024
|
logout: async () => undefined,
|
|
@@ -5075,6 +5080,72 @@ function useAuth() {
|
|
|
5075
5080
|
};
|
|
5076
5081
|
}
|
|
5077
5082
|
|
|
5083
|
+
var _a$1;
|
|
5084
|
+
// SSR guard (mirrors useAuth): no hooks/subscriptions during Node server render.
|
|
5085
|
+
// React Native has no `window` but DOES support hooks, so detect Node SSR
|
|
5086
|
+
// specifically via process.versions.node.
|
|
5087
|
+
const isSSR$1 = typeof window === 'undefined'
|
|
5088
|
+
&& typeof process !== 'undefined'
|
|
5089
|
+
&& !!((_a$1 = process.versions) === null || _a$1 === void 0 ? void 0 : _a$1.node);
|
|
5090
|
+
function useQuery(path, options) {
|
|
5091
|
+
if (isSSR$1) {
|
|
5092
|
+
return { data: undefined, loading: true, error: null };
|
|
5093
|
+
}
|
|
5094
|
+
const [data, setData] = React.useState(undefined);
|
|
5095
|
+
const [loading, setLoading] = React.useState(true);
|
|
5096
|
+
const [error, setError] = React.useState(null);
|
|
5097
|
+
// Re-subscribe only when the query actually changes (not on every render).
|
|
5098
|
+
const optionsKey = options ? JSON.stringify(options) : '';
|
|
5099
|
+
React.useEffect(() => {
|
|
5100
|
+
if (!path) {
|
|
5101
|
+
setData(undefined);
|
|
5102
|
+
setLoading(false);
|
|
5103
|
+
setError(null);
|
|
5104
|
+
return;
|
|
5105
|
+
}
|
|
5106
|
+
let active = true;
|
|
5107
|
+
let unsubscribe;
|
|
5108
|
+
setLoading(true);
|
|
5109
|
+
setError(null);
|
|
5110
|
+
subscribe(path, Object.assign(Object.assign({}, options), { onData: (d) => {
|
|
5111
|
+
if (!active)
|
|
5112
|
+
return;
|
|
5113
|
+
// A reconnect can legitimately surface a transport error before the
|
|
5114
|
+
// socket re-authenticates and sends a new authorized snapshot. That
|
|
5115
|
+
// fresh snapshot is the recovery boundary: keep the error visible
|
|
5116
|
+
// until data arrives, then clear it so React does not remain stuck on
|
|
5117
|
+
// a failure page after realtime has recovered.
|
|
5118
|
+
setError(null);
|
|
5119
|
+
setData(d);
|
|
5120
|
+
setLoading(false);
|
|
5121
|
+
}, onError: (e) => {
|
|
5122
|
+
if (!active)
|
|
5123
|
+
return;
|
|
5124
|
+
setError(e instanceof Error ? e : new Error(String(e)));
|
|
5125
|
+
setLoading(false);
|
|
5126
|
+
} }))
|
|
5127
|
+
.then((unsub) => {
|
|
5128
|
+
if (active)
|
|
5129
|
+
unsubscribe = unsub;
|
|
5130
|
+
else
|
|
5131
|
+
void unsub(); // unmounted before subscribe resolved
|
|
5132
|
+
})
|
|
5133
|
+
.catch((e) => {
|
|
5134
|
+
if (!active)
|
|
5135
|
+
return;
|
|
5136
|
+
setError(e instanceof Error ? e : new Error(String(e)));
|
|
5137
|
+
setLoading(false);
|
|
5138
|
+
});
|
|
5139
|
+
return () => {
|
|
5140
|
+
active = false;
|
|
5141
|
+
void (unsubscribe === null || unsubscribe === void 0 ? void 0 : unsubscribe());
|
|
5142
|
+
};
|
|
5143
|
+
// optionsKey captures the option object's contents; path is the other input.
|
|
5144
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
5145
|
+
}, [path, optionsKey]);
|
|
5146
|
+
return { data, loading, error };
|
|
5147
|
+
}
|
|
5148
|
+
|
|
5078
5149
|
// Wrapper for getIdToken - passes isServer=false for client-side usage
|
|
5079
5150
|
async function getIdToken() {
|
|
5080
5151
|
return getIdToken$1(false);
|
|
@@ -6078,5 +6149,5 @@ class PrivyExpoProvider {
|
|
|
6078
6149
|
}
|
|
6079
6150
|
}
|
|
6080
6151
|
|
|
6081
|
-
export { useAuth as A,
|
|
6082
|
-
//# sourceMappingURL=index.native-
|
|
6152
|
+
export { useAuth as A, useQuery as B, useBuildRun as C, apps as D, EMBEDDED_WALLET_UNSUPPORTED as E, deserializeTransaction as F, getIdToken as G, setPlatform as H, builds as I, BuildsApiError as J, PARK_REASONS as K, FAILURE_REASONS as L, BUILD_REVIEW_CAPABILITY_SCHEMA as M, NON_TERMINAL_STATES as N, OffchainAuthProvider as O, PrivyExpoProvider as P, BUILD_REVIEW_CAPABILITY_REFRESH_SCHEMA as Q, RUN_STATES as R, BUILD_DELEGATED_REVIEW_CAPABILITY_SCHEMA as S, TERMINAL_STATES as T, hasEmbeddedEvmWallet as a, embeddedSignAndSubmit as b, setAuthLoading as c, bufferExports as d, embeddedRunEvmTransaction as e, bs58 as f, getPlatform as g, hasEmbeddedWallet as h, confirmAndCheckTransaction as i, init as j, getCurrentUser as k, onAuthLoadingChanged as l, getAuthLoading as m, normalizeSolanaRpcUrl as n, onAuthStateChanged as o, login as p, logout as q, resolveSolanaRpcUrl as r, setCurrentUser as s, getAuthProvider as t, signInAnonymously as u, loginWithPrivy as v, loginWithRedirect as w, completeLoginFromRedirect as x, loginWithPopup as y, completeLoginInPopup as z };
|
|
6153
|
+
//# sourceMappingURL=index.native-CQiw9baS.mjs.map
|