cizgile 0.1.0 → 0.2.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.
@@ -0,0 +1,268 @@
1
+ //#region src/uri/charset.ts
2
+ function inChars(chars, cp) {
3
+ return cp < 128 && chars.indexOf(String.fromCodePoint(cp)) !== -1;
4
+ }
5
+ function table(predicate) {
6
+ const out = /* @__PURE__ */ new Uint8Array(128);
7
+ for (let cp = 0; cp < 128; cp++) if (predicate(cp)) out[cp] = 1;
8
+ return out;
9
+ }
10
+ /** RFC 3986 `ALPHA`. */
11
+ function isAlpha(cp) {
12
+ return cp >= 65 && cp <= 90 || cp >= 97 && cp <= 122;
13
+ }
14
+ /** RFC 3986 `DIGIT`. */
15
+ function isDigit(cp) {
16
+ return cp >= 48 && cp <= 57;
17
+ }
18
+ /** RFC 3986 `HEXDIG`, either case. */
19
+ function isHexDigit(cp) {
20
+ return isDigit(cp) || cp >= 65 && cp <= 70 || cp >= 97 && cp <= 102;
21
+ }
22
+ /** Whether `text` is a valid RFC 3986 `scheme`: a letter followed by letters, digits, `+`, `-` or `.`. */
23
+ function isScheme(text) {
24
+ return /^[A-Za-z][A-Za-z0-9+.-]*$/.test(text);
25
+ }
26
+ const UNRESERVED = /* @__PURE__ */ table((cp) => isAlpha(cp) || isDigit(cp) || inChars("-._~", cp));
27
+ const GEN_DELIMS = /* @__PURE__ */ table((cp) => inChars(":/?#[]@", cp));
28
+ const SUB_DELIMS = /* @__PURE__ */ table((cp) => inChars("!$&'()*+,;=", cp));
29
+ const PCHAR = /* @__PURE__ */ table((cp) => UNRESERVED[cp] === 1 || SUB_DELIMS[cp] === 1 || cp === 58 || cp === 64);
30
+ const SEGMENT_NZ_NC = /* @__PURE__ */ table((cp) => UNRESERVED[cp] === 1 || SUB_DELIMS[cp] === 1 || cp === 64);
31
+ const QUERY = /* @__PURE__ */ table((cp) => PCHAR[cp] === 1 || cp === 47 || cp === 63);
32
+ /** RFC 3986 section 2.3 `unreserved`: letters, digits, `- . _ ~`. */
33
+ function isUnreserved(cp) {
34
+ return cp < 128 && UNRESERVED[cp] === 1;
35
+ }
36
+ /** RFC 3986 section 2.2 `gen-delims`: `: / ? # [ ] @`. */
37
+ function isGenDelim(cp) {
38
+ return cp < 128 && GEN_DELIMS[cp] === 1;
39
+ }
40
+ /** RFC 3986 section 2.2 `sub-delims`: `! $ & ' ( ) * + , ; =`. */
41
+ function isSubDelim(cp) {
42
+ return cp < 128 && SUB_DELIMS[cp] === 1;
43
+ }
44
+ /** RFC 3986 section 2.2 `reserved`: `gen-delims` or `sub-delims`. */
45
+ function isReserved(cp) {
46
+ return isGenDelim(cp) || isSubDelim(cp);
47
+ }
48
+ /** RFC 3986 section 3.3 `pchar` less `pct-encoded`: `unreserved`, `sub-delims`, `:` or `@`. */
49
+ function isPchar(cp) {
50
+ return cp < 128 && PCHAR[cp] === 1;
51
+ }
52
+ /** RFC 3986 section 3.3 `segment-nz-nc` character: `pchar` without the colon. */
53
+ function isSegmentNzNc(cp) {
54
+ return cp < 128 && SEGMENT_NZ_NC[cp] === 1;
55
+ }
56
+ /** A character allowed unencoded in a `query` or `fragment`: `pchar`, `/` or `?`. */
57
+ function isQueryChar(cp) {
58
+ return cp < 128 && QUERY[cp] === 1;
59
+ }
60
+ function isWhatwgC0Safe(cp) {
61
+ return cp >= 32 && cp <= 126;
62
+ }
63
+ function isWhatwgFragmentSafe(cp) {
64
+ return cp >= 33 && cp <= 126 && !inChars("\"<>`", cp);
65
+ }
66
+ function isWhatwgQuerySafe(cp) {
67
+ return cp >= 33 && cp <= 126 && !inChars("\"#<>", cp);
68
+ }
69
+ function isWhatwgSpecialQuerySafe(cp) {
70
+ return isWhatwgQuerySafe(cp) && cp !== 39;
71
+ }
72
+ function isWhatwgPathSafe(cp) {
73
+ return isWhatwgQuerySafe(cp) && !inChars("?^`{}", cp);
74
+ }
75
+ function isWhatwgUserinfoSafe(cp) {
76
+ return isWhatwgPathSafe(cp) && !inChars("/:;=@[\\]|", cp);
77
+ }
78
+ function isWhatwgComponentSafe(cp) {
79
+ return isWhatwgUserinfoSafe(cp) && !inChars("$&+,", cp);
80
+ }
81
+ function isFormSafe(cp) {
82
+ return isAlpha(cp) || isDigit(cp) || inChars("*-._", cp);
83
+ }
84
+ const SETS = {
85
+ unreserved: isUnreserved,
86
+ pchar: isPchar,
87
+ "segment-nz-nc": isSegmentNzNc,
88
+ path: (cp) => isPchar(cp) || cp === 47,
89
+ query: isQueryChar,
90
+ fragment: isQueryChar,
91
+ userinfo: (cp) => isUnreserved(cp) || isSubDelim(cp) || cp === 58,
92
+ "whatwg-c0-control": isWhatwgC0Safe,
93
+ "whatwg-fragment": isWhatwgFragmentSafe,
94
+ "whatwg-query": isWhatwgQuerySafe,
95
+ "whatwg-special-query": isWhatwgSpecialQuerySafe,
96
+ "whatwg-path": isWhatwgPathSafe,
97
+ "whatwg-userinfo": isWhatwgUserinfoSafe,
98
+ "whatwg-component": isWhatwgComponentSafe,
99
+ form: isFormSafe
100
+ };
101
+ /** The predicate behind a named keep-set, or the predicate itself. */
102
+ function resolveEncodeSet(set) {
103
+ return typeof set === "function" ? set : SETS[set];
104
+ }
105
+ let tablePredicates;
106
+ function keepPredicate(set) {
107
+ if (typeof set === "function") return set;
108
+ tablePredicates ??= /* @__PURE__ */ new Map();
109
+ let out = tablePredicates.get(set);
110
+ if (out === void 0) {
111
+ const safe = table(SETS[set]);
112
+ out = (cp) => cp < 128 && safe[cp] === 1;
113
+ tablePredicates.set(set, out);
114
+ }
115
+ return out;
116
+ }
117
+
118
+ //#endregion
119
+ //#region src/uri/utf8.ts
120
+ const HEX = "0123456789ABCDEF";
121
+ const HEX_BYTES = [];
122
+ for (let byte = 0; byte < 256; byte++) HEX_BYTES.push("%" + HEX[byte >> 4] + HEX[byte & 15]);
123
+ const NIBBLES = (/* @__PURE__ */ new Int8Array(128)).fill(-1);
124
+ for (let i = 0; i < 16; i++) {
125
+ NIBBLES[HEX.codePointAt(i) ?? 0] = i;
126
+ NIBBLES[HEX.toLowerCase().codePointAt(i) ?? 0] = i;
127
+ }
128
+ function hexByte(byte) {
129
+ return HEX_BYTES[byte] ?? "";
130
+ }
131
+ function encodeUtf8(codePoint) {
132
+ const cp = codePoint >= 55296 && codePoint <= 57343 ? 65533 : codePoint;
133
+ if (cp < 128) return hexByte(cp);
134
+ if (cp < 2048) return hexByte(192 | cp >> 6) + hexByte(128 | cp & 63);
135
+ if (cp < 65536) return hexByte(224 | cp >> 12) + hexByte(128 | cp >> 6 & 63) + hexByte(128 | cp & 63);
136
+ return hexByte(240 | cp >> 18) + hexByte(128 | cp >> 12 & 63) + hexByte(128 | cp >> 6 & 63) + hexByte(128 | cp & 63);
137
+ }
138
+ function isContinuation(byte) {
139
+ return byte !== void 0 && (byte & 192) === 128;
140
+ }
141
+ function readUtf8(bytes, index) {
142
+ const b0 = bytes[index];
143
+ if (b0 === void 0) return void 0;
144
+ if (b0 < 128) return {
145
+ codePoint: b0,
146
+ length: 1
147
+ };
148
+ const b1 = bytes[index + 1];
149
+ if (b0 >= 194 && b0 <= 223) {
150
+ if (!isContinuation(b1)) return void 0;
151
+ return {
152
+ codePoint: (b0 & 31) << 6 | b1 & 63,
153
+ length: 2
154
+ };
155
+ }
156
+ const b2 = bytes[index + 2];
157
+ if (b0 >= 224 && b0 <= 239) {
158
+ if (!isContinuation(b1) || !isContinuation(b2)) return void 0;
159
+ if (b0 === 224 && b1 < 160) return void 0;
160
+ if (b0 === 237 && b1 > 159) return void 0;
161
+ return {
162
+ codePoint: (b0 & 15) << 12 | (b1 & 63) << 6 | b2 & 63,
163
+ length: 3
164
+ };
165
+ }
166
+ const b3 = bytes[index + 3];
167
+ if (b0 >= 240 && b0 <= 244) {
168
+ if (!isContinuation(b1) || !isContinuation(b2) || !isContinuation(b3)) return void 0;
169
+ if (b0 === 240 && b1 < 144) return void 0;
170
+ if (b0 === 244 && b1 > 143) return void 0;
171
+ return {
172
+ codePoint: (b0 & 7) << 18 | (b1 & 63) << 12 | (b2 & 63) << 6 | b3 & 63,
173
+ length: 4
174
+ };
175
+ }
176
+ }
177
+ function nibble(code) {
178
+ return code !== void 0 && code < 128 ? NIBBLES[code] ?? -1 : -1;
179
+ }
180
+ function readHexByte(input, index) {
181
+ if (input.codePointAt(index) !== 37) return -1;
182
+ const hi = nibble(input.codePointAt(index + 1));
183
+ const lo = nibble(input.codePointAt(index + 2));
184
+ return hi < 0 || lo < 0 ? -1 : hi * 16 + lo;
185
+ }
186
+
187
+ //#endregion
188
+ //#region src/uri/percent.ts
189
+ /** Percent-encodes `input` as UTF-8 with uppercase hex, leaving the characters `keep` names untouched; `"form"` also turns spaces into `+`. */
190
+ function percentEncode(input, keep = "unreserved") {
191
+ const keepFn = keepPredicate(keep);
192
+ const plusForSpace = keep === "form";
193
+ const length = input.length;
194
+ let i = 0;
195
+ while (i < length) {
196
+ const code = input.codePointAt(i) ?? 0;
197
+ if (code >= 128 || !keepFn(code)) break;
198
+ i += 1;
199
+ }
200
+ if (i === length) return input;
201
+ let out = input.slice(0, i);
202
+ for (const ch of input.slice(i)) {
203
+ const cp = ch.codePointAt(0) ?? 0;
204
+ if (cp < 128 && keepFn(cp)) out += ch;
205
+ else if (plusForSpace && cp === 32) out += "+";
206
+ else out += encodeUtf8(cp);
207
+ }
208
+ return out;
209
+ }
210
+ function decodeBytes(bytes) {
211
+ let out = "";
212
+ let i = 0;
213
+ while (i < bytes.length) {
214
+ const char = readUtf8(bytes, i);
215
+ if (char === void 0) {
216
+ out += "�";
217
+ i += 1;
218
+ } else {
219
+ out += String.fromCodePoint(char.codePoint);
220
+ i += char.length;
221
+ }
222
+ }
223
+ return out;
224
+ }
225
+ /** Decodes every `%XX` sequence as UTF-8; malformed bytes become U+FFFD and lone `%` is kept. */
226
+ function percentDecode(input, options = {}) {
227
+ if (!input.includes("%") && !(options.plusAsSpace === true && input.includes("+"))) return input;
228
+ let out = "";
229
+ let i = 0;
230
+ const bytes = [];
231
+ while (i < input.length) {
232
+ const byte = readHexByte(input, i);
233
+ if (byte !== -1) {
234
+ bytes.push(byte);
235
+ i += 3;
236
+ continue;
237
+ }
238
+ if (bytes.length > 0) {
239
+ out += decodeBytes(bytes);
240
+ bytes.length = 0;
241
+ }
242
+ const ch = input.charAt(i);
243
+ out += options.plusAsSpace && ch === "+" ? " " : ch;
244
+ i += 1;
245
+ }
246
+ if (bytes.length > 0) out += decodeBytes(bytes);
247
+ return out;
248
+ }
249
+ /** RFC 3986 section 6.2.2.2: decodes percent-encoded `unreserved` characters and uppercases the hex of the rest. */
250
+ function normalizePercentEncoding(input) {
251
+ if (!input.includes("%")) return input;
252
+ let out = "";
253
+ let i = 0;
254
+ while (i < input.length) {
255
+ const byte = readHexByte(input, i);
256
+ if (byte === -1) {
257
+ out += input.charAt(i);
258
+ i += 1;
259
+ } else {
260
+ out += isUnreserved(byte) ? String.fromCodePoint(byte) : hexByte(byte);
261
+ i += 3;
262
+ }
263
+ }
264
+ return out;
265
+ }
266
+
267
+ //#endregion
268
+ export { isUnreserved as _, readHexByte as a, isDigit as c, isPchar as d, isQueryChar as f, isSubDelim as g, isSegmentNzNc as h, encodeUtf8 as i, isGenDelim as l, isScheme as m, percentDecode as n, readUtf8 as o, isReserved as p, percentEncode as r, isAlpha as s, normalizePercentEncoding as t, isHexDigit as u, resolveEncodeSet as v };
@@ -0,0 +1,24 @@
1
+ //#region src/transliterate/types.d.ts
2
+ /** Maps a character or character sequence to its ASCII spelling. */
3
+ type TransliterationTable = Readonly<Record<string, string>>;
4
+ /** Language rules: a table applied first, the script tables the language needs, and optionally its own lowercasing. */
5
+ interface Locale {
6
+ /** BCP 47 language tag such as `"de"` or `"de-CH"`. */
7
+ readonly id: string;
8
+ /** Letter and symbol replacements specific to the language, applied before every other table. */
9
+ readonly table: TransliterationTable;
10
+ /** Script tables the language is written in, such as `cyrillic` for Russian. */
11
+ readonly tables?: readonly TransliterationTable[];
12
+ /** Language-aware lowercasing for unicode slugs, such as the Turkish dotted and dotless i. */
13
+ readonly lowercase?: (input: string) => string;
14
+ }
15
+ /** Locale ids `slugify` accepts as strings; their tables ship with the main entry. */
16
+ type LatinLocaleId = "az" | "ca" | "cs" | "da" | "de" | "es" | "et" | "fi" | "fr" | "hr" | "hu" | "is" | "it" | "lt" | "lv" | "nb" | "nl" | "pl" | "pt" | "ro" | "sk" | "sl" | "sv" | "tr" | "vi";
17
+ /** Locales that carry the Cyrillic table; import the objects from `cizgile/transliterate`. */
18
+ type CyrillicLocaleId = "be" | "bg" | "kk" | "mk" | "ru" | "sr" | "uk";
19
+ /** Locales that carry the Greek, Hebrew, kana or Hangul table; import the objects from `cizgile/transliterate`. */
20
+ type OtherLocaleId = "el" | "he" | "ja" | "ko";
21
+ /** Every id in the `locales` registry. */
22
+ type LocaleId = LatinLocaleId | CyrillicLocaleId | OtherLocaleId;
23
+ //#endregion
24
+ export { OtherLocaleId as a, LocaleId as i, LatinLocaleId as n, TransliterationTable as o, Locale as r, CyrillicLocaleId as t };
@@ -1,85 +1,199 @@
1
- import { a as TransliterationTable, i as LocaleId, n as LatinLocaleId, r as Locale, t as CyrillicLocaleId } from "./shared/types-C1iMvUXh.mjs";
2
- //#region src/transliterate/arabic.d.ts
3
- export declare const arabic: TransliterationTable;
4
- export declare const persian: TransliterationTable;
5
- export declare const urdu: TransliterationTable;
6
- export declare const pashto: TransliterationTable;
7
- //#endregion
8
- //#region src/transliterate/armenian.d.ts
9
- export declare const armenian: TransliterationTable;
10
- //#endregion
1
+ import { a as OtherLocaleId, i as LocaleId, n as LatinLocaleId, o as TransliterationTable, r as Locale, t as CyrillicLocaleId } from "./shared/types-DbyhfPRc.mjs";
11
2
  //#region src/transliterate/core.d.ts
