@polyglot-bundles/de-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 +69 -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
|
+
* German Character Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for German characters (Latin script).
|
|
5
|
+
* German has 30 letters: 5 vowels, 21 consonants, and 4 special characters (ä, ö, ü, ß).
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Base character info
|
|
9
|
+
*/
|
|
10
|
+
type GermanCharacterBaseInfo = {
|
|
11
|
+
char: string;
|
|
12
|
+
id: string;
|
|
13
|
+
display?: string;
|
|
14
|
+
audio?: string;
|
|
15
|
+
notes?: string;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* German Vowels
|
|
19
|
+
*/
|
|
20
|
+
export type GermanVowelsInfo = {
|
|
21
|
+
charType: "vowel";
|
|
22
|
+
ipa: string;
|
|
23
|
+
name: string;
|
|
24
|
+
length?: "short" | "long";
|
|
25
|
+
} & GermanCharacterBaseInfo;
|
|
26
|
+
/**
|
|
27
|
+
* German Consonants
|
|
28
|
+
*/
|
|
29
|
+
export type GermanConsonantsInfo = {
|
|
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" | "postalveolar" | "uvular";
|
|
36
|
+
} & GermanCharacterBaseInfo;
|
|
37
|
+
export type GermanCharacter = GermanVowelsInfo | GermanConsonantsInfo;
|
|
38
|
+
export declare function isVowel(character: GermanCharacter): character is GermanVowelsInfo;
|
|
39
|
+
export declare function isConsonant(character: GermanCharacter): character is GermanConsonantsInfo;
|
|
40
|
+
export declare const germanVowels: GermanVowelsInfo[];
|
|
41
|
+
export declare const germanConsonants: GermanConsonantsInfo[];
|
|
42
|
+
export declare const germanAllCharacters: (GermanVowelsInfo | GermanConsonantsInfo)[];
|
|
43
|
+
export {};
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
function e(a) {
|
|
2
|
+
return a.charType === "vowel";
|
|
3
|
+
}
|
|
4
|
+
function c(a) {
|
|
5
|
+
return a.charType === "consonant";
|
|
6
|
+
}
|
|
7
|
+
const i = [
|
|
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: "ɪ", name: "I", length: "short" },
|
|
12
|
+
{ char: "o", id: "o", charType: "vowel", ipa: "ɔ", name: "O", length: "short" },
|
|
13
|
+
{ char: "u", id: "u", charType: "vowel", ipa: "ʊ", name: "U", length: "short" },
|
|
14
|
+
// Long vowels
|
|
15
|
+
{ char: "A", id: "a_long", charType: "vowel", ipa: "aː", name: "A (long)", length: "long" },
|
|
16
|
+
{ char: "E", id: "e_long", charType: "vowel", ipa: "eː", name: "E (long)", length: "long" },
|
|
17
|
+
{ char: "I", id: "i_long", charType: "vowel", ipa: "iː", name: "I (long)", length: "long" },
|
|
18
|
+
{ char: "O", id: "o_long", charType: "vowel", ipa: "oː", name: "O (long)", length: "long" },
|
|
19
|
+
{ char: "U", id: "u_long", charType: "vowel", ipa: "uː", name: "U (long)", length: "long" },
|
|
20
|
+
// Umlaut vowels
|
|
21
|
+
{ char: "ä", id: "ae", charType: "vowel", ipa: "ɛː", name: "Ä", length: "long" },
|
|
22
|
+
{ char: "ö", id: "oe", charType: "vowel", ipa: "øː", name: "Ö", length: "long" },
|
|
23
|
+
{ char: "ü", id: "ue", charType: "vowel", ipa: "yː", name: "Ü", length: "long" },
|
|
24
|
+
// Diphthongs
|
|
25
|
+
{ char: "ai", id: "ai", charType: "vowel", ipa: "aɪ", name: "AI", length: "short" },
|
|
26
|
+
{ char: "au", id: "au", charType: "vowel", ipa: "aʊ", name: "AU", length: "short" },
|
|
27
|
+
{ char: "eu", id: "eu", charType: "vowel", ipa: "ɔʏ", name: "EU", length: "short" },
|
|
28
|
+
{ char: "ei", id: "ei", charType: "vowel", ipa: "aɪ", name: "EI", length: "short" },
|
|
29
|
+
{ char: "ie", id: "ie", charType: "vowel", ipa: "iː", name: "IE", length: "long" }
|
|
30
|
+
], n = [
|
|
31
|
+
// Bilabial consonants
|
|
32
|
+
{ char: "b", id: "b", charType: "consonant", ipa: "b", name: "B", voicing: "voiced", articulation: "stop", place: "labial" },
|
|
33
|
+
{ char: "p", id: "p", charType: "consonant", ipa: "p", name: "P", voicing: "voiceless", articulation: "stop", place: "labial" },
|
|
34
|
+
{ char: "m", id: "m", charType: "consonant", ipa: "m", name: "M", voicing: "nasal", articulation: "nasal", place: "labial" },
|
|
35
|
+
// Labiodental consonants
|
|
36
|
+
{ char: "f", id: "f", charType: "consonant", ipa: "f", name: "F", voicing: "voiceless", articulation: "fricative", place: "labial" },
|
|
37
|
+
{ char: "v", id: "v", charType: "consonant", ipa: "v", name: "V", voicing: "voiced", articulation: "fricative", place: "labial" },
|
|
38
|
+
{ char: "w", id: "w", charType: "consonant", ipa: "v", name: "W", voicing: "voiced", articulation: "approximant", place: "labial" },
|
|
39
|
+
// Dental/Alveolar consonants
|
|
40
|
+
{ char: "t", id: "t", charType: "consonant", ipa: "t", name: "T", voicing: "voiceless", articulation: "stop", place: "dental" },
|
|
41
|
+
{ char: "d", id: "d", charType: "consonant", ipa: "d", name: "D", voicing: "voiced", articulation: "stop", place: "dental" },
|
|
42
|
+
{ char: "s", id: "s", charType: "consonant", ipa: "z", name: "S", voicing: "voiced", articulation: "fricative", place: "alveolar" },
|
|
43
|
+
{ char: "n", id: "n", charType: "consonant", ipa: "n", name: "N", voicing: "nasal", articulation: "nasal", place: "alveolar" },
|
|
44
|
+
{ char: "l", id: "l", charType: "consonant", ipa: "l", name: "L", voicing: "lateral", articulation: "lateral", place: "alveolar" },
|
|
45
|
+
{ char: "r", id: "r", charType: "consonant", ipa: "ʀ", name: "R", voicing: "trill", articulation: "trill", place: "uvular" },
|
|
46
|
+
// Palatal consonants
|
|
47
|
+
{ char: "c", id: "c", charType: "consonant", ipa: "k", name: "C", voicing: "voiceless", articulation: "stop", place: "velar" },
|
|
48
|
+
{ char: "j", id: "j", charType: "consonant", ipa: "j", name: "J", voicing: "voiced", articulation: "approximant", place: "palatal" },
|
|
49
|
+
{ char: "y", id: "y", charType: "consonant", ipa: "j", name: "Y", voicing: "voiced", articulation: "approximant", place: "palatal" },
|
|
50
|
+
// Velar consonants
|
|
51
|
+
{ char: "k", id: "k", charType: "consonant", ipa: "k", name: "K", voicing: "voiceless", articulation: "stop", place: "velar" },
|
|
52
|
+
{ char: "g", id: "g", charType: "consonant", ipa: "ɡ", name: "G", voicing: "voiced", articulation: "stop", place: "velar" },
|
|
53
|
+
{ char: "ch", id: "ch", charType: "consonant", ipa: "ç", name: "CH", voicing: "voiceless", articulation: "fricative", place: "palatal" },
|
|
54
|
+
{ char: "x", id: "x", charType: "consonant", ipa: "ks", name: "X", voicing: "voiceless", articulation: "stop", place: "velar" },
|
|
55
|
+
// Glottal
|
|
56
|
+
{ char: "h", id: "h", charType: "consonant", ipa: "h", name: "H", voicing: "voiceless", articulation: "fricative", place: "glottal" },
|
|
57
|
+
// Eszett (sharp S)
|
|
58
|
+
{ char: "ß", id: "sz", charType: "consonant", ipa: "s", name: "ß", voicing: "voiceless", articulation: "fricative", place: "alveolar" }
|
|
59
|
+
], o = [
|
|
60
|
+
...i,
|
|
61
|
+
...n
|
|
62
|
+
];
|
|
63
|
+
export {
|
|
64
|
+
o as germanAllCharacters,
|
|
65
|
+
n as germanConsonants,
|
|
66
|
+
i as germanVowels,
|
|
67
|
+
c as isConsonant,
|
|
68
|
+
e as isVowel
|
|
69
|
+
};
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { germanVowels, germanConsonants, germanAllCharacters, type GermanVowelsInfo, type GermanConsonantsInfo, type GermanCharacter, isVowel, isConsonant, } from './characters.js';
|
package/dist/index.js
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@polyglot-bundles/de-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/de/lang"
|
|
35
|
+
}
|
|
36
|
+
}
|