@navservice/core 1.29.0 → 1.30.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/config_env/index.d.ts +9 -0
- package/build/lib/helpers/_secret.d.ts +10 -0
- package/build/lib/helpers/_set_response.d.ts +84 -0
- package/build/lib/helpers/_token.d.ts +16 -0
- package/build/lib/helpers/index.d.ts +157 -0
- package/build/lib/helpers.cjs +437 -0
- package/build/lib/index.browser.cjs +805 -0
- package/build/lib/index.browser.d.ts +3 -0
- package/build/lib/index.node.cjs +472 -0
- package/build/lib/index.node.d.ts +1 -0
- package/build/lib/types/_type_response.d.ts +54 -0
- package/build/lib/types/_usuario.d.ts +39 -0
- package/build/lib/types/index.d.ts +20 -0
- package/build/lib/utils/_api.d.ts +41 -0
- package/build/lib/utils/_data.d.ts +11 -0
- package/build/lib/utils/_form.d.ts +11 -0
- package/build/lib/utils/_geral.d.ts +9 -0
- package/build/lib/utils/_local_storage.d.ts +8 -0
- package/build/lib/utils/_session_storage.d.ts +14 -0
- package/build/lib/utils/_update_context.d.ts +21 -0
- package/build/lib/utils/index.d.ts +105 -0
- package/build/lib/utils.cjs +660 -0
- package/package.json +1 -1
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
declare const _session_storage: {
|
|
2
|
+
new (): {};
|
|
3
|
+
adicionar_item_session_storage({ chave, novoItem }: {
|
|
4
|
+
chave: string;
|
|
5
|
+
novoItem: any;
|
|
6
|
+
}): void;
|
|
7
|
+
set_session_storage_sem_incremento({ chave, novoItem }: {
|
|
8
|
+
chave: string;
|
|
9
|
+
novoItem: any;
|
|
10
|
+
}): void;
|
|
11
|
+
get_item_session_storage(chave: string): any;
|
|
12
|
+
remover_item_session_storage(chave: string): void;
|
|
13
|
+
};
|
|
14
|
+
export default _session_storage;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
type ParamsPadrao = {
|
|
2
|
+
oldArray: any[];
|
|
3
|
+
newItem: any;
|
|
4
|
+
key?: string | "_id" | "id";
|
|
5
|
+
};
|
|
6
|
+
type RemoveArrayItems = {
|
|
7
|
+
oldArray: any[];
|
|
8
|
+
itemsToRemove: any[];
|
|
9
|
+
key?: string | "_id" | "id";
|
|
10
|
+
};
|
|
11
|
+
declare const _update_context: {
|
|
12
|
+
new (): {};
|
|
13
|
+
set_new_item_end: ({ oldArray, newItem, key }: ParamsPadrao) => any;
|
|
14
|
+
update_array_itens: ({ oldArray, newItem, key }: ParamsPadrao) => any;
|
|
15
|
+
remove_array_items: ({ oldArray, itemsToRemove, key }: RemoveArrayItems) => any[];
|
|
16
|
+
compare_arrays({ arrayAntigo, arrayNovo }: {
|
|
17
|
+
arrayAntigo: any;
|
|
18
|
+
arrayNovo: any;
|
|
19
|
+
}): any[];
|
|
20
|
+
};
|
|
21
|
+
export default _update_context;
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import _form from "./_form";
|
|
2
|
+
declare const utils: {
|
|
3
|
+
new (): {};
|
|
4
|
+
api: {
|
|
5
|
+
new (): {};
|
|
6
|
+
servidor_service_usuario: {
|
|
7
|
+
new (): {};
|
|
8
|
+
get "__#private@#axios"(): import("axios").AxiosInstance;
|
|
9
|
+
post({ url, data, setToken }: {
|
|
10
|
+
url: string;
|
|
11
|
+
data: any;
|
|
12
|
+
setToken?: boolean;
|
|
13
|
+
}): Promise<import("axios").AxiosResponse<any, any, {}>>;
|
|
14
|
+
get({ url, params, setToken }: {
|
|
15
|
+
url: string;
|
|
16
|
+
params?: any;
|
|
17
|
+
setToken?: boolean;
|
|
18
|
+
}): Promise<import("axios").AxiosResponse<any, any, {}>>;
|
|
19
|
+
patch({ url, data, setToken }: {
|
|
20
|
+
url: string;
|
|
21
|
+
data: any;
|
|
22
|
+
setToken?: boolean;
|
|
23
|
+
}): Promise<import("axios").AxiosResponse<any, any, {}>>;
|
|
24
|
+
delete({ url }: {
|
|
25
|
+
url: string;
|
|
26
|
+
setToken?: boolean;
|
|
27
|
+
}): Promise<import("axios").AxiosResponse<any, any, {}>>;
|
|
28
|
+
};
|
|
29
|
+
headers({ setToken }: {
|
|
30
|
+
setToken?: boolean;
|
|
31
|
+
}): {
|
|
32
|
+
headers: {
|
|
33
|
+
Authorization: string;
|
|
34
|
+
"Content-type": string;
|
|
35
|
+
};
|
|
36
|
+
} | {
|
|
37
|
+
headers: {
|
|
38
|
+
"Content-type": string;
|
|
39
|
+
Authorization?: undefined;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
data: {
|
|
44
|
+
new (): {};
|
|
45
|
+
YYYY_MM_DD_00_00_00(newData: string): string;
|
|
46
|
+
DD_MM_YYYY_00_00_00(newData: string): string;
|
|
47
|
+
DD_MM_YYYY_00_00(newData: string): string;
|
|
48
|
+
DD_MM_YYYY(newData: string): string;
|
|
49
|
+
YYYY_MM_DD(newData: string): string;
|
|
50
|
+
DIFERENCA_SEGUNDOS(data: string): number;
|
|
51
|
+
DIFERENCA_DIAS(data: string): number;
|
|
52
|
+
};
|
|
53
|
+
form: typeof _form;
|
|
54
|
+
geral: {
|
|
55
|
+
new (): {};
|
|
56
|
+
slice_file_name(filename: string, maxLength?: number): string;
|
|
57
|
+
extrair_id(array_enviado: Array<{
|
|
58
|
+
_id?: string;
|
|
59
|
+
}>): string[];
|
|
60
|
+
gerar_id: (length?: number) => string;
|
|
61
|
+
};
|
|
62
|
+
local_storage: {
|
|
63
|
+
new (): {};
|
|
64
|
+
adicionar_item_local_storage(chave: string, novoItem: any): void;
|
|
65
|
+
set_local_storage_sem_incremento(chave: string, novoItem: any): void;
|
|
66
|
+
get_item_local_storage(chave: string): any;
|
|
67
|
+
remover_item_local_storage(chave: string): void;
|
|
68
|
+
};
|
|
69
|
+
update_context: {
|
|
70
|
+
new (): {};
|
|
71
|
+
set_new_item_end: ({ oldArray, newItem, key }: {
|
|
72
|
+
oldArray: any[];
|
|
73
|
+
newItem: any;
|
|
74
|
+
key?: string | "_id" | "id";
|
|
75
|
+
}) => any;
|
|
76
|
+
update_array_itens: ({ oldArray, newItem, key }: {
|
|
77
|
+
oldArray: any[];
|
|
78
|
+
newItem: any;
|
|
79
|
+
key?: string | "_id" | "id";
|
|
80
|
+
}) => any;
|
|
81
|
+
remove_array_items: ({ oldArray, itemsToRemove, key }: {
|
|
82
|
+
oldArray: any[];
|
|
83
|
+
itemsToRemove: any[];
|
|
84
|
+
key?: string | "_id" | "id";
|
|
85
|
+
}) => any[];
|
|
86
|
+
compare_arrays({ arrayAntigo, arrayNovo }: {
|
|
87
|
+
arrayAntigo: any;
|
|
88
|
+
arrayNovo: any;
|
|
89
|
+
}): any[];
|
|
90
|
+
};
|
|
91
|
+
session_sorage: {
|
|
92
|
+
new (): {};
|
|
93
|
+
adicionar_item_session_storage({ chave, novoItem }: {
|
|
94
|
+
chave: string;
|
|
95
|
+
novoItem: any;
|
|
96
|
+
}): void;
|
|
97
|
+
set_session_storage_sem_incremento({ chave, novoItem }: {
|
|
98
|
+
chave: string;
|
|
99
|
+
novoItem: any;
|
|
100
|
+
}): void;
|
|
101
|
+
get_item_session_storage(chave: string): any;
|
|
102
|
+
remover_item_session_storage(chave: string): void;
|
|
103
|
+
};
|
|
104
|
+
};
|
|
105
|
+
export default utils;
|