3
+ /** Options for `transliterate`. */
12
4
  interface TransliterateOptions {
5
+ /** Language rules consulted before the tables. */
13
6
  readonly locale?: Locale;
7
+ /** Extra script tables, consulted before the Latin and symbol defaults. */
14
8
  readonly tables?: readonly TransliterationTable[];
9
+ /** What happens to characters no table covers; `"keep"` by default. */
15
10
  readonly unknown?: "keep" | "drop";
11
+ /** Folds compatibility characters first (ligatures, superscripts, circled digits), as `slugify` does; `false` by default. */
12
+ readonly nfkc?: boolean;
16
13
  }
14
+ /** The tables every call consults last: `latin`, then `symbols`. */
17
15
  export declare const DEFAULT_TABLES: readonly TransliterationTable[];
16
+ type Sequences = ReadonlyArray<readonly [string, string]>;
17
+ interface CompiledTables {
18
+ readonly map: ReadonlyMap<string, string>;
19
+ readonly sequences: Sequences;
20
+ readonly ascii: RegExp | undefined;
21
+ readonly folded: Map<string, string | null>;
22
+ }
23
+ /** The table list a `transliterate` call would consult, in lookup order. */
18
24
  export declare function resolveTables(options: TransliterateOptions): readonly TransliterationTable[];
