hazo_auth 1.4.1 → 1.4.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 +25 -38
- package/dist/components/layouts/email_verification/config/email_verification_field_config.d.ts +2 -2
- package/dist/components/layouts/email_verification/config/email_verification_field_config.d.ts.map +1 -1
- package/dist/components/layouts/email_verification/config/email_verification_field_config.js +1 -1
- package/dist/components/layouts/email_verification/hooks/use_email_verification.d.ts +2 -2
- package/dist/components/layouts/email_verification/hooks/use_email_verification.d.ts.map +1 -1
- package/dist/components/layouts/email_verification/hooks/use_email_verification.js +2 -2
- package/dist/components/layouts/email_verification/index.d.ts +3 -3
- package/dist/components/layouts/email_verification/index.d.ts.map +1 -1
- package/dist/components/layouts/email_verification/index.js +9 -9
- package/dist/components/layouts/forgot_password/config/forgot_password_field_config.d.ts +2 -2
- package/dist/components/layouts/forgot_password/config/forgot_password_field_config.d.ts.map +1 -1
- package/dist/components/layouts/forgot_password/config/forgot_password_field_config.js +1 -1
- package/dist/components/layouts/forgot_password/hooks/use_forgot_password_form.d.ts +2 -2
- package/dist/components/layouts/forgot_password/hooks/use_forgot_password_form.d.ts.map +1 -1
- package/dist/components/layouts/forgot_password/hooks/use_forgot_password_form.js +2 -2
- package/dist/components/layouts/forgot_password/index.d.ts +2 -2
- package/dist/components/layouts/forgot_password/index.d.ts.map +1 -1
- package/dist/components/layouts/forgot_password/index.js +8 -8
- package/dist/components/layouts/login/config/login_field_config.d.ts +2 -2
- package/dist/components/layouts/login/config/login_field_config.d.ts.map +1 -1
- package/dist/components/layouts/login/config/login_field_config.js +1 -1
- package/dist/components/layouts/login/hooks/use_login_form.d.ts +2 -2
- package/dist/components/layouts/login/hooks/use_login_form.d.ts.map +1 -1
- package/dist/components/layouts/login/hooks/use_login_form.js +4 -4
- package/dist/components/layouts/login/index.d.ts +2 -2
- package/dist/components/layouts/login/index.d.ts.map +1 -1
- package/dist/components/layouts/login/index.js +9 -9
- package/dist/components/layouts/my_settings/components/editable_field.js +3 -3
- package/dist/components/layouts/my_settings/components/password_change_dialog.d.ts +1 -1
- package/dist/components/layouts/my_settings/components/password_change_dialog.d.ts.map +1 -1
- package/dist/components/layouts/my_settings/components/password_change_dialog.js +4 -4
- package/dist/components/layouts/my_settings/components/profile_picture_dialog.js +7 -7
- package/dist/components/layouts/my_settings/components/profile_picture_display.js +1 -1
- package/dist/components/layouts/my_settings/components/profile_picture_gravatar_tab.js +3 -3
- package/dist/components/layouts/my_settings/components/profile_picture_library_tab.js +5 -5
- package/dist/components/layouts/my_settings/components/profile_picture_upload_tab.js +4 -4
- package/dist/components/layouts/my_settings/config/my_settings_field_config.d.ts +1 -1
- package/dist/components/layouts/my_settings/config/my_settings_field_config.d.ts.map +1 -1
- package/dist/components/layouts/my_settings/config/my_settings_field_config.js +1 -1
- package/dist/components/layouts/my_settings/hooks/use_my_settings.d.ts +1 -1
- package/dist/components/layouts/my_settings/hooks/use_my_settings.d.ts.map +1 -1
- package/dist/components/layouts/my_settings/hooks/use_my_settings.js +1 -1
- package/dist/components/layouts/my_settings/index.d.ts +2 -2
- package/dist/components/layouts/my_settings/index.d.ts.map +1 -1
- package/dist/components/layouts/my_settings/index.js +9 -9
- package/dist/components/layouts/register/config/register_field_config.d.ts +2 -2
- package/dist/components/layouts/register/config/register_field_config.d.ts.map +1 -1
- package/dist/components/layouts/register/config/register_field_config.js +1 -1
- package/dist/components/layouts/register/hooks/use_register_form.d.ts +3 -3
- package/dist/components/layouts/register/hooks/use_register_form.d.ts.map +1 -1
- package/dist/components/layouts/register/hooks/use_register_form.js +2 -2
- package/dist/components/layouts/register/index.d.ts +2 -2
- package/dist/components/layouts/register/index.d.ts.map +1 -1
- package/dist/components/layouts/register/index.js +9 -9
- package/dist/components/layouts/reset_password/config/reset_password_field_config.d.ts +2 -2
- package/dist/components/layouts/reset_password/config/reset_password_field_config.d.ts.map +1 -1
- package/dist/components/layouts/reset_password/config/reset_password_field_config.js +1 -1
- package/dist/components/layouts/reset_password/hooks/use_reset_password_form.d.ts +3 -3
- package/dist/components/layouts/reset_password/hooks/use_reset_password_form.d.ts.map +1 -1
- package/dist/components/layouts/reset_password/hooks/use_reset_password_form.js +2 -2
- package/dist/components/layouts/reset_password/index.d.ts +2 -2
- package/dist/components/layouts/reset_password/index.d.ts.map +1 -1
- package/dist/components/layouts/reset_password/index.js +8 -8
- package/dist/components/layouts/shared/components/already_logged_in_guard.js +4 -4
- package/dist/components/layouts/shared/components/auth_page_shell.js +3 -3
- package/dist/components/layouts/shared/components/form_action_buttons.d.ts +1 -1
- package/dist/components/layouts/shared/components/form_action_buttons.d.ts.map +1 -1
- package/dist/components/layouts/shared/components/form_action_buttons.js +1 -1
- package/dist/components/layouts/shared/components/form_field_wrapper.js +2 -2
- package/dist/components/layouts/shared/components/logout_button.js +2 -2
- package/dist/components/layouts/shared/components/password_field.js +3 -3
- package/dist/components/layouts/shared/components/profile_pic_menu.d.ts +1 -1
- package/dist/components/layouts/shared/components/profile_pic_menu.d.ts.map +1 -1
- package/dist/components/layouts/shared/components/profile_pic_menu.js +4 -4
- package/dist/components/layouts/shared/components/profile_pic_menu_wrapper.js +2 -2
- package/dist/components/layouts/shared/components/sidebar_layout_wrapper.js +3 -3
- package/dist/components/layouts/shared/components/standalone_layout_wrapper.js +1 -1
- package/dist/components/layouts/shared/components/two_column_auth_layout.js +1 -1
- package/dist/components/layouts/shared/components/unauthorized_guard.js +2 -2
- package/dist/components/layouts/shared/hooks/use_hazo_auth.d.ts +1 -1
- package/dist/components/layouts/shared/hooks/use_hazo_auth.d.ts.map +1 -1
- package/dist/components/layouts/shared/utils/validation.d.ts +1 -1
- package/dist/components/layouts/shared/utils/validation.d.ts.map +1 -1
- package/dist/components/layouts/user_management/components/roles_matrix.js +7 -7
- package/dist/components/layouts/user_management/index.js +11 -11
- package/dist/components/ui/alert-dialog.js +2 -2
- package/dist/components/ui/avatar.js +1 -1
- package/dist/components/ui/button.js +1 -1
- package/dist/components/ui/checkbox.js +1 -1
- package/dist/components/ui/dialog.js +1 -1
- package/dist/components/ui/dropdown-menu.js +1 -1
- package/dist/components/ui/hazo_ui_tooltip.js +1 -1
- package/dist/components/ui/input.js +1 -1
- package/dist/components/ui/label.js +1 -1
- package/dist/components/ui/separator.js +1 -1
- package/dist/components/ui/sheet.js +1 -1
- package/dist/components/ui/sidebar.d.ts +2 -2
- package/dist/components/ui/sidebar.d.ts.map +1 -1
- package/dist/components/ui/sidebar.js +8 -8
- package/dist/components/ui/skeleton.js +1 -1
- package/dist/components/ui/switch.js +1 -1
- package/dist/components/ui/table.js +1 -1
- package/dist/components/ui/tabs.js +1 -1
- package/dist/components/ui/tooltip.js +1 -1
- package/dist/components/ui/vertical-tabs.js +1 -1
- package/dist/lib/already_logged_in_config.server.js +1 -1
- package/dist/lib/app_logger.js +1 -1
- package/dist/lib/auth/auth_cache.d.ts +1 -1
- package/dist/lib/auth/auth_cache.d.ts.map +1 -1
- package/dist/lib/auth/auth_utils.server.js +2 -2
- package/dist/lib/auth/hazo_get_auth.server.d.ts +1 -1
- package/dist/lib/auth/hazo_get_auth.server.d.ts.map +1 -1
- package/dist/lib/auth/hazo_get_auth.server.js +7 -7
- package/dist/lib/auth/server_auth.js +2 -2
- package/dist/lib/auth_utility_config.server.js +1 -1
- package/dist/lib/config/config_loader.server.js +1 -1
- package/dist/lib/email_verification_config.server.js +1 -1
- package/dist/lib/file_types_config.server.js +1 -1
- package/dist/lib/forgot_password_config.server.js +1 -1
- package/dist/lib/hazo_connect_instance.server.js +2 -2
- package/dist/lib/hazo_connect_setup.server.js +2 -2
- package/dist/lib/login_config.server.js +2 -2
- package/dist/lib/messages_config.server.js +1 -1
- package/dist/lib/my_settings_config.server.js +7 -7
- package/dist/lib/password_requirements_config.server.js +1 -1
- package/dist/lib/profile_pic_menu_config.server.js +1 -1
- package/dist/lib/profile_picture_config.server.js +2 -2
- package/dist/lib/register_config.server.js +4 -4
- package/dist/lib/reset_password_config.server.js +3 -3
- package/dist/lib/services/email_service.js +2 -2
- package/dist/lib/services/email_verification_service.js +3 -3
- package/dist/lib/services/login_service.js +3 -3
- package/dist/lib/services/password_change_service.js +3 -3
- package/dist/lib/services/password_reset_service.js +3 -3
- package/dist/lib/services/profile_picture_remove_service.js +3 -3
- package/dist/lib/services/profile_picture_service.d.ts +1 -1
- package/dist/lib/services/profile_picture_service.d.ts.map +1 -1
- package/dist/lib/services/profile_picture_service.js +5 -5
- package/dist/lib/services/registration_service.js +8 -8
- package/dist/lib/services/token_service.js +2 -2
- package/dist/lib/services/user_profiles_service.js +2 -2
- package/dist/lib/services/user_update_service.d.ts +1 -1
- package/dist/lib/services/user_update_service.d.ts.map +1 -1
- package/dist/lib/services/user_update_service.js +4 -4
- package/dist/lib/ui_shell_config.server.js +1 -1
- package/dist/lib/ui_sizes_config.server.js +1 -1
- package/dist/lib/user_fields_config.server.js +1 -1
- package/dist/lib/user_management_config.server.js +1 -1
- package/dist/lib/utils/error_sanitizer.d.ts +1 -1
- package/dist/lib/utils/error_sanitizer.d.ts.map +1 -1
- package/dist/server/config/config_loader.d.ts +1 -1
- package/dist/server/config/config_loader.d.ts.map +1 -1
- package/dist/server/config/config_loader.js +1 -1
- package/dist/server/index.js +2 -2
- package/dist/server/logging/logger_service.d.ts +1 -1
- package/dist/server/logging/logger_service.d.ts.map +1 -1
- package/dist/server/server.js +2 -2
- package/package.json +4 -100
- package/src/components/layouts/email_verification/config/email_verification_field_config.ts +2 -2
- package/src/components/layouts/email_verification/hooks/use_email_verification.ts +3 -3
- package/src/components/layouts/email_verification/index.tsx +11 -11
- package/src/components/layouts/forgot_password/config/forgot_password_field_config.ts +2 -2
- package/src/components/layouts/forgot_password/hooks/use_forgot_password_form.ts +3 -3
- package/src/components/layouts/forgot_password/index.tsx +10 -10
- package/src/components/layouts/login/config/login_field_config.ts +2 -2
- package/src/components/layouts/login/hooks/use_login_form.ts +5 -5
- package/src/components/layouts/login/index.tsx +11 -11
- package/src/components/layouts/my_settings/components/editable_field.tsx +3 -3
- package/src/components/layouts/my_settings/components/password_change_dialog.tsx +5 -5
- package/src/components/layouts/my_settings/components/profile_picture_dialog.tsx +7 -7
- package/src/components/layouts/my_settings/components/profile_picture_display.tsx +2 -2
- package/src/components/layouts/my_settings/components/profile_picture_gravatar_tab.tsx +3 -3
- package/src/components/layouts/my_settings/components/profile_picture_library_tab.tsx +5 -5
- package/src/components/layouts/my_settings/components/profile_picture_upload_tab.tsx +4 -4
- package/src/components/layouts/my_settings/config/my_settings_field_config.ts +2 -2
- package/src/components/layouts/my_settings/hooks/use_my_settings.ts +2 -2
- package/src/components/layouts/my_settings/index.tsx +10 -10
- package/src/components/layouts/register/config/register_field_config.ts +2 -2
- package/src/components/layouts/register/hooks/use_register_form.ts +4 -4
- package/src/components/layouts/register/index.tsx +11 -11
- package/src/components/layouts/reset_password/config/reset_password_field_config.ts +2 -2
- package/src/components/layouts/reset_password/hooks/use_reset_password_form.ts +4 -4
- package/src/components/layouts/reset_password/index.tsx +10 -10
- package/src/components/layouts/shared/components/already_logged_in_guard.tsx +4 -4
- package/src/components/layouts/shared/components/auth_page_shell.tsx +3 -3
- package/src/components/layouts/shared/components/form_action_buttons.tsx +2 -2
- package/src/components/layouts/shared/components/form_field_wrapper.tsx +2 -2
- package/src/components/layouts/shared/components/logout_button.tsx +2 -2
- package/src/components/layouts/shared/components/password_field.tsx +3 -3
- package/src/components/layouts/shared/components/profile_pic_menu.tsx +5 -5
- package/src/components/layouts/shared/components/profile_pic_menu_wrapper.tsx +2 -2
- package/src/components/layouts/shared/components/sidebar_layout_wrapper.tsx +3 -3
- package/src/components/layouts/shared/components/standalone_layout_wrapper.tsx +1 -1
- package/src/components/layouts/shared/components/two_column_auth_layout.tsx +1 -1
- package/src/components/layouts/shared/components/unauthorized_guard.tsx +2 -2
- package/src/components/layouts/shared/hooks/use_hazo_auth.ts +1 -1
- package/src/components/layouts/shared/utils/validation.ts +1 -1
- package/src/components/layouts/user_management/components/roles_matrix.tsx +7 -7
- package/src/components/layouts/user_management/index.tsx +11 -11
- package/src/components/ui/alert-dialog.tsx +2 -2
- package/src/components/ui/avatar.tsx +1 -1
- package/src/components/ui/button.tsx +1 -1
- package/src/components/ui/checkbox.tsx +1 -1
- package/src/components/ui/dialog.tsx +1 -1
- package/src/components/ui/dropdown-menu.tsx +1 -1
- package/src/components/ui/hazo_ui_tooltip.tsx +1 -1
- package/src/components/ui/input.tsx +1 -1
- package/src/components/ui/label.tsx +1 -1
- package/src/components/ui/separator.tsx +1 -1
- package/src/components/ui/sheet.tsx +1 -1
- package/src/components/ui/sidebar.tsx +8 -8
- package/src/components/ui/skeleton.tsx +1 -1
- package/src/components/ui/switch.tsx +1 -1
- package/src/components/ui/table.tsx +1 -1
- package/src/components/ui/tabs.tsx +1 -1
- package/src/components/ui/tooltip.tsx +1 -1
- package/src/components/ui/vertical-tabs.tsx +1 -1
- package/src/lib/already_logged_in_config.server.ts +1 -1
- package/src/lib/app_logger.ts +1 -1
- package/src/lib/auth/auth_cache.ts +1 -1
- package/src/lib/auth/auth_utils.server.ts +2 -2
- package/src/lib/auth/hazo_get_auth.server.ts +8 -8
- package/src/lib/auth/server_auth.ts +2 -2
- package/src/lib/auth_utility_config.server.ts +1 -1
- package/src/lib/config/config_loader.server.ts +1 -1
- package/src/lib/email_verification_config.server.ts +1 -1
- package/src/lib/file_types_config.server.ts +1 -1
- package/src/lib/forgot_password_config.server.ts +1 -1
- package/src/lib/hazo_connect_instance.server.ts +2 -2
- package/src/lib/hazo_connect_setup.server.ts +2 -2
- package/src/lib/login_config.server.ts +2 -2
- package/src/lib/messages_config.server.ts +1 -1
- package/src/lib/my_settings_config.server.ts +7 -7
- package/src/lib/password_requirements_config.server.ts +1 -1
- package/src/lib/profile_pic_menu_config.server.ts +1 -1
- package/src/lib/profile_picture_config.server.ts +2 -2
- package/src/lib/register_config.server.ts +4 -4
- package/src/lib/reset_password_config.server.ts +3 -3
- package/src/lib/services/email_service.ts +2 -2
- package/src/lib/services/email_verification_service.ts +3 -3
- package/src/lib/services/login_service.ts +3 -3
- package/src/lib/services/password_change_service.ts +3 -3
- package/src/lib/services/password_reset_service.ts +3 -3
- package/src/lib/services/profile_picture_remove_service.ts +3 -3
- package/src/lib/services/profile_picture_service.ts +5 -5
- package/src/lib/services/registration_service.ts +8 -8
- package/src/lib/services/token_service.ts +2 -2
- package/src/lib/services/user_profiles_service.ts +2 -2
- package/src/lib/services/user_update_service.ts +4 -4
- package/src/lib/ui_shell_config.server.ts +1 -1
- package/src/lib/ui_sizes_config.server.ts +1 -1
- package/src/lib/user_fields_config.server.ts +1 -1
- package/src/lib/user_management_config.server.ts +1 -1
- package/src/lib/utils/error_sanitizer.ts +1 -1
- package/src/server/config/config_loader.ts +2 -2
- package/src/server/index.ts +2 -2
- package/src/server/logging/logger_service.ts +1 -1
- package/src/server/server.ts +2 -2
- package/src/server/types/express.d.ts +1 -1
- package/tsconfig.build.json +0 -3
|
@@ -4,19 +4,19 @@
|
|
|
4
4
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
5
5
|
// section: imports
|
|
6
6
|
import { useState, useEffect, useCallback } from "react";
|
|
7
|
-
import { Tabs, TabsContent, TabsList, TabsTrigger } from "
|
|
8
|
-
import { use_hazo_auth } from "
|
|
9
|
-
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow, } from "
|
|
10
|
-
import { Button } from "
|
|
11
|
-
import { Avatar, AvatarImage, AvatarFallback } from "
|
|
12
|
-
import { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, } from "
|
|
13
|
-
import { Dialog, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, } from "
|
|
14
|
-
import { Input } from "
|
|
15
|
-
import { Label } from "
|
|
16
|
-
import { RolesMatrix } from "
|
|
7
|
+
import { Tabs, TabsContent, TabsList, TabsTrigger } from "../../ui/tabs";
|
|
8
|
+
import { use_hazo_auth } from "../shared/hooks/use_hazo_auth";
|
|
9
|
+
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow, } from "../../ui/table";
|
|
10
|
+
import { Button } from "../../ui/button";
|
|
11
|
+
import { Avatar, AvatarImage, AvatarFallback } from "../../ui/avatar";
|
|
12
|
+
import { AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, } from "../../ui/alert-dialog";
|
|
13
|
+
import { Dialog, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, } from "../../ui/dialog";
|
|
14
|
+
import { Input } from "../../ui/input";
|
|
15
|
+
import { Label } from "../../ui/label";
|
|
16
|
+
import { RolesMatrix } from "./components/roles_matrix";
|
|
17
17
|
import { UserX, KeyRound, Edit, Trash2, Loader2, CircleCheck, CircleX, Plus, UserPlus } from "lucide-react";
|
|
18
18
|
import { toast } from "sonner";
|
|
19
|
-
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "
|
|
19
|
+
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "../../ui/tooltip";
|
|
20
20
|
// section: component
|
|
21
21
|
/**
|
|
22
22
|
* User Management layout component with three tabs
|
|
@@ -13,8 +13,8 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
13
13
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
|
|
16
|
-
import { cn } from "
|
|
17
|
-
import { buttonVariants } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
|
+
import { buttonVariants } from "./button";
|
|
18
18
|
const AlertDialog = AlertDialogPrimitive.Root;
|
|
19
19
|
const AlertDialogTrigger = AlertDialogPrimitive.Trigger;
|
|
20
20
|
const AlertDialogPortal = AlertDialogPrimitive.Portal;
|
|
@@ -13,7 +13,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as AvatarPrimitive from "@radix-ui/react-avatar";
|
|
16
|
-
import { cn } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
17
|
const Avatar = React.forwardRef((_a, ref) => {
|
|
18
18
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
19
19
|
return (_jsx(AvatarPrimitive.Root, Object.assign({ ref: ref, className: cn("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full", className) }, props)));
|
|
@@ -13,7 +13,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
13
13
|
import * as React from "react";
|
|
14
14
|
import { Slot } from "@radix-ui/react-slot";
|
|
15
15
|
import { cva } from "class-variance-authority";
|
|
16
|
-
import { cn } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
17
|
const buttonVariants = cva("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0", {
|
|
18
18
|
variants: {
|
|
19
19
|
variant: {
|
|
@@ -14,7 +14,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
|
|
16
16
|
import { Check } from "lucide-react";
|
|
17
|
-
import { cn } from "
|
|
17
|
+
import { cn } from "../../lib/utils";
|
|
18
18
|
const Checkbox = React.forwardRef((_a, ref) => {
|
|
19
19
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
20
20
|
return (_jsx(CheckboxPrimitive.Root, Object.assign({ ref: ref, className: cn("grid place-content-center peer h-4 w-4 shrink-0 rounded-sm border border-primary shadow focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground", className) }, props, { children: _jsx(CheckboxPrimitive.Indicator, { className: cn("grid place-content-center text-current"), children: _jsx(Check, { className: "h-4 w-4" }) }) })));
|
|
@@ -14,7 +14,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as DialogPrimitive from "@radix-ui/react-dialog";
|
|
16
16
|
import { X } from "lucide-react";
|
|
17
|
-
import { cn } from "
|
|
17
|
+
import { cn } from "../../lib/utils";
|
|
18
18
|
const Dialog = DialogPrimitive.Root;
|
|
19
19
|
const DialogTrigger = DialogPrimitive.Trigger;
|
|
20
20
|
const DialogPortal = DialogPrimitive.Portal;
|
|
@@ -14,7 +14,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
|
|
16
16
|
import { Check, ChevronRight, Circle } from "lucide-react";
|
|
17
|
-
import { cn } from "
|
|
17
|
+
import { cn } from "../../lib/utils";
|
|
18
18
|
const DropdownMenu = DropdownMenuPrimitive.Root;
|
|
19
19
|
const DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
|
|
20
20
|
const DropdownMenuGroup = DropdownMenuPrimitive.Group;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
5
5
|
// section: imports
|
|
6
6
|
import { HelpCircle } from "lucide-react";
|
|
7
|
-
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "
|
|
7
|
+
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger } from "./tooltip";
|
|
8
8
|
// section: component
|
|
9
9
|
/**
|
|
10
10
|
* Reusable tooltip component with question mark icon
|
|
@@ -11,7 +11,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
11
11
|
};
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import * as React from "react";
|
|
14
|
-
import { cn } from "
|
|
14
|
+
import { cn } from "../../lib/utils";
|
|
15
15
|
const Input = React.forwardRef((_a, ref) => {
|
|
16
16
|
var { className, type } = _a, props = __rest(_a, ["className", "type"]);
|
|
17
17
|
return (_jsx("input", Object.assign({ type: type, className: cn("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm", className), ref: ref }, props)));
|
|
@@ -14,7 +14,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
16
16
|
import { cva } from "class-variance-authority";
|
|
17
|
-
import { cn } from "
|
|
17
|
+
import { cn } from "../../lib/utils";
|
|
18
18
|
const labelVariants = cva("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70");
|
|
19
19
|
const Label = React.forwardRef((_a, ref) => {
|
|
20
20
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
@@ -13,7 +13,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
16
|
-
import { cn } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
17
|
const Separator = React.forwardRef((_a, ref) => {
|
|
18
18
|
var { className, orientation = "horizontal", decorative = true } = _a, props = __rest(_a, ["className", "orientation", "decorative"]);
|
|
19
19
|
return (_jsx(SeparatorPrimitive.Root, Object.assign({ ref: ref, decorative: decorative, orientation: orientation, className: cn("shrink-0 bg-border", orientation === "horizontal" ? "h-[1px] w-full" : "h-full w-[1px]", className) }, props)));
|
|
@@ -15,7 +15,7 @@ import * as React from "react";
|
|
|
15
15
|
import * as SheetPrimitive from "@radix-ui/react-dialog";
|
|
16
16
|
import { cva } from "class-variance-authority";
|
|
17
17
|
import { X } from "lucide-react";
|
|
18
|
-
import { cn } from "
|
|
18
|
+
import { cn } from "../../lib/utils";
|
|
19
19
|
const Sheet = SheetPrimitive.Root;
|
|
20
20
|
const SheetTrigger = SheetPrimitive.Trigger;
|
|
21
21
|
const SheetClose = SheetPrimitive.Close;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { type VariantProps } from "class-variance-authority";
|
|
3
|
-
import { TooltipContent } from "
|
|
3
|
+
import { TooltipContent } from "./tooltip";
|
|
4
4
|
type SidebarContextProps = {
|
|
5
5
|
state: "expanded" | "collapsed";
|
|
6
6
|
open: boolean;
|
|
@@ -21,7 +21,7 @@ declare const Sidebar: React.ForwardRefExoticComponent<Omit<React.ClassAttribute
|
|
|
21
21
|
variant?: "sidebar" | "floating" | "inset";
|
|
22
22
|
collapsible?: "offcanvas" | "icon" | "none";
|
|
23
23
|
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
24
|
-
declare const SidebarTrigger: React.ForwardRefExoticComponent<Omit<import("
|
|
24
|
+
declare const SidebarTrigger: React.ForwardRefExoticComponent<Omit<import("./button").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
25
25
|
declare const SidebarRail: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
26
26
|
declare const SidebarInset: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
27
27
|
declare const SidebarInput: React.ForwardRefExoticComponent<Omit<Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sidebar.d.ts","sourceRoot":"","sources":["../../../src/components/ui/sidebar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAgBjE,OAAO,EAEL,cAAc,EAGf,MAAM,
|
|
1
|
+
{"version":3,"file":"sidebar.d.ts","sourceRoot":"","sources":["../../../src/components/ui/sidebar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAgBjE,OAAO,EAEL,cAAc,EAGf,MAAM,WAAW,CAAA;AASlB,KAAK,mBAAmB,GAAG;IACzB,KAAK,EAAE,UAAU,GAAG,WAAW,CAAA;IAC/B,IAAI,EAAE,OAAO,CAAA;IACb,OAAO,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IAChC,UAAU,EAAE,OAAO,CAAA;IACnB,aAAa,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC,QAAQ,EAAE,OAAO,CAAA;IACjB,aAAa,EAAE,MAAM,IAAI,CAAA;CAC1B,CAAA;AAID,iBAAS,UAAU,wBAOlB;AAED,QAAA,MAAM,eAAe;kBAGH,OAAO;WACd,OAAO;mBACC,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI;gDAqGzC,CAAA;AAGD,QAAA,MAAM,OAAO;WAGF,MAAM,GAAG,OAAO;cACb,SAAS,GAAG,UAAU,GAAG,OAAO;kBAC5B,WAAW,GAAG,MAAM,GAAG,MAAM;gDAmG9C,CAAA;AAGD,QAAA,MAAM,cAAc,gKAuBlB,CAAA;AAGF,QAAA,MAAM,WAAW,kLA0Bf,CAAA;AAGF,QAAA,MAAM,YAAY,6JAehB,CAAA;AAGF,QAAA,MAAM,YAAY,mOAehB,CAAA;AAGF,QAAA,MAAM,aAAa,mKAYjB,CAAA;AAGF,QAAA,MAAM,aAAa,mKAYjB,CAAA;AAGF,QAAA,MAAM,gBAAgB,iOAYpB,CAAA;AAGF,QAAA,MAAM,cAAc,mKAelB,CAAA;AAGF,QAAA,MAAM,YAAY,mKAYhB,CAAA;AAGF,QAAA,MAAM,iBAAiB;cAEqB,OAAO;gDAgBjD,CAAA;AAGF,QAAA,MAAM,kBAAkB;cAEuB,OAAO;mDAkBpD,CAAA;AAGF,QAAA,MAAM,mBAAmB,mKAUvB,CAAA;AAGF,QAAA,MAAM,WAAW,yKAUf,CAAA;AAGF,QAAA,MAAM,eAAe,kKAUnB,CAAA;AAyBF,QAAA,MAAM,iBAAiB;cAGT,OAAO;eACN,OAAO;cACR,MAAM,GAAG,KAAK,CAAC,cAAc,CAAC,OAAO,cAAc,CAAC;;;;iIAmDjE,CAAA;AAGD,QAAA,MAAM,iBAAiB;cAGT,OAAO;kBACH,OAAO;mDAwBvB,CAAA;AAGF,QAAA,MAAM,gBAAgB,mKAkBpB,CAAA;AAGF,QAAA,MAAM,mBAAmB;eAGV,OAAO;gDAgCpB,CAAA;AAGF,QAAA,MAAM,cAAc,yKAclB,CAAA;AAGF,QAAA,MAAM,kBAAkB,kKAG6B,CAAA;AAGrD,QAAA,MAAM,oBAAoB;cAGZ,OAAO;WACV,IAAI,GAAG,IAAI;eACP,OAAO;mDAsBpB,CAAA;AAGF,OAAO,EACL,OAAO,EACP,cAAc,EACd,aAAa,EACb,YAAY,EACZ,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,aAAa,EACb,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,iBAAiB,EACjB,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,EACf,mBAAmB,EACnB,cAAc,EACd,oBAAoB,EACpB,kBAAkB,EAClB,eAAe,EACf,WAAW,EACX,gBAAgB,EAChB,cAAc,EACd,UAAU,GACX,CAAA"}
|
|
@@ -15,14 +15,14 @@ import * as React from "react";
|
|
|
15
15
|
import { Slot } from "@radix-ui/react-slot";
|
|
16
16
|
import { cva } from "class-variance-authority";
|
|
17
17
|
import { PanelLeft } from "lucide-react";
|
|
18
|
-
import { useIsMobile } from "
|
|
19
|
-
import { cn } from "
|
|
20
|
-
import { Button } from "
|
|
21
|
-
import { Input } from "
|
|
22
|
-
import { Separator } from "
|
|
23
|
-
import { Sheet, SheetContent, SheetDescription, SheetHeader, SheetTitle, } from "
|
|
24
|
-
import { Skeleton } from "
|
|
25
|
-
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, } from "
|
|
18
|
+
import { useIsMobile } from "../../hooks/use-mobile";
|
|
19
|
+
import { cn } from "../../lib/utils";
|
|
20
|
+
import { Button } from "./button";
|
|
21
|
+
import { Input } from "./input";
|
|
22
|
+
import { Separator } from "./separator";
|
|
23
|
+
import { Sheet, SheetContent, SheetDescription, SheetHeader, SheetTitle, } from "./sheet";
|
|
24
|
+
import { Skeleton } from "./skeleton";
|
|
25
|
+
import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, } from "./tooltip";
|
|
26
26
|
const SIDEBAR_COOKIE_NAME = "sidebar_state";
|
|
27
27
|
const SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
|
|
28
28
|
const SIDEBAR_WIDTH = "16rem";
|
|
@@ -10,7 +10,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
10
10
|
return t;
|
|
11
11
|
};
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
|
-
import { cn } from "
|
|
13
|
+
import { cn } from "../../lib/utils";
|
|
14
14
|
function Skeleton(_a) {
|
|
15
15
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
16
16
|
return (_jsx("div", Object.assign({ className: cn("animate-pulse rounded-md bg-primary/10", className) }, props)));
|
|
@@ -13,7 +13,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as SwitchPrimitives from "@radix-ui/react-switch";
|
|
16
|
-
import { cn } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
17
|
const Switch = React.forwardRef((_a, ref) => {
|
|
18
18
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
19
19
|
return (_jsx(SwitchPrimitives.Root, Object.assign({ className: cn("peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input", className) }, props, { ref: ref, children: _jsx(SwitchPrimitives.Thumb, { className: cn("pointer-events-none block h-4 w-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0") }) })));
|
|
@@ -11,7 +11,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
11
11
|
};
|
|
12
12
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
import * as React from "react";
|
|
14
|
-
import { cn } from "
|
|
14
|
+
import { cn } from "../../lib/utils";
|
|
15
15
|
const Table = React.forwardRef((_a, ref) => {
|
|
16
16
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
17
17
|
return (_jsx("div", { className: "relative w-full overflow-auto", children: _jsx("table", Object.assign({ ref: ref, className: cn("w-full caption-bottom text-sm", className) }, props)) }));
|
|
@@ -13,7 +13,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
16
|
-
import { cn } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
17
|
const Tabs = TabsPrimitive.Root;
|
|
18
18
|
const TabsList = React.forwardRef((_a, ref) => {
|
|
19
19
|
var { className } = _a, props = __rest(_a, ["className"]);
|
|
@@ -13,7 +13,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
14
|
import * as React from "react";
|
|
15
15
|
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
16
|
-
import { cn } from "
|
|
16
|
+
import { cn } from "../../lib/utils";
|
|
17
17
|
const TooltipProvider = TooltipPrimitive.Provider;
|
|
18
18
|
const Tooltip = TooltipPrimitive.Root;
|
|
19
19
|
const TooltipTrigger = TooltipPrimitive.Trigger;
|
|
@@ -16,7 +16,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
16
16
|
// section: imports
|
|
17
17
|
import * as React from "react";
|
|
18
18
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
19
|
-
import { cn } from "
|
|
19
|
+
import { cn } from "../../lib/utils";
|
|
20
20
|
// section: components
|
|
21
21
|
const VerticalTabs = TabsPrimitive.Root;
|
|
22
22
|
const VerticalTabsList = React.forwardRef((_a, ref) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read already logged in configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value, get_config_boolean } from "
|
|
3
|
+
import { get_config_value, get_config_boolean } from "./config/config_loader.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Reads already logged in configuration from hazo_auth_config.ini file
|
package/dist/lib/app_logger.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: client-accessible wrapper for the main app logging service
|
|
2
2
|
// section: imports
|
|
3
|
-
import { create_logger_service } from "
|
|
3
|
+
import { create_logger_service } from "../server/logging/logger_service";
|
|
4
4
|
// section: constants
|
|
5
5
|
const APP_NAMESPACE = "hazo_auth_ui";
|
|
6
6
|
// section: logger_instance
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth_cache.d.ts","sourceRoot":"","sources":["../../../src/lib/auth/auth_cache.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM
|
|
1
|
+
{"version":3,"file":"auth_cache.d.ts","sourceRoot":"","sources":["../../../src/lib/auth/auth_cache.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAIjD;;GAEG;AACH,KAAK,UAAU,GAAG;IAChB,IAAI,EAAE,YAAY,CAAC;IACnB,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF;;;GAGG;AACH,cAAM,SAAS;IACb,OAAO,CAAC,KAAK,CAA0B;IACvC,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,UAAU,CAAS;IAC3B,OAAO,CAAC,gBAAgB,CAAsB;gBAG5C,QAAQ,EAAE,MAAM,EAChB,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,MAAM;IASzB;;;;;OAKG;IACH,GAAG,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS;IA+B5C;;;;;;;OAOG;IACH,GAAG,CACD,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,YAAY,EAClB,WAAW,EAAE,MAAM,EAAE,EACrB,QAAQ,EAAE,MAAM,EAAE,GACjB,IAAI;IAyBP;;;OAGG;IACH,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI;IAItC;;;;OAIG;IACH,mBAAmB,CAAC,QAAQ,EAAE,MAAM,EAAE,GAAG,IAAI;IAqB7C;;OAEG;IACH,cAAc,IAAI,IAAI;IAItB;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IAc5B;;;OAGG;IACH,SAAS,IAAI;QACX,IAAI,EAAE,MAAM,CAAC;QACb,QAAQ,EAAE,MAAM,CAAC;KAClB;CAMF;AAMD;;;;;;GAMG;AACH,wBAAgB,cAAc,CAC5B,QAAQ,GAAE,MAAc,EACxB,WAAW,GAAE,MAAW,EACxB,eAAe,GAAE,MAAW,GAC3B,SAAS,CAKX;AAED;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,IAAI,CAEvC"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// file_description: server-side authentication utilities for checking login status in API routes
|
|
2
2
|
// section: imports
|
|
3
3
|
import { NextResponse } from "next/server";
|
|
4
|
-
import { get_hazo_connect_instance } from "
|
|
4
|
+
import { get_hazo_connect_instance } from "../hazo_connect_instance.server";
|
|
5
5
|
import { createCrudService } from "hazo_connect/server";
|
|
6
|
-
import { map_db_source_to_ui } from "
|
|
6
|
+
import { map_db_source_to_ui } from "../services/profile_picture_source_mapper";
|
|
7
7
|
// section: helpers
|
|
8
8
|
/**
|
|
9
9
|
* Clears authentication cookies from response
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { NextRequest } from "next/server";
|
|
2
|
-
import type { HazoAuthResult, HazoAuthOptions } from "
|
|
2
|
+
import type { HazoAuthResult, HazoAuthOptions } from "./auth_types";
|
|
3
3
|
/**
|
|
4
4
|
* Main hazo_get_auth function for server-side use in API routes
|
|
5
5
|
* Returns user details, permissions, and checks required permissions
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hazo_get_auth.server.d.ts","sourceRoot":"","sources":["../../../src/lib/auth/hazo_get_auth.server.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAK1C,OAAO,KAAK,EAAE,cAAc,EAAgB,eAAe,EAAE,MAAM
|
|
1
|
+
{"version":3,"file":"hazo_get_auth.server.d.ts","sourceRoot":"","sources":["../../../src/lib/auth/hazo_get_auth.server.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAK1C,OAAO,KAAK,EAAE,cAAc,EAAgB,eAAe,EAAE,MAAM,cAAc,CAAC;AAkLlF;;;;;;;GAOG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,WAAW,EACpB,OAAO,CAAC,EAAE,eAAe,GACxB,OAAO,CAAC,cAAc,CAAC,CAuIzB"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { get_hazo_connect_instance } from "
|
|
1
|
+
import { get_hazo_connect_instance } from "../hazo_connect_instance.server";
|
|
2
2
|
import { createCrudService } from "hazo_connect/server";
|
|
3
|
-
import { create_app_logger } from "
|
|
4
|
-
import { get_filename, get_line_number } from "
|
|
5
|
-
import { PermissionError } from "
|
|
6
|
-
import { get_auth_cache } from "
|
|
7
|
-
import { get_rate_limiter } from "
|
|
8
|
-
import { get_auth_utility_config } from "
|
|
3
|
+
import { create_app_logger } from "../app_logger";
|
|
4
|
+
import { get_filename, get_line_number } from "../utils/api_route_helpers";
|
|
5
|
+
import { PermissionError } from "./auth_types";
|
|
6
|
+
import { get_auth_cache } from "./auth_cache";
|
|
7
|
+
import { get_rate_limiter } from "./auth_rate_limiter";
|
|
8
|
+
import { get_auth_utility_config } from "../auth_utility_config.server";
|
|
9
9
|
// section: helpers
|
|
10
10
|
/**
|
|
11
11
|
* Gets client IP address from request
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// file_description: server-side auth utilities for server components and pages
|
|
2
2
|
// section: imports
|
|
3
3
|
import { cookies } from "next/headers";
|
|
4
|
-
import { get_hazo_connect_instance } from "
|
|
4
|
+
import { get_hazo_connect_instance } from "../hazo_connect_instance.server";
|
|
5
5
|
import { createCrudService } from "hazo_connect/server";
|
|
6
|
-
import { map_db_source_to_ui } from "
|
|
6
|
+
import { map_db_source_to_ui } from "../services/profile_picture_source_mapper";
|
|
7
7
|
// section: functions
|
|
8
8
|
/**
|
|
9
9
|
* Gets authenticated user in server components/pages
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read auth utility configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value, get_config_number, get_config_boolean, } from "
|
|
3
|
+
import { get_config_value, get_config_number, get_config_boolean, } from "./config/config_loader.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Parses permission error messages from config string
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { HazoConfig } from "hazo_config/dist/lib";
|
|
4
4
|
import path from "path";
|
|
5
5
|
import fs from "fs";
|
|
6
|
-
import { create_app_logger } from "
|
|
6
|
+
import { create_app_logger } from "../app_logger";
|
|
7
7
|
// section: constants
|
|
8
8
|
const DEFAULT_CONFIG_FILE = "hazo_auth_config.ini";
|
|
9
9
|
// section: helpers
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read email verification layout configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_already_logged_in_config } from "
|
|
3
|
+
import { get_already_logged_in_config } from "./already_logged_in_config.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Reads email verification layout configuration from hazo_auth_config.ini file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read file type configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_array } from "
|
|
3
|
+
import { get_config_array } from "./config/config_loader.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Reads file type configuration from hazo_auth_config.ini file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read forgot password layout configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_already_logged_in_config } from "
|
|
3
|
+
import { get_already_logged_in_config } from "./already_logged_in_config.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Reads forgot password layout configuration from hazo_auth_config.ini file
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getHazoConnectSingleton } from "hazo_connect/nextjs/setup";
|
|
2
|
-
import { create_sqlite_hazo_connect_server, get_hazo_connect_config_options } from "
|
|
2
|
+
import { create_sqlite_hazo_connect_server, get_hazo_connect_config_options } from "./hazo_connect_setup.server";
|
|
3
3
|
import { initializeAdminService, getSqliteAdminService } from "hazo_connect/server";
|
|
4
|
-
import { create_app_logger } from "
|
|
4
|
+
import { create_app_logger } from "./app_logger";
|
|
5
5
|
// section: singleton_state
|
|
6
6
|
let hazoConnectInstance = null;
|
|
7
7
|
let isInitialized = false;
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
// section: imports
|
|
5
5
|
import { createHazoConnect } from "hazo_connect/server";
|
|
6
6
|
import path from "path";
|
|
7
|
-
import { create_app_logger } from "
|
|
8
|
-
import { read_config_section } from "
|
|
7
|
+
import { create_app_logger } from "./app_logger";
|
|
8
|
+
import { read_config_section } from "./config/config_loader.server";
|
|
9
9
|
// section: helpers
|
|
10
10
|
/**
|
|
11
11
|
* Reads hazo_connect configuration from hazo_auth_config.ini file
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// file_description: server-only helper to read login layout configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value } from "
|
|
4
|
-
import { get_already_logged_in_config } from "
|
|
3
|
+
import { get_config_value } from "./config/config_loader.server";
|
|
4
|
+
import { get_already_logged_in_config } from "./already_logged_in_config.server";
|
|
5
5
|
// section: helpers
|
|
6
6
|
/**
|
|
7
7
|
* Reads login layout configuration from hazo_auth_config.ini file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read user-facing messages from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value } from "
|
|
3
|
+
import { get_config_value } from "./config/config_loader.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Reads user-facing messages from hazo_auth_config.ini file
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
// file_description: server-only helper to read my settings layout configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value } from "
|
|
4
|
-
import { get_user_fields_config } from "
|
|
5
|
-
import { get_password_requirements_config } from "
|
|
6
|
-
import { get_profile_picture_config } from "
|
|
7
|
-
import { get_messages_config } from "
|
|
8
|
-
import { get_ui_sizes_config } from "
|
|
9
|
-
import { get_file_types_config } from "
|
|
3
|
+
import { get_config_value } from "./config/config_loader.server";
|
|
4
|
+
import { get_user_fields_config } from "./user_fields_config.server";
|
|
5
|
+
import { get_password_requirements_config } from "./password_requirements_config.server";
|
|
6
|
+
import { get_profile_picture_config } from "./profile_picture_config.server";
|
|
7
|
+
import { get_messages_config } from "./messages_config.server";
|
|
8
|
+
import { get_ui_sizes_config } from "./ui_sizes_config.server";
|
|
9
|
+
import { get_file_types_config } from "./file_types_config.server";
|
|
10
10
|
// section: helpers
|
|
11
11
|
/**
|
|
12
12
|
* Reads my settings layout configuration from hazo_auth_config.ini file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read shared password requirements configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_number, get_config_boolean } from "
|
|
3
|
+
import { get_config_number, get_config_boolean } from "./config/config_loader.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Reads shared password requirements configuration from hazo_auth_config.ini file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// file_description: server-only helper to read profile picture menu configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value, get_config_boolean, get_config_array } from "
|
|
3
|
+
import { get_config_value, get_config_boolean, get_config_array } from "./config/config_loader.server";
|
|
4
4
|
// section: helpers
|
|
5
5
|
/**
|
|
6
6
|
* Parses custom menu items from config string
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// file_description: server-only helper to read profile picture configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_boolean, get_config_value, get_config_number } from "
|
|
4
|
-
import { create_app_logger } from "
|
|
3
|
+
import { get_config_boolean, get_config_value, get_config_number } from "./config/config_loader.server";
|
|
4
|
+
import { create_app_logger } from "./app_logger";
|
|
5
5
|
// section: helpers
|
|
6
6
|
/**
|
|
7
7
|
* Reads profile picture configuration from hazo_auth_config.ini file
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// file_description: server-only helper to read register layout configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_boolean, get_config_value, read_config_section } from "
|
|
4
|
-
import { get_password_requirements_config } from "
|
|
5
|
-
import { get_already_logged_in_config } from "
|
|
6
|
-
import { get_user_fields_config } from "
|
|
3
|
+
import { get_config_boolean, get_config_value, read_config_section } from "./config/config_loader.server";
|
|
4
|
+
import { get_password_requirements_config } from "./password_requirements_config.server";
|
|
5
|
+
import { get_already_logged_in_config } from "./already_logged_in_config.server";
|
|
6
|
+
import { get_user_fields_config } from "./user_fields_config.server";
|
|
7
7
|
// section: helpers
|
|
8
8
|
/**
|
|
9
9
|
* Reads register layout configuration from hazo_auth_config.ini file
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// file_description: server-only helper to read reset password layout configuration from hazo_auth_config.ini
|
|
2
2
|
// section: imports
|
|
3
|
-
import { get_config_value } from "
|
|
4
|
-
import { get_already_logged_in_config } from "
|
|
5
|
-
import { get_password_requirements_config } from "
|
|
3
|
+
import { get_config_value } from "./config/config_loader.server";
|
|
4
|
+
import { get_already_logged_in_config } from "./already_logged_in_config.server";
|
|
5
|
+
import { get_password_requirements_config } from "./password_requirements_config.server";
|
|
6
6
|
// section: helpers
|
|
7
7
|
/**
|
|
8
8
|
* Reads reset password layout configuration from hazo_auth_config.ini file
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
// section: imports
|
|
3
3
|
import fs from "fs";
|
|
4
4
|
import path from "path";
|
|
5
|
-
import { create_app_logger } from "
|
|
6
|
-
import { read_config_section } from "
|
|
5
|
+
import { create_app_logger } from "../app_logger";
|
|
6
|
+
import { read_config_section } from "../config/config_loader.server";
|
|
7
7
|
// section: constants
|
|
8
8
|
const DEFAULT_EMAIL_FROM = "noreply@hazo_auth.local";
|
|
9
9
|
const DEFAULT_EMAIL_TEMPLATE_DIR = path.resolve(process.cwd(), "email_templates");
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createCrudService } from "hazo_connect/server";
|
|
2
2
|
import argon2 from "argon2";
|
|
3
|
-
import { create_token } from "
|
|
4
|
-
import { send_template_email } from "
|
|
5
|
-
import { create_app_logger } from "
|
|
3
|
+
import { create_token } from "./token_service";
|
|
4
|
+
import { send_template_email } from "./email_service";
|
|
5
|
+
import { create_app_logger } from "../app_logger";
|
|
6
6
|
// section: helpers
|
|
7
7
|
/**
|
|
8
8
|
* Verifies an email verification token
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createCrudService } from "hazo_connect/server";
|
|
2
2
|
import argon2 from "argon2";
|
|
3
|
-
import { create_app_logger } from "
|
|
4
|
-
import { sanitize_error_for_user } from "
|
|
5
|
-
import { get_line_number } from "
|
|
3
|
+
import { create_app_logger } from "../app_logger";
|
|
4
|
+
import { sanitize_error_for_user } from "../utils/error_sanitizer";
|
|
5
|
+
import { get_line_number } from "../utils/api_route_helpers";
|
|
6
6
|
// section: helpers
|
|
7
7
|
/**
|
|
8
8
|
* Authenticates a user by verifying email and password against hazo_users table
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createCrudService } from "hazo_connect/server";
|
|
2
2
|
import argon2 from "argon2";
|
|
3
|
-
import { get_password_requirements_config } from "
|
|
4
|
-
import { send_template_email } from "
|
|
5
|
-
import { create_app_logger } from "
|
|
3
|
+
import { get_password_requirements_config } from "../password_requirements_config.server";
|
|
4
|
+
import { send_template_email } from "./email_service";
|
|
5
|
+
import { create_app_logger } from "../app_logger";
|
|
6
6
|
// section: helpers
|
|
7
7
|
/**
|
|
8
8
|
* Changes a user's password
|