flowlink-auth 2.7.3 → 2.7.5

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/index.js CHANGED
@@ -1,1015 +1,5 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __commonJS = (cb, mod) => function __require() {
8
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
9
- };
10
- var __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from === "object" || typeof from === "function") {
12
- for (let key of __getOwnPropNames(from))
13
- if (!__hasOwnProp.call(to, key) && key !== except)
14
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
- }
16
- return to;
17
- };
18
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
19
- // If the importer is in node compatibility mode or this is not an ESM
20
- // file that has been converted to a CommonJS file using a Babel-
21
- // compatible transform (i.e. "__esModule" has not been set), then set
22
- // "default" to the CommonJS "module.exports" for node compatibility.
23
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
24
- mod
25
- ));
26
-
27
- // node_modules/react/cjs/react.development.js
28
- var require_react_development = __commonJS({
29
- "node_modules/react/cjs/react.development.js"(exports, module) {
30
- "use strict";
31
- (function() {
32
- function defineDeprecationWarning(methodName, info) {
33
- Object.defineProperty(Component.prototype, methodName, {
34
- get: function() {
35
- console.warn(
36
- "%s(...) is deprecated in plain JavaScript React classes. %s",
37
- info[0],
38
- info[1]
39
- );
40
- }
41
- });
42
- }
43
- function getIteratorFn(maybeIterable) {
44
- if (null === maybeIterable || "object" !== typeof maybeIterable)
45
- return null;
46
- maybeIterable = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable["@@iterator"];
47
- return "function" === typeof maybeIterable ? maybeIterable : null;
48
- }
49
- function warnNoop(publicInstance, callerName) {
50
- publicInstance = (publicInstance = publicInstance.constructor) && (publicInstance.displayName || publicInstance.name) || "ReactClass";
51
- var warningKey = publicInstance + "." + callerName;
52
- didWarnStateUpdateForUnmountedComponent[warningKey] || (console.error(
53
- "Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",
54
- callerName,
55
- publicInstance
56
- ), didWarnStateUpdateForUnmountedComponent[warningKey] = true);
57
- }
58
- function Component(props, context, updater) {
59
- this.props = props;
60
- this.context = context;
61
- this.refs = emptyObject;
62
- this.updater = updater || ReactNoopUpdateQueue;
63
- }
64
- function ComponentDummy() {
65
- }
66
- function PureComponent(props, context, updater) {
67
- this.props = props;
68
- this.context = context;
69
- this.refs = emptyObject;
70
- this.updater = updater || ReactNoopUpdateQueue;
71
- }
72
- function noop() {
73
- }
74
- function testStringCoercion(value) {
75
- return "" + value;
76
- }
77
- function checkKeyStringCoercion(value) {
78
- try {
79
- testStringCoercion(value);
80
- var JSCompiler_inline_result = false;
81
- } catch (e) {
82
- JSCompiler_inline_result = true;
83
- }
84
- if (JSCompiler_inline_result) {
85
- JSCompiler_inline_result = console;
86
- var JSCompiler_temp_const = JSCompiler_inline_result.error;
87
- var JSCompiler_inline_result$jscomp$0 = "function" === typeof Symbol && Symbol.toStringTag && value[Symbol.toStringTag] || value.constructor.name || "Object";
88
- JSCompiler_temp_const.call(
89
- JSCompiler_inline_result,
90
- "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
91
- JSCompiler_inline_result$jscomp$0
92
- );
93
- return testStringCoercion(value);
94
- }
95
- }
96
- function getComponentNameFromType(type) {
97
- if (null == type) return null;
98
- if ("function" === typeof type)
99
- return type.$$typeof === REACT_CLIENT_REFERENCE ? null : type.displayName || type.name || null;
100
- if ("string" === typeof type) return type;
101
- switch (type) {
102
- case REACT_FRAGMENT_TYPE:
103
- return "Fragment";
104
- case REACT_PROFILER_TYPE:
105
- return "Profiler";
106
- case REACT_STRICT_MODE_TYPE:
107
- return "StrictMode";
108
- case REACT_SUSPENSE_TYPE:
109
- return "Suspense";
110
- case REACT_SUSPENSE_LIST_TYPE:
111
- return "SuspenseList";
112
- case REACT_ACTIVITY_TYPE:
113
- return "Activity";
114
- }
115
- if ("object" === typeof type)
116
- switch ("number" === typeof type.tag && console.error(
117
- "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
118
- ), type.$$typeof) {
119
- case REACT_PORTAL_TYPE:
120
- return "Portal";
121
- case REACT_CONTEXT_TYPE:
122
- return type.displayName || "Context";
123
- case REACT_CONSUMER_TYPE:
124
- return (type._context.displayName || "Context") + ".Consumer";
125
- case REACT_FORWARD_REF_TYPE:
126
- var innerType = type.render;
127
- type = type.displayName;
128
- type || (type = innerType.displayName || innerType.name || "", type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef");
129
- return type;
130
- case REACT_MEMO_TYPE:
131
- return innerType = type.displayName || null, null !== innerType ? innerType : getComponentNameFromType(type.type) || "Memo";
132
- case REACT_LAZY_TYPE:
133
- innerType = type._payload;
134
- type = type._init;
135
- try {
136
- return getComponentNameFromType(type(innerType));
137
- } catch (x) {
138
- }
139
- }
140
- return null;
141
- }
142
- function getTaskName(type) {
143
- if (type === REACT_FRAGMENT_TYPE) return "<>";
144
- if ("object" === typeof type && null !== type && type.$$typeof === REACT_LAZY_TYPE)
145
- return "<...>";
146
- try {
147
- var name = getComponentNameFromType(type);
148
- return name ? "<" + name + ">" : "<...>";
149
- } catch (x) {
150
- return "<...>";
151
- }
152
- }
153
- function getOwner() {
154
- var dispatcher = ReactSharedInternals.A;
155
- return null === dispatcher ? null : dispatcher.getOwner();
156
- }
157
- function UnknownOwner() {
158
- return Error("react-stack-top-frame");
159
- }
160
- function hasValidKey(config) {
161
- if (hasOwnProperty.call(config, "key")) {
162
- var getter = Object.getOwnPropertyDescriptor(config, "key").get;
163
- if (getter && getter.isReactWarning) return false;
164
- }
165
- return void 0 !== config.key;
166
- }
167
- function defineKeyPropWarningGetter(props, displayName) {
168
- function warnAboutAccessingKey() {
169
- specialPropKeyWarningShown || (specialPropKeyWarningShown = true, console.error(
170
- "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
171
- displayName
172
- ));
173
- }
174
- warnAboutAccessingKey.isReactWarning = true;
175
- Object.defineProperty(props, "key", {
176
- get: warnAboutAccessingKey,
177
- configurable: true
178
- });
179
- }
180
- function elementRefGetterWithDeprecationWarning() {
181
- var componentName = getComponentNameFromType(this.type);
182
- didWarnAboutElementRef[componentName] || (didWarnAboutElementRef[componentName] = true, console.error(
183
- "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
184
- ));
185
- componentName = this.props.ref;
186
- return void 0 !== componentName ? componentName : null;
187
- }
188
- function ReactElement(type, key, props, owner, debugStack, debugTask) {
189
- var refProp = props.ref;
190
- type = {
191
- $$typeof: REACT_ELEMENT_TYPE,
192
- type,
193
- key,
194
- props,
195
- _owner: owner
196
- };
197
- null !== (void 0 !== refProp ? refProp : null) ? Object.defineProperty(type, "ref", {
198
- enumerable: false,
199
- get: elementRefGetterWithDeprecationWarning
200
- }) : Object.defineProperty(type, "ref", { enumerable: false, value: null });
201
- type._store = {};
202
- Object.defineProperty(type._store, "validated", {
203
- configurable: false,
204
- enumerable: false,
205
- writable: true,
206
- value: 0
207
- });
208
- Object.defineProperty(type, "_debugInfo", {
209
- configurable: false,
210
- enumerable: false,
211
- writable: true,
212
- value: null
213
- });
214
- Object.defineProperty(type, "_debugStack", {
215
- configurable: false,
216
- enumerable: false,
217
- writable: true,
218
- value: debugStack
219
- });
220
- Object.defineProperty(type, "_debugTask", {
221
- configurable: false,
222
- enumerable: false,
223
- writable: true,
224
- value: debugTask
225
- });
226
- Object.freeze && (Object.freeze(type.props), Object.freeze(type));
227
- return type;
228
- }
229
- function cloneAndReplaceKey(oldElement, newKey) {
230
- newKey = ReactElement(
231
- oldElement.type,
232
- newKey,
233
- oldElement.props,
234
- oldElement._owner,
235
- oldElement._debugStack,
236
- oldElement._debugTask
237
- );
238
- oldElement._store && (newKey._store.validated = oldElement._store.validated);
239
- return newKey;
240
- }
241
- function validateChildKeys(node) {
242
- isValidElement(node) ? node._store && (node._store.validated = 1) : "object" === typeof node && null !== node && node.$$typeof === REACT_LAZY_TYPE && ("fulfilled" === node._payload.status ? isValidElement(node._payload.value) && node._payload.value._store && (node._payload.value._store.validated = 1) : node._store && (node._store.validated = 1));
243
- }
244
- function isValidElement(object) {
245
- return "object" === typeof object && null !== object && object.$$typeof === REACT_ELEMENT_TYPE;
246
- }
247
- function escape(key) {
248
- var escaperLookup = { "=": "=0", ":": "=2" };
249
- return "$" + key.replace(/[=:]/g, function(match) {
250
- return escaperLookup[match];
251
- });
252
- }
253
- function getElementKey(element, index) {
254
- return "object" === typeof element && null !== element && null != element.key ? (checkKeyStringCoercion(element.key), escape("" + element.key)) : index.toString(36);
255
- }
256
- function resolveThenable(thenable) {
257
- switch (thenable.status) {
258
- case "fulfilled":
259
- return thenable.value;
260
- case "rejected":
261
- throw thenable.reason;
262
- default:
263
- switch ("string" === typeof thenable.status ? thenable.then(noop, noop) : (thenable.status = "pending", thenable.then(
264
- function(fulfilledValue) {
265
- "pending" === thenable.status && (thenable.status = "fulfilled", thenable.value = fulfilledValue);
266
- },
267
- function(error) {
268
- "pending" === thenable.status && (thenable.status = "rejected", thenable.reason = error);
269
- }
270
- )), thenable.status) {
271
- case "fulfilled":
272
- return thenable.value;
273
- case "rejected":
274
- throw thenable.reason;
275
- }
276
- }
277
- throw thenable;
278
- }
279
- function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {
280
- var type = typeof children;
281
- if ("undefined" === type || "boolean" === type) children = null;
282
- var invokeCallback = false;
283
- if (null === children) invokeCallback = true;
284
- else
285
- switch (type) {
286
- case "bigint":
287
- case "string":
288
- case "number":
289
- invokeCallback = true;
290
- break;
291
- case "object":
292
- switch (children.$$typeof) {
293
- case REACT_ELEMENT_TYPE:
294
- case REACT_PORTAL_TYPE:
295
- invokeCallback = true;
296
- break;
297
- case REACT_LAZY_TYPE:
298
- return invokeCallback = children._init, mapIntoArray(
299
- invokeCallback(children._payload),
300
- array,
301
- escapedPrefix,
302
- nameSoFar,
303
- callback
304
- );
305
- }
306
- }
307
- if (invokeCallback) {
308
- invokeCallback = children;
309
- callback = callback(invokeCallback);
310
- var childKey = "" === nameSoFar ? "." + getElementKey(invokeCallback, 0) : nameSoFar;
311
- isArrayImpl(callback) ? (escapedPrefix = "", null != childKey && (escapedPrefix = childKey.replace(userProvidedKeyEscapeRegex, "$&/") + "/"), mapIntoArray(callback, array, escapedPrefix, "", function(c) {
312
- return c;
313
- })) : null != callback && (isValidElement(callback) && (null != callback.key && (invokeCallback && invokeCallback.key === callback.key || checkKeyStringCoercion(callback.key)), escapedPrefix = cloneAndReplaceKey(
314
- callback,
315
- escapedPrefix + (null == callback.key || invokeCallback && invokeCallback.key === callback.key ? "" : ("" + callback.key).replace(
316
- userProvidedKeyEscapeRegex,
317
- "$&/"
318
- ) + "/") + childKey
319
- ), "" !== nameSoFar && null != invokeCallback && isValidElement(invokeCallback) && null == invokeCallback.key && invokeCallback._store && !invokeCallback._store.validated && (escapedPrefix._store.validated = 2), callback = escapedPrefix), array.push(callback));
320
- return 1;
321
- }
322
- invokeCallback = 0;
323
- childKey = "" === nameSoFar ? "." : nameSoFar + ":";
324
- if (isArrayImpl(children))
325
- for (var i = 0; i < children.length; i++)
326
- nameSoFar = children[i], type = childKey + getElementKey(nameSoFar, i), invokeCallback += mapIntoArray(
327
- nameSoFar,
328
- array,
329
- escapedPrefix,
330
- type,
331
- callback
332
- );
333
- else if (i = getIteratorFn(children), "function" === typeof i)
334
- for (i === children.entries && (didWarnAboutMaps || console.warn(
335
- "Using Maps as children is not supported. Use an array of keyed ReactElements instead."
336
- ), didWarnAboutMaps = true), children = i.call(children), i = 0; !(nameSoFar = children.next()).done; )
337
- nameSoFar = nameSoFar.value, type = childKey + getElementKey(nameSoFar, i++), invokeCallback += mapIntoArray(
338
- nameSoFar,
339
- array,
340
- escapedPrefix,
341
- type,
342
- callback
343
- );
344
- else if ("object" === type) {
345
- if ("function" === typeof children.then)
346
- return mapIntoArray(
347
- resolveThenable(children),
348
- array,
349
- escapedPrefix,
350
- nameSoFar,
351
- callback
352
- );
353
- array = String(children);
354
- throw Error(
355
- "Objects are not valid as a React child (found: " + ("[object Object]" === array ? "object with keys {" + Object.keys(children).join(", ") + "}" : array) + "). If you meant to render a collection of children, use an array instead."
356
- );
357
- }
358
- return invokeCallback;
359
- }
360
- function mapChildren(children, func, context) {
361
- if (null == children) return children;
362
- var result = [], count = 0;
363
- mapIntoArray(children, result, "", "", function(child) {
364
- return func.call(context, child, count++);
365
- });
366
- return result;
367
- }
368
- function lazyInitializer(payload) {
369
- if (-1 === payload._status) {
370
- var ioInfo = payload._ioInfo;
371
- null != ioInfo && (ioInfo.start = ioInfo.end = performance.now());
372
- ioInfo = payload._result;
373
- var thenable = ioInfo();
374
- thenable.then(
375
- function(moduleObject) {
376
- if (0 === payload._status || -1 === payload._status) {
377
- payload._status = 1;
378
- payload._result = moduleObject;
379
- var _ioInfo = payload._ioInfo;
380
- null != _ioInfo && (_ioInfo.end = performance.now());
381
- void 0 === thenable.status && (thenable.status = "fulfilled", thenable.value = moduleObject);
382
- }
383
- },
384
- function(error) {
385
- if (0 === payload._status || -1 === payload._status) {
386
- payload._status = 2;
387
- payload._result = error;
388
- var _ioInfo2 = payload._ioInfo;
389
- null != _ioInfo2 && (_ioInfo2.end = performance.now());
390
- void 0 === thenable.status && (thenable.status = "rejected", thenable.reason = error);
391
- }
392
- }
393
- );
394
- ioInfo = payload._ioInfo;
395
- if (null != ioInfo) {
396
- ioInfo.value = thenable;
397
- var displayName = thenable.displayName;
398
- "string" === typeof displayName && (ioInfo.name = displayName);
399
- }
400
- -1 === payload._status && (payload._status = 0, payload._result = thenable);
401
- }
402
- if (1 === payload._status)
403
- return ioInfo = payload._result, void 0 === ioInfo && console.error(
404
- "lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))\n\nDid you accidentally put curly braces around the import?",
405
- ioInfo
406
- ), "default" in ioInfo || console.error(
407
- "lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))",
408
- ioInfo
409
- ), ioInfo.default;
410
- throw payload._result;
411
- }
412
- function resolveDispatcher() {
413
- var dispatcher = ReactSharedInternals.H;
414
- null === dispatcher && console.error(
415
- "Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem."
416
- );
417
- return dispatcher;
418
- }
419
- function releaseAsyncTransition() {
420
- ReactSharedInternals.asyncTransitions--;
421
- }
422
- function enqueueTask(task) {
423
- if (null === enqueueTaskImpl)
424
- try {
425
- var requireString = ("require" + Math.random()).slice(0, 7);
426
- enqueueTaskImpl = (module && module[requireString]).call(
427
- module,
428
- "timers"
429
- ).setImmediate;
430
- } catch (_err) {
431
- enqueueTaskImpl = function(callback) {
432
- false === didWarnAboutMessageChannel && (didWarnAboutMessageChannel = true, "undefined" === typeof MessageChannel && console.error(
433
- "This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning."
434
- ));
435
- var channel = new MessageChannel();
436
- channel.port1.onmessage = callback;
437
- channel.port2.postMessage(void 0);
438
- };
439
- }
440
- return enqueueTaskImpl(task);
441
- }
442
- function aggregateErrors(errors) {
443
- return 1 < errors.length && "function" === typeof AggregateError ? new AggregateError(errors) : errors[0];
444
- }
445
- function popActScope(prevActQueue, prevActScopeDepth) {
446
- prevActScopeDepth !== actScopeDepth - 1 && console.error(
447
- "You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. "
448
- );
449
- actScopeDepth = prevActScopeDepth;
450
- }
451
- function recursivelyFlushAsyncActWork(returnValue, resolve, reject) {
452
- var queue = ReactSharedInternals.actQueue;
453
- if (null !== queue)
454
- if (0 !== queue.length)
455
- try {
456
- flushActQueue(queue);
457
- enqueueTask(function() {
458
- return recursivelyFlushAsyncActWork(returnValue, resolve, reject);
459
- });
460
- return;
461
- } catch (error) {
462
- ReactSharedInternals.thrownErrors.push(error);
463
- }
464
- else ReactSharedInternals.actQueue = null;
465
- 0 < ReactSharedInternals.thrownErrors.length ? (queue = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, reject(queue)) : resolve(returnValue);
466
- }
467
- function flushActQueue(queue) {
468
- if (!isFlushing) {
469
- isFlushing = true;
470
- var i = 0;
471
- try {
472
- for (; i < queue.length; i++) {
473
- var callback = queue[i];
474
- do {
475
- ReactSharedInternals.didUsePromise = false;
476
- var continuation = callback(false);
477
- if (null !== continuation) {
478
- if (ReactSharedInternals.didUsePromise) {
479
- queue[i] = callback;
480
- queue.splice(0, i);
481
- return;
482
- }
483
- callback = continuation;
484
- } else break;
485
- } while (1);
486
- }
487
- queue.length = 0;
488
- } catch (error) {
489
- queue.splice(0, i + 1), ReactSharedInternals.thrownErrors.push(error);
490
- } finally {
491
- isFlushing = false;
492
- }
493
- }
494
- }
495
- "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
496
- var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"), REACT_CONSUMER_TYPE = Symbol.for("react.consumer"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy"), REACT_ACTIVITY_TYPE = Symbol.for("react.activity"), MAYBE_ITERATOR_SYMBOL = Symbol.iterator, didWarnStateUpdateForUnmountedComponent = {}, ReactNoopUpdateQueue = {
497
- isMounted: function() {
498
- return false;
499
- },
500
- enqueueForceUpdate: function(publicInstance) {
501
- warnNoop(publicInstance, "forceUpdate");
502
- },
503
- enqueueReplaceState: function(publicInstance) {
504
- warnNoop(publicInstance, "replaceState");
505
- },
506
- enqueueSetState: function(publicInstance) {
507
- warnNoop(publicInstance, "setState");
508
- }
509
- }, assign = Object.assign, emptyObject = {};
510
- Object.freeze(emptyObject);
511
- Component.prototype.isReactComponent = {};
512
- Component.prototype.setState = function(partialState, callback) {
513
- if ("object" !== typeof partialState && "function" !== typeof partialState && null != partialState)
514
- throw Error(
515
- "takes an object of state variables to update or a function which returns an object of state variables."
516
- );
517
- this.updater.enqueueSetState(this, partialState, callback, "setState");
518
- };
519
- Component.prototype.forceUpdate = function(callback) {
520
- this.updater.enqueueForceUpdate(this, callback, "forceUpdate");
521
- };
522
- var deprecatedAPIs = {
523
- isMounted: [
524
- "isMounted",
525
- "Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."
526
- ],
527
- replaceState: [
528
- "replaceState",
529
- "Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."
530
- ]
531
- };
532
- for (fnName in deprecatedAPIs)
533
- deprecatedAPIs.hasOwnProperty(fnName) && defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);
534
- ComponentDummy.prototype = Component.prototype;
535
- deprecatedAPIs = PureComponent.prototype = new ComponentDummy();
536
- deprecatedAPIs.constructor = PureComponent;
537
- assign(deprecatedAPIs, Component.prototype);
538
- deprecatedAPIs.isPureReactComponent = true;
539
- var isArrayImpl = Array.isArray, REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"), ReactSharedInternals = {
540
- H: null,
541
- A: null,
542
- T: null,
543
- S: null,
544
- actQueue: null,
545
- asyncTransitions: 0,
546
- isBatchingLegacy: false,
547
- didScheduleLegacyUpdate: false,
548
- didUsePromise: false,
549
- thrownErrors: [],
550
- getCurrentStack: null,
551
- recentlyCreatedOwnerStacks: 0
552
- }, hasOwnProperty = Object.prototype.hasOwnProperty, createTask = console.createTask ? console.createTask : function() {
553
- return null;
554
- };
555
- deprecatedAPIs = {
556
- react_stack_bottom_frame: function(callStackForError) {
557
- return callStackForError();
558
- }
559
- };
560
- var specialPropKeyWarningShown, didWarnAboutOldJSXRuntime;
561
- var didWarnAboutElementRef = {};
562
- var unknownOwnerDebugStack = deprecatedAPIs.react_stack_bottom_frame.bind(
563
- deprecatedAPIs,
564
- UnknownOwner
565
- )();
566
- var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));
567
- var didWarnAboutMaps = false, userProvidedKeyEscapeRegex = /\/+/g, reportGlobalError = "function" === typeof reportError ? reportError : function(error) {
568
- if ("object" === typeof window && "function" === typeof window.ErrorEvent) {
569
- var event = new window.ErrorEvent("error", {
570
- bubbles: true,
571
- cancelable: true,
572
- message: "object" === typeof error && null !== error && "string" === typeof error.message ? String(error.message) : String(error),
573
- error
574
- });
575
- if (!window.dispatchEvent(event)) return;
576
- } else if ("object" === typeof process && "function" === typeof process.emit) {
577
- process.emit("uncaughtException", error);
578
- return;
579
- }
580
- console.error(error);
581
- }, didWarnAboutMessageChannel = false, enqueueTaskImpl = null, actScopeDepth = 0, didWarnNoAwaitAct = false, isFlushing = false, queueSeveralMicrotasks = "function" === typeof queueMicrotask ? function(callback) {
582
- queueMicrotask(function() {
583
- return queueMicrotask(callback);
584
- });
585
- } : enqueueTask;
586
- deprecatedAPIs = Object.freeze({
587
- __proto__: null,
588
- c: function(size) {
589
- return resolveDispatcher().useMemoCache(size);
590
- }
591
- });
592
- var fnName = {
593
- map: mapChildren,
594
- forEach: function(children, forEachFunc, forEachContext) {
595
- mapChildren(
596
- children,
597
- function() {
598
- forEachFunc.apply(this, arguments);
599
- },
600
- forEachContext
601
- );
602
- },
603
- count: function(children) {
604
- var n = 0;
605
- mapChildren(children, function() {
606
- n++;
607
- });
608
- return n;
609
- },
610
- toArray: function(children) {
611
- return mapChildren(children, function(child) {
612
- return child;
613
- }) || [];
614
- },
615
- only: function(children) {
616
- if (!isValidElement(children))
617
- throw Error(
618
- "React.Children.only expected to receive a single React element child."
619
- );
620
- return children;
621
- }
622
- };
623
- exports.Activity = REACT_ACTIVITY_TYPE;
624
- exports.Children = fnName;
625
- exports.Component = Component;
626
- exports.Fragment = REACT_FRAGMENT_TYPE;
627
- exports.Profiler = REACT_PROFILER_TYPE;
628
- exports.PureComponent = PureComponent;
629
- exports.StrictMode = REACT_STRICT_MODE_TYPE;
630
- exports.Suspense = REACT_SUSPENSE_TYPE;
631
- exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = ReactSharedInternals;
632
- exports.__COMPILER_RUNTIME = deprecatedAPIs;
633
- exports.act = function(callback) {
634
- var prevActQueue = ReactSharedInternals.actQueue, prevActScopeDepth = actScopeDepth;
635
- actScopeDepth++;
636
- var queue = ReactSharedInternals.actQueue = null !== prevActQueue ? prevActQueue : [], didAwaitActCall = false;
637
- try {
638
- var result = callback();
639
- } catch (error) {
640
- ReactSharedInternals.thrownErrors.push(error);
641
- }
642
- if (0 < ReactSharedInternals.thrownErrors.length)
643
- throw popActScope(prevActQueue, prevActScopeDepth), callback = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, callback;
644
- if (null !== result && "object" === typeof result && "function" === typeof result.then) {
645
- var thenable = result;
646
- queueSeveralMicrotasks(function() {
647
- didAwaitActCall || didWarnNoAwaitAct || (didWarnNoAwaitAct = true, console.error(
648
- "You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);"
649
- ));
650
- });
651
- return {
652
- then: function(resolve, reject) {
653
- didAwaitActCall = true;
654
- thenable.then(
655
- function(returnValue) {
656
- popActScope(prevActQueue, prevActScopeDepth);
657
- if (0 === prevActScopeDepth) {
658
- try {
659
- flushActQueue(queue), enqueueTask(function() {
660
- return recursivelyFlushAsyncActWork(
661
- returnValue,
662
- resolve,
663
- reject
664
- );
665
- });
666
- } catch (error$0) {
667
- ReactSharedInternals.thrownErrors.push(error$0);
668
- }
669
- if (0 < ReactSharedInternals.thrownErrors.length) {
670
- var _thrownError = aggregateErrors(
671
- ReactSharedInternals.thrownErrors
672
- );
673
- ReactSharedInternals.thrownErrors.length = 0;
674
- reject(_thrownError);
675
- }
676
- } else resolve(returnValue);
677
- },
678
- function(error) {
679
- popActScope(prevActQueue, prevActScopeDepth);
680
- 0 < ReactSharedInternals.thrownErrors.length ? (error = aggregateErrors(
681
- ReactSharedInternals.thrownErrors
682
- ), ReactSharedInternals.thrownErrors.length = 0, reject(error)) : reject(error);
683
- }
684
- );
685
- }
686
- };
687
- }
688
- var returnValue$jscomp$0 = result;
689
- popActScope(prevActQueue, prevActScopeDepth);
690
- 0 === prevActScopeDepth && (flushActQueue(queue), 0 !== queue.length && queueSeveralMicrotasks(function() {
691
- didAwaitActCall || didWarnNoAwaitAct || (didWarnNoAwaitAct = true, console.error(
692
- "A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\n\nawait act(() => ...)"
693
- ));
694
- }), ReactSharedInternals.actQueue = null);
695
- if (0 < ReactSharedInternals.thrownErrors.length)
696
- throw callback = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, callback;
697
- return {
698
- then: function(resolve, reject) {
699
- didAwaitActCall = true;
700
- 0 === prevActScopeDepth ? (ReactSharedInternals.actQueue = queue, enqueueTask(function() {
701
- return recursivelyFlushAsyncActWork(
702
- returnValue$jscomp$0,
703
- resolve,
704
- reject
705
- );
706
- })) : resolve(returnValue$jscomp$0);
707
- }
708
- };
709
- };
710
- exports.cache = function(fn) {
711
- return function() {
712
- return fn.apply(null, arguments);
713
- };
714
- };
715
- exports.cacheSignal = function() {
716
- return null;
717
- };
718
- exports.captureOwnerStack = function() {
719
- var getCurrentStack = ReactSharedInternals.getCurrentStack;
720
- return null === getCurrentStack ? null : getCurrentStack();
721
- };
722
- exports.cloneElement = function(element, config, children) {
723
- if (null === element || void 0 === element)
724
- throw Error(
725
- "The argument must be a React element, but you passed " + element + "."
726
- );
727
- var props = assign({}, element.props), key = element.key, owner = element._owner;
728
- if (null != config) {
729
- var JSCompiler_inline_result;
730
- a: {
731
- if (hasOwnProperty.call(config, "ref") && (JSCompiler_inline_result = Object.getOwnPropertyDescriptor(
732
- config,
733
- "ref"
734
- ).get) && JSCompiler_inline_result.isReactWarning) {
735
- JSCompiler_inline_result = false;
736
- break a;
737
- }
738
- JSCompiler_inline_result = void 0 !== config.ref;
739
- }
740
- JSCompiler_inline_result && (owner = getOwner());
741
- hasValidKey(config) && (checkKeyStringCoercion(config.key), key = "" + config.key);
742
- for (propName in config)
743
- !hasOwnProperty.call(config, propName) || "key" === propName || "__self" === propName || "__source" === propName || "ref" === propName && void 0 === config.ref || (props[propName] = config[propName]);
744
- }
745
- var propName = arguments.length - 2;
746
- if (1 === propName) props.children = children;
747
- else if (1 < propName) {
748
- JSCompiler_inline_result = Array(propName);
749
- for (var i = 0; i < propName; i++)
750
- JSCompiler_inline_result[i] = arguments[i + 2];
751
- props.children = JSCompiler_inline_result;
752
- }
753
- props = ReactElement(
754
- element.type,
755
- key,
756
- props,
757
- owner,
758
- element._debugStack,
759
- element._debugTask
760
- );
761
- for (key = 2; key < arguments.length; key++)
762
- validateChildKeys(arguments[key]);
763
- return props;
764
- };
765
- exports.createContext = function(defaultValue) {
766
- defaultValue = {
767
- $$typeof: REACT_CONTEXT_TYPE,
768
- _currentValue: defaultValue,
769
- _currentValue2: defaultValue,
770
- _threadCount: 0,
771
- Provider: null,
772
- Consumer: null
773
- };
774
- defaultValue.Provider = defaultValue;
775
- defaultValue.Consumer = {
776
- $$typeof: REACT_CONSUMER_TYPE,
777
- _context: defaultValue
778
- };
779
- defaultValue._currentRenderer = null;
780
- defaultValue._currentRenderer2 = null;
781
- return defaultValue;
782
- };
783
- exports.createElement = function(type, config, children) {
784
- for (var i = 2; i < arguments.length; i++)
785
- validateChildKeys(arguments[i]);
786
- i = {};
787
- var key = null;
788
- if (null != config)
789
- for (propName in didWarnAboutOldJSXRuntime || !("__self" in config) || "key" in config || (didWarnAboutOldJSXRuntime = true, console.warn(
790
- "Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform"
791
- )), hasValidKey(config) && (checkKeyStringCoercion(config.key), key = "" + config.key), config)
792
- hasOwnProperty.call(config, propName) && "key" !== propName && "__self" !== propName && "__source" !== propName && (i[propName] = config[propName]);
793
- var childrenLength = arguments.length - 2;
794
- if (1 === childrenLength) i.children = children;
795
- else if (1 < childrenLength) {
796
- for (var childArray = Array(childrenLength), _i = 0; _i < childrenLength; _i++)
797
- childArray[_i] = arguments[_i + 2];
798
- Object.freeze && Object.freeze(childArray);
799
- i.children = childArray;
800
- }
801
- if (type && type.defaultProps)
802
- for (propName in childrenLength = type.defaultProps, childrenLength)
803
- void 0 === i[propName] && (i[propName] = childrenLength[propName]);
804
- key && defineKeyPropWarningGetter(
805
- i,
806
- "function" === typeof type ? type.displayName || type.name || "Unknown" : type
807
- );
808
- var propName = 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;
809
- return ReactElement(
810
- type,
811
- key,
812
- i,
813
- getOwner(),
814
- propName ? Error("react-stack-top-frame") : unknownOwnerDebugStack,
815
- propName ? createTask(getTaskName(type)) : unknownOwnerDebugTask
816
- );
817
- };
818
- exports.createRef = function() {
819
- var refObject = { current: null };
820
- Object.seal(refObject);
821
- return refObject;
822
- };
823
- exports.forwardRef = function(render) {
824
- null != render && render.$$typeof === REACT_MEMO_TYPE ? console.error(
825
- "forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))."
826
- ) : "function" !== typeof render ? console.error(
827
- "forwardRef requires a render function but was given %s.",
828
- null === render ? "null" : typeof render
829
- ) : 0 !== render.length && 2 !== render.length && console.error(
830
- "forwardRef render functions accept exactly two parameters: props and ref. %s",
831
- 1 === render.length ? "Did you forget to use the ref parameter?" : "Any additional parameter will be undefined."
832
- );
833
- null != render && null != render.defaultProps && console.error(
834
- "forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?"
835
- );
836
- var elementType = { $$typeof: REACT_FORWARD_REF_TYPE, render }, ownName;
837
- Object.defineProperty(elementType, "displayName", {
838
- enumerable: false,
839
- configurable: true,
840
- get: function() {
841
- return ownName;
842
- },
843
- set: function(name) {
844
- ownName = name;
845
- render.name || render.displayName || (Object.defineProperty(render, "name", { value: name }), render.displayName = name);
846
- }
847
- });
848
- return elementType;
849
- };
850
- exports.isValidElement = isValidElement;
851
- exports.lazy = function(ctor) {
852
- ctor = { _status: -1, _result: ctor };
853
- var lazyType = {
854
- $$typeof: REACT_LAZY_TYPE,
855
- _payload: ctor,
856
- _init: lazyInitializer
857
- }, ioInfo = {
858
- name: "lazy",
859
- start: -1,
860
- end: -1,
861
- value: null,
862
- owner: null,
863
- debugStack: Error("react-stack-top-frame"),
864
- debugTask: console.createTask ? console.createTask("lazy()") : null
865
- };
866
- ctor._ioInfo = ioInfo;
867
- lazyType._debugInfo = [{ awaited: ioInfo }];
868
- return lazyType;
869
- };
870
- exports.memo = function(type, compare) {
871
- null == type && console.error(
872
- "memo: The first argument must be a component. Instead received: %s",
873
- null === type ? "null" : typeof type
874
- );
875
- compare = {
876
- $$typeof: REACT_MEMO_TYPE,
877
- type,
878
- compare: void 0 === compare ? null : compare
879
- };
880
- var ownName;
881
- Object.defineProperty(compare, "displayName", {
882
- enumerable: false,
883
- configurable: true,
884
- get: function() {
885
- return ownName;
886
- },
887
- set: function(name) {
888
- ownName = name;
889
- type.name || type.displayName || (Object.defineProperty(type, "name", { value: name }), type.displayName = name);
890
- }
891
- });
892
- return compare;
893
- };
894
- exports.startTransition = function(scope) {
895
- var prevTransition = ReactSharedInternals.T, currentTransition = {};
896
- currentTransition._updatedFibers = /* @__PURE__ */ new Set();
897
- ReactSharedInternals.T = currentTransition;
898
- try {
899
- var returnValue = scope(), onStartTransitionFinish = ReactSharedInternals.S;
900
- null !== onStartTransitionFinish && onStartTransitionFinish(currentTransition, returnValue);
901
- "object" === typeof returnValue && null !== returnValue && "function" === typeof returnValue.then && (ReactSharedInternals.asyncTransitions++, returnValue.then(releaseAsyncTransition, releaseAsyncTransition), returnValue.then(noop, reportGlobalError));
902
- } catch (error) {
903
- reportGlobalError(error);
904
- } finally {
905
- null === prevTransition && currentTransition._updatedFibers && (scope = currentTransition._updatedFibers.size, currentTransition._updatedFibers.clear(), 10 < scope && console.warn(
906
- "Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table."
907
- )), null !== prevTransition && null !== currentTransition.types && (null !== prevTransition.types && prevTransition.types !== currentTransition.types && console.error(
908
- "We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React."
909
- ), prevTransition.types = currentTransition.types), ReactSharedInternals.T = prevTransition;
910
- }
911
- };
912
- exports.unstable_useCacheRefresh = function() {
913
- return resolveDispatcher().useCacheRefresh();
914
- };
915
- exports.use = function(usable) {
916
- return resolveDispatcher().use(usable);
917
- };
918
- exports.useActionState = function(action, initialState, permalink) {
919
- return resolveDispatcher().useActionState(
920
- action,
921
- initialState,
922
- permalink
923
- );
924
- };
925
- exports.useCallback = function(callback, deps) {
926
- return resolveDispatcher().useCallback(callback, deps);
927
- };
928
- exports.useContext = function(Context) {
929
- var dispatcher = resolveDispatcher();
930
- Context.$$typeof === REACT_CONSUMER_TYPE && console.error(
931
- "Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?"
932
- );
933
- return dispatcher.useContext(Context);
934
- };
935
- exports.useDebugValue = function(value, formatterFn) {
936
- return resolveDispatcher().useDebugValue(value, formatterFn);
937
- };
938
- exports.useDeferredValue = function(value, initialValue) {
939
- return resolveDispatcher().useDeferredValue(value, initialValue);
940
- };
941
- exports.useEffect = function(create, deps) {
942
- null == create && console.warn(
943
- "React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?"
944
- );
945
- return resolveDispatcher().useEffect(create, deps);
946
- };
947
- exports.useEffectEvent = function(callback) {
948
- return resolveDispatcher().useEffectEvent(callback);
949
- };
950
- exports.useId = function() {
951
- return resolveDispatcher().useId();
952
- };
953
- exports.useImperativeHandle = function(ref, create, deps) {
954
- return resolveDispatcher().useImperativeHandle(ref, create, deps);
955
- };
956
- exports.useInsertionEffect = function(create, deps) {
957
- null == create && console.warn(
958
- "React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?"
959
- );
960
- return resolveDispatcher().useInsertionEffect(create, deps);
961
- };
962
- exports.useLayoutEffect = function(create, deps) {
963
- null == create && console.warn(
964
- "React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?"
965
- );
966
- return resolveDispatcher().useLayoutEffect(create, deps);
967
- };
968
- exports.useMemo = function(create, deps) {
969
- return resolveDispatcher().useMemo(create, deps);
970
- };
971
- exports.useOptimistic = function(passthrough, reducer) {
972
- return resolveDispatcher().useOptimistic(passthrough, reducer);
973
- };
974
- exports.useReducer = function(reducer, initialArg, init) {
975
- return resolveDispatcher().useReducer(reducer, initialArg, init);
976
- };
977
- exports.useRef = function(initialValue) {
978
- return resolveDispatcher().useRef(initialValue);
979
- };
980
- exports.useState = function(initialState) {
981
- return resolveDispatcher().useState(initialState);
982
- };
983
- exports.useSyncExternalStore = function(subscribe, getSnapshot, getServerSnapshot) {
984
- return resolveDispatcher().useSyncExternalStore(
985
- subscribe,
986
- getSnapshot,
987
- getServerSnapshot
988
- );
989
- };
990
- exports.useTransition = function() {
991
- return resolveDispatcher().useTransition();
992
- };
993
- exports.version = "19.2.0";
994
- "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
995
- })();
996
- }
997
- });
998
-
999
- // node_modules/react/index.js
1000
- var require_react = __commonJS({
1001
- "node_modules/react/index.js"(exports, module) {
1002
- "use strict";
1003
- if (false) {
1004
- module.exports = null;
1005
- } else {
1006
- module.exports = require_react_development();
1007
- }
1008
- }
1009
- });
1010
-
1011
1
  // src/provider.js