25
+ /** The first table value for `key`, or `undefined`. */
19
26
  export declare function lookup(tables: readonly TransliterationTable[], key: string): string | undefined;
27
+ /** Removes combining marks: `"é"` becomes `"e"`, `"ǿ"` becomes `"ø"`. */
20
28
  export declare function stripMarks(input: string): string;
21
- export declare function fold(input: string, tables: readonly TransliterationTable[], dropUnknown: boolean, foldMarks?: boolean): string;
29
+ /** The transliteration core: applies `tables` to NFC text, folding marks unless told not to. */
30
+ export declare function fold(input: string, tables: readonly TransliterationTable[] | CompiledTables, dropUnknown: boolean, foldMarks?: boolean): string;
31
+ /** Replaces non-ASCII letters with ASCII from the tables and the mark-stripping fallback. Characters no table knows are kept whole, marks included, or dropped with `unknown: "drop"`. */
22
32
  export declare function transliterate(input: string, options?: TransliterateOptions): string;
23
33
  //#endregion
34
+ //#region src/transliterate/arabic.d.ts
35
+ /** Arabic letters to Latin; short vowels are marks and fall away. */
36
+ export declare const arabic: TransliterationTable;
37
+ /** Persian letters that differ from Arabic: `پ چ ژ گ` and the Persian yeh and kaf. */
38
+ export declare const persian: TransliterationTable;
39
+ /** Urdu letters that differ from Arabic: `ٹ ڈ ڑ ں ے`. */
40
+ export declare const urdu: TransliterationTable;
41
+ /** Pashto letters that differ from Arabic: `ټ ډ ړ ږ ښ ڼ`. */
42
+ export declare const pashto: TransliterationTable;
43
+ //#endregion
44
+ //#region src/transliterate/armenian.d.ts
45
+ /** Armenian to Latin; `ե` and `ո` take their word-initial spelling on the capital. */
46
+ export declare const armenian: TransliterationTable;
47
+ //#endregion
24
48
  //#region src/transliterate/cyrillic.d.ts
