hazo_auth 1.3.0 → 1.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +398 -773
- package/dist/components/index.d.ts +3 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +5 -0
- package/dist/components/layouts/email_verification/config/email_verification_field_config.d.ts +23 -0
- package/dist/components/layouts/email_verification/config/email_verification_field_config.d.ts.map +1 -0
- package/dist/components/layouts/email_verification/config/email_verification_field_config.js +44 -0
- package/dist/components/layouts/email_verification/hooks/use_email_verification.d.ts +31 -0
- package/dist/components/layouts/email_verification/hooks/use_email_verification.d.ts.map +1 -0
- package/dist/components/layouts/email_verification/hooks/use_email_verification.js +222 -0
- package/dist/components/layouts/email_verification/index.d.ts +23 -0
- package/dist/components/layouts/email_verification/index.d.ts.map +1 -0
- package/dist/components/layouts/email_verification/index.js +61 -0
- package/dist/components/layouts/forgot_password/config/forgot_password_field_config.d.ts +10 -0
- package/dist/components/layouts/forgot_password/config/forgot_password_field_config.d.ts.map +1 -0
- package/dist/components/layouts/forgot_password/config/forgot_password_field_config.js +33 -0
- package/dist/components/layouts/forgot_password/hooks/use_forgot_password_form.d.ts +22 -0
- package/dist/components/layouts/forgot_password/hooks/use_forgot_password_form.d.ts.map +1 -0
- package/dist/components/layouts/forgot_password/hooks/use_forgot_password_form.js +127 -0
- package/dist/components/layouts/forgot_password/index.d.ts +18 -0
- package/dist/components/layouts/forgot_password/index.d.ts.map +1 -0
- package/dist/components/layouts/forgot_password/index.js +43 -0
- package/dist/components/layouts/index.d.ts +16 -0
- package/dist/components/layouts/index.d.ts.map +1 -0
- package/dist/components/layouts/index.js +11 -0
- package/dist/components/layouts/login/config/login_field_config.d.ts +11 -0
- package/dist/components/layouts/login/config/login_field_config.d.ts.map +1 -0
- package/dist/components/layouts/login/config/login_field_config.js +42 -0
- package/dist/components/layouts/login/hooks/use_login_form.d.ts +34 -0
- package/dist/components/layouts/login/hooks/use_login_form.d.ts.map +1 -0
- package/dist/components/layouts/login/hooks/use_login_form.js +196 -0
- package/dist/components/layouts/login/index.d.ts +31 -0
- package/dist/components/layouts/login/index.d.ts.map +1 -0
- package/dist/components/layouts/login/index.js +58 -0
- package/dist/components/layouts/my_settings/components/editable_field.d.ts +19 -0
- package/dist/components/layouts/my_settings/components/editable_field.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/editable_field.js +73 -0
- package/dist/components/layouts/my_settings/components/password_change_dialog.d.ts +28 -0
- package/dist/components/layouts/my_settings/components/password_change_dialog.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/password_change_dialog.js +138 -0
- package/dist/components/layouts/my_settings/components/profile_picture_dialog.d.ts +42 -0
- package/dist/components/layouts/my_settings/components/profile_picture_dialog.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/profile_picture_dialog.js +198 -0
- package/dist/components/layouts/my_settings/components/profile_picture_display.d.ts +16 -0
- package/dist/components/layouts/my_settings/components/profile_picture_display.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/profile_picture_display.js +33 -0
- package/dist/components/layouts/my_settings/components/profile_picture_gravatar_tab.d.ts +17 -0
- package/dist/components/layouts/my_settings/components/profile_picture_gravatar_tab.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/profile_picture_gravatar_tab.js +48 -0
- package/dist/components/layouts/my_settings/components/profile_picture_library_tab.d.ts +21 -0
- package/dist/components/layouts/my_settings/components/profile_picture_library_tab.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/profile_picture_library_tab.js +144 -0
- package/dist/components/layouts/my_settings/components/profile_picture_upload_tab.d.ts +23 -0
- package/dist/components/layouts/my_settings/components/profile_picture_upload_tab.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/components/profile_picture_upload_tab.js +169 -0
- package/dist/components/layouts/my_settings/config/my_settings_field_config.d.ts +19 -0
- package/dist/components/layouts/my_settings/config/my_settings_field_config.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/config/my_settings_field_config.js +26 -0
- package/dist/components/layouts/my_settings/hooks/use_my_settings.d.ts +46 -0
- package/dist/components/layouts/my_settings/hooks/use_my_settings.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/hooks/use_my_settings.js +354 -0
- package/dist/components/layouts/my_settings/index.d.ts +64 -0
- package/dist/components/layouts/my_settings/index.d.ts.map +1 -0
- package/dist/components/layouts/my_settings/index.js +65 -0
- package/dist/components/layouts/register/config/register_field_config.d.ts +14 -0
- package/dist/components/layouts/register/config/register_field_config.d.ts.map +1 -0
- package/dist/components/layouts/register/config/register_field_config.js +69 -0
- package/dist/components/layouts/register/hooks/use_register_form.d.ts +30 -0
- package/dist/components/layouts/register/hooks/use_register_form.d.ts.map +1 -0
- package/dist/components/layouts/register/hooks/use_register_form.js +184 -0
- package/dist/components/layouts/register/index.d.ts +23 -0
- package/dist/components/layouts/register/index.d.ts.map +1 -0
- package/dist/components/layouts/register/index.js +58 -0
- package/dist/components/layouts/reset_password/config/reset_password_field_config.d.ts +13 -0
- package/dist/components/layouts/reset_password/config/reset_password_field_config.d.ts.map +1 -0
- package/dist/components/layouts/reset_password/config/reset_password_field_config.js +53 -0
- package/dist/components/layouts/reset_password/hooks/use_reset_password_form.d.ts +28 -0
- package/dist/components/layouts/reset_password/hooks/use_reset_password_form.d.ts.map +1 -0
- package/dist/components/layouts/reset_password/hooks/use_reset_password_form.js +201 -0
- package/dist/components/layouts/reset_password/index.d.ts +23 -0
- package/dist/components/layouts/reset_password/index.d.ts.map +1 -0
- package/dist/components/layouts/reset_password/index.js +53 -0
- package/dist/components/layouts/shared/components/already_logged_in_guard.d.ts +20 -0
- package/dist/components/layouts/shared/components/already_logged_in_guard.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/already_logged_in_guard.js +32 -0
- package/dist/components/layouts/shared/components/auth_page_shell.d.ts +7 -0
- package/dist/components/layouts/shared/components/auth_page_shell.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/auth_page_shell.js +12 -0
- package/dist/components/layouts/shared/components/field_error_message.d.ts +7 -0
- package/dist/components/layouts/shared/components/field_error_message.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/field_error_message.js +6 -0
- package/dist/components/layouts/shared/components/form_action_buttons.d.ts +14 -0
- package/dist/components/layouts/shared/components/form_action_buttons.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/form_action_buttons.js +15 -0
- package/dist/components/layouts/shared/components/form_field_wrapper.d.ts +11 -0
- package/dist/components/layouts/shared/components/form_field_wrapper.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/form_field_wrapper.js +9 -0
- package/dist/components/layouts/shared/components/form_header.d.ts +10 -0
- package/dist/components/layouts/shared/components/form_header.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/form_header.js +5 -0
- package/dist/components/layouts/shared/components/logout_button.d.ts +7 -0
- package/dist/components/layouts/shared/components/logout_button.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/logout_button.js +44 -0
- package/dist/components/layouts/shared/components/password_field.d.ts +13 -0
- package/dist/components/layouts/shared/components/password_field.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/password_field.js +13 -0
- package/dist/components/layouts/shared/components/profile_pic_menu.d.ts +22 -0
- package/dist/components/layouts/shared/components/profile_pic_menu.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/profile_pic_menu.js +169 -0
- package/dist/components/layouts/shared/components/profile_pic_menu_wrapper.d.ts +12 -0
- package/dist/components/layouts/shared/components/profile_pic_menu_wrapper.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/profile_pic_menu_wrapper.js +16 -0
- package/dist/components/layouts/shared/components/sidebar_layout_wrapper.d.ts +6 -0
- package/dist/components/layouts/shared/components/sidebar_layout_wrapper.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/sidebar_layout_wrapper.js +15 -0
- package/dist/components/layouts/shared/components/standalone_layout_wrapper.d.ts +11 -0
- package/dist/components/layouts/shared/components/standalone_layout_wrapper.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/standalone_layout_wrapper.js +10 -0
- package/dist/components/layouts/shared/components/two_column_auth_layout.d.ts +12 -0
- package/dist/components/layouts/shared/components/two_column_auth_layout.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/two_column_auth_layout.js +8 -0
- package/dist/components/layouts/shared/components/unauthorized_guard.d.ts +14 -0
- package/dist/components/layouts/shared/components/unauthorized_guard.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/unauthorized_guard.js +30 -0
- package/dist/components/layouts/shared/components/visual_panel.d.ts +9 -0
- package/dist/components/layouts/shared/components/visual_panel.d.ts.map +1 -0
- package/dist/components/layouts/shared/components/visual_panel.js +10 -0
- package/dist/components/layouts/shared/config/layout_customization.d.ts +38 -0
- package/dist/components/layouts/shared/config/layout_customization.d.ts.map +1 -0
- package/dist/components/layouts/shared/config/layout_customization.js +19 -0
- package/dist/components/layouts/shared/data/layout_data_client.d.ts +6 -0
- package/dist/components/layouts/shared/data/layout_data_client.d.ts.map +1 -0
- package/dist/components/layouts/shared/data/layout_data_client.js +9 -0
- package/dist/components/layouts/shared/hooks/use_auth_status.d.ts +20 -0
- package/dist/components/layouts/shared/hooks/use_auth_status.d.ts.map +1 -0
- package/dist/components/layouts/shared/hooks/use_auth_status.js +71 -0
- package/dist/components/layouts/shared/hooks/use_hazo_auth.d.ts +48 -0
- package/dist/components/layouts/shared/hooks/use_hazo_auth.d.ts.map +1 -0
- package/dist/components/layouts/shared/hooks/use_hazo_auth.js +90 -0
- package/dist/components/layouts/shared/index.d.ts +24 -0
- package/dist/components/layouts/shared/index.d.ts.map +1 -0
- package/dist/components/layouts/shared/index.js +27 -0
- package/dist/components/layouts/shared/utils/ip_address.d.ts +7 -0
- package/dist/components/layouts/shared/utils/ip_address.d.ts.map +1 -0
- package/dist/components/layouts/shared/utils/ip_address.js +34 -0
- package/dist/components/layouts/shared/utils/validation.d.ts +15 -0
- package/dist/components/layouts/shared/utils/validation.d.ts.map +1 -0
- package/dist/components/layouts/shared/utils/validation.js +45 -0
- package/dist/components/layouts/user_management/components/roles_matrix.d.ts +29 -0
- package/dist/components/layouts/user_management/components/roles_matrix.d.ts.map +1 -0
- package/dist/components/layouts/user_management/components/roles_matrix.js +287 -0
- package/dist/components/layouts/user_management/index.d.ts +13 -0
- package/dist/components/layouts/user_management/index.d.ts.map +1 -0
- package/dist/components/layouts/user_management/index.js +495 -0
- package/dist/components/ui/alert-dialog.d.ts +21 -0
- package/dist/components/ui/alert-dialog.d.ts.map +1 -0
- package/dist/components/ui/alert-dialog.js +62 -0
- package/dist/components/ui/avatar.d.ts +7 -0
- package/dist/components/ui/avatar.d.ts.map +1 -0
- package/dist/components/ui/avatar.js +32 -0
- package/dist/components/ui/button.d.ts +12 -0
- package/dist/components/ui/button.d.ts.map +1 -0
- package/dist/components/ui/button.js +45 -0
- package/dist/components/ui/checkbox.d.ts +5 -0
- package/dist/components/ui/checkbox.d.ts.map +1 -0
- package/dist/components/ui/checkbox.js +23 -0
- package/dist/components/ui/dialog.d.ts +20 -0
- package/dist/components/ui/dialog.d.ts.map +1 -0
- package/dist/components/ui/dialog.js +52 -0
- package/dist/components/ui/dropdown-menu.d.ts +28 -0
- package/dist/components/ui/dropdown-menu.d.ts.map +1 -0
- package/dist/components/ui/dropdown-menu.js +72 -0
- package/dist/components/ui/hazo_ui_tooltip.d.ts +26 -0
- package/dist/components/ui/hazo_ui_tooltip.d.ts.map +1 -0
- package/dist/components/ui/hazo_ui_tooltip.js +17 -0
- package/dist/components/ui/index.d.ts +20 -0
- package/dist/components/ui/index.d.ts.map +1 -0
- package/dist/components/ui/index.js +21 -0
- package/dist/components/ui/input.d.ts +4 -0
- package/dist/components/ui/input.d.ts.map +1 -0
- package/dist/components/ui/input.js +20 -0
- package/dist/components/ui/label.d.ts +6 -0
- package/dist/components/ui/label.d.ts.map +1 -0
- package/dist/components/ui/label.js +24 -0
- package/dist/components/ui/separator.d.ts +5 -0
- package/dist/components/ui/separator.d.ts.map +1 -0
- package/dist/components/ui/separator.js +22 -0
- package/dist/components/ui/sheet.d.ts +23 -0
- package/dist/components/ui/sheet.d.ts.map +1 -0
- package/dist/components/ui/sheet.js +66 -0
- package/dist/components/ui/sidebar.d.ts +66 -0
- package/dist/components/ui/sidebar.d.ts.map +1 -0
- package/dist/components/ui/sidebar.js +267 -0
- package/dist/components/ui/skeleton.d.ts +3 -0
- package/dist/components/ui/skeleton.d.ts.map +1 -0
- package/dist/components/ui/skeleton.js +18 -0
- package/dist/components/ui/sonner.d.ts +5 -0
- package/dist/components/ui/sonner.d.ts.map +1 -0
- package/dist/components/ui/sonner.js +28 -0
- package/dist/components/ui/switch.d.ts +5 -0
- package/dist/components/ui/switch.d.ts.map +1 -0
- package/dist/components/ui/switch.js +22 -0
- package/dist/components/ui/table.d.ts +11 -0
- package/dist/components/ui/table.d.ts.map +1 -0
- package/dist/components/ui/table.js +55 -0
- package/dist/components/ui/tabs.d.ts +8 -0
- package/dist/components/ui/tabs.d.ts.map +1 -0
- package/dist/components/ui/tabs.js +33 -0
- package/dist/components/ui/tooltip.d.ts +8 -0
- package/dist/components/ui/tooltip.d.ts.map +1 -0
- package/dist/components/ui/tooltip.js +25 -0
- package/dist/components/ui/vertical-tabs.d.ts +8 -0
- package/dist/components/ui/vertical-tabs.d.ts.map +1 -0
- package/dist/components/ui/vertical-tabs.js +37 -0
- package/dist/hooks/use-mobile.d.ts +2 -0
- package/dist/hooks/use-mobile.d.ts.map +1 -0
- package/dist/hooks/use-mobile.js +15 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +5 -0
- package/dist/lib/already_logged_in_config.server.d.ts +14 -0
- package/dist/lib/already_logged_in_config.server.d.ts.map +1 -0
- package/dist/lib/already_logged_in_config.server.js +29 -0
- package/dist/lib/app_logger.d.ts +12 -0
- package/dist/lib/app_logger.d.ts.map +1 -0
- package/dist/lib/app_logger.js +14 -0
- package/dist/lib/auth/auth_cache.d.ts +83 -0
- package/dist/lib/auth/auth_cache.d.ts.map +1 -0
- package/dist/lib/auth/auth_cache.js +158 -0
- package/dist/lib/auth/auth_rate_limiter.d.ts +39 -0
- package/dist/lib/auth/auth_rate_limiter.d.ts.map +1 -0
- package/dist/lib/auth/auth_rate_limiter.js +95 -0
- package/dist/lib/auth/auth_types.d.ts +53 -0
- package/dist/lib/auth/auth_types.d.ts.map +1 -0
- package/dist/lib/auth/auth_types.js +16 -0
- package/dist/lib/auth/auth_utils.server.d.ts +47 -0
- package/dist/lib/auth/auth_utils.server.d.ts.map +1 -0
- package/dist/lib/auth/auth_utils.server.js +150 -0
- package/dist/lib/auth/hazo_get_auth.server.d.ts +12 -0
- package/dist/lib/auth/hazo_get_auth.server.d.ts.map +1 -0
- package/dist/lib/auth/hazo_get_auth.server.js +256 -0
- package/dist/lib/auth/index.d.ts +9 -0
- package/dist/lib/auth/index.d.ts.map +1 -0
- package/dist/lib/auth/index.js +12 -0
- package/dist/lib/auth/server_auth.d.ts +26 -0
- package/dist/lib/auth/server_auth.d.ts.map +1 -0
- package/dist/lib/auth/server_auth.js +62 -0
- package/dist/lib/auth_utility_config.server.d.ts +20 -0
- package/dist/lib/auth_utility_config.server.d.ts.map +1 -0
- package/dist/lib/auth_utility_config.server.js +64 -0
- package/dist/lib/config/config_loader.server.d.ts +44 -0
- package/dist/lib/config/config_loader.server.d.ts.map +1 -0
- package/dist/lib/config/config_loader.server.js +122 -0
- package/dist/lib/email_verification_config.server.d.ts +14 -0
- package/dist/lib/email_verification_config.server.d.ts.map +1 -0
- package/dist/lib/email_verification_config.server.js +20 -0
- package/dist/lib/file_types_config.server.d.ts +11 -0
- package/dist/lib/file_types_config.server.d.ts.map +1 -0
- package/dist/lib/file_types_config.server.js +16 -0
- package/dist/lib/forgot_password_config.server.d.ts +14 -0
- package/dist/lib/forgot_password_config.server.d.ts.map +1 -0
- package/dist/lib/forgot_password_config.server.js +20 -0
- package/dist/lib/hazo_connect_instance.server.d.ts +17 -0
- package/dist/lib/hazo_connect_instance.server.d.ts.map +1 -0
- package/dist/lib/hazo_connect_instance.server.js +88 -0
- package/dist/lib/hazo_connect_setup.d.ts +2 -0
- package/dist/lib/hazo_connect_setup.d.ts.map +1 -0
- package/dist/lib/hazo_connect_setup.js +49 -0
- package/dist/lib/hazo_connect_setup.server.d.ts +20 -0
- package/dist/lib/hazo_connect_setup.server.d.ts.map +1 -0
- package/dist/lib/hazo_connect_setup.server.js +138 -0
- package/dist/lib/index.d.ts +28 -0
- package/dist/lib/index.d.ts.map +1 -0
- package/dist/lib/index.js +35 -0
- package/dist/lib/login_config.server.d.ts +20 -0
- package/dist/lib/login_config.server.d.ts.map +1 -0
- package/dist/lib/login_config.server.js +37 -0
- package/dist/lib/messages_config.server.d.ts +13 -0
- package/dist/lib/messages_config.server.d.ts.map +1 -0
- package/dist/lib/messages_config.server.js +18 -0
- package/dist/lib/migrations/apply_migration.d.ts +22 -0
- package/dist/lib/migrations/apply_migration.d.ts.map +1 -0
- package/dist/lib/migrations/apply_migration.js +78 -0
- package/dist/lib/my_settings_config.server.d.ts +65 -0
- package/dist/lib/my_settings_config.server.d.ts.map +1 -0
- package/dist/lib/my_settings_config.server.js +67 -0
- package/dist/lib/password_requirements_config.server.d.ts +15 -0
- package/dist/lib/password_requirements_config.server.d.ts.map +1 -0
- package/dist/lib/password_requirements_config.server.js +26 -0
- package/dist/lib/profile_pic_menu_config.server.d.ts +26 -0
- package/dist/lib/profile_pic_menu_config.server.d.ts.map +1 -0
- package/dist/lib/profile_pic_menu_config.server.js +95 -0
- package/dist/lib/profile_picture_config.server.d.ts +16 -0
- package/dist/lib/profile_picture_config.server.d.ts.map +1 -0
- package/dist/lib/profile_picture_config.server.js +40 -0
- package/dist/lib/register_config.server.d.ts +24 -0
- package/dist/lib/register_config.server.d.ts.map +1 -0
- package/dist/lib/register_config.server.js +39 -0
- package/dist/lib/reset_password_config.server.d.ts +25 -0
- package/dist/lib/reset_password_config.server.d.ts.map +1 -0
- package/dist/lib/reset_password_config.server.js +38 -0
- package/dist/lib/services/email_service.d.ts +44 -0
- package/dist/lib/services/email_service.d.ts.map +1 -0
- package/dist/lib/services/email_service.js +480 -0
- package/dist/lib/services/email_verification_service.d.ts +35 -0
- package/dist/lib/services/email_verification_service.d.ts.map +1 -0
- package/dist/lib/services/email_verification_service.js +208 -0
- package/dist/lib/services/index.d.ts +13 -0
- package/dist/lib/services/index.d.ts.map +1 -0
- package/dist/lib/services/index.js +14 -0
- package/dist/lib/services/login_service.d.ts +20 -0
- package/dist/lib/services/login_service.d.ts.map +1 -0
- package/dist/lib/services/login_service.js +94 -0
- package/dist/lib/services/password_change_service.d.ts +19 -0
- package/dist/lib/services/password_change_service.d.ts.map +1 -0
- package/dist/lib/services/password_change_service.js +118 -0
- package/dist/lib/services/password_reset_service.d.ts +52 -0
- package/dist/lib/services/password_reset_service.d.ts.map +1 -0
- package/dist/lib/services/password_reset_service.js +318 -0
- package/dist/lib/services/profile_picture_remove_service.d.ts +15 -0
- package/dist/lib/services/profile_picture_remove_service.d.ts.map +1 -0
- package/dist/lib/services/profile_picture_remove_service.js +94 -0
- package/dist/lib/services/profile_picture_service.d.ts +45 -0
- package/dist/lib/services/profile_picture_service.d.ts.map +1 -0
- package/dist/lib/services/profile_picture_service.js +183 -0
- package/dist/lib/services/profile_picture_source_mapper.d.ts +23 -0
- package/dist/lib/services/profile_picture_source_mapper.d.ts.map +1 -0
- package/dist/lib/services/profile_picture_source_mapper.js +45 -0
- package/dist/lib/services/registration_service.d.ts +20 -0
- package/dist/lib/services/registration_service.d.ts.map +1 -0
- package/dist/lib/services/registration_service.js +147 -0
- package/dist/lib/services/token_service.d.ts +20 -0
- package/dist/lib/services/token_service.d.ts.map +1 -0
- package/dist/lib/services/token_service.js +201 -0
- package/dist/lib/services/user_profiles_service.d.ts +31 -0
- package/dist/lib/services/user_profiles_service.d.ts.map +1 -0
- package/dist/lib/services/user_profiles_service.js +99 -0
- package/dist/lib/services/user_update_service.d.ts +23 -0
- package/dist/lib/services/user_update_service.d.ts.map +1 -0
- package/dist/lib/services/user_update_service.js +103 -0
- package/dist/lib/ui_shell_config.server.d.ts +16 -0
- package/dist/lib/ui_shell_config.server.d.ts.map +1 -0
- package/dist/lib/ui_shell_config.server.js +28 -0
- package/dist/lib/ui_sizes_config.server.d.ts +17 -0
- package/dist/lib/ui_sizes_config.server.d.ts.map +1 -0
- package/dist/lib/ui_sizes_config.server.js +22 -0
- package/dist/lib/user_fields_config.server.d.ts +13 -0
- package/dist/lib/user_fields_config.server.d.ts.map +1 -0
- package/dist/lib/user_fields_config.server.js +21 -0
- package/dist/lib/user_management_config.server.d.ts +10 -0
- package/dist/lib/user_management_config.server.d.ts.map +1 -0
- package/dist/lib/user_management_config.server.js +26 -0
- package/dist/lib/utils/api_route_helpers.d.ts +13 -0
- package/dist/lib/utils/api_route_helpers.d.ts.map +1 -0
- package/dist/lib/utils/api_route_helpers.js +58 -0
- package/dist/lib/utils/error_sanitizer.d.ts +16 -0
- package/dist/lib/utils/error_sanitizer.d.ts.map +1 -0
- package/dist/lib/utils/error_sanitizer.js +39 -0
- package/dist/lib/utils.d.ts +4 -0
- package/dist/lib/utils.d.ts.map +1 -0
- package/dist/lib/utils.js +9 -0
- package/dist/server/config/config_loader.d.ts +26 -0
- package/dist/server/config/config_loader.d.ts.map +1 -0
- package/dist/server/config/config_loader.js +329 -0
- package/dist/server/index.d.ts +2 -0
- package/dist/server/index.d.ts.map +1 -0
- package/dist/server/index.js +32 -0
- package/dist/server/logging/logger_service.d.ts +3 -0
- package/dist/server/logging/logger_service.d.ts.map +1 -0
- package/dist/server/logging/logger_service.js +37 -0
- package/dist/server/routes/root_router.d.ts +3 -0
- package/dist/server/routes/root_router.d.ts.map +1 -0
- package/dist/server/routes/root_router.js +14 -0
- package/dist/server/server.d.ts +3 -0
- package/dist/server/server.d.ts.map +1 -0
- package/dist/server/server.js +25 -0
- package/dist/server/types/app_types.d.ts +53 -0
- package/dist/server/types/app_types.d.ts.map +1 -0
- package/dist/server/types/app_types.js +1 -0
- package/migrations/003_add_url_on_logon_to_hazo_users.sql +8 -0
- package/next.config.mjs +12 -0
- package/package.json +150 -1
- package/src/components/index.ts +7 -0
- 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/index.ts +26 -0
- 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/index.ts +34 -0
- 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/index.ts +22 -0
- 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/index.ts +7 -0
- 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/index.ts +23 -0
- 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/index.ts +44 -0
- 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/index.ts +15 -0
- 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 -2
- package/src/lib/utils/error_sanitizer.ts +1 -1
- package/src/routes/index.ts +34 -0
- 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 +39 -0
- package/tsconfig.json +5 -1
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* UI representation of profile picture source
|
|
3
|
+
* Used in components and API interfaces
|
|
4
|
+
*/
|
|
5
|
+
export type ProfilePictureSourceUI = "upload" | "library" | "gravatar" | "custom";
|
|
6
|
+
/**
|
|
7
|
+
* Database enum values for profile_source
|
|
8
|
+
* Must match the CHECK constraint in the database
|
|
9
|
+
*/
|
|
10
|
+
export type ProfilePictureSourceDB = "gravatar" | "custom" | "predefined";
|
|
11
|
+
/**
|
|
12
|
+
* Maps UI profile picture source to database enum value
|
|
13
|
+
* @param uiSource - UI representation of source ("upload", "library", "gravatar", "custom")
|
|
14
|
+
* @returns Database enum value ("gravatar", "custom", "predefined")
|
|
15
|
+
*/
|
|
16
|
+
export declare function map_ui_source_to_db(uiSource: ProfilePictureSourceUI): ProfilePictureSourceDB;
|
|
17
|
+
/**
|
|
18
|
+
* Maps database enum value to UI representation
|
|
19
|
+
* @param dbSource - Database enum value ("gravatar", "custom", "predefined")
|
|
20
|
+
* @returns UI representation ("upload", "library", "gravatar", "custom")
|
|
21
|
+
*/
|
|
22
|
+
export declare function map_db_source_to_ui(dbSource: ProfilePictureSourceDB | string | null | undefined): ProfilePictureSourceUI;
|
|
23
|
+
//# sourceMappingURL=profile_picture_source_mapper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"profile_picture_source_mapper.d.ts","sourceRoot":"","sources":["../../../src/lib/services/profile_picture_source_mapper.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,MAAM,MAAM,sBAAsB,GAAG,QAAQ,GAAG,SAAS,GAAG,UAAU,GAAG,QAAQ,CAAC;AAElF;;;GAGG;AACH,MAAM,MAAM,sBAAsB,GAAG,UAAU,GAAG,QAAQ,GAAG,YAAY,CAAC;AAG1E;;;;GAIG;AACH,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,sBAAsB,GAAG,sBAAsB,CAc5F;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,sBAAsB,GAAG,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,sBAAsB,CAmBxH"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// section: helpers
|
|
2
|
+
/**
|
|
3
|
+
* Maps UI profile picture source to database enum value
|
|
4
|
+
* @param uiSource - UI representation of source ("upload", "library", "gravatar", "custom")
|
|
5
|
+
* @returns Database enum value ("gravatar", "custom", "predefined")
|
|
6
|
+
*/
|
|
7
|
+
export function map_ui_source_to_db(uiSource) {
|
|
8
|
+
switch (uiSource) {
|
|
9
|
+
case "upload":
|
|
10
|
+
return "custom"; // User uploaded their own photo
|
|
11
|
+
case "library":
|
|
12
|
+
return "predefined"; // User selected from predefined library
|
|
13
|
+
case "gravatar":
|
|
14
|
+
return "gravatar"; // User's Gravatar
|
|
15
|
+
case "custom":
|
|
16
|
+
return "custom"; // Already in database format
|
|
17
|
+
default:
|
|
18
|
+
// Fallback to custom for unknown values
|
|
19
|
+
return "custom";
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Maps database enum value to UI representation
|
|
24
|
+
* @param dbSource - Database enum value ("gravatar", "custom", "predefined")
|
|
25
|
+
* @returns UI representation ("upload", "library", "gravatar", "custom")
|
|
26
|
+
*/
|
|
27
|
+
export function map_db_source_to_ui(dbSource) {
|
|
28
|
+
if (!dbSource) {
|
|
29
|
+
return "custom"; // Default fallback
|
|
30
|
+
}
|
|
31
|
+
switch (dbSource) {
|
|
32
|
+
case "gravatar":
|
|
33
|
+
return "gravatar";
|
|
34
|
+
case "custom":
|
|
35
|
+
return "upload"; // Map custom to upload in UI (user uploaded their own)
|
|
36
|
+
case "predefined":
|
|
37
|
+
return "library"; // Map predefined to library in UI (user selected from library)
|
|
38
|
+
default:
|
|
39
|
+
// For unknown values, try to return as-is if it matches UI format
|
|
40
|
+
if (dbSource === "upload" || dbSource === "library") {
|
|
41
|
+
return dbSource;
|
|
42
|
+
}
|
|
43
|
+
return "custom"; // Fallback
|
|
44
|
+
}
|
|
45
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { HazoConnectAdapter } from "hazo_connect";
|
|
2
|
+
export type RegistrationData = {
|
|
3
|
+
email: string;
|
|
4
|
+
password: string;
|
|
5
|
+
name?: string;
|
|
6
|
+
url_on_logon?: string;
|
|
7
|
+
};
|
|
8
|
+
export type RegistrationResult = {
|
|
9
|
+
success: boolean;
|
|
10
|
+
user_id?: string;
|
|
11
|
+
error?: string;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Registers a new user in the database using hazo_connect
|
|
15
|
+
* @param adapter - The hazo_connect adapter instance
|
|
16
|
+
* @param data - Registration data (email, password, optional name)
|
|
17
|
+
* @returns Registration result with success status and user_id or error
|
|
18
|
+
*/
|
|
19
|
+
export declare function register_user(adapter: HazoConnectAdapter, data: RegistrationData): Promise<RegistrationResult>;
|
|
20
|
+
//# sourceMappingURL=registration_service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registration_service.d.ts","sourceRoot":"","sources":["../../../src/lib/services/registration_service.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAcvD,MAAM,MAAM,gBAAgB,GAAG;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAGF;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,kBAAkB,EAC3B,IAAI,EAAE,gBAAgB,GACrB,OAAO,CAAC,kBAAkB,CAAC,CA+I7B"}
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import { createCrudService } from "hazo_connect/server";
|
|
2
|
+
import argon2 from "argon2";
|
|
3
|
+
import { randomUUID } from "crypto";
|
|
4
|
+
import { create_token } from "hazo_auth/lib/services/token_service";
|
|
5
|
+
import { get_default_profile_picture } from "hazo_auth/lib/services/profile_picture_service";
|
|
6
|
+
import { get_profile_picture_config } from "hazo_auth/lib/profile_picture_config.server";
|
|
7
|
+
import { map_ui_source_to_db } from "hazo_auth/lib/services/profile_picture_source_mapper";
|
|
8
|
+
import { create_app_logger } from "hazo_auth/lib/app_logger";
|
|
9
|
+
import { send_template_email } from "hazo_auth/lib/services/email_service";
|
|
10
|
+
import { sanitize_error_for_user } from "hazo_auth/lib/utils/error_sanitizer";
|
|
11
|
+
import { get_line_number } from "hazo_auth/lib/utils/api_route_helpers";
|
|
12
|
+
// section: helpers
|
|
13
|
+
/**
|
|
14
|
+
* Registers a new user in the database using hazo_connect
|
|
15
|
+
* @param adapter - The hazo_connect adapter instance
|
|
16
|
+
* @param data - Registration data (email, password, optional name)
|
|
17
|
+
* @returns Registration result with success status and user_id or error
|
|
18
|
+
*/
|
|
19
|
+
export async function register_user(adapter, data) {
|
|
20
|
+
try {
|
|
21
|
+
const { email, password, name, url_on_logon } = data;
|
|
22
|
+
// Create CRUD service for hazo_users table
|
|
23
|
+
const users_service = createCrudService(adapter, "hazo_users");
|
|
24
|
+
// Check if user already exists
|
|
25
|
+
const existing_users = await users_service.findBy({
|
|
26
|
+
email_address: email,
|
|
27
|
+
});
|
|
28
|
+
if (Array.isArray(existing_users) && existing_users.length > 0) {
|
|
29
|
+
return {
|
|
30
|
+
success: false,
|
|
31
|
+
error: "Email address already registered",
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
// Hash password using argon2
|
|
35
|
+
const password_hash = await argon2.hash(password);
|
|
36
|
+
// Generate user ID
|
|
37
|
+
const user_id = randomUUID();
|
|
38
|
+
const now = new Date().toISOString();
|
|
39
|
+
// Insert user into database using CRUD service
|
|
40
|
+
const insert_data = {
|
|
41
|
+
id: user_id,
|
|
42
|
+
email_address: email,
|
|
43
|
+
password_hash: password_hash,
|
|
44
|
+
email_verified: false,
|
|
45
|
+
is_active: true,
|
|
46
|
+
login_attempts: 0,
|
|
47
|
+
created_at: now,
|
|
48
|
+
changed_at: now,
|
|
49
|
+
};
|
|
50
|
+
// Include name if provided
|
|
51
|
+
if (name) {
|
|
52
|
+
insert_data.name = name;
|
|
53
|
+
}
|
|
54
|
+
// Validate and include url_on_logon if provided
|
|
55
|
+
if (url_on_logon) {
|
|
56
|
+
// Ensure it's a relative path starting with / but not //
|
|
57
|
+
if (url_on_logon.startsWith("/") && !url_on_logon.startsWith("//")) {
|
|
58
|
+
insert_data.url_on_logon = url_on_logon;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
// Set default profile picture if enabled
|
|
62
|
+
const profile_picture_config = get_profile_picture_config();
|
|
63
|
+
if (profile_picture_config.user_photo_default) {
|
|
64
|
+
const default_photo = get_default_profile_picture(email, name);
|
|
65
|
+
if (default_photo) {
|
|
66
|
+
insert_data.profile_picture_url = default_photo.profile_picture_url;
|
|
67
|
+
// Map UI source value to database enum value
|
|
68
|
+
insert_data.profile_source = map_ui_source_to_db(default_photo.profile_source);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
const inserted_users = await users_service.insert(insert_data);
|
|
72
|
+
// Verify insertion was successful
|
|
73
|
+
if (!Array.isArray(inserted_users) || inserted_users.length === 0) {
|
|
74
|
+
return {
|
|
75
|
+
success: false,
|
|
76
|
+
error: "Failed to create user account",
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
// Create email verification token for the new user
|
|
80
|
+
const token_result = await create_token({
|
|
81
|
+
adapter,
|
|
82
|
+
user_id,
|
|
83
|
+
token_type: "email_verification",
|
|
84
|
+
});
|
|
85
|
+
if (!token_result.success) {
|
|
86
|
+
// Log error but don't fail registration - token can be resent later
|
|
87
|
+
const logger = create_app_logger();
|
|
88
|
+
const error_message = token_result.error || "Unknown error";
|
|
89
|
+
logger.error("registration_service_token_creation_failed", {
|
|
90
|
+
filename: "registration_service.ts",
|
|
91
|
+
line_number: 0,
|
|
92
|
+
user_id,
|
|
93
|
+
error: error_message,
|
|
94
|
+
note: "This may be due to missing token_type column in hazo_refresh_tokens table. Please ensure migration 001_add_token_type_to_refresh_tokens.sql has been applied.",
|
|
95
|
+
});
|
|
96
|
+
}
|
|
97
|
+
else {
|
|
98
|
+
const logger = create_app_logger();
|
|
99
|
+
logger.info("registration_service_token_created", {
|
|
100
|
+
filename: "registration_service.ts",
|
|
101
|
+
line_number: 0,
|
|
102
|
+
user_id,
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
// Send verification email if token was created successfully
|
|
106
|
+
if (token_result.success && token_result.raw_token) {
|
|
107
|
+
const email_result = await send_template_email("email_verification", email, {
|
|
108
|
+
token: token_result.raw_token,
|
|
109
|
+
user_email: email,
|
|
110
|
+
user_name: name,
|
|
111
|
+
});
|
|
112
|
+
if (!email_result.success) {
|
|
113
|
+
const logger = create_app_logger();
|
|
114
|
+
logger.error("registration_service_email_send_failed", {
|
|
115
|
+
filename: "registration_service.ts",
|
|
116
|
+
line_number: 0,
|
|
117
|
+
user_id,
|
|
118
|
+
email,
|
|
119
|
+
error: email_result.error,
|
|
120
|
+
note: "User registration succeeded but verification email failed to send",
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
return {
|
|
125
|
+
success: true,
|
|
126
|
+
user_id,
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
catch (error) {
|
|
130
|
+
const logger = create_app_logger();
|
|
131
|
+
const user_friendly_error = sanitize_error_for_user(error, {
|
|
132
|
+
logToConsole: true,
|
|
133
|
+
logToLogger: true,
|
|
134
|
+
logger,
|
|
135
|
+
context: {
|
|
136
|
+
filename: "registration_service.ts",
|
|
137
|
+
line_number: get_line_number(),
|
|
138
|
+
email: data.email,
|
|
139
|
+
operation: "register_user",
|
|
140
|
+
},
|
|
141
|
+
});
|
|
142
|
+
return {
|
|
143
|
+
success: false,
|
|
144
|
+
error: user_friendly_error,
|
|
145
|
+
};
|
|
146
|
+
}
|
|
147
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { HazoConnectAdapter } from "hazo_connect";
|
|
2
|
+
export type TokenType = "refresh" | "password_reset" | "email_verification";
|
|
3
|
+
export type CreateTokenParams = {
|
|
4
|
+
adapter: HazoConnectAdapter;
|
|
5
|
+
user_id: string;
|
|
6
|
+
token_type: TokenType;
|
|
7
|
+
};
|
|
8
|
+
export type CreateTokenResult = {
|
|
9
|
+
success: boolean;
|
|
10
|
+
raw_token?: string;
|
|
11
|
+
error?: string;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Creates a token for a user and stores it in hazo_refresh_tokens table
|
|
15
|
+
* Invalidates any existing tokens of the same type for the user before creating a new one
|
|
16
|
+
* @param params - Token creation parameters (adapter, user_id, token_type)
|
|
17
|
+
* @returns Token creation result with raw_token (for sending to user) or error
|
|
18
|
+
*/
|
|
19
|
+
export declare function create_token(params: CreateTokenParams): Promise<CreateTokenResult>;
|
|
20
|
+
//# sourceMappingURL=token_service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"token_service.d.ts","sourceRoot":"","sources":["../../../src/lib/services/token_service.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAQvD,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,gBAAgB,GAAG,oBAAoB,CAAC;AAE5E,MAAM,MAAM,iBAAiB,GAAG;IAC9B,OAAO,EAAE,kBAAkB,CAAC;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,SAAS,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AA+BF;;;;;GAKG;AACH,wBAAsB,YAAY,CAChC,MAAM,EAAE,iBAAiB,GACxB,OAAO,CAAC,iBAAiB,CAAC,CAiL5B"}
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
import { createCrudService } from "hazo_connect/server";
|
|
2
|
+
import { randomBytes, randomUUID } from "crypto";
|
|
3
|
+
import argon2 from "argon2";
|
|
4
|
+
import { read_config_section } from "hazo_auth/lib/config/config_loader.server";
|
|
5
|
+
import { create_app_logger } from "hazo_auth/lib/app_logger";
|
|
6
|
+
// section: helpers
|
|
7
|
+
/**
|
|
8
|
+
* Gets token expiry hours from hazo_auth_config.ini for a specific token type
|
|
9
|
+
* Falls back to defaults if config is not found
|
|
10
|
+
* @param token_type - The type of token (refresh, password_reset, email_verification)
|
|
11
|
+
* @returns Number of hours until token expires
|
|
12
|
+
*/
|
|
13
|
+
function get_token_expiry_hours(token_type) {
|
|
14
|
+
const default_expiries = {
|
|
15
|
+
refresh: 720, // 30 days
|
|
16
|
+
password_reset: 0.167, // 10 minutes
|
|
17
|
+
email_verification: 48, // 48 hours
|
|
18
|
+
};
|
|
19
|
+
const logger = create_app_logger();
|
|
20
|
+
const token_config_section = read_config_section("hazo_auth__tokens");
|
|
21
|
+
// Get expiry from config or environment variable or default
|
|
22
|
+
const config_key = `${token_type}_expiry_hours`;
|
|
23
|
+
const env_key = `HAZO_AUTH_${token_type.toUpperCase()}_TOKEN_EXPIRY_HOURS`;
|
|
24
|
+
const expiry_hours = (token_config_section === null || token_config_section === void 0 ? void 0 : token_config_section[config_key]) ||
|
|
25
|
+
process.env[env_key] ||
|
|
26
|
+
default_expiries[token_type];
|
|
27
|
+
return parseFloat(String(expiry_hours)) || default_expiries[token_type];
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Creates a token for a user and stores it in hazo_refresh_tokens table
|
|
31
|
+
* Invalidates any existing tokens of the same type for the user before creating a new one
|
|
32
|
+
* @param params - Token creation parameters (adapter, user_id, token_type)
|
|
33
|
+
* @returns Token creation result with raw_token (for sending to user) or error
|
|
34
|
+
*/
|
|
35
|
+
export async function create_token(params) {
|
|
36
|
+
try {
|
|
37
|
+
const { adapter, user_id, token_type } = params;
|
|
38
|
+
// Create CRUD service for hazo_refresh_tokens table
|
|
39
|
+
const tokens_service = createCrudService(adapter, "hazo_refresh_tokens");
|
|
40
|
+
// Invalidate any existing tokens of this type for this user
|
|
41
|
+
// If token_type column doesn't exist, this will fail - catch and continue
|
|
42
|
+
let existing_tokens = [];
|
|
43
|
+
try {
|
|
44
|
+
existing_tokens = (await tokens_service.findBy({
|
|
45
|
+
user_id: user_id,
|
|
46
|
+
token_type: token_type,
|
|
47
|
+
}));
|
|
48
|
+
}
|
|
49
|
+
catch (error) {
|
|
50
|
+
// If token_type column doesn't exist, try without it
|
|
51
|
+
// This is a fallback for databases that haven't had the migration applied
|
|
52
|
+
const logger = create_app_logger();
|
|
53
|
+
const error_message = error instanceof Error ? error.message : "Unknown error";
|
|
54
|
+
logger.warn("token_service_token_type_column_missing", {
|
|
55
|
+
filename: "token_service.ts",
|
|
56
|
+
line_number: 0,
|
|
57
|
+
user_id,
|
|
58
|
+
token_type,
|
|
59
|
+
error: error_message,
|
|
60
|
+
note: "token_type column may not exist, trying without filter",
|
|
61
|
+
});
|
|
62
|
+
// Try to find tokens by user_id only (less precise but works without migration)
|
|
63
|
+
try {
|
|
64
|
+
existing_tokens = (await tokens_service.findBy({
|
|
65
|
+
user_id: user_id,
|
|
66
|
+
}));
|
|
67
|
+
}
|
|
68
|
+
catch (fallbackError) {
|
|
69
|
+
// If that also fails, log and continue (will just create new token)
|
|
70
|
+
const fallback_error_message = fallbackError instanceof Error ? fallbackError.message : "Unknown error";
|
|
71
|
+
logger.warn("token_service_query_existing_tokens_failed", {
|
|
72
|
+
filename: "token_service.ts",
|
|
73
|
+
line_number: 0,
|
|
74
|
+
user_id,
|
|
75
|
+
error: fallback_error_message,
|
|
76
|
+
note: "Could not query existing tokens, will create new token anyway",
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
if (Array.isArray(existing_tokens) && existing_tokens.length > 0) {
|
|
81
|
+
// Delete existing tokens (of this type if token_type exists, or all for user if not)
|
|
82
|
+
for (const token of existing_tokens) {
|
|
83
|
+
try {
|
|
84
|
+
await tokens_service.deleteById(token.id);
|
|
85
|
+
}
|
|
86
|
+
catch (deleteError) {
|
|
87
|
+
const logger = create_app_logger();
|
|
88
|
+
const error_message = deleteError instanceof Error ? deleteError.message : "Unknown error";
|
|
89
|
+
logger.warn("token_service_delete_existing_token_failed", {
|
|
90
|
+
filename: "token_service.ts",
|
|
91
|
+
line_number: 0,
|
|
92
|
+
user_id,
|
|
93
|
+
token_id: token.id,
|
|
94
|
+
error: error_message,
|
|
95
|
+
});
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
// Generate a secure random token
|
|
100
|
+
const raw_token = randomBytes(32).toString("hex");
|
|
101
|
+
// Hash the token before storing
|
|
102
|
+
const token_hash = await argon2.hash(raw_token);
|
|
103
|
+
// Get expiry hours from config
|
|
104
|
+
const expiry_hours = get_token_expiry_hours(token_type);
|
|
105
|
+
// Calculate expiration time (convert hours to milliseconds)
|
|
106
|
+
const expires_at = new Date();
|
|
107
|
+
expires_at.setTime(expires_at.getTime() + expiry_hours * 60 * 60 * 1000);
|
|
108
|
+
const now = new Date().toISOString();
|
|
109
|
+
// Insert the token into the database
|
|
110
|
+
// Try with token_type first, fallback to without if column doesn't exist
|
|
111
|
+
let inserted_tokens;
|
|
112
|
+
try {
|
|
113
|
+
inserted_tokens = (await tokens_service.insert({
|
|
114
|
+
id: randomUUID(),
|
|
115
|
+
user_id: user_id,
|
|
116
|
+
token_hash: token_hash,
|
|
117
|
+
token_type: token_type,
|
|
118
|
+
expires_at: expires_at.toISOString(),
|
|
119
|
+
created_at: now,
|
|
120
|
+
}));
|
|
121
|
+
}
|
|
122
|
+
catch (error) {
|
|
123
|
+
// If token_type column doesn't exist, try without it
|
|
124
|
+
const logger = create_app_logger();
|
|
125
|
+
const error_message = error instanceof Error ? error.message : "Unknown error";
|
|
126
|
+
logger.warn("token_service_insert_with_token_type_failed", {
|
|
127
|
+
filename: "token_service.ts",
|
|
128
|
+
line_number: 0,
|
|
129
|
+
user_id,
|
|
130
|
+
token_type,
|
|
131
|
+
error: error_message,
|
|
132
|
+
note: "token_type column may not exist, inserting without it",
|
|
133
|
+
});
|
|
134
|
+
// Fallback: insert without token_type (will use default if column exists with default)
|
|
135
|
+
inserted_tokens = (await tokens_service.insert({
|
|
136
|
+
id: randomUUID(),
|
|
137
|
+
user_id: user_id,
|
|
138
|
+
token_hash: token_hash,
|
|
139
|
+
expires_at: expires_at.toISOString(),
|
|
140
|
+
created_at: now,
|
|
141
|
+
}));
|
|
142
|
+
}
|
|
143
|
+
// Verify insertion was successful
|
|
144
|
+
if (!Array.isArray(inserted_tokens) || inserted_tokens.length === 0) {
|
|
145
|
+
const logger = create_app_logger();
|
|
146
|
+
const error_msg = `Failed to create ${token_type} token - no rows inserted`;
|
|
147
|
+
logger.error("token_service_insertion_failed", {
|
|
148
|
+
filename: "token_service.ts",
|
|
149
|
+
line_number: 0,
|
|
150
|
+
user_id,
|
|
151
|
+
token_type,
|
|
152
|
+
error: error_msg,
|
|
153
|
+
});
|
|
154
|
+
return {
|
|
155
|
+
success: false,
|
|
156
|
+
error: error_msg,
|
|
157
|
+
};
|
|
158
|
+
}
|
|
159
|
+
const logger = create_app_logger();
|
|
160
|
+
logger.info("token_service_token_created", {
|
|
161
|
+
filename: "token_service.ts",
|
|
162
|
+
line_number: 0,
|
|
163
|
+
user_id,
|
|
164
|
+
token_type,
|
|
165
|
+
});
|
|
166
|
+
// Log raw token and test URLs in debug mode (logger handles dev mode)
|
|
167
|
+
logger.debug("token_service_raw_token", {
|
|
168
|
+
filename: "token_service.ts",
|
|
169
|
+
line_number: 0,
|
|
170
|
+
user_id,
|
|
171
|
+
token_type,
|
|
172
|
+
raw_token,
|
|
173
|
+
test_url: token_type === "email_verification"
|
|
174
|
+
? `/hazo_auth/verify_email?token=${raw_token}`
|
|
175
|
+
: token_type === "password_reset"
|
|
176
|
+
? `/hazo_auth/reset_password?token=${raw_token}`
|
|
177
|
+
: undefined,
|
|
178
|
+
});
|
|
179
|
+
return {
|
|
180
|
+
success: true,
|
|
181
|
+
raw_token,
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
catch (error) {
|
|
185
|
+
const logger = create_app_logger();
|
|
186
|
+
const error_message = error instanceof Error ? error.message : "Unknown error";
|
|
187
|
+
const error_stack = error instanceof Error ? error.stack : undefined;
|
|
188
|
+
logger.error("token_service_create_token_error", {
|
|
189
|
+
filename: "token_service.ts",
|
|
190
|
+
line_number: 0,
|
|
191
|
+
user_id: params.user_id,
|
|
192
|
+
token_type: params.token_type,
|
|
193
|
+
error: error_message,
|
|
194
|
+
error_stack,
|
|
195
|
+
});
|
|
196
|
+
return {
|
|
197
|
+
success: false,
|
|
198
|
+
error: error_message,
|
|
199
|
+
};
|
|
200
|
+
}
|
|
201
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { HazoConnectAdapter } from "hazo_connect";
|
|
2
|
+
/**
|
|
3
|
+
* Basic user profile information returned by get_profiles
|
|
4
|
+
* Contains resolved profile picture URL, email, name, and account age
|
|
5
|
+
*/
|
|
6
|
+
export type UserProfileInfo = {
|
|
7
|
+
user_id: string;
|
|
8
|
+
profile_picture_url: string | null;
|
|
9
|
+
email: string;
|
|
10
|
+
name: string | null;
|
|
11
|
+
days_since_created: number;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Result type for get_profiles function
|
|
15
|
+
* Includes found profiles and list of IDs that were not found
|
|
16
|
+
*/
|
|
17
|
+
export type GetProfilesResult = {
|
|
18
|
+
success: boolean;
|
|
19
|
+
profiles: UserProfileInfo[];
|
|
20
|
+
not_found_ids: string[];
|
|
21
|
+
error?: string;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Retrieves basic profile information for multiple users in a single batch call
|
|
25
|
+
* Useful for chat applications and similar use cases where basic user info is needed
|
|
26
|
+
* @param adapter - The hazo_connect adapter instance
|
|
27
|
+
* @param user_ids - Array of user IDs to retrieve profiles for
|
|
28
|
+
* @returns GetProfilesResult with found profiles and list of not found IDs
|
|
29
|
+
*/
|
|
30
|
+
export declare function hazo_get_user_profiles(adapter: HazoConnectAdapter, user_ids: string[]): Promise<GetProfilesResult>;
|
|
31
|
+
//# sourceMappingURL=user_profiles_service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"user_profiles_service.d.ts","sourceRoot":"","sources":["../../../src/lib/services/user_profiles_service.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAOvD;;;GAGG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,mBAAmB,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,kBAAkB,EAAE,MAAM,CAAC;CAC5B,CAAC;AAEF;;;GAGG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,eAAe,EAAE,CAAC;IAC5B,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAGF;;;;;;GAMG;AACH,wBAAsB,sBAAsB,CAC1C,OAAO,EAAE,kBAAkB,EAC3B,QAAQ,EAAE,MAAM,EAAE,GACjB,OAAO,CAAC,iBAAiB,CAAC,CAkG5B"}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { createCrudService } from "hazo_connect/server";
|
|
2
|
+
import { differenceInDays } from "date-fns";
|
|
3
|
+
import { create_app_logger } from "hazo_auth/lib/app_logger";
|
|
4
|
+
import { sanitize_error_for_user } from "hazo_auth/lib/utils/error_sanitizer";
|
|
5
|
+
// section: helpers
|
|
6
|
+
/**
|
|
7
|
+
* Retrieves basic profile information for multiple users in a single batch call
|
|
8
|
+
* Useful for chat applications and similar use cases where basic user info is needed
|
|
9
|
+
* @param adapter - The hazo_connect adapter instance
|
|
10
|
+
* @param user_ids - Array of user IDs to retrieve profiles for
|
|
11
|
+
* @returns GetProfilesResult with found profiles and list of not found IDs
|
|
12
|
+
*/
|
|
13
|
+
export async function hazo_get_user_profiles(adapter, user_ids) {
|
|
14
|
+
const logger = create_app_logger();
|
|
15
|
+
try {
|
|
16
|
+
// Handle empty input
|
|
17
|
+
if (!user_ids || user_ids.length === 0) {
|
|
18
|
+
return {
|
|
19
|
+
success: true,
|
|
20
|
+
profiles: [],
|
|
21
|
+
not_found_ids: [],
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
// Remove duplicates from input
|
|
25
|
+
const unique_user_ids = [...new Set(user_ids)];
|
|
26
|
+
// Create CRUD service for hazo_users table
|
|
27
|
+
const users_service = createCrudService(adapter, "hazo_users");
|
|
28
|
+
// Query users by IDs using the 'in' filter
|
|
29
|
+
// PostgREST supports 'in' filter syntax: id=in.(id1,id2,id3)
|
|
30
|
+
const users = await users_service.findBy({
|
|
31
|
+
id: `in.(${unique_user_ids.join(",")})`,
|
|
32
|
+
});
|
|
33
|
+
// Handle case where no users are found
|
|
34
|
+
if (!Array.isArray(users)) {
|
|
35
|
+
logger.warn("hazo_get_user_profiles_unexpected_response", {
|
|
36
|
+
filename: "user_profiles_service.ts",
|
|
37
|
+
line_number: 70,
|
|
38
|
+
message: "Unexpected response format from database query",
|
|
39
|
+
user_ids: unique_user_ids,
|
|
40
|
+
});
|
|
41
|
+
return {
|
|
42
|
+
success: true,
|
|
43
|
+
profiles: [],
|
|
44
|
+
not_found_ids: unique_user_ids,
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
// Build set of found user IDs for quick lookup
|
|
48
|
+
const found_user_ids = new Set(users.map((user) => user.id));
|
|
49
|
+
// Determine which user IDs were not found
|
|
50
|
+
const not_found_ids = unique_user_ids.filter((id) => !found_user_ids.has(id));
|
|
51
|
+
// Transform database records to UserProfileInfo
|
|
52
|
+
const now = new Date();
|
|
53
|
+
const profiles = users.map((user) => {
|
|
54
|
+
const created_at = user.created_at;
|
|
55
|
+
const created_date = new Date(created_at);
|
|
56
|
+
const days_since_created = differenceInDays(now, created_date);
|
|
57
|
+
return {
|
|
58
|
+
user_id: user.id,
|
|
59
|
+
profile_picture_url: user.profile_picture_url || null,
|
|
60
|
+
email: user.email_address,
|
|
61
|
+
name: user.name || null,
|
|
62
|
+
days_since_created,
|
|
63
|
+
};
|
|
64
|
+
});
|
|
65
|
+
// Log successful retrieval
|
|
66
|
+
logger.info("hazo_get_user_profiles_success", {
|
|
67
|
+
filename: "user_profiles_service.ts",
|
|
68
|
+
line_number: 105,
|
|
69
|
+
message: "Successfully retrieved user profiles",
|
|
70
|
+
requested_count: unique_user_ids.length,
|
|
71
|
+
found_count: profiles.length,
|
|
72
|
+
not_found_count: not_found_ids.length,
|
|
73
|
+
});
|
|
74
|
+
return {
|
|
75
|
+
success: true,
|
|
76
|
+
profiles,
|
|
77
|
+
not_found_ids,
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
catch (error) {
|
|
81
|
+
const user_friendly_error = sanitize_error_for_user(error, {
|
|
82
|
+
logToConsole: true,
|
|
83
|
+
logToLogger: true,
|
|
84
|
+
logger,
|
|
85
|
+
context: {
|
|
86
|
+
filename: "user_profiles_service.ts",
|
|
87
|
+
line_number: 122,
|
|
88
|
+
operation: "hazo_get_user_profiles",
|
|
89
|
+
user_ids_count: (user_ids === null || user_ids === void 0 ? void 0 : user_ids.length) || 0,
|
|
90
|
+
},
|
|
91
|
+
});
|
|
92
|
+
return {
|
|
93
|
+
success: false,
|
|
94
|
+
profiles: [],
|
|
95
|
+
not_found_ids: [],
|
|
96
|
+
error: user_friendly_error,
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { HazoConnectAdapter } from "hazo_connect";
|
|
2
|
+
import { type ProfilePictureSourceUI } from "hazo_auth/lib/services/profile_picture_source_mapper";
|
|
3
|
+
export type UserUpdateData = {
|
|
4
|
+
name?: string;
|
|
5
|
+
email?: string;
|
|
6
|
+
profile_picture_url?: string;
|
|
7
|
+
profile_source?: ProfilePictureSourceUI;
|
|
8
|
+
};
|
|
9
|
+
export type UserUpdateResult = {
|
|
10
|
+
success: boolean;
|
|
11
|
+
email_changed?: boolean;
|
|
12
|
+
error?: string;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Updates user profile information (name, email)
|
|
16
|
+
* If email is changed, sets email_verified to false
|
|
17
|
+
* @param adapter - The hazo_connect adapter instance
|
|
18
|
+
* @param user_id - The user ID to update
|
|
19
|
+
* @param data - User update data (name, email)
|
|
20
|
+
* @returns User update result with success status, email_changed flag, or error
|
|
21
|
+
*/
|
|
22
|
+
export declare function update_user_profile(adapter: HazoConnectAdapter, user_id: string, data: UserUpdateData): Promise<UserUpdateResult>;
|
|
23
|
+
//# sourceMappingURL=user_update_service.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"user_update_service.d.ts","sourceRoot":"","sources":["../../../src/lib/services/user_update_service.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,OAAO,EAAuB,KAAK,sBAAsB,EAAE,MAAM,sDAAsD,CAAC;AAMxH,MAAM,MAAM,cAAc,GAAG;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,cAAc,CAAC,EAAE,sBAAsB,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAGF;;;;;;;GAOG;AACH,wBAAsB,mBAAmB,CACvC,OAAO,EAAE,kBAAkB,EAC3B,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,cAAc,GACnB,OAAO,CAAC,gBAAgB,CAAC,CAuG3B"}
|