@asteby/metacore-i18n 2.0.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/LICENSE +201 -0
- package/README.md +78 -0
- package/dist/config.d.ts +57 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +48 -0
- package/dist/config.js.map +1 -0
- package/dist/direction-provider.d.ts +44 -0
- package/dist/direction-provider.d.ts.map +1 -0
- package/dist/direction-provider.js +47 -0
- package/dist/direction-provider.js.map +1 -0
- package/dist/hooks.d.ts +27 -0
- package/dist/hooks.d.ts.map +1 -0
- package/dist/hooks.js +40 -0
- package/dist/hooks.js.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -0
- package/dist/language-switcher.d.ts +37 -0
- package/dist/language-switcher.d.ts.map +1 -0
- package/dist/language-switcher.js +29 -0
- package/dist/language-switcher.js.map +1 -0
- package/dist/locales/en.json +174 -0
- package/dist/locales/es.json +174 -0
- package/dist/locales/index.d.ts +365 -0
- package/dist/locales/index.d.ts.map +1 -0
- package/dist/locales/index.js +14 -0
- package/dist/locales/index.js.map +1 -0
- package/package.json +79 -0
|
@@ -0,0 +1,365 @@
|
|
|
1
|
+
import en from './en.json';
|
|
2
|
+
import es from './es.json';
|
|
3
|
+
export { en, es };
|
|
4
|
+
/**
|
|
5
|
+
* Base resource bundles for i18next.
|
|
6
|
+
*
|
|
7
|
+
* Each app can either pass these directly to `createI18n` or spread them
|
|
8
|
+
* and override specific keys / add their own namespaces.
|
|
9
|
+
*/
|
|
10
|
+
export declare const baseResources: {
|
|
11
|
+
readonly en: {
|
|
12
|
+
readonly translation: {
|
|
13
|
+
auth: {
|
|
14
|
+
signIn: {
|
|
15
|
+
title: string;
|
|
16
|
+
description: string;
|
|
17
|
+
email: string;
|
|
18
|
+
password: string;
|
|
19
|
+
forgotPassword: string;
|
|
20
|
+
signInButton: string;
|
|
21
|
+
orContinueWith: string;
|
|
22
|
+
terms: string;
|
|
23
|
+
termsLink: string;
|
|
24
|
+
and: string;
|
|
25
|
+
privacyLink: string;
|
|
26
|
+
};
|
|
27
|
+
signUp: {
|
|
28
|
+
title: string;
|
|
29
|
+
description: string;
|
|
30
|
+
name: string;
|
|
31
|
+
email: string;
|
|
32
|
+
password: string;
|
|
33
|
+
confirmPassword: string;
|
|
34
|
+
signUpButton: string;
|
|
35
|
+
haveAccount: string;
|
|
36
|
+
signInLink: string;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
common: {
|
|
40
|
+
all: string;
|
|
41
|
+
search: string;
|
|
42
|
+
search_placeholder: string;
|
|
43
|
+
search_command: string;
|
|
44
|
+
no_results: string;
|
|
45
|
+
theme: string;
|
|
46
|
+
theme_light: string;
|
|
47
|
+
theme_dark: string;
|
|
48
|
+
theme_system: string;
|
|
49
|
+
logout: string;
|
|
50
|
+
profile: string;
|
|
51
|
+
settings: string;
|
|
52
|
+
notifications: string;
|
|
53
|
+
save: string;
|
|
54
|
+
cancel: string;
|
|
55
|
+
delete: string;
|
|
56
|
+
edit: string;
|
|
57
|
+
view: string;
|
|
58
|
+
create: string;
|
|
59
|
+
actions: string;
|
|
60
|
+
loading: string;
|
|
61
|
+
noData: string;
|
|
62
|
+
success: string;
|
|
63
|
+
error: string;
|
|
64
|
+
connected: string;
|
|
65
|
+
disconnected: string;
|
|
66
|
+
connecting: string;
|
|
67
|
+
reset: string;
|
|
68
|
+
refresh: string;
|
|
69
|
+
add: string;
|
|
70
|
+
remove: string;
|
|
71
|
+
manage: string;
|
|
72
|
+
save_changes: string;
|
|
73
|
+
save_preferences: string;
|
|
74
|
+
saving: string;
|
|
75
|
+
name: string;
|
|
76
|
+
description: string;
|
|
77
|
+
status: string;
|
|
78
|
+
active: string;
|
|
79
|
+
inactive: string;
|
|
80
|
+
select: string;
|
|
81
|
+
select_placeholder: string;
|
|
82
|
+
new: string;
|
|
83
|
+
created: string;
|
|
84
|
+
updated: string;
|
|
85
|
+
back: string;
|
|
86
|
+
next: string;
|
|
87
|
+
previous: string;
|
|
88
|
+
finish: string;
|
|
89
|
+
close: string;
|
|
90
|
+
appearance: string;
|
|
91
|
+
change: string;
|
|
92
|
+
retry: string;
|
|
93
|
+
continue: string;
|
|
94
|
+
done: string;
|
|
95
|
+
};
|
|
96
|
+
errors: {
|
|
97
|
+
generic: string;
|
|
98
|
+
network: string;
|
|
99
|
+
unauthorized: string;
|
|
100
|
+
not_found: string;
|
|
101
|
+
validation: string;
|
|
102
|
+
required: string;
|
|
103
|
+
invalid_email: string;
|
|
104
|
+
password_min_length: string;
|
|
105
|
+
name_min_length: string;
|
|
106
|
+
};
|
|
107
|
+
datatable: {
|
|
108
|
+
search_placeholder: string;
|
|
109
|
+
filter_by_date: string;
|
|
110
|
+
no_results_title: string;
|
|
111
|
+
no_results_description: string;
|
|
112
|
+
delete_confirmation_title: string;
|
|
113
|
+
delete_confirmation_description: string;
|
|
114
|
+
delete_button: string;
|
|
115
|
+
deleting: string;
|
|
116
|
+
delete_success: string;
|
|
117
|
+
delete_error: string;
|
|
118
|
+
bulk_delete_title: string;
|
|
119
|
+
bulk_delete_running_title: string;
|
|
120
|
+
bulk_delete_description: string;
|
|
121
|
+
bulk_delete_progress: string;
|
|
122
|
+
bulk_delete_confirm: string;
|
|
123
|
+
bulk_delete_success: string;
|
|
124
|
+
bulk_delete_error: string;
|
|
125
|
+
delete_selected: string;
|
|
126
|
+
rows_per_page: string;
|
|
127
|
+
page_x_of_y: string;
|
|
128
|
+
go_first_page: string;
|
|
129
|
+
go_previous_page: string;
|
|
130
|
+
go_next_page: string;
|
|
131
|
+
go_last_page: string;
|
|
132
|
+
go_page: string;
|
|
133
|
+
refresh: string;
|
|
134
|
+
asc: string;
|
|
135
|
+
desc: string;
|
|
136
|
+
hide: string;
|
|
137
|
+
columns: string;
|
|
138
|
+
view: string;
|
|
139
|
+
};
|
|
140
|
+
settings: {
|
|
141
|
+
profile: {
|
|
142
|
+
title: string;
|
|
143
|
+
photo: string;
|
|
144
|
+
photo_description: string;
|
|
145
|
+
name: string;
|
|
146
|
+
name_placeholder: string;
|
|
147
|
+
name_description: string;
|
|
148
|
+
name_min_length: string;
|
|
149
|
+
name_max_length: string;
|
|
150
|
+
email: string;
|
|
151
|
+
email_placeholder: string;
|
|
152
|
+
email_description: string;
|
|
153
|
+
email_invalid: string;
|
|
154
|
+
profile_updated: string;
|
|
155
|
+
error_updating: string;
|
|
156
|
+
};
|
|
157
|
+
appearance: {
|
|
158
|
+
font: string;
|
|
159
|
+
font_description: string;
|
|
160
|
+
theme: string;
|
|
161
|
+
theme_description: string;
|
|
162
|
+
light: string;
|
|
163
|
+
dark: string;
|
|
164
|
+
preferences_saved: string;
|
|
165
|
+
};
|
|
166
|
+
notifications: {
|
|
167
|
+
new_messages: string;
|
|
168
|
+
new_messages_description: string;
|
|
169
|
+
news_promotions: string;
|
|
170
|
+
news_promotions_description: string;
|
|
171
|
+
preferences_saved: string;
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
coming_soon: {
|
|
175
|
+
default_title: string;
|
|
176
|
+
default_description: string;
|
|
177
|
+
access_soon: string;
|
|
178
|
+
};
|
|
179
|
+
language: {
|
|
180
|
+
label: string;
|
|
181
|
+
toggle: string;
|
|
182
|
+
english: string;
|
|
183
|
+
spanish: string;
|
|
184
|
+
};
|
|
185
|
+
};
|
|
186
|
+
};
|
|
187
|
+
readonly es: {
|
|
188
|
+
readonly translation: {
|
|
189
|
+
auth: {
|
|
190
|
+
signIn: {
|
|
191
|
+
title: string;
|
|
192
|
+
description: string;
|
|
193
|
+
email: string;
|
|
194
|
+
password: string;
|
|
195
|
+
forgotPassword: string;
|
|
196
|
+
signInButton: string;
|
|
197
|
+
orContinueWith: string;
|
|
198
|
+
terms: string;
|
|
199
|
+
termsLink: string;
|
|
200
|
+
and: string;
|
|
201
|
+
privacyLink: string;
|
|
202
|
+
};
|
|
203
|
+
signUp: {
|
|
204
|
+
title: string;
|
|
205
|
+
description: string;
|
|
206
|
+
name: string;
|
|
207
|
+
email: string;
|
|
208
|
+
password: string;
|
|
209
|
+
confirmPassword: string;
|
|
210
|
+
signUpButton: string;
|
|
211
|
+
haveAccount: string;
|
|
212
|
+
signInLink: string;
|
|
213
|
+
};
|
|
214
|
+
};
|
|
215
|
+
common: {
|
|
216
|
+
all: string;
|
|
217
|
+
search: string;
|
|
218
|
+
search_placeholder: string;
|
|
219
|
+
search_command: string;
|
|
220
|
+
no_results: string;
|
|
221
|
+
theme: string;
|
|
222
|
+
theme_light: string;
|
|
223
|
+
theme_dark: string;
|
|
224
|
+
theme_system: string;
|
|
225
|
+
logout: string;
|
|
226
|
+
profile: string;
|
|
227
|
+
settings: string;
|
|
228
|
+
notifications: string;
|
|
229
|
+
save: string;
|
|
230
|
+
cancel: string;
|
|
231
|
+
delete: string;
|
|
232
|
+
edit: string;
|
|
233
|
+
view: string;
|
|
234
|
+
create: string;
|
|
235
|
+
actions: string;
|
|
236
|
+
loading: string;
|
|
237
|
+
noData: string;
|
|
238
|
+
success: string;
|
|
239
|
+
error: string;
|
|
240
|
+
connected: string;
|
|
241
|
+
disconnected: string;
|
|
242
|
+
connecting: string;
|
|
243
|
+
reset: string;
|
|
244
|
+
refresh: string;
|
|
245
|
+
add: string;
|
|
246
|
+
remove: string;
|
|
247
|
+
manage: string;
|
|
248
|
+
save_changes: string;
|
|
249
|
+
save_preferences: string;
|
|
250
|
+
saving: string;
|
|
251
|
+
name: string;
|
|
252
|
+
description: string;
|
|
253
|
+
status: string;
|
|
254
|
+
active: string;
|
|
255
|
+
inactive: string;
|
|
256
|
+
select: string;
|
|
257
|
+
select_placeholder: string;
|
|
258
|
+
new: string;
|
|
259
|
+
created: string;
|
|
260
|
+
updated: string;
|
|
261
|
+
back: string;
|
|
262
|
+
next: string;
|
|
263
|
+
previous: string;
|
|
264
|
+
finish: string;
|
|
265
|
+
close: string;
|
|
266
|
+
appearance: string;
|
|
267
|
+
change: string;
|
|
268
|
+
retry: string;
|
|
269
|
+
continue: string;
|
|
270
|
+
done: string;
|
|
271
|
+
};
|
|
272
|
+
errors: {
|
|
273
|
+
generic: string;
|
|
274
|
+
network: string;
|
|
275
|
+
unauthorized: string;
|
|
276
|
+
not_found: string;
|
|
277
|
+
validation: string;
|
|
278
|
+
required: string;
|
|
279
|
+
invalid_email: string;
|
|
280
|
+
password_min_length: string;
|
|
281
|
+
name_min_length: string;
|
|
282
|
+
};
|
|
283
|
+
datatable: {
|
|
284
|
+
search_placeholder: string;
|
|
285
|
+
filter_by_date: string;
|
|
286
|
+
no_results_title: string;
|
|
287
|
+
no_results_description: string;
|
|
288
|
+
delete_confirmation_title: string;
|
|
289
|
+
delete_confirmation_description: string;
|
|
290
|
+
delete_button: string;
|
|
291
|
+
deleting: string;
|
|
292
|
+
delete_success: string;
|
|
293
|
+
delete_error: string;
|
|
294
|
+
bulk_delete_title: string;
|
|
295
|
+
bulk_delete_running_title: string;
|
|
296
|
+
bulk_delete_description: string;
|
|
297
|
+
bulk_delete_progress: string;
|
|
298
|
+
bulk_delete_confirm: string;
|
|
299
|
+
bulk_delete_success: string;
|
|
300
|
+
bulk_delete_error: string;
|
|
301
|
+
delete_selected: string;
|
|
302
|
+
rows_per_page: string;
|
|
303
|
+
page_x_of_y: string;
|
|
304
|
+
go_first_page: string;
|
|
305
|
+
go_previous_page: string;
|
|
306
|
+
go_next_page: string;
|
|
307
|
+
go_last_page: string;
|
|
308
|
+
go_page: string;
|
|
309
|
+
refresh: string;
|
|
310
|
+
asc: string;
|
|
311
|
+
desc: string;
|
|
312
|
+
hide: string;
|
|
313
|
+
columns: string;
|
|
314
|
+
view: string;
|
|
315
|
+
};
|
|
316
|
+
settings: {
|
|
317
|
+
profile: {
|
|
318
|
+
title: string;
|
|
319
|
+
photo: string;
|
|
320
|
+
photo_description: string;
|
|
321
|
+
name: string;
|
|
322
|
+
name_placeholder: string;
|
|
323
|
+
name_description: string;
|
|
324
|
+
name_min_length: string;
|
|
325
|
+
name_max_length: string;
|
|
326
|
+
email: string;
|
|
327
|
+
email_placeholder: string;
|
|
328
|
+
email_description: string;
|
|
329
|
+
email_invalid: string;
|
|
330
|
+
profile_updated: string;
|
|
331
|
+
error_updating: string;
|
|
332
|
+
};
|
|
333
|
+
appearance: {
|
|
334
|
+
font: string;
|
|
335
|
+
font_description: string;
|
|
336
|
+
theme: string;
|
|
337
|
+
theme_description: string;
|
|
338
|
+
light: string;
|
|
339
|
+
dark: string;
|
|
340
|
+
preferences_saved: string;
|
|
341
|
+
};
|
|
342
|
+
notifications: {
|
|
343
|
+
new_messages: string;
|
|
344
|
+
new_messages_description: string;
|
|
345
|
+
news_promotions: string;
|
|
346
|
+
news_promotions_description: string;
|
|
347
|
+
preferences_saved: string;
|
|
348
|
+
};
|
|
349
|
+
};
|
|
350
|
+
coming_soon: {
|
|
351
|
+
default_title: string;
|
|
352
|
+
default_description: string;
|
|
353
|
+
access_soon: string;
|
|
354
|
+
};
|
|
355
|
+
language: {
|
|
356
|
+
label: string;
|
|
357
|
+
toggle: string;
|
|
358
|
+
english: string;
|
|
359
|
+
spanish: string;
|
|
360
|
+
};
|
|
361
|
+
};
|
|
362
|
+
};
|
|
363
|
+
};
|
|
364
|
+
export type BaseLanguage = keyof typeof baseResources;
|
|
365
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/locales/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,WAAW,CAAA;AAC1B,OAAO,EAAE,MAAM,WAAW,CAAA;AAE1B,OAAO,EAAE,EAAE,EAAE,EAAE,EAAE,CAAA;AAEjB;;;;;GAKG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGhB,CAAA;AAEV,MAAM,MAAM,YAAY,GAAG,MAAM,OAAO,aAAa,CAAA"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import en from './en.json';
|
|
2
|
+
import es from './es.json';
|
|
3
|
+
export { en, es };
|
|
4
|
+
/**
|
|
5
|
+
* Base resource bundles for i18next.
|
|
6
|
+
*
|
|
7
|
+
* Each app can either pass these directly to `createI18n` or spread them
|
|
8
|
+
* and override specific keys / add their own namespaces.
|
|
9
|
+
*/
|
|
10
|
+
export const baseResources = {
|
|
11
|
+
en: { translation: en },
|
|
12
|
+
es: { translation: es },
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/locales/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,WAAW,CAAA;AAC1B,OAAO,EAAE,MAAM,WAAW,CAAA;AAE1B,OAAO,EAAE,EAAE,EAAE,EAAE,EAAE,CAAA;AAEjB;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,EAAE,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE;IACvB,EAAE,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE;CACf,CAAA"}
|
package/package.json
ADDED
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@asteby/metacore-i18n",
|
|
3
|
+
"version": "2.0.0",
|
|
4
|
+
"description": "Metacore i18n — i18next factory, base ES/EN bundles, language switcher, RTL provider",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/asteby/metacore-sdk",
|
|
9
|
+
"directory": "packages/i18n"
|
|
10
|
+
},
|
|
11
|
+
"type": "module",
|
|
12
|
+
"main": "./dist/index.js",
|
|
13
|
+
"types": "./dist/index.d.ts",
|
|
14
|
+
"files": [
|
|
15
|
+
"dist",
|
|
16
|
+
"README.md"
|
|
17
|
+
],
|
|
18
|
+
"exports": {
|
|
19
|
+
".": {
|
|
20
|
+
"types": "./dist/index.d.ts",
|
|
21
|
+
"import": "./dist/index.js"
|
|
22
|
+
},
|
|
23
|
+
"./config": {
|
|
24
|
+
"types": "./dist/config.d.ts",
|
|
25
|
+
"import": "./dist/config.js"
|
|
26
|
+
},
|
|
27
|
+
"./language-switcher": {
|
|
28
|
+
"types": "./dist/language-switcher.d.ts",
|
|
29
|
+
"import": "./dist/language-switcher.js"
|
|
30
|
+
},
|
|
31
|
+
"./direction-provider": {
|
|
32
|
+
"types": "./dist/direction-provider.d.ts",
|
|
33
|
+
"import": "./dist/direction-provider.js"
|
|
34
|
+
},
|
|
35
|
+
"./hooks": {
|
|
36
|
+
"types": "./dist/hooks.d.ts",
|
|
37
|
+
"import": "./dist/hooks.js"
|
|
38
|
+
},
|
|
39
|
+
"./locales/en": "./dist/locales/en.json",
|
|
40
|
+
"./locales/es": "./dist/locales/es.json"
|
|
41
|
+
},
|
|
42
|
+
"peerDependencies": {
|
|
43
|
+
"react": ">=18",
|
|
44
|
+
"react-dom": ">=18",
|
|
45
|
+
"i18next": ">=23",
|
|
46
|
+
"lucide-react": ">=0.460",
|
|
47
|
+
"react-i18next": ">=13",
|
|
48
|
+
"@asteby/metacore-ui": "^0.3.0"
|
|
49
|
+
},
|
|
50
|
+
"peerDependenciesMeta": {
|
|
51
|
+
"@asteby/metacore-ui": {
|
|
52
|
+
"optional": true
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"dependencies": {
|
|
56
|
+
"i18next-browser-languagedetector": "^8.0.0"
|
|
57
|
+
},
|
|
58
|
+
"devDependencies": {
|
|
59
|
+
"@types/react": "^19.0.0",
|
|
60
|
+
"@types/react-dom": "^19.0.0",
|
|
61
|
+
"i18next": "^23.16.0",
|
|
62
|
+
"lucide-react": "^0.460.0",
|
|
63
|
+
"react": "^19.2.4",
|
|
64
|
+
"react-dom": "^19.2.4",
|
|
65
|
+
"react-i18next": "^15.1.0",
|
|
66
|
+
"tsc-alias": "^1.8.10",
|
|
67
|
+
"typescript": "^5.6.0",
|
|
68
|
+
"@asteby/metacore-ui": "0.3.0"
|
|
69
|
+
},
|
|
70
|
+
"publishConfig": {
|
|
71
|
+
"access": "public"
|
|
72
|
+
},
|
|
73
|
+
"scripts": {
|
|
74
|
+
"build": "tsc -p tsconfig.json && tsc-alias -p tsconfig.json",
|
|
75
|
+
"dev": "tsc -w -p tsconfig.json",
|
|
76
|
+
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
77
|
+
"clean": "rm -rf dist"
|
|
78
|
+
}
|
|
79
|
+
}
|