49
+ /** Cyrillic to Latin, the simov/slugify values, covering Russian, Kazakh, Belarusian and the other national alphabets. */
25
50
  export declare const cyrillic: TransliterationTable;
51
+ /** Ukrainian refinements: `г` is `h`, `и` is `y`, `є ї й ю я` take their word-initial spelling on the capital. */
26
52
  export declare const cyrillicUk: TransliterationTable;
53
+ /** Bulgarian refinements: `щ` is `sht`, `ъ` is `a`. */
27
54
  export declare const cyrillicBg: TransliterationTable;
55
+ /** Macedonian refinements: `ѓ ќ ѕ џ љ њ`. */
28
56
  export declare const cyrillicMk: TransliterationTable;
57
+ /** Serbian refinements: `ђ ћ џ љ њ`, `х` is `h`. */
29
58
  export declare const cyrillicSr: TransliterationTable;
30
59
  //#endregion
31
60
  //#region src/transliterate/define.d.ts
61
+ /** What `defineLocale` may change; every field is optional. */
32
62
  interface LocaleOverrides {
63
+ /** Replaces the base id, such as `"de-CH"`. */
33
64
  readonly id?: string;
65
+ /** Merged over the base table; later keys win. */
34
66
  readonly table?: TransliterationTable;
67
+ /** Replaces the base script tables. */
35
68
  readonly tables?: readonly TransliterationTable[];
69
+ /** Replaces the base lowercasing function. */
36
70
  readonly lowercase?: (input: string) => string;
37
71
  }
