@candlerip/shared 0.0.67 → 0.0.69

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.
Files changed (184) hide show
  1. package/custom-error/domains.d.ts +2 -2
  2. package/dictionary/country-dictionary/domains.d.ts +4 -0
  3. package/dictionary/country-dictionary/index.d.ts +2 -0
  4. package/dictionary/country-dictionary/index.js +2 -0
  5. package/dictionary/country-dictionary/utils/convert-countries-to-dictionary/index.d.ts +2 -0
  6. package/dictionary/country-dictionary/utils/convert-countries-to-dictionary/index.js +4 -0
  7. package/dictionary/country-dictionary/utils/convert-countries-to-dictionary/type.d.ts +6 -0
  8. package/dictionary/country-dictionary/utils/index.d.ts +1 -0
  9. package/dictionary/country-dictionary/utils/index.js +1 -0
  10. package/dictionary/dictionary/configs.d.ts +47 -0
  11. package/dictionary/dictionary/configs.js +268 -0
  12. package/dictionary/dictionary/domains.d.ts +4 -0
  13. package/dictionary/dictionary/domains.js +1 -0
  14. package/dictionary/dictionary/index.d.ts +2 -0
  15. package/dictionary/dictionary/index.js +2 -0
  16. package/dictionary/index.d.ts +2 -0
  17. package/dictionary/index.js +2 -0
  18. package/environment/index.d.ts +0 -2
  19. package/environment/index.js +0 -2
  20. package/geographical/country/domains.d.ts +17 -0
  21. package/geographical/country/domains.js +1 -0
  22. package/geographical/county-code/configs.d.ts +1 -0
  23. package/geographical/county-code/configs.js +248 -0
  24. package/geographical/county-code/domains.d.ts +2 -0
  25. package/geographical/county-code/domains.js +1 -0
  26. package/{environment/environment-variable-name → geographical/county-code}/index.d.ts +1 -1
  27. package/{environment/environment-variable-name → geographical/county-code}/index.js +1 -1
  28. package/geographical/county-code/type-guards.d.ts +2 -0
  29. package/geographical/county-code/type-guards.js +4 -0
  30. package/geographical/index.d.ts +2 -0
  31. package/geographical/index.js +2 -0
  32. package/index.d.ts +6 -1
  33. package/index.js +6 -1
  34. package/package.json +1 -1
  35. package/page/configs.d.ts +1 -0
  36. package/page/configs.js +17 -0
  37. package/page/domains.d.ts +2 -0
  38. package/page/domains.js +1 -0
  39. package/page/index.d.ts +3 -0
  40. package/page/index.js +3 -0
  41. package/page/type-guards.d.ts +2 -0
  42. package/page/type-guards.js +4 -0
  43. package/page-menu/configs.d.ts +1 -0
  44. package/page-menu/configs.js +12 -0
  45. package/page-menu/domains.d.ts +2 -0
  46. package/page-menu/domains.js +1 -0
  47. package/page-menu/index.d.ts +3 -0
  48. package/page-menu/index.js +3 -0
  49. package/page-menu/type-guards.d.ts +2 -0
  50. package/page-menu/type-guards.js +2 -0
  51. package/service/service-name/constants.d.ts +1 -1
  52. package/service/service-name/constants.js +1 -1
  53. package/translation/index.d.ts +3 -0
  54. package/translation/index.js +3 -0
  55. package/translation/language/configs.d.ts +1 -0
  56. package/translation/language/configs.js +1 -0
  57. package/translation/language/defaults.d.ts +2 -0
  58. package/translation/language/defaults.js +1 -0
  59. package/translation/language/domains.d.ts +2 -0
  60. package/translation/language/domains.js +1 -0
  61. package/translation/language/index.d.ts +5 -0
  62. package/translation/language/index.js +5 -0
  63. package/translation/language/type-guards.d.ts +2 -0
  64. package/translation/language/type-guards.js +2 -0
  65. package/translation/language/validates/index.d.ts +2 -0
  66. package/translation/language/validates/index.js +2 -0
  67. package/translation/language/validates/validate-language/index.d.ts +2 -0
  68. package/translation/language/validates/validate-language/index.js +3 -0
  69. package/translation/language/validates/validate-language/type.d.ts +7 -0
  70. package/translation/language/validates/validate-language/type.js +1 -0
  71. package/translation/language/validates/validate-page/index.d.ts +2 -0
  72. package/translation/language/validates/validate-page/index.js +3 -0
  73. package/translation/language/validates/validate-page/type.d.ts +6 -0
  74. package/translation/language/validates/validate-page/type.js +1 -0
  75. package/translation/translation/domains/index.d.ts +7 -0
  76. package/translation/translation/domains/index.js +1 -0
  77. package/translation/translation/index.d.ts +1 -0
  78. package/translation/translation/index.js +1 -0
  79. package/translation/translation-code/excluded-translation-code/configs.d.ts +2 -0
  80. package/translation/translation-code/excluded-translation-code/configs.js +12 -0
  81. package/translation/translation-code/excluded-translation-code/domains.d.ts +4 -0
  82. package/translation/translation-code/excluded-translation-code/domains.js +1 -0
  83. package/translation/translation-code/excluded-translation-code/index.d.ts +2 -0
  84. package/translation/translation-code/excluded-translation-code/index.js +2 -0
  85. package/translation/translation-code/excluded-translation-code/utils/compose-excluded-translation-codes/index.d.ts +2 -0
  86. package/translation/translation-code/excluded-translation-code/utils/compose-excluded-translation-codes/index.js +20 -0
  87. package/translation/translation-code/excluded-translation-code/utils/compose-excluded-translation-codes/type.d.ts +7 -0
  88. package/translation/translation-code/excluded-translation-code/utils/compose-excluded-translation-codes/type.js +1 -0
  89. package/translation/translation-code/excluded-translation-code/utils/index.d.ts +2 -0
  90. package/translation/translation-code/excluded-translation-code/utils/index.js +2 -0
  91. package/translation/translation-code/index.d.ts +2 -0
  92. package/translation/translation-code/index.js +2 -0
  93. package/translation/translation-code/translation-code/candle/candle-card/config.d.ts +1 -0
  94. package/translation/translation-code/translation-code/candle/candle-card/config.js +10 -0
  95. package/translation/translation-code/translation-code/candle/candle-card/index.d.ts +1 -0
  96. package/translation/translation-code/translation-code/candle/candle-card/index.js +1 -0
  97. package/translation/translation-code/translation-code/candle/candle-cards/config.d.ts +1 -0
  98. package/translation/translation-code/translation-code/candle/candle-cards/config.js +4 -0
  99. package/translation/translation-code/translation-code/candle/candle-cards/index.d.ts +1 -0
  100. package/translation/translation-code/translation-code/candle/candle-cards/index.js +1 -0
  101. package/translation/translation-code/translation-code/candle/candle-image/config.d.ts +1 -0
  102. package/translation/translation-code/translation-code/candle/candle-image/config.js +3 -0
  103. package/translation/translation-code/translation-code/candle/candle-image/index.d.ts +1 -0
  104. package/translation/translation-code/translation-code/candle/candle-image/index.js +1 -0
  105. package/translation/translation-code/translation-code/candle/candle-maintenance/config.d.ts +1 -0
  106. package/translation/translation-code/translation-code/candle/candle-maintenance/config.js +10 -0
  107. package/translation/translation-code/translation-code/candle/candle-maintenance/index.d.ts +1 -0
  108. package/translation/translation-code/translation-code/candle/candle-maintenance/index.js +1 -0
  109. package/translation/translation-code/translation-code/candle/candles-list/config.d.ts +1 -0
  110. package/translation/translation-code/translation-code/candle/candles-list/config.js +19 -0
  111. package/translation/translation-code/translation-code/candle/candles-list/index.d.ts +1 -0
  112. package/translation/translation-code/translation-code/candle/candles-list/index.js +1 -0
  113. package/translation/translation-code/translation-code/candle/index.d.ts +5 -0
  114. package/translation/translation-code/translation-code/candle/index.js +5 -0
  115. package/translation/translation-code/translation-code/common-page/config.d.ts +1 -0
  116. package/translation/translation-code/translation-code/common-page/config.js +29 -0
  117. package/translation/translation-code/translation-code/common-page/index.d.ts +1 -0
  118. package/translation/translation-code/translation-code/common-page/index.js +1 -0
  119. package/translation/translation-code/translation-code/configs.d.ts +1 -0
  120. package/translation/translation-code/translation-code/configs.js +434 -0
  121. package/translation/translation-code/translation-code/country/country-code/config.d.ts +1 -0
  122. package/translation/translation-code/translation-code/country/country-code/config.js +250 -0
  123. package/translation/translation-code/translation-code/country/country-code/index.d.ts +1 -0
  124. package/translation/translation-code/translation-code/country/country-code/index.js +1 -0
  125. package/translation/translation-code/translation-code/country/index.d.ts +1 -0
  126. package/translation/translation-code/translation-code/country/index.js +1 -0
  127. package/translation/translation-code/translation-code/domains.d.ts +2 -0
  128. package/translation/translation-code/translation-code/domains.js +1 -0
  129. package/translation/translation-code/translation-code/index.d.ts +7 -0
  130. package/translation/translation-code/translation-code/index.js +7 -0
  131. package/translation/translation-code/translation-code/person/index.d.ts +5 -0
  132. package/translation/translation-code/translation-code/person/index.js +5 -0
  133. package/translation/translation-code/translation-code/person/person-card/config.d.ts +1 -0
  134. package/translation/translation-code/translation-code/person/person-card/config.js +4 -0
  135. package/translation/translation-code/translation-code/person/person-card/index.d.ts +1 -0
  136. package/translation/translation-code/translation-code/person/person-card/index.js +1 -0
  137. package/translation/translation-code/translation-code/person/person-cards/config.d.ts +1 -0
  138. package/translation/translation-code/translation-code/person/person-cards/config.js +4 -0
  139. package/translation/translation-code/translation-code/person/person-cards/index.d.ts +1 -0
  140. package/translation/translation-code/translation-code/person/person-cards/index.js +1 -0
  141. package/translation/translation-code/translation-code/person/person-image/config.d.ts +1 -0
  142. package/translation/translation-code/translation-code/person/person-image/config.js +3 -0
  143. package/translation/translation-code/translation-code/person/person-image/index.d.ts +1 -0
  144. package/translation/translation-code/translation-code/person/person-image/index.js +1 -0
  145. package/translation/translation-code/translation-code/person/person-maintenance/config.d.ts +1 -0
  146. package/translation/translation-code/translation-code/person/person-maintenance/config.js +28 -0
  147. package/translation/translation-code/translation-code/person/person-maintenance/index.d.ts +1 -0
  148. package/translation/translation-code/translation-code/person/person-maintenance/index.js +1 -0
  149. package/translation/translation-code/translation-code/person/persons-list/config.d.ts +1 -0
  150. package/translation/translation-code/translation-code/person/persons-list/config.js +19 -0
  151. package/translation/translation-code/translation-code/person/persons-list/index.d.ts +1 -0
  152. package/translation/translation-code/translation-code/person/persons-list/index.js +1 -0
  153. package/translation/translation-code/translation-code/time/index.d.ts +1 -0
  154. package/translation/translation-code/translation-code/time/index.js +1 -0
  155. package/translation/translation-code/translation-code/time/time-abbreviation/config.d.ts +1 -0
  156. package/translation/translation-code/translation-code/time/time-abbreviation/config.js +3 -0
  157. package/translation/translation-code/translation-code/time/time-abbreviation/index.d.ts +1 -0
  158. package/translation/translation-code/translation-code/time/time-abbreviation/index.js +1 -0
  159. package/type/index.d.ts +2 -0
  160. package/type/index.js +2 -0
  161. package/type/type/index.d.ts +2 -0
  162. package/type/type/index.js +2 -0
  163. package/type/type/type-guards.d.ts +1 -0
  164. package/type/type/type-guards.js +6 -0
  165. package/type/type/utils/index.d.ts +1 -0
  166. package/type/type/utils/index.js +1 -0
  167. package/type/type/utils/validate-by-values/index.d.ts +2 -0
  168. package/type/type/utils/validate-by-values/index.js +20 -0
  169. package/type/type/utils/validate-by-values/type.d.ts +6 -0
  170. package/type/type/utils/validate-by-values/type.js +1 -0
  171. package/type/undefined/index.d.ts +1 -0
  172. package/type/undefined/index.js +1 -0
  173. package/type/undefined/type-guard.d.ts +1 -0
  174. package/type/undefined/type-guard.js +1 -0
  175. package/environment/environment-variable-name/constants.d.ts +0 -2
  176. package/environment/environment-variable-name/constants.js +0 -23
  177. package/environment/environment-variable-name/domains.d.ts +0 -2
  178. package/environment/environment-variable-name/type-guards.d.ts +0 -2
  179. package/environment/environment-variable-name/type-guards.js +0 -2
  180. package/environment/environment-variables/domains.d.ts +0 -23
  181. /package/{environment/environment-variable-name → dictionary/country-dictionary}/domains.js +0 -0
  182. /package/{environment/environment-variables/domains.js → dictionary/country-dictionary/utils/convert-countries-to-dictionary/type.js} +0 -0
  183. /package/{environment/environment-variables → geographical/country}/index.d.ts +0 -0
  184. /package/{environment/environment-variables → geographical/country}/index.js +0 -0
