rx-player 3.33.1 → 3.33.3
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/CHANGELOG.md +1080 -1129
- package/VERSION +1 -1
- package/dist/_esm5.processed/compat/can_rely_on_request_media_key_system_access.d.ts +34 -0
- package/dist/_esm5.processed/compat/can_rely_on_request_media_key_system_access.js +40 -0
- package/dist/_esm5.processed/compat/generate_init_data.d.ts +14 -0
- package/dist/_esm5.processed/compat/generate_init_data.js +61 -0
- package/dist/_esm5.processed/compat/may_media_element_fail_on_undecipherable_data.d.ts +16 -0
- package/dist/_esm5.processed/compat/may_media_element_fail_on_undecipherable_data.js +17 -0
- package/dist/_esm5.processed/compat/should_wait_for_data_before_loaded.d.ts +1 -1
- package/dist/_esm5.processed/compat/should_wait_for_data_before_loaded.js +5 -3
- package/dist/_esm5.processed/config.d.ts +2 -0
- package/dist/_esm5.processed/core/adaptive/adaptive_representation_selector.js +1 -1
- package/dist/_esm5.processed/core/api/debug/buffer_graph.js +3 -3
- package/dist/_esm5.processed/core/api/public_api.d.ts +17 -0
- package/dist/_esm5.processed/core/api/public_api.js +41 -2
- package/dist/_esm5.processed/core/api/tracks_management/media_element_track_choice_manager.js +21 -25
- package/dist/_esm5.processed/core/decrypt/attach_media_keys.js +6 -6
- package/dist/_esm5.processed/core/decrypt/find_key_system.d.ts +10 -0
- package/dist/_esm5.processed/core/decrypt/find_key_system.js +42 -1
- package/dist/_esm5.processed/core/decrypt/session_events_listener.js +2 -2
- package/dist/_esm5.processed/core/fetchers/manifest/manifest_fetcher.js +2 -2
- package/dist/_esm5.processed/core/fetchers/segment/segment_fetcher.js +1 -1
- package/dist/_esm5.processed/core/init/media_source_content_initializer.js +34 -12
- package/dist/_esm5.processed/core/init/utils/get_loaded_reference.js +6 -1
- package/dist/_esm5.processed/core/init/utils/initial_seek_and_play.js +4 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/audio_video/audio_video_segment_buffer.js +24 -25
- package/dist/_esm5.processed/core/segment_buffers/implementations/image/image_segment_buffer.js +1 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/html_text_segment_buffer.js +1 -1
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/text_track_cues_store.js +2 -2
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.d.ts +15 -0
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/html/utils.js +23 -0
- package/dist/_esm5.processed/core/segment_buffers/implementations/text/native/native_text_segment_buffer.js +1 -1
- package/dist/_esm5.processed/core/segment_buffers/inventory/segment_inventory.d.ts +18 -4
- package/dist/_esm5.processed/core/segment_buffers/inventory/segment_inventory.js +57 -13
- package/dist/_esm5.processed/core/stream/adaptation/adaptation_stream.js +3 -0
- package/dist/_esm5.processed/core/stream/representation/utils/append_segment_to_buffer.js +15 -8
- package/dist/_esm5.processed/core/stream/representation/utils/get_buffer_status.js +1 -37
- package/dist/_esm5.processed/core/stream/representation/utils/get_needed_segments.js +19 -11
- package/dist/_esm5.processed/core/stream/representation/utils/push_init_segment.js +6 -6
- package/dist/_esm5.processed/core/stream/representation/utils/push_media_segment.js +9 -9
- package/dist/_esm5.processed/default_config.d.ts +31 -0
- package/dist/_esm5.processed/default_config.js +48 -17
- package/dist/_esm5.processed/errors/assertion_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/assertion_error.js +1 -2
- package/dist/_esm5.processed/errors/custom_loader_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/custom_loader_error.js +1 -2
- package/dist/_esm5.processed/errors/encrypted_media_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/encrypted_media_error.js +1 -2
- package/dist/_esm5.processed/errors/media_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/media_error.js +1 -2
- package/dist/_esm5.processed/errors/network_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/network_error.js +1 -2
- package/dist/_esm5.processed/errors/other_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/other_error.js +1 -2
- package/dist/_esm5.processed/errors/request_error.d.ts +0 -1
- package/dist/_esm5.processed/errors/request_error.js +17 -15
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader_error.d.ts +0 -1
- package/dist/_esm5.processed/experimental/tools/VideoThumbnailLoader/video_thumbnail_loader_error.js +2 -2
- package/dist/_esm5.processed/experimental/tools/createMetaplaylist/get_duration_from_manifest.js +1 -1
- package/dist/_esm5.processed/experimental/tools/mediaCapabilitiesProber/probers/decodingInfo.js +4 -4
- package/dist/_esm5.processed/parsers/containers/isobmff/utils.js +3 -1
- package/dist/_esm5.processed/parsers/manifest/dash/common/indexes/timeline/timeline_representation_index.js +1 -3
- package/dist/_esm5.processed/parsers/manifest/dash/common/parse_representation_index.js +9 -5
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.d.ts +0 -1
- package/dist/_esm5.processed/parsers/manifest/dash/js-parser/node_parsers/utils.js +1 -2
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentComponent.js +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/ContentProtection.js +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.d.ts +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/generators/Scheme.js +1 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/parsers_stack.d.ts +2 -1
- package/dist/_esm5.processed/parsers/manifest/dash/wasm-parser/ts/types.d.ts +55 -55
- package/dist/_esm5.processed/parsers/manifest/smooth/parse_protection_node.js +1 -1
- package/dist/_esm5.processed/transports/dash/extract_complete_chunks.d.ts +1 -1
- package/dist/_esm5.processed/transports/dash/extract_complete_chunks.js +6 -2
- package/dist/_esm5.processed/transports/dash/low_latency_segment_loader.js +4 -2
- package/dist/_esm5.processed/utils/languages/ISO_639-1_to_ISO_639-3.js +182 -182
- package/dist/_esm5.processed/utils/languages/ISO_639-2_to_ISO_639-3.js +19 -19
- package/dist/_esm5.processed/utils/languages/normalize.js +4 -1
- package/dist/_esm5.processed/utils/resolve_url.d.ts +13 -10
- package/dist/_esm5.processed/utils/resolve_url.js +220 -69
- package/dist/_esm5.processed/utils/string_parsing.d.ts +1 -1
- package/dist/_esm5.processed/utils/string_parsing.js +1 -1
- package/dist/_esm5.processed/utils/task_canceller.d.ts +0 -1
- package/dist/_esm5.processed/utils/task_canceller.js +3 -2
- package/dist/mpd-parser.wasm +0 -0
- package/dist/rx-player.d.ts +1 -1
- package/dist/rx-player.js +3951 -3398
- package/dist/rx-player.min.d.ts +1 -1
- package/dist/rx-player.min.js +1 -1
- package/package.json +40 -40
|
@@ -17,189 +17,189 @@
|
|
|
17
17
|
* Translate ISO 639-1 language codes into ISO 639-3 ones.
|
|
18
18
|
*/
|
|
19
19
|
var ISO_MAP_1_TO_3 = {
|
|
20
|
-
aa: "aar",
|
|
21
|
-
ab: "abk",
|
|
22
|
-
ae: "ave",
|
|
23
|
-
af: "afr",
|
|
24
|
-
ak: "aka",
|
|
25
|
-
am: "amh",
|
|
26
|
-
an: "arg",
|
|
27
|
-
ar: "ara",
|
|
28
|
-
as: "asm",
|
|
29
|
-
av: "ava",
|
|
30
|
-
ay: "aym",
|
|
31
|
-
az: "aze",
|
|
32
|
-
ba: "bak",
|
|
33
|
-
be: "bel",
|
|
34
|
-
bg: "bul",
|
|
35
|
-
bi: "bis",
|
|
36
|
-
bm: "bam",
|
|
37
|
-
bn: "ben",
|
|
38
|
-
bo: "bod",
|
|
39
|
-
br: "bre",
|
|
40
|
-
bs: "bos",
|
|
41
|
-
ca: "cat",
|
|
42
|
-
ce: "che",
|
|
43
|
-
ch: "cha",
|
|
44
|
-
co: "cos",
|
|
45
|
-
cr: "cre",
|
|
46
|
-
cs: "ces",
|
|
47
|
-
cu: "chu",
|
|
20
|
+
aa: "aar", // Afar
|
|
21
|
+
ab: "abk", // Abkhazian
|
|
22
|
+
ae: "ave", // Avestan
|
|
23
|
+
af: "afr", // Afrikaans
|
|
24
|
+
ak: "aka", // Akan
|
|
25
|
+
am: "amh", // Amharic
|
|
26
|
+
an: "arg", // Aragonese
|
|
27
|
+
ar: "ara", // Arabic
|
|
28
|
+
as: "asm", // Assamese
|
|
29
|
+
av: "ava", // Avaric
|
|
30
|
+
ay: "aym", // Aymara
|
|
31
|
+
az: "aze", // Azerbaijani
|
|
32
|
+
ba: "bak", // Bashkir
|
|
33
|
+
be: "bel", // Belarusian
|
|
34
|
+
bg: "bul", // Bulgarian
|
|
35
|
+
bi: "bis", // Bislama
|
|
36
|
+
bm: "bam", // Bambara
|
|
37
|
+
bn: "ben", // Bengali
|
|
38
|
+
bo: "bod", // Tibetan
|
|
39
|
+
br: "bre", // Breton
|
|
40
|
+
bs: "bos", // Bosnian
|
|
41
|
+
ca: "cat", // Catalan, Valencian
|
|
42
|
+
ce: "che", // Chechen
|
|
43
|
+
ch: "cha", // Chamorro
|
|
44
|
+
co: "cos", // Corsican
|
|
45
|
+
cr: "cre", // Cree
|
|
46
|
+
cs: "ces", // Czech
|
|
47
|
+
cu: "chu", // Church Slavic, Church Slavonic, Old Church Slavonic,
|
|
48
48
|
// Old Slavonic, Old Bulgarian
|
|
49
|
-
cv: "chv",
|
|
50
|
-
cy: "cym",
|
|
51
|
-
da: "dan",
|
|
52
|
-
de: "deu",
|
|
53
|
-
dv: "div",
|
|
54
|
-
dz: "dzo",
|
|
55
|
-
ee: "ewe",
|
|
56
|
-
el: "ell",
|
|
57
|
-
en: "eng",
|
|
58
|
-
eo: "epo",
|
|
59
|
-
es: "spa",
|
|
60
|
-
et: "est",
|
|
61
|
-
eu: "eus",
|
|
62
|
-
fa: "fas",
|
|
63
|
-
ff: "ful",
|
|
64
|
-
fi: "fin",
|
|
65
|
-
fj: "fij",
|
|
66
|
-
fo: "fao",
|
|
67
|
-
fr: "fra",
|
|
68
|
-
fy: "fry",
|
|
69
|
-
ga: "gle",
|
|
70
|
-
gd: "gla",
|
|
71
|
-
gl: "glg",
|
|
72
|
-
gn: "grn",
|
|
73
|
-
gu: "guj",
|
|
74
|
-
gv: "glv",
|
|
75
|
-
ha: "hau",
|
|
76
|
-
he: "heb",
|
|
77
|
-
hi: "hin",
|
|
78
|
-
ho: "hmo",
|
|
79
|
-
hr: "hrv",
|
|
80
|
-
ht: "hat",
|
|
81
|
-
hu: "hun",
|
|
82
|
-
hy: "hye",
|
|
83
|
-
hz: "her",
|
|
84
|
-
ia: "ina",
|
|
85
|
-
id: "ind",
|
|
86
|
-
ie: "ile",
|
|
87
|
-
ig: "ibo",
|
|
88
|
-
ii: "iii",
|
|
89
|
-
ik: "ipk",
|
|
90
|
-
io: "ido",
|
|
91
|
-
is: "isl",
|
|
92
|
-
it: "ita",
|
|
93
|
-
iu: "iku",
|
|
94
|
-
ja: "jpn",
|
|
95
|
-
jv: "jav",
|
|
96
|
-
ka: "kat",
|
|
97
|
-
kg: "kon",
|
|
98
|
-
ki: "kik",
|
|
99
|
-
kj: "kua",
|
|
100
|
-
kk: "kaz",
|
|
101
|
-
kl: "kal",
|
|
102
|
-
km: "khm",
|
|
103
|
-
kn: "kan",
|
|
104
|
-
ko: "kor",
|
|
105
|
-
kr: "kau",
|
|
106
|
-
ks: "kas",
|
|
107
|
-
ku: "kur",
|
|
108
|
-
kv: "kom",
|
|
109
|
-
kw: "cor",
|
|
110
|
-
ky: "kir",
|
|
111
|
-
la: "lat",
|
|
112
|
-
lb: "ltz",
|
|
113
|
-
lg: "lug",
|
|
114
|
-
li: "lim",
|
|
115
|
-
ln: "lin",
|
|
116
|
-
lo: "lao",
|
|
117
|
-
lt: "lit",
|
|
118
|
-
lu: "lub",
|
|
119
|
-
lv: "lav",
|
|
120
|
-
mg: "mlg",
|
|
121
|
-
mh: "mah",
|
|
122
|
-
mi: "mri",
|
|
123
|
-
mk: "mkd",
|
|
124
|
-
ml: "mal",
|
|
125
|
-
mn: "mon",
|
|
126
|
-
mr: "mar",
|
|
127
|
-
ms: "msa",
|
|
128
|
-
mt: "mlt",
|
|
129
|
-
my: "mya",
|
|
130
|
-
na: "nau",
|
|
131
|
-
nb: "nob",
|
|
132
|
-
nd: "nde",
|
|
133
|
-
ne: "nep",
|
|
134
|
-
ng: "ndo",
|
|
135
|
-
nl: "nld",
|
|
136
|
-
nn: "nno",
|
|
137
|
-
no: "nor",
|
|
138
|
-
nr: "nbl",
|
|
139
|
-
nv: "nav",
|
|
140
|
-
ny: "nya",
|
|
141
|
-
oc: "oci",
|
|
142
|
-
oj: "oji",
|
|
143
|
-
om: "orm",
|
|
144
|
-
or: "ori",
|
|
145
|
-
os: "oss",
|
|
146
|
-
pa: "pan",
|
|
147
|
-
pi: "pli",
|
|
148
|
-
pl: "pol",
|
|
149
|
-
ps: "pus",
|
|
150
|
-
pt: "por",
|
|
151
|
-
qu: "que",
|
|
152
|
-
rm: "roh",
|
|
153
|
-
rn: "run",
|
|
154
|
-
ro: "ron",
|
|
155
|
-
ru: "rus",
|
|
156
|
-
rw: "kin",
|
|
157
|
-
sa: "san",
|
|
158
|
-
sc: "srd",
|
|
159
|
-
sd: "snd",
|
|
160
|
-
se: "sme",
|
|
161
|
-
sg: "sag",
|
|
162
|
-
si: "sin",
|
|
163
|
-
sk: "slk",
|
|
164
|
-
sl: "slv",
|
|
165
|
-
sm: "smo",
|
|
166
|
-
sn: "sna",
|
|
167
|
-
so: "som",
|
|
168
|
-
sq: "sqi",
|
|
169
|
-
sr: "srp",
|
|
170
|
-
ss: "ssw",
|
|
171
|
-
st: "sot",
|
|
172
|
-
su: "sun",
|
|
173
|
-
sv: "swe",
|
|
174
|
-
sw: "swa",
|
|
175
|
-
ta: "tam",
|
|
176
|
-
te: "tel",
|
|
177
|
-
tg: "tgk",
|
|
178
|
-
th: "tha",
|
|
179
|
-
ti: "tir",
|
|
180
|
-
tk: "tuk",
|
|
181
|
-
tl: "tgl",
|
|
182
|
-
tn: "tsn",
|
|
183
|
-
to: "ton",
|
|
184
|
-
tr: "tur",
|
|
185
|
-
ts: "tso",
|
|
186
|
-
tt: "tat",
|
|
187
|
-
tw: "twi",
|
|
188
|
-
ty: "tah",
|
|
189
|
-
ug: "uig",
|
|
190
|
-
uk: "ukr",
|
|
191
|
-
ur: "urd",
|
|
192
|
-
uz: "uzb",
|
|
193
|
-
ve: "ven",
|
|
194
|
-
vi: "vie",
|
|
195
|
-
vo: "vol",
|
|
196
|
-
wa: "wln",
|
|
197
|
-
wo: "wol",
|
|
198
|
-
xh: "xho",
|
|
199
|
-
yi: "yid",
|
|
200
|
-
yo: "yor",
|
|
201
|
-
za: "zha",
|
|
202
|
-
zh: "zho",
|
|
49
|
+
cv: "chv", // Chuvash
|
|
50
|
+
cy: "cym", // Welsh
|
|
51
|
+
da: "dan", // Danish
|
|
52
|
+
de: "deu", // German
|
|
53
|
+
dv: "div", // Divehi, Dhivehi, Maldivian
|
|
54
|
+
dz: "dzo", // Dzongkha
|
|
55
|
+
ee: "ewe", // Ewe
|
|
56
|
+
el: "ell", // Greek (modern)
|
|
57
|
+
en: "eng", // English
|
|
58
|
+
eo: "epo", // Esperanto
|
|
59
|
+
es: "spa", // Spanish, Castilian
|
|
60
|
+
et: "est", // Estonian
|
|
61
|
+
eu: "eus", // Basque
|
|
62
|
+
fa: "fas", // Persian
|
|
63
|
+
ff: "ful", // Fulah
|
|
64
|
+
fi: "fin", // Finnish
|
|
65
|
+
fj: "fij", // Fijian
|
|
66
|
+
fo: "fao", // Faroese
|
|
67
|
+
fr: "fra", // French
|
|
68
|
+
fy: "fry", // Western Frisian
|
|
69
|
+
ga: "gle", // Irish
|
|
70
|
+
gd: "gla", // Gaelic, Scottish Gaelic
|
|
71
|
+
gl: "glg", // Galician
|
|
72
|
+
gn: "grn", // Guaraní
|
|
73
|
+
gu: "guj", // Gujarati
|
|
74
|
+
gv: "glv", // Manx
|
|
75
|
+
ha: "hau", // Hausa
|
|
76
|
+
he: "heb", // Hebrew (modern)
|
|
77
|
+
hi: "hin", // Hindi
|
|
78
|
+
ho: "hmo", // Hiri Motu
|
|
79
|
+
hr: "hrv", // Croatian
|
|
80
|
+
ht: "hat", // Haitian, Haitian Creole
|
|
81
|
+
hu: "hun", // Hungarian
|
|
82
|
+
hy: "hye", // Armenian
|
|
83
|
+
hz: "her", // Herero
|
|
84
|
+
ia: "ina", // Interlingua
|
|
85
|
+
id: "ind", // Indonesian
|
|
86
|
+
ie: "ile", // Interlingue
|
|
87
|
+
ig: "ibo", // Igbo
|
|
88
|
+
ii: "iii", // Sichuan Yi, Nuosu
|
|
89
|
+
ik: "ipk", // Inupiaq
|
|
90
|
+
io: "ido", // Ido
|
|
91
|
+
is: "isl", // Icelandic
|
|
92
|
+
it: "ita", // Italian
|
|
93
|
+
iu: "iku", // Inuktitut
|
|
94
|
+
ja: "jpn", // Japanese
|
|
95
|
+
jv: "jav", // Javanese
|
|
96
|
+
ka: "kat", // Georgian
|
|
97
|
+
kg: "kon", // Kongo
|
|
98
|
+
ki: "kik", // Kikuyu, Gikuyu
|
|
99
|
+
kj: "kua", // Kuanyama, Kwanyama
|
|
100
|
+
kk: "kaz", // Kazakh
|
|
101
|
+
kl: "kal", // Kalaallisut, Greenlandic
|
|
102
|
+
km: "khm", // Central Khmer
|
|
103
|
+
kn: "kan", // Kannada
|
|
104
|
+
ko: "kor", // Korean
|
|
105
|
+
kr: "kau", // Kanuri
|
|
106
|
+
ks: "kas", // Kashmiri
|
|
107
|
+
ku: "kur", // Kurdish
|
|
108
|
+
kv: "kom", // Komi
|
|
109
|
+
kw: "cor", // Cornish
|
|
110
|
+
ky: "kir", // Kirghiz, Kyrgyz
|
|
111
|
+
la: "lat", // Latin
|
|
112
|
+
lb: "ltz", // Luxembourgish, Letzeburgesch
|
|
113
|
+
lg: "lug", // Ganda
|
|
114
|
+
li: "lim", // Limburgan, Limburger, Limburgish
|
|
115
|
+
ln: "lin", // Lingala
|
|
116
|
+
lo: "lao", // Lao
|
|
117
|
+
lt: "lit", // Lithuanian
|
|
118
|
+
lu: "lub", // Luba-Katanga
|
|
119
|
+
lv: "lav", // Latvian
|
|
120
|
+
mg: "mlg", // Malagasy
|
|
121
|
+
mh: "mah", // Marshallese
|
|
122
|
+
mi: "mri", // Maori
|
|
123
|
+
mk: "mkd", // Macedonian
|
|
124
|
+
ml: "mal", // Malayalam
|
|
125
|
+
mn: "mon", // Mongolian
|
|
126
|
+
mr: "mar", // Marathi
|
|
127
|
+
ms: "msa", // Malay
|
|
128
|
+
mt: "mlt", // Maltese
|
|
129
|
+
my: "mya", // Burmese
|
|
130
|
+
na: "nau", // Nauru
|
|
131
|
+
nb: "nob", // Norwegian Bokmål
|
|
132
|
+
nd: "nde", // North Ndebele
|
|
133
|
+
ne: "nep", // Nepali
|
|
134
|
+
ng: "ndo", // Ndonga
|
|
135
|
+
nl: "nld", // Dutch, Flemish
|
|
136
|
+
nn: "nno", // Norwegian Nynorsk
|
|
137
|
+
no: "nor", // Norwegian
|
|
138
|
+
nr: "nbl", // South Ndebele
|
|
139
|
+
nv: "nav", // Navajo, Navaho
|
|
140
|
+
ny: "nya", // Chichewa, Chewa, Nyanja
|
|
141
|
+
oc: "oci", // Occitan
|
|
142
|
+
oj: "oji", // Ojibwa
|
|
143
|
+
om: "orm", // Oromo
|
|
144
|
+
or: "ori", // Oriya
|
|
145
|
+
os: "oss", // Ossetian, Ossetic
|
|
146
|
+
pa: "pan", // Panjabi, Punjabi
|
|
147
|
+
pi: "pli", // Pali
|
|
148
|
+
pl: "pol", // Polish
|
|
149
|
+
ps: "pus", // Pashto, Pushto
|
|
150
|
+
pt: "por", // Portuguese
|
|
151
|
+
qu: "que", // Quechua
|
|
152
|
+
rm: "roh", // Romansh
|
|
153
|
+
rn: "run", // Rundi
|
|
154
|
+
ro: "ron", // Romanian, Moldavian, Moldovan
|
|
155
|
+
ru: "rus", // Russian
|
|
156
|
+
rw: "kin", // Kinyarwanda
|
|
157
|
+
sa: "san", // Sanskrit
|
|
158
|
+
sc: "srd", // Sardinian
|
|
159
|
+
sd: "snd", // Sindhi
|
|
160
|
+
se: "sme", // Northern Sami
|
|
161
|
+
sg: "sag", // Sango
|
|
162
|
+
si: "sin", // Sinhala, Sinhalese
|
|
163
|
+
sk: "slk", // Slovak
|
|
164
|
+
sl: "slv", // Slovenian
|
|
165
|
+
sm: "smo", // Samoan
|
|
166
|
+
sn: "sna", // Shona
|
|
167
|
+
so: "som", // Somali
|
|
168
|
+
sq: "sqi", // Albanian
|
|
169
|
+
sr: "srp", // Serbian
|
|
170
|
+
ss: "ssw", // Swati
|
|
171
|
+
st: "sot", // Southern Sotho
|
|
172
|
+
su: "sun", // Sundanese
|
|
173
|
+
sv: "swe", // Swedish
|
|
174
|
+
sw: "swa", // Swahili
|
|
175
|
+
ta: "tam", // Tamil
|
|
176
|
+
te: "tel", // Telugu
|
|
177
|
+
tg: "tgk", // Tajik
|
|
178
|
+
th: "tha", // Thai
|
|
179
|
+
ti: "tir", // Tigrinya
|
|
180
|
+
tk: "tuk", // Turkmen
|
|
181
|
+
tl: "tgl", // Tagalog
|
|
182
|
+
tn: "tsn", // Tswana
|
|
183
|
+
to: "ton", // Tonga (Tonga Islands)
|
|
184
|
+
tr: "tur", // Turkish
|
|
185
|
+
ts: "tso", // Tsonga
|
|
186
|
+
tt: "tat", // Tatar
|
|
187
|
+
tw: "twi", // Twi
|
|
188
|
+
ty: "tah", // Tahitian
|
|
189
|
+
ug: "uig", // Uighur, Uyghur
|
|
190
|
+
uk: "ukr", // Ukrainian
|
|
191
|
+
ur: "urd", // Urdu
|
|
192
|
+
uz: "uzb", // Uzbek
|
|
193
|
+
ve: "ven", // Venda
|
|
194
|
+
vi: "vie", // Vietnamese
|
|
195
|
+
vo: "vol", // Volapük
|
|
196
|
+
wa: "wln", // Walloon
|
|
197
|
+
wo: "wol", // Wolof
|
|
198
|
+
xh: "xho", // Xhosa
|
|
199
|
+
yi: "yid", // Yiddish
|
|
200
|
+
yo: "yor", // Yoruba
|
|
201
|
+
za: "zha", // Zhuang, Chuang
|
|
202
|
+
zh: "zho", // Chinese
|
|
203
203
|
zu: "zul", // Zulu
|
|
204
204
|
};
|
|
205
205
|
export default ISO_MAP_1_TO_3;
|
|
@@ -17,25 +17,25 @@
|
|
|
17
17
|
* Translate ISO 639-2 synonyms to their ISO 639-3 counterparts.
|
|
18
18
|
*/
|
|
19
19
|
var ISO_MAP_2_TO_3 = {
|
|
20
|
-
alb: "sqi",
|
|
21
|
-
arm: "hye",
|
|
22
|
-
baq: "eus",
|
|
23
|
-
bur: "mya",
|
|
24
|
-
chi: "zho",
|
|
25
|
-
cze: "ces",
|
|
26
|
-
dut: "nld",
|
|
27
|
-
fre: "fra",
|
|
28
|
-
geo: "kat",
|
|
29
|
-
ger: "deu",
|
|
30
|
-
gre: "ell",
|
|
31
|
-
ice: "isl",
|
|
32
|
-
mac: "mkd",
|
|
33
|
-
mao: "mri",
|
|
34
|
-
may: "msa",
|
|
35
|
-
per: "fas",
|
|
36
|
-
slo: "slk",
|
|
37
|
-
rum: "ron",
|
|
38
|
-
tib: "bod",
|
|
20
|
+
alb: "sqi", // Albanian
|
|
21
|
+
arm: "hye", // Armenian
|
|
22
|
+
baq: "eus", // Basque
|
|
23
|
+
bur: "mya", // Burmese
|
|
24
|
+
chi: "zho", // Chinese
|
|
25
|
+
cze: "ces", // Czech
|
|
26
|
+
dut: "nld", // Dutch; Flemish
|
|
27
|
+
fre: "fra", // French
|
|
28
|
+
geo: "kat", // Georgian
|
|
29
|
+
ger: "deu", // German
|
|
30
|
+
gre: "ell", // Modern Greek (1453–)
|
|
31
|
+
ice: "isl", // Icelandic
|
|
32
|
+
mac: "mkd", // Macedonian
|
|
33
|
+
mao: "mri", // Maori
|
|
34
|
+
may: "msa", // Malay
|
|
35
|
+
per: "fas", // Persian
|
|
36
|
+
slo: "slk", // Slovak
|
|
37
|
+
rum: "ron", // Moldovan
|
|
38
|
+
tib: "bod", // Tibetan
|
|
39
39
|
wel: "cym", // Welsh
|
|
40
40
|
};
|
|
41
41
|
export default ISO_MAP_2_TO_3;
|
|
@@ -28,7 +28,10 @@ import ISO_MAP_2_TO_3 from "./ISO_639-2_to_ISO_639-3";
|
|
|
28
28
|
*/
|
|
29
29
|
function normalizeLanguage(_language) {
|
|
30
30
|
if (isNullOrUndefined(_language) || _language === "") {
|
|
31
|
-
|
|
31
|
+
/**
|
|
32
|
+
* "und" is a special value in ISO 639-3 that stands for "undetermined language".
|
|
33
|
+
*/
|
|
34
|
+
return "und";
|
|
32
35
|
}
|
|
33
36
|
var fields = ("" + _language).toLowerCase().split("-");
|
|
34
37
|
var base = fields[0];
|
|
@@ -13,16 +13,6 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
/**
|
|
17
|
-
* Construct an url from the arguments given.
|
|
18
|
-
* Basically:
|
|
19
|
-
* - The last arguments that contains a scheme (e.g. "http://") is the base
|
|
20
|
-
* of the url.
|
|
21
|
-
* - every subsequent string arguments are concatened to it.
|
|
22
|
-
* @param {...string|undefined} args
|
|
23
|
-
* @returns {string}
|
|
24
|
-
*/
|
|
25
|
-
export default function resolveURL(...args: Array<string | undefined>): string;
|
|
26
16
|
/**
|
|
27
17
|
* In a given URL, find the index at which the filename begins.
|
|
28
18
|
* That is, this function finds the index of the last `/` character and returns
|
|
@@ -32,4 +22,17 @@ export default function resolveURL(...args: Array<string | undefined>): string;
|
|
|
32
22
|
* @returns {number}
|
|
33
23
|
*/
|
|
34
24
|
declare function getFilenameIndexInUrl(url: string): number;
|
|
25
|
+
/**
|
|
26
|
+
* Resolves multiple URL segments using the RFC 3986 URL resolution algorithm.
|
|
27
|
+
*
|
|
28
|
+
* This function takes a variable number of URL segments and resolves them
|
|
29
|
+
* sequentially according to the RFC 3986 URL resolution algorithm.
|
|
30
|
+
* First argument is the base URL.
|
|
31
|
+
* Empty string arguments are ignored.
|
|
32
|
+
*
|
|
33
|
+
* @param {...(string|undefined)} args - The URL segments to resolve.
|
|
34
|
+
* @returns {string} The resolved URL as a string.
|
|
35
|
+
*/
|
|
36
|
+
export declare function resolveURL(...args: Array<string | undefined>): string;
|
|
35
37
|
export { getFilenameIndexInUrl };
|
|
38
|
+
export default resolveURL;
|