72
+ /** One table from many; later tables win. Returns a new object. */
38
73
  export declare function mergeTables(...tables: readonly TransliterationTable[]): TransliterationTable;
74
+ /** A new locale from `base` with `overrides` merged in; neither object is mutated. */
39
75
  export declare function defineLocale(base: Locale, overrides?: LocaleOverrides): Locale;
40
76
  //#endregion
41
77
  //#region src/transliterate/dhivehi.d.ts
78
+ /** Thaana (Dhivehi) to Latin, the sindresorhus/transliterate values. */
42
79
  export declare const dhivehi: TransliterationTable;
43
80
  //#endregion
44
81
  //#region src/transliterate/georgian.d.ts
82
+ /** Georgian Mkhedruli to Latin. */
45
83
  export declare const georgian: TransliterationTable;
46
84
  //#endregion
47
85
  //#region src/transliterate/greek.d.ts
86
+ /** Modern Greek to Latin: `η` and `ι` are `i`, `β` is `v`, `θ` is `th`. */
48
87
  export declare const greek: TransliterationTable;
49
88
  //#endregion
89
+ //#region src/transliterate/hangul.d.ts
90
+ /** Hangul jamo to Revised Romanization, jamo by jamo; precomposed syllables reach it through NFD, with no sound-change rules across syllables. */
91
+ export declare const hangul: TransliterationTable;
92
+ //#endregion
93
+ //#region src/transliterate/hebrew.d.ts
94
+ /** Hebrew consonants to Latin, final forms and Yiddish ligatures included; vowel points fall away. */
95
+ export declare const hebrew: TransliterationTable;
96
+ //#endregion
97
+ //#region src/transliterate/kana.d.ts
98
+ /** Hiragana and katakana to Hepburn, digraphs and foreign-sound combinations included; the long-vowel mark and sokuon are dropped, kanji is left alone. */
99
+ export declare const kana: TransliterationTable;
100
+ //#endregion
50
101
  //#region src/transliterate/latin.d.ts