@@ -0,0 +1,250 @@
1
+ export const COUNTRY_CODE_TRANSLATION_CODES = [
2
+ 'countryCode.AD',
3
+ 'countryCode.AE',
4
+ 'countryCode.AF',
5
+ 'countryCode.AG',
6
+ 'countryCode.AI',
7
+ 'countryCode.AL',
8
+ 'countryCode.AM',
9
+ 'countryCode.AN',
10
+ 'countryCode.AO',
11
+ 'countryCode.AQ',
12
+ 'countryCode.AR',
13
+ 'countryCode.AS',
14
+ 'countryCode.AT',
15
+ 'countryCode.AU',
16
+ 'countryCode.AW',
17
+ 'countryCode.AX',
18
+ 'countryCode.AZ',
19
+ 'countryCode.BA',
20
+ 'countryCode.BB',
21
+ 'countryCode.BD',
22
+ 'countryCode.BE',
23
+ 'countryCode.BF',
24
+ 'countryCode.BG',
25
+ 'countryCode.BH',
26
+ 'countryCode.BI',
27
+ 'countryCode.BJ',
28
+ 'countryCode.BM',
29
+ 'countryCode.BN',
30
+ 'countryCode.BO',
31
+ 'countryCode.BR',
32
+ 'countryCode.BQ',
33
+ 'countryCode.BS',
34
+ 'countryCode.BT',
35
+ 'countryCode.BV',
36
+ 'countryCode.BW',
37
+ 'countryCode.BY',
38
+ 'countryCode.BZ',
39
+ 'countryCode.CA',
40
+ 'countryCode.CC',
41
+ 'countryCode.CD',
42
+ 'countryCode.CF',
43
+ 'countryCode.CG',
44
+ 'countryCode.CH',
45
+ 'countryCode.CI',
46
+ 'countryCode.CK',
47
+ 'countryCode.CL',
48
+ 'countryCode.CM',
49
+ 'countryCode.CN',
50
+ 'countryCode.CO',
51
+ 'countryCode.CR',
52
+ 'countryCode.CU',
53
+ 'countryCode.CV',
54
+ 'countryCode.CX',
55
+ 'countryCode.CY',
56
+ 'countryCode.CZ',
57
+ 'countryCode.DE',
58
+ 'countryCode.DJ',
59
+ 'countryCode.DK',
60
+ 'countryCode.DM',
61
+ 'countryCode.DO',
62
+ 'countryCode.DZ',
63
+ 'countryCode.EC',
64
+ 'countryCode.EE',
65
+ 'countryCode.EG',
66
+ 'countryCode.EH',
67
+ 'countryCode.ER',
68
+ 'countryCode.ES',
69
+ 'countryCode.ET',
70
+ 'countryCode.FI',
71
+ 'countryCode.FJ',
72
+ 'countryCode.FK',
73
+ 'countryCode.FM',
74
+ 'countryCode.FO',
75
+ 'countryCode.FR',
76
+ 'countryCode.GA',
77
+ 'countryCode.GB',
78
+ 'countryCode.GD',
79
+ 'countryCode.GE',
80
+ 'countryCode.GF',
81
+ 'countryCode.GG',
82
+ 'countryCode.GH',
83
+ 'countryCode.GI',
84
+ 'countryCode.GL',
85
+ 'countryCode.GM',
86
+ 'countryCode.GN',
87
+ 'countryCode.GP',
88
+ 'countryCode.GQ',
89
+ 'countryCode.GR',
90
+ 'countryCode.GS',
91
+ 'countryCode.GT',
92
+ 'countryCode.GU',
93
+ 'countryCode.GW',
94
+ 'countryCode.GY',
95
+ 'countryCode.GZ',
96
+ 'countryCode.HK',
97
+ 'countryCode.HM',
98
+ 'countryCode.HN',
99
+ 'countryCode.HR',
100
+ 'countryCode.HT',
101
+ 'countryCode.HU',
102
+ 'countryCode.ID',
103
+ 'countryCode.IE',
104
+ 'countryCode.IL',
105
+ 'countryCode.IM',
106
+ 'countryCode.IN',
107
+ 'countryCode.IO',
108
+ 'countryCode.IQ',
109
+ 'countryCode.IR',
110
+ 'countryCode.IS',
111
+ 'countryCode.IT',
112
+ 'countryCode.JE',
113
+ 'countryCode.JM',
114
+ 'countryCode.JO',
115
+ 'countryCode.JP',
116
+ 'countryCode.KE',
117
+ 'countryCode.KG',
118
+ 'countryCode.KH',
119
+ 'countryCode.KI',
120
+ 'countryCode.KM',
121
+ 'countryCode.KN',
122
+ 'countryCode.KP',
123
+ 'countryCode.KR',
124
+ 'countryCode.KW',
125
+ 'countryCode.KY',
126
+ 'countryCode.KZ',
127
+ 'countryCode.LA',
128
+ 'countryCode.LB',
129
+ 'countryCode.LC',
130
+ 'countryCode.LI',
131
+ 'countryCode.LK',
132
+ 'countryCode.LR',
133
+ 'countryCode.LS',
134
+ 'countryCode.LT',
135
+ 'countryCode.LU',
136
+ 'countryCode.LV',
137
+ 'countryCode.LY',
138
+ 'countryCode.MA',
139
+ 'countryCode.MC',
140
+ 'countryCode.MD',
141
+ 'countryCode.ME',
142
+ 'countryCode.MG',
143
+ 'countryCode.MH',
144
+ 'countryCode.MK',
145
+ 'countryCode.ML',
146
+ 'countryCode.MM',
147
+ 'countryCode.MN',
148
+ 'countryCode.MO',
149
+ 'countryCode.MP',
150
+ 'countryCode.MQ',
151
+ 'countryCode.MR',
152
+ 'countryCode.MS',
153
+ 'countryCode.MT',
154
+ 'countryCode.MU',
155
+ 'countryCode.MV',
156
+ 'countryCode.MW',
157
+ 'countryCode.MX',
158
+ 'countryCode.MY',
159
+ 'countryCode.MZ',
160
+ 'countryCode.NA',
161
+ 'countryCode.NC',
162
+ 'countryCode.NE',
163
+ 'countryCode.NF',
164
+ 'countryCode.NG',
165
+ 'countryCode.NI',
166
+ 'countryCode.NL',
167
+ 'countryCode.NO',
168
+ 'countryCode.NP',
169
+ 'countryCode.NR',
170
+ 'countryCode.NU',
171
+ 'countryCode.NZ',
172
+ 'countryCode.OM',
173
+ 'countryCode.PA',
174
+ 'countryCode.PE',
175
+ 'countryCode.PF',
176
+ 'countryCode.PG',
177
+ 'countryCode.PH',
178
+ 'countryCode.PK',
179
+ 'countryCode.PL',
180
+ 'countryCode.PM',
181
+ 'countryCode.PN',
182
+ 'countryCode.PR',
183
+ 'countryCode.PS',
184
+ 'countryCode.PT',
185
+ 'countryCode.PW',
186
+ 'countryCode.PY',
187
+ 'countryCode.QA',
188
+ 'countryCode.RE',
189
+ 'countryCode.RO',
190
+ 'countryCode.RS',
191
+ 'countryCode.RU',
192
+ 'countryCode.RW',
193
+ 'countryCode.SA',
194
+ 'countryCode.SB',
195
+ 'countryCode.SC',
196
+ 'countryCode.SD',
197
+ 'countryCode.SE',
198
+ 'countryCode.SG',
199
+ 'countryCode.SH',
200
+ 'countryCode.SI',
201
+ 'countryCode.SJ',
202
+ 'countryCode.SK',
203
+ 'countryCode.SL',
204
+ 'countryCode.SM',
205
+ 'countryCode.SN',
206
+ 'countryCode.SO',
207
+ 'countryCode.SR',
208
+ 'countryCode.ST',
209
+ 'countryCode.SV',
210
+ 'countryCode.SY',
211
+ 'countryCode.SZ',
212
+ 'countryCode.TC',
213
+ 'countryCode.TD',
214
+ 'countryCode.TF',
215
+ 'countryCode.TG',
216
+ 'countryCode.TH',
217
+ 'countryCode.TJ',
218
+ 'countryCode.TK',
219
+ 'countryCode.TL',
220
+ 'countryCode.TM',
221
+ 'countryCode.TN',
222
+ 'countryCode.TO',
223
+ 'countryCode.TR',
224
+ 'countryCode.TT',
225
+ 'countryCode.TV',
226
+ 'countryCode.TW',
227
+ 'countryCode.TZ',
228
+ 'countryCode.UA',
229
+ 'countryCode.UG',
230
+ 'countryCode.US',
231
+ 'countryCode.UY',
232
+ 'countryCode.UZ',
233
+ 'countryCode.VA',
234
+ 'countryCode.VC',
235
+ 'countryCode.VE',
236
+ 'countryCode.VG',
237
+ 'countryCode.VI',
238
+ 'countryCode.VN',
239
+ 'countryCode.VU',
240
+ 'countryCode.WF',
241
+ 'countryCode.WS',
242
+ 'countryCode.XK',
243
+ 'countryCode.YE',
244
+ 'countryCode.YT',
245
+ 'countryCode.ZA',
246
+ 'countryCode.ZM',
247
+ 'countryCode.ZW',
248
+ ];
249
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
250
+ const CHECK = COUNTRY_CODE_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './country-code/index.js';
@@ -0,0 +1 @@
1
+ export * from './country-code/index.js';
@@ -0,0 +1,2 @@
1
+ import { TRANSLATION_CODES } from './configs.js';
2
+ export type TranslationCode = (typeof TRANSLATION_CODES)[number];
@@ -0,0 +1,7 @@
1
+ export * from './candle/index.js';
2
+ export * from './common-page/index.js';
3
+ export * from './country/index.js';
4
+ export * from './person/index.js';
5
+ export * from './time/index.js';
6
+ export * from './configs.js';
7
+ export * from './domains.js';
@@ -0,0 +1,7 @@
1
+ export * from './candle/index.js';
2
+ export * from './common-page/index.js';
3
+ export * from './country/index.js';
4
+ export * from './person/index.js';
5
+ export * from './time/index.js';
6
+ export * from './configs.js';
7
+ export * from './domains.js';
@@ -0,0 +1,5 @@
1
+ export * from './person-card/index.js';
2
+ export * from './person-cards/index.js';
3
+ export * from './person-image/index.js';
4
+ export * from './person-maintenance/index.js';
5
+ export * from './persons-list/index.js';
@@ -0,0 +1,5 @@
1
+ export * from './person-card/index.js';
2
+ export * from './person-cards/index.js';
3
+ export * from './person-image/index.js';
4
+ export * from './person-maintenance/index.js';
5
+ export * from './persons-list/index.js';
@@ -0,0 +1 @@
1
+ export declare const PERSON_CARD_TRANSLATION_CODES: readonly ["burnedCandles", "burningCandles", "imageCannotBeLoaded", "imageClickToSeeOriginal", "imageNotSet", "lightACandle"];
@@ -0,0 +1,4 @@
1
+ import { PERSON_IMAGE_TRANSLATION_CODES } from '../person-image/config.js';
2
+ export const PERSON_CARD_TRANSLATION_CODES = ['burnedCandles', 'burningCandles', ...PERSON_IMAGE_TRANSLATION_CODES, 'lightACandle'];
3
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
4
+ const CHECK = PERSON_CARD_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export declare const PERSON_CARDS_TRANSLATION_CODES: readonly ["burnedCandles", "burningCandles", "imageCannotBeLoaded", "imageClickToSeeOriginal", "imageNotSet", "lightACandle"];
@@ -0,0 +1,4 @@
1
+ import { PERSON_CARD_TRANSLATION_CODES } from '../person-card/config.js';
2
+ export const PERSON_CARDS_TRANSLATION_CODES = [...PERSON_CARD_TRANSLATION_CODES];
3
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
4
+ const CHECK = PERSON_CARDS_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export declare const PERSON_IMAGE_TRANSLATION_CODES: readonly ["imageCannotBeLoaded", "imageClickToSeeOriginal", "imageNotSet"];
@@ -0,0 +1,3 @@
1
+ export const PERSON_IMAGE_TRANSLATION_CODES = ['imageCannotBeLoaded', 'imageClickToSeeOriginal', 'imageNotSet'];
2
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
3
+ const CHECK = PERSON_IMAGE_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export declare const PERSON_MAINTENANCE_TRANSLATION_CODES: readonly ["auth.cannotBeChangedLaterWarning", "auth.loginRequired", "add-person-page", "modify", "reset", "count", "dropZone.acceptedFormats", "dropZone.drapActive", "dropZone.dropZone", "dropZone.sizeLimit", "invalidImage", "tooBigImage", "image", "noMoreImages", "form.error.date", "person.birthDate", "person.birthPlaceCountry", "person.deathDate", "person.description", "select", "form.error.maxLength", "proposable", "form.error.required", "name"];
@@ -0,0 +1,28 @@
1
+ export const PERSON_MAINTENANCE_TRANSLATION_CODES = [
2
+ 'auth.cannotBeChangedLaterWarning',
3
+ 'auth.loginRequired',
4
+ 'add-person-page',
5
+ 'modify',
6
+ 'reset',
7
+ 'count',
8
+ 'dropZone.acceptedFormats',
9
+ 'dropZone.drapActive',
10
+ 'dropZone.dropZone',
11
+ 'dropZone.sizeLimit',
12
+ 'invalidImage',
13
+ 'tooBigImage',
14
+ 'image',
15
+ 'noMoreImages',
16
+ 'form.error.date',
17
+ 'person.birthDate',
18
+ 'person.birthPlaceCountry',
19
+ 'person.deathDate',
20
+ 'person.description',
21
+ 'select',
22
+ 'form.error.maxLength',
23
+ 'proposable',
24
+ 'form.error.required',
25
+ 'name',
26
+ ];
27
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
28
+ const CHECK = PERSON_MAINTENANCE_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export declare const PERSONS_LIST_TRANSLATION_CODES: readonly ["burnedCandles", "burningCandles", "imageCannotBeLoaded", "imageClickToSeeOriginal", "imageNotSet", "lightACandle", "personsInCount", "person", "reset", "sort", "name", "caseSensitive", "myPersons", "select", "persons-map-page", "person.birthPlaceCountry", "persons", "persons-page.personsList.hasImage", "createdAt"];
@@ -0,0 +1,19 @@
1
+ import { PERSON_CARDS_TRANSLATION_CODES } from '../person-cards/config.js';
2
+ export const PERSONS_LIST_TRANSLATION_CODES = [
3
+ ...PERSON_CARDS_TRANSLATION_CODES,
4
+ 'personsInCount',
5
+ 'person',
6
+ 'reset',
7
+ 'sort',
8
+ 'name',
9
+ 'caseSensitive',
10
+ 'myPersons',
11
+ 'select',
12
+ 'persons-map-page',
13
+ 'person.birthPlaceCountry',
14
+ 'persons',
15
+ 'persons-page.personsList.hasImage',
16
+ 'createdAt',
17
+ ];
18
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
19
+ const CHECK = PERSONS_LIST_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './config.js';
@@ -0,0 +1 @@
1
+ export * from './time-abbreviation/index.js';
@@ -0,0 +1 @@
1
+ export * from './time-abbreviation/index.js';
@@ -0,0 +1 @@
1
+ export declare const TIME_ABBREVIATION_TRANSLATION_CODES: readonly ["timeAbbreviationDay", "timeAbbreviationHour", "timeAbbreviationMinute"];
@@ -0,0 +1,3 @@
1
+ export const TIME_ABBREVIATION_TRANSLATION_CODES = ['timeAbbreviationDay', 'timeAbbreviationHour', 'timeAbbreviationMinute'];
2
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
3
+ const CHECK = TIME_ABBREVIATION_TRANSLATION_CODES;
@@ -0,0 +1 @@
1
+ export * from './config.js';
package/type/index.d.ts CHANGED
@@ -2,3 +2,5 @@ export * from './array/index.js';
2
2
  export * from './null/index.js';
