@webitel/ui-sdk 26.6.34 → 26.6.36
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/AgentStatus.enum-C3IGHtvR.js +9 -0
- package/dist/_plugin-vue_export-helper-B3ysoDQm.js +8 -0
- package/dist/caseConverters-DXegZoCt.js +27 -0
- package/dist/chunk-CY3AvKd6.js +20 -0
- package/dist/clients-A6MHYfOX.js +36118 -0
- package/dist/components-DFOWyAAb.js +5395 -0
- package/dist/composables-DnDH-KUv.js +263 -0
- package/dist/convertDuration-1K7fuEpO.js +8 -0
- package/dist/debounce-DrmECuJ2.js +128 -0
- package/dist/deep-copy-CQw5yeEH.js +41 -0
- package/dist/displayText-CtaxzaBz.js +3 -0
- package/dist/dist-05Bf47Wg.js +87 -0
- package/dist/dist-BYiYpK00.js +7 -0
- package/dist/dist-Dz55hlwp.js +1371 -0
- package/dist/engineCallFileType-D7QVFOac.js +11 -0
- package/dist/enums-pbYAJNeb.js +158 -0
- package/dist/errors-SUXKojVW.js +69 -0
- package/dist/floating-ui.dom-n2j9PKCB.js +842 -0
- package/dist/generateInstance-ppTIeLX4.js +2582 -0
- package/dist/isObject-Dgs_L5xI.js +11 -0
- package/dist/logger-hl3ueNok.js +47 -0
- package/dist/prod-Cp0BjuxI.js +775 -0
- package/dist/prod-DSuxcp5t.js +2 -0
- package/dist/side-channel-Cyte-MzW.js +833 -0
- package/dist/sortQueryAdapters-CyYXvnDN.js +14 -0
- package/dist/srt-parser-DdH5U08c.js +21 -0
- package/dist/ssa-parser-Bjs7yDD1.js +184 -0
- package/dist/ui-sdk.css +2 -1
- package/dist/ui-sdk.js +34567 -4
- package/dist/ui-sdk.umd.cjs +7748 -7606
- package/dist/useExpansion-DVdIpoOn.js +24 -0
- package/dist/useValidation-DG0tifBv.js +37 -0
- package/dist/useVidstackSrc-DfNrFbOO.js +155 -0
- package/dist/useWtTable-tqmVOvve.js +12 -0
- package/dist/vidstack-B01xzxC4-DeYSgDZy.js +7 -0
- package/dist/vidstack-BGSTndAW-CyKM_CM4.js +957 -0
- package/dist/vidstack-BQlOPwOu-ChhdffAJ.js +43 -0
- package/dist/vidstack-Bq6c3Bam-3dCf_D36.js +398 -0
- package/dist/vidstack-C2US-gSO-DeIgENrW.js +127 -0
- package/dist/vidstack-C9vIqaYT-C1EgPq17.js +9 -0
- package/dist/vidstack-CTojmhKq-D7sZJxgm.js +30 -0
- package/dist/vidstack-ChQTHmIQ-nTO94M6P.js +51 -0
- package/dist/vidstack-Ci54COQW-CAAXpwzv.js +208 -0
- package/dist/vidstack-D2pY00kU-DoW028io.js +70 -0
- package/dist/vidstack-D5EzK014-DOe01V3H.js +14 -0
- package/dist/vidstack-DDXt6fpN-Don_e6LS.js +42 -0
- package/dist/vidstack-D_-9AA6_-Dq3APB0-.js +19 -0
- package/dist/vidstack-Dihypf8P-ibWMCHK-.js +12 -0
- package/dist/vidstack-Dm1xEU9Q-VlefmrP8.js +31 -0
- package/dist/vidstack-DqAw8m9J-Dk1GT3Oe.js +22 -0
- package/dist/vidstack-audio-B58bvsna.js +23 -0
- package/dist/vidstack-dash-CX-LTHx3.js +332 -0
- package/dist/vidstack-google-cast-Co5Q_rfL.js +361 -0
- package/dist/vidstack-hls-CLzdTFu6.js +269 -0
- package/dist/vidstack-krOAtKMi-DN1WZC3p.js +30 -0
- package/dist/vidstack-video-XtP8iTBc.js +151 -0
- package/dist/vidstack-vimeo-EzzPpggD.js +386 -0
- package/dist/vidstack-youtube-C1_NAfWa.js +205 -0
- package/dist/vue-i18n-B8Px6VcD.js +2201 -0
- package/dist/wt-action-bar-Ba1ZJjE_.js +85 -0
- package/dist/wt-button-DENbrKdy.js +785 -0
- package/dist/wt-button-select-BnRHgJ4i.js +80 -0
- package/dist/wt-call-media-action-Bkyppnsm.js +42 -0
- package/dist/wt-chat-emoji-D3SBme6f.js +2208 -0
- package/dist/wt-confirm-dialog-DCUitG2v.js +70 -0
- package/dist/wt-context-menu-yW52oF-2.js +89 -0
- package/dist/wt-copy-action-d9gVzAsB.js +38 -0
- package/dist/wt-datepicker-Cnbarx_j.js +5774 -0
- package/dist/wt-display-chip-items-DagfTTIq.js +34 -0
- package/dist/wt-dual-panel-DAhTYFS_.js +49 -0
- package/dist/wt-dummy-CLjhRWZ6.js +59 -0
- package/dist/wt-error-page-vhu4lIyF.js +62 -0
- package/dist/wt-expand-transition-C2p9bR4j.js +39 -0
- package/dist/wt-expansion-card-qsxvbtZm.js +47 -0
- package/dist/wt-expansion-panel-C_EXvx1d.js +40 -0
- package/dist/wt-filters-panel-wrapper-Cc9b3aci.js +51 -0
- package/dist/wt-galleria-CWXKuZTD.js +224 -0
- package/dist/wt-icon-action-CQlZHMDB.js +100 -0
- package/dist/wt-icon-btn-CjjI4cgE.js +107 -0
- package/dist/wt-icon-pxO7IjwV.js +1026 -0
- package/dist/wt-inline-add-panel-B0E4Vk2l.js +43 -0
- package/dist/wt-navigation-menu-CenQi_-T.js +126 -0
- package/dist/wt-notifications-bar-Ep1QuFZi.js +52 -0
- package/dist/wt-page-header-CDbd4aOh.js +59 -0
- package/dist/wt-pagination-BA_PZPIE.js +94 -0
- package/dist/wt-player-uidPXSTe.js +287 -0
- package/dist/wt-popover-CJZH3wMl.js +98 -0
- package/dist/wt-screen-recordings-action-Dg7Ts2Jt.js +37 -0
- package/dist/wt-search-bar-CWZdvAOf.js +123 -0
- package/dist/wt-selection-popup-B77UY7Yu.js +79 -0
- package/dist/wt-send-message-popup-CltYZA9D.js +77 -0
- package/dist/wt-slider-BS3SoGht.js +68 -0
- package/dist/wt-start-page-eN1PEokc.js +86 -0
- package/dist/wt-status-select-A5t6Vjm4.js +101 -0
- package/dist/wt-stepper-B6zpd1Uh.js +41 -0
- package/dist/wt-table-D0FynxIE.js +364 -0
- package/dist/wt-table-actions-4-peSVkc.js +63 -0
- package/dist/wt-table-column-select-DFF6z3a3.js +100 -0
- package/dist/wt-tabs-DuOgj-lZ.js +60 -0
- package/dist/wt-time-input-CO2cop3y.js +62 -0
- package/dist/wt-timepicker-BltFF1QD.js +145 -0
- package/dist/wt-tree-ZyoPrNOl.js +1206 -0
- package/dist/wt-tree-table-MLET4gIv.js +221 -0
- package/dist/wt-type-extension-value-input-028o8xRF.js +104 -0
- package/dist/wt-vidstack-player-B-WSB_Be.js +7440 -0
- package/package.json +5 -5
- package/src/components/wt-multi-select/wt-multi-select.vue +3 -0
- package/src/components/wt-single-select/wt-single-select.vue +5 -0
- package/src/components/wt-table-column-select/__tests__/WtTableColumnSelect.spec.js +3 -3
- package/src/plugins/primevue/theme/components/multi-select/multi-select.js +4 -0
- package/src/plugins/primevue/theme/components/single-select/single-select.js +4 -0
- package/types/plugins/primevue/theme/components/multi-select/multi-select.d.ts +2 -0
- package/types/plugins/primevue/theme/components/single-select/single-select.d.ts +2 -0
- package/dist/contacts-DzLKP4GQ.js +0 -49654
- package/dist/displayText-Cbh4IOfM.js +0 -5
- package/dist/engineCallFileType-yaadA7-2.js +0 -8
- package/dist/errors-CTL-RV3B.js +0 -70
- package/dist/index-BgLoxAyu.js +0 -50
- package/dist/install-Cm-8fwtB.js +0 -53489
- package/dist/isObject-BSIwu4UO.js +0 -28
- package/dist/prod-BoQuiIB3.js +0 -973
- package/dist/srt-parser-CsN7bp5E.js +0 -26
- package/dist/ssa-parser-BJOOPeQF.js +0 -200
- package/dist/useExpansion-BrQ40HiR.js +0 -24
- package/dist/useVidstackSrc-DKXY5f7v.js +0 -1341
- package/dist/vidstack-Bq6c3Bam-BHF-0bv4.js +0 -426
- package/dist/vidstack-D2pY00kU-B8Mhvp0m.js +0 -136
- package/dist/vidstack-DDXt6fpN-D0eou9h7.js +0 -51
- package/dist/vidstack-D_-9AA6_-DYAfclN7.js +0 -21
- package/dist/vidstack-Dm1xEU9Q-CXHNvShT.js +0 -30
- package/dist/vidstack-DqAw8m9J-b5BHkhrw.js +0 -22
- package/dist/vidstack-audio-CPu_TbjK.js +0 -28
- package/dist/vidstack-dash-VYriMjws.js +0 -393
- package/dist/vidstack-google-cast-Byp1cemB.js +0 -383
- package/dist/vidstack-hls-DdUQcmEx.js +0 -310
- package/dist/vidstack-krOAtKMi-C50BTxmn.js +0 -28
- package/dist/vidstack-video-BpSKQ3wb.js +0 -164
- package/dist/vidstack-vimeo-CgVJJm06.js +0 -452
- package/dist/vidstack-youtube-DuES80MV.js +0 -233
- package/dist/wt-action-bar-TMuck-q1.js +0 -102
- package/dist/wt-button-select-D1NP5Xw9.js +0 -105
- package/dist/wt-call-media-action-BsepfSVy.js +0 -60
- package/dist/wt-chat-emoji-B00dUXbP.js +0 -2909
- package/dist/wt-confirm-dialog-1hO851Da.js +0 -92
- package/dist/wt-context-menu-BrzRmoDw.js +0 -104
- package/dist/wt-copy-action-CEMOiYzN.js +0 -60
- package/dist/wt-datepicker-DHqZIkg2.js +0 -5660
- package/dist/wt-display-chip-items-D7kEAcOo.js +0 -47
- package/dist/wt-dual-panel-DEWR3-k-.js +0 -66
- package/dist/wt-dummy-DfgxciHw.js +0 -104
- package/dist/wt-error-page-DUSVxkXq.js +0 -89
- package/dist/wt-expansion-card-B8JKBMLa.js +0 -56
- package/dist/wt-expansion-panel-DL3eoj_b.js +0 -54
- package/dist/wt-filters-panel-wrapper-CGXQiRvh.js +0 -75
- package/dist/wt-galleria-Bahv6Mgq.js +0 -323
- package/dist/wt-inline-add-panel-B4RjHVDI.js +0 -49
- package/dist/wt-navigation-menu-DqCXAV8E.js +0 -159
- package/dist/wt-notifications-bar-CRIKdVai.js +0 -79
- package/dist/wt-page-header-DdsnoLgd.js +0 -115
- package/dist/wt-pagination-C_b3WmH1.js +0 -144
- package/dist/wt-player-B4GWEqdu.js +0 -291
- package/dist/wt-popover-Di-7_rDL.js +0 -4
- package/dist/wt-popover.vue_vue_type_style_index_0_lang-DMDTlCgv.js +0 -81
- package/dist/wt-screen-recordings-action-B4OpN5kl.js +0 -54
- package/dist/wt-search-bar-B_0_YwCn.js +0 -144
- package/dist/wt-selection-popup-Boyw9_V_.js +0 -109
- package/dist/wt-send-message-popup-0C23Zocu.js +0 -579
- package/dist/wt-slider-BEkw4KGp.js +0 -4
- package/dist/wt-slider.vue_vue_type_script_setup_true_lang-DlaRDHxo.js +0 -55
- package/dist/wt-start-page-HQMIG05a.js +0 -99
- package/dist/wt-status-select-H_me1xwA.js +0 -138
- package/dist/wt-stepper-hJxqyiyo.js +0 -65
- package/dist/wt-table-Du6mtkPw.js +0 -426
- package/dist/wt-table-actions-ah_H6LY9.js +0 -79
- package/dist/wt-table-column-select-C2Nbic5-.js +0 -128
- package/dist/wt-tabs-D4aGEd_t.js +0 -74
- package/dist/wt-time-input-DYiW0ijt.js +0 -42
- package/dist/wt-timepicker-BE8POMhF.js +0 -118
- package/dist/wt-tree-table-BJxaXqKl.js +0 -285
- package/dist/wt-tree-u0Zp8nb5.js +0 -2777
- package/dist/wt-type-extension-value-input-C1VlNa4K.js +0 -121
- package/dist/wt-vidstack-player-C1eyCEzP.js +0 -9094
|
@@ -0,0 +1,386 @@
|
|
|
1
|
+
import { $ as e, H as t, I as n, K as r, g as i, h as a, v as o, w as s } from "./vidstack-BGSTndAW-CyKM_CM4.js";
|
|
2
|
+
import { i as c } from "./vidstack-CTojmhKq-D7sZJxgm.js";
|
|
3
|
+
import { getVimeoVideoInfo as l, resolveVimeoVideoId as u } from "./vidstack-krOAtKMi-DN1WZC3p.js";
|
|
4
|
+
import { t as d } from "./vidstack-DqAw8m9J-Dk1GT3Oe.js";
|
|
5
|
+
import { t as f } from "./vidstack-D5EzK014-DOe01V3H.js";
|
|
6
|
+
import { t as p } from "./vidstack-Ci54COQW-CAAXpwzv.js";
|
|
7
|
+
import { t as m } from "./vidstack-B01xzxC4-DeYSgDZy.js";
|
|
8
|
+
import { t as h } from "./vidstack-ChQTHmIQ-nTO94M6P.js";
|
|
9
|
+
import { t as g } from "./vidstack-DDXt6fpN-Don_e6LS.js";
|
|
10
|
+
//#region node_modules/vidstack/prod/providers/vidstack-vimeo.js
|
|
11
|
+
var _ = [
|
|
12
|
+
"bufferend",
|
|
13
|
+
"bufferstart",
|
|
14
|
+
"durationchange",
|
|
15
|
+
"ended",
|
|
16
|
+
"enterpictureinpicture",
|
|
17
|
+
"error",
|
|
18
|
+
"fullscreenchange",
|
|
19
|
+
"leavepictureinpicture",
|
|
20
|
+
"loaded",
|
|
21
|
+
"playProgress",
|
|
22
|
+
"loadProgress",
|
|
23
|
+
"pause",
|
|
24
|
+
"play",
|
|
25
|
+
"playbackratechange",
|
|
26
|
+
"qualitychange",
|
|
27
|
+
"seeked",
|
|
28
|
+
"seeking",
|
|
29
|
+
"timeupdate",
|
|
30
|
+
"volumechange",
|
|
31
|
+
"waiting"
|
|
32
|
+
], v = class extends g {
|
|
33
|
+
$$PROVIDER_TYPE = "VIMEO";
|
|
34
|
+
scope = a();
|
|
35
|
+
fullscreen;
|
|
36
|
+
#e;
|
|
37
|
+
#t = e("");
|
|
38
|
+
#n = e(!1);
|
|
39
|
+
#r = null;
|
|
40
|
+
#i = null;
|
|
41
|
+
#a = !1;
|
|
42
|
+
#o = new h(0, 0);
|
|
43
|
+
#s = new d(this.#h.bind(this));
|
|
44
|
+
#c = null;
|
|
45
|
+
#l = null;
|
|
46
|
+
#u = /* @__PURE__ */ new Map();
|
|
47
|
+
#d = null;
|
|
48
|
+
constructor(e, t) {
|
|
49
|
+
super(e), this.#e = t;
|
|
50
|
+
let n = this;
|
|
51
|
+
this.fullscreen = {
|
|
52
|
+
get active() {
|
|
53
|
+
return n.#a;
|
|
54
|
+
},
|
|
55
|
+
supported: !0,
|
|
56
|
+
enter: () => this.#L("requestFullscreen"),
|
|
57
|
+
exit: () => this.#L("exitFullscreen")
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
cookies = !1;
|
|
61
|
+
title = !0;
|
|
62
|
+
byline = !0;
|
|
63
|
+
portrait = !0;
|
|
64
|
+
color = "00ADEF";
|
|
65
|
+
get type() {
|
|
66
|
+
return "vimeo";
|
|
67
|
+
}
|
|
68
|
+
get currentSrc() {
|
|
69
|
+
return this.#i;
|
|
70
|
+
}
|
|
71
|
+
get videoId() {
|
|
72
|
+
return this.#t();
|
|
73
|
+
}
|
|
74
|
+
get hash() {
|
|
75
|
+
return this.#r;
|
|
76
|
+
}
|
|
77
|
+
get isPro() {
|
|
78
|
+
return this.#n();
|
|
79
|
+
}
|
|
80
|
+
preconnect() {
|
|
81
|
+
c(this.getOrigin());
|
|
82
|
+
}
|
|
83
|
+
setup() {
|
|
84
|
+
super.setup(), o(this.#f.bind(this)), o(this.#p.bind(this)), o(this.#m.bind(this)), this.#e.notify("provider-setup", this);
|
|
85
|
+
}
|
|
86
|
+
destroy() {
|
|
87
|
+
this.#R(), this.fullscreen = void 0;
|
|
88
|
+
for (let e of this.#u.values()) for (let { reject: t } of e) t("provider destroyed");
|
|
89
|
+
this.#u.clear(), this.#L("destroy");
|
|
90
|
+
}
|
|
91
|
+
async play() {
|
|
92
|
+
return this.#L("play");
|
|
93
|
+
}
|
|
94
|
+
async pause() {
|
|
95
|
+
return this.#L("pause");
|
|
96
|
+
}
|
|
97
|
+
setMuted(e) {
|
|
98
|
+
this.#L("setMuted", e);
|
|
99
|
+
}
|
|
100
|
+
setCurrentTime(e) {
|
|
101
|
+
this.#L("seekTo", e), this.#e.notify("seeking", e);
|
|
102
|
+
}
|
|
103
|
+
setVolume(e) {
|
|
104
|
+
this.#L("setVolume", e), this.#L("setMuted", r(this.#e.$state.muted));
|
|
105
|
+
}
|
|
106
|
+
setPlaybackRate(e) {
|
|
107
|
+
this.#L("setPlaybackRate", e);
|
|
108
|
+
}
|
|
109
|
+
async loadSource(e) {
|
|
110
|
+
if (!n(e.src)) {
|
|
111
|
+
this.#i = null, this.#r = null, this.#t.set("");
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
114
|
+
let { videoId: t, hash: r } = u(e.src);
|
|
115
|
+
this.#t.set(t ?? ""), this.#r = r ?? null, this.#i = e;
|
|
116
|
+
}
|
|
117
|
+
#f() {
|
|
118
|
+
this.#R();
|
|
119
|
+
let e = this.#t();
|
|
120
|
+
if (!e) {
|
|
121
|
+
this.src.set("");
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
this.src.set(`${this.getOrigin()}/video/${e}`), this.#e.notify("load-start");
|
|
125
|
+
}
|
|
126
|
+
#p() {
|
|
127
|
+
let e = this.#t();
|
|
128
|
+
if (!e) return;
|
|
129
|
+
let t = i(), n = new AbortController();
|
|
130
|
+
return this.#d = t, l(e, n, this.#r).then((e) => {
|
|
131
|
+
t.resolve(e);
|
|
132
|
+
}).catch((e) => {
|
|
133
|
+
t.reject();
|
|
134
|
+
}), () => {
|
|
135
|
+
t.reject(), n.abort();
|
|
136
|
+
};
|
|
137
|
+
}
|
|
138
|
+
#m() {
|
|
139
|
+
let e = this.#n(), { $state: n, qualities: r } = this.#e;
|
|
140
|
+
if (n.canSetPlaybackRate.set(e), r[f.setReadonly](!e), e) return t(r, "change", () => {
|
|
141
|
+
if (r.auto) return;
|
|
142
|
+
let e = r.selected?.id;
|
|
143
|
+
e && this.#L("setQuality", e);
|
|
144
|
+
});
|
|
145
|
+
}
|
|
146
|
+
getOrigin() {
|
|
147
|
+
return "https://player.vimeo.com";
|
|
148
|
+
}
|
|
149
|
+
buildParams() {
|
|
150
|
+
let { keyDisabled: e } = this.#e.$props, { playsInline: t, nativeControls: n } = this.#e.$state, r = n();
|
|
151
|
+
return {
|
|
152
|
+
title: this.title,
|
|
153
|
+
byline: this.byline,
|
|
154
|
+
color: this.color,
|
|
155
|
+
portrait: this.portrait,
|
|
156
|
+
controls: r,
|
|
157
|
+
h: this.hash,
|
|
158
|
+
keyboard: r && !e(),
|
|
159
|
+
transparent: !0,
|
|
160
|
+
playsinline: t(),
|
|
161
|
+
dnt: !this.cookies
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
#h() {
|
|
165
|
+
this.#L("getCurrentTime");
|
|
166
|
+
}
|
|
167
|
+
#g = !1;
|
|
168
|
+
#_(e, t) {
|
|
169
|
+
if (this.#g && e === 0) return;
|
|
170
|
+
let { realCurrentTime: n, paused: r, bufferedEnd: i, seekableEnd: a, live: o } = this.#e.$state;
|
|
171
|
+
if (n() === e) return;
|
|
172
|
+
let s = n();
|
|
173
|
+
this.#e.notify("time-change", e, t), Math.abs(s - e) > 1.5 && (this.#e.notify("seeking", e, t), !r() && i() < e && this.#e.notify("waiting", void 0, t)), !o() && a() - e < .01 && (this.#e.notify("end", void 0, t), this.#g = !0, setTimeout(() => {
|
|
174
|
+
this.#g = !1;
|
|
175
|
+
}, 500));
|
|
176
|
+
}
|
|
177
|
+
#v(e, t) {
|
|
178
|
+
this.#e.notify("seeked", e, t);
|
|
179
|
+
}
|
|
180
|
+
#y(e) {
|
|
181
|
+
let t = this.#t();
|
|
182
|
+
this.#d?.promise.then((t) => {
|
|
183
|
+
if (!t) return;
|
|
184
|
+
let { title: n, poster: r, duration: i, pro: a } = t;
|
|
185
|
+
this.#n.set(a), this.#e.notify("title-change", n, e), this.#e.notify("poster-change", r, e), this.#e.notify("duration-change", i, e), this.#b(i, e);
|
|
186
|
+
}).catch(() => {
|
|
187
|
+
t === this.#t() && (this.#L("getVideoTitle"), this.#L("getDuration"));
|
|
188
|
+
});
|
|
189
|
+
}
|
|
190
|
+
#b(e, t) {
|
|
191
|
+
let { nativeControls: n } = this.#e.$state, r = n();
|
|
192
|
+
this.#o = new h(0, e);
|
|
193
|
+
let i = {
|
|
194
|
+
buffered: new h(0, 0),
|
|
195
|
+
seekable: this.#o,
|
|
196
|
+
duration: e
|
|
197
|
+
};
|
|
198
|
+
this.#e.delegate.ready(i, t), r || this.#L("_hideOverlay"), this.#L("getQualities"), this.#L("getChapters");
|
|
199
|
+
}
|
|
200
|
+
#x(e, t, n) {
|
|
201
|
+
switch (e) {
|
|
202
|
+
case "getVideoTitle":
|
|
203
|
+
let e = t;
|
|
204
|
+
this.#e.notify("title-change", e, n);
|
|
205
|
+
break;
|
|
206
|
+
case "getDuration":
|
|
207
|
+
let i = t;
|
|
208
|
+
this.#e.$state.canPlay() ? this.#e.notify("duration-change", i, n) : this.#b(i, n);
|
|
209
|
+
break;
|
|
210
|
+
case "getCurrentTime":
|
|
211
|
+
this.#_(t, n);
|
|
212
|
+
break;
|
|
213
|
+
case "getBuffered":
|
|
214
|
+
s(t) && t.length && this.#E(t[t.length - 1][1], n);
|
|
215
|
+
break;
|
|
216
|
+
case "setMuted":
|
|
217
|
+
this.#A(r(this.#e.$state.volume), t, n);
|
|
218
|
+
break;
|
|
219
|
+
case "getChapters":
|
|
220
|
+
this.#j(t);
|
|
221
|
+
break;
|
|
222
|
+
case "getQualities":
|
|
223
|
+
this.#N(t, n);
|
|
224
|
+
break;
|
|
225
|
+
}
|
|
226
|
+
this.#z(e)?.resolve();
|
|
227
|
+
}
|
|
228
|
+
#S() {
|
|
229
|
+
for (let e of _) this.#L("addEventListener", e);
|
|
230
|
+
}
|
|
231
|
+
#C(e) {
|
|
232
|
+
this.#s.stop(), this.#e.notify("pause", void 0, e);
|
|
233
|
+
}
|
|
234
|
+
#w(e) {
|
|
235
|
+
this.#s.start(), this.#e.notify("play", void 0, e);
|
|
236
|
+
}
|
|
237
|
+
#T(e) {
|
|
238
|
+
let { paused: t } = this.#e.$state;
|
|
239
|
+
!t() && !this.#g && this.#e.notify("playing", void 0, e);
|
|
240
|
+
}
|
|
241
|
+
#E(e, t) {
|
|
242
|
+
let n = {
|
|
243
|
+
buffered: new h(0, e),
|
|
244
|
+
seekable: this.#o
|
|
245
|
+
};
|
|
246
|
+
this.#e.notify("progress", n, t);
|
|
247
|
+
}
|
|
248
|
+
#D(e) {
|
|
249
|
+
this.#e.notify("waiting", void 0, e);
|
|
250
|
+
}
|
|
251
|
+
#O(e) {
|
|
252
|
+
let { paused: t } = this.#e.$state;
|
|
253
|
+
t() || this.#e.notify("playing", void 0, e);
|
|
254
|
+
}
|
|
255
|
+
#k(e) {
|
|
256
|
+
let { paused: t } = this.#e.$state;
|
|
257
|
+
t() && this.#e.notify("play", void 0, e), this.#e.notify("waiting", void 0, e);
|
|
258
|
+
}
|
|
259
|
+
#A(e, t, n) {
|
|
260
|
+
let r = {
|
|
261
|
+
volume: e,
|
|
262
|
+
muted: t
|
|
263
|
+
};
|
|
264
|
+
this.#e.notify("volume-change", r, n);
|
|
265
|
+
}
|
|
266
|
+
#j(e) {
|
|
267
|
+
if (this.#M(), !e.length) return;
|
|
268
|
+
let t = new p({
|
|
269
|
+
kind: "chapters",
|
|
270
|
+
default: !0
|
|
271
|
+
}), { seekableEnd: n } = this.#e.$state;
|
|
272
|
+
for (let r = 0; r < e.length; r++) {
|
|
273
|
+
let i = e[r], a = e[r + 1];
|
|
274
|
+
t.addCue(new window.VTTCue(i.startTime, a?.startTime ?? n(), i.title));
|
|
275
|
+
}
|
|
276
|
+
this.#l = t, this.#e.textTracks.add(t);
|
|
277
|
+
}
|
|
278
|
+
#M() {
|
|
279
|
+
this.#l &&= (this.#e.textTracks.remove(this.#l), null);
|
|
280
|
+
}
|
|
281
|
+
#N(e, t) {
|
|
282
|
+
this.#e.qualities[m.enableAuto] = e.some((e) => e.id === "auto") ? () => this.#L("setQuality", "auto") : void 0;
|
|
283
|
+
for (let n of e) {
|
|
284
|
+
if (n.id === "auto") continue;
|
|
285
|
+
let e = +n.id.slice(0, -1);
|
|
286
|
+
isNaN(e) || this.#e.qualities[f.add]({
|
|
287
|
+
id: n.id,
|
|
288
|
+
width: 16 / 9 * e,
|
|
289
|
+
height: e,
|
|
290
|
+
codec: "avc1,h.264",
|
|
291
|
+
bitrate: -1
|
|
292
|
+
}, t);
|
|
293
|
+
}
|
|
294
|
+
this.#P(e.find((e) => e.active), t);
|
|
295
|
+
}
|
|
296
|
+
#P({ id: e } = {}, t) {
|
|
297
|
+
if (!e) return;
|
|
298
|
+
let n = e === "auto", r = this.#e.qualities.getById(e);
|
|
299
|
+
n ? (this.#e.qualities[m.setAuto](n, t), this.#e.qualities[f.select](void 0, !0, t)) : this.#e.qualities[f.select](r ?? void 0, !0, t);
|
|
300
|
+
}
|
|
301
|
+
#F(e, t, n) {
|
|
302
|
+
switch (e) {
|
|
303
|
+
case "ready":
|
|
304
|
+
this.#S();
|
|
305
|
+
break;
|
|
306
|
+
case "loaded":
|
|
307
|
+
this.#y(n);
|
|
308
|
+
break;
|
|
309
|
+
case "play":
|
|
310
|
+
this.#w(n);
|
|
311
|
+
break;
|
|
312
|
+
case "playProgress":
|
|
313
|
+
this.#T(n);
|
|
314
|
+
break;
|
|
315
|
+
case "pause":
|
|
316
|
+
this.#C(n);
|
|
317
|
+
break;
|
|
318
|
+
case "loadProgress":
|
|
319
|
+
this.#E(t.seconds, n);
|
|
320
|
+
break;
|
|
321
|
+
case "waiting":
|
|
322
|
+
this.#k(n);
|
|
323
|
+
break;
|
|
324
|
+
case "bufferstart":
|
|
325
|
+
this.#D(n);
|
|
326
|
+
break;
|
|
327
|
+
case "bufferend":
|
|
328
|
+
this.#O(n);
|
|
329
|
+
break;
|
|
330
|
+
case "volumechange":
|
|
331
|
+
this.#A(t.volume, r(this.#e.$state.muted), n);
|
|
332
|
+
break;
|
|
333
|
+
case "durationchange":
|
|
334
|
+
this.#o = new h(0, t.duration), this.#e.notify("duration-change", t.duration, n);
|
|
335
|
+
break;
|
|
336
|
+
case "playbackratechange":
|
|
337
|
+
this.#e.notify("rate-change", t.playbackRate, n);
|
|
338
|
+
break;
|
|
339
|
+
case "qualitychange":
|
|
340
|
+
this.#P(t, n);
|
|
341
|
+
break;
|
|
342
|
+
case "fullscreenchange":
|
|
343
|
+
this.#a = t.fullscreen, this.#e.notify("fullscreen-change", t.fullscreen, n);
|
|
344
|
+
break;
|
|
345
|
+
case "enterpictureinpicture":
|
|
346
|
+
this.#e.notify("picture-in-picture-change", !0, n);
|
|
347
|
+
break;
|
|
348
|
+
case "leavepictureinpicture":
|
|
349
|
+
this.#e.notify("picture-in-picture-change", !1, n);
|
|
350
|
+
break;
|
|
351
|
+
case "ended":
|
|
352
|
+
this.#e.notify("end", void 0, n);
|
|
353
|
+
break;
|
|
354
|
+
case "error":
|
|
355
|
+
this.#I(t, n);
|
|
356
|
+
break;
|
|
357
|
+
case "seek":
|
|
358
|
+
case "seeked":
|
|
359
|
+
this.#v(t.seconds, n);
|
|
360
|
+
break;
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
#I(e, t) {
|
|
364
|
+
let { message: n, method: r } = e;
|
|
365
|
+
r === "setPlaybackRate" && this.#n.set(!1), r && this.#z(r)?.reject(n);
|
|
366
|
+
}
|
|
367
|
+
onMessage(e, t) {
|
|
368
|
+
e.event ? this.#F(e.event, e.data, t) : e.method && this.#x(e.method, e.value, t);
|
|
369
|
+
}
|
|
370
|
+
onLoad() {}
|
|
371
|
+
async #L(e, t) {
|
|
372
|
+
let n = i(), r = this.#u.get(e);
|
|
373
|
+
return r || this.#u.set(e, r = []), r.push(n), this.postMessage({
|
|
374
|
+
method: e,
|
|
375
|
+
value: t
|
|
376
|
+
}), n.promise;
|
|
377
|
+
}
|
|
378
|
+
#R() {
|
|
379
|
+
this.#s.stop(), this.#o = new h(0, 0), this.#d = null, this.#c = null, this.#n.set(!1), this.#M();
|
|
380
|
+
}
|
|
381
|
+
#z(e) {
|
|
382
|
+
return this.#u.get(e)?.shift();
|
|
383
|
+
}
|
|
384
|
+
};
|
|
385
|
+
//#endregion
|
|
386
|
+
export { v as VimeoProvider };
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
import { $ as e, I as t, N as n, P as r, T as i, g as a, h as o, v as s } from "./vidstack-BGSTndAW-CyKM_CM4.js";
|
|
2
|
+
import { i as c } from "./vidstack-CTojmhKq-D7sZJxgm.js";
|
|
3
|
+
import { resolveYouTubeVideoId as l } from "./vidstack-Dm1xEU9Q-VlefmrP8.js";
|
|
4
|
+
import { t as u } from "./vidstack-ChQTHmIQ-nTO94M6P.js";
|
|
5
|
+
import { t as d } from "./vidstack-DDXt6fpN-Don_e6LS.js";
|
|
6
|
+
//#region node_modules/vidstack/prod/providers/vidstack-youtube.js
|
|
7
|
+
var f = {
|
|
8
|
+
Ended: 0,
|
|
9
|
+
Playing: 1,
|
|
10
|
+
Paused: 2,
|
|
11
|
+
Buffering: 3,
|
|
12
|
+
Cued: 5
|
|
13
|
+
}, p = class extends d {
|
|
14
|
+
$$PROVIDER_TYPE = "YOUTUBE";
|
|
15
|
+
scope = o();
|
|
16
|
+
#e;
|
|
17
|
+
#t = e("");
|
|
18
|
+
#n = -1;
|
|
19
|
+
#r = null;
|
|
20
|
+
#i = -1;
|
|
21
|
+
#a = !1;
|
|
22
|
+
#o = /* @__PURE__ */ new Map();
|
|
23
|
+
constructor(e, t) {
|
|
24
|
+
super(e), this.#e = t;
|
|
25
|
+
}
|
|
26
|
+
language = "en";
|
|
27
|
+
color = "red";
|
|
28
|
+
cookies = !1;
|
|
29
|
+
get currentSrc() {
|
|
30
|
+
return this.#r;
|
|
31
|
+
}
|
|
32
|
+
get type() {
|
|
33
|
+
return "youtube";
|
|
34
|
+
}
|
|
35
|
+
get videoId() {
|
|
36
|
+
return this.#t();
|
|
37
|
+
}
|
|
38
|
+
preconnect() {
|
|
39
|
+
c(this.getOrigin());
|
|
40
|
+
}
|
|
41
|
+
setup() {
|
|
42
|
+
super.setup(), s(this.#s.bind(this)), this.#e.notify("provider-setup", this);
|
|
43
|
+
}
|
|
44
|
+
destroy() {
|
|
45
|
+
this.#g();
|
|
46
|
+
for (let e of this.#o.values()) for (let { reject: t } of e) t("provider destroyed");
|
|
47
|
+
this.#o.clear();
|
|
48
|
+
}
|
|
49
|
+
async play() {
|
|
50
|
+
return this.#c("playVideo");
|
|
51
|
+
}
|
|
52
|
+
async pause() {
|
|
53
|
+
return this.#c("pauseVideo");
|
|
54
|
+
}
|
|
55
|
+
setMuted(e) {
|
|
56
|
+
e ? this.#c("mute") : this.#c("unMute");
|
|
57
|
+
}
|
|
58
|
+
setCurrentTime(e) {
|
|
59
|
+
this.#c("seekTo", e), this.#e.notify("seeking", e);
|
|
60
|
+
}
|
|
61
|
+
setVolume(e) {
|
|
62
|
+
this.#c("setVolume", e * 100);
|
|
63
|
+
}
|
|
64
|
+
setPlaybackRate(e) {
|
|
65
|
+
this.#c("setPlaybackRate", e);
|
|
66
|
+
}
|
|
67
|
+
async loadSource(e) {
|
|
68
|
+
if (!t(e.src)) {
|
|
69
|
+
this.#r = null, this.#t.set("");
|
|
70
|
+
return;
|
|
71
|
+
}
|
|
72
|
+
let n = l(e.src);
|
|
73
|
+
this.#t.set(n ?? ""), this.#r = e;
|
|
74
|
+
}
|
|
75
|
+
getOrigin() {
|
|
76
|
+
return this.cookies ? "https://www.youtube.com" : "https://www.youtube-nocookie.com";
|
|
77
|
+
}
|
|
78
|
+
#s() {
|
|
79
|
+
this.#g();
|
|
80
|
+
let e = this.#t();
|
|
81
|
+
if (!e) {
|
|
82
|
+
this.src.set("");
|
|
83
|
+
return;
|
|
84
|
+
}
|
|
85
|
+
this.src.set(`${this.getOrigin()}/embed/${e}`), this.#e.notify("load-start");
|
|
86
|
+
}
|
|
87
|
+
buildParams() {
|
|
88
|
+
let { keyDisabled: e } = this.#e.$props, { muted: t, playsInline: n, nativeControls: r } = this.#e.$state, i = r();
|
|
89
|
+
return {
|
|
90
|
+
rel: 0,
|
|
91
|
+
autoplay: 0,
|
|
92
|
+
cc_lang_pref: this.language,
|
|
93
|
+
cc_load_policy: i ? 1 : void 0,
|
|
94
|
+
color: this.color,
|
|
95
|
+
controls: +!!i,
|
|
96
|
+
disablekb: !i || e() ? 1 : 0,
|
|
97
|
+
enablejsapi: 1,
|
|
98
|
+
fs: 1,
|
|
99
|
+
hl: this.language,
|
|
100
|
+
iv_load_policy: i ? 1 : 3,
|
|
101
|
+
mute: +!!t(),
|
|
102
|
+
playsinline: +!!n()
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
#c(e, t) {
|
|
106
|
+
let n = a(), r = this.#o.get(e);
|
|
107
|
+
return r || this.#o.set(e, r = []), r.push(n), this.postMessage({
|
|
108
|
+
event: "command",
|
|
109
|
+
func: e,
|
|
110
|
+
args: t ? [t] : void 0
|
|
111
|
+
}), n.promise;
|
|
112
|
+
}
|
|
113
|
+
onLoad() {
|
|
114
|
+
window.setTimeout(() => this.postMessage({ event: "listening" }), 100);
|
|
115
|
+
}
|
|
116
|
+
#l(e) {
|
|
117
|
+
this.#e.notify("loaded-metadata"), this.#e.notify("loaded-data"), this.#e.delegate.ready(void 0, e);
|
|
118
|
+
}
|
|
119
|
+
#u(e) {
|
|
120
|
+
this.#_("pauseVideo")?.resolve(), this.#e.notify("pause", void 0, e);
|
|
121
|
+
}
|
|
122
|
+
#d(e, t) {
|
|
123
|
+
let { duration: n, realCurrentTime: r } = this.#e.$state, i = this.#n === f.Ended, a = i ? n() : e;
|
|
124
|
+
this.#e.notify("time-change", a, t), !i && Math.abs(a - r()) > 1 && this.#e.notify("seeking", a, t);
|
|
125
|
+
}
|
|
126
|
+
#f(e, t, n) {
|
|
127
|
+
let r = {
|
|
128
|
+
buffered: new u(0, e),
|
|
129
|
+
seekable: t
|
|
130
|
+
};
|
|
131
|
+
this.#e.notify("progress", r, n);
|
|
132
|
+
let { seeking: i, realCurrentTime: a } = this.#e.$state;
|
|
133
|
+
i() && e > a() && this.#p(n);
|
|
134
|
+
}
|
|
135
|
+
#p(e) {
|
|
136
|
+
let { paused: t, realCurrentTime: n } = this.#e.$state;
|
|
137
|
+
window.clearTimeout(this.#i), this.#i = window.setTimeout(() => {
|
|
138
|
+
this.#e.notify("seeked", n(), e), this.#i = -1;
|
|
139
|
+
}, t() ? 100 : 0);
|
|
140
|
+
}
|
|
141
|
+
#m(e) {
|
|
142
|
+
let { seeking: t } = this.#e.$state;
|
|
143
|
+
t() && this.#p(e), this.#e.notify("pause", void 0, e), this.#e.notify("end", void 0, e);
|
|
144
|
+
}
|
|
145
|
+
#h(e, t) {
|
|
146
|
+
let { paused: n, seeking: r } = this.#e.$state, i = e === f.Playing, a = e === f.Buffering, o = this.#v("playVideo"), s = n() && (a || i);
|
|
147
|
+
if (a && this.#e.notify("waiting", void 0, t), r() && i && this.#p(t), this.#a && i) {
|
|
148
|
+
this.pause(), this.#a = !1, this.setMuted(this.#e.$state.muted());
|
|
149
|
+
return;
|
|
150
|
+
}
|
|
151
|
+
if (!o && s) {
|
|
152
|
+
this.#a = !0, this.setMuted(!0);
|
|
153
|
+
return;
|
|
154
|
+
}
|
|
155
|
+
switch (s && (this.#_("playVideo")?.resolve(), this.#e.notify("play", void 0, t)), e) {
|
|
156
|
+
case f.Cued:
|
|
157
|
+
this.#l(t);
|
|
158
|
+
break;
|
|
159
|
+
case f.Playing:
|
|
160
|
+
this.#e.notify("playing", void 0, t);
|
|
161
|
+
break;
|
|
162
|
+
case f.Paused:
|
|
163
|
+
this.#u(t);
|
|
164
|
+
break;
|
|
165
|
+
case f.Ended:
|
|
166
|
+
this.#m(t);
|
|
167
|
+
break;
|
|
168
|
+
}
|
|
169
|
+
this.#n = e;
|
|
170
|
+
}
|
|
171
|
+
onMessage({ info: e }, t) {
|
|
172
|
+
if (!e) return;
|
|
173
|
+
let { title: a, intrinsicDuration: o, playbackRate: s } = this.#e.$state;
|
|
174
|
+
if (r(e.videoData) && e.videoData.title !== a() && this.#e.notify("title-change", e.videoData.title, t), n(e.duration) && e.duration !== o()) {
|
|
175
|
+
if (n(e.videoLoadedFraction)) {
|
|
176
|
+
let n = e.progressState?.loaded ?? e.videoLoadedFraction * e.duration, r = new u(0, e.duration);
|
|
177
|
+
this.#f(n, r, t);
|
|
178
|
+
}
|
|
179
|
+
this.#e.notify("duration-change", e.duration, t);
|
|
180
|
+
}
|
|
181
|
+
if (n(e.playbackRate) && e.playbackRate !== s() && this.#e.notify("rate-change", e.playbackRate, t), e.progressState) {
|
|
182
|
+
let { current: n, seekableStart: r, seekableEnd: i, loaded: a, duration: s } = e.progressState;
|
|
183
|
+
this.#d(n, t), this.#f(a, new u(r, i), t), s !== o() && this.#e.notify("duration-change", s, t);
|
|
184
|
+
}
|
|
185
|
+
if (n(e.volume) && i(e.muted) && !this.#a) {
|
|
186
|
+
let n = {
|
|
187
|
+
muted: e.muted,
|
|
188
|
+
volume: e.volume / 100
|
|
189
|
+
};
|
|
190
|
+
this.#e.notify("volume-change", n, t);
|
|
191
|
+
}
|
|
192
|
+
n(e.playerState) && e.playerState !== this.#n && this.#h(e.playerState, t);
|
|
193
|
+
}
|
|
194
|
+
#g() {
|
|
195
|
+
this.#n = -1, this.#i = -1, this.#a = !1;
|
|
196
|
+
}
|
|
197
|
+
#_(e) {
|
|
198
|
+
return this.#o.get(e)?.shift();
|
|
199
|
+
}
|
|
200
|
+
#v(e) {
|
|
201
|
+
return !!this.#o.get(e)?.length;
|
|
202
|
+
}
|
|
203
|
+
};
|
|
204
|
+
//#endregion
|
|
205
|
+
export { p as YouTubeProvider };
|