hazo_auth 5.1.40 → 5.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/SETUP_CHECKLIST.md +46 -0
- package/cli-src/lib/auth/ensure_anon_id.server.ts +88 -0
- package/cli-src/lib/auth/index.ts +3 -0
- package/cli-src/lib/cookies_config.edge.ts +1 -0
- package/cli-src/lib/cookies_config.server.ts +1 -0
- package/cli-src/lib/hazo_connect_setup.server.ts +0 -8
- package/cli-src/lib/services/email_service.ts +136 -289
- package/cli-src/lib/services/email_template_manifest.ts +104 -0
- package/cli-src/lib/services/email_templates/email_verification.html +18 -0
- package/cli-src/lib/services/email_templates/email_verification.txt +9 -0
- package/cli-src/lib/services/email_templates/forgot_password.html +18 -0
- package/cli-src/lib/services/email_templates/forgot_password.txt +9 -0
- package/cli-src/lib/services/email_templates/password_changed.html +14 -0
- package/cli-src/lib/services/email_templates/password_changed.txt +9 -0
- package/cli-src/lib/services/session_token_service.ts +2 -2
- package/cli-src/lib/ui_shell_config.server.ts +6 -2
- package/dist/components/layouts/login/index.d.ts +16 -3
- package/dist/components/layouts/login/index.d.ts.map +1 -1
- package/dist/components/layouts/login/index.js +49 -5
- package/dist/components/layouts/register/index.d.ts +7 -3
- package/dist/components/layouts/register/index.d.ts.map +1 -1
- package/dist/components/layouts/register/index.js +36 -3
- package/dist/components/layouts/shared/components/floating_home_link.d.ts +20 -0
- package/dist/components/layouts/shared/components/floating_home_link.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/floating_home_link.js +29 -0
- package/dist/components/layouts/shared/components/profile_pic_menu.d.ts +8 -0
- package/dist/components/layouts/shared/components/profile_pic_menu.d.ts.map +1 -1
- package/dist/components/layouts/shared/components/profile_pic_menu.js +18 -8
- package/dist/components/layouts/shared/index.d.ts +2 -0
- package/dist/components/layouts/shared/index.d.ts.map +1 -1
- package/dist/components/layouts/shared/index.js +1 -0
- package/dist/lib/auth/ensure_anon_id.server.d.ts +21 -0
- package/dist/lib/auth/ensure_anon_id.server.d.ts.map +1 -0
- package/dist/lib/auth/ensure_anon_id.server.js +73 -0
- package/dist/lib/auth/index.d.ts +1 -0
- package/dist/lib/auth/index.d.ts.map +1 -1
- package/dist/lib/auth/index.js +2 -0
- package/dist/lib/cookies_config.edge.d.ts +1 -0
- package/dist/lib/cookies_config.edge.d.ts.map +1 -1
- package/dist/lib/cookies_config.edge.js +1 -0
- package/dist/lib/cookies_config.server.d.ts +1 -0
- package/dist/lib/cookies_config.server.d.ts.map +1 -1
- package/dist/lib/cookies_config.server.js +1 -0
- package/dist/lib/hazo_connect_setup.server.d.ts.map +1 -1
- package/dist/lib/hazo_connect_setup.server.js +0 -8
- package/dist/lib/services/email_service.d.ts +17 -4
- package/dist/lib/services/email_service.d.ts.map +1 -1
- package/dist/lib/services/email_service.js +93 -221
- package/dist/lib/services/email_template_manifest.d.ts +11 -0
- package/dist/lib/services/email_template_manifest.d.ts.map +1 -0
- package/dist/lib/services/email_template_manifest.js +95 -0
- package/dist/lib/services/email_templates/email_verification.html +18 -0
- package/dist/lib/services/email_templates/email_verification.txt +9 -0
- package/dist/lib/services/email_templates/forgot_password.html +18 -0
- package/dist/lib/services/email_templates/forgot_password.txt +9 -0
- package/dist/lib/services/email_templates/password_changed.html +14 -0
- package/dist/lib/services/email_templates/password_changed.txt +9 -0
- package/dist/lib/services/session_token_service.js +2 -2
- package/dist/lib/ui_shell_config.server.d.ts.map +1 -1
- package/dist/lib/ui_shell_config.server.js +6 -2
- package/dist/server/routes/oauth_google_callback.d.ts.map +1 -1
- package/dist/server/routes/oauth_google_callback.js +33 -6
- package/dist/server-lib.d.ts +1 -0
- package/dist/server-lib.d.ts.map +1 -1
- package/dist/server-lib.js +1 -0
- package/dist/server_pages/login.d.ts +13 -1
- package/dist/server_pages/login.d.ts.map +1 -1
- package/dist/server_pages/login.js +25 -9
- package/dist/server_pages/login_client_wrapper.d.ts +6 -4
- package/dist/server_pages/login_client_wrapper.d.ts.map +1 -1
- package/dist/server_pages/login_client_wrapper.js +2 -2
- package/dist/server_pages/register.d.ts +7 -1
- package/dist/server_pages/register.d.ts.map +1 -1
- package/dist/server_pages/register.js +18 -9
- package/dist/server_pages/register_client_wrapper.d.ts +6 -4
- package/dist/server_pages/register_client_wrapper.d.ts.map +1 -1
- package/dist/server_pages/register_client_wrapper.js +2 -2
- package/package.json +26 -20
- package/cli-src/assets/images/new_firm_default.jpg +0 -0
- package/cli-src/lib/auth/org_cache.ts +0 -148
- package/cli-src/lib/index.ts +0 -48
- package/cli-src/lib/services/org_service.ts +0 -965
- package/cli-src/lib/services/scope_labels_service.ts +0 -348
|
@@ -25,10 +25,18 @@ export async function GET(original_request) {
|
|
|
25
25
|
// Detect if request came through HTTPS proxy (Cloudflare tunnel, etc.)
|
|
26
26
|
const is_secure = original_request.headers.get("x-forwarded-proto") === "https" ||
|
|
27
27
|
request.url.startsWith("https://");
|
|
28
|
+
// Resolve the configured sign-in page up-front so the early error redirects
|
|
29
|
+
// (no token / missing data) honour [hazo_auth__oauth] sign_in_page just like
|
|
30
|
+
// the success path. Defaults to `/hazo_auth/login` for back-compat.
|
|
31
|
+
const sign_in_page = get_oauth_config().sign_in_page;
|
|
28
32
|
try {
|
|
29
33
|
// Get the NextAuth token from the session
|
|
30
34
|
// When behind HTTPS proxy, next-auth uses __Secure- cookie prefix
|
|
31
35
|
const token = (await getToken({
|
|
36
|
+
// next-auth@4 was typed against an older next/server NextRequest that
|
|
37
|
+
// still carried `geo`, `ip`, and the `[INTERNALS]` symbol. Next 16
|
|
38
|
+
// dropped those, leaving the two NextRequest types structurally
|
|
39
|
+
// incompatible at the type level even though the runtime shape is fine.
|
|
32
40
|
req: request,
|
|
33
41
|
secureCookie: is_secure,
|
|
34
42
|
}));
|
|
@@ -47,7 +55,7 @@ export async function GET(original_request) {
|
|
|
47
55
|
note: "No NextAuth token found - user may not have completed Google sign-in",
|
|
48
56
|
});
|
|
49
57
|
// Redirect to login with error — use .toString() to ensure absolute URL
|
|
50
|
-
const login_url = new URL(
|
|
58
|
+
const login_url = new URL(sign_in_page, request.url);
|
|
51
59
|
login_url.searchParams.set("error", "oauth_failed");
|
|
52
60
|
return NextResponse.redirect(login_url.toString());
|
|
53
61
|
}
|
|
@@ -60,13 +68,13 @@ export async function GET(original_request) {
|
|
|
60
68
|
has_hazo_user_id: !!token.hazo_user_id,
|
|
61
69
|
has_google_id: !!token.google_id,
|
|
62
70
|
});
|
|
63
|
-
const login_url = new URL(
|
|
71
|
+
const login_url = new URL(sign_in_page, request.url);
|
|
64
72
|
login_url.searchParams.set("error", "oauth_incomplete");
|
|
65
73
|
return NextResponse.redirect(login_url.toString());
|
|
66
74
|
}
|
|
67
75
|
const user_id = token.hazo_user_id;
|
|
68
76
|
const email = token.email;
|
|
69
|
-
logger.
|
|
77
|
+
logger.debug("google_callback_success", {
|
|
70
78
|
filename: get_filename(),
|
|
71
79
|
line_number: get_line_number(),
|
|
72
80
|
user_id,
|
|
@@ -75,13 +83,32 @@ export async function GET(original_request) {
|
|
|
75
83
|
// Get redirect URL based on user's scope/invitation status
|
|
76
84
|
const loginConfig = get_login_config();
|
|
77
85
|
const oauthConfig = get_oauth_config();
|
|
86
|
+
// Per-request override: the login/register layouts can encode a
|
|
87
|
+
// `?next=<path>` query param into the GoogleSignInButton callback URL,
|
|
88
|
+
// letting consumer flows (e.g. invite-link landings) keep the user on
|
|
89
|
+
// their original target after the OAuth round-trip rather than
|
|
90
|
+
// bouncing through the static `oauthConfig.default_redirect`.
|
|
91
|
+
//
|
|
92
|
+
// Validation: must be a same-origin path (starts with `/`, not `//`,
|
|
93
|
+
// no protocol). Anything else is dropped — prevents an open-redirect
|
|
94
|
+
// attack where a hostile referrer crafts a `next=//evil.com` URL.
|
|
95
|
+
const raw_next = request.nextUrl.searchParams.get("next");
|
|
96
|
+
const safe_next = raw_next &&
|
|
97
|
+
raw_next.startsWith("/") &&
|
|
98
|
+
!raw_next.startsWith("//") &&
|
|
99
|
+
!/^[a-z][a-z0-9+.\-]*:/i.test(raw_next)
|
|
100
|
+
? raw_next
|
|
101
|
+
: null;
|
|
78
102
|
// Check if user needs onboarding (no scope, no invitation = create firm)
|
|
79
103
|
const hazoConnect = get_hazo_connect_instance();
|
|
80
104
|
const { redirect_url: determined_redirect, needs_onboarding, invitation_check_skipped, invitation_table_error, } = await get_post_login_redirect(hazoConnect, user_id, email, {
|
|
81
|
-
default_redirect: oauthConfig.default_redirect || loginConfig.redirectRoute || "/",
|
|
105
|
+
default_redirect: safe_next || oauthConfig.default_redirect || loginConfig.redirectRoute || "/",
|
|
82
106
|
create_firm_url: oauthConfig.create_firm_url,
|
|
83
107
|
skip_invitation_check: oauthConfig.skip_invitation_check,
|
|
84
|
-
no_scope_redirect
|
|
108
|
+
// When a per-request next= is set, override no_scope_redirect too.
|
|
109
|
+
// Otherwise an invite recipient (no scope yet) would still get
|
|
110
|
+
// bounced to /onboarding instead of back to the invite landing.
|
|
111
|
+
no_scope_redirect: safe_next || oauthConfig.no_scope_redirect,
|
|
85
112
|
});
|
|
86
113
|
// Log warning if invitation table is missing
|
|
87
114
|
if (invitation_table_error) {
|
|
@@ -93,7 +120,7 @@ export async function GET(original_request) {
|
|
|
93
120
|
note: "hazo_invitations table does not exist - run migration or set skip_invitation_check=true in [hazo_auth__oauth]",
|
|
94
121
|
});
|
|
95
122
|
}
|
|
96
|
-
logger.
|
|
123
|
+
logger.debug("google_callback_post_login_redirect", {
|
|
97
124
|
filename: get_filename(),
|
|
98
125
|
line_number: get_line_number(),
|
|
99
126
|
user_id,
|
package/dist/server-lib.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import "server-only";
|
|
2
2
|
export * from "./lib/auth/index.js";
|
|
3
3
|
export * from "./lib/services/index.js";
|
|
4
|
+
export { hazo_auth_template_manifest } from "./lib/services/email_template_manifest.js";
|
|
4
5
|
export { get_config_value, get_config_number, get_config_boolean, get_config_array, read_config_section, } from "./lib/config/config_loader.server.js";
|
|
5
6
|
export { get_login_config } from "./lib/login_config.server.js";
|
|
6
7
|
export { get_register_config } from "./lib/register_config.server.js";
|
package/dist/server-lib.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server-lib.d.ts","sourceRoot":"","sources":["../src/server-lib.ts"],"names":[],"mappings":"AAYA,OAAO,aAAa,CAAC;AAGrB,cAAc,kBAAkB,CAAC;AAGjC,cAAc,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"server-lib.d.ts","sourceRoot":"","sources":["../src/server-lib.ts"],"names":[],"mappings":"AAYA,OAAO,aAAa,CAAC;AAGrB,cAAc,kBAAkB,CAAC;AAGjC,cAAc,sBAAsB,CAAC;AACrC,OAAO,EAAE,2BAA2B,EAAE,MAAM,wCAAwC,CAAC;AAGrF,OAAO,EACL,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,gBAAgB,EAChB,mBAAmB,GACpB,MAAM,mCAAmC,CAAC;AAG3C,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,0BAA0B,EAAE,MAAM,qCAAqC,CAAC;AACjF,OAAO,EAAE,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAC/E,OAAO,EAAE,6BAA6B,EAAE,MAAM,wCAAwC,CAAC;AACvF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iCAAiC,CAAC;AACzE,OAAO,EAAE,0BAA0B,EAAE,MAAM,qCAAqC,CAAC;AACjF,OAAO,EAAE,0BAA0B,EAAE,MAAM,qCAAqC,CAAC;AACjF,OAAO,EAAE,2BAA2B,EAAE,MAAM,sCAAsC,CAAC;AACnF,OAAO,EAAE,4BAA4B,EAAE,MAAM,uCAAuC,CAAC;AACrF,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,EAAE,gCAAgC,EAAE,MAAM,2CAA2C,CAAC;AAC7F,OAAO,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,sBAAsB,EAAE,MAAM,iCAAiC,CAAC;AACzE,OAAO,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AACvE,OAAO,EACL,gBAAgB,EAChB,uBAAuB,EACvB,yBAAyB,GAC1B,MAAM,2BAA2B,CAAC;AACnC,YAAY,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAC7D,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,sBAAsB,EACtB,uBAAuB,GACxB,MAAM,8BAA8B,CAAC;AACtC,YAAY,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AAGvE,OAAO,EAAE,0BAA0B,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,EAAE,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAG/E,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAGrD,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AACtE,YAAY,EAAE,wBAAwB,EAAE,MAAM,6BAA6B,CAAC;AAC5E,cAAc,+BAA+B,CAAC"}
|
package/dist/server-lib.js
CHANGED
|
@@ -14,6 +14,7 @@ import "server-only";
|
|
|
14
14
|
export * from "./lib/auth/index.js";
|
|
15
15
|
// section: service_exports
|
|
16
16
|
export * from "./lib/services/index.js";
|
|
17
|
+
export { hazo_auth_template_manifest } from "./lib/services/email_template_manifest.js";
|
|
17
18
|
// section: config_exports
|
|
18
19
|
export { get_config_value, get_config_number, get_config_boolean, get_config_array, read_config_section, } from "./lib/config/config_loader.server.js";
|
|
19
20
|
// section: config_server_exports
|
|
@@ -16,6 +16,18 @@ export type LoginPageProps = {
|
|
|
16
16
|
* Defaults to "#f1f5f9"
|
|
17
17
|
*/
|
|
18
18
|
image_background_color?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Layout mode (default: `"two_column"`).
|
|
21
|
+
* - `"two_column"` — full server-rendered page with the package's
|
|
22
|
+
* TwoColumnAuthLayout (image on the left, form on the right) wrapped in
|
|
23
|
+
* the standalone AuthPageShell. Backwards-compatible.
|
|
24
|
+
* - `"form_only"` — emits just the form content (no AuthPageShell, no
|
|
25
|
+
* TwoColumnAuthLayout). Use when wrapping the form in your own brand
|
|
26
|
+
* chrome (e.g. a custom split-panel layout or an existing app shell).
|
|
27
|
+
* `image_src` / `image_alt` / `image_background_color` are ignored in
|
|
28
|
+
* this mode.
|
|
29
|
+
*/
|
|
30
|
+
layout?: "two_column" | "form_only";
|
|
19
31
|
};
|
|
20
32
|
/**
|
|
21
33
|
* Zero-config LoginPage server component
|
|
@@ -40,6 +52,6 @@ export type LoginPageProps = {
|
|
|
40
52
|
* @param props - Optional visual customization props
|
|
41
53
|
* @returns Server-rendered login page
|
|
42
54
|
*/
|
|
43
|
-
export default function LoginPage({ image_src, image_alt, image_background_color, }?: LoginPageProps): import("react/jsx-runtime").JSX.Element;
|
|
55
|
+
export default function LoginPage({ image_src, image_alt, image_background_color, layout, }?: LoginPageProps): import("react/jsx-runtime").JSX.Element;
|
|
44
56
|
export { LoginPage };
|
|
45
57
|
//# sourceMappingURL=login.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"login.d.ts","sourceRoot":"","sources":["../../src/server_pages/login.tsx"],"names":[],"mappings":"AAEA,OAAO,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"login.d.ts","sourceRoot":"","sources":["../../src/server_pages/login.tsx"],"names":[],"mappings":"AAEA,OAAO,aAAa,CAAC;AASrB,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,cAAc,GAAG;IAC3B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC;IAErC;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAEhC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,YAAY,GAAG,WAAW,CAAC;CACrC,CAAC;AAGF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,EAChC,SAAS,EACT,SAAS,EACT,sBAAsB,EACtB,MAAqB,GACtB,GAAE,cAAmB,2CA2DrB;AAGD,OAAO,EAAE,SAAS,EAAE,CAAC"}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
// file_description: Zero-config LoginPage server component - drop in and use with no configuration required
|
|
3
3
|
// section: server-only-guard
|
|
4
4
|
import "server-only";
|
|
5
5
|
// section: imports
|
|
6
6
|
import { get_login_config } from "../lib/login_config.server.js";
|
|
7
|
+
import { get_navbar_config } from "../lib/navbar_config.server.js";
|
|
7
8
|
import { LoginClientWrapper } from "./login_client_wrapper.js";
|
|
8
9
|
import { AuthPageShell } from "../components/layouts/shared/components/auth_page_shell.js";
|
|
10
|
+
import { FloatingHomeLink } from "../components/layouts/shared/components/floating_home_link.js";
|
|
9
11
|
// section: component
|
|
10
12
|
/**
|
|
11
13
|
* Zero-config LoginPage server component
|
|
@@ -30,20 +32,34 @@ import { AuthPageShell } from "../components/layouts/shared/components/auth_page
|
|
|
30
32
|
* @param props - Optional visual customization props
|
|
31
33
|
* @returns Server-rendered login page
|
|
32
34
|
*/
|
|
33
|
-
export default function LoginPage({ image_src, image_alt, image_background_color, } = {}) {
|
|
35
|
+
export default function LoginPage({ image_src, image_alt, image_background_color, layout = "two_column", } = {}) {
|
|
34
36
|
// Load configuration from INI file (with defaults including asset images)
|
|
35
37
|
const config = get_login_config();
|
|
36
38
|
// Use props if provided, otherwise fall back to config (which includes default asset image)
|
|
37
39
|
const finalImageSrc = image_src || config.imageSrc;
|
|
38
40
|
const finalImageAlt = image_alt || config.imageAlt;
|
|
39
41
|
const finalImageBackgroundColor = image_background_color || config.imageBackgroundColor;
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
42
|
+
const wrapper = (_jsx(LoginClientWrapper, { image_src: finalImageSrc, image_alt: finalImageAlt, image_background_color: finalImageBackgroundColor, redirectRoute: config.redirectRoute, successMessage: config.successMessage, alreadyLoggedInMessage: config.alreadyLoggedInMessage, showLogoutButton: config.showLogoutButton, showReturnHomeButton: config.showReturnHomeButton, returnHomeButtonLabel: config.returnHomeButtonLabel, returnHomePath: config.returnHomePath, forgotPasswordPath: config.forgotPasswordPath, forgotPasswordLabel: config.forgotPasswordLabel, createAccountPath: config.createAccountPath, createAccountLabel: config.createAccountLabel, showCreateAccountLink: config.showCreateAccountLink, oauth: {
|
|
43
|
+
enable_google: config.oauth.enable_google,
|
|
44
|
+
enable_email_password: config.oauth.enable_email_password,
|
|
45
|
+
google_button_text: config.oauth.google_button_text,
|
|
46
|
+
oauth_divider_text: config.oauth.oauth_divider_text,
|
|
47
|
+
}, layout: layout }));
|
|
48
|
+
// form_only mode: skip AuthPageShell so the consumer's own page chrome
|
|
49
|
+
// (e.g. a split-panel AuthLayout) hosts the form without our standalone
|
|
50
|
+
// wrapper interfering. Two-column mode keeps the existing AuthPageShell
|
|
51
|
+
// wrap for navbar/centering support.
|
|
52
|
+
//
|
|
53
|
+
// The navbar config's home_link is also surfaced here in form_only mode
|
|
54
|
+
// so users mid-auth-flow always have a way out — without this, the only
|
|
55
|
+
// exit is the browser back button. Rendered as a fixed-position "Back to
|
|
56
|
+
// home" pill (top-left). Disabled by setting `[hazo_auth__navbar]
|
|
57
|
+
// show_home_link = false` or by hiding it CSS-side at the consumer.
|
|
58
|
+
if (layout === "form_only") {
|
|
59
|
+
const navbar = get_navbar_config();
|
|
60
|
+
return (_jsxs(_Fragment, { children: [navbar.show_home_link && (_jsx(FloatingHomeLink, { path: navbar.home_path, label: navbar.home_label })), wrapper] }));
|
|
61
|
+
}
|
|
62
|
+
return _jsx(AuthPageShell, { children: wrapper });
|
|
47
63
|
}
|
|
48
64
|
// Named export for direct imports
|
|
49
65
|
export { LoginPage };
|
|
@@ -2,17 +2,19 @@ import type { LoginConfig } from "../lib/login_config.server";
|
|
|
2
2
|
import type { OAuthLayoutConfig } from "../components/layouts/login/index";
|
|
3
3
|
import type { StaticImageData } from "next/image";
|
|
4
4
|
export type LoginClientWrapperProps = Omit<LoginConfig, 'imageSrc' | 'imageAlt' | 'imageBackgroundColor' | 'oauth' | 'showCreateAccountLink'> & {
|
|
5
|
-
image_src
|
|
6
|
-
image_alt
|
|
7
|
-
image_background_color
|
|
5
|
+
image_src?: string | StaticImageData;
|
|
6
|
+
image_alt?: string;
|
|
7
|
+
image_background_color?: string;
|
|
8
8
|
/** Show/hide "Create account" link (default: true) */
|
|
9
9
|
showCreateAccountLink?: boolean;
|
|
10
10
|
/** OAuth configuration */
|
|
11
11
|
oauth?: OAuthLayoutConfig;
|
|
12
|
+
/** Layout mode — see LoginLayoutProps.layout. Default `"two_column"`. */
|
|
13
|
+
layout?: "two_column" | "form_only";
|
|
12
14
|
};
|
|
13
15
|
/**
|
|
14
16
|
* Client wrapper for LoginLayout
|
|
15
17
|
* Initializes hazo_connect data client on client side and passes config from server
|
|
16
18
|
*/
|
|
17
|
-
export declare function LoginClientWrapper({ image_src, image_alt, image_background_color, redirectRoute, successMessage, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, forgotPasswordPath, forgotPasswordLabel, createAccountPath, createAccountLabel, showCreateAccountLink, oauth, }: LoginClientWrapperProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function LoginClientWrapper({ image_src, image_alt, image_background_color, redirectRoute, successMessage, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, forgotPasswordPath, forgotPasswordLabel, createAccountPath, createAccountLabel, showCreateAccountLink, oauth, layout, }: LoginClientWrapperProps): import("react/jsx-runtime").JSX.Element;
|
|
18
20
|
//# sourceMappingURL=login_client_wrapper.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"login_client_wrapper.d.ts","sourceRoot":"","sources":["../../src/server_pages/login_client_wrapper.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAG3E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,uBAAuB,GAAG,IAAI,CAAC,WAAW,EAAE,UAAU,GAAG,UAAU,GAAG,sBAAsB,GAAG,OAAO,GAAG,uBAAuB,CAAC,GAAG;IAC9I,SAAS,EAAE,MAAM,GAAG,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"login_client_wrapper.d.ts","sourceRoot":"","sources":["../../src/server_pages/login_client_wrapper.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAG3E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,uBAAuB,GAAG,IAAI,CAAC,WAAW,EAAE,UAAU,GAAG,UAAU,GAAG,sBAAsB,GAAG,OAAO,GAAG,uBAAuB,CAAC,GAAG;IAC9I,SAAS,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC;IACrC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,sDAAsD;IACtD,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,0BAA0B;IAC1B,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAC1B,yEAAyE;IACzE,MAAM,CAAC,EAAE,YAAY,GAAG,WAAW,CAAC;CACrC,CAAC;AAGF;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,EACjC,SAAS,EACT,SAAS,EACT,sBAAsB,EACtB,aAAa,EACb,cAAc,EACd,sBAAsB,EACtB,gBAAgB,EAChB,oBAAoB,EACpB,qBAAqB,EACrB,cAAc,EACd,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,EAClB,qBAA4B,EAC5B,KAAK,EACL,MAAqB,GACtB,EAAE,uBAAuB,2CA0CzB"}
|
|
@@ -11,7 +11,7 @@ import { create_sqlite_hazo_connect } from "../lib/hazo_connect_setup.js";
|
|
|
11
11
|
* Client wrapper for LoginLayout
|
|
12
12
|
* Initializes hazo_connect data client on client side and passes config from server
|
|
13
13
|
*/
|
|
14
|
-
export function LoginClientWrapper({ image_src, image_alt, image_background_color, redirectRoute, successMessage, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, forgotPasswordPath, forgotPasswordLabel, createAccountPath, createAccountLabel, showCreateAccountLink = true, oauth, }) {
|
|
14
|
+
export function LoginClientWrapper({ image_src, image_alt, image_background_color, redirectRoute, successMessage, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, forgotPasswordPath, forgotPasswordLabel, createAccountPath, createAccountLabel, showCreateAccountLink = true, oauth, layout = "two_column", }) {
|
|
15
15
|
const [dataClient, setDataClient] = useState(null);
|
|
16
16
|
useEffect(() => {
|
|
17
17
|
// Initialize hazo_connect on client side
|
|
@@ -23,5 +23,5 @@ export function LoginClientWrapper({ image_src, image_alt, image_background_colo
|
|
|
23
23
|
if (!dataClient) {
|
|
24
24
|
return (_jsx("div", { className: "cls_login_page_loading flex items-center justify-center min-h-screen", children: _jsx("div", { className: "text-slate-600 animate-pulse", children: "Loading..." }) }));
|
|
25
25
|
}
|
|
26
|
-
return (_jsx(LoginLayout, { image_src: image_src, image_alt: image_alt, image_background_color: image_background_color, data_client: dataClient, redirectRoute: redirectRoute, successMessage: successMessage, alreadyLoggedInMessage: alreadyLoggedInMessage, showLogoutButton: showLogoutButton, showReturnHomeButton: showReturnHomeButton, returnHomeButtonLabel: returnHomeButtonLabel, returnHomePath: returnHomePath, forgot_password_path: forgotPasswordPath, forgot_password_label: forgotPasswordLabel, create_account_path: createAccountPath, create_account_label: createAccountLabel, show_create_account_link: showCreateAccountLink, oauth: oauth }));
|
|
26
|
+
return (_jsx(LoginLayout, { image_src: image_src, image_alt: image_alt, image_background_color: image_background_color, data_client: dataClient, redirectRoute: redirectRoute, successMessage: successMessage, alreadyLoggedInMessage: alreadyLoggedInMessage, showLogoutButton: showLogoutButton, showReturnHomeButton: showReturnHomeButton, returnHomeButtonLabel: returnHomeButtonLabel, returnHomePath: returnHomePath, forgot_password_path: forgotPasswordPath, forgot_password_label: forgotPasswordLabel, create_account_path: createAccountPath, create_account_label: createAccountLabel, show_create_account_link: showCreateAccountLink, oauth: oauth, layout: layout }));
|
|
27
27
|
}
|
|
@@ -16,6 +16,12 @@ export type RegisterPageProps = {
|
|
|
16
16
|
* Defaults from hazo_auth_config.ini or "#e2e8f0"
|
|
17
17
|
*/
|
|
18
18
|
image_background_color?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Layout mode (default: `"two_column"`). See `LoginPageProps.layout` for the
|
|
21
|
+
* full description. `"form_only"` skips both AuthPageShell and
|
|
22
|
+
* TwoColumnAuthLayout so the consumer's brand chrome can wrap the form.
|
|
23
|
+
*/
|
|
24
|
+
layout?: "two_column" | "form_only";
|
|
19
25
|
};
|
|
20
26
|
/**
|
|
21
27
|
* Zero-config RegisterPage server component
|
|
@@ -42,6 +48,6 @@ export type RegisterPageProps = {
|
|
|
42
48
|
* @param props - Optional visual customization props
|
|
43
49
|
* @returns Server-rendered register page
|
|
44
50
|
*/
|
|
45
|
-
export default function RegisterPage({ image_src, image_alt, image_background_color, }?: RegisterPageProps): import("react/jsx-runtime").JSX.Element;
|
|
51
|
+
export default function RegisterPage({ image_src, image_alt, image_background_color, layout, }?: RegisterPageProps): import("react/jsx-runtime").JSX.Element;
|
|
46
52
|
export { RegisterPage };
|
|
47
53
|
//# sourceMappingURL=register.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"register.d.ts","sourceRoot":"","sources":["../../src/server_pages/register.tsx"],"names":[],"mappings":"AAEA,OAAO,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"register.d.ts","sourceRoot":"","sources":["../../src/server_pages/register.tsx"],"names":[],"mappings":"AAEA,OAAO,aAAa,CAAC;AASrB,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,iBAAiB,GAAG;IAC9B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC;IAErC;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAEhC;;;;OAIG;IACH,MAAM,CAAC,EAAE,YAAY,GAAG,WAAW,CAAC;CACrC,CAAC;AAIF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,EACnC,SAAS,EACT,SAAS,EACT,sBAAsB,EACtB,MAAqB,GACtB,GAAE,iBAAsB,2CAiDxB;AAGD,OAAO,EAAE,YAAY,EAAE,CAAC"}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
// file_description: Zero-config RegisterPage server component - drop in and use with no configuration required
|
|
3
3
|
// section: server-only-guard
|
|
4
4
|
import "server-only";
|
|
5
5
|
// section: imports
|
|
6
6
|
import { get_register_config } from "../lib/register_config.server.js";
|
|
7
|
+
import { get_navbar_config } from "../lib/navbar_config.server.js";
|
|
7
8
|
import { RegisterClientWrapper } from "./register_client_wrapper.js";
|
|
8
9
|
import { AuthPageShell } from "../components/layouts/shared/components/auth_page_shell.js";
|
|
10
|
+
import { FloatingHomeLink } from "../components/layouts/shared/components/floating_home_link.js";
|
|
9
11
|
// section: component
|
|
10
12
|
/**
|
|
11
13
|
* Zero-config RegisterPage server component
|
|
@@ -32,20 +34,27 @@ import { AuthPageShell } from "../components/layouts/shared/components/auth_page
|
|
|
32
34
|
* @param props - Optional visual customization props
|
|
33
35
|
* @returns Server-rendered register page
|
|
34
36
|
*/
|
|
35
|
-
export default function RegisterPage({ image_src, image_alt, image_background_color, } = {}) {
|
|
37
|
+
export default function RegisterPage({ image_src, image_alt, image_background_color, layout = "two_column", } = {}) {
|
|
36
38
|
// Load configuration from INI file (with defaults including asset images)
|
|
37
39
|
const config = get_register_config();
|
|
38
40
|
// Use props if provided, otherwise fall back to config (which includes default asset image)
|
|
39
41
|
const finalImageSrc = image_src || config.imageSrc;
|
|
40
42
|
const finalImageAlt = image_alt || config.imageAlt;
|
|
41
43
|
const finalImageBackgroundColor = image_background_color || config.imageBackgroundColor;
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
44
|
+
const wrapper = (_jsx(RegisterClientWrapper, { image_src: finalImageSrc, image_alt: finalImageAlt, image_background_color: finalImageBackgroundColor, showNameField: config.showNameField, passwordRequirements: config.passwordRequirements, alreadyLoggedInMessage: config.alreadyLoggedInMessage, showLogoutButton: config.showLogoutButton, showReturnHomeButton: config.showReturnHomeButton, returnHomeButtonLabel: config.returnHomeButtonLabel, returnHomePath: config.returnHomePath, signInPath: config.signInPath, signInLabel: config.signInLabel, oauth: {
|
|
45
|
+
enable_google: config.oauth.enable_google,
|
|
46
|
+
enable_email_password: config.oauth.enable_email_password,
|
|
47
|
+
google_button_text: config.oauth.google_button_text,
|
|
48
|
+
oauth_divider_text: config.oauth.oauth_divider_text,
|
|
49
|
+
}, layout: layout }));
|
|
50
|
+
// form_only mode: skip AuthPageShell so the consumer's own page chrome
|
|
51
|
+
// hosts the form. See LoginPage for the full rationale, including the
|
|
52
|
+
// FloatingHomeLink rendering rule below.
|
|
53
|
+
if (layout === "form_only") {
|
|
54
|
+
const navbar = get_navbar_config();
|
|
55
|
+
return (_jsxs(_Fragment, { children: [navbar.show_home_link && (_jsx(FloatingHomeLink, { path: navbar.home_path, label: navbar.home_label })), wrapper] }));
|
|
56
|
+
}
|
|
57
|
+
return _jsx(AuthPageShell, { children: wrapper });
|
|
49
58
|
}
|
|
50
59
|
// Named export for direct imports
|
|
51
60
|
export { RegisterPage };
|
|
@@ -2,15 +2,17 @@ import type { RegisterConfig } from "../lib/register_config.server";
|
|
|
2
2
|
import type { OAuthLayoutConfig } from "../components/layouts/register/index";
|
|
3
3
|
import type { StaticImageData } from "next/image";
|
|
4
4
|
export type RegisterClientWrapperProps = Omit<RegisterConfig, 'imageSrc' | 'imageAlt' | 'imageBackgroundColor' | 'oauth'> & {
|
|
5
|
-
image_src
|
|
6
|
-
image_alt
|
|
7
|
-
image_background_color
|
|
5
|
+
image_src?: string | StaticImageData;
|
|
6
|
+
image_alt?: string;
|
|
7
|
+
image_background_color?: string;
|
|
8
8
|
/** OAuth configuration */
|
|
9
9
|
oauth?: OAuthLayoutConfig;
|
|
10
|
+
/** Layout mode — see RegisterLayoutProps.layout. Default `"two_column"`. */
|
|
11
|
+
layout?: "two_column" | "form_only";
|
|
10
12
|
};
|
|
11
13
|
/**
|
|
12
14
|
* Client wrapper for RegisterLayout
|
|
13
15
|
* Initializes hazo_connect data client on client side and passes config from server
|
|
14
16
|
*/
|
|
15
|
-
export declare function RegisterClientWrapper({ image_src, image_alt, image_background_color, showNameField, passwordRequirements, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, signInPath, signInLabel, oauth, }: RegisterClientWrapperProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare function RegisterClientWrapper({ image_src, image_alt, image_background_color, showNameField, passwordRequirements, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, signInPath, signInLabel, oauth, layout, }: RegisterClientWrapperProps): import("react/jsx-runtime").JSX.Element;
|
|
16
18
|
//# sourceMappingURL=register_client_wrapper.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"register_client_wrapper.d.ts","sourceRoot":"","sources":["../../src/server_pages/register_client_wrapper.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AACpE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sCAAsC,CAAC;AAG9E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,0BAA0B,GAAG,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,UAAU,GAAG,sBAAsB,GAAG,OAAO,CAAC,GAAG;IAC1H,SAAS,EAAE,MAAM,GAAG,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"register_client_wrapper.d.ts","sourceRoot":"","sources":["../../src/server_pages/register_client_wrapper.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AACpE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sCAAsC,CAAC;AAG9E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAElD,MAAM,MAAM,0BAA0B,GAAG,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,UAAU,GAAG,sBAAsB,GAAG,OAAO,CAAC,GAAG;IAC1H,SAAS,CAAC,EAAE,MAAM,GAAG,eAAe,CAAC;IACrC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,0BAA0B;IAC1B,KAAK,CAAC,EAAE,iBAAiB,CAAC;IAC1B,4EAA4E;IAC5E,MAAM,CAAC,EAAE,YAAY,GAAG,WAAW,CAAC;CACrC,CAAC;AAGF;;;GAGG;AACH,wBAAgB,qBAAqB,CAAC,EACpC,SAAS,EACT,SAAS,EACT,sBAAsB,EACtB,aAAa,EACb,oBAAoB,EACpB,sBAAsB,EACtB,gBAAgB,EAChB,oBAAoB,EACpB,qBAAqB,EACrB,cAAc,EACd,UAAU,EACV,WAAW,EACX,KAAK,EACL,MAAqB,GACtB,EAAE,0BAA0B,2CAuC5B"}
|
|
@@ -11,7 +11,7 @@ import { create_sqlite_hazo_connect } from "../lib/hazo_connect_setup.js";
|
|
|
11
11
|
* Client wrapper for RegisterLayout
|
|
12
12
|
* Initializes hazo_connect data client on client side and passes config from server
|
|
13
13
|
*/
|
|
14
|
-
export function RegisterClientWrapper({ image_src, image_alt, image_background_color, showNameField, passwordRequirements, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, signInPath, signInLabel, oauth, }) {
|
|
14
|
+
export function RegisterClientWrapper({ image_src, image_alt, image_background_color, showNameField, passwordRequirements, alreadyLoggedInMessage, showLogoutButton, showReturnHomeButton, returnHomeButtonLabel, returnHomePath, signInPath, signInLabel, oauth, layout = "two_column", }) {
|
|
15
15
|
const [dataClient, setDataClient] = useState(null);
|
|
16
16
|
useEffect(() => {
|
|
17
17
|
// Initialize hazo_connect on client side
|
|
@@ -23,5 +23,5 @@ export function RegisterClientWrapper({ image_src, image_alt, image_background_c
|
|
|
23
23
|
if (!dataClient) {
|
|
24
24
|
return (_jsx("div", { className: "cls_register_page_loading flex items-center justify-center min-h-screen", children: _jsx("div", { className: "text-slate-600 animate-pulse", children: "Loading..." }) }));
|
|
25
25
|
}
|
|
26
|
-
return (_jsx(RegisterLayout, { image_src: image_src, image_alt: image_alt, image_background_color: image_background_color, data_client: dataClient, show_name_field: showNameField, password_requirements: passwordRequirements, alreadyLoggedInMessage: alreadyLoggedInMessage, showLogoutButton: showLogoutButton, showReturnHomeButton: showReturnHomeButton, returnHomeButtonLabel: returnHomeButtonLabel, returnHomePath: returnHomePath, signInPath: signInPath, signInLabel: signInLabel, oauth: oauth }));
|
|
26
|
+
return (_jsx(RegisterLayout, { image_src: image_src, image_alt: image_alt, image_background_color: image_background_color, data_client: dataClient, show_name_field: showNameField, password_requirements: passwordRequirements, alreadyLoggedInMessage: alreadyLoggedInMessage, showLogoutButton: showLogoutButton, showReturnHomeButton: showReturnHomeButton, returnHomeButtonLabel: returnHomeButtonLabel, returnHomePath: returnHomePath, signInPath: signInPath, signInLabel: signInLabel, oauth: oauth, layout: layout }));
|
|
27
27
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hazo_auth",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.3.0",
|
|
4
4
|
"description": "Zero-config authentication UI components for Next.js with RBAC, OAuth, scope-based multi-tenancy, and invitations",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"authentication",
|
|
@@ -89,6 +89,10 @@
|
|
|
89
89
|
"types": "./dist/lib/auth/hazo_get_auth.server.d.ts",
|
|
90
90
|
"import": "./dist/lib/auth/hazo_get_auth.server.js"
|
|
91
91
|
},
|
|
92
|
+
"./lib/auth/ensure_anon_id.server": {
|
|
93
|
+
"types": "./dist/lib/auth/ensure_anon_id.server.d.ts",
|
|
94
|
+
"import": "./dist/lib/auth/ensure_anon_id.server.js"
|
|
95
|
+
},
|
|
92
96
|
"./server": {
|
|
93
97
|
"types": "./dist/server/index.d.ts",
|
|
94
98
|
"import": "./dist/server/index.js"
|
|
@@ -189,6 +193,7 @@
|
|
|
189
193
|
"dev": "next dev",
|
|
190
194
|
"build": "next build",
|
|
191
195
|
"build:pkg": "tsc --jsx react-jsx --skipLibCheck -p tsconfig.build.json && tsx scripts/copy_assets.ts",
|
|
196
|
+
"prepare": "npm run build:pkg",
|
|
192
197
|
"prepublishOnly": "npm run build:pkg",
|
|
193
198
|
"validate": "tsx scripts/validate_setup.ts",
|
|
194
199
|
"generate-routes": "tsx scripts/generate_routes.ts",
|
|
@@ -214,8 +219,8 @@
|
|
|
214
219
|
"jsonwebtoken": "^9.0.2",
|
|
215
220
|
"mime-types": "^3.0.1",
|
|
216
221
|
"server-only": "^0.0.1",
|
|
217
|
-
"tailwind-merge": "^3.
|
|
218
|
-
"
|
|
222
|
+
"tailwind-merge": "^3.5.0",
|
|
223
|
+
"tw-animate-css": "^1.4.0",
|
|
219
224
|
"zod": "^4.1.12"
|
|
220
225
|
},
|
|
221
226
|
"optionalDependencies": {
|
|
@@ -244,18 +249,18 @@
|
|
|
244
249
|
"@radix-ui/react-switch": "^1.2.0",
|
|
245
250
|
"@radix-ui/react-tabs": "^1.1.0",
|
|
246
251
|
"@radix-ui/react-tooltip": "^1.2.0",
|
|
247
|
-
"hazo_config": "^
|
|
252
|
+
"hazo_config": "^2.1.0",
|
|
248
253
|
"hazo_connect": "^2.4.0",
|
|
249
|
-
"hazo_logs": "^1.0.
|
|
250
|
-
"hazo_notify": "^
|
|
251
|
-
"hazo_ui": "^2.
|
|
252
|
-
"lucide-react": "
|
|
254
|
+
"hazo_logs": "^1.0.13",
|
|
255
|
+
"hazo_notify": "^3.0.0",
|
|
256
|
+
"hazo_ui": "^2.7.0",
|
|
257
|
+
"lucide-react": "^0.553.0",
|
|
253
258
|
"next": ">=14.0.0",
|
|
254
259
|
"next-auth": "^4.24.0",
|
|
255
260
|
"next-themes": "^0.4.0",
|
|
256
261
|
"react": "^18.0.0 || ^19.0.0",
|
|
257
262
|
"react-dom": "^18.0.0 || ^19.0.0",
|
|
258
|
-
"sonner": "^2.0.
|
|
263
|
+
"sonner": "^2.0.7"
|
|
259
264
|
},
|
|
260
265
|
"peerDependenciesMeta": {
|
|
261
266
|
"hazo_config": {
|
|
@@ -359,36 +364,37 @@
|
|
|
359
364
|
"@types/jsonwebtoken": "^9.0.10",
|
|
360
365
|
"@types/multer": "^2.0.0",
|
|
361
366
|
"@types/node": "^20.19.24",
|
|
362
|
-
"@types/react": "^18",
|
|
363
|
-
"@types/react-dom": "^18",
|
|
367
|
+
"@types/react": "^18.3.3",
|
|
368
|
+
"@types/react-dom": "^18.3.0",
|
|
364
369
|
"better-sqlite3": "^12.4.1",
|
|
365
370
|
"cross-env": "^10.1.0",
|
|
366
371
|
"dotenv": "^17.4.2",
|
|
367
372
|
"eslint": "^9.39.1",
|
|
368
373
|
"eslint-config-next": "^16.0.4",
|
|
369
374
|
"eslint-plugin-storybook": "^10.0.6",
|
|
370
|
-
"
|
|
371
|
-
"
|
|
372
|
-
"
|
|
373
|
-
"
|
|
374
|
-
"
|
|
375
|
+
"@tailwindcss/postcss": "^4.2.4",
|
|
376
|
+
"hazo_config": "^2.1.0",
|
|
377
|
+
"hazo_connect": "^2.4.0",
|
|
378
|
+
"hazo_logs": "^1.0.13",
|
|
379
|
+
"hazo_notify": "^3.0.0",
|
|
380
|
+
"hazo_ui": "^2.7.0",
|
|
375
381
|
"jest": "^30.2.0",
|
|
376
|
-
"jest-environment-jsdom": "^
|
|
382
|
+
"jest-environment-jsdom": "^30.0.0",
|
|
377
383
|
"lucide-react": "^0.553.0",
|
|
378
384
|
"next": "^16.0.7",
|
|
379
385
|
"next-auth": "^4.24.13",
|
|
380
386
|
"next-themes": "^0.4.6",
|
|
381
387
|
"patch-package": "^8.0.1",
|
|
382
388
|
"playwright": "^1.57.0",
|
|
383
|
-
"postcss": "^8",
|
|
389
|
+
"postcss": "^8.4.49",
|
|
384
390
|
"react": "^18.3.1",
|
|
385
391
|
"react-dom": "^18.3.1",
|
|
386
392
|
"sonner": "^2.0.7",
|
|
387
393
|
"storybook": "^10.0.6",
|
|
388
394
|
"supertest": "^7.1.4",
|
|
389
|
-
"tailwindcss": "^
|
|
395
|
+
"tailwindcss": "^4.2.4",
|
|
390
396
|
"ts-jest": "^29.4.5",
|
|
391
397
|
"tsx": "^4.20.6",
|
|
392
|
-
"typescript": "^5"
|
|
398
|
+
"typescript": "^5.7.2"
|
|
393
399
|
}
|
|
394
400
|
}
|
|
Binary file
|