@machinemetrics/mm-react-tools 5.2.0-0 → 5.2.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.
- package/dist/Authorized.d.ts.map +1 -1
- package/dist/MMApolloLinkProvider.d.ts.map +1 -1
- package/dist/MMContext.d.ts +21 -4
- package/dist/MMContext.d.ts.map +1 -1
- package/dist/MMEmbeddedAppProvider.d.ts.map +1 -1
- package/dist/MMProvider.d.ts +5 -1
- package/dist/MMProvider.d.ts.map +1 -1
- package/dist/PrivateLayout.d.ts.map +1 -1
- package/dist/apiJwt.d.ts +21 -10
- package/dist/apiJwt.d.ts.map +1 -1
- package/dist/credentialError.d.ts +14 -0
- package/dist/credentialError.d.ts.map +1 -0
- package/dist/credentialWait.d.ts +12 -0
- package/dist/credentialWait.d.ts.map +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/mm-react-tools.es.js +8112 -8003
- package/dist/utils.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/Authorized.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Authorized.d.ts","sourceRoot":"","sources":["../src/Authorized.tsx"],"names":[],"mappings":"AAgBA,QAAA,MAAM,IAAI,GAAI,eAAe,GAAG,
|
|
1
|
+
{"version":3,"file":"Authorized.d.ts","sourceRoot":"","sources":["../src/Authorized.tsx"],"names":[],"mappings":"AAgBA,QAAA,MAAM,IAAI,GAAI,eAAe,GAAG,4CAmC/B,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MMApolloLinkProvider.d.ts","sourceRoot":"","sources":["../src/MMApolloLinkProvider.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MMApolloLinkProvider.d.ts","sourceRoot":"","sources":["../src/MMApolloLinkProvider.tsx"],"names":[],"mappings":"AAsBA,QAAA,MAAM,oBAAoB,+CA8HzB,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
|
package/dist/MMContext.d.ts
CHANGED
|
@@ -24,8 +24,17 @@ export interface MMUrls {
|
|
|
24
24
|
*/
|
|
25
25
|
export type MMRequestOptions = RequestInit;
|
|
26
26
|
/**
|
|
27
|
-
* Authenticated fetch helper.
|
|
28
|
-
*
|
|
27
|
+
* Authenticated fetch helper. Sends the API JWT as bearer and resolves with
|
|
28
|
+
* the parsed JSON response body.
|
|
29
|
+
*
|
|
30
|
+
* A `401` on a `GET` mints a new JWT and replays once; a second `401` signs
|
|
31
|
+
* the user out and throws `Error('UNAUTHORIZED')`. A `401` on any other
|
|
32
|
+
* method throws `UNAUTHORIZED` without signing out. When no JWT can be
|
|
33
|
+
* minted, throws a `CredentialError` whose message and `code` are the
|
|
34
|
+
* server's error code (e.g. `jwt_bearer_not_allowed`) with the HTTP `status`,
|
|
35
|
+
* or `api_credential_unavailable` with status 0 when there is no server
|
|
36
|
+
* verdict. With no access token at all, throws `UNAUTHORIZED`.
|
|
37
|
+
*
|
|
29
38
|
* Generic so consumers can write `request<MyType>(url)` as they do today.
|
|
30
39
|
*/
|
|
31
40
|
export type MMRequest = <T = any>(url: string, options?: MMRequestOptions) => Promise<T>;
|
|
@@ -35,13 +44,21 @@ export type MMRequest = <T = any>(url: string, options?: MMRequestOptions) => Pr
|
|
|
35
44
|
export interface MMContextValue {
|
|
36
45
|
/** The OAuth client id passed to `MMProvider`. */
|
|
37
46
|
clientId: string;
|
|
38
|
-
/**
|
|
47
|
+
/**
|
|
48
|
+
* The credential held for a purpose ('api' | 'graphql' | 'nats'), or null
|
|
49
|
+
* when none is held. The value is served as-is until it is replaced or
|
|
50
|
+
* cleared; read it per use rather than caching it.
|
|
51
|
+
*/
|
|
39
52
|
getCredential: (purpose: CredentialPurpose) => string | null;
|
|
40
53
|
/** Subscribe to credential-store changes (for the reactive `useCredential`). */
|
|
41
54
|
subscribeCredentials: (listener: () => void) => () => void;
|
|
42
55
|
/** Scopes actually granted, if known. */
|
|
43
56
|
grantedScope?: string | null;
|
|
44
|
-
/**
|
|
57
|
+
/**
|
|
58
|
+
* True once the first API JWT has landed, minted from the access token or
|
|
59
|
+
* pushed by a host. Stays true while the access token is held, even across
|
|
60
|
+
* a failed refresh; `logout` or a rejected token resets it to false.
|
|
61
|
+
*/
|
|
45
62
|
isAuthenticated: boolean;
|
|
46
63
|
/** Redirects the browser to the MachineMetrics OAuth login page. */
|
|
47
64
|
login: (opts?: Record<string, unknown>) => void;
|
package/dist/MMContext.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MMContext.d.ts","sourceRoot":"","sources":["../src/MMContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAE3D;;;;;;;;GAQG;AACH,MAAM,WAAW,MAAM;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;CACnC;AAED;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,WAAW,CAAC;AAE3C
|
|
1
|
+
{"version":3,"file":"MMContext.d.ts","sourceRoot":"","sources":["../src/MMContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAE3D;;;;;;;;GAQG;AACH,MAAM,WAAW,MAAM;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;CACnC;AAED;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,WAAW,CAAC;AAE3C;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,GAAG,GAAG,EAC9B,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE,gBAAgB,KACvB,OAAO,CAAC,CAAC,CAAC,CAAC;AAEhB;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,kDAAkD;IAClD,QAAQ,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,aAAa,EAAE,CAAC,OAAO,EAAE,iBAAiB,KAAK,MAAM,GAAG,IAAI,CAAC;IAC7D,gFAAgF;IAChF,oBAAoB,EAAE,CAAC,QAAQ,EAAE,MAAM,IAAI,KAAK,MAAM,IAAI,CAAC;IAC3D,yCAAyC;IACzC,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B;;;;OAIG;IACH,eAAe,EAAE,OAAO,CAAC;IACzB,oEAAoE;IACpE,KAAK,EAAE,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;IAChD,yDAAyD;IACzD,MAAM,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC5B,0DAA0D;IAC1D,OAAO,EAAE,SAAS,CAAC;IACnB,yDAAyD;IACzD,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;;GAIG;AACH,MAAM,MAAM,YAAY,GAAG,cAAc,CAAC;;AAE1C,wBAA0E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MMEmbeddedAppProvider.d.ts","sourceRoot":"","sources":["../src/MMEmbeddedAppProvider.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MMEmbeddedAppProvider.d.ts","sourceRoot":"","sources":["../src/MMEmbeddedAppProvider.tsx"],"names":[],"mappings":"AAsBA,eAAO,MAAM,yBAAyB,UAAmB,CAAC;AAK1D,QAAA,MAAM,qBAAqB,+CAsvB1B,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
package/dist/MMProvider.d.ts
CHANGED
|
@@ -14,7 +14,11 @@ export interface MMProviderProps {
|
|
|
14
14
|
* `string` (e.g. from JSON config) is also accepted and validated at runtime.
|
|
15
15
|
*/
|
|
16
16
|
releaseStage: MMReleaseStage | (string & {});
|
|
17
|
-
/**
|
|
17
|
+
/**
|
|
18
|
+
* How often the GraphQL JWT is refreshed. Defaults to 4.5 minutes. The API
|
|
19
|
+
* JWT refreshes from its own `exp` and falls back to this cadence only when
|
|
20
|
+
* `exp` cannot be read.
|
|
21
|
+
*/
|
|
18
22
|
refreshJwtIntervalMs?: number;
|
|
19
23
|
/** Optional device identifier forwarded to the login page. */
|
|
20
24
|
device?: string;
|
package/dist/MMProvider.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MMProvider.d.ts","sourceRoot":"","sources":["../src/MMProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAON,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"MMProvider.d.ts","sourceRoot":"","sources":["../src/MMProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAON,MAAM,OAAO,CAAC;AA8Bf,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAG1C,MAAM,MAAM,cAAc,GACtB,YAAY,GACZ,UAAU,GACV,SAAS,GACT,aAAa,CAAC;AAsDlB,MAAM,WAAW,eAAe;IAC9B,uEAAuE;IACvE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,2CAA2C;IAC3C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,uBAAuB;IACvB,QAAQ,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,YAAY,EAAE,cAAc,GAAG,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC;IAC7C;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,8DAA8D;IAC9D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,4DAA4D;IAC5D,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,0DAA0D;IAC1D,IAAI,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,CAAC;CACxB;AAED,QAAA,MAAM,UAAU,GAAI,0IAWjB,eAAe,4CA4bjB,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrivateLayout.d.ts","sourceRoot":"","sources":["../src/PrivateLayout.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PrivateLayout.d.ts","sourceRoot":"","sources":["../src/PrivateLayout.tsx"],"names":[],"mappings":"AAiBA,QAAA,MAAM,aAAa,+CAsBlB,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
package/dist/apiJwt.d.ts
CHANGED
|
@@ -1,34 +1,45 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/** Lead time before `exp` at which the next mint is scheduled. */
|
|
2
2
|
export declare const JWT_EXPIRY_MARGIN_MS: number;
|
|
3
|
-
/**
|
|
3
|
+
/** Least remaining life a held JWT needs to be sent on a request. */
|
|
4
|
+
export declare const JWT_IN_TRANSIT_MARGIN_MS: number;
|
|
5
|
+
/** How long a transient mint failure suppresses the next attempt. */
|
|
4
6
|
export declare const MINT_BACKOFF_MS: number;
|
|
5
7
|
/** The `exp` claim in seconds, or null when the token cannot be parsed. */
|
|
6
8
|
export declare const parseJwtExp: (token: unknown) => number | null;
|
|
7
|
-
export declare const isJwtFresh: (token: unknown, now?: number) => token is string;
|
|
9
|
+
export declare const isJwtFresh: (token: unknown, now?: number, marginMs?: number) => token is string;
|
|
10
|
+
/** A refusal from `/user-token` that will repeat for the same access token. */
|
|
11
|
+
export interface ApiJwtMintFailure {
|
|
12
|
+
status: number;
|
|
13
|
+
code: string;
|
|
14
|
+
}
|
|
8
15
|
export interface ApiJwtControllerOptions {
|
|
9
16
|
getApiUrl: () => string;
|
|
10
17
|
/** The private access token, or null when a mint must not run. */
|
|
11
18
|
getAccessToken: () => string | null | undefined;
|
|
12
19
|
/** Called when /user-token answers 401: the access token is no longer valid. */
|
|
13
20
|
onAccessTokenRejected: () => void;
|
|
21
|
+
/** Called with the refusal when a mint is refused, and with null once it is forgotten. */
|
|
22
|
+
onMintFailure?: (failure: ApiJwtMintFailure | null) => void;
|
|
14
23
|
read: () => string | null;
|
|
15
24
|
write: (jwt: string | null) => void;
|
|
25
|
+
/** Refresh cadence used only when the minted JWT carries no readable `exp`. */
|
|
26
|
+
fallbackRefreshMs?: () => number;
|
|
16
27
|
now?: () => number;
|
|
17
28
|
fetchJson?: (url: string, options: RequestInit) => Promise<any>;
|
|
18
29
|
}
|
|
19
30
|
export interface ApiJwtController {
|
|
20
|
-
/** The
|
|
31
|
+
/** The held JWT, minted or pushed, or null when none is held. No side effects. */
|
|
21
32
|
current(): string | null;
|
|
22
|
-
/** Like `current()`, but a stale or missing JWT starts a mint in the background. */
|
|
23
|
-
peek(): string | null;
|
|
24
33
|
/** Fetch a new JWT. Concurrent callers share one request; resolves null on failure or during backoff. */
|
|
25
34
|
mint(): Promise<string | null>;
|
|
26
|
-
/** A
|
|
35
|
+
/** A JWT fit to send: the held one while it has life left, else a freshly minted one, else whatever is held. */
|
|
27
36
|
fresh(): Promise<string | null>;
|
|
28
|
-
/** Forget the
|
|
37
|
+
/** Forget the held JWT and any recorded refusal without ending the session. */
|
|
29
38
|
invalidate(): void;
|
|
30
|
-
/** Sign-out: forget the JWT, discard in-flight results,
|
|
39
|
+
/** Sign-out: forget the JWT, discard in-flight results, cancel the schedule. */
|
|
31
40
|
clear(): void;
|
|
41
|
+
/** The refusal blocking mints for the current access token, if any. */
|
|
42
|
+
failure(): ApiJwtMintFailure | null;
|
|
32
43
|
}
|
|
33
|
-
export declare const createApiJwtController: ({ getApiUrl, getAccessToken, onAccessTokenRejected, read, write, now, fetchJson, }: ApiJwtControllerOptions) => ApiJwtController;
|
|
44
|
+
export declare const createApiJwtController: ({ getApiUrl, getAccessToken, onAccessTokenRejected, onMintFailure, read, write, fallbackRefreshMs, now, fetchJson, }: ApiJwtControllerOptions) => ApiJwtController;
|
|
34
45
|
//# sourceMappingURL=apiJwt.d.ts.map
|
package/dist/apiJwt.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apiJwt.d.ts","sourceRoot":"","sources":["../src/apiJwt.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"apiJwt.d.ts","sourceRoot":"","sources":["../src/apiJwt.ts"],"names":[],"mappings":"AAGA,kEAAkE;AAClE,eAAO,MAAM,oBAAoB,QAAY,CAAC;AAE9C,qEAAqE;AACrE,eAAO,MAAM,wBAAwB,QAAW,CAAC;AAEjD,qEAAqE;AACrE,eAAO,MAAM,eAAe,QAAY,CAAC;AAUzC,2EAA2E;AAC3E,eAAO,MAAM,WAAW,GAAI,OAAO,OAAO,KAAG,MAAM,GAAG,IAcrD,CAAC;AAEF,eAAO,MAAM,UAAU,GACrB,OAAO,OAAO,EACd,MAAK,MAAmB,EACxB,WAAU,MAA6B,KACtC,KAAK,IAAI,MAGX,CAAC;AAEF,+EAA+E;AAC/E,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,uBAAuB;IACtC,SAAS,EAAE,MAAM,MAAM,CAAC;IACxB,kEAAkE;IAClE,cAAc,EAAE,MAAM,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IAChD,gFAAgF;IAChF,qBAAqB,EAAE,MAAM,IAAI,CAAC;IAClC,0FAA0F;IAC1F,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,iBAAiB,GAAG,IAAI,KAAK,IAAI,CAAC;IAC5D,IAAI,EAAE,MAAM,MAAM,GAAG,IAAI,CAAC;IAC1B,KAAK,EAAE,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAC;IACpC,+EAA+E;IAC/E,iBAAiB,CAAC,EAAE,MAAM,MAAM,CAAC;IACjC,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,WAAW,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;CACjE;AAED,MAAM,WAAW,gBAAgB;IAC/B,kFAAkF;IAClF,OAAO,IAAI,MAAM,GAAG,IAAI,CAAC;IACzB,yGAAyG;IACzG,IAAI,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAC/B,gHAAgH;IAChH,KAAK,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAChC,+EAA+E;IAC/E,UAAU,IAAI,IAAI,CAAC;IACnB,gFAAgF;IAChF,KAAK,IAAI,IAAI,CAAC;IACd,uEAAuE;IACvE,OAAO,IAAI,iBAAiB,GAAG,IAAI,CAAC;CACrC;AAUD,eAAO,MAAM,sBAAsB,GAAI,sHAUpC,uBAAuB,KAAG,gBAgK5B,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A credential could not be obtained. `message` and `code` carry the server's
|
|
3
|
+
* error code when it sent one, else a library code; `status` is the HTTP
|
|
4
|
+
* status of the refusal, or 0 when no server verdict exists.
|
|
5
|
+
*/
|
|
6
|
+
export declare class CredentialError extends Error {
|
|
7
|
+
code: string;
|
|
8
|
+
status: number;
|
|
9
|
+
constructor(code: string, status: number);
|
|
10
|
+
}
|
|
11
|
+
export declare const API_CREDENTIAL_UNAVAILABLE = "api_credential_unavailable";
|
|
12
|
+
export declare const CREDENTIAL_TIMEOUT = "credential_timeout";
|
|
13
|
+
export declare const UNAUTHORIZED = "UNAUTHORIZED";
|
|
14
|
+
//# sourceMappingURL=credentialError.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"credentialError.d.ts","sourceRoot":"","sources":["../src/credentialError.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,qBAAa,eAAgB,SAAQ,KAAK;IACxC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;gBAEH,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;CAMzC;AAED,eAAO,MAAM,0BAA0B,+BAA+B,CAAC;AACvE,eAAO,MAAM,kBAAkB,uBAAuB,CAAC;AACvD,eAAO,MAAM,YAAY,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/** How long a request waits for a credential that has not landed yet. */
|
|
2
|
+
export declare const CREDENTIAL_WAIT_TIMEOUT_MS: number;
|
|
3
|
+
export interface WaitForCredentialOptions {
|
|
4
|
+
read: () => string | null;
|
|
5
|
+
subscribe: (listener: () => void) => () => void;
|
|
6
|
+
/** Checked on each store change; true rejects the wait. */
|
|
7
|
+
isSignedOut?: () => boolean;
|
|
8
|
+
timeoutMs?: number;
|
|
9
|
+
}
|
|
10
|
+
/** Resolves with the credential as soon as the store holds one. */
|
|
11
|
+
export declare const waitForCredential: ({ read, subscribe, isSignedOut, timeoutMs, }: WaitForCredentialOptions) => Promise<string>;
|
|
12
|
+
//# sourceMappingURL=credentialWait.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"credentialWait.d.ts","sourceRoot":"","sources":["../src/credentialWait.ts"],"names":[],"mappings":"AAMA,yEAAyE;AACzE,eAAO,MAAM,0BAA0B,QAAY,CAAC;AAEpD,MAAM,WAAW,wBAAwB;IACvC,IAAI,EAAE,MAAM,MAAM,GAAG,IAAI,CAAC;IAC1B,SAAS,EAAE,CAAC,QAAQ,EAAE,MAAM,IAAI,KAAK,MAAM,IAAI,CAAC;IAChD,2DAA2D;IAC3D,WAAW,CAAC,EAAE,MAAM,OAAO,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,mEAAmE;AACnE,eAAO,MAAM,iBAAiB,GAAI,8CAK/B,wBAAwB,KAAG,OAAO,CAAC,MAAM,CA2B3C,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -2,8 +2,9 @@ import PrivateLayout from './PrivateLayout';
|
|
|
2
2
|
import MMProvider from './MMProvider';
|
|
3
3
|
import { useEventStream } from './eventStream';
|
|
4
4
|
import Link from './Link';
|
|
5
|
+
import { CredentialError } from './credentialError';
|
|
5
6
|
import { useAsyncEffect, useAsyncInterval, useApiRequest, useProductionQuery, useDowntimeQuery, useMMAuth, useCredential, useMMTemplates, useQuantityStream, useSearchParamsState, _useMMApolloLinkContext, useMMAppParams, useMMAppCommands, useMMAppContext, useMMAppInfo, useMMAppSetting, useMMAppCustomInputOpen, useMMAppCustomInputSave, useMMAppCustomInputLabel, useMMAppSetClaims, useMMAppModalSave } from './hooks';
|
|
6
|
-
export { _useMMApolloLinkContext, useMMAuth, useCredential, useMMAppParams, useMMAppCommands, useMMAppContext, useMMAppInfo, useMMAppSetting, useMMAppCustomInputOpen, useMMAppCustomInputSave, useMMAppCustomInputLabel, useMMAppSetClaims, useMMAppModalSave, useMMTemplates, PrivateLayout, useAsyncEffect, useAsyncInterval, useApiRequest, useProductionQuery, useDowntimeQuery, useQuantityStream, useSearchParamsState, MMProvider, Link, useEventStream, };
|
|
7
|
+
export { _useMMApolloLinkContext, useMMAuth, useCredential, useMMAppParams, useMMAppCommands, useMMAppContext, useMMAppInfo, useMMAppSetting, useMMAppCustomInputOpen, useMMAppCustomInputSave, useMMAppCustomInputLabel, useMMAppSetClaims, useMMAppModalSave, useMMTemplates, PrivateLayout, useAsyncEffect, useAsyncInterval, useApiRequest, useProductionQuery, useDowntimeQuery, useQuantityStream, useSearchParamsState, MMProvider, Link, useEventStream, CredentialError, };
|
|
7
8
|
export type { MMContextValue, MMAuthResult, MMUrls, MMRequest, MMRequestOptions, } from './MMContext';
|
|
8
9
|
export type { MMProviderProps, MMReleaseStage } from './MMProvider';
|
|
9
10
|
export type { UseApiRequestOptions, UseApiRequestResult } from './hooks';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,iBAAiB,CAAC;AAC5C,OAAO,UAAU,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,IAAI,MAAM,QAAQ,CAAC;AAC1B,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,aAAa,EACb,kBAAkB,EAClB,gBAAgB,EAChB,SAAS,EACT,aAAa,EACb,cAAc,EACd,iBAAiB,EACjB,oBAAoB,EACpB,uBAAuB,EACvB,cAAc,EACd,gBAAgB,EAChB,eAAe,EACf,YAAY,EACZ,eAAe,EACf,uBAAuB,EACvB,uBAAuB,EACvB,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EAClB,MAAM,SAAS,CAAC;AAEjB,OAAO,EACL,uBAAuB,EACvB,SAAS,EACT,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,eAAe,EACf,YAAY,EACZ,eAAe,EACf,uBAAuB,EACvB,uBAAuB,EACvB,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EACjB,cAAc,EACd,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,aAAa,EACb,kBAAkB,EAClB,gBAAgB,EAChB,iBAAiB,EACjB,oBAAoB,EACpB,UAAU,EACV,IAAI,EACJ,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,iBAAiB,CAAC;AAC5C,OAAO,UAAU,MAAM,cAAc,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/C,OAAO,IAAI,MAAM,QAAQ,CAAC;AAC1B,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,aAAa,EACb,kBAAkB,EAClB,gBAAgB,EAChB,SAAS,EACT,aAAa,EACb,cAAc,EACd,iBAAiB,EACjB,oBAAoB,EACpB,uBAAuB,EACvB,cAAc,EACd,gBAAgB,EAChB,eAAe,EACf,YAAY,EACZ,eAAe,EACf,uBAAuB,EACvB,uBAAuB,EACvB,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EAClB,MAAM,SAAS,CAAC;AAEjB,OAAO,EACL,uBAAuB,EACvB,SAAS,EACT,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,eAAe,EACf,YAAY,EACZ,eAAe,EACf,uBAAuB,EACvB,uBAAuB,EACvB,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EACjB,cAAc,EACd,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,aAAa,EACb,kBAAkB,EAClB,gBAAgB,EAChB,iBAAiB,EACjB,oBAAoB,EACpB,UAAU,EACV,IAAI,EACJ,cAAc,EACd,eAAe,GAChB,CAAC;AAEF,YAAY,EACV,cAAc,EACd,YAAY,EACZ,MAAM,EACN,SAAS,EACT,gBAAgB,GACjB,MAAM,aAAa,CAAC;AACrB,YAAY,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AACpE,YAAY,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC"}
|