1012
- var import_react = __toESM(require_react(), 1);
2
+ import React, { createContext, useContext, useEffect, useState, useCallback, useRef } from "react";
1013
3
 
1014
4
  // src/securityUtils.js
1015
5
  function isSecureContext() {
@@ -1039,19 +29,19 @@ function getSafeErrorMessage(error) {
1039
29
  }
1040
30
 
1041
31
  // src/provider.js
1042
- var AuthContext = (0, import_react.createContext)(null);
32
+ var AuthContext = createContext(null);
1043
33
  var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) => {
1044
- const [ready, setReady] = (0, import_react.useState)(false);
1045
- const [error, setError] = (0, import_react.useState)(null);
1046
- const [user, setUser] = (0, import_react.useState)(null);
1047
- const [loadingUser, setLoadingUser] = (0, import_react.useState)(true);
1048
- const [sessionTimeout, setSessionTimeout] = (0, import_react.useState)(null);
1049
- const redirectedRef = (0, import_react.useRef)(false);
1050
- const sessionTimerRef = (0, import_react.useRef)(null);
1051
- (0, import_react.useEffect)(() => {
34
+ const [ready, setReady] = useState(false);
35
+ const [error, setError] = useState(null);
36
+ const [user, setUser] = useState(null);
37
+ const [loadingUser, setLoadingUser] = useState(true);
38
+ const [sessionTimeout, setSessionTimeout] = useState(null);
39
+ const redirectedRef = useRef(false);
40
+ const sessionTimerRef = useRef(null);
41
+ useEffect(() => {
1052
42
  checkSecureContext();
1053
43
  }, []);
1054
- (0, import_react.useEffect)(() => {
44
+ useEffect(() => {
1055
45
  if (!publishableKey || !publishableKey.trim()) {
1056
46
  setError("Missing publishable key");
1057
47
  setReady(false);
@@ -1068,7 +58,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1068
58
  setError(null);
1069
59
  setReady(true);
1070
60
  }, [publishableKey, baseUrl]);
1071
- const normalizedBase = (0, import_react.useCallback)(() => {
61
+ const normalizedBase = useCallback(() => {
1072
62
  return baseUrl?.replace(/\/+$/, "") || "";
1073
63
  }, [baseUrl]);
1074
64
  const redirectTo = (url, { replace = true } = {}) => {
@@ -1085,7 +75,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1085
75
  window.location.href = url;
1086
76
  }
1087
77
  };
1088
- const resetSessionTimeout = (0, import_react.useCallback)(() => {
78
+ const resetSessionTimeout = useCallback(() => {
1089
79
  if (sessionTimerRef.current) {
1090
80
  clearTimeout(sessionTimerRef.current);
1091
81
  }
@@ -1094,7 +84,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1094
84
  logout();
1095
85
  }, 24 * 60 * 60 * 1e3);
1096
86
  }, []);
1097
- const fetchMe = (0, import_react.useCallback)(async () => {
87
+ const fetchMe = useCallback(async () => {
1098
88
  setLoadingUser(true);
1099
89
  try {
1100
90
  const base = normalizedBase();
@@ -1130,7 +120,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1130
120
  return null;
1131
121
  }
1132
122
  }, [normalizedBase, resetSessionTimeout]);
1133
- (0, import_react.useEffect)(() => {
123
+ useEffect(() => {
1134
124
  if (!ready) return;
1135
125
  fetchMe();
1136
126
  const onStorage = (e) => {
@@ -1148,7 +138,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1148
138
  }
1149
139
  };
1150
140
  }, [ready, fetchMe]);
1151
- (0, import_react.useEffect)(() => {
141
+ useEffect(() => {
1152
142
  if (!ready) return;
1153
143
  if (loadingUser) return;
1154
144
  if (!user) {
@@ -1160,7 +150,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1160
150
  redirectTo(redirect, { replace: true });
1161
151
  }
1162
152
  }, [ready, loadingUser, user, redirect]);
1163
- const completeLogin = (0, import_react.useCallback)(async (opts = {}) => {
153
+ const completeLogin = useCallback(async (opts = {}) => {
1164
154
  const { redirectTo: redirectUrl, replace = true } = opts;
1165
155
  const u = await fetchMe();
1166
156
  try {
@@ -1173,7 +163,7 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1173
163
  }
1174
164
  return u;
1175
165
  }, [fetchMe, redirect]);
1176
- const logout = (0, import_react.useCallback)(async (opts = {}) => {
166
+ const logout = useCallback(async (opts = {}) => {
1177
167
  const { callServer = true, redirectTo: redirectUrl, replace = true } = opts;
1178
168
  const base = normalizedBase();
1179
169
  if (callServer && base) {
@@ -1205,17 +195,17 @@ var FlowlinkAuthProvider = ({ children, publishableKey, baseUrl, redirect }) =>
1205
195
  logout,
1206
196
  completeLogin
1207
197
  };
1208
- return /* @__PURE__ */ import_react.default.createElement(AuthContext.Provider, { value }, error ? /* @__PURE__ */ import_react.default.createElement("div", { style: { padding: "20px", background: "#220000", color: "white" } }, /* @__PURE__ */ import_react.default.createElement("h2", null, "flowlink Auth Error"), /* @__PURE__ */ import_react.default.createElement("p", null, error)) : !ready ? null : children);
198
+ return /* @__PURE__ */ React.createElement(AuthContext.Provider, { value }, error ? /* @__PURE__ */ React.createElement("div", { style: { padding: "20px", background: "#220000", color: "white" } }, /* @__PURE__ */ React.createElement("h2", null, "flowlink Auth Error"), /* @__PURE__ */ React.createElement("p", null, error)) : !ready ? null : children);
1209
199
  };
1210
200
  var useAuth = () => {
1211
- const ctx = (0, import_react.useContext)(AuthContext);
201
+ const ctx = useContext(AuthContext);
1212
202
  if (!ctx) throw new Error("useAuth must be used within FlowlinkAuthProvider");
1213
203
  return ctx;
1214
204
  };
1215
205
  var provider_default = FlowlinkAuthProvider;
1216
206
 
1217
207
  // src/SignIn.jsx
1218
- var import_react2 = __toESM(require_react(), 1);
208
+ import React2, { useState as useState2 } from "react";
1219
209
  function SignIn({ onSuccess } = {}) {
1220
210
  const {
1221
211
  publishableKey,
@@ -1228,11 +218,11 @@ function SignIn({ onSuccess } = {}) {
1228
218
  fetchMe,
1229
219
  setUser
1230
220
  } = useAuth();
1231
- const [email, setEmail] = (0, import_react2.useState)("");
1232
- const [password, setPassword] = (0, import_react2.useState)("");
1233
- const [loading, setLoading] = (0, import_react2.useState)(false);
1234
- const [error, setError] = (0, import_react2.useState)(null);
1235
- const [message, setMessage] = (0, import_react2.useState)(null);
221
+ const [email, setEmail] = useState2("");
222
+ const [password, setPassword] = useState2("");
223
+ const [loading, setLoading] = useState2(false);
224
+ const [error, setError] = useState2(null);
225
+ const [message, setMessage] = useState2(null);
1236
226
  if (loadingUser) return null;
1237
227
  if (user && redirect) {
1238
228
  if (typeof redirectTo === "function") redirectTo(redirect);
@@ -1259,9 +249,9 @@ function SignIn({ onSuccess } = {}) {
1259
249
  },
1260
250
  body: JSON.stringify({ email, password })
1261
251
  });
1262
- const ct = res.headers.get("content-type") || "";
252
+ const ct2 = res.headers.get("content-type") || "";
1263
253
  let data = {};
1264
- if (ct.includes("application/json")) data = await res.json();
254
+ if (ct2.includes("application/json")) data = await res.json();
1265
255
  else {
1266
256
  const text = await res.text();
1267
257
  throw new Error(`Unexpected response (status ${res.status}): ${text.slice(0, 200)}`);
@@ -1308,10 +298,10 @@ function SignIn({ onSuccess } = {}) {
1308
298
  try {
1309
299
  const rid = typeof crypto !== "undefined" && typeof crypto.randomUUID === "function" ? crypto.randomUUID() : `${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`;
1310
300
  const callbackUrl = encodeURIComponent(`${window.location.origin}/signin`);
1311
- const sdkBase = typeof process !== "undefined" && process.env && process.env.NEXT_PUBLIC_SDK_BASE_URL || baseUrl || "http://localhost:3001";
301
+ const sdkBase = typeof process !== "undefined" && process.env && process.env.NEXT_PUBLIC_FLOWLINK_BASE_URL || baseUrl || "http://localhost:3001";
1312
302
  const startUrl = `${sdkBase.replace(/\/+$/, "")}/sdk/auth/start?rid=${rid}&source=${encodeURIComponent(provider)}&callbackUrl=${callbackUrl}`;
1313
303
  if (!publishableKey) {
1314
- throw new Error("Missing publishable key (client side). Set NEXT_PUBLIC_SDK_PUBLISHABLE_KEY or provide publishableKey in provider.");
304
+ throw new Error("Missing publishable key (client side). Set NEXT_PUBLIC_FLOWLINK_PUBLISHABLE_KEY or provide publishableKey in provider.");
1315
305
  }
1316
306
  const res = await fetch(startUrl, {
1317
307
  method: "GET",
@@ -1336,7 +326,7 @@ function SignIn({ onSuccess } = {}) {
1336
326
  if (e && typeof e.preventDefault === "function") e.preventDefault();
1337
327
  startOAuthFlow("github");
1338
328
  };
1339
- return /* @__PURE__ */ import_react2.default.createElement("div", { style: overlay }, /* @__PURE__ */ import_react2.default.createElement("div", { style: modal }, /* @__PURE__ */ import_react2.default.createElement("h2", { style: title }, "Sign in"), /* @__PURE__ */ import_react2.default.createElement("p", { style: subtitle }, "Welcome back \u2014 enter your credentials."), /* @__PURE__ */ import_react2.default.createElement("form", { onSubmit: submit, style: { width: "100%" } }, /* @__PURE__ */ import_react2.default.createElement("label", { style: label }, "Email"), /* @__PURE__ */ import_react2.default.createElement(
329
+ return /* @__PURE__ */ React2.createElement("div", { style: overlay }, /* @__PURE__ */ React2.createElement("div", { style: modal }, /* @__PURE__ */ React2.createElement("h2", { style: title }, "Sign in"), /* @__PURE__ */ React2.createElement("p", { style: subtitle }, "Welcome back \u2014 enter your credentials."), /* @__PURE__ */ React2.createElement("form", { onSubmit: submit, style: { width: "100%" } }, /* @__PURE__ */ React2.createElement("label", { style: label }, "Email"), /* @__PURE__ */ React2.createElement(
1340
330
  "input",
1341
331
  {
1342
332
  style: input,
@@ -1345,7 +335,7 @@ function SignIn({ onSuccess } = {}) {
1345
335
  type: "email",
1346
336
  required: true
1347
337
  }
1348
- ), /* @__PURE__ */ import_react2.default.createElement("label", { style: label }, "Password"), /* @__PURE__ */ import_react2.default.createElement(
338
+ ), /* @__PURE__ */ React2.createElement("label", { style: label }, "Password"), /* @__PURE__ */ React2.createElement(
1349
339
  "input",
1350
340
  {
1351
341
  style: input,
@@ -1354,7 +344,7 @@ function SignIn({ onSuccess } = {}) {
1354
344
  onChange: (e) => setPassword(e.target.value),
1355
345
  required: true
1356
346
  }
1357
- ), /* @__PURE__ */ import_react2.default.createElement("div", { style: { marginTop: 12 } }, /* @__PURE__ */ import_react2.default.createElement("button", { style: button, type: "submit", disabled: loading }, loading ? "Signing in\u2026" : "Sign in")), /* @__PURE__ */ import_react2.default.createElement("div", { style: { display: "flex", gap: 8, marginTop: 16 } }, /* @__PURE__ */ import_react2.default.createElement("button", { type: "button", onClick: handleGoogle, style: oauthButtonGoogle, disabled: loading }, "Continue with Google"), /* @__PURE__ */ import_react2.default.createElement("button", { type: "button", onClick: handleGithub, style: oauthButtonGithub, disabled: loading }, "Continue with GitHub")), error && /* @__PURE__ */ import_react2.default.createElement("div", { style: errorBox }, error), message && /* @__PURE__ */ import_react2.default.createElement("div", { style: successBox }, message))));
347
+ ), /* @__PURE__ */ React2.createElement("div", { style: { marginTop: 12 } }, /* @__PURE__ */ React2.createElement("button", { style: button, type: "submit", disabled: loading }, loading ? "Signing in\u2026" : "Sign in")), /* @__PURE__ */ React2.createElement("div", { style: { display: "flex", gap: 8, marginTop: 16 } }, /* @__PURE__ */ React2.createElement("button", { type: "button", onClick: handleGoogle, style: oauthButtonGoogle, disabled: loading }, "Continue with Google"), /* @__PURE__ */ React2.createElement("button", { type: "button", onClick: handleGithub, style: oauthButtonGithub, disabled: loading }, "Continue with GitHub")), error && /* @__PURE__ */ React2.createElement("div", { style: errorBox }, error), message && /* @__PURE__ */ React2.createElement("div", { style: successBox }, message))));
1358
348
  }
1359
349
  var overlay = { position: "fixed", inset: 0, display: "flex", alignItems: "center", justifyContent: "center", background: "rgba(0,0,0,0.45)", zIndex: 9999, padding: 20 };
1360
350
  var modal = { width: "100%", maxWidth: 420, background: "#0f1724", color: "#fff", borderRadius: 12, padding: 22, boxShadow: "0 10px 30px rgba(2,6,23,0.6)", border: "1px solid rgba(255,255,255,0.04)" };
@@ -1369,7 +359,439 @@ var errorBox = { marginTop: 10, color: "#ffb4b4", fontSize: 13 };
1369
359
  var successBox = { marginTop: 10, color: "#bef264", fontSize: 13 };
1370
360
 
1371
361
  // src/SignUp.jsx
1372
- var import_react3 = __toESM(require_react(), 1);
362
+ import React3, { useState as useState3, useRef as useRef2, useEffect as useEffect2 } from "react";
363
+
364
+ // ../node_modules/react-toastify/dist/index.mjs
365
+ import { isValidElement as $t } from "react";
366
+ import ut, { useEffect as Rt, useLayoutEffect as Bt, useRef as zt } from "react";
367
+ import { cloneElement as Ft, isValidElement as Ut } from "react";
368
+ import ot from "react";
369
+ import et from "react";
370
+
371
+ // ../node_modules/clsx/dist/clsx.mjs
372
+ function r(e) {
373
+ var t, f, n = "";
374
+ if ("string" == typeof e || "number" == typeof e) n += e;
375
+ else if ("object" == typeof e) if (Array.isArray(e)) {
376
+ var o = e.length;
377
+ for (t = 0; t < o; t++) e[t] && (f = r(e[t])) && (n && (n += " "), n += f);
378
+ } else for (f in e) e[f] && (n && (n += " "), n += f);
379
+ return n;
380
+ }
381
+ function clsx() {
382
+ for (var e, t, f = 0, n = "", o = arguments.length; f < o; f++) (e = arguments[f]) && (t = r(e)) && (n && (n += " "), n += t);
383
+ return n;
384
+ }
385
+ var clsx_default = clsx;
386
+
387
+ // ../node_modules/react-toastify/dist/index.mjs
388
+ import ct, { useEffect as yo, useRef as To, useState as go } from "react";
389
+ import { useRef as Kt, useSyncExternalStore as Yt } from "react";
390
+ import { useEffect as Zt, useRef as St, useState as kt } from "react";
391
+ import { useEffect as Jt, useLayoutEffect as to } from "react";
392
+ import q, { cloneElement as co, isValidElement as fo } from "react";
393
+ import O, { cloneElement as oo, isValidElement as eo } from "react";
394
+ function Mt(t) {
395
+ if (!t || typeof document == "undefined") return;
396
+ let o = document.head || document.getElementsByTagName("head")[0], e = document.createElement("style");
397
+ e.type = "text/css", o.firstChild ? o.insertBefore(e, o.firstChild) : o.appendChild(e), e.styleSheet ? e.styleSheet.cssText = t : e.appendChild(document.createTextNode(t));
398
+ }
399
+ Mt(`:root{--toastify-color-light: #fff;--toastify-color-dark: #121212;--toastify-color-info: #3498db;--toastify-color-success: #07bc0c;--toastify-color-warning: #f1c40f;--toastify-color-error: hsl(6, 78%, 57%);--toastify-color-transparent: rgba(255, 255, 255, .7);--toastify-icon-color-info: var(--toastify-color-info);--toastify-icon-color-success: var(--toastify-color-success);--toastify-icon-color-warning: var(--toastify-color-warning);--toastify-icon-color-error: var(--toastify-color-error);--toastify-container-width: fit-content;--toastify-toast-width: 320px;--toastify-toast-offset: 16px;--toastify-toast-top: max(var(--toastify-toast-offset), env(safe-area-inset-top));--toastify-toast-right: max(var(--toastify-toast-offset), env(safe-area-inset-right));--toastify-toast-left: max(var(--toastify-toast-offset), env(safe-area-inset-left));--toastify-toast-bottom: max(var(--toastify-toast-offset), env(safe-area-inset-bottom));--toastify-toast-background: #fff;--toastify-toast-padding: 14px;--toastify-toast-min-height: 64px;--toastify-toast-max-height: 800px;--toastify-toast-bd-radius: 6px;--toastify-toast-shadow: 0px 4px 12px rgba(0, 0, 0, .1);--toastify-font-family: sans-serif;--toastify-z-index: 9999;--toastify-text-color-light: #757575;--toastify-text-color-dark: #fff;--toastify-text-color-info: #fff;--toastify-text-color-success: #fff;--toastify-text-color-warning: #fff;--toastify-text-color-error: #fff;--toastify-spinner-color: #616161;--toastify-spinner-color-empty-area: #e0e0e0;--toastify-color-progress-light: linear-gradient(to right, #4cd964, #5ac8fa, #007aff, #34aadc, #5856d6, #ff2d55);--toastify-color-progress-dark: #bb86fc;--toastify-color-progress-info: var(--toastify-color-info);--toastify-color-progress-success: var(--toastify-color-success);--toastify-color-progress-warning: var(--toastify-color-warning);--toastify-color-progress-error: var(--toastify-color-error);--toastify-color-progress-bgo: .2}.Toastify__toast-container{z-index:var(--toastify-z-index);-webkit-transform:translate3d(0,0,var(--toastify-z-index));position:fixed;width:var(--toastify-container-width);box-sizing:border-box;color:#fff;display:flex;flex-direction:column}.Toastify__toast-container--top-left{top:var(--toastify-toast-top);left:var(--toastify-toast-left)}.Toastify__toast-container--top-center{top:var(--toastify-toast-top);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--top-right{top:var(--toastify-toast-top);right:var(--toastify-toast-right);align-items:end}.Toastify__toast-container--bottom-left{bottom:var(--toastify-toast-bottom);left:var(--toastify-toast-left)}.Toastify__toast-container--bottom-center{bottom:var(--toastify-toast-bottom);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--bottom-right{bottom:var(--toastify-toast-bottom);right:var(--toastify-toast-right);align-items:end}.Toastify__toast{--y: 0;position:relative;touch-action:none;width:var(--toastify-toast-width);min-height:var(--toastify-toast-min-height);box-sizing:border-box;margin-bottom:1rem;padding:var(--toastify-toast-padding);border-radius:var(--toastify-toast-bd-radius);box-shadow:var(--toastify-toast-shadow);max-height:var(--toastify-toast-max-height);font-family:var(--toastify-font-family);z-index:0;display:flex;flex:1 auto;align-items:center;word-break:break-word}@media only screen and (max-width: 480px){.Toastify__toast-container{width:100vw;left:env(safe-area-inset-left);margin:0}.Toastify__toast-container--top-left,.Toastify__toast-container--top-center,.Toastify__toast-container--top-right{top:env(safe-area-inset-top);transform:translate(0)}.Toastify__toast-container--bottom-left,.Toastify__toast-container--bottom-center,.Toastify__toast-container--bottom-right{bottom:env(safe-area-inset-bottom);transform:translate(0)}.Toastify__toast-container--rtl{right:env(safe-area-inset-right);left:initial}.Toastify__toast{--toastify-toast-width: 100%;margin-bottom:0;border-radius:0}}.Toastify__toast-container[data-stacked=true]{width:var(--toastify-toast-width)}.Toastify__toast--stacked{position:absolute;width:100%;transform:translate3d(0,var(--y),0) scale(var(--s));transition:transform .3s}.Toastify__toast--stacked[data-collapsed] .Toastify__toast-body,.Toastify__toast--stacked[data-collapsed] .Toastify__close-button{transition:opacity .1s}.Toastify__toast--stacked[data-collapsed=false]{overflow:visible}.Toastify__toast--stacked[data-collapsed=true]:not(:last-child)>*{opacity:0}.Toastify__toast--stacked:after{content:"";position:absolute;left:0;right:0;height:calc(var(--g) * 1px);bottom:100%}.Toastify__toast--stacked[data-pos=top]{top:0}.Toastify__toast--stacked[data-pos=bot]{bottom:0}.Toastify__toast--stacked[data-pos=bot].Toastify__toast--stacked:before{transform-origin:top}.Toastify__toast--stacked[data-pos=top].Toastify__toast--stacked:before{transform-origin:bottom}.Toastify__toast--stacked:before{content:"";position:absolute;left:0;right:0;bottom:0;height:100%;transform:scaleY(3);z-index:-1}.Toastify__toast--rtl{direction:rtl}.Toastify__toast--close-on-click{cursor:pointer}.Toastify__toast-icon{margin-inline-end:10px;width:22px;flex-shrink:0;display:flex}.Toastify--animate{animation-fill-mode:both;animation-duration:.5s}.Toastify--animate-icon{animation-fill-mode:both;animation-duration:.3s}.Toastify__toast-theme--dark{background:var(--toastify-color-dark);color:var(--toastify-text-color-dark)}.Toastify__toast-theme--light,.Toastify__toast-theme--colored.Toastify__toast--default{background:var(--toastify-color-light);color:var(--toastify-text-color-light)}.Toastify__toast-theme--colored.Toastify__toast--info{color:var(--toastify-text-color-info);background:var(--toastify-color-info)}.Toastify__toast-theme--colored.Toastify__toast--success{color:var(--toastify-text-color-success);background:var(--toastify-color-success)}.Toastify__toast-theme--colored.Toastify__toast--warning{color:var(--toastify-text-color-warning);background:var(--toastify-color-warning)}.Toastify__toast-theme--colored.Toastify__toast--error{color:var(--toastify-text-color-error);background:var(--toastify-color-error)}.Toastify__progress-bar-theme--light{background:var(--toastify-color-progress-light)}.Toastify__progress-bar-theme--dark{background:var(--toastify-color-progress-dark)}.Toastify__progress-bar--info{background:var(--toastify-color-progress-info)}.Toastify__progress-bar--success{background:var(--toastify-color-progress-success)}.Toastify__progress-bar--warning{background:var(--toastify-color-progress-warning)}.Toastify__progress-bar--error{background:var(--toastify-color-progress-error)}.Toastify__progress-bar-theme--colored.Toastify__progress-bar--info,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--success,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--warning,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--error{background:var(--toastify-color-transparent)}.Toastify__close-button{color:#fff;position:absolute;top:6px;right:6px;background:transparent;outline:none;border:none;padding:0;cursor:pointer;opacity:.7;transition:.3s ease;z-index:1}.Toastify__toast--rtl .Toastify__close-button{left:6px;right:unset}.Toastify__close-button--light{color:#000;opacity:.3}.Toastify__close-button>svg{fill:currentColor;height:16px;width:14px}.Toastify__close-button:hover,.Toastify__close-button:focus{opacity:1}@keyframes Toastify__trackProgress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.Toastify__progress-bar{position:absolute;bottom:0;left:0;width:100%;height:100%;z-index:1;opacity:.7;transform-origin:left}.Toastify__progress-bar--animated{animation:Toastify__trackProgress linear 1 forwards}.Toastify__progress-bar--controlled{transition:transform .2s}.Toastify__progress-bar--rtl{right:0;left:initial;transform-origin:right;border-bottom-left-radius:initial}.Toastify__progress-bar--wrp{position:absolute;overflow:hidden;bottom:0;left:0;width:100%;height:5px;border-bottom-left-radius:var(--toastify-toast-bd-radius);border-bottom-right-radius:var(--toastify-toast-bd-radius)}.Toastify__progress-bar--wrp[data-hidden=true]{opacity:0}.Toastify__progress-bar--bg{opacity:var(--toastify-color-progress-bgo);width:100%;height:100%}.Toastify__spinner{width:20px;height:20px;box-sizing:border-box;border:2px solid;border-radius:100%;border-color:var(--toastify-spinner-color-empty-area);border-right-color:var(--toastify-spinner-color);animation:Toastify__spin .65s linear infinite}@keyframes Toastify__bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0)}60%{opacity:1;transform:translate3d(-25px,0,0)}75%{transform:translate3d(10px,0,0)}90%{transform:translate3d(-5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutRight{20%{opacity:1;transform:translate3d(-20px,var(--y),0)}to{opacity:0;transform:translate3d(2000px,var(--y),0)}}@keyframes Toastify__bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0)}60%{opacity:1;transform:translate3d(25px,0,0)}75%{transform:translate3d(-10px,0,0)}90%{transform:translate3d(5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutLeft{20%{opacity:1;transform:translate3d(20px,var(--y),0)}to{opacity:0;transform:translate3d(-2000px,var(--y),0)}}@keyframes Toastify__bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0)}60%{opacity:1;transform:translate3d(0,-20px,0)}75%{transform:translate3d(0,10px,0)}90%{transform:translate3d(0,-5px,0)}to{transform:translateZ(0)}}@keyframes Toastify__bounceOutUp{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes Toastify__bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0)}60%{opacity:1;transform:translate3d(0,25px,0)}75%{transform:translate3d(0,-10px,0)}90%{transform:translate3d(0,5px,0)}to{transform:none}}@keyframes Toastify__bounceOutDown{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,2000px,0)}}.Toastify__bounce-enter--top-left,.Toastify__bounce-enter--bottom-left{animation-name:Toastify__bounceInLeft}.Toastify__bounce-enter--top-right,.Toastify__bounce-enter--bottom-right{animation-name:Toastify__bounceInRight}.Toastify__bounce-enter--top-center{animation-name:Toastify__bounceInDown}.Toastify__bounce-enter--bottom-center{animation-name:Toastify__bounceInUp}.Toastify__bounce-exit--top-left,.Toastify__bounce-exit--bottom-left{animation-name:Toastify__bounceOutLeft}.Toastify__bounce-exit--top-right,.Toastify__bounce-exit--bottom-right{animation-name:Toastify__bounceOutRight}.Toastify__bounce-exit--top-center{animation-name:Toastify__bounceOutUp}.Toastify__bounce-exit--bottom-center{animation-name:Toastify__bounceOutDown}@keyframes Toastify__zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes Toastify__zoomOut{0%{opacity:1}50%{opacity:0;transform:translate3d(0,var(--y),0) scale3d(.3,.3,.3)}to{opacity:0}}.Toastify__zoom-enter{animation-name:Toastify__zoomIn}.Toastify__zoom-exit{animation-name:Toastify__zoomOut}@keyframes Toastify__flipIn{0%{transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0}40%{transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in}60%{transform:perspective(400px) rotateX(10deg);opacity:1}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}@keyframes Toastify__flipOut{0%{transform:translate3d(0,var(--y),0) perspective(400px)}30%{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(-20deg);opacity:1}to{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(90deg);opacity:0}}.Toastify__flip-enter{animation-name:Toastify__flipIn}.Toastify__flip-exit{animation-name:Toastify__flipOut}@keyframes Toastify__slideInRight{0%{transform:translate3d(110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInLeft{0%{transform:translate3d(-110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInUp{0%{transform:translate3d(0,110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInDown{0%{transform:translate3d(0,-110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideOutRight{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(110%,var(--y),0)}}@keyframes Toastify__slideOutLeft{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(-110%,var(--y),0)}}@keyframes Toastify__slideOutDown{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,500px,0)}}@keyframes Toastify__slideOutUp{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,-500px,0)}}.Toastify__slide-enter--top-left,.Toastify__slide-enter--bottom-left{animation-name:Toastify__slideInLeft}.Toastify__slide-enter--top-right,.Toastify__slide-enter--bottom-right{animation-name:Toastify__slideInRight}.Toastify__slide-enter--top-center{animation-name:Toastify__slideInDown}.Toastify__slide-enter--bottom-center{animation-name:Toastify__slideInUp}.Toastify__slide-exit--top-left,.Toastify__slide-exit--bottom-left{animation-name:Toastify__slideOutLeft;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-right,.Toastify__slide-exit--bottom-right{animation-name:Toastify__slideOutRight;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-center{animation-name:Toastify__slideOutUp;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--bottom-center{animation-name:Toastify__slideOutDown;animation-timing-function:ease-in;animation-duration:.3s}@keyframes Toastify__spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
400
+ `);
401
+ var L = (t) => typeof t == "number" && !isNaN(t);
402
+ var N = (t) => typeof t == "string";
403
+ var P = (t) => typeof t == "function";
404
+ var mt = (t) => N(t) || L(t);
405
+ var B = (t) => N(t) || P(t) ? t : null;
406
+ var pt = (t, o) => t === false || L(t) && t > 0 ? t : o;
407
+ var z = (t) => $t(t) || N(t) || P(t) || L(t);
408
+ function Z(t, o, e = 300) {
409
+ let { scrollHeight: r2, style: s } = t;
410
+ requestAnimationFrame(() => {
411
+ s.minHeight = "initial", s.height = r2 + "px", s.transition = `all ${e}ms`, requestAnimationFrame(() => {
412
+ s.height = "0", s.padding = "0", s.margin = "0", setTimeout(o, e);
413
+ });
414
+ });
415
+ }
416
+ function $({ enter: t, exit: o, appendPosition: e = false, collapse: r2 = true, collapseDuration: s = 300 }) {
417
+ return function({ children: a, position: d, preventExitTransition: c, done: T, nodeRef: g, isIn: v, playToast: x }) {
418
+ let C = e ? `${t}--${d}` : t, S = e ? `${o}--${d}` : o, E = zt(0);
419
+ return Bt(() => {
420
+ let f = g.current, p = C.split(" "), b = (n) => {
421
+ n.target === g.current && (x(), f.removeEventListener("animationend", b), f.removeEventListener("animationcancel", b), E.current === 0 && n.type !== "animationcancel" && f.classList.remove(...p));
422
+ };
423
+ (() => {
424
+ f.classList.add(...p), f.addEventListener("animationend", b), f.addEventListener("animationcancel", b);
425
+ })();
426
+ }, []), Rt(() => {
427
+ let f = g.current, p = () => {
428
+ f.removeEventListener("animationend", p), r2 ? Z(f, T, s) : T();
429
+ };
430
+ v || (c ? p() : (() => {
431
+ E.current = 1, f.className += ` ${S}`, f.addEventListener("animationend", p);
432
+ })());
433
+ }, [v]), ut.createElement(ut.Fragment, null, a);
434
+ };
435
+ }
436
+ function J(t, o) {
437
+ return { content: tt(t.content, t.props), containerId: t.props.containerId, id: t.props.toastId, theme: t.props.theme, type: t.props.type, data: t.props.data || {}, isLoading: t.props.isLoading, icon: t.props.icon, reason: t.removalReason, status: o };
438
+ }
439
+ function tt(t, o, e = false) {
440
+ return Ut(t) && !N(t.type) ? Ft(t, { closeToast: o.closeToast, toastProps: o, data: o.data, isPaused: e }) : P(t) ? t({ closeToast: o.closeToast, toastProps: o, data: o.data, isPaused: e }) : t;
441
+ }
442
+ function yt({ closeToast: t, theme: o, ariaLabel: e = "close" }) {
443
+ return ot.createElement("button", { className: `Toastify__close-button Toastify__close-button--${o}`, type: "button", onClick: (r2) => {
444
+ r2.stopPropagation(), t(true);
445
+ }, "aria-label": e }, ot.createElement("svg", { "aria-hidden": "true", viewBox: "0 0 14 16" }, ot.createElement("path", { fillRule: "evenodd", d: "M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z" })));
446
+ }
447
+ function gt({ delay: t, isRunning: o, closeToast: e, type: r2 = "default", hide: s, className: l, controlledProgress: a, progress: d, rtl: c, isIn: T, theme: g }) {
448
+ let v = s || a && d === 0, x = { animationDuration: `${t}ms`, animationPlayState: o ? "running" : "paused" };
449
+ a && (x.transform = `scaleX(${d})`);
450
+ let C = clsx_default("Toastify__progress-bar", a ? "Toastify__progress-bar--controlled" : "Toastify__progress-bar--animated", `Toastify__progress-bar-theme--${g}`, `Toastify__progress-bar--${r2}`, { ["Toastify__progress-bar--rtl"]: c }), S = P(l) ? l({ rtl: c, type: r2, defaultClassName: C }) : clsx_default(C, l), E = { [a && d >= 1 ? "onTransitionEnd" : "onAnimationEnd"]: a && d < 1 ? null : () => {
451
+ T && e();
452
+ } };
453
+ return et.createElement("div", { className: "Toastify__progress-bar--wrp", "data-hidden": v }, et.createElement("div", { className: `Toastify__progress-bar--bg Toastify__progress-bar-theme--${g} Toastify__progress-bar--${r2}` }), et.createElement("div", { role: "progressbar", "aria-hidden": v ? "true" : "false", "aria-label": "notification timer", className: S, style: x, ...E }));
454
+ }
455
+ var Xt = 1;
456
+ var at = () => `${Xt++}`;
457
+ function _t(t, o, e) {
458
+ let r2 = 1, s = 0, l = [], a = [], d = o, c = /* @__PURE__ */ new Map(), T = /* @__PURE__ */ new Set(), g = (i) => (T.add(i), () => T.delete(i)), v = () => {
459
+ a = Array.from(c.values()), T.forEach((i) => i());
460
+ }, x = ({ containerId: i, toastId: n, updateId: u }) => {
461
+ let h = i ? i !== t : t !== 1, m = c.has(n) && u == null;
462
+ return h || m;
463
+ }, C = (i, n) => {
464
+ c.forEach((u) => {
465
+ var h;
466
+ (n == null || n === u.props.toastId) && ((h = u.toggle) == null || h.call(u, i));
467
+ });
468
+ }, S = (i) => {
469
+ var n, u;
470
+ (u = (n = i.props) == null ? void 0 : n.onClose) == null || u.call(n, i.removalReason), i.isActive = false;
471
+ }, E = (i) => {
472
+ if (i == null) c.forEach(S);
473
+ else {
474
+ let n = c.get(i);
475
+ n && S(n);
476
+ }
477
+ v();
478
+ }, f = () => {
479
+ s -= l.length, l = [];
480
+ }, p = (i) => {
481
+ var m, _;
482
+ let { toastId: n, updateId: u } = i.props, h = u == null;
483
+ i.staleId && c.delete(i.staleId), i.isActive = true, c.set(n, i), v(), e(J(i, h ? "added" : "updated")), h && ((_ = (m = i.props).onOpen) == null || _.call(m));
484
+ };
485
+ return { id: t, props: d, observe: g, toggle: C, removeToast: E, toasts: c, clearQueue: f, buildToast: (i, n) => {
486
+ if (x(n)) return;
487
+ let { toastId: u, updateId: h, data: m, staleId: _, delay: k } = n, M = h == null;
488
+ M && s++;
489
+ let A = { ...d, style: d.toastStyle, key: r2++, ...Object.fromEntries(Object.entries(n).filter(([D, Y]) => Y != null)), toastId: u, updateId: h, data: m, isIn: false, className: B(n.className || d.toastClassName), progressClassName: B(n.progressClassName || d.progressClassName), autoClose: n.isLoading ? false : pt(n.autoClose, d.autoClose), closeToast(D) {
490
+ c.get(u).removalReason = D, E(u);
491
+ }, deleteToast() {
492
+ let D = c.get(u);
493
+ if (D != null) {
494
+ if (e(J(D, "removed")), c.delete(u), s--, s < 0 && (s = 0), l.length > 0) {
495
+ p(l.shift());
496
+ return;
497
+ }
498
+ v();
499
+ }
500
+ } };
501
+ A.closeButton = d.closeButton, n.closeButton === false || z(n.closeButton) ? A.closeButton = n.closeButton : n.closeButton === true && (A.closeButton = z(d.closeButton) ? d.closeButton : true);
502
+ let R = { content: i, props: A, staleId: _ };
503
+ d.limit && d.limit > 0 && s > d.limit && M ? l.push(R) : L(k) ? setTimeout(() => {
504
+ p(R);
505
+ }, k) : p(R);
506
+ }, setProps(i) {
507
+ d = i;
508
+ }, setToggle: (i, n) => {
509
+ let u = c.get(i);
510
+ u && (u.toggle = n);
511
+ }, isToastActive: (i) => {
512
+ var n;
513
+ return (n = c.get(i)) == null ? void 0 : n.isActive;
514
+ }, getSnapshot: () => a };
515
+ }
516
+ var I = /* @__PURE__ */ new Map();
517
+ var F = [];
518
+ var st = /* @__PURE__ */ new Set();
519
+ var Vt = (t) => st.forEach((o) => o(t));
520
+ var bt = () => I.size > 0;
521
+ function Qt() {
522
+ F.forEach((t) => nt(t.content, t.options)), F = [];
523
+ }
524
+ var vt = (t, { containerId: o }) => {
525
+ var e;
526
+ return (e = I.get(o || 1)) == null ? void 0 : e.toasts.get(t);
527
+ };
528
+ function X(t, o) {
529
+ var r2;
530
+ if (o) return !!((r2 = I.get(o)) != null && r2.isToastActive(t));
531
+ let e = false;
532
+ return I.forEach((s) => {
533
+ s.isToastActive(t) && (e = true);
534
+ }), e;
535
+ }
536
+ function ht(t) {
537
+ if (!bt()) {
538
+ F = F.filter((o) => t != null && o.options.toastId !== t);
539
+ return;
540
+ }
541
+ if (t == null || mt(t)) I.forEach((o) => {
542
+ o.removeToast(t);
543
+ });
544
+ else if (t && ("containerId" in t || "id" in t)) {
545
+ let o = I.get(t.containerId);
546
+ o ? o.removeToast(t.id) : I.forEach((e) => {
547
+ e.removeToast(t.id);
548
+ });
549
+ }
550
+ }
551
+ var Ct = (t = {}) => {
552
+ I.forEach((o) => {
553
+ o.props.limit && (!t.containerId || o.id === t.containerId) && o.clearQueue();
554
+ });
555
+ };
556
+ function nt(t, o) {
557
+ z(t) && (bt() || F.push({ content: t, options: o }), I.forEach((e) => {
558
+ e.buildToast(t, o);
559
+ }));
560
+ }
561
+ function xt(t) {
562
+ var o;
563
+ (o = I.get(t.containerId || 1)) == null || o.setToggle(t.id, t.fn);
564
+ }
565
+ function rt(t, o) {
566
+ I.forEach((e) => {
567
+ (o == null || !(o != null && o.containerId) || (o == null ? void 0 : o.containerId) === e.id) && e.toggle(t, o == null ? void 0 : o.id);
568
+ });
569
+ }
570
+ function Et(t) {
571
+ let o = t.containerId || 1;
572
+ return { subscribe(e) {
573
+ let r2 = _t(o, t, Vt);
574
+ I.set(o, r2);
575
+ let s = r2.observe(e);
576
+ return Qt(), () => {
577
+ s(), I.delete(o);
578
+ };
579
+ }, setProps(e) {
580
+ var r2;
581
+ (r2 = I.get(o)) == null || r2.setProps(e);
582
+ }, getSnapshot() {
583
+ var e;
584
+ return (e = I.get(o)) == null ? void 0 : e.getSnapshot();
585
+ } };
586
+ }
587
+ function Pt(t) {
588
+ return st.add(t), () => {
589
+ st.delete(t);
590
+ };
591
+ }
592
+ function Wt(t) {
593
+ return t && (N(t.toastId) || L(t.toastId)) ? t.toastId : at();
594
+ }
595
+ function U(t, o) {
596
+ return nt(t, o), o.toastId;
597
+ }
598
+ function V(t, o) {
599
+ return { ...o, type: o && o.type || t, toastId: Wt(o) };
600
+ }
601
+ function Q(t) {
602
+ return (o, e) => U(o, V(t, e));
603
+ }
604
+ function y(t, o) {
605
+ return U(t, V("default", o));
606
+ }
607
+ y.loading = (t, o) => U(t, V("default", { isLoading: true, autoClose: false, closeOnClick: false, closeButton: false, draggable: false, ...o }));
608
+ function Gt(t, { pending: o, error: e, success: r2 }, s) {
609
+ let l;
610
+ o && (l = N(o) ? y.loading(o, s) : y.loading(o.render, { ...s, ...o }));
611
+ let a = { isLoading: null, autoClose: null, closeOnClick: null, closeButton: null, draggable: null }, d = (T, g, v) => {
612
+ if (g == null) {
613
+ y.dismiss(l);
614
+ return;
615
+ }
616
+ let x = { type: T, ...a, ...s, data: v }, C = N(g) ? { render: g } : g;
617
+ return l ? y.update(l, { ...x, ...C }) : y(C.render, { ...x, ...C }), v;
618
+ }, c = P(t) ? t() : t;
619
+ return c.then((T) => d("success", r2, T)).catch((T) => d("error", e, T)), c;
620
+ }
621
+ y.promise = Gt;
622
+ y.success = Q("success");
623
+ y.info = Q("info");
624
+ y.error = Q("error");
625
+ y.warning = Q("warning");
626
+ y.warn = y.warning;
627
+ y.dark = (t, o) => U(t, V("default", { theme: "dark", ...o }));
628
+ function qt(t) {
629
+ ht(t);
630
+ }
631
+ y.dismiss = qt;
632
+ y.clearWaitingQueue = Ct;
633
+ y.isActive = X;
634
+ y.update = (t, o = {}) => {
635
+ let e = vt(t, o);
636
+ if (e) {
637
+ let { props: r2, content: s } = e, l = { delay: 100, ...r2, ...o, toastId: o.toastId || t, updateId: at() };
638
+ l.toastId !== t && (l.staleId = t);
639
+ let a = l.render || s;
640
+ delete l.render, U(a, l);
641
+ }
642
+ };
643
+ y.done = (t) => {
644
+ y.update(t, { progress: 1 });
645
+ };
646
+ y.onChange = Pt;
647
+ y.play = (t) => rt(true, t);
648
+ y.pause = (t) => rt(false, t);
649
+ function It(t) {
650
+ var a;
651
+ let { subscribe: o, getSnapshot: e, setProps: r2 } = Kt(Et(t)).current;
652
+ r2(t);
653
+ let s = (a = Yt(o, e, e)) == null ? void 0 : a.slice();
654
+ function l(d) {
655
+ if (!s) return [];
656
+ let c = /* @__PURE__ */ new Map();
657
+ return t.newestOnTop && s.reverse(), s.forEach((T) => {
658
+ let { position: g } = T.props;
659
+ c.has(g) || c.set(g, []), c.get(g).push(T);
660
+ }), Array.from(c, (T) => d(T[0], T[1]));
661
+ }
662
+ return { getToastToRender: l, isToastActive: X, count: s == null ? void 0 : s.length };
663
+ }
664
+ function At(t) {
665
+ let [o, e] = kt(false), [r2, s] = kt(false), l = St(null), a = St({ start: 0, delta: 0, removalDistance: 0, canCloseOnClick: true, canDrag: false, didMove: false }).current, { autoClose: d, pauseOnHover: c, closeToast: T, onClick: g, closeOnClick: v } = t;
666
+ xt({ id: t.toastId, containerId: t.containerId, fn: e }), Zt(() => {
667
+ if (t.pauseOnFocusLoss) return x(), () => {
668
+ C();
669
+ };
670
+ }, [t.pauseOnFocusLoss]);
671
+ function x() {
672
+ document.hasFocus() || p(), window.addEventListener("focus", f), window.addEventListener("blur", p);
673
+ }
674
+ function C() {
675
+ window.removeEventListener("focus", f), window.removeEventListener("blur", p);
676
+ }
677
+ function S(m) {
678
+ if (t.draggable === true || t.draggable === m.pointerType) {
679
+ b();
680
+ let _ = l.current;
681
+ a.canCloseOnClick = true, a.canDrag = true, _.style.transition = "none", t.draggableDirection === "x" ? (a.start = m.clientX, a.removalDistance = _.offsetWidth * (t.draggablePercent / 100)) : (a.start = m.clientY, a.removalDistance = _.offsetHeight * (t.draggablePercent === 80 ? t.draggablePercent * 1.5 : t.draggablePercent) / 100);
682
+ }
683
+ }
684
+ function E(m) {
685
+ let { top: _, bottom: k, left: M, right: A } = l.current.getBoundingClientRect();
686
+ m.nativeEvent.type !== "touchend" && t.pauseOnHover && m.clientX >= M && m.clientX <= A && m.clientY >= _ && m.clientY <= k ? p() : f();
687
+ }
688
+ function f() {
689
+ e(true);
690
+ }
691
+ function p() {
692
+ e(false);
693
+ }
694
+ function b() {
695
+ a.didMove = false, document.addEventListener("pointermove", n), document.addEventListener("pointerup", u);
696
+ }
697
+ function i() {
698
+ document.removeEventListener("pointermove", n), document.removeEventListener("pointerup", u);
699
+ }
700
+ function n(m) {
701
+ let _ = l.current;
702
+ if (a.canDrag && _) {
703
+ a.didMove = true, o && p(), t.draggableDirection === "x" ? a.delta = m.clientX - a.start : a.delta = m.clientY - a.start, a.start !== m.clientX && (a.canCloseOnClick = false);
704
+ let k = t.draggableDirection === "x" ? `${a.delta}px, var(--y)` : `0, calc(${a.delta}px + var(--y))`;
705
+ _.style.transform = `translate3d(${k},0)`, _.style.opacity = `${1 - Math.abs(a.delta / a.removalDistance)}`;
706
+ }
707
+ }
708
+ function u() {
709
+ i();
710
+ let m = l.current;
711
+ if (a.canDrag && a.didMove && m) {
712
+ if (a.canDrag = false, Math.abs(a.delta) > a.removalDistance) {
713
+ s(true), t.closeToast(true), t.collapseAll();
714
+ return;
715
+ }
716
+ m.style.transition = "transform 0.2s, opacity 0.2s", m.style.removeProperty("transform"), m.style.removeProperty("opacity");
717
+ }
718
+ }
719
+ let h = { onPointerDown: S, onPointerUp: E };
720
+ return d && c && (h.onMouseEnter = p, t.stacked || (h.onMouseLeave = f)), v && (h.onClick = (m) => {
721
+ g && g(m), a.canCloseOnClick && T(true);
722
+ }), { playToast: f, pauseToast: p, isRunning: o, preventExitTransition: r2, toastRef: l, eventHandlers: h };
723
+ }
724
+ var Ot = typeof window != "undefined" ? to : Jt;
725
+ var G = ({ theme: t, type: o, isLoading: e, ...r2 }) => O.createElement("svg", { viewBox: "0 0 24 24", width: "100%", height: "100%", fill: t === "colored" ? "currentColor" : `var(--toastify-icon-color-${o})`, ...r2 });
726
+ function ao(t) {
727
+ return O.createElement(G, { ...t }, O.createElement("path", { d: "M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z" }));
728
+ }
729
+ function so(t) {
730
+ return O.createElement(G, { ...t }, O.createElement("path", { d: "M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z" }));
731
+ }
732
+ function no(t) {
733
+ return O.createElement(G, { ...t }, O.createElement("path", { d: "M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z" }));
734
+ }
735
+ function ro(t) {
736
+ return O.createElement(G, { ...t }, O.createElement("path", { d: "M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z" }));
737
+ }
738
+ function io() {
739
+ return O.createElement("div", { className: "Toastify__spinner" });
740
+ }
741
+ var W = { info: so, warning: ao, success: no, error: ro, spinner: io };
742
+ var lo = (t) => t in W;
743
+ function Nt({ theme: t, type: o, isLoading: e, icon: r2 }) {
744
+ let s = null, l = { theme: t, type: o };
745
+ return r2 === false || (P(r2) ? s = r2({ ...l, isLoading: e }) : eo(r2) ? s = oo(r2, l) : e ? s = W.spinner() : lo(o) && (s = W[o](l))), s;
746
+ }
747
+ var wt = (t) => {
748
+ let { isRunning: o, preventExitTransition: e, toastRef: r2, eventHandlers: s, playToast: l } = At(t), { closeButton: a, children: d, autoClose: c, onClick: T, type: g, hideProgressBar: v, closeToast: x, transition: C, position: S, className: E, style: f, progressClassName: p, updateId: b, role: i, progress: n, rtl: u, toastId: h, deleteToast: m, isIn: _, isLoading: k, closeOnClick: M, theme: A, ariaLabel: R } = t, D = clsx_default("Toastify__toast", `Toastify__toast-theme--${A}`, `Toastify__toast--${g}`, { ["Toastify__toast--rtl"]: u }, { ["Toastify__toast--close-on-click"]: M }), Y = P(E) ? E({ rtl: u, position: S, type: g, defaultClassName: D }) : clsx_default(D, E), ft = Nt(t), dt = !!n || !c, j = { closeToast: x, type: g, theme: A }, H = null;
749
+ return a === false || (P(a) ? H = a(j) : fo(a) ? H = co(a, j) : H = yt(j)), q.createElement(C, { isIn: _, done: m, position: S, preventExitTransition: e, nodeRef: r2, playToast: l }, q.createElement("div", { id: h, tabIndex: 0, onClick: T, "data-in": _, className: Y, ...s, style: f, ref: r2, ..._ && { role: i, "aria-label": R } }, ft != null && q.createElement("div", { className: clsx_default("Toastify__toast-icon", { ["Toastify--animate-icon Toastify__zoom-enter"]: !k }) }, ft), tt(d, t, !o), H, !t.customProgressBar && q.createElement(gt, { ...b && !dt ? { key: `p-${b}` } : {}, rtl: u, theme: A, delay: c, isRunning: o, isIn: _, closeToast: x, hide: v, type: g, className: p, controlledProgress: dt, progress: n || 0 })));
750
+ };
751
+ var K = (t, o = false) => ({ enter: `Toastify--animate Toastify__${t}-enter`, exit: `Toastify--animate Toastify__${t}-exit`, appendPosition: o });
752
+ var lt = $(K("bounce", true));
753
+ var mo = $(K("slide", true));
754
+ var po = $(K("zoom"));
755
+ var uo = $(K("flip"));
756
+ var _o = { position: "top-right", transition: lt, autoClose: 5e3, closeButton: true, pauseOnHover: true, pauseOnFocusLoss: true, draggable: "touch", draggablePercent: 80, draggableDirection: "x", role: "alert", theme: "light", "aria-label": "Notifications Alt+T", hotKeys: (t) => t.altKey && t.code === "KeyT" };
757
+ function Lt(t) {
758
+ let o = { ..._o, ...t }, e = t.stacked, [r2, s] = go(true), l = To(null), { getToastToRender: a, isToastActive: d, count: c } = It(o), { className: T, style: g, rtl: v, containerId: x, hotKeys: C } = o;
759
+ function S(f) {
760
+ let p = clsx_default("Toastify__toast-container", `Toastify__toast-container--${f}`, { ["Toastify__toast-container--rtl"]: v });
761
+ return P(T) ? T({ position: f, rtl: v, defaultClassName: p }) : clsx_default(p, B(T));
762
+ }
763
+ function E() {
764
+ e && (s(true), y.play());
765
+ }
766
+ return Ot(() => {
767
+ var f;
768
+ if (e) {
769
+ let p = l.current.querySelectorAll('[data-in="true"]'), b = 12, i = (f = o.position) == null ? void 0 : f.includes("top"), n = 0, u = 0;
770
+ Array.from(p).reverse().forEach((h, m) => {
771
+ let _ = h;
772
+ _.classList.add("Toastify__toast--stacked"), m > 0 && (_.dataset.collapsed = `${r2}`), _.dataset.pos || (_.dataset.pos = i ? "top" : "bot");
773
+ let k = n * (r2 ? 0.2 : 1) + (r2 ? 0 : b * m);
774
+ _.style.setProperty("--y", `${i ? k : k * -1}px`), _.style.setProperty("--g", `${b}`), _.style.setProperty("--s", `${1 - (r2 ? u : 0)}`), n += _.offsetHeight, u += 0.025;
775
+ });
776
+ }
777
+ }, [r2, c, e]), yo(() => {
778
+ function f(p) {
779
+ var i;
780
+ let b = l.current;
781
+ C(p) && ((i = b.querySelector('[tabIndex="0"]')) == null || i.focus(), s(false), y.pause()), p.key === "Escape" && (document.activeElement === b || b != null && b.contains(document.activeElement)) && (s(true), y.play());
782
+ }
783
+ return document.addEventListener("keydown", f), () => {
784
+ document.removeEventListener("keydown", f);
785
+ };
786
+ }, [C]), ct.createElement("section", { ref: l, className: "Toastify", id: x, onMouseEnter: () => {
787
+ e && (s(false), y.pause());
788
+ }, onMouseLeave: E, "aria-live": "polite", "aria-atomic": "false", "aria-relevant": "additions text", "aria-label": o["aria-label"] }, a((f, p) => {
789
+ let b = p.length ? { ...g } : { ...g, pointerEvents: "none" };
790
+ return ct.createElement("div", { tabIndex: -1, className: S(f), "data-stacked": e, style: b, key: `c-${f}` }, p.map(({ content: i, props: n }) => ct.createElement(wt, { ...n, stacked: e, collapseAll: E, isIn: d(n.toastId, n.containerId), key: `t-${n.key}` }, i)));
791
+ }));
792
+ }
793
+
794
+ // src/SignUp.jsx
1373
795
  function SignUp() {
1374
796
  const {
1375
797
  publishableKey,
@@ -1381,12 +803,17 @@ function SignUp() {
1381
803
  fetchMe,
1382
804
  setUser
1383
805
  } = useAuth();
1384
- const [name, setName] = (0, import_react3.useState)("");
1385
- const [email, setEmail] = (0, import_react3.useState)("");
1386
- const [password, setPassword] = (0, import_react3.useState)("");
1387
- const [loading, setLoading] = (0, import_react3.useState)(false);
1388
- const [error, setError] = (0, import_react3.useState)(null);
1389
- const [message, setMessage] = (0, import_react3.useState)(null);
806
+ const [name, setName] = useState3("");
807
+ const [email, setEmail] = useState3("");
808
+ const [password, setPassword] = useState3("");
809
+ const [loading, setLoading] = useState3(false);
810
+ const [message, setMessage] = useState3(null);
811
+ const redirectTimer = useRef2(null);
812
+ useEffect2(() => {
813
+ return () => {
814
+ if (redirectTimer.current) clearTimeout(redirectTimer.current);
815
+ };
816
+ }, []);
1390
817
  if (loadingUser) return null;
1391
818
  if (user && redirect) {
1392
819
  if (typeof redirectTo === "function") redirectTo(redirect);
@@ -1395,7 +822,7 @@ function SignUp() {
1395
822
  }
1396
823
  async function submit(e) {
1397
824
  e.preventDefault();
1398
- setError(null);
825
+ if (loading) return;
1399
826
  setMessage(null);
1400
827
  setLoading(true);
1401
828
  const url = `${(baseUrl || "").replace(/\/+$/, "")}/api/sdk/signup`;
@@ -1409,34 +836,42 @@ function SignUp() {
1409
836
  },
1410
837
  body: JSON.stringify({ name, email, password })
1411
838
  });
1412
- const data = await res.json().catch(() => ({}));
1413
- if (!res.ok) throw new Error(data.error || "Signup failed");
839
+ const data = await res.json().catch(async () => {
840
+ const text = await res.text().catch(() => "");
841
+ return { _raw: text };
842
+ });
843
+ if (!res.ok) {
844
+ const errMsg = data?.error || data?._raw || `Signup failed (${res.status})`;
845
+ throw new Error(errMsg);
846
+ }
1414
847
  if (data.user && typeof setUser === "function") setUser(data.user);
1415
848
  if (typeof fetchMe === "function") await fetchMe();
1416
849
  setMessage("Account created. Redirecting\u2026");
850
+ y.success("Account created. Redirecting\u2026");
1417
851
  if (redirect) {
1418
- setTimeout(() => {
852
+ redirectTimer.current = setTimeout(() => {
1419
853
  if (typeof redirectTo === "function") redirectTo(redirect);
1420
854
  else if (typeof window !== "undefined") window.location.assign(redirect);
1421
855
  }, 300);
1422
856
  }
1423
857
  } catch (err) {
1424
- setError(err?.message ?? "Network error");
858
+ const text = err?.message ?? "Network error";
859
+ y.error(text);
1425
860
  console.error("Signup error:", err);
1426
861
  } finally {
1427
862
  setLoading(false);
1428
863
  }
1429
864
  }
1430
865
  async function startOAuthFlow(provider) {
1431
- setError(null);
866
+ if (loading) return;
1432
867
  setLoading(true);
1433
868
  try {
1434
869
  const rid = typeof crypto !== "undefined" && typeof crypto.randomUUID === "function" ? crypto.randomUUID() : `${Date.now().toString(36)}-${Math.random().toString(36).slice(2)}`;
1435
870
  const callbackUrl = encodeURIComponent(`${window.location.origin}/signup`);
1436
- const sdkBase = typeof process !== "undefined" && process.env && process.env.NEXT_PUBLIC_SDK_BASE_URL || baseUrl || window.location.origin.replace(/\/+$/, "");
871
+ const sdkBase = baseUrl || window.location.origin.replace(/\/+$/, "");
1437
872
  const startUrl = `${sdkBase}/sdk/auth/start?rid=${rid}&source=${encodeURIComponent(provider)}&callbackUrl=${callbackUrl}`;
1438
873
  if (!publishableKey) {
1439
- throw new Error("Missing publishable key (client side). Set NEXT_PUBLIC_SDK_PUBLISHABLE_KEY or provide publishableKey in provider.");
874
+ throw new Error("Missing publishable key (client side). Set NEXT_PUBLIC_FLOWLINK_PUBLISHABLE_KEY or provide publishableKey in provider.");
1440
875
  }
1441
876
  const res = await fetch(startUrl, {
1442
877
  method: "GET",
@@ -1454,7 +889,7 @@ function SignUp() {
1454
889
  window.location.href = data.oauthUrl;
1455
890
  } catch (err) {
1456
891
  console.error("OAuth start error:", err);
1457
- setError(err?.message || "OAuth start failed");
892
+ y.error(err?.message || "OAuth start failed");
1458
893
  setLoading(false);
1459
894
  }
1460
895
  }
@@ -1466,131 +901,263 @@ function SignUp() {
1466
901
  if (e && typeof e.preventDefault === "function") e.preventDefault();
1467
902
  startOAuthFlow("github");
1468
903
  };
1469
- return /* @__PURE__ */ import_react3.default.createElement("div", { style: overlay2 }, /* @__PURE__ */ import_react3.default.createElement("div", { style: modal2 }, /* @__PURE__ */ import_react3.default.createElement("h2", { style: title2 }, "Create account"), /* @__PURE__ */ import_react3.default.createElement("form", { onSubmit: submit }, /* @__PURE__ */ import_react3.default.createElement("label", { style: label2 }, "Full name"), /* @__PURE__ */ import_react3.default.createElement(
904
+ return /* @__PURE__ */ React3.createElement("div", { style: page }, /* @__PURE__ */ React3.createElement(Lt, { position: "top-right", autoClose: 5e3 }), /* @__PURE__ */ React3.createElement("div", { style: card }, /* @__PURE__ */ React3.createElement("div", { style: cardInner }, /* @__PURE__ */ React3.createElement("div", { style: brand }, /* @__PURE__ */ React3.createElement("div", { style: brandRow }, /* @__PURE__ */ React3.createElement("div", { style: logoPlaceholder, "aria-hidden": true }), /* @__PURE__ */ React3.createElement("h1", { style: brandTitle }, "Create account")), /* @__PURE__ */ React3.createElement("div", { style: brandSub }, /* @__PURE__ */ React3.createElement("div", { style: brandLead }, "Sign up to continue"), /* @__PURE__ */ React3.createElement("div", { style: brandMuted }, "Welcome! Create your account."))), /* @__PURE__ */ React3.createElement("div", { style: oauthRow }, /* @__PURE__ */ React3.createElement(
905
+ "button",
906
+ {
907
+ onClick: handleGoogle,
908
+ type: "button",
909
+ style: { ...oauthButton, ...oauthGoogle },
910
+ disabled: loading,
911
+ "aria-disabled": loading
912
+ },
913
+ /* @__PURE__ */ React3.createElement("svg", { width: 18, style: { marginRight: 10 }, viewBox: "-3 0 262 262", xmlns: "http://www.w3.org/2000/svg", fill: "#000000", "aria-hidden": true }, /* @__PURE__ */ React3.createElement("path", { d: "M255.878 133.451c0-10.734-.871-18.567-2.756-26.69H130.55v48.448h71.947c-1.45 12.04-9.283 30.172-26.69 42.356l-.244 1.622 38.755 30.023 2.685.268c24.659-22.774 38.875-56.282 38.875-96.027", fill: "#4285F4" }), /* @__PURE__ */ React3.createElement("path", { d: "M130.55 261.1c35.248 0 64.839-11.605 86.453-31.622l-41.196-31.913c-11.024 7.688-25.82 13.055-45.257 13.055-34.523 0-63.824-22.773-74.269-54.25l-1.531.13-40.298 31.187-.527 1.465C35.393 231.798 79.49 261.1 130.55 261.1", fill: "#34A853" }), /* @__PURE__ */ React3.createElement("path", { d: "M56.281 156.37c-2.756-8.123-4.351-16.827-4.351-25.82 0-8.994 1.595-17.697 4.206-25.82l-.073-1.73L15.26 71.312l-1.335.635C5.077 89.644 0 109.517 0 130.55s5.077 40.905 13.925 58.602l42.356-32.782", fill: "#FBBC05" }), /* @__PURE__ */ React3.createElement("path", { d: "M130.55 50.479c24.514 0 41.05 10.589 50.479 19.438l36.844-35.974C195.245 12.91 165.798 0 130.55 0 79.49 0 35.393 29.301 13.925 71.947l42.211 32.783c10.59-31.477 39.891-54.251 74.414-54.251", fill: "#EB4335" })),
914
+ /* @__PURE__ */ React3.createElement("span", null, loading ? "Loading..." : "Continue with Google")
915
+ ), /* @__PURE__ */ React3.createElement(
916
+ "button",
917
+ {
918
+ onClick: handleGithub,
919
+ type: "button",
920
+ style: { ...oauthButton, ...oauthGithub },
921
+ disabled: loading,
922
+ "aria-disabled": loading
923
+ },
924
+ /* @__PURE__ */ React3.createElement("svg", { width: 18, style: { marginRight: 10 }, xmlns: "http://www.w3.org/2000/svg", fill: "white", viewBox: "0 0 20 20", "aria-hidden": true }, /* @__PURE__ */ React3.createElement("path", { fillRule: "evenodd", d: "M10 .333A9.911 9.911 0 0 0 6.866 19.65c.5.092.678-.215.678-.477 0-.237-.01-1.017-.014-1.845-2.757.6-3.338-1.169-3.338-1.169a2.627 2.627 0 0 0-1.1-1.451c-.9-.615.07-.6.07-.6a2.084 2.084 0 0 1 1.518 1.021 2.11 2.11 0 0 0 2.884.823c.044-.503.268-.973.63-1.325-2.2-.25-4.516-1.1-4.516-4.9A3.832 3.832 0 0 1 4.7 7.068a3.56 3.56 0 0 1 .095-2.623s.832-.266 2.726 1.016a9.409 9.409 0 0 1 4.962 0c1.89-1.282 2.717-1.016 2.717-1.016.366.83.402 1.768.1 2.623a3.827 3.827 0 0 1 1.02 2.659c0 3.807-2.319 4.644-4.525 4.889a2.366 2.366 0 0 1 .673 1.834c0 1.326-.012 2.394-.012 2.72 0 .263.18.572.681.475A9.911 9.911 0 0 0 10 .333Z", clipRule: "evenodd" })),
925
+ /* @__PURE__ */ React3.createElement("span", null, loading ? "Loading..." : "Continue with GitHub")
926
+ )), /* @__PURE__ */ React3.createElement("div", { style: dividerRow }, /* @__PURE__ */ React3.createElement("div", { style: line }), /* @__PURE__ */ React3.createElement("div", { style: orText }, "or"), /* @__PURE__ */ React3.createElement("div", { style: line })), /* @__PURE__ */ React3.createElement("form", { onSubmit: submit, style: form }, /* @__PURE__ */ React3.createElement("label", { style: label2, htmlFor: "name" }, /* @__PURE__ */ React3.createElement("span", { style: labelText }, "Name"), /* @__PURE__ */ React3.createElement(
1470
927
  "input",
1471
928
  {
1472
- name: "name",
1473
- style: input2,
929
+ id: "name",
930
+ type: "text",
1474
931
  value: name,
1475
932
  onChange: (e) => setName(e.target.value),
933
+ placeholder: "Your name",
934
+ style: input2,
1476
935
  autoComplete: "name"
1477
936
  }
1478
- ), /* @__PURE__ */ import_react3.default.createElement("label", { style: label2 }, "Email"), /* @__PURE__ */ import_react3.default.createElement(
937
+ )), /* @__PURE__ */ React3.createElement("label", { style: label2, htmlFor: "email" }, /* @__PURE__ */ React3.createElement("span", { style: labelText }, "Email address"), /* @__PURE__ */ React3.createElement(
1479
938
  "input",
1480
939
  {
1481
- name: "email",
940
+ id: "email",
1482
941
  type: "email",
1483
- style: input2,
1484
942
  value: email,
1485
943
  onChange: (e) => setEmail(e.target.value),
1486
944
  required: true,
945
+ placeholder: "you@example.com",
946
+ style: input2,
1487
947
  autoComplete: "email"
1488
948
  }
1489
- ), /* @__PURE__ */ import_react3.default.createElement("label", { style: label2 }, "Password"), /* @__PURE__ */ import_react3.default.createElement(
949
+ )), /* @__PURE__ */ React3.createElement("label", { style: label2, htmlFor: "password" }, /* @__PURE__ */ React3.createElement("span", { style: labelText }, "Password"), /* @__PURE__ */ React3.createElement(
1490
950
  "input",
1491
951
  {
1492
- name: "password",
952
+ id: "password",
1493
953
  type: "password",
1494
- style: input2,
1495
954
  value: password,
1496
955
  onChange: (e) => setPassword(e.target.value),
1497
956
  required: true,
957
+ placeholder: "\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022",
958
+ style: input2,
1498
959
  autoComplete: "new-password"
1499
960
  }
1500
- ), /* @__PURE__ */ import_react3.default.createElement("div", { style: { marginTop: 12 } }, /* @__PURE__ */ import_react3.default.createElement("button", { style: button2, type: "submit", disabled: loading }, loading ? "Creating..." : "Create account")), /* @__PURE__ */ import_react3.default.createElement("div", { style: { display: "flex", gap: 8, marginTop: 16 } }, /* @__PURE__ */ import_react3.default.createElement(
961
+ )), /* @__PURE__ */ React3.createElement(
1501
962
  "button",
1502
963
  {
1503
- type: "button",
1504
- onClick: handleGoogle,
1505
- style: oauthButtonGoogle2
964
+ type: "submit",
965
+ style: submitButton,
966
+ disabled: loading,
967
+ "aria-disabled": loading
1506
968
  },
1507
- "Continue with Google"
1508
- ), /* @__PURE__ */ import_react3.default.createElement(
1509
- "button",
1510
- {
1511
- type: "button",
1512
- onClick: handleGithub,
1513
- style: oauthButtonGithub2
1514
- },
1515
- "Continue with GitHub"
1516
- )), error && /* @__PURE__ */ import_react3.default.createElement("div", { style: errorBox2 }, error), message && /* @__PURE__ */ import_react3.default.createElement("div", { style: successBox2 }, message))));
969
+ loading ? "Signing up..." : "Sign Up"
970
+ ))), /* @__PURE__ */ React3.createElement("div", { style: below }, /* @__PURE__ */ React3.createElement("div", { style: belowRow }, /* @__PURE__ */ React3.createElement("span", { style: muted }, "Already have an account? "), /* @__PURE__ */ React3.createElement("a", { href: "/sign-in", style: link }, "Sign in")), /* @__PURE__ */ React3.createElement("div", { style: dividerThin }), /* @__PURE__ */ React3.createElement("div", { style: secured }, /* @__PURE__ */ React3.createElement("div", { style: securedText }, "Secured by auth")))));
1517
971
  }
1518
- var overlay2 = {
972
+ var page = {
1519
973
  position: "fixed",
1520
974
  inset: 0,
1521
- background: "rgba(0,0,0,0.5)",
1522
975
  display: "flex",
1523
- justifyContent: "center",
1524
976
  alignItems: "center",
1525
- padding: 20,
977
+ justifyContent: "center",
978
+ padding: 24,
979
+ background: "linear-gradient(to bottom, #0b1220 0%, #071023 40%, #02040a 100%)",
980
+ color: "#f8e9d3",
981
+ minHeight: "100vh",
1526
982
  zIndex: 9999
1527
983
  };
1528
- var modal2 = {
984
+ var card = {
1529
985
  width: "100%",
1530
- maxWidth: 420,
1531
- background: "#0f1724",
1532
- borderRadius: 12,
1533
- padding: 24,
986
+ maxWidth: 520,
987
+ borderRadius: 18,
988
+ background: "linear-gradient(180deg, rgba(15,19,36,0.9) 0%, rgba(6,10,18,0.95) 100%)",
989
+ border: "1px solid rgba(148,163,184,0.06)",
990
+ boxShadow: "0 10px 30px rgba(2,6,23,0.6)",
991
+ overflow: "hidden",
992
+ display: "flex",
993
+ flexDirection: "column",
994
+ gap: 12
995
+ };
996
+ var cardInner = {
997
+ padding: 26,
998
+ display: "flex",
999
+ flexDirection: "column",
1000
+ gap: 18
1001
+ };
1002
+ var brand = {
1003
+ display: "flex",
1004
+ flexDirection: "column",
1005
+ gap: 8
1006
+ };
1007
+ var brandRow = {
1008
+ display: "flex",
1009
+ alignItems: "center",
1010
+ gap: 12
1011
+ };
1012
+ var logoPlaceholder = {
1013
+ width: 36,
1014
+ height: 36,
1015
+ borderRadius: 999,
1016
+ background: "linear-gradient(135deg,#2b313a,#0f1724)"
1017
+ };
1018
+ var brandTitle = {
1019
+ margin: 0,
1020
+ fontSize: 20,
1021
+ fontWeight: 600,
1022
+ color: "#fff"
1023
+ };
1024
+ var brandSub = {
1025
+ display: "flex",
1026
+ flexDirection: "column",
1027
+ gap: 4
1028
+ };
1029
+ var brandLead = {
1030
+ fontSize: 15,
1031
+ color: "rgba(255,255,255,0.95)"
1032
+ };
1033
+ var brandMuted = {
1034
+ fontSize: 13,
1035
+ color: "rgba(255,255,255,0.65)",
1036
+ marginTop: 2
1037
+ };
1038
+ var oauthRow = {
1039
+ display: "flex",
1040
+ gap: 10,
1041
+ marginTop: 8
1042
+ };
1043
+ var oauthButton = {
1044
+ flex: 1,
1045
+ display: "inline-flex",
1046
+ alignItems: "center",
1047
+ justifyContent: "center",
1048
+ padding: "10px 12px",
1049
+ borderRadius: 10,
1050
+ border: "1px solid rgba(148,163,184,0.08)",
1051
+ fontSize: 14,
1052
+ cursor: "pointer",
1053
+ userSelect: "none",
1054
+ gap: 8
1055
+ };
1056
+ var oauthGoogle = {
1057
+ background: "rgba(255,255,255,0.06)",
1058
+ color: "#fff"
1059
+ };
1060
+ var oauthGithub = {
1061
+ background: "rgba(255,255,255,0.03)",
1534
1062
  color: "#fff"
1535
1063
  };
1536
- var title2 = { margin: 0, fontSize: 20, fontWeight: 600 };
1537
- var label2 = { marginTop: 10, display: "block", fontSize: 13 };
1064
+ var dividerRow = {
1065
+ display: "flex",
1066
+ alignItems: "center",
1067
+ gap: 12,
1068
+ marginTop: 14
1069
+ };
1070
+ var line = {
1071
+ flex: 1,
1072
+ height: 1,
1073
+ background: "rgba(148,163,184,0.06)"
1074
+ };
1075
+ var orText = {
1076
+ fontSize: 13,
1077
+ color: "rgba(255,255,255,0.6)",
1078
+ padding: "0 8px"
1079
+ };
1080
+ var form = {
1081
+ display: "flex",
1082
+ flexDirection: "column",
1083
+ gap: 12,
1084
+ marginTop: 6
1085
+ };
1086
+ var label2 = {
1087
+ display: "flex",
1088
+ flexDirection: "column",
1089
+ gap: 6
1090
+ };
1091
+ var labelText = {
1092
+ fontSize: 13,
1093
+ color: "rgba(255,255,255,0.66)"
1094
+ };
1538
1095
  var input2 = {
1539
1096
  width: "100%",
1540
1097
  padding: "10px 12px",
1541
- borderRadius: 8,
1542
- background: "#0b1220",
1543
- color: "#fff",
1544
- border: "1px solid #1e293b",
1545
- marginTop: 6
1098
+ borderRadius: 10,
1099
+ background: "rgba(11,18,32,0.5)",
1100
+ color: "#f8e9d3",
1101
+ border: "1px solid rgba(148,163,184,0.06)",
1102
+ fontSize: 14,
1103
+ outline: "none",
1104
+ boxSizing: "border-box"
1546
1105
  };
1547
- var button2 = {
1548
- marginTop: 15,
1106
+ var submitButton = {
1107
+ marginTop: 6,
1549
1108
  width: "100%",
1550
1109
  padding: "10px 12px",
1551
- borderRadius: 8,
1552
- background: "#2563eb",
1110
+ borderRadius: 10,
1111
+ background: "linear-gradient(180deg,#2563eb,#60a5fa)",
1553
1112
  border: "none",
1554
1113
  color: "#fff",
1555
1114
  fontWeight: 600,
1556
- cursor: "pointer"
1115
+ cursor: "pointer",
1116
+ fontSize: 15,
1117
+ display: "inline-flex",
1118
+ alignItems: "center",
1119
+ justifyContent: "center"
1557
1120
  };
1558
- var oauthButtonGoogle2 = {
1559
- flex: 1,
1560
- padding: "10px 12px",
1561
- borderRadius: 8,
1562
- background: "#db4437",
1563
- color: "#fff",
1564
- border: "none",
1565
- cursor: "pointer"
1121
+ var below = {
1122
+ padding: "12px 20px 20px 20px",
1123
+ borderTop: "1px solid rgba(148,163,184,0.03)",
1124
+ display: "flex",
1125
+ flexDirection: "column",
1126
+ gap: 10
1566
1127
  };
1567
- var oauthButtonGithub2 = {
1568
- flex: 1,
1569
- padding: "10px 12px",
1570
- borderRadius: 8,
1571
- background: "#24292f",
1572
- color: "#fff",
1573
- border: "none",
1574
- cursor: "pointer"
1128
+ var belowRow = {
1129
+ textAlign: "center",
1130
+ display: "flex",
1131
+ justifyContent: "center",
1132
+ gap: 8,
1133
+ alignItems: "center"
1134
+ };
1135
+ var muted = {
1136
+ color: "rgba(255,255,255,0.65)",
1137
+ fontSize: 13
1138
+ };
1139
+ var link = {
1140
+ color: "#3b82f6",
1141
+ textDecoration: "none",
1142
+ fontWeight: 600
1143
+ };
1144
+ var dividerThin = {
1145
+ height: 1,
1146
+ background: "rgba(148,163,184,0.05)",
1147
+ marginTop: 6,
1148
+ marginBottom: 6
1149
+ };
1150
+ var secured = {
1151
+ textAlign: "center"
1152
+ };
1153
+ var securedText = {
1154
+ color: "rgba(255,255,255,0.9)",
1155
+ fontSize: 13,
1156
+ fontWeight: 600
1575
1157
  };
1576
- var errorBox2 = { marginTop: 10, color: "#ffb4b4", fontSize: 13 };
1577
- var successBox2 = { marginTop: 10, color: "#bef264", fontSize: 13 };
1578
1158
  export {
1579
1159
  provider_default as FlowlinkAuthProvider,
1580
1160
  SignIn,
1581
1161
  SignUp,
1582
1162
  useAuth
1583
1163
  };
1584
- /*! Bundled license information:
1585
-
1586
- react/cjs/react.development.js:
1587
- (**
1588
- * @license React
1589
- * react.development.js
1590
- *
1591
- * Copyright (c) Meta Platforms, Inc. and affiliates.
1592
- *
1593
- * This source code is licensed under the MIT license found in the
1594
- * LICENSE file in the root directory of this source tree.
1595
- *)
1596
- */