@mindly/ui-components 6.6.0-dev.9 → 6.6.1-dev.1
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.
|
@@ -14,8 +14,6 @@
|
|
|
14
14
|
* use `waitForReady()` or `getIsReady()` to ensure auth is initialized before making requests
|
|
15
15
|
*
|
|
16
16
|
* ## Example:
|
|
17
|
-
*
|
|
18
|
-
* ```typescript
|
|
19
17
|
* // In UI library (AuthProvider):
|
|
20
18
|
* globalAuthState.setReady(); // Called after auth initialization
|
|
21
19
|
*
|
|
@@ -26,7 +24,6 @@
|
|
|
26
24
|
* if (globalAuthState.getIsReady()) {
|
|
27
25
|
* // Proceed with auth-dependent operations
|
|
28
26
|
* }
|
|
29
|
-
* ```
|
|
30
27
|
*
|
|
31
28
|
* ## Thread Safety:
|
|
32
29
|
* This class is designed to be safe for concurrent access. Multiple consumers can wait
|
|
@@ -49,10 +46,8 @@ declare class GlobalAuthState {
|
|
|
49
46
|
* This method is idempotent - calling it multiple times has no additional effect.
|
|
50
47
|
*
|
|
51
48
|
* @example
|
|
52
|
-
* ```typescript
|
|
53
49
|
* // In AuthProvider after successful initialization
|
|
54
50
|
* globalAuthState.setReady();
|
|
55
|
-
* ```
|
|
56
51
|
*/
|
|
57
52
|
setReady(): void;
|
|
58
53
|
/**
|
|
@@ -67,7 +62,6 @@ declare class GlobalAuthState {
|
|
|
67
62
|
* @returns Promise that resolves when authentication is ready
|
|
68
63
|
*
|
|
69
64
|
* @example
|
|
70
|
-
* ```typescript
|
|
71
65
|
* // In HTTP interceptor
|
|
72
66
|
* async function makeAuthenticatedRequest(url: string) {
|
|
73
67
|
* await globalAuthState.waitForReady();
|
|
@@ -79,7 +73,6 @@ declare class GlobalAuthState {
|
|
|
79
73
|
* await globalAuthState.waitForReady();
|
|
80
74
|
* // Now safe to make authenticated API calls
|
|
81
75
|
* }
|
|
82
|
-
* ```
|
|
83
76
|
*/
|
|
84
77
|
waitForReady(): Promise<void>;
|
|
85
78
|
/**
|
|
@@ -91,7 +84,6 @@ declare class GlobalAuthState {
|
|
|
91
84
|
* @returns `true` if authentication is ready, `false` otherwise
|
|
92
85
|
*
|
|
93
86
|
* @example
|
|
94
|
-
* ```typescript
|
|
95
87
|
* // In a synchronous context
|
|
96
88
|
* function canMakeAuthRequest(): boolean {
|
|
97
89
|
* return globalAuthState.getIsReady();
|
|
@@ -105,7 +97,6 @@ declare class GlobalAuthState {
|
|
|
105
97
|
* // Show loading state
|
|
106
98
|
* showAuthLoadingSpinner();
|
|
107
99
|
* }
|
|
108
|
-
* ```
|
|
109
100
|
*/
|
|
110
101
|
getIsReady(): boolean;
|
|
111
102
|
/**
|
|
@@ -126,7 +117,6 @@ declare class GlobalAuthState {
|
|
|
126
117
|
* Import and use this instance throughout your application to coordinate auth-dependent operations.
|
|
127
118
|
*
|
|
128
119
|
* @example
|
|
129
|
-
* ```typescript
|
|
130
120
|
* import { globalAuthState } from './globalAuthState';
|
|
131
121
|
*
|
|
132
122
|
* // Wait for auth in async contexts
|
|
@@ -136,7 +126,6 @@ declare class GlobalAuthState {
|
|
|
136
126
|
* if (globalAuthState.getIsReady()) {
|
|
137
127
|
* // Proceed with authenticated operations
|
|
138
128
|
* }
|
|
139
|
-
* ```
|
|
140
129
|
*/
|
|
141
130
|
export declare const globalAuthState: GlobalAuthState;
|
|
142
131
|
export {};
|
package/dist/index.d.ts
CHANGED
|
@@ -3908,8 +3908,6 @@ declare const ONBOARDING_THEME_DEFAULT_COLORS: Record<OnboardingVariant, {
|
|
|
3908
3908
|
* use `waitForReady()` or `getIsReady()` to ensure auth is initialized before making requests
|
|
3909
3909
|
*
|
|
3910
3910
|
* ## Example:
|
|
3911
|
-
*
|
|
3912
|
-
* ```typescript
|
|
3913
3911
|
* // In UI library (AuthProvider):
|
|
3914
3912
|
* globalAuthState.setReady(); // Called after auth initialization
|
|
3915
3913
|
*
|
|
@@ -3920,7 +3918,6 @@ declare const ONBOARDING_THEME_DEFAULT_COLORS: Record<OnboardingVariant, {
|
|
|
3920
3918
|
* if (globalAuthState.getIsReady()) {
|
|
3921
3919
|
* // Proceed with auth-dependent operations
|
|
3922
3920
|
* }
|
|
3923
|
-
* ```
|
|
3924
3921
|
*
|
|
3925
3922
|
* ## Thread Safety:
|
|
3926
3923
|
* This class is designed to be safe for concurrent access. Multiple consumers can wait
|
|
@@ -3943,10 +3940,8 @@ declare class GlobalAuthState {
|
|
|
3943
3940
|
* This method is idempotent - calling it multiple times has no additional effect.
|
|
3944
3941
|
*
|
|
3945
3942
|
* @example
|
|
3946
|
-
* ```typescript
|
|
3947
3943
|
* // In AuthProvider after successful initialization
|
|
3948
3944
|
* globalAuthState.setReady();
|
|
3949
|
-
* ```
|
|
3950
3945
|
*/
|
|
3951
3946
|
setReady(): void;
|
|
3952
3947
|
/**
|
|
@@ -3961,7 +3956,6 @@ declare class GlobalAuthState {
|
|
|
3961
3956
|
* @returns Promise that resolves when authentication is ready
|
|
3962
3957
|
*
|
|
3963
3958
|
* @example
|
|
3964
|
-
* ```typescript
|
|
3965
3959
|
* // In HTTP interceptor
|
|
3966
3960
|
* async function makeAuthenticatedRequest(url: string) {
|
|
3967
3961
|
* await globalAuthState.waitForReady();
|
|
@@ -3973,7 +3967,6 @@ declare class GlobalAuthState {
|
|
|
3973
3967
|
* await globalAuthState.waitForReady();
|
|
3974
3968
|
* // Now safe to make authenticated API calls
|
|
3975
3969
|
* }
|
|
3976
|
-
* ```
|
|
3977
3970
|
*/
|
|
3978
3971
|
waitForReady(): Promise<void>;
|
|
3979
3972
|
/**
|
|
@@ -3985,7 +3978,6 @@ declare class GlobalAuthState {
|
|
|
3985
3978
|
* @returns `true` if authentication is ready, `false` otherwise
|
|
3986
3979
|
*
|
|
3987
3980
|
* @example
|
|
3988
|
-
* ```typescript
|
|
3989
3981
|
* // In a synchronous context
|
|
3990
3982
|
* function canMakeAuthRequest(): boolean {
|
|
3991
3983
|
* return globalAuthState.getIsReady();
|
|
@@ -3999,7 +3991,6 @@ declare class GlobalAuthState {
|
|
|
3999
3991
|
* // Show loading state
|
|
4000
3992
|
* showAuthLoadingSpinner();
|
|
4001
3993
|
* }
|
|
4002
|
-
* ```
|
|
4003
3994
|
*/
|
|
4004
3995
|
getIsReady(): boolean;
|
|
4005
3996
|
/**
|
|
@@ -4020,7 +4011,6 @@ declare class GlobalAuthState {
|
|
|
4020
4011
|
* Import and use this instance throughout your application to coordinate auth-dependent operations.
|
|
4021
4012
|
*
|
|
4022
4013
|
* @example
|
|
4023
|
-
* ```typescript
|
|
4024
4014
|
* import { globalAuthState } from './globalAuthState';
|
|
4025
4015
|
*
|
|
4026
4016
|
* // Wait for auth in async contexts
|
|
@@ -4030,7 +4020,6 @@ declare class GlobalAuthState {
|
|
|
4030
4020
|
* if (globalAuthState.getIsReady()) {
|
|
4031
4021
|
* // Proceed with authenticated operations
|
|
4032
4022
|
* }
|
|
4033
|
-
* ```
|
|
4034
4023
|
*/
|
|
4035
4024
|
declare const globalAuthState: GlobalAuthState;
|
|
4036
4025
|
|