@insforge/react 0.6.0 → 0.6.2
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/README.md +0 -6
- package/dist/atoms.cjs +14 -17
- package/dist/atoms.cjs.map +1 -1
- package/dist/atoms.d.cts +1 -0
- package/dist/atoms.d.ts +1 -0
- package/dist/atoms.js +13 -16
- package/dist/atoms.js.map +1 -1
- package/dist/components.cjs +23 -26
- package/dist/components.cjs.map +1 -1
- package/dist/components.d.cts +2 -1
- package/dist/components.d.ts +2 -1
- package/dist/components.js +22 -25
- package/dist/components.js.map +1 -1
- package/dist/forms.cjs +14 -17
- package/dist/forms.cjs.map +1 -1
- package/dist/forms.d.cts +1 -0
- package/dist/forms.d.ts +1 -0
- package/dist/forms.js +13 -16
- package/dist/forms.js.map +1 -1
- package/dist/hooks.cjs +15 -18
- package/dist/hooks.cjs.map +1 -1
- package/dist/hooks.d.cts +4 -5
- package/dist/hooks.d.ts +4 -5
- package/dist/hooks.js +14 -17
- package/dist/hooks.js.map +1 -1
- package/dist/index.cjs +40 -46
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -59
- package/dist/index.d.ts +7 -59
- package/dist/index.js +38 -44
- package/dist/index.js.map +1 -1
- package/dist/types.d.cts +3 -19
- package/dist/types.d.ts +3 -19
- package/package.json +98 -110
package/dist/forms.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
|
2
2
|
import { OAuthProvidersSchema } from '@insforge/shared-schemas';
|
|
3
3
|
import { FormEvent } from 'react';
|
|
4
4
|
import { AuthConfig } from './types.js';
|
|
5
|
+
import '@insforge/shared';
|
|
5
6
|
|
|
6
7
|
interface SignInFormProps {
|
|
7
8
|
email: string;
|
package/dist/forms.js
CHANGED
|
@@ -2,6 +2,7 @@ import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
|
2
2
|
import { AlertTriangle, EyeOff, Eye, Loader2, CircleCheck, Check } from 'lucide-react';
|
|
3
3
|
import { createContext, useState, useEffect, useMemo, useCallback, useContext, useRef } from 'react';
|
|
4
4
|
import '@insforge/sdk';
|
|
5
|
+
import { InsforgeContext } from '@insforge/shared/react';
|
|
5
6
|
|
|
6
7
|
// src/components/atoms/AuthBranding.tsx
|
|
7
8
|
function AuthBranding() {
|
|
@@ -623,8 +624,6 @@ function AuthVerificationCodeInput({
|
|
|
623
624
|
index
|
|
624
625
|
)) });
|
|
625
626
|
}
|
|
626
|
-
var InsforgeContext = createContext(void 0);
|
|
627
|
-
InsforgeContext.displayName = "InsforgeContext";
|
|
628
627
|
function useInsforge() {
|
|
629
628
|
const context = useContext(InsforgeContext);
|
|
630
629
|
if (!context) {
|
|
@@ -634,20 +633,18 @@ function useInsforge() {
|
|
|
634
633
|
isSignedIn: false,
|
|
635
634
|
setUser: () => {
|
|
636
635
|
},
|
|
637
|
-
signIn:
|
|
638
|
-
signUp:
|
|
639
|
-
signOut:
|
|
640
|
-
},
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
},
|
|
650
|
-
getPublicAuthConfig: async () => null,
|
|
636
|
+
signIn: () => Promise.resolve({ error: "SSR mode" }),
|
|
637
|
+
signUp: () => Promise.resolve({ error: "SSR mode" }),
|
|
638
|
+
signOut: () => Promise.resolve(),
|
|
639
|
+
updateUser: () => Promise.resolve({ error: "SSR mode" }),
|
|
640
|
+
reloadAuth: () => Promise.resolve({ success: false, error: "SSR mode" }),
|
|
641
|
+
sendVerificationEmail: () => Promise.resolve(null),
|
|
642
|
+
sendResetPasswordEmail: () => Promise.resolve(null),
|
|
643
|
+
resetPassword: () => Promise.resolve(null),
|
|
644
|
+
verifyEmail: () => Promise.resolve(null),
|
|
645
|
+
exchangeResetPasswordToken: () => Promise.resolve({ error: { message: "SSR mode" } }),
|
|
646
|
+
loginWithOAuth: () => Promise.resolve(),
|
|
647
|
+
getPublicAuthConfig: () => Promise.resolve(null),
|
|
651
648
|
baseUrl: "",
|
|
652
649
|
afterSignInUrl: "/"
|
|
653
650
|
};
|