@navservice/usuario 1.31.0 → 1.32.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/lib/biblioteca/src/componentes/auth/AuthAtivarDesativarAuthenticator/AuthAtivarDesativarAuthenticator.d.ts +2 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthAtivarDesativarAuthenticator/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthGoogle/AuthGoogle.d.ts +5 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthGoogle/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthLogin/AuthLogin.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthLogin/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthRegister/AuthRegister.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/AuthRegister/index.d.ts +2 -0
- package/build/lib/biblioteca/src/componentes/auth/EnviarCodigoOtpParaEmail/EnviarCodigoOtpParaEmail.d.ts +12 -0
- package/build/lib/biblioteca/src/componentes/auth/EnviarCodigoOtpParaEmail/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/EsqueciMinhaSenha/EsqueciMinhaSenha.d.ts +5 -0
- package/build/lib/biblioteca/src/componentes/auth/EsqueciMinhaSenha/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/RecuperarSenhaComCodigoOtp/RecuperarSenhaComCodigoOtp.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/RecuperarSenhaComCodigoOtp/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/auth/VerificarAuthenticator/VerificarAuthenticator.d.ts +2 -0
- package/build/lib/biblioteca/src/componentes/auth/VerificarAuthenticator/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/drawer/DraweFullScreen/DraweFullScreen.d.ts +12 -0
- package/build/lib/biblioteca/src/componentes/drawer/DraweFullScreen/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/drawer/DrawerPadrao/DrawerPadrao.d.ts +12 -0
- package/build/lib/biblioteca/src/componentes/drawer/DrawerPadrao/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/geral/FormularioZod/index.d.ts +45 -0
- package/build/lib/biblioteca/src/componentes/geral/PaginaEmDesenvolvimento/index.d.ts +5 -0
- package/build/lib/biblioteca/src/componentes/geral/TopTabs/index.d.ts +10 -0
- package/build/lib/biblioteca/src/componentes/layout/Layout.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/layout/NavBar/DarkMode.d.ts +2 -0
- package/build/lib/biblioteca/src/componentes/layout/NavBar/Logo.d.ts +2 -0
- package/build/lib/biblioteca/src/componentes/layout/NavBar/Profile.d.ts +5 -0
- package/build/lib/biblioteca/src/componentes/layout/NavBar/index.d.ts +3 -0
- package/build/lib/biblioteca/src/componentes/layout/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/layoutPublic/Header.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/layoutPublic/index.d.ts +1 -0
- package/build/lib/biblioteca/src/componentes/layoutPublic/layoutPublic.d.ts +1 -0
- package/build/lib/biblioteca/src/config_env/index.d.ts +16 -0
- package/build/lib/biblioteca/src/contexto/contexto_codigo_otp.d.ts +19 -0
- package/build/lib/biblioteca/src/contexto/contexto_layout.d.ts +74 -0
- package/build/lib/biblioteca/src/contexto/contexto_usuario.d.ts +32 -0
- package/build/lib/biblioteca/src/index.d.ts +15 -0
- package/build/lib/index.js +38894 -0
- package/build/lib/shared/configuracoes/_sistema.d.ts +49 -0
- package/build/lib/shared/configuracoes/_theme.d.ts +91 -0
- package/build/lib/shared/configuracoes/index.d.ts +142 -0
- package/build/lib/shared/types/controller/type_codigo_verificacao_otp.d.ts +87 -0
- package/build/lib/shared/types/controller/type_controller_authenticator.d.ts +88 -0
- package/build/lib/shared/types/controller/type_controller_usuario.d.ts +261 -0
- package/build/lib/shared/types/geral/type_response.d.ts +54 -0
- package/build/lib/shared/types/index.d.ts +45 -0
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AuthAtivarDesativarAuthenticator, AuthAtivarDesativarAuthenticatorButton } from "./AuthAtivarDesativarAuthenticator";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AuthGoogle } from "./AuthGoogle";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function AuthLogin(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AuthLogin } from "./AuthLogin";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function AuthRegister(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
type Props = {
|
|
2
|
+
email: string;
|
|
3
|
+
erroExterno?: string | null;
|
|
4
|
+
onConfirmarCodigo?: (codigo: string) => void;
|
|
5
|
+
title?: string;
|
|
6
|
+
color?: "error" | "primary";
|
|
7
|
+
};
|
|
8
|
+
export type EnviarCodigoOtpEmailRef = {
|
|
9
|
+
reset: () => void;
|
|
10
|
+
};
|
|
11
|
+
export declare const EnviarCodigoOtpEmail: import("react").ForwardRefExoticComponent<Props & import("react").RefAttributes<EnviarCodigoOtpEmailRef>>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { EnviarCodigoOtpEmail, EnviarCodigoOtpEmailRef } from "./EnviarCodigoOtpParaEmail";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { EsqueciMinhaSenha } from "./EsqueciMinhaSenha";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function RecuperarSenhaComCodigoOtpButton(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { RecuperarSenhaComCodigoOtpButton } from "./RecuperarSenhaComCodigoOtp";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { VerificarAuthenticator } from "./VerificarAuthenticator";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
type DrawerFullScreenProps = {
|
|
3
|
+
title?: ReactNode;
|
|
4
|
+
children?: ReactNode;
|
|
5
|
+
onClose?: () => void;
|
|
6
|
+
};
|
|
7
|
+
export type TypeDrawerFullScreenRef = {
|
|
8
|
+
abrir: () => void;
|
|
9
|
+
fechar: () => void;
|
|
10
|
+
};
|
|
11
|
+
export declare const DrawerFullScreen: import("react").ForwardRefExoticComponent<DrawerFullScreenProps & import("react").RefAttributes<TypeDrawerFullScreenRef>>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { DrawerFullScreen, TypeDrawerFullScreenRef } from "./DraweFullScreen";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
type DrawerPadraoProps = {
|
|
3
|
+
title?: ReactNode;
|
|
4
|
+
children?: ReactNode;
|
|
5
|
+
onClose?: () => void;
|
|
6
|
+
};
|
|
7
|
+
export type TypeDrawerPadraoRef = {
|
|
8
|
+
abrir: () => void;
|
|
9
|
+
fechar: () => void;
|
|
10
|
+
};
|
|
11
|
+
export declare const DrawerPadrao: import("react").ForwardRefExoticComponent<DrawerPadraoProps & import("react").RefAttributes<TypeDrawerPadraoRef>>;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TypeDrawerPadraoRef, DrawerPadrao } from "./DrawerPadrao";
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { z, ZodObject } from "zod/v4";
|
|
3
|
+
/**
|
|
4
|
+
* =============================================================
|
|
5
|
+
* Utils de TIPAGEM – dot paths e valores inferidos do schema
|
|
6
|
+
* =============================================================
|
|
7
|
+
*/
|
|
8
|
+
type Primitive = string | number | boolean | bigint | symbol | null | undefined | Date | File;
|
|
9
|
+
type Join<K, P> = K extends string | number ? (P extends string | number ? `${K}.${P}` : never) : never;
|
|
10
|
+
type Prev = [never, 0, 1, 2, 3, 4, 5, 6, 7, 8];
|
|
11
|
+
export type DotPath<T, D extends number = 6> = [D] extends [never] ? never : T extends Primitive ? never : T extends readonly (infer A)[] ? DotPath<A, Prev[D]> : {
|
|
12
|
+
[K in keyof T & (string | number)]: T[K] extends Primitive | readonly any[] ? `${K}` : `${K}` | Join<K, DotPath<T[K], Prev[D]>>;
|
|
13
|
+
}[keyof T & (string | number)];
|
|
14
|
+
export type PathValue<T, P extends string> = P extends `${infer K}.${infer R}` ? (K extends keyof T ? PathValue<T[K], R> : never) : P extends keyof T ? T[P] : never;
|
|
15
|
+
export type FlatPaths<T> = {
|
|
16
|
+
[P in DotPath<T>]: PathValue<T, P>;
|
|
17
|
+
};
|
|
18
|
+
type InferSchema<TSchema extends z.ZodTypeAny> = z.infer<TSchema>;
|
|
19
|
+
export type DotPathOfSchema<TSchema extends z.ZodTypeAny> = DotPath<InferSchema<TSchema>>;
|
|
20
|
+
export type FlatPathsOfSchema<TSchema extends z.ZodTypeAny> = FlatPaths<InferSchema<TSchema>>;
|
|
21
|
+
/**
|
|
22
|
+
* =============================================================
|
|
23
|
+
* TIPAGEM do Ref exposto pelo componente
|
|
24
|
+
* =============================================================
|
|
25
|
+
*/
|
|
26
|
+
export interface FormularioZodRef<TSchema extends z.ZodTypeAny> {
|
|
27
|
+
enviarFormulario: () => InferSchema<TSchema> | null;
|
|
28
|
+
limparFormulario: () => void;
|
|
29
|
+
getValues: () => Partial<FlatPathsOfSchema<TSchema>>;
|
|
30
|
+
setValue: <P extends DotPathOfSchema<TSchema>>(path: P, value: PathValue<InferSchema<TSchema>, P>) => void;
|
|
31
|
+
getValue: <P extends DotPathOfSchema<TSchema>>(path: P) => PathValue<InferSchema<TSchema>, P> | undefined;
|
|
32
|
+
}
|
|
33
|
+
interface FormularioZodProps<TSchema extends ZodObject<any>> {
|
|
34
|
+
schema: TSchema;
|
|
35
|
+
devMode?: boolean;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* =============================================================
|
|
39
|
+
* forwardRef preservando genéricos
|
|
40
|
+
* =============================================================
|
|
41
|
+
*/
|
|
42
|
+
declare const FormularioZod: <TSchema extends ZodObject<any>>(props: FormularioZodProps<TSchema> & {
|
|
43
|
+
ref?: React.Ref<FormularioZodRef<TSchema>>;
|
|
44
|
+
}) => React.ReactElement;
|
|
45
|
+
export default FormularioZod;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React, { ReactNode } from "react";
|
|
2
|
+
type TabItem = {
|
|
3
|
+
title: string;
|
|
4
|
+
content: ReactNode;
|
|
5
|
+
};
|
|
6
|
+
type TopTabNavigationProps = {
|
|
7
|
+
tabs: TabItem[];
|
|
8
|
+
};
|
|
9
|
+
declare const TopTabNavigation: React.FC<TopTabNavigationProps>;
|
|
10
|
+
export default TopTabNavigation;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function Layout(): React.JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Layout } from "./Layout";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function Header(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { LayoutPublic } from "./layoutPublic";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function LayoutPublic(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import t from "../../../shared/types";
|
|
2
|
+
interface TypesConfigEnv {
|
|
3
|
+
SET_PUBLIC_GOOGLE_CLIENT_ID_AUTH0: string;
|
|
4
|
+
SET_APP: t.Controller.Usuario.UsuarioAuth["app"];
|
|
5
|
+
SET_USUARIO_TIPO: t.Controller.Usuario.UsuarioAuth["usuario_tipo"];
|
|
6
|
+
}
|
|
7
|
+
declare class config_env {
|
|
8
|
+
private static SET_PUBLIC_GOOGLE_CLIENT_ID_AUTH0;
|
|
9
|
+
private static SET_APP;
|
|
10
|
+
private static SET_USUARIO_TIPO;
|
|
11
|
+
static init(config: TypesConfigEnv): void;
|
|
12
|
+
static get PUBLIC_GOOGLE_CLIENT_ID_AUTH0(): string;
|
|
13
|
+
static get PUBLIC_APP(): t.Controller.Usuario.UsuarioAuth["app"];
|
|
14
|
+
static get PUBLIC_USUARIO_TIPO(): t.Controller.Usuario.UsuarioAuth["usuario_tipo"];
|
|
15
|
+
}
|
|
16
|
+
export default config_env;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { AxiosResponse } from "axios";
|
|
2
|
+
import t from "../../../shared/types";
|
|
3
|
+
interface ZustandStore {
|
|
4
|
+
states: {
|
|
5
|
+
recuperar_senha_pelo_app_com_codigo_otp: {
|
|
6
|
+
loading: boolean;
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
declare class contexto_codigo_otp {
|
|
11
|
+
api: {
|
|
12
|
+
recuperar_senha_pelo_app_com_codigo_otp: (props: t.Controller.CodigoOtp.RecuperarSenhaPeloAppComCodigoOtp.Input) => Promise<AxiosResponse<any, any, {}>>;
|
|
13
|
+
};
|
|
14
|
+
get get_jsx(): ZustandStore['states'];
|
|
15
|
+
get get_state(): ZustandStore['states'];
|
|
16
|
+
set_state: (updater: (state: ZustandStore["states"]) => void) => void;
|
|
17
|
+
}
|
|
18
|
+
declare const _default: contexto_codigo_otp;
|
|
19
|
+
export default _default;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
interface NotificacaoNovoRecurso {
|
|
2
|
+
idItem: number;
|
|
3
|
+
contador: number;
|
|
4
|
+
expiraEmDias?: number;
|
|
5
|
+
dataCriacao: Date;
|
|
6
|
+
lido: boolean;
|
|
7
|
+
}
|
|
8
|
+
interface NavbarItem {
|
|
9
|
+
id: number;
|
|
10
|
+
title: string;
|
|
11
|
+
icon?: any;
|
|
12
|
+
href?: string;
|
|
13
|
+
collapsible?: boolean;
|
|
14
|
+
children?: NavbarItem[];
|
|
15
|
+
subheader?: string;
|
|
16
|
+
disabled?: boolean;
|
|
17
|
+
badge?: {
|
|
18
|
+
color: string;
|
|
19
|
+
value: string | number;
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
declare class contexto_layout {
|
|
23
|
+
static contexto: {
|
|
24
|
+
new (): {};
|
|
25
|
+
jsx: {
|
|
26
|
+
new (): {};
|
|
27
|
+
get_navbar(): {
|
|
28
|
+
data: NavbarItem[];
|
|
29
|
+
loading: boolean;
|
|
30
|
+
_ids: any[];
|
|
31
|
+
};
|
|
32
|
+
get_expanded_item(): {
|
|
33
|
+
data: number | null;
|
|
34
|
+
loading: boolean;
|
|
35
|
+
};
|
|
36
|
+
get_mobile_open(): {
|
|
37
|
+
data: boolean;
|
|
38
|
+
loading: boolean;
|
|
39
|
+
};
|
|
40
|
+
get_novos_recursos(): {
|
|
41
|
+
data: NotificacaoNovoRecurso[];
|
|
42
|
+
loading: boolean;
|
|
43
|
+
};
|
|
44
|
+
get_recurso_novo_item(idItem: number): NotificacaoNovoRecurso | undefined;
|
|
45
|
+
};
|
|
46
|
+
state: {
|
|
47
|
+
new (): {};
|
|
48
|
+
set_navbar(values: {
|
|
49
|
+
data: NavbarItem[];
|
|
50
|
+
loading: boolean;
|
|
51
|
+
}): void;
|
|
52
|
+
get_navbar(): {
|
|
53
|
+
data: NavbarItem[];
|
|
54
|
+
loading: boolean;
|
|
55
|
+
_ids: any[];
|
|
56
|
+
};
|
|
57
|
+
set_expanded_item(id: number | null): void;
|
|
58
|
+
get_expanded_item(): {
|
|
59
|
+
data: number | null;
|
|
60
|
+
loading: boolean;
|
|
61
|
+
};
|
|
62
|
+
toggle_mobile_open(): void;
|
|
63
|
+
set_mobile_open(isOpen: boolean): void;
|
|
64
|
+
marcar_recurso_como_lido(idItem: number): void;
|
|
65
|
+
limpar_todos_recursos(): void;
|
|
66
|
+
limpar_recursos_expirados(): void;
|
|
67
|
+
adicionar_novos_recursos(recursos: NotificacaoNovoRecurso[]): void;
|
|
68
|
+
};
|
|
69
|
+
};
|
|
70
|
+
static websocket: {
|
|
71
|
+
new (): {};
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
export default contexto_layout;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { AxiosResponse } from "axios";
|
|
2
|
+
import t from "../../../shared/types";
|
|
3
|
+
declare const contexto_usuario: {
|
|
4
|
+
new (): {};
|
|
5
|
+
api: {
|
|
6
|
+
new (): {};
|
|
7
|
+
register(props: t.Controller.Usuario.Register.Input): Promise<t.Controller.Usuario.Register.Response>;
|
|
8
|
+
login(props: t.Controller.Usuario.Login.Input): Promise<AxiosResponse>;
|
|
9
|
+
entrar_com_codigo_otp(props: t.Controller.CodigoOtp.EntrarComCodigoOtp.Input): Promise<t.Controller.CodigoOtp.EntrarComCodigoOtp.Response>;
|
|
10
|
+
login_register_google(props: t.Controller.Usuario.RegisterLoginGoogle.Input): Promise<AxiosResponse<any, any, {}>>;
|
|
11
|
+
};
|
|
12
|
+
contexto: {
|
|
13
|
+
new (): {};
|
|
14
|
+
jsx: {
|
|
15
|
+
new (): {};
|
|
16
|
+
get_user(): t.Controller.Usuario.Login.Output;
|
|
17
|
+
get_signed(): boolean;
|
|
18
|
+
get_loading(): boolean;
|
|
19
|
+
};
|
|
20
|
+
state: {
|
|
21
|
+
new (): {};
|
|
22
|
+
set_signed(): void;
|
|
23
|
+
set_user(userData: t.Controller.Usuario.Login.Output | null): void;
|
|
24
|
+
set_loading(value: boolean): void;
|
|
25
|
+
set_signout(): void;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
websocket: {
|
|
29
|
+
new (): {};
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
export default contexto_usuario;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export { default as config_env_usuario } from "./config_env";
|
|
2
|
+
export { default as contexto_usuario } from "./contexto/contexto_usuario";
|
|
3
|
+
export { default as contexto_layout } from "./contexto/contexto_layout";
|
|
4
|
+
export { AuthAtivarDesativarAuthenticatorButton } from "./componentes/auth/AuthAtivarDesativarAuthenticator";
|
|
5
|
+
export { RecuperarSenhaComCodigoOtpButton } from "./componentes/auth/RecuperarSenhaComCodigoOtp";
|
|
6
|
+
export { EsqueciMinhaSenha } from "./componentes/auth/EsqueciMinhaSenha";
|
|
7
|
+
export { AuthGoogle } from "./componentes/auth/AuthGoogle";
|
|
8
|
+
export { AuthLogin } from "./componentes/auth/AuthLogin";
|
|
9
|
+
export { AuthRegister } from "./componentes/auth/AuthRegister";
|
|
10
|
+
export { VerificarAuthenticator } from "./componentes/auth/VerificarAuthenticator";
|
|
11
|
+
export { DrawerFullScreen, TypeDrawerFullScreenRef } from "./componentes/drawer/DraweFullScreen";
|
|
12
|
+
export { DrawerPadrao, TypeDrawerPadraoRef } from "./componentes/drawer/DrawerPadrao";
|
|
13
|
+
export { Layout } from "./componentes/layout";
|
|
14
|
+
export { LayoutPublic } from "./componentes/layoutPublic";
|
|
15
|
+
export { default as TypesUsuario } from "../../shared/types";
|