@polyglot-bundles/mi-lang 1.1.2
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/characters.d.ts +43 -0
- package/dist/characters.js +57 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +8 -0
- package/package.json +36 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Māori Character Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for Māori characters (Latin script).
|
|
5
|
+
* Māori has 10 letters: 5 vowels, 5 consonants.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Base character info
|
|
9
|
+
*/
|
|
10
|
+
type MāoriCharacterBaseInfo = {
|
|
11
|
+
char: string;
|
|
12
|
+
id: string;
|
|
13
|
+
display?: string;
|
|
14
|
+
audio?: string;
|
|
15
|
+
notes?: string;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Māori Vowels
|
|
19
|
+
*/
|
|
20
|
+
export type MāoriVowelsInfo = {
|
|
21
|
+
charType: "vowel";
|
|
22
|
+
ipa: string;
|
|
23
|
+
name: string;
|
|
24
|
+
length?: "short" | "long";
|
|
25
|
+
} & MāoriCharacterBaseInfo;
|
|
26
|
+
/**
|
|
27
|
+
* Māori Consonants
|
|
28
|
+
*/
|
|
29
|
+
export type MāoriConsonantsInfo = {
|
|
30
|
+
charType: "consonant";
|
|
31
|
+
ipa: string;
|
|
32
|
+
name: string;
|
|
33
|
+
articulation: "stop" | "fricative" | "nasal" | "approximant" | "lateral" | "trill";
|
|
34
|
+
voicing: "voiced" | "voiceless" | "nasal" | "lateral" | "approximant" | "trill" | "fricative";
|
|
35
|
+
place: "velar" | "palatal" | "alveolar" | "dental" | "labial" | "glottal" | "alveolar";
|
|
36
|
+
} & MāoriCharacterBaseInfo;
|
|
37
|
+
export type MāoriCharacter = MāoriVowelsInfo | MāoriConsonantsInfo;
|
|
38
|
+
export declare function isVowel(character: MāoriCharacter): character is MāoriVowelsInfo;
|
|
39
|
+
export declare function isConsonant(character: MāoriCharacter): character is MāoriConsonantsInfo;
|
|
40
|
+
export declare const māoriVowels: MāoriVowelsInfo[];
|
|
41
|
+
export declare const māoriConsonants: MāoriConsonantsInfo[];
|
|
42
|
+
export declare const māoriAllCharacters: (MāoriVowelsInfo | MāoriConsonantsInfo)[];
|
|
43
|
+
export {};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
function e(a) {
|
|
2
|
+
return a.charType === "vowel";
|
|
3
|
+
}
|
|
4
|
+
function c(a) {
|
|
5
|
+
return a.charType === "consonant";
|
|
6
|
+
}
|
|
7
|
+
const n = [
|
|
8
|
+
// Short vowels
|
|
9
|
+
{ char: "a", id: "a", charType: "vowel", ipa: "a", name: "A", length: "short" },
|
|
10
|
+
{ char: "e", id: "e", charType: "vowel", ipa: "ɛ", name: "E", length: "short" },
|
|
11
|
+
{ char: "i", id: "i", charType: "vowel", ipa: "i", name: "I", length: "short" },
|
|
12
|
+
{ char: "o", id: "o", charType: "vowel", ipa: "ɔ", name: "O", length: "short" },
|
|
13
|
+
{ char: "u", id: "u", charType: "vowel", ipa: "u", name: "U", length: "short" },
|
|
14
|
+
// Long vowels (marked with macron)
|
|
15
|
+
{ char: "ā", id: "a_macron", charType: "vowel", ipa: "aː", name: "Ā", length: "long" },
|
|
16
|
+
{ char: "ē", id: "e_macron", charType: "vowel", ipa: "eː", name: "Ē", length: "long" },
|
|
17
|
+
{ char: "ī", id: "i_macron", charType: "vowel", ipa: "iː", name: "Ī", length: "long" },
|
|
18
|
+
{ char: "ō", id: "o_macron", charType: "vowel", ipa: "oː", name: "Ō", length: "long" },
|
|
19
|
+
{ char: "ū", id: "u_macron", charType: "vowel", ipa: "uː", name: "Ū", length: "long" },
|
|
20
|
+
// Diphthongs
|
|
21
|
+
{ char: "ai", id: "ai", charType: "vowel", ipa: "ai", name: "AI", length: "short" },
|
|
22
|
+
{ char: "ae", id: "ae", charType: "vowel", ipa: "ai", name: "AE", length: "short" },
|
|
23
|
+
{ char: "au", id: "au", charType: "vowel", ipa: "au", name: "AU", length: "short" },
|
|
24
|
+
{ char: "eu", id: "eu", charType: "vowel", ipa: "ɛu", name: "EU", length: "short" },
|
|
25
|
+
{ char: "iu", id: "iu", charType: "vowel", ipa: "iu", name: "IU", length: "short" }
|
|
26
|
+
], i = [
|
|
27
|
+
// Bilabial consonants
|
|
28
|
+
{ char: "b", id: "b", charType: "consonant", ipa: "b", name: "B", voicing: "voiced", articulation: "stop", place: "labial" },
|
|
29
|
+
{ char: "p", id: "p", charType: "consonant", ipa: "p", name: "P", voicing: "voiceless", articulation: "stop", place: "labial" },
|
|
30
|
+
{ char: "m", id: "m", charType: "consonant", ipa: "m", name: "M", voicing: "nasal", articulation: "nasal", place: "labial" },
|
|
31
|
+
// Dental/Alveolar consonants
|
|
32
|
+
{ char: "t", id: "t", charType: "consonant", ipa: "t", name: "T", voicing: "voiceless", articulation: "stop", place: "dental" },
|
|
33
|
+
{ char: "d", id: "d", charType: "consonant", ipa: "d", name: "D", voicing: "voiced", articulation: "stop", place: "dental" },
|
|
34
|
+
{ char: "n", id: "n", charType: "consonant", ipa: "n", name: "N", voicing: "nasal", articulation: "nasal", place: "alveolar" },
|
|
35
|
+
{ char: "r", id: "r", charType: "consonant", ipa: "r", name: "R", voicing: "trill", articulation: "trill", place: "alveolar" },
|
|
36
|
+
{ char: "l", id: "l", charType: "consonant", ipa: "l", name: "L", voicing: "lateral", articulation: "lateral", place: "alveolar" },
|
|
37
|
+
// Velar consonants
|
|
38
|
+
{ char: "k", id: "k", charType: "consonant", ipa: "k", name: "K", voicing: "voiceless", articulation: "stop", place: "velar" },
|
|
39
|
+
{ char: "g", id: "g", charType: "consonant", ipa: "ɡ", name: "G", voicing: "voiced", articulation: "stop", place: "velar" },
|
|
40
|
+
{ char: "ng", id: "ng", charType: "consonant", ipa: "ŋ", name: "NG", voicing: "nasal", articulation: "nasal", place: "velar" },
|
|
41
|
+
{ char: "wh", id: "wh", charType: "consonant", ipa: "f", name: "WH", voicing: "voiceless", articulation: "fricative", place: "labial" },
|
|
42
|
+
{ char: "w", id: "w", charType: "consonant", ipa: "w", name: "W", voicing: "voiced", articulation: "approximant", place: "labial" },
|
|
43
|
+
// Glottal
|
|
44
|
+
{ char: "h", id: "h", charType: "consonant", ipa: "h", name: "H", voicing: "voiceless", articulation: "fricative", place: "glottal" },
|
|
45
|
+
// Other consonants
|
|
46
|
+
{ char: "ng", id: "ngk", charType: "consonant", ipa: "ŋk", name: "NGK", voicing: "nasal", articulation: "stop", place: "velar" }
|
|
47
|
+
], o = [
|
|
48
|
+
...n,
|
|
49
|
+
...i
|
|
50
|
+
];
|
|
51
|
+
export {
|
|
52
|
+
c as isConsonant,
|
|
53
|
+
e as isVowel,
|
|
54
|
+
o as māoriAllCharacters,
|
|
55
|
+
i as māoriConsonants,
|
|
56
|
+
n as māoriVowels
|
|
57
|
+
};
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { māoriVowels, māoriConsonants, māoriAllCharacters, type MāoriVowelsInfo, type MāoriConsonantsInfo, type MāoriCharacter, isVowel, isConsonant, } from './characters.js';
|
package/dist/index.js
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@polyglot-bundles/mi-lang",
|
|
3
|
+
"version": "1.1.2",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"main": "./dist/index.js",
|
|
6
|
+
"types": "./dist/index.d.ts",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"build": "vite build",
|
|
9
|
+
"clean": "rm -rf dist"
|
|
10
|
+
},
|
|
11
|
+
"exports": {
|
|
12
|
+
".": {
|
|
13
|
+
"import": "./dist/index.js",
|
|
14
|
+
"types": "./dist/index.d.ts"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist"
|
|
19
|
+
],
|
|
20
|
+
"publishConfig": {
|
|
21
|
+
"access": "public"
|
|
22
|
+
},
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"@polyglot-bundles/content-shared": "workspace:*"
|
|
25
|
+
},
|
|
26
|
+
"devDependencies": {
|
|
27
|
+
"@polyglot-bundles/lang-tooling": "workspace:*",
|
|
28
|
+
"vite": "catalog:",
|
|
29
|
+
"vite-plugin-dts": "catalog:"
|
|
30
|
+
},
|
|
31
|
+
"repository": {
|
|
32
|
+
"type": "git",
|
|
33
|
+
"url": "git+https://github.com/fustilio/polyglot-bundles.git",
|
|
34
|
+
"directory": "packages/mi/lang"
|
|
35
|
+
}
|
|
36
|
+
}
|