102
+ /** Latin letters with no decomposition (`ß`, `Æ`, `Ł`, `Þ`, `Ə`, ...) and the modifier letters that are dropped. */
51
103
  export declare const latin: TransliterationTable;
52
104
  //#endregion
53
105
  //#region src/transliterate/locales-cyrillic.d.ts
106
+ /** Russian: the Cyrillic table, `&` becomes `i`. */
54
107
  export declare const ru: Locale;
108
+ /** Ukrainian: the Ukrainian overlay on the Cyrillic table, `&` becomes `ta`. */
55
109
  export declare const uk: Locale;
110
+ /** Bulgarian: the Bulgarian overlay on the Cyrillic table, `&` becomes `i`. */
56
111
  export declare const bg: Locale;
112
+ /** Macedonian: the Macedonian overlay on the Cyrillic table, `&` becomes `i`. */
57
113
  export declare const mk: Locale;
114
+ /** Serbian: the Serbian overlay on the Cyrillic table, Latin `đ` becomes `dj`, `&` becomes `i`. */
58
115
  export declare const sr: Locale;
116
+ /** Kazakh: the Cyrillic table, `&` becomes `zhane`. */
117
+ export declare const kk: Locale;
118
+ /** Belarusian: the Cyrillic table, `&` becomes `i`. */
119
+ export declare const be: Locale;
120
+ /** The Cyrillic-script locales by id. */
59
121
  export declare const cyrillicLocales: Readonly<Record<CyrillicLocaleId, Locale>>;
60
122
  //#endregion
123
+ //#region src/transliterate/locales-other.d.ts
124
+ /** Greek: the Greek table, `&` becomes `kai`. */
125
+ export declare const el: Locale;
126
+ /** Hebrew: the Hebrew table, `&` becomes `ve`. */
127
+ export declare const he: Locale;
128
+ /** Japanese: the kana table, `&` becomes `to`; kanji is left alone. */
129
+ export declare const ja: Locale;
130
+ /** Korean: the Hangul table, `&` becomes `mit`. */
131
+ export declare const ko: Locale;
132
+ /** The Greek, Hebrew, Japanese and Korean locales by id. */
133
+ export declare const otherLocales: Readonly<Record<OtherLocaleId, Locale>>;
134
+ //#endregion
61
135
  //#region src/transliterate/locales-latin.d.ts
