intlayer 7.5.0-canary.1 → 7.5.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/dist/cjs/cli/index.cjs +3 -3
- package/dist/cjs/cli/script.cjs +2 -2
- package/dist/cjs/cli/script.cjs.map +1 -1
- package/dist/cjs/index.cjs +58 -52
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.mjs +4 -1
- package/dist/esm/index.mjs.map +1 -1
- package/dist/types/index.d.ts +5 -2
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +7 -7
package/dist/cjs/cli/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
Object.keys(
|
|
3
|
+
var _intlayer_cli = require("@intlayer/cli");
|
|
4
|
+
Object.keys(_intlayer_cli).forEach(function (k) {
|
|
5
5
|
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
6
6
|
enumerable: true,
|
|
7
|
-
get: function () { return
|
|
7
|
+
get: function () { return _intlayer_cli[k]; }
|
|
8
8
|
});
|
|
9
9
|
});
|
package/dist/cjs/cli/script.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
|
|
3
|
-
let
|
|
3
|
+
let _intlayer_cli = require("@intlayer/cli");
|
|
4
4
|
|
|
5
5
|
//#region src/cli/script.ts
|
|
6
|
-
(0,
|
|
6
|
+
(0, _intlayer_cli.setAPI)();
|
|
7
7
|
|
|
8
8
|
//#endregion
|
|
9
9
|
//# sourceMappingURL=script.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"script.cjs","names":[],"sources":["../../../src/cli/script.ts"],"sourcesContent":["#!/usr/bin/env node\nimport { setAPI } from '@intlayer/cli';\n\nsetAPI();\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"script.cjs","names":[],"sources":["../../../src/cli/script.ts"],"sourcesContent":["#!/usr/bin/env node\nimport { setAPI } from '@intlayer/cli';\n\nsetAPI();\n"],"mappings":";;;;;2BAGQ"}
|
package/dist/cjs/index.cjs
CHANGED
|
@@ -1,286 +1,292 @@
|
|
|
1
1
|
const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
|
|
2
|
-
let
|
|
3
|
-
let
|
|
4
|
-
|
|
5
|
-
let
|
|
6
|
-
let
|
|
2
|
+
let _intlayer_types = require("@intlayer/types");
|
|
3
|
+
let _intlayer_config_built = require("@intlayer/config/built");
|
|
4
|
+
_intlayer_config_built = require_rolldown_runtime.__toESM(_intlayer_config_built);
|
|
5
|
+
let _intlayer_core = require("@intlayer/core");
|
|
6
|
+
let _intlayer_core_file = require("@intlayer/core/file");
|
|
7
7
|
|
|
8
8
|
//#region src/index.ts
|
|
9
9
|
/** biome-ignore-all lint/suspicious/noEmptyInterface: Intlayer module augmentation registries */
|
|
10
10
|
/**
|
|
11
11
|
* Rexport using named import because πof Tsup bug in CJS
|
|
12
12
|
*/
|
|
13
|
-
|
|
13
|
+
_intlayer_types.Locales.ALL_LOCALES;
|
|
14
14
|
/**
|
|
15
15
|
* @deprecated Use `import { configuration } from 'intlayer'` instead.
|
|
16
16
|
*/
|
|
17
|
-
const getConfiguration = () =>
|
|
17
|
+
const getConfiguration = () => _intlayer_config_built.default;
|
|
18
|
+
const locales = _intlayer_config_built.default.internationalization.locales;
|
|
19
|
+
const requiredLocales = _intlayer_config_built.default.internationalization.requiredLocales;
|
|
20
|
+
const defaultLocale = _intlayer_config_built.default.internationalization.defaultLocale;
|
|
18
21
|
|
|
19
22
|
//#endregion
|
|
20
23
|
Object.defineProperty(exports, 'Intl', {
|
|
21
24
|
enumerable: true,
|
|
22
25
|
get: function () {
|
|
23
|
-
return
|
|
26
|
+
return _intlayer_core.Intl;
|
|
24
27
|
}
|
|
25
28
|
});
|
|
26
29
|
Object.defineProperty(exports, 'Locales', {
|
|
27
30
|
enumerable: true,
|
|
28
31
|
get: function () {
|
|
29
|
-
return
|
|
32
|
+
return _intlayer_types.Locales;
|
|
30
33
|
}
|
|
31
34
|
});
|
|
32
35
|
Object.defineProperty(exports, 'compact', {
|
|
33
36
|
enumerable: true,
|
|
34
37
|
get: function () {
|
|
35
|
-
return
|
|
38
|
+
return _intlayer_core.compact;
|
|
36
39
|
}
|
|
37
40
|
});
|
|
38
41
|
Object.defineProperty(exports, 'cond', {
|
|
39
42
|
enumerable: true,
|
|
40
43
|
get: function () {
|
|
41
|
-
return
|
|
44
|
+
return _intlayer_core.cond;
|
|
42
45
|
}
|
|
43
46
|
});
|
|
44
|
-
exports.configuration =
|
|
47
|
+
exports.configuration = _intlayer_config_built.default;
|
|
45
48
|
Object.defineProperty(exports, 'currency', {
|
|
46
49
|
enumerable: true,
|
|
47
50
|
get: function () {
|
|
48
|
-
return
|
|
51
|
+
return _intlayer_core.currency;
|
|
49
52
|
}
|
|
50
53
|
});
|
|
51
54
|
Object.defineProperty(exports, 'date', {
|
|
52
55
|
enumerable: true,
|
|
53
56
|
get: function () {
|
|
54
|
-
return
|
|
57
|
+
return _intlayer_core.date;
|
|
55
58
|
}
|
|
56
59
|
});
|
|
60
|
+
exports.defaultLocale = defaultLocale;
|
|
57
61
|
Object.defineProperty(exports, 'enu', {
|
|
58
62
|
enumerable: true,
|
|
59
63
|
get: function () {
|
|
60
|
-
return
|
|
64
|
+
return _intlayer_core.enu;
|
|
61
65
|
}
|
|
62
66
|
});
|
|
63
67
|
Object.defineProperty(exports, 'file', {
|
|
64
68
|
enumerable: true,
|
|
65
69
|
get: function () {
|
|
66
|
-
return
|
|
70
|
+
return _intlayer_core_file.file;
|
|
67
71
|
}
|
|
68
72
|
});
|
|
69
73
|
Object.defineProperty(exports, 'gender', {
|
|
70
74
|
enumerable: true,
|
|
71
75
|
get: function () {
|
|
72
|
-
return
|
|
76
|
+
return _intlayer_core.gender;
|
|
73
77
|
}
|
|
74
78
|
});
|
|
75
79
|
Object.defineProperty(exports, 'getBrowserLocale', {
|
|
76
80
|
enumerable: true,
|
|
77
81
|
get: function () {
|
|
78
|
-
return
|
|
82
|
+
return _intlayer_core.getBrowserLocale;
|
|
79
83
|
}
|
|
80
84
|
});
|
|
81
85
|
exports.getConfiguration = getConfiguration;
|
|
82
86
|
Object.defineProperty(exports, 'getCookie', {
|
|
83
87
|
enumerable: true,
|
|
84
88
|
get: function () {
|
|
85
|
-
return
|
|
89
|
+
return _intlayer_core.getCookie;
|
|
86
90
|
}
|
|
87
91
|
});
|
|
88
92
|
Object.defineProperty(exports, 'getDictionary', {
|
|
89
93
|
enumerable: true,
|
|
90
94
|
get: function () {
|
|
91
|
-
return
|
|
95
|
+
return _intlayer_core.getDictionary;
|
|
92
96
|
}
|
|
93
97
|
});
|
|
94
98
|
Object.defineProperty(exports, 'getEnumeration', {
|
|
95
99
|
enumerable: true,
|
|
96
100
|
get: function () {
|
|
97
|
-
return
|
|
101
|
+
return _intlayer_core.getEnumeration;
|
|
98
102
|
}
|
|
99
103
|
});
|
|
100
104
|
Object.defineProperty(exports, 'getEnumerationContent', {
|
|
101
105
|
enumerable: true,
|
|
102
106
|
get: function () {
|
|
103
|
-
return
|
|
107
|
+
return _intlayer_core.getEnumeration;
|
|
104
108
|
}
|
|
105
109
|
});
|
|
106
110
|
Object.defineProperty(exports, 'getHTMLTextDir', {
|
|
107
111
|
enumerable: true,
|
|
108
112
|
get: function () {
|
|
109
|
-
return
|
|
113
|
+
return _intlayer_core.getHTMLTextDir;
|
|
110
114
|
}
|
|
111
115
|
});
|
|
112
116
|
Object.defineProperty(exports, 'getIntlayer', {
|
|
113
117
|
enumerable: true,
|
|
114
118
|
get: function () {
|
|
115
|
-
return
|
|
119
|
+
return _intlayer_core.getIntlayer;
|
|
116
120
|
}
|
|
117
121
|
});
|
|
118
122
|
Object.defineProperty(exports, 'getLocale', {
|
|
119
123
|
enumerable: true,
|
|
120
124
|
get: function () {
|
|
121
|
-
return
|
|
125
|
+
return _intlayer_core.getLocale;
|
|
122
126
|
}
|
|
123
127
|
});
|
|
124
128
|
Object.defineProperty(exports, 'getLocaleFromPath', {
|
|
125
129
|
enumerable: true,
|
|
126
130
|
get: function () {
|
|
127
|
-
return
|
|
131
|
+
return _intlayer_core.getLocaleFromPath;
|
|
128
132
|
}
|
|
129
133
|
});
|
|
130
134
|
Object.defineProperty(exports, 'getLocaleFromStorage', {
|
|
131
135
|
enumerable: true,
|
|
132
136
|
get: function () {
|
|
133
|
-
return
|
|
137
|
+
return _intlayer_core.getLocaleFromStorage;
|
|
134
138
|
}
|
|
135
139
|
});
|
|
136
140
|
Object.defineProperty(exports, 'getLocaleLang', {
|
|
137
141
|
enumerable: true,
|
|
138
142
|
get: function () {
|
|
139
|
-
return
|
|
143
|
+
return _intlayer_core.getLocaleLang;
|
|
140
144
|
}
|
|
141
145
|
});
|
|
142
146
|
Object.defineProperty(exports, 'getLocaleName', {
|
|
143
147
|
enumerable: true,
|
|
144
148
|
get: function () {
|
|
145
|
-
return
|
|
149
|
+
return _intlayer_core.getLocaleName;
|
|
146
150
|
}
|
|
147
151
|
});
|
|
148
152
|
Object.defineProperty(exports, 'getLocalizedUrl', {
|
|
149
153
|
enumerable: true,
|
|
150
154
|
get: function () {
|
|
151
|
-
return
|
|
155
|
+
return _intlayer_core.getLocalizedUrl;
|
|
152
156
|
}
|
|
153
157
|
});
|
|
154
158
|
Object.defineProperty(exports, 'getMarkdownMetadata', {
|
|
155
159
|
enumerable: true,
|
|
156
160
|
get: function () {
|
|
157
|
-
return
|
|
161
|
+
return _intlayer_core.getMarkdownMetadata;
|
|
158
162
|
}
|
|
159
163
|
});
|
|
160
164
|
Object.defineProperty(exports, 'getMultilingualUrls', {
|
|
161
165
|
enumerable: true,
|
|
162
166
|
get: function () {
|
|
163
|
-
return
|
|
167
|
+
return _intlayer_core.getMultilingualUrls;
|
|
164
168
|
}
|
|
165
169
|
});
|
|
166
170
|
Object.defineProperty(exports, 'getNesting', {
|
|
167
171
|
enumerable: true,
|
|
168
172
|
get: function () {
|
|
169
|
-
return
|
|
173
|
+
return _intlayer_core.getNesting;
|
|
170
174
|
}
|
|
171
175
|
});
|
|
172
176
|
Object.defineProperty(exports, 'getPathWithoutLocale', {
|
|
173
177
|
enumerable: true,
|
|
174
178
|
get: function () {
|
|
175
|
-
return
|
|
179
|
+
return _intlayer_core.getPathWithoutLocale;
|
|
176
180
|
}
|
|
177
181
|
});
|
|
178
182
|
Object.defineProperty(exports, 'getPrefix', {
|
|
179
183
|
enumerable: true,
|
|
180
184
|
get: function () {
|
|
181
|
-
return
|
|
185
|
+
return _intlayer_core.getPrefix;
|
|
182
186
|
}
|
|
183
187
|
});
|
|
184
188
|
Object.defineProperty(exports, 'getTranslation', {
|
|
185
189
|
enumerable: true,
|
|
186
190
|
get: function () {
|
|
187
|
-
return
|
|
191
|
+
return _intlayer_core.getTranslation;
|
|
188
192
|
}
|
|
189
193
|
});
|
|
190
194
|
Object.defineProperty(exports, 'getTranslationContent', {
|
|
191
195
|
enumerable: true,
|
|
192
196
|
get: function () {
|
|
193
|
-
return
|
|
197
|
+
return _intlayer_core.getTranslation;
|
|
194
198
|
}
|
|
195
199
|
});
|
|
196
200
|
Object.defineProperty(exports, 'insert', {
|
|
197
201
|
enumerable: true,
|
|
198
202
|
get: function () {
|
|
199
|
-
return
|
|
203
|
+
return _intlayer_core.insert;
|
|
200
204
|
}
|
|
201
205
|
});
|
|
202
206
|
Object.defineProperty(exports, 'localeDetector', {
|
|
203
207
|
enumerable: true,
|
|
204
208
|
get: function () {
|
|
205
|
-
return
|
|
209
|
+
return _intlayer_core.localeDetector;
|
|
206
210
|
}
|
|
207
211
|
});
|
|
208
212
|
Object.defineProperty(exports, 'localeFlatMap', {
|
|
209
213
|
enumerable: true,
|
|
210
214
|
get: function () {
|
|
211
|
-
return
|
|
215
|
+
return _intlayer_core.localeFlatMap;
|
|
212
216
|
}
|
|
213
217
|
});
|
|
214
218
|
Object.defineProperty(exports, 'localeMap', {
|
|
215
219
|
enumerable: true,
|
|
216
220
|
get: function () {
|
|
217
|
-
return
|
|
221
|
+
return _intlayer_core.localeMap;
|
|
218
222
|
}
|
|
219
223
|
});
|
|
220
224
|
Object.defineProperty(exports, 'localeRecord', {
|
|
221
225
|
enumerable: true,
|
|
222
226
|
get: function () {
|
|
223
|
-
return
|
|
227
|
+
return _intlayer_core.localeRecord;
|
|
224
228
|
}
|
|
225
229
|
});
|
|
226
230
|
Object.defineProperty(exports, 'localeResolver', {
|
|
227
231
|
enumerable: true,
|
|
228
232
|
get: function () {
|
|
229
|
-
return
|
|
233
|
+
return _intlayer_core.localeResolver;
|
|
230
234
|
}
|
|
231
235
|
});
|
|
236
|
+
exports.locales = locales;
|
|
232
237
|
Object.defineProperty(exports, 'md', {
|
|
233
238
|
enumerable: true,
|
|
234
239
|
get: function () {
|
|
235
|
-
return
|
|
240
|
+
return _intlayer_core.md;
|
|
236
241
|
}
|
|
237
242
|
});
|
|
238
243
|
Object.defineProperty(exports, 'nest', {
|
|
239
244
|
enumerable: true,
|
|
240
245
|
get: function () {
|
|
241
|
-
return
|
|
246
|
+
return _intlayer_core.nest;
|
|
242
247
|
}
|
|
243
248
|
});
|
|
244
249
|
Object.defineProperty(exports, 'number', {
|
|
245
250
|
enumerable: true,
|
|
246
251
|
get: function () {
|
|
247
|
-
return
|
|
252
|
+
return _intlayer_core.number;
|
|
248
253
|
}
|
|
249
254
|
});
|
|
250
255
|
Object.defineProperty(exports, 'percentage', {
|
|
251
256
|
enumerable: true,
|
|
252
257
|
get: function () {
|
|
253
|
-
return
|
|
258
|
+
return _intlayer_core.percentage;
|
|
254
259
|
}
|
|
255
260
|
});
|
|
256
261
|
Object.defineProperty(exports, 'relativeTime', {
|
|
257
262
|
enumerable: true,
|
|
258
263
|
get: function () {
|
|
259
|
-
return
|
|
264
|
+
return _intlayer_core.relativeTime;
|
|
260
265
|
}
|
|
261
266
|
});
|
|
267
|
+
exports.requiredLocales = requiredLocales;
|
|
262
268
|
Object.defineProperty(exports, 'setLocaleInStorage', {
|
|
263
269
|
enumerable: true,
|
|
264
270
|
get: function () {
|
|
265
|
-
return
|
|
271
|
+
return _intlayer_core.setLocaleInStorage;
|
|
266
272
|
}
|
|
267
273
|
});
|
|
268
274
|
Object.defineProperty(exports, 't', {
|
|
269
275
|
enumerable: true,
|
|
270
276
|
get: function () {
|
|
271
|
-
return
|
|
277
|
+
return _intlayer_core.t;
|
|
272
278
|
}
|
|
273
279
|
});
|
|
274
280
|
Object.defineProperty(exports, 'units', {
|
|
275
281
|
enumerable: true,
|
|
276
282
|
get: function () {
|
|
277
|
-
return
|
|
283
|
+
return _intlayer_core.units;
|
|
278
284
|
}
|
|
279
285
|
});
|
|
280
286
|
Object.defineProperty(exports, 'validatePrefix', {
|
|
281
287
|
enumerable: true,
|
|
282
288
|
get: function () {
|
|
283
|
-
return
|
|
289
|
+
return _intlayer_core.validatePrefix;
|
|
284
290
|
}
|
|
285
291
|
});
|
|
286
292
|
//# sourceMappingURL=index.cjs.map
|
package/dist/cjs/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":["Locales","configuration"],"sources":["../../src/index.ts"],"sourcesContent":["/** biome-ignore-all lint/suspicious/noEmptyInterface: Intlayer module augmentation registries */\nimport {\n type Dictionary as DictionaryCore,\n type CustomIntlayerConfig as IntlayerConfig,\n Locales,\n} from '@intlayer/types';\n\ntype Dictionary<T = undefined> = DictionaryCore<T, true>;\n/**\n * @deprecated Use `Dictionary<T>` instead.\n */\ntype DeclarationContent<T = undefined> = Dictionary<T>;\n\n/**\n * @deprecated\n *\n * Use Locales.All_LOCALES instead\n */\nconst localeList = Locales.ALL_LOCALES;\n\nexport {\n type ContentNode,\n type Locale,\n Locales,\n type LocalesValues,\n type StrictModeLocaleMap,\n} from '@intlayer/types';\nexport type { DeclarationContent, Dictionary, IntlayerConfig, localeList };\n\n/**\n * Rexport using named import because πof Tsup bug in CJS\n */\nimport configuration from '@intlayer/config/built';\n\n/**\n * @deprecated Use `import { configuration } from 'intlayer'` instead.\n */\nconst getConfiguration = () => configuration;\n\n// Reexport here for CJS compatibility\n// Fix ReferenceError: Cannot access 'xxx' before initialization\nexport {
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["Locales","configuration"],"sources":["../../src/index.ts"],"sourcesContent":["/** biome-ignore-all lint/suspicious/noEmptyInterface: Intlayer module augmentation registries */\nimport {\n type Dictionary as DictionaryCore,\n type CustomIntlayerConfig as IntlayerConfig,\n Locales,\n} from '@intlayer/types';\n\ntype Dictionary<T = undefined> = DictionaryCore<T, true>;\n/**\n * @deprecated Use `Dictionary<T>` instead.\n */\ntype DeclarationContent<T = undefined> = Dictionary<T>;\n\n/**\n * @deprecated\n *\n * Use Locales.All_LOCALES instead\n */\nconst localeList = Locales.ALL_LOCALES;\n\nexport {\n type ContentNode,\n type Locale,\n Locales,\n type LocalesValues,\n type StrictModeLocaleMap,\n} from '@intlayer/types';\nexport type { DeclarationContent, Dictionary, IntlayerConfig, localeList };\n\n/**\n * Rexport using named import because πof Tsup bug in CJS\n */\nimport configuration from '@intlayer/config/built';\n\n/**\n * @deprecated Use `import { configuration } from 'intlayer'` instead.\n */\nconst getConfiguration = () => configuration;\n\nconst locales = configuration.internationalization.locales;\nconst requiredLocales = configuration.internationalization.requiredLocales;\nconst defaultLocale = configuration.internationalization.defaultLocale;\n\n// Reexport here for CJS compatibility\n// Fix ReferenceError: Cannot access 'xxx' before initialization\nexport {\n configuration,\n getConfiguration,\n locales,\n requiredLocales,\n defaultLocale,\n};\n\nexport {\n compact,\n cond,\n currency,\n date,\n enu,\n gender,\n getBrowserLocale,\n getCookie,\n getDictionary,\n getEnumeration,\n /**\n * @deprecated Use `getEnumeration` instead.\n */\n getEnumeration as getEnumerationContent,\n getHTMLTextDir,\n getIntlayer,\n getLocale,\n getLocaleFromPath,\n getLocaleFromStorage,\n getLocaleLang,\n getLocaleName,\n getLocalizedUrl,\n getMarkdownMetadata,\n getMultilingualUrls,\n getNesting,\n getPathWithoutLocale,\n getPrefix,\n getTranslation,\n /**\n * @deprecated Use `getTranslation` instead.\n */\n getTranslation as getTranslationContent,\n Intl,\n insert,\n localeDetector,\n localeFlatMap,\n localeMap,\n localeRecord,\n localeResolver,\n md,\n nest,\n number,\n percentage,\n relativeTime,\n setLocaleInStorage,\n t,\n units,\n validatePrefix,\n} from '@intlayer/core';\nexport { file } from '@intlayer/core/file'; // Include specific export for browser because of node js function that can't be used in browser\n\n// --- Registries to be augmented by the generator ---\nexport interface __DictionaryRegistry {} // id -> interfaceof ictionary\nexport interface __DeclaredLocalesRegistry {} // 'fr': 1, 'en': 1, ...\nexport interface __RequiredLocalesRegistry {} // 'en': 1, ...\nexport interface __StrictModeRegistry {} // one of: { strict: true } | { inclusive: true } | { loose: true }\n"],"mappings":";;;;;;;;;;;;AAkBmBA,wBAAQ;;;;AAmB3B,MAAM,yBAAyBC;AAE/B,MAAM,UAAUA,+BAAc,qBAAqB;AACnD,MAAM,kBAAkBA,+BAAc,qBAAqB;AAC3D,MAAM,gBAAgBA,+BAAc,qBAAqB"}
|
package/dist/esm/index.mjs
CHANGED
|
@@ -13,7 +13,10 @@ Locales$1.ALL_LOCALES;
|
|
|
13
13
|
* @deprecated Use `import { configuration } from 'intlayer'` instead.
|
|
14
14
|
*/
|
|
15
15
|
const getConfiguration = () => configuration;
|
|
16
|
+
const locales = configuration.internationalization.locales;
|
|
17
|
+
const requiredLocales = configuration.internationalization.requiredLocales;
|
|
18
|
+
const defaultLocale = configuration.internationalization.defaultLocale;
|
|
16
19
|
|
|
17
20
|
//#endregion
|
|
18
|
-
export { Intl, Locales, compact, cond, configuration, currency, date, enu, file, gender, getBrowserLocale, getConfiguration, getCookie, getDictionary, getEnumeration, getEnumerationContent, getHTMLTextDir, getIntlayer, getLocale, getLocaleFromPath, getLocaleFromStorage, getLocaleLang, getLocaleName, getLocalizedUrl, getMarkdownMetadata, getMultilingualUrls, getNesting, getPathWithoutLocale, getPrefix, getTranslation, getTranslationContent, insert, localeDetector, localeFlatMap, localeMap, localeRecord, localeResolver, md, nest, number, percentage, relativeTime, setLocaleInStorage, t, units, validatePrefix };
|
|
21
|
+
export { Intl, Locales, compact, cond, configuration, currency, date, defaultLocale, enu, file, gender, getBrowserLocale, getConfiguration, getCookie, getDictionary, getEnumeration, getEnumerationContent, getHTMLTextDir, getIntlayer, getLocale, getLocaleFromPath, getLocaleFromStorage, getLocaleLang, getLocaleName, getLocalizedUrl, getMarkdownMetadata, getMultilingualUrls, getNesting, getPathWithoutLocale, getPrefix, getTranslation, getTranslationContent, insert, localeDetector, localeFlatMap, localeMap, localeRecord, localeResolver, locales, md, nest, number, percentage, relativeTime, requiredLocales, setLocaleInStorage, t, units, validatePrefix };
|
|
19
22
|
//# sourceMappingURL=index.mjs.map
|
package/dist/esm/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":["Locales"],"sources":["../../src/index.ts"],"sourcesContent":["/** biome-ignore-all lint/suspicious/noEmptyInterface: Intlayer module augmentation registries */\nimport {\n type Dictionary as DictionaryCore,\n type CustomIntlayerConfig as IntlayerConfig,\n Locales,\n} from '@intlayer/types';\n\ntype Dictionary<T = undefined> = DictionaryCore<T, true>;\n/**\n * @deprecated Use `Dictionary<T>` instead.\n */\ntype DeclarationContent<T = undefined> = Dictionary<T>;\n\n/**\n * @deprecated\n *\n * Use Locales.All_LOCALES instead\n */\nconst localeList = Locales.ALL_LOCALES;\n\nexport {\n type ContentNode,\n type Locale,\n Locales,\n type LocalesValues,\n type StrictModeLocaleMap,\n} from '@intlayer/types';\nexport type { DeclarationContent, Dictionary, IntlayerConfig, localeList };\n\n/**\n * Rexport using named import because πof Tsup bug in CJS\n */\nimport configuration from '@intlayer/config/built';\n\n/**\n * @deprecated Use `import { configuration } from 'intlayer'` instead.\n */\nconst getConfiguration = () => configuration;\n\n// Reexport here for CJS compatibility\n// Fix ReferenceError: Cannot access 'xxx' before initialization\nexport {
|
|
1
|
+
{"version":3,"file":"index.mjs","names":["Locales"],"sources":["../../src/index.ts"],"sourcesContent":["/** biome-ignore-all lint/suspicious/noEmptyInterface: Intlayer module augmentation registries */\nimport {\n type Dictionary as DictionaryCore,\n type CustomIntlayerConfig as IntlayerConfig,\n Locales,\n} from '@intlayer/types';\n\ntype Dictionary<T = undefined> = DictionaryCore<T, true>;\n/**\n * @deprecated Use `Dictionary<T>` instead.\n */\ntype DeclarationContent<T = undefined> = Dictionary<T>;\n\n/**\n * @deprecated\n *\n * Use Locales.All_LOCALES instead\n */\nconst localeList = Locales.ALL_LOCALES;\n\nexport {\n type ContentNode,\n type Locale,\n Locales,\n type LocalesValues,\n type StrictModeLocaleMap,\n} from '@intlayer/types';\nexport type { DeclarationContent, Dictionary, IntlayerConfig, localeList };\n\n/**\n * Rexport using named import because πof Tsup bug in CJS\n */\nimport configuration from '@intlayer/config/built';\n\n/**\n * @deprecated Use `import { configuration } from 'intlayer'` instead.\n */\nconst getConfiguration = () => configuration;\n\nconst locales = configuration.internationalization.locales;\nconst requiredLocales = configuration.internationalization.requiredLocales;\nconst defaultLocale = configuration.internationalization.defaultLocale;\n\n// Reexport here for CJS compatibility\n// Fix ReferenceError: Cannot access 'xxx' before initialization\nexport {\n configuration,\n getConfiguration,\n locales,\n requiredLocales,\n defaultLocale,\n};\n\nexport {\n compact,\n cond,\n currency,\n date,\n enu,\n gender,\n getBrowserLocale,\n getCookie,\n getDictionary,\n getEnumeration,\n /**\n * @deprecated Use `getEnumeration` instead.\n */\n getEnumeration as getEnumerationContent,\n getHTMLTextDir,\n getIntlayer,\n getLocale,\n getLocaleFromPath,\n getLocaleFromStorage,\n getLocaleLang,\n getLocaleName,\n getLocalizedUrl,\n getMarkdownMetadata,\n getMultilingualUrls,\n getNesting,\n getPathWithoutLocale,\n getPrefix,\n getTranslation,\n /**\n * @deprecated Use `getTranslation` instead.\n */\n getTranslation as getTranslationContent,\n Intl,\n insert,\n localeDetector,\n localeFlatMap,\n localeMap,\n localeRecord,\n localeResolver,\n md,\n nest,\n number,\n percentage,\n relativeTime,\n setLocaleInStorage,\n t,\n units,\n validatePrefix,\n} from '@intlayer/core';\nexport { file } from '@intlayer/core/file'; // Include specific export for browser because of node js function that can't be used in browser\n\n// --- Registries to be augmented by the generator ---\nexport interface __DictionaryRegistry {} // id -> interfaceof ictionary\nexport interface __DeclaredLocalesRegistry {} // 'fr': 1, 'en': 1, ...\nexport interface __RequiredLocalesRegistry {} // 'en': 1, ...\nexport interface __StrictModeRegistry {} // one of: { strict: true } | { inclusive: true } | { loose: true }\n"],"mappings":";;;;;;;;;;AAkBmBA,UAAQ;;;;AAmB3B,MAAM,yBAAyB;AAE/B,MAAM,UAAU,cAAc,qBAAqB;AACnD,MAAM,kBAAkB,cAAc,qBAAqB;AAC3D,MAAM,gBAAgB,cAAc,qBAAqB"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _intlayer_types0 from "@intlayer/types";
|
|
2
|
-
import { ContentNode, CustomIntlayerConfig as IntlayerConfig, Dictionary as Dictionary$1, Locale, Locales, LocalesValues, StrictModeLocaleMap } from "@intlayer/types";
|
|
2
|
+
import { ContentNode, CustomIntlayerConfig as IntlayerConfig, Dictionary as Dictionary$1, Locale, Locales, Locales as Locales$1, LocalesValues, StrictModeLocaleMap } from "@intlayer/types";
|
|
3
3
|
import configuration from "@intlayer/config/built";
|
|
4
4
|
import { Intl, compact, cond, currency, date, enu, gender, getBrowserLocale, getCookie, getDictionary, getEnumeration, getEnumeration as getEnumerationContent, getHTMLTextDir, getIntlayer, getLocale, getLocaleFromPath, getLocaleFromStorage, getLocaleLang, getLocaleName, getLocalizedUrl, getMarkdownMetadata, getMultilingualUrls, getNesting, getPathWithoutLocale, getPrefix, getTranslation, getTranslation as getTranslationContent, insert, localeDetector, localeFlatMap, localeMap, localeRecord, localeResolver, md, nest, number, percentage, relativeTime, setLocaleInStorage, t, units, validatePrefix } from "@intlayer/core";
|
|
5
5
|
import { file } from "@intlayer/core/file";
|
|
@@ -322,10 +322,13 @@ declare const localeList: {
|
|
|
322
322
|
* @deprecated Use `import { configuration } from 'intlayer'` instead.
|
|
323
323
|
*/
|
|
324
324
|
declare const getConfiguration: () => _intlayer_types0.IntlayerConfig;
|
|
325
|
+
declare const locales: Locales$1.Locale[];
|
|
326
|
+
declare const requiredLocales: Locales$1.Locale[];
|
|
327
|
+
declare const defaultLocale: Locales$1.Locale;
|
|
325
328
|
interface __DictionaryRegistry {}
|
|
326
329
|
interface __DeclaredLocalesRegistry {}
|
|
327
330
|
interface __RequiredLocalesRegistry {}
|
|
328
331
|
interface __StrictModeRegistry {}
|
|
329
332
|
//#endregion
|
|
330
|
-
export { type ContentNode, type DeclarationContent, type Dictionary, Intl, type IntlayerConfig, type Locale, Locales, type LocalesValues, type StrictModeLocaleMap, __DeclaredLocalesRegistry, __DictionaryRegistry, __RequiredLocalesRegistry, __StrictModeRegistry, compact, cond, configuration, currency, date, enu, file, gender, getBrowserLocale, getConfiguration, getCookie, getDictionary, getEnumeration, getEnumerationContent, getHTMLTextDir, getIntlayer, getLocale, getLocaleFromPath, getLocaleFromStorage, getLocaleLang, getLocaleName, getLocalizedUrl, getMarkdownMetadata, getMultilingualUrls, getNesting, getPathWithoutLocale, getPrefix, getTranslation, getTranslationContent, insert, localeDetector, localeFlatMap, type localeList, localeMap, localeRecord, localeResolver, md, nest, number, percentage, relativeTime, setLocaleInStorage, t, units, validatePrefix };
|
|
333
|
+
export { type ContentNode, type DeclarationContent, type Dictionary, Intl, type IntlayerConfig, type Locale, Locales, type LocalesValues, type StrictModeLocaleMap, __DeclaredLocalesRegistry, __DictionaryRegistry, __RequiredLocalesRegistry, __StrictModeRegistry, compact, cond, configuration, currency, date, defaultLocale, enu, file, gender, getBrowserLocale, getConfiguration, getCookie, getDictionary, getEnumeration, getEnumerationContent, getHTMLTextDir, getIntlayer, getLocale, getLocaleFromPath, getLocaleFromStorage, getLocaleLang, getLocaleName, getLocalizedUrl, getMarkdownMetadata, getMultilingualUrls, getNesting, getPathWithoutLocale, getPrefix, getTranslation, getTranslationContent, insert, localeDetector, localeFlatMap, type localeList, localeMap, localeRecord, localeResolver, locales, md, nest, number, percentage, relativeTime, requiredLocales, setLocaleInStorage, t, units, validatePrefix };
|
|
331
334
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","names":[],"sources":["../../src/index.ts"],"sourcesContent":[],"mappings":";;;;;;;KAOK,4BAA4B,aAAe;;;;KAI3C,oCAAoC,WAAW;AAN3B;AAEsB;AAII;AAqBA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../../src/index.ts"],"sourcesContent":[],"mappings":";;;;;;;KAOK,4BAA4B,aAAe;;;;KAI3C,oCAAoC,WAAW;AAN3B;AAEsB;AAII;AAqBA;AAKP;AAE/B,cArBP,UAsBoE,EAAA;EACpE,SAAA,SAAgE,EAAA,IAAA;EAiErD,SAAA,sBAAoB,EAAA,OAAA;EACpB,SAAA,MAAA,EAAA,IAAA;EACA,SAAA,2BAAyB,EAAA,OAAA;EACzB,SAAA,cAAoB,EAAA,OAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAxE/B,wBAAsC,gBAAA,CAAtB;cAEhB,SAAO,SAAA,CAAA;cACP,iBAAe,SAAA,CAAA;cACf,eAAa,SAAA,CAAA;UAiEF,oBAAA;UACA,yBAAA;UACA,yBAAA;UACA,oBAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "intlayer",
|
|
3
|
-
"version": "7.5.
|
|
3
|
+
"version": "7.5.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Manage internationalization i18n in a simple way, through TypeScript, declaration file, declare your multilingual content every where in your code.",
|
|
6
6
|
"keywords": [
|
|
@@ -91,18 +91,18 @@
|
|
|
91
91
|
"typecheck": "tsc --noEmit --project tsconfig.types.json"
|
|
92
92
|
},
|
|
93
93
|
"dependencies": {
|
|
94
|
-
"@intlayer/cli": "7.5.
|
|
95
|
-
"@intlayer/config": "7.5.
|
|
96
|
-
"@intlayer/core": "7.5.
|
|
97
|
-
"@intlayer/types": "7.5.
|
|
94
|
+
"@intlayer/cli": "7.5.1",
|
|
95
|
+
"@intlayer/config": "7.5.1",
|
|
96
|
+
"@intlayer/core": "7.5.1",
|
|
97
|
+
"@intlayer/types": "7.5.1"
|
|
98
98
|
},
|
|
99
99
|
"devDependencies": {
|
|
100
|
-
"@types/node": "25.0.
|
|
100
|
+
"@types/node": "25.0.3",
|
|
101
101
|
"@utils/ts-config": "1.0.4",
|
|
102
102
|
"@utils/ts-config-types": "1.0.4",
|
|
103
103
|
"@utils/tsdown-config": "1.0.4",
|
|
104
104
|
"rimraf": "6.1.2",
|
|
105
|
-
"tsdown": "0.18.
|
|
105
|
+
"tsdown": "0.18.1",
|
|
106
106
|
"typescript": "5.9.3",
|
|
107
107
|
"vitest": "4.0.16"
|
|
108
108
|
},
|