3
3
  export * from './object/index.js';
4
4
  export * from './string/index.js';
5
+ export * from './type/index.js';
6
+ export * from './undefined/index.js';
package/type/index.js CHANGED
@@ -2,3 +2,5 @@ export * from './array/index.js';
2
2
  export * from './null/index.js';
3
3
  export * from './object/index.js';
4
4
  export * from './string/index.js';
5
+ export * from './type/index.js';
6
+ export * from './undefined/index.js';
@@ -0,0 +1,2 @@
1
+ export * from './type-guards.js';
2
+ export * from './utils/index.js';
@@ -0,0 +1,2 @@
1
+ export * from './type-guards.js';
2
+ export * from './utils/index.js';
@@ -0,0 +1 @@
1
+ export declare const isType: <T>(data: unknown, valid: readonly T[]) => data is T;
@@ -0,0 +1,6 @@
1
+ export const isType = (data, valid) => {
2
+ if (!valid.includes(data)) {
3
+ return false;
4
+ }
5
+ return true;
6
+ };
@@ -0,0 +1 @@
1
+ export * from './validate-by-values/index.js';
@@ -0,0 +1 @@
1
+ export * from './validate-by-values/index.js';
@@ -0,0 +1,2 @@
1
+ import { ValidateByValues } from './type.js';
2
+ export declare const validateByValues: ValidateByValues;
@@ -0,0 +1,20 @@
1
+ /* eslint-disable @typescript-eslint/no-explicit-any */
2
+ import { CustomErrorWorker } from '../../../../custom-error/index.js';
3
+ import { isString } from '../../../string/index.js';
4
+ export const validateByValues = (data, valids) => {
5
+ const { composeCustomError } = CustomErrorWorker({ info: { data, valids } });
6
+ const name = Object.keys(data)[0];
7
+ const value = data[name];
8
+ if (!value) {
9
+ return { customError: composeCustomError(`Missing ${name}`) };
10
+ }
11
+ if (!isString(value)) {
12
+ return { customError: composeCustomError(`Invalid ${name}`) };
13
+ }
14
+ if (!valids.includes(value)) {
15
+ return { customError: composeCustomError(`Invalid ${name}`) };
16
+ }
17
+ return {
18
+ data: value,
19
+ };
20
+ };
@@ -0,0 +1,6 @@
1
+ import { CustomError } from '../../../../index.js';
2
+ export type ValidateByValues = <T>(data: Record<string, unknown>, valids: readonly T[]) => {
3
+ data: T;
4
+ } | {
5
+ customError: CustomError;
6
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export * from './type-guard.js';
@@ -0,0 +1 @@
1
+ export * from './type-guard.js';
@@ -0,0 +1 @@
1
+ export declare const isUndefined: (data?: unknown) => data is undefined;
@@ -0,0 +1 @@
1
+ export const isUndefined = (data) => data === undefined;
@@ -1,2 +0,0 @@
1
- export declare const ENVIRONMENT_VARIABLE_NAMES: readonly ["APP_NAME", "APP_PORT", "AWS_REGION", "AWS_S3_IMAGES_BUCKET_NAME", "CACHE_SERVICE_PORT", "DATABASE_URL", "DOMAIN_NAME", "FRONTEND_URL", "MOBILE_APP_URL", "NODE_ENV", "RABBITMQ_MANAGEMENT_PORT", "RABBITMQ_PORT", "RABBITMQ_PWD", "RABBITMQ_USER", "RABBITMQ_URL", "REDIS_PORT", "REDIS_PWD", "REDIS_URL", "REDIS_URL_APP", "SSL_PRIVATE_KEY"];
2
- export declare const MODE_DEPENDENT_ENVIRONMENT_VARIABLE_NAMES: readonly ["DATABASE_URL"];
@@ -1,23 +0,0 @@
1
- export const ENVIRONMENT_VARIABLE_NAMES = [
2
- 'APP_NAME',
3
- 'APP_PORT',
4
- 'AWS_REGION',
5
- 'AWS_S3_IMAGES_BUCKET_NAME',
6
- 'CACHE_SERVICE_PORT',
7
- 'DATABASE_URL',
8
- 'DOMAIN_NAME',
9
- 'FRONTEND_URL',
10
- 'MOBILE_APP_URL',
11
- 'NODE_ENV',
12
- 'RABBITMQ_MANAGEMENT_PORT',
13
- 'RABBITMQ_PORT',
14
- 'RABBITMQ_PWD',
15
- 'RABBITMQ_USER',
16
- 'RABBITMQ_URL',
17
- 'REDIS_PORT',
18
- 'REDIS_PWD',
19
- 'REDIS_URL',
20
- 'REDIS_URL_APP',
21
- 'SSL_PRIVATE_KEY',
22
- ];
23
- export const MODE_DEPENDENT_ENVIRONMENT_VARIABLE_NAMES = ['DATABASE_URL'];
@@ -1,2 +0,0 @@
1
- import { ENVIRONMENT_VARIABLE_NAMES } from './constants.js';
2
- export type EnvironmentVariableName = (typeof ENVIRONMENT_VARIABLE_NAMES)[number];
@@ -1,2 +0,0 @@
1
- import { EnvironmentVariableName } from './domains.js';
2
- export declare const isEnvironmentVariableName: (data?: unknown) => data is EnvironmentVariableName;
@@ -1,2 +0,0 @@
1
- import { ENVIRONMENT_VARIABLE_NAMES } from './constants.js';
2
- export const isEnvironmentVariableName = (data) => ENVIRONMENT_VARIABLE_NAMES.some((it) => data === it);
@@ -1,23 +0,0 @@
1
- import { EnvironmentMode } from '../environment-mode/index.js';
2
- export type EnvironmentVariables = {
3
- APP_NAME: string;
4
- APP_PORT: number;
5
- AWS_REGION: string;
6
- AWS_S3_IMAGES_BUCKET_NAME: string;
7
- CACHE_SERVICE_PORT: number;
8
- DATABASE_URL: string;
9
- DOMAIN_NAME: string;
10
- FRONTEND_URL: string;
11
- MOBILE_APP_URL: string;
12
- NODE_ENV: EnvironmentMode;
13
- RABBITMQ_MANAGEMENT_PORT: number;
14
- RABBITMQ_PORT: number;
15
- RABBITMQ_PWD: string;
16
- RABBITMQ_USER: string;
17
- RABBITMQ_URL: string;
18
- REDIS_PORT: number;
19
- REDIS_PWD: string;
20
- REDIS_URL: string;
21
- REDIS_URL_APP: string;
22
- SSL_PRIVATE_KEY: string;
23
- };