@tern-secure/react 1.1.5 → 1.1.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/ctx/AuthProvider.d.mts +13 -3
- package/dist/ctx/AuthProvider.d.ts +13 -3
- package/dist/ctx/AuthProvider.js +1 -1
- package/dist/ctx/AuthProvider.js.map +1 -1
- package/dist/ctx/AuthProvider.mjs +1 -1
- package/dist/ctx/AuthProvider.mjs.map +1 -1
- package/dist/ctx/IsomorphicTernSecureCtx.d.mts +5 -5
- package/dist/ctx/IsomorphicTernSecureCtx.d.ts +5 -5
- package/dist/ctx/IsomorphicTernSecureCtx.js +1 -1
- package/dist/ctx/IsomorphicTernSecureCtx.js.map +1 -1
- package/dist/ctx/IsomorphicTernSecureCtx.mjs +1 -1
- package/dist/ctx/IsomorphicTernSecureCtx.mjs.map +1 -1
- package/dist/ctx/TernSecureAuthResourcesCtx.d.mts +6 -0
- package/dist/ctx/TernSecureAuthResourcesCtx.d.ts +6 -0
- package/dist/ctx/TernSecureAuthResourcesCtx.js +2 -0
- package/dist/ctx/TernSecureAuthResourcesCtx.js.map +1 -0
- package/dist/ctx/TernSecureAuthResourcesCtx.mjs +2 -0
- package/dist/ctx/TernSecureAuthResourcesCtx.mjs.map +1 -0
- package/dist/ctx/TernSecureCtxProvider.d.mts +6 -8
- package/dist/ctx/TernSecureCtxProvider.d.ts +6 -8
- package/dist/ctx/TernSecureCtxProvider.js +1 -1
- package/dist/ctx/TernSecureCtxProvider.js.map +1 -1
- package/dist/ctx/TernSecureCtxProvider.mjs +1 -1
- package/dist/ctx/TernSecureCtxProvider.mjs.map +1 -1
- package/dist/ctx/TernSecureProvider.js +1 -1
- package/dist/ctx/TernSecureProvider.js.map +1 -1
- package/dist/ctx/TernSecureProvider.mjs +1 -1
- package/dist/ctx/TernSecureProvider.mjs.map +1 -1
- package/dist/hooks/useAssertWrappedTernSecureProvider.d.mts +2 -2
- package/dist/hooks/useAssertWrappedTernSecureProvider.d.ts +2 -2
- package/dist/hooks/useAssertWrappedTernSecureProvider.js +2 -2
- package/dist/hooks/useAssertWrappedTernSecureProvider.js.map +1 -1
- package/dist/hooks/useAssertWrappedTernSecureProvider.mjs +2 -2
- package/dist/hooks/useAssertWrappedTernSecureProvider.mjs.map +1 -1
- package/dist/hooks/useAuth.d.mts +2 -2
- package/dist/hooks/useAuth.d.ts +2 -2
- package/dist/hooks/useAuth.js +1 -1
- package/dist/hooks/useAuth.js.map +1 -1
- package/dist/hooks/useAuth.mjs +1 -1
- package/dist/hooks/useAuth.mjs.map +1 -1
- package/dist/hooks/useIdToken.js +1 -1
- package/dist/hooks/useIdToken.js.map +1 -1
- package/dist/hooks/useIdToken.mjs +1 -1
- package/dist/hooks/useIdToken.mjs.map +1 -1
- package/dist/hooks/useSession.js +1 -1
- package/dist/hooks/useSession.js.map +1 -1
- package/dist/hooks/useSession.mjs +1 -1
- package/dist/hooks/useSession.mjs.map +1 -1
- package/dist/hooks/useSignIn.d.mts +17 -0
- package/dist/hooks/useSignIn.d.ts +17 -0
- package/dist/hooks/useSignIn.js +2 -0
- package/dist/hooks/useSignIn.js.map +1 -0
- package/dist/hooks/useSignIn.mjs +2 -0
- package/dist/hooks/useSignIn.mjs.map +1 -0
- package/dist/index.d.mts +2 -7
- package/dist/index.d.ts +2 -7
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/lib/isoTernSecureAuth.d.mts +46 -0
- package/dist/lib/isoTernSecureAuth.d.ts +46 -0
- package/dist/lib/isoTernSecureAuth.js +2 -0
- package/dist/lib/isoTernSecureAuth.js.map +1 -0
- package/dist/lib/isoTernSecureAuth.mjs +2 -0
- package/dist/lib/isoTernSecureAuth.mjs.map +1 -0
- package/dist/lib/utils.js.map +1 -1
- package/dist/lib/utils.mjs.map +1 -1
- package/dist/types.d.mts +16 -6
- package/dist/types.d.ts +16 -6
- package/dist/types.js +1 -1
- package/dist/types.js.map +1 -1
- package/dist/types.mjs.map +1 -1
- package/dist/utils/config.js +2 -2
- package/dist/utils/config.js.map +1 -1
- package/dist/utils/config.mjs +3 -3
- package/dist/utils/config.mjs.map +1 -1
- package/dist/utils/construct.js.map +1 -1
- package/dist/utils/construct.mjs +1 -1
- package/dist/utils/construct.mjs.map +1 -1
- package/dist/utils/debug.js +1 -1
- package/dist/utils/debug.js.map +1 -1
- package/dist/utils/debug.mjs +1 -1
- package/dist/utils/debug.mjs.map +1 -1
- package/package.json +6 -5
- package/dist/client/actions.d.mts +0 -2
- package/dist/client/actions.d.ts +0 -2
- package/dist/client/actions.js +0 -2
- package/dist/client/actions.js.map +0 -1
- package/dist/client/actions.mjs +0 -1
- package/dist/client/actions.mjs.map +0 -1
- package/dist/client/session.d.mts +0 -9
- package/dist/client/session.d.ts +0 -9
- package/dist/client/session.js +0 -2
- package/dist/client/session.js.map +0 -1
- package/dist/client/session.mjs +0 -2
- package/dist/client/session.mjs.map +0 -1
- package/dist/components/TernSecureHostRenderer.d.mts +0 -32
- package/dist/components/TernSecureHostRenderer.d.ts +0 -32
- package/dist/components/TernSecureHostRenderer.js +0 -2
- package/dist/components/TernSecureHostRenderer.js.map +0 -1
- package/dist/components/TernSecureHostRenderer.mjs +0 -2
- package/dist/components/TernSecureHostRenderer.mjs.map +0 -1
- package/dist/components/background.d.mts +0 -5
- package/dist/components/background.d.ts +0 -5
- package/dist/components/background.js +0 -2
- package/dist/components/background.js.map +0 -1
- package/dist/components/background.mjs +0 -2
- package/dist/components/background.mjs.map +0 -1
- package/dist/components/old.d.mts +0 -2
- package/dist/components/old.d.ts +0 -2
- package/dist/components/old.js +0 -2
- package/dist/components/old.js.map +0 -1
- package/dist/components/old.mjs +0 -1
- package/dist/components/old.mjs.map +0 -1
- package/dist/components/uiComponent.d.mts +0 -30
- package/dist/components/uiComponent.d.ts +0 -30
- package/dist/components/uiComponent.js +0 -2
- package/dist/components/uiComponent.js.map +0 -1
- package/dist/components/uiComponent.mjs +0 -2
- package/dist/components/uiComponent.mjs.map +0 -1
- package/dist/components/withTernSecure.d.mts +0 -19
- package/dist/components/withTernSecure.d.ts +0 -19
- package/dist/components/withTernSecure.js +0 -2
- package/dist/components/withTernSecure.js.map +0 -1
- package/dist/components/withTernSecure.mjs +0 -2
- package/dist/components/withTernSecure.mjs.map +0 -1
- package/dist/hooks/useAuthState.d.mts +0 -17
- package/dist/hooks/useAuthState.d.ts +0 -17
- package/dist/hooks/useAuthState.js +0 -2
- package/dist/hooks/useAuthState.js.map +0 -1
- package/dist/hooks/useAuthState.mjs +0 -2
- package/dist/hooks/useAuthState.mjs.map +0 -1
- package/dist/hooks/useMaxAllowedInstances.d.mts +0 -6
- package/dist/hooks/useMaxAllowedInstances.d.ts +0 -6
- package/dist/hooks/useMaxAllowedInstances.js +0 -2
- package/dist/hooks/useMaxAllowedInstances.js.map +0 -1
- package/dist/hooks/useMaxAllowedInstances.mjs +0 -2
- package/dist/hooks/useMaxAllowedInstances.mjs.map +0 -1
- package/dist/hooks/useSignUp.d.mts +0 -13
- package/dist/hooks/useSignUp.d.ts +0 -13
- package/dist/hooks/useSignUp.js +0 -2
- package/dist/hooks/useSignUp.js.map +0 -1
- package/dist/hooks/useSignUp.mjs +0 -2
- package/dist/hooks/useSignUp.mjs.map +0 -1
- package/dist/hooks/useWaitForComponentMount.d.mts +0 -8
- package/dist/hooks/useWaitForComponentMount.d.ts +0 -8
- package/dist/hooks/useWaitForComponentMount.js +0 -2
- package/dist/hooks/useWaitForComponentMount.js.map +0 -1
- package/dist/hooks/useWaitForComponentMount.mjs +0 -2
- package/dist/hooks/useWaitForComponentMount.mjs.map +0 -1
- package/dist/lib/isomorphicTernSecure.d.mts +0 -73
- package/dist/lib/isomorphicTernSecure.d.ts +0 -73
- package/dist/lib/isomorphicTernSecure.js +0 -2
- package/dist/lib/isomorphicTernSecure.js.map +0 -1
- package/dist/lib/isomorphicTernSecure.mjs +0 -2
- package/dist/lib/isomorphicTernSecure.mjs.map +0 -1
- package/dist/types/auth.d.mts +0 -2
- package/dist/types/auth.d.ts +0 -2
- package/dist/types/auth.js +0 -2
- package/dist/types/auth.js.map +0 -1
- package/dist/types/auth.mjs +0 -1
- package/dist/types/auth.mjs.map +0 -1
- package/dist/types/client/actions.d.ts +0 -2
- package/dist/types/client/actions.d.ts.map +0 -1
- package/dist/types/client/session.d.ts +0 -7
- package/dist/types/client/session.d.ts.map +0 -1
- package/dist/types/components/TernSecureHostRenderer.d.ts +0 -30
- package/dist/types/components/TernSecureHostRenderer.d.ts.map +0 -1
- package/dist/types/components/background.d.ts +0 -2
- package/dist/types/components/background.d.ts.map +0 -1
- package/dist/types/components/old.d.ts +0 -2
- package/dist/types/components/old.d.ts.map +0 -1
- package/dist/types/components/uiComponent.d.ts +0 -27
- package/dist/types/components/uiComponent.d.ts.map +0 -1
- package/dist/types/components/withTernSecure.d.ts +0 -16
- package/dist/types/components/withTernSecure.d.ts.map +0 -1
- package/dist/types/ctx/AuthProvider.d.ts +0 -3
- package/dist/types/ctx/AuthProvider.d.ts.map +0 -1
- package/dist/types/ctx/IsomorphicTernSecureCtx.d.ts +0 -6
- package/dist/types/ctx/IsomorphicTernSecureCtx.d.ts.map +0 -1
- package/dist/types/ctx/SessionCtx.d.ts +0 -2
- package/dist/types/ctx/SessionCtx.d.ts.map +0 -1
- package/dist/types/ctx/TernSecureCtxProvider.d.ts +0 -14
- package/dist/types/ctx/TernSecureCtxProvider.d.ts.map +0 -1
- package/dist/types/ctx/TernSecureProvider.d.ts +0 -6
- package/dist/types/ctx/TernSecureProvider.d.ts.map +0 -1
- package/dist/types/ctx/UserCtx.d.ts +0 -2
- package/dist/types/ctx/UserCtx.d.ts.map +0 -1
- package/dist/types/hooks/useAssertWrappedTernSecureProvider.d.ts +0 -2
- package/dist/types/hooks/useAssertWrappedTernSecureProvider.d.ts.map +0 -1
- package/dist/types/hooks/useAuth.d.ts +0 -3
- package/dist/types/hooks/useAuth.d.ts.map +0 -1
- package/dist/types/hooks/useAuthState.d.ts +0 -14
- package/dist/types/hooks/useAuthState.d.ts.map +0 -1
- package/dist/types/hooks/useIdToken.d.ts +0 -19
- package/dist/types/hooks/useIdToken.d.ts.map +0 -1
- package/dist/types/hooks/useMaxAllowedInstances.d.ts +0 -4
- package/dist/types/hooks/useMaxAllowedInstances.d.ts.map +0 -1
- package/dist/types/hooks/useSession.d.ts +0 -12
- package/dist/types/hooks/useSession.d.ts.map +0 -1
- package/dist/types/hooks/useSignUp.d.ts +0 -11
- package/dist/types/hooks/useSignUp.d.ts.map +0 -1
- package/dist/types/hooks/useWaitForComponentMount.d.ts +0 -8
- package/dist/types/hooks/useWaitForComponentMount.d.ts.map +0 -1
- package/dist/types/index.d.ts +0 -14
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/lib/isomorphicTernSecure.d.ts +0 -70
- package/dist/types/lib/isomorphicTernSecure.d.ts.map +0 -1
- package/dist/types/lib/utils.d.ts +0 -3
- package/dist/types/lib/utils.d.ts.map +0 -1
- package/dist/types/route-handler/internal-route.d.ts +0 -13
- package/dist/types/route-handler/internal-route.d.ts.map +0 -1
- package/dist/types/types/auth.d.ts +0 -2
- package/dist/types/types/auth.d.ts.map +0 -1
- package/dist/types/types.d.ts +0 -94
- package/dist/types/types.d.ts.map +0 -1
- package/dist/types/utils/client-init.d.ts +0 -2
- package/dist/types/utils/client-init.d.ts.map +0 -1
- package/dist/types/utils/config.d.ts +0 -35
- package/dist/types/utils/config.d.ts.map +0 -1
- package/dist/types/utils/construct.d.ts +0 -38
- package/dist/types/utils/construct.d.ts.map +0 -1
- package/dist/types/utils/create-styles.d.ts +0 -99
- package/dist/types/utils/create-styles.d.ts.map +0 -1
- package/dist/types/utils/debug.d.ts +0 -13
- package/dist/types/utils/debug.d.ts.map +0 -1
- package/dist/types/utils/redirect.d.ts +0 -9
- package/dist/types/utils/redirect.d.ts.map +0 -1
- package/dist/utils/client-init.d.mts +0 -2
- package/dist/utils/client-init.d.ts +0 -2
- package/dist/utils/client-init.js +0 -2
- package/dist/utils/client-init.js.map +0 -1
- package/dist/utils/client-init.mjs +0 -1
- package/dist/utils/client-init.mjs.map +0 -1
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import type { TernSecureInstanceTree, TernSecureInstanceTreeStatus, TernSecureAuthProvider, SignInPropsTree, SignUpPropsTree, SignInRedirectOptions, SignUpRedirectOptions } from '@tern-secure/types';
|
|
2
|
-
import type { Browser, IsomorphicTernSecureOptions, HeadlessUIBrowser } from '../types';
|
|
3
|
-
export interface Global {
|
|
4
|
-
TernSecure?: HeadlessUIBrowser | Browser;
|
|
5
|
-
}
|
|
6
|
-
export declare function inBrowser(): boolean;
|
|
7
|
-
/**
|
|
8
|
-
* IsomorphicTernSecure class manages the auth state and UI rendering
|
|
9
|
-
* in both browser and server environments
|
|
10
|
-
*/
|
|
11
|
-
export declare class IsomorphicTernSecure implements TernSecureInstanceTree {
|
|
12
|
-
#private;
|
|
13
|
-
private readonly _mode;
|
|
14
|
-
private readonly options;
|
|
15
|
-
private readonly TernSecure;
|
|
16
|
-
private ternui;
|
|
17
|
-
private _authProvider?;
|
|
18
|
-
private premountState;
|
|
19
|
-
get isReady(): boolean;
|
|
20
|
-
get status(): TernSecureInstanceTreeStatus;
|
|
21
|
-
get isLoading(): boolean;
|
|
22
|
-
get error(): Error | null;
|
|
23
|
-
get requiresVerification(): boolean;
|
|
24
|
-
static getOrCreateInstance(options: IsomorphicTernSecureOptions): IsomorphicTernSecure;
|
|
25
|
-
static clearInstance(): void;
|
|
26
|
-
get customDomain(): string;
|
|
27
|
-
get proxyUrl(): string | undefined;
|
|
28
|
-
get apiKey(): string | undefined;
|
|
29
|
-
get projectId(): string | undefined;
|
|
30
|
-
get sdkMetadata(): import("@tern-secure/types").TernSecureSDK | undefined;
|
|
31
|
-
get version(): string | undefined;
|
|
32
|
-
get mode(): 'browser' | 'server' | undefined;
|
|
33
|
-
constructor(options: IsomorphicTernSecureOptions);
|
|
34
|
-
get auth(): TernSecureInstanceTree['auth'];
|
|
35
|
-
get isVisible(): boolean;
|
|
36
|
-
get currentView(): 'signIn' | 'signUp' | 'verify' | null;
|
|
37
|
-
get ternAuth(): TernSecureAuthProvider | undefined;
|
|
38
|
-
loadTernUI(): Promise<HeadlessUIBrowser | Browser | undefined>;
|
|
39
|
-
private beforeLoad;
|
|
40
|
-
private injectTernUI;
|
|
41
|
-
/**
|
|
42
|
-
* Subscribe to TernUI events and delegate status changes
|
|
43
|
-
*/
|
|
44
|
-
private subscribeToTernUIEvents;
|
|
45
|
-
initialize: (props: any) => Promise<void>;
|
|
46
|
-
showSignIn: (node: HTMLDivElement, config?: SignInPropsTree) => void;
|
|
47
|
-
hideSignIn: (node: HTMLDivElement) => void;
|
|
48
|
-
showSignUp: (node: HTMLDivElement, config?: SignUpPropsTree) => void;
|
|
49
|
-
hideSignUp: (node: HTMLDivElement) => void;
|
|
50
|
-
showUserButton: (node: HTMLDivElement) => void;
|
|
51
|
-
hideUserButton: (node: HTMLDivElement) => void;
|
|
52
|
-
clearError: () => void;
|
|
53
|
-
setLoading: (isLoading: boolean) => void;
|
|
54
|
-
getRedirectResult: () => Promise<any>;
|
|
55
|
-
shouldRedirect: (currentPath: string) => boolean | string;
|
|
56
|
-
constructUrlWithAuthRedirect: (baseUrl: string) => string;
|
|
57
|
-
redirectToSignIn: (options?: SignInRedirectOptions) => Promise<void>;
|
|
58
|
-
redirectToSignUp: (options?: SignUpRedirectOptions) => Promise<void>;
|
|
59
|
-
redirectAfterSignIn: (redirectUrl?: string) => void;
|
|
60
|
-
redirectAfterSignUp: (redirectUrl?: string) => void;
|
|
61
|
-
get events(): TernSecureInstanceTree['events'];
|
|
62
|
-
private queueMethodCall;
|
|
63
|
-
setAuthProvider(ternAuth: TernSecureAuthProvider): void;
|
|
64
|
-
/**
|
|
65
|
-
* Update the instance and process any queued operations
|
|
66
|
-
*/
|
|
67
|
-
__internal_updateInstance(instance: TernSecureInstanceTree): void;
|
|
68
|
-
}
|
|
69
|
-
export declare function isConstructor<T>(f: any): f is T;
|
|
70
|
-
//# sourceMappingURL=isomorphicTernSecure.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"isomorphicTernSecure.d.ts","sourceRoot":"","sources":["../../../src/lib/isomorphicTernSecure.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,sBAAsB,EAEtB,4BAA4B,EAC5B,sBAAsB,EACtB,eAAe,EAEf,eAAe,EACf,qBAAqB,EACrB,qBAAqB,EAEtB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EACV,OAAO,EAGP,2BAA2B,EAC3B,iBAAiB,EAElB,MAAM,UAAU,CAAA;AAWjB,MAAM,WAAW,MAAM;IACrB,UAAU,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC;CAC1C;AAID,wBAAgB,SAAS,IAAI,OAAO,CAEnC;AAcD;;;GAGG;AACH,qBAAa,oBAAqB,YAAW,sBAAsB;;IACjE,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAwB;IAC9C,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA8B;IACtD,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAkB;IAC7C,OAAO,CAAC,MAAM,CAA4C;IAC1D,OAAO,CAAC,aAAa,CAAC,CAAyB;IAG/C,OAAO,CAAC,aAAa,CAQnB;IAKF,IAAI,OAAO,IAAI,OAAO,CAErB;IAED,IAAI,MAAM,IAAI,4BAA4B,CAQzC;IAED,IAAI,SAAS,IAAI,OAAO,CAEvB;IAED,IAAI,KAAK,IAAI,KAAK,GAAG,IAAI,CAExB;IAED,IAAI,oBAAoB,IAAI,OAAO,CAElC;IAED,MAAM,CAAC,mBAAmB,CAAC,OAAO,EAAE,2BAA2B;IAW/D,MAAM,CAAC,aAAa;IAKpB,IAAI,YAAY,IAAI,MAAM,CAKzB;IAED,IAAI,QAAQ,IAAI,MAAM,GAAG,SAAS,CAEjC;IAED,IAAI,MAAM,IAAI,MAAM,GAAG,SAAS,CAE/B;IAED,IAAI,SAAS,IAAI,MAAM,GAAG,SAAS,CAElC;IAED,IAAI,WAAW,2DAEd;IAED,IAAI,OAAO,uBAEV;IAED,IAAI,IAAI,IAAI,SAAS,GAAG,QAAQ,GAAG,SAAS,CAE3C;gBAEW,OAAO,EAAE,2BAA2B;IAkBhD,IAAI,IAAI,IAAI,sBAAsB,CAAC,MAAM,CAAC,CAKzC;IAGD,IAAI,SAAS,IAAI,OAAO,CAEvB;IAED,IAAI,WAAW,IAAI,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,IAAI,CAEvD;IAGD,IAAI,QAAQ,IAAI,sBAAsB,GAAG,SAAS,CAKjD;IAEK,UAAU,IAAI,OAAO,CAAC,iBAAiB,GAAG,OAAO,GAAG,SAAS,CAAC;IA2DpE,OAAO,CAAC,UAAU,CAIhB;IAEF,OAAO,CAAC,YAAY,CAgClB;IAEF;;OAEG;IACH,OAAO,CAAC,uBAAuB,CAuC7B;IASF,UAAU,GAAU,OAAO,GAAG,KAAG,OAAO,CAAC,IAAI,CAAC,CAS7C;IAID,UAAU,GAAI,MAAM,cAAc,EAAE,SAAS,eAAe,KAAG,IAAI,CAMjE;IAEF,UAAU,GAAI,MAAM,cAAc,KAAG,IAAI,CAMvC;IAEF,UAAU,GAAI,MAAM,cAAc,EAAE,SAAS,eAAe,KAAG,IAAI,CAMjE;IAEF,UAAU,GAAI,MAAM,cAAc,KAAG,IAAI,CAMvC;IAEF,cAAc,GAAI,MAAM,cAAc,KAAG,IAAI,CAM5C;IAED,cAAc,GAAI,MAAM,cAAc,KAAG,IAAI,CAM3C;IAEF,UAAU,QAAO,IAAI,CAInB;IAEF,UAAU,GAAI,WAAW,OAAO,KAAG,IAAI,CAIrC;IAGF,iBAAiB,QAAa,OAAO,CAAC,GAAG,CAAC,CAKxC;IAEF,cAAc,GAAI,aAAa,MAAM,KAAG,OAAO,GAAG,MAAM,CAKtD;IAEF,4BAA4B,GAAI,SAAS,MAAM,KAAG,MAAM,CAKtD;IAEF,gBAAgB,GAAU,UAAU,qBAAqB,mBAIvD;IAEF,gBAAgB,GAAU,UAAU,qBAAqB,mBAIvD;IAEF,mBAAmB,GAAI,cAAc,MAAM,KAAG,IAAI,CAIjD;IAED,mBAAmB,GAAI,cAAc,MAAM,KAAG,IAAI,CAIhD;IAGF,IAAI,MAAM,IAAI,sBAAsB,CAAC,QAAQ,CAAC,CAgC7C;IAGD,OAAO,CAAC,eAAe;IAahB,eAAe,CAAC,QAAQ,EAAE,sBAAsB,GAAG,IAAI;IAY9D;;OAEG;IACH,yBAAyB,CAAC,QAAQ,EAAE,sBAAsB;CA+C3D;AAGD,wBAAgB,aAAa,CAAC,CAAC,EAAE,CAAC,EAAE,GAAG,GAAG,CAAC,IAAI,CAAC,CAE/C"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/lib/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAA;AAG5C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,UAEzC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export declare const internalRoutes: {
|
|
2
|
-
signUpVerify: {
|
|
3
|
-
pattern: RegExp;
|
|
4
|
-
};
|
|
5
|
-
signInVerify: {
|
|
6
|
-
pattern: RegExp;
|
|
7
|
-
};
|
|
8
|
-
};
|
|
9
|
-
export declare function isInternalRoute(pathname: string): boolean;
|
|
10
|
-
export declare function isAuthRoute(pathname: string): boolean;
|
|
11
|
-
export declare function isBaseAuthRoute(pathname: string): boolean;
|
|
12
|
-
export declare function handleInternalRoute(pathname: string): null;
|
|
13
|
-
//# sourceMappingURL=internal-route.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"internal-route.d.ts","sourceRoot":"","sources":["../../../src/route-handler/internal-route.tsx"],"names":[],"mappings":"AAGA,eAAO,MAAM,cAAc;;;;;;;CAO1B,CAAA;AAGD,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEzD;AAGD,wBAAgB,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAErD;AAGD,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEzD;AAGD,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,QAOnD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../../src/types/auth.ts"],"names":[],"mappings":""}
|
package/dist/types/types.d.ts
DELETED
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import type { TernSecureInstanceTree, TernSecureInstanceTreeOptions, TernSecureConfig, TernSecureState } from '@tern-secure/types';
|
|
2
|
-
declare global {
|
|
3
|
-
interface Window {
|
|
4
|
-
apiKey?: string;
|
|
5
|
-
customDomain?: TernSecureInstanceTree['customDomain'];
|
|
6
|
-
proxyUrl?: TernSecureInstanceTree['proxyUrl'];
|
|
7
|
-
projectId?: TernSecureInstanceTree['projectId'];
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* TernSecure User
|
|
12
|
-
*/
|
|
13
|
-
export type TernSecureUserData = {
|
|
14
|
-
uid: string;
|
|
15
|
-
email: string | null;
|
|
16
|
-
emailVerified?: boolean;
|
|
17
|
-
displayName?: string | null;
|
|
18
|
-
};
|
|
19
|
-
export interface SignInResponse {
|
|
20
|
-
success: boolean;
|
|
21
|
-
message?: string;
|
|
22
|
-
error?: any | undefined;
|
|
23
|
-
user?: any;
|
|
24
|
-
}
|
|
25
|
-
export interface AuthError extends Error {
|
|
26
|
-
code?: any | string;
|
|
27
|
-
message: string;
|
|
28
|
-
response?: SignInResponse;
|
|
29
|
-
}
|
|
30
|
-
export declare function isSignInResponse(value: any): value is SignInResponse;
|
|
31
|
-
/**
|
|
32
|
-
* Configuration validation result
|
|
33
|
-
*/
|
|
34
|
-
export interface ConfigValidationResult {
|
|
35
|
-
isValid: boolean;
|
|
36
|
-
errors: string[];
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* TernSecureAuthState
|
|
40
|
-
*/
|
|
41
|
-
export type TernSecureAuthState = {
|
|
42
|
-
userId: string | null;
|
|
43
|
-
isLoaded: boolean;
|
|
44
|
-
error: Error | null;
|
|
45
|
-
isValid: boolean;
|
|
46
|
-
isVerified: boolean;
|
|
47
|
-
isAuthenticated: boolean;
|
|
48
|
-
token: any | null;
|
|
49
|
-
email: string | null;
|
|
50
|
-
status: "loading" | "authenticated" | "unauthenticated" | "unverified";
|
|
51
|
-
requiresVerification: boolean;
|
|
52
|
-
};
|
|
53
|
-
/**
|
|
54
|
-
* TernSecureInitialState
|
|
55
|
-
*/
|
|
56
|
-
export type initialState = {
|
|
57
|
-
userId: string | null;
|
|
58
|
-
sessionId: string | undefined;
|
|
59
|
-
};
|
|
60
|
-
export interface BrowserConstructor {
|
|
61
|
-
new (customDomain?: string): Browser;
|
|
62
|
-
}
|
|
63
|
-
export interface HeadlessUIBrowserConstructor {
|
|
64
|
-
new (customDomain?: string): HeadlessUIBrowser;
|
|
65
|
-
}
|
|
66
|
-
/**
|
|
67
|
-
* TernSecureProviderProps
|
|
68
|
-
* @param interface
|
|
69
|
-
*/
|
|
70
|
-
export type TernSecureProviderProps = IsomorphicTernSecureOptions & {
|
|
71
|
-
children: React.ReactNode;
|
|
72
|
-
initialState?: TernSecureState;
|
|
73
|
-
loadingComponent?: React.ReactNode;
|
|
74
|
-
bypassApiKey?: boolean;
|
|
75
|
-
};
|
|
76
|
-
export interface HeadlessUIBrowser extends TernSecureInstanceTree {
|
|
77
|
-
load: (options?: TernSecureInstanceTreeOptions) => Promise<void>;
|
|
78
|
-
setTernAuth: (provider: any) => void;
|
|
79
|
-
}
|
|
80
|
-
export interface Browser extends HeadlessUIBrowser {
|
|
81
|
-
onComponentsReady: Promise<void>;
|
|
82
|
-
components: any;
|
|
83
|
-
}
|
|
84
|
-
export type TernSecureProps = HeadlessUIBrowserConstructor | HeadlessUIBrowser | Browser | BrowserConstructor | null | undefined;
|
|
85
|
-
export type IsomorphicTernSecureOptions = TernSecureInstanceTreeOptions & {
|
|
86
|
-
TernSecure?: TernSecureProps;
|
|
87
|
-
ternUIVersion?: string;
|
|
88
|
-
apiKey?: string;
|
|
89
|
-
customDomain?: string;
|
|
90
|
-
proxyUrl?: string;
|
|
91
|
-
projectId?: string;
|
|
92
|
-
ternSecureConfig?: TernSecureConfig;
|
|
93
|
-
};
|
|
94
|
-
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"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"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"client-init.d.ts","sourceRoot":"","sources":["../../../src/utils/client-init.ts"],"names":[],"mappings":""}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { TernSecureConfig, ConfigValidationResult, TernSecureAdminConfig, AdminConfigValidationResult } from '@tern-secure/types';
|
|
2
|
-
/**
|
|
3
|
-
* Loads Firebase configuration from environment variables
|
|
4
|
-
* @returns {TernSecureConfig} Firebase configuration object
|
|
5
|
-
*/
|
|
6
|
-
export declare const loadFireConfig: () => TernSecureConfig;
|
|
7
|
-
/**
|
|
8
|
-
* Validates Firebase configuration
|
|
9
|
-
* @param {TernSecureConfig} config - Firebase configuration object
|
|
10
|
-
* @throws {Error} If required configuration values are missing
|
|
11
|
-
* @returns {TernSecureConfig} Validated configuration object
|
|
12
|
-
*/
|
|
13
|
-
export declare const validateConfig: (config: TernSecureConfig) => ConfigValidationResult;
|
|
14
|
-
/**
|
|
15
|
-
* Initializes configuration with validation
|
|
16
|
-
* @throws {Error} If configuration is invalid
|
|
17
|
-
*/
|
|
18
|
-
export declare const initializeConfig: () => TernSecureConfig;
|
|
19
|
-
/**
|
|
20
|
-
* Loads Firebase Admin configuration from environment variables
|
|
21
|
-
* @returns {AdminConfig} Firebase Admin configuration object
|
|
22
|
-
*/
|
|
23
|
-
export declare const loadAdminConfig: () => TernSecureAdminConfig;
|
|
24
|
-
/**
|
|
25
|
-
* Validates Firebase Admin configuration
|
|
26
|
-
* @param {AdminConfig} config - Firebase Admin configuration object
|
|
27
|
-
* @returns {ConfigValidationResult} Validation result
|
|
28
|
-
*/
|
|
29
|
-
export declare const validateAdminConfig: (config: TernSecureAdminConfig) => AdminConfigValidationResult;
|
|
30
|
-
/**
|
|
31
|
-
* Initializes admin configuration with validation
|
|
32
|
-
* @throws {Error} If configuration is invalid
|
|
33
|
-
*/
|
|
34
|
-
export declare const initializeAdminConfig: () => TernSecureAdminConfig;
|
|
35
|
-
//# sourceMappingURL=config.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/utils/config.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,sBAAsB,EACtB,qBAAqB,EACrB,2BAA2B,EAC5B,MAAM,oBAAoB,CAAA;AAE3B;;;GAGG;AACH,eAAO,MAAM,cAAc,QAAO,gBAQhC,CAAA;AAEF;;;;;GAKG;AACH,eAAO,MAAM,cAAc,GAAI,QAAQ,gBAAgB,KAAG,sBAuBzD,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,gBAAgB,QAAO,gBAWnC,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,eAAe,QAAO,qBAIjC,CAAA;AAEF;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,GAAI,QAAQ,qBAAqB,KAAG,2BAoBnE,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,qBAAqB,QAAO,qBAWxC,CAAA"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Constructs a full URL with the current origin
|
|
3
|
-
* @param path - The path to construct the URL for
|
|
4
|
-
* @returns The full URL with origin
|
|
5
|
-
*/
|
|
6
|
-
export declare const constructFullUrl: (path: string) => string;
|
|
7
|
-
/**
|
|
8
|
-
* Checks if the current URL has a redirect loop
|
|
9
|
-
* @param currentPath - The current pathname
|
|
10
|
-
* @param redirectPath - The path we're trying to redirect to
|
|
11
|
-
* @returns boolean indicating if there's a redirect loop
|
|
12
|
-
*/
|
|
13
|
-
export declare const hasRedirectLoop: (currentPath: string, redirectPath: string) => boolean;
|
|
14
|
-
/**
|
|
15
|
-
* Constructs a URL with redirect parameters while preventing loops
|
|
16
|
-
* @param path - The base path (usually login path)
|
|
17
|
-
* @param redirectUrl - The URL to redirect to after action completes
|
|
18
|
-
* @param loginPath - The login path to check against
|
|
19
|
-
* @param signUpPath - The sign up path to check against
|
|
20
|
-
* @returns The full URL with redirect parameters
|
|
21
|
-
*/
|
|
22
|
-
export declare const constructUrlWithRedirect: (path: string, redirectUrl: string | undefined) => string;
|
|
23
|
-
/**
|
|
24
|
-
* Stores the current path before signing out
|
|
25
|
-
*/
|
|
26
|
-
export declare const storePreviousPath: (path: string) => void;
|
|
27
|
-
/**
|
|
28
|
-
* Gets the stored previous path
|
|
29
|
-
*/
|
|
30
|
-
export declare const getPreviousPath: () => string | null;
|
|
31
|
-
/**
|
|
32
|
-
* Gets a validated redirect URL ensuring it's from the same origin
|
|
33
|
-
* @param redirectUrl - The URL to validate
|
|
34
|
-
* @param searchParams - The search parameters to check for redirect
|
|
35
|
-
* @returns A validated redirect URL
|
|
36
|
-
*/
|
|
37
|
-
export declare const getValidRedirectUrl: (searchParams: URLSearchParams, configuredRedirect?: string) => string;
|
|
38
|
-
//# sourceMappingURL=construct.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"construct.d.ts","sourceRoot":"","sources":["../../../src/utils/construct.ts"],"names":[],"mappings":"AAIA;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,GAAI,MAAM,MAAM,WAO1C,CAAA;AAGH;;;;;GAKG;AACH,eAAO,MAAM,eAAe,GAAI,aAAa,MAAM,EAAE,cAAc,MAAM,KAAG,OAQ3E,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,wBAAwB,GACnC,MAAM,MAAM,EACZ,aAAa,MAAM,GAAG,SAAS,KAC9B,MAQF,CAAA;AAED;;GAEG;AACH,eAAO,MAAM,iBAAiB,GAAI,MAAM,MAAM,KAAG,IAIhD,CAAA;AAED;;GAEG;AACH,eAAO,MAAM,eAAe,QAAO,MAAM,GAAG,IAK3C,CAAA;AAID;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB,GAC9B,cAAc,eAAe,EAC7B,qBAAqB,MAAM,KAC1B,MAcF,CAAA"}
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
export declare const defaultClassNames: {
|
|
2
|
-
readonly container: "tern-container";
|
|
3
|
-
readonly header: "tern-header";
|
|
4
|
-
readonly title: "tern-title";
|
|
5
|
-
readonly formWrapper: "tern-formWrapper";
|
|
6
|
-
readonly formContainer: "tern-formContainer";
|
|
7
|
-
readonly form: "tern-form";
|
|
8
|
-
readonly label: "tern-label";
|
|
9
|
-
readonly input: "tern-input";
|
|
10
|
-
readonly button: "tern-button";
|
|
11
|
-
readonly error: "tern-error";
|
|
12
|
-
};
|
|
13
|
-
export declare const styleConfig: {
|
|
14
|
-
readonly container: {
|
|
15
|
-
readonly display: "flex";
|
|
16
|
-
readonly minHeight: "100%";
|
|
17
|
-
readonly flex: "1";
|
|
18
|
-
readonly flexDirection: "column";
|
|
19
|
-
readonly justifyContent: "center";
|
|
20
|
-
readonly padding: "3rem 1.5rem";
|
|
21
|
-
};
|
|
22
|
-
readonly header: {
|
|
23
|
-
readonly margin: "0 auto";
|
|
24
|
-
readonly width: "100%";
|
|
25
|
-
readonly maxWidth: "28rem";
|
|
26
|
-
};
|
|
27
|
-
readonly title: {
|
|
28
|
-
readonly marginTop: "1.5rem";
|
|
29
|
-
readonly textAlign: "center";
|
|
30
|
-
readonly fontSize: "1.875rem";
|
|
31
|
-
readonly fontWeight: "700";
|
|
32
|
-
readonly lineHeight: "2.25rem";
|
|
33
|
-
readonly letterSpacing: "-0.025em";
|
|
34
|
-
readonly color: "var(--tern-text-primary, #111827)";
|
|
35
|
-
};
|
|
36
|
-
readonly formWrapper: {
|
|
37
|
-
readonly marginTop: "2.5rem";
|
|
38
|
-
readonly margin: "0 auto";
|
|
39
|
-
readonly width: "100%";
|
|
40
|
-
readonly maxWidth: "30rem";
|
|
41
|
-
};
|
|
42
|
-
readonly formContainer: {
|
|
43
|
-
readonly padding: "3rem 1.5rem";
|
|
44
|
-
readonly boxShadow: "0 1px 3px 0 rgb(0 0 0 / 0.1)";
|
|
45
|
-
readonly borderRadius: "0.5rem";
|
|
46
|
-
readonly backgroundColor: "var(--tern-background, white)";
|
|
47
|
-
};
|
|
48
|
-
readonly form: {
|
|
49
|
-
readonly display: "flex";
|
|
50
|
-
readonly flexDirection: "column";
|
|
51
|
-
readonly gap: "1rem";
|
|
52
|
-
};
|
|
53
|
-
readonly label: {
|
|
54
|
-
readonly display: "block";
|
|
55
|
-
readonly fontSize: "0.875rem";
|
|
56
|
-
readonly fontWeight: "500";
|
|
57
|
-
readonly color: "var(--tern-text-secondary, #374151)";
|
|
58
|
-
};
|
|
59
|
-
readonly input: {
|
|
60
|
-
readonly marginTop: "0.25rem";
|
|
61
|
-
readonly display: "block";
|
|
62
|
-
readonly width: "100%";
|
|
63
|
-
readonly padding: "0.5rem 0.75rem";
|
|
64
|
-
readonly borderRadius: "0.375rem";
|
|
65
|
-
readonly border: "1px solid var(--tern-border, #D1D5DB)";
|
|
66
|
-
readonly backgroundColor: "var(--tern-input-background, white)";
|
|
67
|
-
readonly color: "var(--tern-text-primary, #111827)";
|
|
68
|
-
};
|
|
69
|
-
readonly button: {
|
|
70
|
-
readonly display: "flex";
|
|
71
|
-
readonly width: "100%";
|
|
72
|
-
readonly justifyContent: "center";
|
|
73
|
-
readonly padding: "0.5rem 1rem";
|
|
74
|
-
readonly fontSize: "0.875rem";
|
|
75
|
-
readonly fontWeight: "500";
|
|
76
|
-
readonly color: "white";
|
|
77
|
-
readonly backgroundColor: "var(--tern-primary, #2563EB)";
|
|
78
|
-
readonly border: "none";
|
|
79
|
-
readonly borderRadius: "0.375rem";
|
|
80
|
-
readonly cursor: "pointer";
|
|
81
|
-
};
|
|
82
|
-
readonly error: {
|
|
83
|
-
readonly color: "var(--tern-error, #DC2626)";
|
|
84
|
-
readonly fontSize: "0.875rem";
|
|
85
|
-
};
|
|
86
|
-
};
|
|
87
|
-
export declare const styles: {
|
|
88
|
-
readonly container: "tern-container";
|
|
89
|
-
readonly header: "tern-header";
|
|
90
|
-
readonly title: "tern-title";
|
|
91
|
-
readonly formWrapper: "tern-formWrapper";
|
|
92
|
-
readonly formContainer: "tern-formContainer";
|
|
93
|
-
readonly form: "tern-form";
|
|
94
|
-
readonly label: "tern-label";
|
|
95
|
-
readonly input: "tern-input";
|
|
96
|
-
readonly button: "tern-button";
|
|
97
|
-
readonly error: "tern-error";
|
|
98
|
-
};
|
|
99
|
-
//# sourceMappingURL=create-styles.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"create-styles.d.ts","sourceRoot":"","sources":["../../../src/utils/create-styles.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,iBAAiB;;;;;;;;;;;CAWpB,CAAA;AAwCV,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyEd,CAAA;AAGV,eAAO,MAAM,MAAM;;;;;;;;;;;CAAgC,CAAA"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { TernSecureUser } from '@tern-secure/types';
|
|
2
|
-
interface LogContext {
|
|
3
|
-
component: string;
|
|
4
|
-
action: string;
|
|
5
|
-
data?: any;
|
|
6
|
-
}
|
|
7
|
-
export declare const debugLog: (context: LogContext) => void;
|
|
8
|
-
export declare const logAuthState: (component: string, user: TernSecureUser | null, isValid: boolean, isVerified: boolean) => void;
|
|
9
|
-
export declare const logSessionState: (component: string, token: string | null, expirationTime: number | null) => void;
|
|
10
|
-
export declare const logLifecycle: (component: string, lifecycle: string, props?: any) => void;
|
|
11
|
-
export declare const logError: (component: string, error: Error | unknown) => void;
|
|
12
|
-
export {};
|
|
13
|
-
//# sourceMappingURL=debug.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"debug.d.ts","sourceRoot":"","sources":["../../../src/utils/debug.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA;AAMnD,UAAU,UAAU;IAClB,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,GAAG,CAAA;CACX;AAED,eAAO,MAAM,QAAQ,GAAI,SAAS,UAAU,SAO3C,CAAA;AAED,eAAO,MAAM,YAAY,GAAI,WAAW,MAAM,EAAE,MAAM,cAAc,GAAG,IAAI,EAAE,SAAS,OAAO,EAAE,YAAY,OAAO,SAcjH,CAAA;AAED,eAAO,MAAM,eAAe,GAAI,WAAW,MAAM,EAAE,OAAO,MAAM,GAAG,IAAI,EAAE,gBAAgB,MAAM,GAAG,IAAI,SAUrG,CAAA;AAED,eAAO,MAAM,YAAY,GAAI,WAAW,MAAM,EAAE,WAAW,MAAM,EAAE,QAAQ,GAAG,SAM7E,CAAA;AAED,eAAO,MAAM,QAAQ,GAAI,WAAW,MAAM,EAAE,OAAO,KAAK,GAAG,OAAO,SAUjE,CAAA"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Validates and sanitizes redirect URLs
|
|
3
|
-
*/
|
|
4
|
-
export declare function validateRedirectUrl(url: string | null): Promise<string>;
|
|
5
|
-
/**
|
|
6
|
-
* Gets the current path for redirect purposes
|
|
7
|
-
*/
|
|
8
|
-
export declare function getCurrentPath(): Promise<string>;
|
|
9
|
-
//# sourceMappingURL=redirect.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"redirect.d.ts","sourceRoot":"","sources":["../../../src/utils/redirect.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,wBAAsB,mBAAmB,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAwB7E;AAED;;GAEG;AACH,wBAAsB,cAAc,IAAI,OAAO,CAAC,MAAM,CAAC,CAQtD"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=client-init.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|