@sankhyalabs/core-docs 0.0.0-feat-dev-KB-69322.2 → 0.0.0-feat-dev-KB-97809.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/classes/LangUtils.md +130 -0
- package/globals.md +1 -0
- package/package.json +1 -1
@@ -0,0 +1,130 @@
|
|
1
|
+
[**@sankhyalabs/core**](../README.md) • **Docs**
|
2
|
+
|
3
|
+
***
|
4
|
+
|
5
|
+
[@sankhyalabs/core](../globals.md) / LangUtils
|
6
|
+
|
7
|
+
# Class: LangUtils
|
8
|
+
|
9
|
+
## Constructors
|
10
|
+
|
11
|
+
### new LangUtils()
|
12
|
+
|
13
|
+
> **new LangUtils**(): [`LangUtils`](LangUtils.md)
|
14
|
+
|
15
|
+
#### Returns
|
16
|
+
|
17
|
+
[`LangUtils`](LangUtils.md)
|
18
|
+
|
19
|
+
## Properties
|
20
|
+
|
21
|
+
### ELanguages
|
22
|
+
|
23
|
+
> `static` **ELanguages**: *typeof* `__class`
|
24
|
+
|
25
|
+
#### Source
|
26
|
+
|
27
|
+
src/utils/LangUtils.ts:2
|
28
|
+
|
29
|
+
## Methods
|
30
|
+
|
31
|
+
### applyLanguageFromCookie()
|
32
|
+
|
33
|
+
> `static` **applyLanguageFromCookie**(): `void`
|
34
|
+
|
35
|
+
Define o atributo lang no <html> com base no cookie, se existir
|
36
|
+
|
37
|
+
#### Returns
|
38
|
+
|
39
|
+
`void`
|
40
|
+
|
41
|
+
#### Source
|
42
|
+
|
43
|
+
src/utils/LangUtils.ts:69
|
44
|
+
|
45
|
+
***
|
46
|
+
|
47
|
+
### convertLanguage()
|
48
|
+
|
49
|
+
> `static` `private` **convertLanguage**(`lang`): `string`
|
50
|
+
|
51
|
+
#### Parameters
|
52
|
+
|
53
|
+
• **lang**: `string`
|
54
|
+
|
55
|
+
#### Returns
|
56
|
+
|
57
|
+
`string`
|
58
|
+
|
59
|
+
#### Source
|
60
|
+
|
61
|
+
src/utils/LangUtils.ts:8
|
62
|
+
|
63
|
+
***
|
64
|
+
|
65
|
+
### getHtmlLanguage()
|
66
|
+
|
67
|
+
> `static` **getHtmlLanguage**(): `string`
|
68
|
+
|
69
|
+
Captura o valor do atributo lang do elemento <html>
|
70
|
+
|
71
|
+
#### Returns
|
72
|
+
|
73
|
+
`string`
|
74
|
+
|
75
|
+
#### Source
|
76
|
+
|
77
|
+
src/utils/LangUtils.ts:39
|
78
|
+
|
79
|
+
***
|
80
|
+
|
81
|
+
### getLanguage()
|
82
|
+
|
83
|
+
> `static` **getLanguage**(): `string`
|
84
|
+
|
85
|
+
Captura a lingua definida.
|
86
|
+
|
87
|
+
#### Returns
|
88
|
+
|
89
|
+
`string`
|
90
|
+
|
91
|
+
#### Source
|
92
|
+
|
93
|
+
src/utils/LangUtils.ts:26
|
94
|
+
|
95
|
+
***
|
96
|
+
|
97
|
+
### getLanguageFromCookie()
|
98
|
+
|
99
|
+
> `static` **getLanguageFromCookie**(): `null` \| `string`
|
100
|
+
|
101
|
+
Recupera o valor do cookie de linguagem
|
102
|
+
|
103
|
+
#### Returns
|
104
|
+
|
105
|
+
`null` \| `string`
|
106
|
+
|
107
|
+
#### Source
|
108
|
+
|
109
|
+
src/utils/LangUtils.ts:61
|
110
|
+
|
111
|
+
***
|
112
|
+
|
113
|
+
### setHtmlLanguage()
|
114
|
+
|
115
|
+
> `static` **setHtmlLanguage**(`language`): `void`
|
116
|
+
|
117
|
+
Altera o valor do atributo lang no elemento <html>
|
118
|
+
e atualiza o cookie de linguagem
|
119
|
+
|
120
|
+
#### Parameters
|
121
|
+
|
122
|
+
• **language**: `string`
|
123
|
+
|
124
|
+
#### Returns
|
125
|
+
|
126
|
+
`void`
|
127
|
+
|
128
|
+
#### Source
|
129
|
+
|
130
|
+
src/utils/LangUtils.ts:53
|
package/globals.md
CHANGED
@@ -46,6 +46,7 @@
|
|
46
46
|
- [IDBRepository](classes/IDBRepository.md)
|
47
47
|
- [JSUtils](classes/JSUtils.md)
|
48
48
|
- [KeyboardManager](classes/KeyboardManager.md)
|
49
|
+
- [LangUtils](classes/LangUtils.md)
|
49
50
|
- [LockManager](classes/LockManager.md)
|
50
51
|
- [MaskFormatter](classes/MaskFormatter.md)
|
51
52
|
- [NumberUtils](classes/NumberUtils.md)
|