generaltranslation 2.0.19 → 2.0.20
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/codes/codes.d.ts +3 -1
- package/dist/codes/codes.js +3 -1
- package/package.json +1 -1
package/dist/codes/codes.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* Ensures correct capitalization and formatting of a language code.
|
|
3
|
+
* @param {string} code - The language-country-script code to standardize.
|
|
4
|
+
* @returns {string} A BCP 47 language code.
|
|
3
5
|
*/
|
|
4
6
|
declare function _standardizeLanguageCode(code: string): string;
|
|
5
7
|
/**
|
package/dist/codes/codes.js
CHANGED
|
@@ -34,7 +34,9 @@ const Predefined_json_1 = __importDefault(require("./predefined/Predefined.json"
|
|
|
34
34
|
const Predefined = Predefined_json_1.default;
|
|
35
35
|
// ----- VALIDITY CHECKS ----- //
|
|
36
36
|
/**
|
|
37
|
-
*
|
|
37
|
+
* Ensures correct capitalization and formatting of a language code.
|
|
38
|
+
* @param {string} code - The language-country-script code to standardize.
|
|
39
|
+
* @returns {string} A BCP 47 language code.
|
|
38
40
|
*/
|
|
39
41
|
function _standardizeLanguageCode(code) {
|
|
40
42
|
if (!code || typeof code !== 'string')
|