136
+ /** German: `ä ö ü` become `ae oe ue`, `ß` becomes `ss`, `&` becomes `und`. */
62
137
  export declare const de: Locale;
138
+ /** Turkish: dotted and dotless i, `ğ ş ç ö ü` stripped, `&` becomes `ve`; lowercases with the Turkish rules. */
63
139
  export declare const tr: Locale;
140
+ /** Azerbaijani: the Turkish letters plus `ə`, `&` becomes `ve`. */
64
141
  export declare const az: Locale;
142
+ /** Danish: `ø å æ` become `oe aa ae`, `&` becomes `og`. */
65
143
  export declare const da: Locale;
144
+ /** Norwegian Bokmål: `ø å æ` become `oe aa ae`, `&` becomes `og`. */
66
145
  export declare const nb: Locale;
146
+ /** Swedish: `ä ö å` become `ae oe aa`, `&` becomes `och`. */
67
147
  export declare const sv: Locale;
148
+ /** Finnish: `ä ö å` become `ae oe aa`, `&` becomes `ja`. */
68
149
  export declare const fi: Locale;
150
+ /** Hungarian: `&` becomes `es`. */
69
151
  export declare const hu: Locale;
152
+ /** Vietnamese: `đ` becomes `d`, `&` becomes `va`. */
70
153
  export declare const vi: Locale;
154
+ /** Spanish: `ñ` becomes `n`, `&` becomes `y`. */
71
155
  export declare const es: Locale;
156
+ /** French: `œ æ` become `oe ae`, `&` becomes `et`. */
72
157
  export declare const fr: Locale;
158
+ /** Portuguese: `&` becomes `e`. */
73
159
  export declare const pt: Locale;
160
+ /** Italian: `&` becomes `e`. */
74
161
  export declare const it: Locale;
162
+ /** Dutch: `ij` becomes `ij`, `&` becomes `en`. */
75
163
  export declare const nl: Locale;
164
+ /** Polish: `&` becomes `i`. */
165
+ export declare const pl: Locale;
166
+ /** Romanian: `&` becomes `si`. */
167
+ export declare const ro: Locale;
168
+ /** Czech: `&` becomes `a`. */
169
+ export declare const cs: Locale;
170
+ /** Slovak: `&` becomes `a`. */
171
+ export declare const sk: Locale;
172
+ /** Slovenian: `&` becomes `in`. */
173
+ export declare const sl: Locale;
174
+ /** Croatian: `&` becomes `i`. */
175
+ export declare const hr: Locale;
176
+ /** Icelandic: `þ ð` become `th d`, `&` becomes `og`. */
177
+ export declare const is: Locale;
178
+ /** Estonian: `&` becomes `ja`. */
179
+ export declare const et: Locale;
180
+ /** Latvian: `&` becomes `un`. */
181
+ export declare const lv: Locale;
182
+ /** Lithuanian: `&` becomes `ir`. */
183
+ export declare const lt: Locale;
184
+ /** Catalan: the punt volat in `l·l` is dropped, `&` becomes `i`. */
185
+ export declare const ca: Locale;
186
+ /** The Latin-script locales by id; these ship with the main entry. */
76
187
  export declare const latinLocales: Readonly<Record<LatinLocaleId, Locale>>;
77
188
  //#endregion
78
189
  //#region src/transliterate/symbols.d.ts
190
+ /** Symbols spelled out in English (`&`, `©`, currency signs) or turned into separators (dashes, quotes, bullets). */
79
191
  export declare const symbols: TransliterationTable;
80
192
  //#endregion
81
193
  //#region src/transliterate.d.ts
194
+ /** Every script table; pass as `tables` when the input language is unknown. */
82
195
  export declare const allScripts: readonly TransliterationTable[];
196
+ /** Every locale object by id. */
83
197
  export declare const locales: Readonly<Record<LocaleId, Locale>>;
84
198
  //#endregion
85
- export type { CyrillicLocaleId, LatinLocaleId, Locale, LocaleId, LocaleOverrides, TransliterateOptions, TransliterationTable };
199
+ export type { CyrillicLocaleId, LatinLocaleId, Locale, LocaleId, LocaleOverrides, OtherLocaleId, TransliterateOptions, TransliterationTable };