@clicktap/state 0.11.6 → 0.12.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.
- package/auth/AuthProvider.d.ts +266 -230
- package/auth/auth.d.ts +127 -109
- package/index.js +24 -24
- package/index.mjs +1301 -1257
- package/package.json +5 -4
- package/toast/ToastProvider.d.ts +142 -42
- package/toast/timer.d.ts +16 -20
- package/toast/toast.d.ts +71 -21
package/auth/auth.d.ts
CHANGED
|
@@ -46,7 +46,7 @@ export declare const authMachine: import("xstate").StateMachine<AuthMachineConte
|
|
|
46
46
|
}>, {
|
|
47
47
|
[k: string]: unknown;
|
|
48
48
|
type: string;
|
|
49
|
-
}> | import("xstate").ActorRef<import("xstate").PromiseSnapshot<{
|
|
49
|
+
}, import("xstate").EventObject> | import("xstate").ActorRef<import("xstate").PromiseSnapshot<{
|
|
50
50
|
type: string;
|
|
51
51
|
accessToken: string;
|
|
52
52
|
}, {
|
|
@@ -56,119 +56,137 @@ export declare const authMachine: import("xstate").StateMachine<AuthMachineConte
|
|
|
56
56
|
}>, {
|
|
57
57
|
[k: string]: unknown;
|
|
58
58
|
type: string;
|
|
59
|
-
}> | import("xstate").ActorRef<import("xstate").PromiseSnapshot<{
|
|
59
|
+
}, import("xstate").EventObject> | import("xstate").ActorRef<import("xstate").PromiseSnapshot<{
|
|
60
60
|
type: string;
|
|
61
61
|
}, {
|
|
62
62
|
context: AuthMachineContext;
|
|
63
63
|
}>, {
|
|
64
64
|
[k: string]: unknown;
|
|
65
65
|
type: string;
|
|
66
|
-
}> | undefined;
|
|
67
|
-
}, {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
}
|
|
66
|
+
}, import("xstate").EventObject> | undefined;
|
|
67
|
+
}, import("xstate").Values<{
|
|
68
|
+
refreshAccessToken: {
|
|
69
|
+
src: "refreshAccessToken";
|
|
70
|
+
logic: import("xstate").PromiseActorLogic<{
|
|
71
|
+
type: string;
|
|
72
|
+
accessToken: string;
|
|
73
|
+
}, {
|
|
74
|
+
context: AuthMachineContext;
|
|
75
|
+
}>;
|
|
76
|
+
id: string | undefined;
|
|
77
|
+
};
|
|
78
|
+
authenticate: {
|
|
79
|
+
src: "authenticate";
|
|
80
|
+
logic: import("xstate").PromiseActorLogic<{
|
|
81
|
+
type: string;
|
|
82
|
+
accessToken: string;
|
|
83
|
+
}, {
|
|
84
|
+
context: AuthMachineContext;
|
|
85
|
+
username: string;
|
|
86
|
+
password: string;
|
|
87
|
+
}>;
|
|
88
|
+
id: string | undefined;
|
|
89
|
+
};
|
|
90
|
+
unauthenticate: {
|
|
91
|
+
src: "unauthenticate";
|
|
92
|
+
logic: import("xstate").PromiseActorLogic<{
|
|
93
|
+
type: string;
|
|
94
|
+
}, {
|
|
95
|
+
context: AuthMachineContext;
|
|
96
|
+
}>;
|
|
97
|
+
id: string | undefined;
|
|
98
|
+
};
|
|
99
|
+
}>, import("xstate").Values<{
|
|
100
|
+
setUserContext: {
|
|
101
|
+
type: "setUserContext";
|
|
102
|
+
params: import("xstate").NonReducibleUnknown;
|
|
103
|
+
};
|
|
104
|
+
unsetUserContext: {
|
|
105
|
+
type: "unsetUserContext";
|
|
106
|
+
params: import("xstate").NonReducibleUnknown;
|
|
107
|
+
};
|
|
108
|
+
setAccessToken: {
|
|
109
|
+
type: "setAccessToken";
|
|
110
|
+
params: import("xstate").NonReducibleUnknown;
|
|
111
|
+
};
|
|
112
|
+
unsetRefreshToken: {
|
|
113
|
+
type: "unsetRefreshToken";
|
|
114
|
+
params: import("xstate").NonReducibleUnknown;
|
|
115
|
+
};
|
|
116
|
+
setIgnoreRefreshToken: {
|
|
117
|
+
type: "setIgnoreRefreshToken";
|
|
118
|
+
params: import("xstate").NonReducibleUnknown;
|
|
119
|
+
};
|
|
120
|
+
addError: {
|
|
121
|
+
type: "addError";
|
|
122
|
+
params: import("xstate").NonReducibleUnknown;
|
|
123
|
+
};
|
|
124
|
+
clearErrors: {
|
|
125
|
+
type: "clearErrors";
|
|
126
|
+
params: import("xstate").NonReducibleUnknown;
|
|
127
|
+
};
|
|
128
|
+
}>, never, never, "refreshing" | "authenticating" | "loggedIn" | "loggedOut" | "unauthenticating", string, {
|
|
120
129
|
initialContext: Partial<AuthMachineContext>;
|
|
121
130
|
initialState?: string | undefined;
|
|
122
|
-
}, import("xstate").NonReducibleUnknown, import("xstate").ResolveTypegenMeta<import("xstate").TypegenDisabled, RefreshTokenEvent | LoginEvent | LogoutEvent | ClearErrorsEvent | DoneActorEvent<AuthenticateSuccessEvent> | DoneActorEvent<RefreshTokenSuccessEvent>, {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
}
|
|
131
|
+
}, import("xstate").NonReducibleUnknown, import("xstate").EventObject, import("xstate").ResolveTypegenMeta<import("xstate").TypegenDisabled, RefreshTokenEvent | LoginEvent | LogoutEvent | ClearErrorsEvent | DoneActorEvent<AuthenticateSuccessEvent> | DoneActorEvent<RefreshTokenSuccessEvent>, import("xstate").Values<{
|
|
132
|
+
refreshAccessToken: {
|
|
133
|
+
src: "refreshAccessToken";
|
|
134
|
+
logic: import("xstate").PromiseActorLogic<{
|
|
135
|
+
type: string;
|
|
136
|
+
accessToken: string;
|
|
137
|
+
}, {
|
|
138
|
+
context: AuthMachineContext;
|
|
139
|
+
}>;
|
|
140
|
+
id: string | undefined;
|
|
141
|
+
};
|
|
142
|
+
authenticate: {
|
|
143
|
+
src: "authenticate";
|
|
144
|
+
logic: import("xstate").PromiseActorLogic<{
|
|
145
|
+
type: string;
|
|
146
|
+
accessToken: string;
|
|
147
|
+
}, {
|
|
148
|
+
context: AuthMachineContext;
|
|
149
|
+
username: string;
|
|
150
|
+
password: string;
|
|
151
|
+
}>;
|
|
152
|
+
id: string | undefined;
|
|
153
|
+
};
|
|
154
|
+
unauthenticate: {
|
|
155
|
+
src: "unauthenticate";
|
|
156
|
+
logic: import("xstate").PromiseActorLogic<{
|
|
157
|
+
type: string;
|
|
158
|
+
}, {
|
|
159
|
+
context: AuthMachineContext;
|
|
160
|
+
}>;
|
|
161
|
+
id: string | undefined;
|
|
162
|
+
};
|
|
163
|
+
}>, import("xstate").Values<{
|
|
164
|
+
setUserContext: {
|
|
165
|
+
type: "setUserContext";
|
|
166
|
+
params: import("xstate").NonReducibleUnknown;
|
|
167
|
+
};
|
|
168
|
+
unsetUserContext: {
|
|
169
|
+
type: "unsetUserContext";
|
|
170
|
+
params: import("xstate").NonReducibleUnknown;
|
|
171
|
+
};
|
|
172
|
+
setAccessToken: {
|
|
173
|
+
type: "setAccessToken";
|
|
174
|
+
params: import("xstate").NonReducibleUnknown;
|
|
175
|
+
};
|
|
176
|
+
unsetRefreshToken: {
|
|
177
|
+
type: "unsetRefreshToken";
|
|
178
|
+
params: import("xstate").NonReducibleUnknown;
|
|
179
|
+
};
|
|
180
|
+
setIgnoreRefreshToken: {
|
|
181
|
+
type: "setIgnoreRefreshToken";
|
|
182
|
+
params: import("xstate").NonReducibleUnknown;
|
|
183
|
+
};
|
|
184
|
+
addError: {
|
|
185
|
+
type: "addError";
|
|
186
|
+
params: import("xstate").NonReducibleUnknown;
|
|
187
|
+
};
|
|
188
|
+
clearErrors: {
|
|
189
|
+
type: "clearErrors";
|
|
190
|
+
params: import("xstate").NonReducibleUnknown;
|
|
191
|
+
};
|
|
192
|
+
}>, never, never, string, import("xstate").EventObject>>;
|