classicy 0.6.1 → 0.6.8
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/package.json +6 -3
- package/dist/Preview-DFWgeXbD.js +0 -87
- package/dist/Preview-DFWgeXbD.js.map +0 -1
- package/dist/classicy.css +0 -1
- package/dist/classicy.es.js +0 -34154
- package/dist/classicy.es.js.map +0 -1
- package/dist/classicy.umd.js +0 -3619
- package/dist/classicy.umd.js.map +0 -1
- package/dist/dash.all.min-DWS2dLrE.js +0 -18789
- package/dist/dash.all.min-DWS2dLrE.js.map +0 -1
- package/dist/hls-BoR3u0PC.js +0 -21705
- package/dist/hls-BoR3u0PC.js.map +0 -1
- package/dist/index-Cd0v-WM7.js +0 -15697
- package/dist/index-Cd0v-WM7.js.map +0 -1
- package/dist/mixin-CkMUTfmX.js +0 -731
- package/dist/mixin-CkMUTfmX.js.map +0 -1
- package/dist/react-BnzwZp9T.js +0 -357
- package/dist/react-BnzwZp9T.js.map +0 -1
- package/dist/react-BzHiAeII.js +0 -402
- package/dist/react-BzHiAeII.js.map +0 -1
- package/dist/react-Ct5L317G.js +0 -217
- package/dist/react-Ct5L317G.js.map +0 -1
- package/dist/react-DY0DOTNY.js +0 -356
- package/dist/react-DY0DOTNY.js.map +0 -1
- package/dist/react-D_7TFUvN.js +0 -437
- package/dist/react-D_7TFUvN.js.map +0 -1
- package/dist/react-Ql_PNI5h.js +0 -267
- package/dist/react-Ql_PNI5h.js.map +0 -1
- package/dist/react-_-oMoy3X.js +0 -503
- package/dist/react-_-oMoy3X.js.map +0 -1
- package/dist/react-b5Gp0-6S.js +0 -3067
- package/dist/react-b5Gp0-6S.js.map +0 -1
- package/dist/sounds/platinum/platinum.ac3 +0 -0
- package/dist/sounds/platinum/platinum.caf +0 -0
- package/dist/sounds/platinum/platinum.json +0 -174
- package/dist/sounds/platinum/platinum.m4a +0 -0
- package/dist/sounds/platinum/platinum.mp3 +0 -0
- package/dist/sounds/platinum/platinum.ogg +0 -0
- package/dist/sounds/platinum/platinum.wav +0 -0
- package/dist/types/assets/sounds/platinum/platinum.json.d.ts +0 -176
- package/dist/types/src/SystemFolder/ControlPanels/AppManager/ClassicyAppManager.d.ts +0 -98
- package/dist/types/src/SystemFolder/ControlPanels/AppManager/ClassicyAppManager.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppManager/ClassicyAppManagerContext.d.ts +0 -9
- package/dist/types/src/SystemFolder/ControlPanels/AppManager/ClassicyAppManagerContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppManager/ClassicyAppManagerUtils.d.ts +0 -7
- package/dist/types/src/SystemFolder/ControlPanels/AppManager/ClassicyAppManagerUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicyAppearance.d.ts +0 -120
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicyAppearance.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicyAppearanceManager.d.ts +0 -3
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicyAppearanceManager.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicyColors.d.ts +0 -3
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicyColors.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicySize.d.ts +0 -5
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/ClassicySize.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/AppearanceManager/styles/themes.json.d.ts +0 -1433
- package/dist/types/src/SystemFolder/ControlPanels/ClassicyControlPanels.d.ts +0 -2
- package/dist/types/src/SystemFolder/ControlPanels/ClassicyControlPanels.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/DateAndTimeManager/ClassicyDateAndTimeManager.d.ts +0 -3
- package/dist/types/src/SystemFolder/ControlPanels/DateAndTimeManager/ClassicyDateAndTimeManager.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/DateAndTimeManager/ClassicyDateAndTimeManagerUtils.d.ts +0 -3
- package/dist/types/src/SystemFolder/ControlPanels/DateAndTimeManager/ClassicyDateAndTimeManagerUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/SoundManager/ClassicySoundManager.d.ts +0 -3
- package/dist/types/src/SystemFolder/ControlPanels/SoundManager/ClassicySoundManager.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/SoundManager/ClassicySoundManagerContext.d.ts +0 -79
- package/dist/types/src/SystemFolder/ControlPanels/SoundManager/ClassicySoundManagerContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/ControlPanels/SoundManager/ClassicySoundManagerLabels.json.d.ts +0 -185
- package/dist/types/src/SystemFolder/Finder/Finder.d.ts +0 -2
- package/dist/types/src/SystemFolder/Finder/Finder.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/Finder/FinderContext.d.ts +0 -3
- package/dist/types/src/SystemFolder/Finder/FinderContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/QuickTime/MoviePlayer/MoviePlayer.d.ts +0 -3
- package/dist/types/src/SystemFolder/QuickTime/MoviePlayer/MoviePlayer.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/QuickTime/MoviePlayer/MoviePlayerContext.d.ts +0 -16
- package/dist/types/src/SystemFolder/QuickTime/MoviePlayer/MoviePlayerContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/QuickTime/MoviePlayer/MoviePlayerUtils.d.ts +0 -14
- package/dist/types/src/SystemFolder/QuickTime/MoviePlayer/MoviePlayerUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/QuickTime/PictureViewer/PictureViewer.d.ts +0 -13
- package/dist/types/src/SystemFolder/QuickTime/PictureViewer/PictureViewer.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/QuickTime/PictureViewer/PictureViewerContext.d.ts +0 -10
- package/dist/types/src/SystemFolder/QuickTime/PictureViewer/PictureViewerContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/AboutWindow/ClassicyAboutWindow.d.ts +0 -11
- package/dist/types/src/SystemFolder/SystemResources/AboutWindow/ClassicyAboutWindow.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/AboutWindow/ClassicyAboutWindowUtils.d.ts +0 -3
- package/dist/types/src/SystemFolder/SystemResources/AboutWindow/ClassicyAboutWindowUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Analytics/useClassicyAnalytics.d.ts +0 -27
- package/dist/types/src/SystemFolder/SystemResources/Analytics/useClassicyAnalytics.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/App/ClassicyApp.d.ts +0 -13
- package/dist/types/src/SystemFolder/SystemResources/App/ClassicyApp.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/App/ClassicyAppUtils.d.ts +0 -21
- package/dist/types/src/SystemFolder/SystemResources/App/ClassicyAppUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Boot/ClassicyBoot.d.ts +0 -3
- package/dist/types/src/SystemFolder/SystemResources/Boot/ClassicyBoot.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Button/ClassicyButton.d.ts +0 -12
- package/dist/types/src/SystemFolder/SystemResources/Button/ClassicyButton.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Checkbox/ClassicyCheckbox.d.ts +0 -12
- package/dist/types/src/SystemFolder/SystemResources/Checkbox/ClassicyCheckbox.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/ContextualMenu/ClassicyContextualMenu.d.ts +0 -10
- package/dist/types/src/SystemFolder/SystemResources/ContextualMenu/ClassicyContextualMenu.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/ControlGroup/ClassicyControlGroup.d.ts +0 -9
- package/dist/types/src/SystemFolder/SystemResources/ControlGroup/ClassicyControlGroup.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/ControlLabel/ClassicyControlLabel.d.ts +0 -17
- package/dist/types/src/SystemFolder/SystemResources/ControlLabel/ClassicyControlLabel.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/DatePicker/ClassicyDatePicker.d.ts +0 -14
- package/dist/types/src/SystemFolder/SystemResources/DatePicker/ClassicyDatePicker.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/DatePicker/ClassicyDatePickerUtils.d.ts +0 -3
- package/dist/types/src/SystemFolder/SystemResources/DatePicker/ClassicyDatePickerUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktop.d.ts +0 -7
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktop.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopIcon.d.ts +0 -14
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopIcon.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopIconContext.d.ts +0 -5
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopIconContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopManager.d.ts +0 -30
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopManager.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopWindowManagerContext.d.ts +0 -108
- package/dist/types/src/SystemFolder/SystemResources/Desktop/ClassicyDesktopWindowManagerContext.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/MenuBar/ClassicyDesktopMenuBar.d.ts +0 -3
- package/dist/types/src/SystemFolder/SystemResources/Desktop/MenuBar/ClassicyDesktopMenuBar.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/MenuBar/Widgets/Sound/ClassicyDesktopMenuWidgetSound.d.ts +0 -7
- package/dist/types/src/SystemFolder/SystemResources/Desktop/MenuBar/Widgets/Sound/ClassicyDesktopMenuWidgetSound.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Desktop/MenuBar/Widgets/Time/ClassicyDesktopMenuWidgetTime.d.ts +0 -3
- package/dist/types/src/SystemFolder/SystemResources/Desktop/MenuBar/Widgets/Time/ClassicyDesktopMenuWidgetTime.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Disclosure/ClassicyDisclosure.d.ts +0 -10
- package/dist/types/src/SystemFolder/SystemResources/Disclosure/ClassicyDisclosure.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowser.d.ts +0 -13
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowser.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowserUtils.d.ts +0 -7
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowserUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowserViewIcons.d.ts +0 -12
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowserViewIcons.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowserViewTable.d.ts +0 -14
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileBrowserViewTable.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileSystem.d.ts +0 -29
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileSystem.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileSystemModel.d.ts +0 -37
- package/dist/types/src/SystemFolder/SystemResources/File/ClassicyFileSystemModel.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/File/DefaultClassicyFileSystem.d.ts +0 -94
- package/dist/types/src/SystemFolder/SystemResources/File/DefaultClassicyFileSystem.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Icon/ClassicyIcon.d.ts +0 -14
- package/dist/types/src/SystemFolder/SystemResources/Icon/ClassicyIcon.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Input/ClassicyInput.d.ts +0 -15
- package/dist/types/src/SystemFolder/SystemResources/Input/ClassicyInput.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Menu/ClassicyMenu.d.ts +0 -29
- package/dist/types/src/SystemFolder/SystemResources/Menu/ClassicyMenu.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/PopUpMenu/ClassicyPopUpMenu.d.ts +0 -18
- package/dist/types/src/SystemFolder/SystemResources/PopUpMenu/ClassicyPopUpMenu.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/ProgressBar/ClassicyProgressBar.d.ts +0 -1
- package/dist/types/src/SystemFolder/SystemResources/ProgressBar/ClassicyProgressBar.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/QuickTime/QuickTimeMovieEmbed.d.ts +0 -16
- package/dist/types/src/SystemFolder/SystemResources/QuickTime/QuickTimeMovieEmbed.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/QuickTime/QuickTimeUtils.d.ts +0 -3
- package/dist/types/src/SystemFolder/SystemResources/QuickTime/QuickTimeUtils.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/RadioInput/ClassicyRadioInput.d.ts +0 -20
- package/dist/types/src/SystemFolder/SystemResources/RadioInput/ClassicyRadioInput.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/RichTextEditor/ClassicyRichTextEditor.d.ts +0 -9
- package/dist/types/src/SystemFolder/SystemResources/RichTextEditor/ClassicyRichTextEditor.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Tabs/ClassicyTabs.d.ts +0 -11
- package/dist/types/src/SystemFolder/SystemResources/Tabs/ClassicyTabs.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/TextEditor/ClassicyTextEditor.d.ts +0 -1
- package/dist/types/src/SystemFolder/SystemResources/TextEditor/ClassicyTextEditor.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/TimePicker/ClassicyTimePicker.d.ts +0 -15
- package/dist/types/src/SystemFolder/SystemResources/TimePicker/ClassicyTimePicker.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Window/ClassicyWindow.d.ts +0 -29
- package/dist/types/src/SystemFolder/SystemResources/Window/ClassicyWindow.d.ts.map +0 -1
- package/dist/types/src/SystemFolder/SystemResources/Window/ClassicyWindowContext.d.ts +0 -19
- package/dist/types/src/SystemFolder/SystemResources/Window/ClassicyWindowContext.d.ts.map +0 -1
- package/dist/types/src/index.d.ts +0 -58
- package/dist/types/src/index.d.ts.map +0 -1
- package/dist/types/vite.config.d.ts +0 -3
- package/dist/types/vite.config.d.ts.map +0 -1
package/dist/react-b5Gp0-6S.js
DELETED
|
@@ -1,3067 +0,0 @@
|
|
|
1
|
-
import Re from "react";
|
|
2
|
-
function ce(r, e) {
|
|
3
|
-
var t = Object.keys(r);
|
|
4
|
-
if (Object.getOwnPropertySymbols) {
|
|
5
|
-
var n = Object.getOwnPropertySymbols(r);
|
|
6
|
-
e && (n = n.filter(function(i) {
|
|
7
|
-
return Object.getOwnPropertyDescriptor(r, i).enumerable;
|
|
8
|
-
})), t.push.apply(t, n);
|
|
9
|
-
}
|
|
10
|
-
return t;
|
|
11
|
-
}
|
|
12
|
-
function fe(r) {
|
|
13
|
-
for (var e = 1; e < arguments.length; e++) {
|
|
14
|
-
var t = arguments[e] != null ? arguments[e] : {};
|
|
15
|
-
e % 2 ? ce(Object(t), !0).forEach(function(n) {
|
|
16
|
-
X(r, n, t[n]);
|
|
17
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(r, Object.getOwnPropertyDescriptors(t)) : ce(Object(t)).forEach(function(n) {
|
|
18
|
-
Object.defineProperty(r, n, Object.getOwnPropertyDescriptor(t, n));
|
|
19
|
-
});
|
|
20
|
-
}
|
|
21
|
-
return r;
|
|
22
|
-
}
|
|
23
|
-
function R() {
|
|
24
|
-
R = function() {
|
|
25
|
-
return r;
|
|
26
|
-
};
|
|
27
|
-
var r = {}, e = Object.prototype, t = e.hasOwnProperty, n = Object.defineProperty || function(c, l, d) {
|
|
28
|
-
c[l] = d.value;
|
|
29
|
-
}, i = typeof Symbol == "function" ? Symbol : {}, a = i.iterator || "@@iterator", u = i.asyncIterator || "@@asyncIterator", s = i.toStringTag || "@@toStringTag";
|
|
30
|
-
function h(c, l, d) {
|
|
31
|
-
return Object.defineProperty(c, l, {
|
|
32
|
-
value: d,
|
|
33
|
-
enumerable: !0,
|
|
34
|
-
configurable: !0,
|
|
35
|
-
writable: !0
|
|
36
|
-
}), c[l];
|
|
37
|
-
}
|
|
38
|
-
try {
|
|
39
|
-
h({}, "");
|
|
40
|
-
} catch {
|
|
41
|
-
h = function(l, d, M) {
|
|
42
|
-
return l[d] = M;
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
|
-
function o(c, l, d, M) {
|
|
46
|
-
var w = l && l.prototype instanceof T ? l : T, C = Object.create(w.prototype), A = new j(M || []);
|
|
47
|
-
return n(C, "_invoke", {
|
|
48
|
-
value: v(c, d, A)
|
|
49
|
-
}), C;
|
|
50
|
-
}
|
|
51
|
-
function b(c, l, d) {
|
|
52
|
-
try {
|
|
53
|
-
return {
|
|
54
|
-
type: "normal",
|
|
55
|
-
arg: c.call(l, d)
|
|
56
|
-
};
|
|
57
|
-
} catch (M) {
|
|
58
|
-
return {
|
|
59
|
-
type: "throw",
|
|
60
|
-
arg: M
|
|
61
|
-
};
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
r.wrap = o;
|
|
65
|
-
var k = {};
|
|
66
|
-
function T() {
|
|
67
|
-
}
|
|
68
|
-
function P() {
|
|
69
|
-
}
|
|
70
|
-
function g() {
|
|
71
|
-
}
|
|
72
|
-
var _ = {};
|
|
73
|
-
h(_, a, function() {
|
|
74
|
-
return this;
|
|
75
|
-
});
|
|
76
|
-
var O = Object.getPrototypeOf, N = O && O(O($([])));
|
|
77
|
-
N && N !== e && t.call(N, a) && (_ = N);
|
|
78
|
-
var m = g.prototype = T.prototype = Object.create(_);
|
|
79
|
-
function p(c) {
|
|
80
|
-
["next", "throw", "return"].forEach(function(l) {
|
|
81
|
-
h(c, l, function(d) {
|
|
82
|
-
return this._invoke(l, d);
|
|
83
|
-
});
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
function f(c, l) {
|
|
87
|
-
function d(w, C, A, I) {
|
|
88
|
-
var F = b(c[w], c, C);
|
|
89
|
-
if (F.type !== "throw") {
|
|
90
|
-
var H = F.arg, U = H.value;
|
|
91
|
-
return U && typeof U == "object" && t.call(U, "__await") ? l.resolve(U.__await).then(function(D) {
|
|
92
|
-
d("next", D, A, I);
|
|
93
|
-
}, function(D) {
|
|
94
|
-
d("throw", D, A, I);
|
|
95
|
-
}) : l.resolve(U).then(function(D) {
|
|
96
|
-
H.value = D, A(H);
|
|
97
|
-
}, function(D) {
|
|
98
|
-
return d("throw", D, A, I);
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
I(F.arg);
|
|
102
|
-
}
|
|
103
|
-
var M;
|
|
104
|
-
n(this, "_invoke", {
|
|
105
|
-
value: function(w, C) {
|
|
106
|
-
function A() {
|
|
107
|
-
return new l(function(I, F) {
|
|
108
|
-
d(w, C, I, F);
|
|
109
|
-
});
|
|
110
|
-
}
|
|
111
|
-
return M = M ? M.then(A, A) : A();
|
|
112
|
-
}
|
|
113
|
-
});
|
|
114
|
-
}
|
|
115
|
-
function v(c, l, d) {
|
|
116
|
-
var M = "suspendedStart";
|
|
117
|
-
return function(w, C) {
|
|
118
|
-
if (M === "executing") throw new Error("Generator is already running");
|
|
119
|
-
if (M === "completed") {
|
|
120
|
-
if (w === "throw") throw C;
|
|
121
|
-
return ne();
|
|
122
|
-
}
|
|
123
|
-
for (d.method = w, d.arg = C; ; ) {
|
|
124
|
-
var A = d.delegate;
|
|
125
|
-
if (A) {
|
|
126
|
-
var I = E(A, d);
|
|
127
|
-
if (I) {
|
|
128
|
-
if (I === k) continue;
|
|
129
|
-
return I;
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
if (d.method === "next") d.sent = d._sent = d.arg;
|
|
133
|
-
else if (d.method === "throw") {
|
|
134
|
-
if (M === "suspendedStart") throw M = "completed", d.arg;
|
|
135
|
-
d.dispatchException(d.arg);
|
|
136
|
-
} else d.method === "return" && d.abrupt("return", d.arg);
|
|
137
|
-
M = "executing";
|
|
138
|
-
var F = b(c, l, d);
|
|
139
|
-
if (F.type === "normal") {
|
|
140
|
-
if (M = d.done ? "completed" : "suspendedYield", F.arg === k) continue;
|
|
141
|
-
return {
|
|
142
|
-
value: F.arg,
|
|
143
|
-
done: d.done
|
|
144
|
-
};
|
|
145
|
-
}
|
|
146
|
-
F.type === "throw" && (M = "completed", d.method = "throw", d.arg = F.arg);
|
|
147
|
-
}
|
|
148
|
-
};
|
|
149
|
-
}
|
|
150
|
-
function E(c, l) {
|
|
151
|
-
var d = l.method, M = c.iterator[d];
|
|
152
|
-
if (M === void 0) return l.delegate = null, d === "throw" && c.iterator.return && (l.method = "return", l.arg = void 0, E(c, l), l.method === "throw") || d !== "return" && (l.method = "throw", l.arg = new TypeError("The iterator does not provide a '" + d + "' method")), k;
|
|
153
|
-
var w = b(M, c.iterator, l.arg);
|
|
154
|
-
if (w.type === "throw") return l.method = "throw", l.arg = w.arg, l.delegate = null, k;
|
|
155
|
-
var C = w.arg;
|
|
156
|
-
return C ? C.done ? (l[c.resultName] = C.value, l.next = c.nextLoc, l.method !== "return" && (l.method = "next", l.arg = void 0), l.delegate = null, k) : C : (l.method = "throw", l.arg = new TypeError("iterator result is not an object"), l.delegate = null, k);
|
|
157
|
-
}
|
|
158
|
-
function S(c) {
|
|
159
|
-
var l = {
|
|
160
|
-
tryLoc: c[0]
|
|
161
|
-
};
|
|
162
|
-
1 in c && (l.catchLoc = c[1]), 2 in c && (l.finallyLoc = c[2], l.afterLoc = c[3]), this.tryEntries.push(l);
|
|
163
|
-
}
|
|
164
|
-
function y(c) {
|
|
165
|
-
var l = c.completion || {};
|
|
166
|
-
l.type = "normal", delete l.arg, c.completion = l;
|
|
167
|
-
}
|
|
168
|
-
function j(c) {
|
|
169
|
-
this.tryEntries = [{
|
|
170
|
-
tryLoc: "root"
|
|
171
|
-
}], c.forEach(S, this), this.reset(!0);
|
|
172
|
-
}
|
|
173
|
-
function $(c) {
|
|
174
|
-
if (c) {
|
|
175
|
-
var l = c[a];
|
|
176
|
-
if (l) return l.call(c);
|
|
177
|
-
if (typeof c.next == "function") return c;
|
|
178
|
-
if (!isNaN(c.length)) {
|
|
179
|
-
var d = -1, M = function w() {
|
|
180
|
-
for (; ++d < c.length; ) if (t.call(c, d)) return w.value = c[d], w.done = !1, w;
|
|
181
|
-
return w.value = void 0, w.done = !0, w;
|
|
182
|
-
};
|
|
183
|
-
return M.next = M;
|
|
184
|
-
}
|
|
185
|
-
}
|
|
186
|
-
return {
|
|
187
|
-
next: ne
|
|
188
|
-
};
|
|
189
|
-
}
|
|
190
|
-
function ne() {
|
|
191
|
-
return {
|
|
192
|
-
value: void 0,
|
|
193
|
-
done: !0
|
|
194
|
-
};
|
|
195
|
-
}
|
|
196
|
-
return P.prototype = g, n(m, "constructor", {
|
|
197
|
-
value: g,
|
|
198
|
-
configurable: !0
|
|
199
|
-
}), n(g, "constructor", {
|
|
200
|
-
value: P,
|
|
201
|
-
configurable: !0
|
|
202
|
-
}), P.displayName = h(g, s, "GeneratorFunction"), r.isGeneratorFunction = function(c) {
|
|
203
|
-
var l = typeof c == "function" && c.constructor;
|
|
204
|
-
return !!l && (l === P || (l.displayName || l.name) === "GeneratorFunction");
|
|
205
|
-
}, r.mark = function(c) {
|
|
206
|
-
return Object.setPrototypeOf ? Object.setPrototypeOf(c, g) : (c.__proto__ = g, h(c, s, "GeneratorFunction")), c.prototype = Object.create(m), c;
|
|
207
|
-
}, r.awrap = function(c) {
|
|
208
|
-
return {
|
|
209
|
-
__await: c
|
|
210
|
-
};
|
|
211
|
-
}, p(f.prototype), h(f.prototype, u, function() {
|
|
212
|
-
return this;
|
|
213
|
-
}), r.AsyncIterator = f, r.async = function(c, l, d, M, w) {
|
|
214
|
-
w === void 0 && (w = Promise);
|
|
215
|
-
var C = new f(o(c, l, d, M), w);
|
|
216
|
-
return r.isGeneratorFunction(l) ? C : C.next().then(function(A) {
|
|
217
|
-
return A.done ? A.value : C.next();
|
|
218
|
-
});
|
|
219
|
-
}, p(m), h(m, s, "Generator"), h(m, a, function() {
|
|
220
|
-
return this;
|
|
221
|
-
}), h(m, "toString", function() {
|
|
222
|
-
return "[object Generator]";
|
|
223
|
-
}), r.keys = function(c) {
|
|
224
|
-
var l = Object(c), d = [];
|
|
225
|
-
for (var M in l) d.push(M);
|
|
226
|
-
return d.reverse(), function w() {
|
|
227
|
-
for (; d.length; ) {
|
|
228
|
-
var C = d.pop();
|
|
229
|
-
if (C in l) return w.value = C, w.done = !1, w;
|
|
230
|
-
}
|
|
231
|
-
return w.done = !0, w;
|
|
232
|
-
};
|
|
233
|
-
}, r.values = $, j.prototype = {
|
|
234
|
-
constructor: j,
|
|
235
|
-
reset: function(c) {
|
|
236
|
-
if (this.prev = 0, this.next = 0, this.sent = this._sent = void 0, this.done = !1, this.delegate = null, this.method = "next", this.arg = void 0, this.tryEntries.forEach(y), !c) for (var l in this) l.charAt(0) === "t" && t.call(this, l) && !isNaN(+l.slice(1)) && (this[l] = void 0);
|
|
237
|
-
},
|
|
238
|
-
stop: function() {
|
|
239
|
-
this.done = !0;
|
|
240
|
-
var c = this.tryEntries[0].completion;
|
|
241
|
-
if (c.type === "throw") throw c.arg;
|
|
242
|
-
return this.rval;
|
|
243
|
-
},
|
|
244
|
-
dispatchException: function(c) {
|
|
245
|
-
if (this.done) throw c;
|
|
246
|
-
var l = this;
|
|
247
|
-
function d(F, H) {
|
|
248
|
-
return C.type = "throw", C.arg = c, l.next = F, H && (l.method = "next", l.arg = void 0), !!H;
|
|
249
|
-
}
|
|
250
|
-
for (var M = this.tryEntries.length - 1; M >= 0; --M) {
|
|
251
|
-
var w = this.tryEntries[M], C = w.completion;
|
|
252
|
-
if (w.tryLoc === "root") return d("end");
|
|
253
|
-
if (w.tryLoc <= this.prev) {
|
|
254
|
-
var A = t.call(w, "catchLoc"), I = t.call(w, "finallyLoc");
|
|
255
|
-
if (A && I) {
|
|
256
|
-
if (this.prev < w.catchLoc) return d(w.catchLoc, !0);
|
|
257
|
-
if (this.prev < w.finallyLoc) return d(w.finallyLoc);
|
|
258
|
-
} else if (A) {
|
|
259
|
-
if (this.prev < w.catchLoc) return d(w.catchLoc, !0);
|
|
260
|
-
} else {
|
|
261
|
-
if (!I) throw new Error("try statement without catch or finally");
|
|
262
|
-
if (this.prev < w.finallyLoc) return d(w.finallyLoc);
|
|
263
|
-
}
|
|
264
|
-
}
|
|
265
|
-
}
|
|
266
|
-
},
|
|
267
|
-
abrupt: function(c, l) {
|
|
268
|
-
for (var d = this.tryEntries.length - 1; d >= 0; --d) {
|
|
269
|
-
var M = this.tryEntries[d];
|
|
270
|
-
if (M.tryLoc <= this.prev && t.call(M, "finallyLoc") && this.prev < M.finallyLoc) {
|
|
271
|
-
var w = M;
|
|
272
|
-
break;
|
|
273
|
-
}
|
|
274
|
-
}
|
|
275
|
-
w && (c === "break" || c === "continue") && w.tryLoc <= l && l <= w.finallyLoc && (w = null);
|
|
276
|
-
var C = w ? w.completion : {};
|
|
277
|
-
return C.type = c, C.arg = l, w ? (this.method = "next", this.next = w.finallyLoc, k) : this.complete(C);
|
|
278
|
-
},
|
|
279
|
-
complete: function(c, l) {
|
|
280
|
-
if (c.type === "throw") throw c.arg;
|
|
281
|
-
return c.type === "break" || c.type === "continue" ? this.next = c.arg : c.type === "return" ? (this.rval = this.arg = c.arg, this.method = "return", this.next = "end") : c.type === "normal" && l && (this.next = l), k;
|
|
282
|
-
},
|
|
283
|
-
finish: function(c) {
|
|
284
|
-
for (var l = this.tryEntries.length - 1; l >= 0; --l) {
|
|
285
|
-
var d = this.tryEntries[l];
|
|
286
|
-
if (d.finallyLoc === c) return this.complete(d.completion, d.afterLoc), y(d), k;
|
|
287
|
-
}
|
|
288
|
-
},
|
|
289
|
-
catch: function(c) {
|
|
290
|
-
for (var l = this.tryEntries.length - 1; l >= 0; --l) {
|
|
291
|
-
var d = this.tryEntries[l];
|
|
292
|
-
if (d.tryLoc === c) {
|
|
293
|
-
var M = d.completion;
|
|
294
|
-
if (M.type === "throw") {
|
|
295
|
-
var w = M.arg;
|
|
296
|
-
y(d);
|
|
297
|
-
}
|
|
298
|
-
return w;
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
throw new Error("illegal catch attempt");
|
|
302
|
-
},
|
|
303
|
-
delegateYield: function(c, l, d) {
|
|
304
|
-
return this.delegate = {
|
|
305
|
-
iterator: $(c),
|
|
306
|
-
resultName: l,
|
|
307
|
-
nextLoc: d
|
|
308
|
-
}, this.method === "next" && (this.arg = void 0), k;
|
|
309
|
-
}
|
|
310
|
-
}, r;
|
|
311
|
-
}
|
|
312
|
-
function he(r, e, t, n, i, a, u) {
|
|
313
|
-
try {
|
|
314
|
-
var s = r[a](u), h = s.value;
|
|
315
|
-
} catch (o) {
|
|
316
|
-
t(o);
|
|
317
|
-
return;
|
|
318
|
-
}
|
|
319
|
-
s.done ? e(h) : Promise.resolve(h).then(n, i);
|
|
320
|
-
}
|
|
321
|
-
function W(r) {
|
|
322
|
-
return function() {
|
|
323
|
-
var e = this, t = arguments;
|
|
324
|
-
return new Promise(function(n, i) {
|
|
325
|
-
var a = r.apply(e, t);
|
|
326
|
-
function u(h) {
|
|
327
|
-
he(a, n, i, u, s, "next", h);
|
|
328
|
-
}
|
|
329
|
-
function s(h) {
|
|
330
|
-
he(a, n, i, u, s, "throw", h);
|
|
331
|
-
}
|
|
332
|
-
u(void 0);
|
|
333
|
-
});
|
|
334
|
-
};
|
|
335
|
-
}
|
|
336
|
-
function Ee(r, e) {
|
|
337
|
-
if (!(r instanceof e))
|
|
338
|
-
throw new TypeError("Cannot call a class as a function");
|
|
339
|
-
}
|
|
340
|
-
function Le(r, e) {
|
|
341
|
-
for (var t = 0; t < e.length; t++) {
|
|
342
|
-
var n = e[t];
|
|
343
|
-
n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(r, Te(n.key), n);
|
|
344
|
-
}
|
|
345
|
-
}
|
|
346
|
-
function ke(r, e, t) {
|
|
347
|
-
return e && Le(r.prototype, e), Object.defineProperty(r, "prototype", {
|
|
348
|
-
writable: !1
|
|
349
|
-
}), r;
|
|
350
|
-
}
|
|
351
|
-
function X(r, e, t) {
|
|
352
|
-
return e = Te(e), e in r ? Object.defineProperty(r, e, {
|
|
353
|
-
value: t,
|
|
354
|
-
enumerable: !0,
|
|
355
|
-
configurable: !0,
|
|
356
|
-
writable: !0
|
|
357
|
-
}) : r[e] = t, r;
|
|
358
|
-
}
|
|
359
|
-
function je(r, e) {
|
|
360
|
-
if (typeof e != "function" && e !== null)
|
|
361
|
-
throw new TypeError("Super expression must either be null or a function");
|
|
362
|
-
r.prototype = Object.create(e && e.prototype, {
|
|
363
|
-
constructor: {
|
|
364
|
-
value: r,
|
|
365
|
-
writable: !0,
|
|
366
|
-
configurable: !0
|
|
367
|
-
}
|
|
368
|
-
}), Object.defineProperty(r, "prototype", {
|
|
369
|
-
writable: !1
|
|
370
|
-
}), e && J(r, e);
|
|
371
|
-
}
|
|
372
|
-
function Y(r) {
|
|
373
|
-
return Y = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(t) {
|
|
374
|
-
return t.__proto__ || Object.getPrototypeOf(t);
|
|
375
|
-
}, Y(r);
|
|
376
|
-
}
|
|
377
|
-
function J(r, e) {
|
|
378
|
-
return J = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(n, i) {
|
|
379
|
-
return n.__proto__ = i, n;
|
|
380
|
-
}, J(r, e);
|
|
381
|
-
}
|
|
382
|
-
function Pe() {
|
|
383
|
-
if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
|
|
384
|
-
if (typeof Proxy == "function") return !0;
|
|
385
|
-
try {
|
|
386
|
-
return Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
387
|
-
})), !0;
|
|
388
|
-
} catch {
|
|
389
|
-
return !1;
|
|
390
|
-
}
|
|
391
|
-
}
|
|
392
|
-
function K(r, e, t) {
|
|
393
|
-
return Pe() ? K = Reflect.construct.bind() : K = function(i, a, u) {
|
|
394
|
-
var s = [null];
|
|
395
|
-
s.push.apply(s, a);
|
|
396
|
-
var h = Function.bind.apply(i, s), o = new h();
|
|
397
|
-
return u && J(o, u.prototype), o;
|
|
398
|
-
}, K.apply(null, arguments);
|
|
399
|
-
}
|
|
400
|
-
function Ie(r) {
|
|
401
|
-
return Function.toString.call(r).indexOf("[native code]") !== -1;
|
|
402
|
-
}
|
|
403
|
-
function ue(r) {
|
|
404
|
-
var e = typeof Map == "function" ? /* @__PURE__ */ new Map() : void 0;
|
|
405
|
-
return ue = function(n) {
|
|
406
|
-
if (n === null || !Ie(n)) return n;
|
|
407
|
-
if (typeof n != "function")
|
|
408
|
-
throw new TypeError("Super expression must either be null or a function");
|
|
409
|
-
if (typeof e < "u") {
|
|
410
|
-
if (e.has(n)) return e.get(n);
|
|
411
|
-
e.set(n, i);
|
|
412
|
-
}
|
|
413
|
-
function i() {
|
|
414
|
-
return K(n, arguments, Y(this).constructor);
|
|
415
|
-
}
|
|
416
|
-
return i.prototype = Object.create(n.prototype, {
|
|
417
|
-
constructor: {
|
|
418
|
-
value: i,
|
|
419
|
-
enumerable: !1,
|
|
420
|
-
writable: !0,
|
|
421
|
-
configurable: !0
|
|
422
|
-
}
|
|
423
|
-
}), J(i, n);
|
|
424
|
-
}, ue(r);
|
|
425
|
-
}
|
|
426
|
-
function Z(r) {
|
|
427
|
-
if (r === void 0)
|
|
428
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
429
|
-
return r;
|
|
430
|
-
}
|
|
431
|
-
function Fe(r, e) {
|
|
432
|
-
if (e && (typeof e == "object" || typeof e == "function"))
|
|
433
|
-
return e;
|
|
434
|
-
if (e !== void 0)
|
|
435
|
-
throw new TypeError("Derived constructors may only return object or undefined");
|
|
436
|
-
return Z(r);
|
|
437
|
-
}
|
|
438
|
-
function $e(r) {
|
|
439
|
-
var e = Pe();
|
|
440
|
-
return function() {
|
|
441
|
-
var n = Y(r), i;
|
|
442
|
-
if (e) {
|
|
443
|
-
var a = Y(this).constructor;
|
|
444
|
-
i = Reflect.construct(n, arguments, a);
|
|
445
|
-
} else
|
|
446
|
-
i = n.apply(this, arguments);
|
|
447
|
-
return Fe(this, i);
|
|
448
|
-
};
|
|
449
|
-
}
|
|
450
|
-
function qe(r, e) {
|
|
451
|
-
if (typeof r != "object" || r === null) return r;
|
|
452
|
-
var t = r[Symbol.toPrimitive];
|
|
453
|
-
if (t !== void 0) {
|
|
454
|
-
var n = t.call(r, e);
|
|
455
|
-
if (typeof n != "object") return n;
|
|
456
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
457
|
-
}
|
|
458
|
-
return String(r);
|
|
459
|
-
}
|
|
460
|
-
function Te(r) {
|
|
461
|
-
var e = qe(r, "string");
|
|
462
|
-
return typeof e == "symbol" ? e : String(e);
|
|
463
|
-
}
|
|
464
|
-
var Me = typeof global < "u" && {}.toString.call(global) === "[object global]";
|
|
465
|
-
function de(r, e) {
|
|
466
|
-
return r.indexOf(e.toLowerCase()) === 0 ? r : "".concat(e.toLowerCase()).concat(r.substr(0, 1).toUpperCase()).concat(r.substr(1));
|
|
467
|
-
}
|
|
468
|
-
function Ve(r) {
|
|
469
|
-
return !!(r && r.nodeType === 1 && "nodeName" in r && r.ownerDocument && r.ownerDocument.defaultView);
|
|
470
|
-
}
|
|
471
|
-
function De(r) {
|
|
472
|
-
return !isNaN(parseFloat(r)) && isFinite(r) && Math.floor(r) == r;
|
|
473
|
-
}
|
|
474
|
-
function z(r) {
|
|
475
|
-
return /^(https?:)?\/\/((((player|www)\.)?vimeo\.com)|((player\.)?[a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))(?=$|\/)/.test(r);
|
|
476
|
-
}
|
|
477
|
-
function Se(r) {
|
|
478
|
-
var e = /^https:\/\/player\.((vimeo\.com)|([a-zA-Z0-9-]+\.(videoji\.(hk|cn)|vimeo\.work)))\/video\/\d+/;
|
|
479
|
-
return e.test(r);
|
|
480
|
-
}
|
|
481
|
-
function xe(r) {
|
|
482
|
-
for (var e = (r || "").match(/^(?:https?:)?(?:\/\/)?([^/?]+)/), t = (e && e[1] || "").replace("player.", ""), n = [".videoji.hk", ".vimeo.work", ".videoji.cn"], i = 0, a = n; i < a.length; i++) {
|
|
483
|
-
var u = a[i];
|
|
484
|
-
if (t.endsWith(u))
|
|
485
|
-
return t;
|
|
486
|
-
}
|
|
487
|
-
return "vimeo.com";
|
|
488
|
-
}
|
|
489
|
-
function Ce() {
|
|
490
|
-
var r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, e = r.id, t = r.url, n = e || t;
|
|
491
|
-
if (!n)
|
|
492
|
-
throw new Error("An id or url must be passed, either in an options object or as a data-vimeo-id or data-vimeo-url attribute.");
|
|
493
|
-
if (De(n))
|
|
494
|
-
return "https://vimeo.com/".concat(n);
|
|
495
|
-
if (z(n))
|
|
496
|
-
return n.replace("http:", "https:");
|
|
497
|
-
throw e ? new TypeError("“".concat(e, "” is not a valid video id.")) : new TypeError("“".concat(n, "” is not a vimeo.com url."));
|
|
498
|
-
}
|
|
499
|
-
var pe = function(e, t, n) {
|
|
500
|
-
var i = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : "addEventListener", a = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : "removeEventListener", u = typeof t == "string" ? [t] : t;
|
|
501
|
-
return u.forEach(function(s) {
|
|
502
|
-
e[i](s, n);
|
|
503
|
-
}), {
|
|
504
|
-
cancel: function() {
|
|
505
|
-
return u.forEach(function(h) {
|
|
506
|
-
return e[a](h, n);
|
|
507
|
-
});
|
|
508
|
-
}
|
|
509
|
-
};
|
|
510
|
-
}, We = typeof Array.prototype.indexOf < "u", ze = typeof window < "u" && typeof window.postMessage < "u";
|
|
511
|
-
if (!Me && (!We || !ze))
|
|
512
|
-
throw new Error("Sorry, the Vimeo Player API is not available in this browser.");
|
|
513
|
-
var G = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
514
|
-
function He(r, e) {
|
|
515
|
-
return e = { exports: {} }, r(e, e.exports), e.exports;
|
|
516
|
-
}
|
|
517
|
-
(function(r) {
|
|
518
|
-
if (r.WeakMap)
|
|
519
|
-
return;
|
|
520
|
-
var e = Object.prototype.hasOwnProperty, t = Object.defineProperty && (function() {
|
|
521
|
-
try {
|
|
522
|
-
return Object.defineProperty({}, "x", {
|
|
523
|
-
value: 1
|
|
524
|
-
}).x === 1;
|
|
525
|
-
} catch {
|
|
526
|
-
}
|
|
527
|
-
})(), n = function(a, u, s) {
|
|
528
|
-
t ? Object.defineProperty(a, u, {
|
|
529
|
-
configurable: !0,
|
|
530
|
-
writable: !0,
|
|
531
|
-
value: s
|
|
532
|
-
}) : a[u] = s;
|
|
533
|
-
};
|
|
534
|
-
r.WeakMap = (function() {
|
|
535
|
-
function a() {
|
|
536
|
-
if (this === void 0)
|
|
537
|
-
throw new TypeError("Constructor WeakMap requires 'new'");
|
|
538
|
-
if (n(this, "_id", s("_WeakMap")), arguments.length > 0)
|
|
539
|
-
throw new TypeError("WeakMap iterable is not supported");
|
|
540
|
-
}
|
|
541
|
-
n(a.prototype, "delete", function(o) {
|
|
542
|
-
if (u(this, "delete"), !i(o))
|
|
543
|
-
return !1;
|
|
544
|
-
var b = o[this._id];
|
|
545
|
-
return b && b[0] === o ? (delete o[this._id], !0) : !1;
|
|
546
|
-
}), n(a.prototype, "get", function(o) {
|
|
547
|
-
if (u(this, "get"), !!i(o)) {
|
|
548
|
-
var b = o[this._id];
|
|
549
|
-
if (b && b[0] === o)
|
|
550
|
-
return b[1];
|
|
551
|
-
}
|
|
552
|
-
}), n(a.prototype, "has", function(o) {
|
|
553
|
-
if (u(this, "has"), !i(o))
|
|
554
|
-
return !1;
|
|
555
|
-
var b = o[this._id];
|
|
556
|
-
return !!(b && b[0] === o);
|
|
557
|
-
}), n(a.prototype, "set", function(o, b) {
|
|
558
|
-
if (u(this, "set"), !i(o))
|
|
559
|
-
throw new TypeError("Invalid value used as weak map key");
|
|
560
|
-
var k = o[this._id];
|
|
561
|
-
return k && k[0] === o ? (k[1] = b, this) : (n(o, this._id, [o, b]), this);
|
|
562
|
-
});
|
|
563
|
-
function u(o, b) {
|
|
564
|
-
if (!i(o) || !e.call(o, "_id"))
|
|
565
|
-
throw new TypeError(b + " method called on incompatible receiver " + typeof o);
|
|
566
|
-
}
|
|
567
|
-
function s(o) {
|
|
568
|
-
return o + "_" + h() + "." + h();
|
|
569
|
-
}
|
|
570
|
-
function h() {
|
|
571
|
-
return Math.random().toString().substring(2);
|
|
572
|
-
}
|
|
573
|
-
return n(a, "_polyfill", !0), a;
|
|
574
|
-
})();
|
|
575
|
-
function i(a) {
|
|
576
|
-
return Object(a) === a;
|
|
577
|
-
}
|
|
578
|
-
})(typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : G);
|
|
579
|
-
var q = He(function(r) {
|
|
580
|
-
(function(t, n, i) {
|
|
581
|
-
n[t] = n[t] || i(), r.exports && (r.exports = n[t]);
|
|
582
|
-
})("Promise", G, function() {
|
|
583
|
-
var t, n, i, a = Object.prototype.toString, u = typeof setImmediate < "u" ? function(p) {
|
|
584
|
-
return setImmediate(p);
|
|
585
|
-
} : setTimeout;
|
|
586
|
-
try {
|
|
587
|
-
Object.defineProperty({}, "x", {}), t = function(p, f, v, E) {
|
|
588
|
-
return Object.defineProperty(p, f, {
|
|
589
|
-
value: v,
|
|
590
|
-
writable: !0,
|
|
591
|
-
configurable: E !== !1
|
|
592
|
-
});
|
|
593
|
-
};
|
|
594
|
-
} catch {
|
|
595
|
-
t = function(f, v, E) {
|
|
596
|
-
return f[v] = E, f;
|
|
597
|
-
};
|
|
598
|
-
}
|
|
599
|
-
i = /* @__PURE__ */ (function() {
|
|
600
|
-
var p, f, v;
|
|
601
|
-
function E(S, y) {
|
|
602
|
-
this.fn = S, this.self = y, this.next = void 0;
|
|
603
|
-
}
|
|
604
|
-
return {
|
|
605
|
-
add: function(y, j) {
|
|
606
|
-
v = new E(y, j), f ? f.next = v : p = v, f = v, v = void 0;
|
|
607
|
-
},
|
|
608
|
-
drain: function() {
|
|
609
|
-
var y = p;
|
|
610
|
-
for (p = f = n = void 0; y; )
|
|
611
|
-
y.fn.call(y.self), y = y.next;
|
|
612
|
-
}
|
|
613
|
-
};
|
|
614
|
-
})();
|
|
615
|
-
function s(m, p) {
|
|
616
|
-
i.add(m, p), n || (n = u(i.drain));
|
|
617
|
-
}
|
|
618
|
-
function h(m) {
|
|
619
|
-
var p, f = typeof m;
|
|
620
|
-
return m != null && (f == "object" || f == "function") && (p = m.then), typeof p == "function" ? p : !1;
|
|
621
|
-
}
|
|
622
|
-
function o() {
|
|
623
|
-
for (var m = 0; m < this.chain.length; m++)
|
|
624
|
-
b(this, this.state === 1 ? this.chain[m].success : this.chain[m].failure, this.chain[m]);
|
|
625
|
-
this.chain.length = 0;
|
|
626
|
-
}
|
|
627
|
-
function b(m, p, f) {
|
|
628
|
-
var v, E;
|
|
629
|
-
try {
|
|
630
|
-
p === !1 ? f.reject(m.msg) : (p === !0 ? v = m.msg : v = p.call(void 0, m.msg), v === f.promise ? f.reject(TypeError("Promise-chain cycle")) : (E = h(v)) ? E.call(v, f.resolve, f.reject) : f.resolve(v));
|
|
631
|
-
} catch (S) {
|
|
632
|
-
f.reject(S);
|
|
633
|
-
}
|
|
634
|
-
}
|
|
635
|
-
function k(m) {
|
|
636
|
-
var p, f = this;
|
|
637
|
-
if (!f.triggered) {
|
|
638
|
-
f.triggered = !0, f.def && (f = f.def);
|
|
639
|
-
try {
|
|
640
|
-
(p = h(m)) ? s(function() {
|
|
641
|
-
var v = new g(f);
|
|
642
|
-
try {
|
|
643
|
-
p.call(m, function() {
|
|
644
|
-
k.apply(v, arguments);
|
|
645
|
-
}, function() {
|
|
646
|
-
T.apply(v, arguments);
|
|
647
|
-
});
|
|
648
|
-
} catch (E) {
|
|
649
|
-
T.call(v, E);
|
|
650
|
-
}
|
|
651
|
-
}) : (f.msg = m, f.state = 1, f.chain.length > 0 && s(o, f));
|
|
652
|
-
} catch (v) {
|
|
653
|
-
T.call(new g(f), v);
|
|
654
|
-
}
|
|
655
|
-
}
|
|
656
|
-
}
|
|
657
|
-
function T(m) {
|
|
658
|
-
var p = this;
|
|
659
|
-
p.triggered || (p.triggered = !0, p.def && (p = p.def), p.msg = m, p.state = 2, p.chain.length > 0 && s(o, p));
|
|
660
|
-
}
|
|
661
|
-
function P(m, p, f, v) {
|
|
662
|
-
for (var E = 0; E < p.length; E++)
|
|
663
|
-
(function(y) {
|
|
664
|
-
m.resolve(p[y]).then(function($) {
|
|
665
|
-
f(y, $);
|
|
666
|
-
}, v);
|
|
667
|
-
})(E);
|
|
668
|
-
}
|
|
669
|
-
function g(m) {
|
|
670
|
-
this.def = m, this.triggered = !1;
|
|
671
|
-
}
|
|
672
|
-
function _(m) {
|
|
673
|
-
this.promise = m, this.state = 0, this.triggered = !1, this.chain = [], this.msg = void 0;
|
|
674
|
-
}
|
|
675
|
-
function O(m) {
|
|
676
|
-
if (typeof m != "function")
|
|
677
|
-
throw TypeError("Not a function");
|
|
678
|
-
if (this.__NPO__ !== 0)
|
|
679
|
-
throw TypeError("Not a promise");
|
|
680
|
-
this.__NPO__ = 1;
|
|
681
|
-
var p = new _(this);
|
|
682
|
-
this.then = function(v, E) {
|
|
683
|
-
var S = {
|
|
684
|
-
success: typeof v == "function" ? v : !0,
|
|
685
|
-
failure: typeof E == "function" ? E : !1
|
|
686
|
-
};
|
|
687
|
-
return S.promise = new this.constructor(function(j, $) {
|
|
688
|
-
if (typeof j != "function" || typeof $ != "function")
|
|
689
|
-
throw TypeError("Not a function");
|
|
690
|
-
S.resolve = j, S.reject = $;
|
|
691
|
-
}), p.chain.push(S), p.state !== 0 && s(o, p), S.promise;
|
|
692
|
-
}, this.catch = function(v) {
|
|
693
|
-
return this.then(void 0, v);
|
|
694
|
-
};
|
|
695
|
-
try {
|
|
696
|
-
m.call(void 0, function(v) {
|
|
697
|
-
k.call(p, v);
|
|
698
|
-
}, function(v) {
|
|
699
|
-
T.call(p, v);
|
|
700
|
-
});
|
|
701
|
-
} catch (f) {
|
|
702
|
-
T.call(p, f);
|
|
703
|
-
}
|
|
704
|
-
}
|
|
705
|
-
var N = t(
|
|
706
|
-
{},
|
|
707
|
-
"constructor",
|
|
708
|
-
O,
|
|
709
|
-
/*configurable=*/
|
|
710
|
-
!1
|
|
711
|
-
);
|
|
712
|
-
return O.prototype = N, t(
|
|
713
|
-
N,
|
|
714
|
-
"__NPO__",
|
|
715
|
-
0,
|
|
716
|
-
/*configurable=*/
|
|
717
|
-
!1
|
|
718
|
-
), t(O, "resolve", function(p) {
|
|
719
|
-
var f = this;
|
|
720
|
-
return p && typeof p == "object" && p.__NPO__ === 1 ? p : new f(function(E, S) {
|
|
721
|
-
if (typeof E != "function" || typeof S != "function")
|
|
722
|
-
throw TypeError("Not a function");
|
|
723
|
-
E(p);
|
|
724
|
-
});
|
|
725
|
-
}), t(O, "reject", function(p) {
|
|
726
|
-
return new this(function(v, E) {
|
|
727
|
-
if (typeof v != "function" || typeof E != "function")
|
|
728
|
-
throw TypeError("Not a function");
|
|
729
|
-
E(p);
|
|
730
|
-
});
|
|
731
|
-
}), t(O, "all", function(p) {
|
|
732
|
-
var f = this;
|
|
733
|
-
return a.call(p) != "[object Array]" ? f.reject(TypeError("Not an array")) : p.length === 0 ? f.resolve([]) : new f(function(E, S) {
|
|
734
|
-
if (typeof E != "function" || typeof S != "function")
|
|
735
|
-
throw TypeError("Not a function");
|
|
736
|
-
var y = p.length, j = Array(y), $ = 0;
|
|
737
|
-
P(f, p, function(c, l) {
|
|
738
|
-
j[c] = l, ++$ === y && E(j);
|
|
739
|
-
}, S);
|
|
740
|
-
});
|
|
741
|
-
}), t(O, "race", function(p) {
|
|
742
|
-
var f = this;
|
|
743
|
-
return a.call(p) != "[object Array]" ? f.reject(TypeError("Not an array")) : new f(function(E, S) {
|
|
744
|
-
if (typeof E != "function" || typeof S != "function")
|
|
745
|
-
throw TypeError("Not a function");
|
|
746
|
-
P(f, p, function(j, $) {
|
|
747
|
-
E($);
|
|
748
|
-
}, S);
|
|
749
|
-
});
|
|
750
|
-
}), O;
|
|
751
|
-
});
|
|
752
|
-
}), V = /* @__PURE__ */ new WeakMap();
|
|
753
|
-
function Q(r, e, t) {
|
|
754
|
-
var n = V.get(r.element) || {};
|
|
755
|
-
e in n || (n[e] = []), n[e].push(t), V.set(r.element, n);
|
|
756
|
-
}
|
|
757
|
-
function ee(r, e) {
|
|
758
|
-
var t = V.get(r.element) || {};
|
|
759
|
-
return t[e] || [];
|
|
760
|
-
}
|
|
761
|
-
function te(r, e, t) {
|
|
762
|
-
var n = V.get(r.element) || {};
|
|
763
|
-
if (!n[e])
|
|
764
|
-
return !0;
|
|
765
|
-
if (!t)
|
|
766
|
-
return n[e] = [], V.set(r.element, n), !0;
|
|
767
|
-
var i = n[e].indexOf(t);
|
|
768
|
-
return i !== -1 && n[e].splice(i, 1), V.set(r.element, n), n[e] && n[e].length === 0;
|
|
769
|
-
}
|
|
770
|
-
function Be(r, e) {
|
|
771
|
-
var t = ee(r, e);
|
|
772
|
-
if (t.length < 1)
|
|
773
|
-
return !1;
|
|
774
|
-
var n = t.shift();
|
|
775
|
-
return te(r, e, n), n;
|
|
776
|
-
}
|
|
777
|
-
function Ge(r, e) {
|
|
778
|
-
var t = V.get(r);
|
|
779
|
-
V.set(e, t), V.delete(r);
|
|
780
|
-
}
|
|
781
|
-
function re(r) {
|
|
782
|
-
if (typeof r == "string")
|
|
783
|
-
try {
|
|
784
|
-
r = JSON.parse(r);
|
|
785
|
-
} catch (e) {
|
|
786
|
-
return console.warn(e), {};
|
|
787
|
-
}
|
|
788
|
-
return r;
|
|
789
|
-
}
|
|
790
|
-
function x(r, e, t) {
|
|
791
|
-
if (!(!r.element.contentWindow || !r.element.contentWindow.postMessage)) {
|
|
792
|
-
var n = {
|
|
793
|
-
method: e
|
|
794
|
-
};
|
|
795
|
-
t !== void 0 && (n.value = t);
|
|
796
|
-
var i = parseFloat(navigator.userAgent.toLowerCase().replace(/^.*msie (\d+).*$/, "$1"));
|
|
797
|
-
i >= 8 && i < 10 && (n = JSON.stringify(n)), r.element.contentWindow.postMessage(n, r.origin);
|
|
798
|
-
}
|
|
799
|
-
}
|
|
800
|
-
function Ue(r, e) {
|
|
801
|
-
e = re(e);
|
|
802
|
-
var t = [], n;
|
|
803
|
-
if (e.event) {
|
|
804
|
-
if (e.event === "error") {
|
|
805
|
-
var i = ee(r, e.data.method);
|
|
806
|
-
i.forEach(function(u) {
|
|
807
|
-
var s = new Error(e.data.message);
|
|
808
|
-
s.name = e.data.name, u.reject(s), te(r, e.data.method, u);
|
|
809
|
-
});
|
|
810
|
-
}
|
|
811
|
-
t = ee(r, "event:".concat(e.event)), n = e.data;
|
|
812
|
-
} else if (e.method) {
|
|
813
|
-
var a = Be(r, e.method);
|
|
814
|
-
a && (t.push(a), n = e.value);
|
|
815
|
-
}
|
|
816
|
-
t.forEach(function(u) {
|
|
817
|
-
try {
|
|
818
|
-
if (typeof u == "function") {
|
|
819
|
-
u.call(r, n);
|
|
820
|
-
return;
|
|
821
|
-
}
|
|
822
|
-
u.resolve(n);
|
|
823
|
-
} catch {
|
|
824
|
-
}
|
|
825
|
-
});
|
|
826
|
-
}
|
|
827
|
-
var Qe = ["airplay", "audio_tracks", "audiotrack", "autopause", "autoplay", "background", "byline", "cc", "chapter_id", "chapters", "chromecast", "color", "colors", "controls", "dnt", "end_time", "fullscreen", "height", "id", "initial_quality", "interactive_params", "keyboard", "loop", "maxheight", "max_quality", "maxwidth", "min_quality", "muted", "play_button_position", "playsinline", "portrait", "preload", "progress_bar", "quality", "quality_selector", "responsive", "skipping_forward", "speed", "start_time", "texttrack", "thumbnail_id", "title", "transcript", "transparent", "unmute_button", "url", "vimeo_logo", "volume", "watch_full_video", "width"];
|
|
828
|
-
function Oe(r) {
|
|
829
|
-
var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
830
|
-
return Qe.reduce(function(t, n) {
|
|
831
|
-
var i = r.getAttribute("data-vimeo-".concat(n));
|
|
832
|
-
return (i || i === "") && (t[n] = i === "" ? 1 : i), t;
|
|
833
|
-
}, e);
|
|
834
|
-
}
|
|
835
|
-
function se(r, e) {
|
|
836
|
-
var t = r.html;
|
|
837
|
-
if (!e)
|
|
838
|
-
throw new TypeError("An element must be provided");
|
|
839
|
-
if (e.getAttribute("data-vimeo-initialized") !== null)
|
|
840
|
-
return e.querySelector("iframe");
|
|
841
|
-
var n = document.createElement("div");
|
|
842
|
-
return n.innerHTML = t, e.appendChild(n.firstChild), e.setAttribute("data-vimeo-initialized", "true"), e.querySelector("iframe");
|
|
843
|
-
}
|
|
844
|
-
function _e(r) {
|
|
845
|
-
var e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = arguments.length > 2 ? arguments[2] : void 0;
|
|
846
|
-
return new Promise(function(n, i) {
|
|
847
|
-
if (!z(r))
|
|
848
|
-
throw new TypeError("“".concat(r, "” is not a vimeo.com url."));
|
|
849
|
-
var a = xe(r), u = "https://".concat(a, "/api/oembed.json?url=").concat(encodeURIComponent(r));
|
|
850
|
-
for (var s in e)
|
|
851
|
-
e.hasOwnProperty(s) && (u += "&".concat(s, "=").concat(encodeURIComponent(e[s])));
|
|
852
|
-
var h = "XDomainRequest" in window ? new XDomainRequest() : new XMLHttpRequest();
|
|
853
|
-
h.open("GET", u, !0), h.onload = function() {
|
|
854
|
-
if (h.status === 404) {
|
|
855
|
-
i(new Error("“".concat(r, "” was not found.")));
|
|
856
|
-
return;
|
|
857
|
-
}
|
|
858
|
-
if (h.status === 403) {
|
|
859
|
-
i(new Error("“".concat(r, "” is not embeddable.")));
|
|
860
|
-
return;
|
|
861
|
-
}
|
|
862
|
-
try {
|
|
863
|
-
var o = JSON.parse(h.responseText);
|
|
864
|
-
if (o.domain_status_code === 403) {
|
|
865
|
-
se(o, t), i(new Error("“".concat(r, "” is not embeddable.")));
|
|
866
|
-
return;
|
|
867
|
-
}
|
|
868
|
-
n(o);
|
|
869
|
-
} catch (b) {
|
|
870
|
-
i(b);
|
|
871
|
-
}
|
|
872
|
-
}, h.onerror = function() {
|
|
873
|
-
var o = h.status ? " (".concat(h.status, ")") : "";
|
|
874
|
-
i(new Error("There was an error fetching the embed code from Vimeo".concat(o, ".")));
|
|
875
|
-
}, h.send();
|
|
876
|
-
});
|
|
877
|
-
}
|
|
878
|
-
function Ye() {
|
|
879
|
-
var r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : document, e = [].slice.call(r.querySelectorAll("[data-vimeo-id], [data-vimeo-url]")), t = function(i) {
|
|
880
|
-
"console" in window && console.error && console.error("There was an error creating an embed: ".concat(i));
|
|
881
|
-
};
|
|
882
|
-
e.forEach(function(n) {
|
|
883
|
-
try {
|
|
884
|
-
if (n.getAttribute("data-vimeo-defer") !== null)
|
|
885
|
-
return;
|
|
886
|
-
var i = Oe(n), a = Ce(i);
|
|
887
|
-
_e(a, i, n).then(function(u) {
|
|
888
|
-
return se(u, n);
|
|
889
|
-
}).catch(t);
|
|
890
|
-
} catch (u) {
|
|
891
|
-
t(u);
|
|
892
|
-
}
|
|
893
|
-
});
|
|
894
|
-
}
|
|
895
|
-
function Je() {
|
|
896
|
-
var r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : document;
|
|
897
|
-
if (!window.VimeoPlayerResizeEmbeds_) {
|
|
898
|
-
window.VimeoPlayerResizeEmbeds_ = !0;
|
|
899
|
-
var e = function(n) {
|
|
900
|
-
if (z(n.origin) && !(!n.data || n.data.event !== "spacechange")) {
|
|
901
|
-
for (var i = r.querySelectorAll("iframe"), a = 0; a < i.length; a++)
|
|
902
|
-
if (i[a].contentWindow === n.source) {
|
|
903
|
-
var u = i[a].parentElement;
|
|
904
|
-
u.style.paddingBottom = "".concat(n.data.data[0].bottom, "px");
|
|
905
|
-
break;
|
|
906
|
-
}
|
|
907
|
-
}
|
|
908
|
-
};
|
|
909
|
-
window.addEventListener("message", e);
|
|
910
|
-
}
|
|
911
|
-
}
|
|
912
|
-
function Xe() {
|
|
913
|
-
var r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : document;
|
|
914
|
-
if (!window.VimeoSeoMetadataAppended) {
|
|
915
|
-
window.VimeoSeoMetadataAppended = !0;
|
|
916
|
-
var e = function(n) {
|
|
917
|
-
if (z(n.origin)) {
|
|
918
|
-
var i = re(n.data);
|
|
919
|
-
if (!(!i || i.event !== "ready"))
|
|
920
|
-
for (var a = r.querySelectorAll("iframe"), u = 0; u < a.length; u++) {
|
|
921
|
-
var s = a[u], h = s.contentWindow === n.source;
|
|
922
|
-
if (Se(s.src) && h) {
|
|
923
|
-
var o = new le(s);
|
|
924
|
-
o.callMethod("appendVideoMetadata", window.location.href);
|
|
925
|
-
}
|
|
926
|
-
}
|
|
927
|
-
}
|
|
928
|
-
};
|
|
929
|
-
window.addEventListener("message", e);
|
|
930
|
-
}
|
|
931
|
-
}
|
|
932
|
-
function Ke() {
|
|
933
|
-
var r = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : document;
|
|
934
|
-
if (!window.VimeoCheckedUrlTimeParam) {
|
|
935
|
-
window.VimeoCheckedUrlTimeParam = !0;
|
|
936
|
-
var e = function(i) {
|
|
937
|
-
"console" in window && console.error && console.error("There was an error getting video Id: ".concat(i));
|
|
938
|
-
}, t = function(i) {
|
|
939
|
-
if (z(i.origin)) {
|
|
940
|
-
var a = re(i.data);
|
|
941
|
-
if (!(!a || a.event !== "ready"))
|
|
942
|
-
for (var u = r.querySelectorAll("iframe"), s = function() {
|
|
943
|
-
var b = u[h], k = b.contentWindow === i.source;
|
|
944
|
-
if (Se(b.src) && k) {
|
|
945
|
-
var T = new le(b);
|
|
946
|
-
T.getVideoId().then(function(P) {
|
|
947
|
-
var g = new RegExp("[?&]vimeo_t_".concat(P, "=([^&#]*)")).exec(window.location.href);
|
|
948
|
-
if (g && g[1]) {
|
|
949
|
-
var _ = decodeURI(g[1]);
|
|
950
|
-
T.setCurrentTime(_);
|
|
951
|
-
}
|
|
952
|
-
}).catch(e);
|
|
953
|
-
}
|
|
954
|
-
}, h = 0; h < u.length; h++)
|
|
955
|
-
s();
|
|
956
|
-
}
|
|
957
|
-
};
|
|
958
|
-
window.addEventListener("message", t);
|
|
959
|
-
}
|
|
960
|
-
}
|
|
961
|
-
function Ze() {
|
|
962
|
-
var r = (function() {
|
|
963
|
-
for (var n, i = [
|
|
964
|
-
["requestFullscreen", "exitFullscreen", "fullscreenElement", "fullscreenEnabled", "fullscreenchange", "fullscreenerror"],
|
|
965
|
-
// New WebKit
|
|
966
|
-
["webkitRequestFullscreen", "webkitExitFullscreen", "webkitFullscreenElement", "webkitFullscreenEnabled", "webkitfullscreenchange", "webkitfullscreenerror"],
|
|
967
|
-
// Old WebKit
|
|
968
|
-
["webkitRequestFullScreen", "webkitCancelFullScreen", "webkitCurrentFullScreenElement", "webkitCancelFullScreen", "webkitfullscreenchange", "webkitfullscreenerror"],
|
|
969
|
-
["mozRequestFullScreen", "mozCancelFullScreen", "mozFullScreenElement", "mozFullScreenEnabled", "mozfullscreenchange", "mozfullscreenerror"],
|
|
970
|
-
["msRequestFullscreen", "msExitFullscreen", "msFullscreenElement", "msFullscreenEnabled", "MSFullscreenChange", "MSFullscreenError"]
|
|
971
|
-
], a = 0, u = i.length, s = {}; a < u; a++)
|
|
972
|
-
if (n = i[a], n && n[1] in document) {
|
|
973
|
-
for (a = 0; a < n.length; a++)
|
|
974
|
-
s[i[0][a]] = n[a];
|
|
975
|
-
return s;
|
|
976
|
-
}
|
|
977
|
-
return !1;
|
|
978
|
-
})(), e = {
|
|
979
|
-
fullscreenchange: r.fullscreenchange,
|
|
980
|
-
fullscreenerror: r.fullscreenerror
|
|
981
|
-
}, t = {
|
|
982
|
-
request: function(i) {
|
|
983
|
-
return new Promise(function(a, u) {
|
|
984
|
-
var s = function o() {
|
|
985
|
-
t.off("fullscreenchange", o), a();
|
|
986
|
-
};
|
|
987
|
-
t.on("fullscreenchange", s), i = i || document.documentElement;
|
|
988
|
-
var h = i[r.requestFullscreen]();
|
|
989
|
-
h instanceof Promise && h.then(s).catch(u);
|
|
990
|
-
});
|
|
991
|
-
},
|
|
992
|
-
exit: function() {
|
|
993
|
-
return new Promise(function(i, a) {
|
|
994
|
-
if (!t.isFullscreen) {
|
|
995
|
-
i();
|
|
996
|
-
return;
|
|
997
|
-
}
|
|
998
|
-
var u = function h() {
|
|
999
|
-
t.off("fullscreenchange", h), i();
|
|
1000
|
-
};
|
|
1001
|
-
t.on("fullscreenchange", u);
|
|
1002
|
-
var s = document[r.exitFullscreen]();
|
|
1003
|
-
s instanceof Promise && s.then(u).catch(a);
|
|
1004
|
-
});
|
|
1005
|
-
},
|
|
1006
|
-
on: function(i, a) {
|
|
1007
|
-
var u = e[i];
|
|
1008
|
-
u && document.addEventListener(u, a);
|
|
1009
|
-
},
|
|
1010
|
-
off: function(i, a) {
|
|
1011
|
-
var u = e[i];
|
|
1012
|
-
u && document.removeEventListener(u, a);
|
|
1013
|
-
}
|
|
1014
|
-
};
|
|
1015
|
-
return Object.defineProperties(t, {
|
|
1016
|
-
isFullscreen: {
|
|
1017
|
-
get: function() {
|
|
1018
|
-
return !!document[r.fullscreenElement];
|
|
1019
|
-
}
|
|
1020
|
-
},
|
|
1021
|
-
element: {
|
|
1022
|
-
enumerable: !0,
|
|
1023
|
-
get: function() {
|
|
1024
|
-
return document[r.fullscreenElement];
|
|
1025
|
-
}
|
|
1026
|
-
},
|
|
1027
|
-
isEnabled: {
|
|
1028
|
-
enumerable: !0,
|
|
1029
|
-
get: function() {
|
|
1030
|
-
return !!document[r.fullscreenEnabled];
|
|
1031
|
-
}
|
|
1032
|
-
}
|
|
1033
|
-
}), t;
|
|
1034
|
-
}
|
|
1035
|
-
var et = {
|
|
1036
|
-
role: "viewer",
|
|
1037
|
-
autoPlayMuted: !0,
|
|
1038
|
-
allowedDrift: 0.3,
|
|
1039
|
-
maxAllowedDrift: 1,
|
|
1040
|
-
minCheckInterval: 0.1,
|
|
1041
|
-
maxRateAdjustment: 0.2,
|
|
1042
|
-
maxTimeToCatchUp: 1
|
|
1043
|
-
}, tt = /* @__PURE__ */ (function(r) {
|
|
1044
|
-
je(t, r);
|
|
1045
|
-
var e = $e(t);
|
|
1046
|
-
function t(n, i) {
|
|
1047
|
-
var a, u = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, s = arguments.length > 3 ? arguments[3] : void 0;
|
|
1048
|
-
return Ee(this, t), a = e.call(this), X(Z(a), "logger", void 0), X(Z(a), "speedAdjustment", 0), X(Z(a), "adjustSpeed", /* @__PURE__ */ (function() {
|
|
1049
|
-
var h = W(/* @__PURE__ */ R().mark(function o(b, k) {
|
|
1050
|
-
var T;
|
|
1051
|
-
return R().wrap(function(g) {
|
|
1052
|
-
for (; ; ) switch (g.prev = g.next) {
|
|
1053
|
-
case 0:
|
|
1054
|
-
if (a.speedAdjustment !== k) {
|
|
1055
|
-
g.next = 2;
|
|
1056
|
-
break;
|
|
1057
|
-
}
|
|
1058
|
-
return g.abrupt("return");
|
|
1059
|
-
case 2:
|
|
1060
|
-
return g.next = 4, b.getPlaybackRate();
|
|
1061
|
-
case 4:
|
|
1062
|
-
return g.t0 = g.sent, g.t1 = a.speedAdjustment, g.t2 = g.t0 - g.t1, g.t3 = k, T = g.t2 + g.t3, a.log("New playbackRate: ".concat(T)), g.next = 12, b.setPlaybackRate(T);
|
|
1063
|
-
case 12:
|
|
1064
|
-
a.speedAdjustment = k;
|
|
1065
|
-
case 13:
|
|
1066
|
-
case "end":
|
|
1067
|
-
return g.stop();
|
|
1068
|
-
}
|
|
1069
|
-
}, o);
|
|
1070
|
-
}));
|
|
1071
|
-
return function(o, b) {
|
|
1072
|
-
return h.apply(this, arguments);
|
|
1073
|
-
};
|
|
1074
|
-
})()), a.logger = s, a.init(i, n, fe(fe({}, et), u)), a;
|
|
1075
|
-
}
|
|
1076
|
-
return ke(t, [{
|
|
1077
|
-
key: "disconnect",
|
|
1078
|
-
value: function() {
|
|
1079
|
-
this.dispatchEvent(new Event("disconnect"));
|
|
1080
|
-
}
|
|
1081
|
-
/**
|
|
1082
|
-
* @param {TimingObject} timingObject
|
|
1083
|
-
* @param {PlayerControls} player
|
|
1084
|
-
* @param {TimingSrcConnectorOptions} options
|
|
1085
|
-
* @return {Promise<void>}
|
|
1086
|
-
*/
|
|
1087
|
-
}, {
|
|
1088
|
-
key: "init",
|
|
1089
|
-
value: (function() {
|
|
1090
|
-
var n = W(/* @__PURE__ */ R().mark(function a(u, s, h) {
|
|
1091
|
-
var o = this, b, k, T;
|
|
1092
|
-
return R().wrap(function(g) {
|
|
1093
|
-
for (; ; ) switch (g.prev = g.next) {
|
|
1094
|
-
case 0:
|
|
1095
|
-
return g.next = 2, this.waitForTOReadyState(u, "open");
|
|
1096
|
-
case 2:
|
|
1097
|
-
if (h.role !== "viewer") {
|
|
1098
|
-
g.next = 10;
|
|
1099
|
-
break;
|
|
1100
|
-
}
|
|
1101
|
-
return g.next = 5, this.updatePlayer(u, s, h);
|
|
1102
|
-
case 5:
|
|
1103
|
-
b = pe(u, "change", function() {
|
|
1104
|
-
return o.updatePlayer(u, s, h);
|
|
1105
|
-
}), k = this.maintainPlaybackPosition(u, s, h), this.addEventListener("disconnect", function() {
|
|
1106
|
-
k.cancel(), b.cancel();
|
|
1107
|
-
}), g.next = 14;
|
|
1108
|
-
break;
|
|
1109
|
-
case 10:
|
|
1110
|
-
return g.next = 12, this.updateTimingObject(u, s);
|
|
1111
|
-
case 12:
|
|
1112
|
-
T = pe(s, ["seeked", "play", "pause", "ratechange"], function() {
|
|
1113
|
-
return o.updateTimingObject(u, s);
|
|
1114
|
-
}, "on", "off"), this.addEventListener("disconnect", function() {
|
|
1115
|
-
return T.cancel();
|
|
1116
|
-
});
|
|
1117
|
-
case 14:
|
|
1118
|
-
case "end":
|
|
1119
|
-
return g.stop();
|
|
1120
|
-
}
|
|
1121
|
-
}, a, this);
|
|
1122
|
-
}));
|
|
1123
|
-
function i(a, u, s) {
|
|
1124
|
-
return n.apply(this, arguments);
|
|
1125
|
-
}
|
|
1126
|
-
return i;
|
|
1127
|
-
})()
|
|
1128
|
-
/**
|
|
1129
|
-
* Sets the TimingObject's state to reflect that of the player
|
|
1130
|
-
*
|
|
1131
|
-
* @param {TimingObject} timingObject
|
|
1132
|
-
* @param {PlayerControls} player
|
|
1133
|
-
* @return {Promise<void>}
|
|
1134
|
-
*/
|
|
1135
|
-
}, {
|
|
1136
|
-
key: "updateTimingObject",
|
|
1137
|
-
value: (function() {
|
|
1138
|
-
var n = W(/* @__PURE__ */ R().mark(function a(u, s) {
|
|
1139
|
-
return R().wrap(function(o) {
|
|
1140
|
-
for (; ; ) switch (o.prev = o.next) {
|
|
1141
|
-
case 0:
|
|
1142
|
-
return o.t0 = u, o.next = 3, s.getCurrentTime();
|
|
1143
|
-
case 3:
|
|
1144
|
-
return o.t1 = o.sent, o.next = 6, s.getPaused();
|
|
1145
|
-
case 6:
|
|
1146
|
-
if (!o.sent) {
|
|
1147
|
-
o.next = 10;
|
|
1148
|
-
break;
|
|
1149
|
-
}
|
|
1150
|
-
o.t2 = 0, o.next = 13;
|
|
1151
|
-
break;
|
|
1152
|
-
case 10:
|
|
1153
|
-
return o.next = 12, s.getPlaybackRate();
|
|
1154
|
-
case 12:
|
|
1155
|
-
o.t2 = o.sent;
|
|
1156
|
-
case 13:
|
|
1157
|
-
o.t3 = o.t2, o.t4 = {
|
|
1158
|
-
position: o.t1,
|
|
1159
|
-
velocity: o.t3
|
|
1160
|
-
}, o.t0.update.call(o.t0, o.t4);
|
|
1161
|
-
case 16:
|
|
1162
|
-
case "end":
|
|
1163
|
-
return o.stop();
|
|
1164
|
-
}
|
|
1165
|
-
}, a);
|
|
1166
|
-
}));
|
|
1167
|
-
function i(a, u) {
|
|
1168
|
-
return n.apply(this, arguments);
|
|
1169
|
-
}
|
|
1170
|
-
return i;
|
|
1171
|
-
})()
|
|
1172
|
-
/**
|
|
1173
|
-
* Sets the player's timing state to reflect that of the TimingObject
|
|
1174
|
-
*
|
|
1175
|
-
* @param {TimingObject} timingObject
|
|
1176
|
-
* @param {PlayerControls} player
|
|
1177
|
-
* @param {TimingSrcConnectorOptions} options
|
|
1178
|
-
* @return {Promise<void>}
|
|
1179
|
-
*/
|
|
1180
|
-
}, {
|
|
1181
|
-
key: "updatePlayer",
|
|
1182
|
-
value: (function() {
|
|
1183
|
-
var n = W(/* @__PURE__ */ R().mark(function a(u, s, h) {
|
|
1184
|
-
var o, b, k;
|
|
1185
|
-
return R().wrap(function(P) {
|
|
1186
|
-
for (; ; ) switch (P.prev = P.next) {
|
|
1187
|
-
case 0:
|
|
1188
|
-
if (o = u.query(), b = o.position, k = o.velocity, typeof b == "number" && s.setCurrentTime(b), typeof k != "number") {
|
|
1189
|
-
P.next = 25;
|
|
1190
|
-
break;
|
|
1191
|
-
}
|
|
1192
|
-
if (k !== 0) {
|
|
1193
|
-
P.next = 11;
|
|
1194
|
-
break;
|
|
1195
|
-
}
|
|
1196
|
-
return P.next = 6, s.getPaused();
|
|
1197
|
-
case 6:
|
|
1198
|
-
if (P.t0 = P.sent, P.t0 !== !1) {
|
|
1199
|
-
P.next = 9;
|
|
1200
|
-
break;
|
|
1201
|
-
}
|
|
1202
|
-
s.pause();
|
|
1203
|
-
case 9:
|
|
1204
|
-
P.next = 25;
|
|
1205
|
-
break;
|
|
1206
|
-
case 11:
|
|
1207
|
-
if (!(k > 0)) {
|
|
1208
|
-
P.next = 25;
|
|
1209
|
-
break;
|
|
1210
|
-
}
|
|
1211
|
-
return P.next = 14, s.getPaused();
|
|
1212
|
-
case 14:
|
|
1213
|
-
if (P.t1 = P.sent, P.t1 !== !0) {
|
|
1214
|
-
P.next = 19;
|
|
1215
|
-
break;
|
|
1216
|
-
}
|
|
1217
|
-
return P.next = 18, s.play().catch(/* @__PURE__ */ (function() {
|
|
1218
|
-
var g = W(/* @__PURE__ */ R().mark(function _(O) {
|
|
1219
|
-
return R().wrap(function(m) {
|
|
1220
|
-
for (; ; ) switch (m.prev = m.next) {
|
|
1221
|
-
case 0:
|
|
1222
|
-
if (!(O.name === "NotAllowedError" && h.autoPlayMuted)) {
|
|
1223
|
-
m.next = 5;
|
|
1224
|
-
break;
|
|
1225
|
-
}
|
|
1226
|
-
return m.next = 3, s.setMuted(!0);
|
|
1227
|
-
case 3:
|
|
1228
|
-
return m.next = 5, s.play().catch(function(p) {
|
|
1229
|
-
return console.error("Couldn't play the video from TimingSrcConnector. Error:", p);
|
|
1230
|
-
});
|
|
1231
|
-
case 5:
|
|
1232
|
-
case "end":
|
|
1233
|
-
return m.stop();
|
|
1234
|
-
}
|
|
1235
|
-
}, _);
|
|
1236
|
-
}));
|
|
1237
|
-
return function(_) {
|
|
1238
|
-
return g.apply(this, arguments);
|
|
1239
|
-
};
|
|
1240
|
-
})());
|
|
1241
|
-
case 18:
|
|
1242
|
-
this.updatePlayer(u, s, h);
|
|
1243
|
-
case 19:
|
|
1244
|
-
return P.next = 21, s.getPlaybackRate();
|
|
1245
|
-
case 21:
|
|
1246
|
-
if (P.t2 = P.sent, P.t3 = k, P.t2 === P.t3) {
|
|
1247
|
-
P.next = 25;
|
|
1248
|
-
break;
|
|
1249
|
-
}
|
|
1250
|
-
s.setPlaybackRate(k);
|
|
1251
|
-
case 25:
|
|
1252
|
-
case "end":
|
|
1253
|
-
return P.stop();
|
|
1254
|
-
}
|
|
1255
|
-
}, a, this);
|
|
1256
|
-
}));
|
|
1257
|
-
function i(a, u, s) {
|
|
1258
|
-
return n.apply(this, arguments);
|
|
1259
|
-
}
|
|
1260
|
-
return i;
|
|
1261
|
-
})()
|
|
1262
|
-
/**
|
|
1263
|
-
* Since video players do not play with 100% time precision, we need to closely monitor
|
|
1264
|
-
* our player to be sure it remains in sync with the TimingObject.
|
|
1265
|
-
*
|
|
1266
|
-
* If out of sync, we use the current conditions and the options provided to determine
|
|
1267
|
-
* whether to re-sync via setting currentTime or adjusting the playbackRate
|
|
1268
|
-
*
|
|
1269
|
-
* @param {TimingObject} timingObject
|
|
1270
|
-
* @param {PlayerControls} player
|
|
1271
|
-
* @param {TimingSrcConnectorOptions} options
|
|
1272
|
-
* @return {{cancel: (function(): void)}}
|
|
1273
|
-
*/
|
|
1274
|
-
}, {
|
|
1275
|
-
key: "maintainPlaybackPosition",
|
|
1276
|
-
value: function(i, a, u) {
|
|
1277
|
-
var s = this, h = u.allowedDrift, o = u.maxAllowedDrift, b = u.minCheckInterval, k = u.maxRateAdjustment, T = u.maxTimeToCatchUp, P = Math.min(T, Math.max(b, o)) * 1e3, g = /* @__PURE__ */ (function() {
|
|
1278
|
-
var O = W(/* @__PURE__ */ R().mark(function N() {
|
|
1279
|
-
var m, p, f, v, E;
|
|
1280
|
-
return R().wrap(function(y) {
|
|
1281
|
-
for (; ; ) switch (y.prev = y.next) {
|
|
1282
|
-
case 0:
|
|
1283
|
-
if (y.t0 = i.query().velocity === 0, y.t0) {
|
|
1284
|
-
y.next = 6;
|
|
1285
|
-
break;
|
|
1286
|
-
}
|
|
1287
|
-
return y.next = 4, a.getPaused();
|
|
1288
|
-
case 4:
|
|
1289
|
-
y.t1 = y.sent, y.t0 = y.t1 === !0;
|
|
1290
|
-
case 6:
|
|
1291
|
-
if (!y.t0) {
|
|
1292
|
-
y.next = 8;
|
|
1293
|
-
break;
|
|
1294
|
-
}
|
|
1295
|
-
return y.abrupt("return");
|
|
1296
|
-
case 8:
|
|
1297
|
-
return y.t2 = i.query().position, y.next = 11, a.getCurrentTime();
|
|
1298
|
-
case 11:
|
|
1299
|
-
if (y.t3 = y.sent, m = y.t2 - y.t3, p = Math.abs(m), s.log("Drift: ".concat(m)), !(p > o)) {
|
|
1300
|
-
y.next = 22;
|
|
1301
|
-
break;
|
|
1302
|
-
}
|
|
1303
|
-
return y.next = 18, s.adjustSpeed(a, 0);
|
|
1304
|
-
case 18:
|
|
1305
|
-
a.setCurrentTime(i.query().position), s.log("Resync by currentTime"), y.next = 29;
|
|
1306
|
-
break;
|
|
1307
|
-
case 22:
|
|
1308
|
-
if (!(p > h)) {
|
|
1309
|
-
y.next = 29;
|
|
1310
|
-
break;
|
|
1311
|
-
}
|
|
1312
|
-
return f = p / T, v = k, E = f < v ? (v - f) / 2 : v, y.next = 28, s.adjustSpeed(a, E * Math.sign(m));
|
|
1313
|
-
case 28:
|
|
1314
|
-
s.log("Resync by playbackRate");
|
|
1315
|
-
case 29:
|
|
1316
|
-
case "end":
|
|
1317
|
-
return y.stop();
|
|
1318
|
-
}
|
|
1319
|
-
}, N);
|
|
1320
|
-
}));
|
|
1321
|
-
return function() {
|
|
1322
|
-
return O.apply(this, arguments);
|
|
1323
|
-
};
|
|
1324
|
-
})(), _ = setInterval(function() {
|
|
1325
|
-
return g();
|
|
1326
|
-
}, P);
|
|
1327
|
-
return {
|
|
1328
|
-
cancel: function() {
|
|
1329
|
-
return clearInterval(_);
|
|
1330
|
-
}
|
|
1331
|
-
};
|
|
1332
|
-
}
|
|
1333
|
-
/**
|
|
1334
|
-
* @param {string} msg
|
|
1335
|
-
*/
|
|
1336
|
-
}, {
|
|
1337
|
-
key: "log",
|
|
1338
|
-
value: function(i) {
|
|
1339
|
-
var a;
|
|
1340
|
-
(a = this.logger) === null || a === void 0 || a.call(this, "TimingSrcConnector: ".concat(i));
|
|
1341
|
-
}
|
|
1342
|
-
}, {
|
|
1343
|
-
key: "waitForTOReadyState",
|
|
1344
|
-
value: (
|
|
1345
|
-
/**
|
|
1346
|
-
* @param {TimingObject} timingObject
|
|
1347
|
-
* @param {TConnectionState} state
|
|
1348
|
-
* @return {Promise<void>}
|
|
1349
|
-
*/
|
|
1350
|
-
function(i, a) {
|
|
1351
|
-
return new Promise(function(u) {
|
|
1352
|
-
var s = function h() {
|
|
1353
|
-
i.readyState === a ? u() : i.addEventListener("readystatechange", h, {
|
|
1354
|
-
once: !0
|
|
1355
|
-
});
|
|
1356
|
-
};
|
|
1357
|
-
s();
|
|
1358
|
-
});
|
|
1359
|
-
}
|
|
1360
|
-
)
|
|
1361
|
-
}]), t;
|
|
1362
|
-
})(/* @__PURE__ */ ue(EventTarget)), B = /* @__PURE__ */ new WeakMap(), ie = /* @__PURE__ */ new WeakMap(), L = {}, le = /* @__PURE__ */ (function() {
|
|
1363
|
-
function r(e) {
|
|
1364
|
-
var t = this, n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
1365
|
-
if (Ee(this, r), window.jQuery && e instanceof jQuery && (e.length > 1 && window.console && console.warn && console.warn("A jQuery object with multiple elements was passed, using the first element."), e = e[0]), typeof document < "u" && typeof e == "string" && (e = document.getElementById(e)), !Ve(e))
|
|
1366
|
-
throw new TypeError("You must pass either a valid element or a valid id.");
|
|
1367
|
-
if (e.nodeName !== "IFRAME") {
|
|
1368
|
-
var i = e.querySelector("iframe");
|
|
1369
|
-
i && (e = i);
|
|
1370
|
-
}
|
|
1371
|
-
if (e.nodeName === "IFRAME" && !z(e.getAttribute("src") || ""))
|
|
1372
|
-
throw new Error("The player element passed isn’t a Vimeo embed.");
|
|
1373
|
-
if (B.has(e))
|
|
1374
|
-
return B.get(e);
|
|
1375
|
-
this._window = e.ownerDocument.defaultView, this.element = e, this.origin = "*";
|
|
1376
|
-
var a = new q(function(s, h) {
|
|
1377
|
-
if (t._onMessage = function(k) {
|
|
1378
|
-
if (!(!z(k.origin) || t.element.contentWindow !== k.source)) {
|
|
1379
|
-
t.origin === "*" && (t.origin = k.origin);
|
|
1380
|
-
var T = re(k.data), P = T && T.event === "error", g = P && T.data && T.data.method === "ready";
|
|
1381
|
-
if (g) {
|
|
1382
|
-
var _ = new Error(T.data.message);
|
|
1383
|
-
_.name = T.data.name, h(_);
|
|
1384
|
-
return;
|
|
1385
|
-
}
|
|
1386
|
-
var O = T && T.event === "ready", N = T && T.method === "ping";
|
|
1387
|
-
if (O || N) {
|
|
1388
|
-
t.element.setAttribute("data-ready", "true"), s();
|
|
1389
|
-
return;
|
|
1390
|
-
}
|
|
1391
|
-
Ue(t, T);
|
|
1392
|
-
}
|
|
1393
|
-
}, t._window.addEventListener("message", t._onMessage), t.element.nodeName !== "IFRAME") {
|
|
1394
|
-
var o = Oe(e, n), b = Ce(o);
|
|
1395
|
-
_e(b, o, e).then(function(k) {
|
|
1396
|
-
var T = se(k, e);
|
|
1397
|
-
return t.element = T, t._originalElement = e, Ge(e, T), B.set(t.element, t), k;
|
|
1398
|
-
}).catch(h);
|
|
1399
|
-
}
|
|
1400
|
-
});
|
|
1401
|
-
if (ie.set(this, a), B.set(this.element, this), this.element.nodeName === "IFRAME" && x(this, "ping"), L.isEnabled) {
|
|
1402
|
-
var u = function() {
|
|
1403
|
-
return L.exit();
|
|
1404
|
-
};
|
|
1405
|
-
this.fullscreenchangeHandler = function() {
|
|
1406
|
-
L.isFullscreen ? Q(t, "event:exitFullscreen", u) : te(t, "event:exitFullscreen", u), t.ready().then(function() {
|
|
1407
|
-
x(t, "fullscreenchange", L.isFullscreen);
|
|
1408
|
-
});
|
|
1409
|
-
}, L.on("fullscreenchange", this.fullscreenchangeHandler);
|
|
1410
|
-
}
|
|
1411
|
-
return this;
|
|
1412
|
-
}
|
|
1413
|
-
return ke(r, [{
|
|
1414
|
-
key: "callMethod",
|
|
1415
|
-
value: function(t) {
|
|
1416
|
-
for (var n = this, i = arguments.length, a = new Array(i > 1 ? i - 1 : 0), u = 1; u < i; u++)
|
|
1417
|
-
a[u - 1] = arguments[u];
|
|
1418
|
-
if (t == null)
|
|
1419
|
-
throw new TypeError("You must pass a method name.");
|
|
1420
|
-
return new q(function(s, h) {
|
|
1421
|
-
return n.ready().then(function() {
|
|
1422
|
-
Q(n, t, {
|
|
1423
|
-
resolve: s,
|
|
1424
|
-
reject: h
|
|
1425
|
-
}), x(n, t, a);
|
|
1426
|
-
}).catch(h);
|
|
1427
|
-
});
|
|
1428
|
-
}
|
|
1429
|
-
/**
|
|
1430
|
-
* Get a promise for the value of a player property.
|
|
1431
|
-
*
|
|
1432
|
-
* @param {string} name The property name
|
|
1433
|
-
* @return {Promise}
|
|
1434
|
-
*/
|
|
1435
|
-
}, {
|
|
1436
|
-
key: "get",
|
|
1437
|
-
value: function(t) {
|
|
1438
|
-
var n = this;
|
|
1439
|
-
return new q(function(i, a) {
|
|
1440
|
-
return t = de(t, "get"), n.ready().then(function() {
|
|
1441
|
-
Q(n, t, {
|
|
1442
|
-
resolve: i,
|
|
1443
|
-
reject: a
|
|
1444
|
-
}), x(n, t);
|
|
1445
|
-
}).catch(a);
|
|
1446
|
-
});
|
|
1447
|
-
}
|
|
1448
|
-
/**
|
|
1449
|
-
* Get a promise for setting the value of a player property.
|
|
1450
|
-
*
|
|
1451
|
-
* @param {string} name The API method to call.
|
|
1452
|
-
* @param {mixed} value The value to set.
|
|
1453
|
-
* @return {Promise}
|
|
1454
|
-
*/
|
|
1455
|
-
}, {
|
|
1456
|
-
key: "set",
|
|
1457
|
-
value: function(t, n) {
|
|
1458
|
-
var i = this;
|
|
1459
|
-
return new q(function(a, u) {
|
|
1460
|
-
if (t = de(t, "set"), n == null)
|
|
1461
|
-
throw new TypeError("There must be a value to set.");
|
|
1462
|
-
return i.ready().then(function() {
|
|
1463
|
-
Q(i, t, {
|
|
1464
|
-
resolve: a,
|
|
1465
|
-
reject: u
|
|
1466
|
-
}), x(i, t, n);
|
|
1467
|
-
}).catch(u);
|
|
1468
|
-
});
|
|
1469
|
-
}
|
|
1470
|
-
/**
|
|
1471
|
-
* Add an event listener for the specified event. Will call the
|
|
1472
|
-
* callback with a single parameter, `data`, that contains the data for
|
|
1473
|
-
* that event.
|
|
1474
|
-
*
|
|
1475
|
-
* @param {string} eventName The name of the event.
|
|
1476
|
-
* @param {function(*)} callback The function to call when the event fires.
|
|
1477
|
-
* @return {void}
|
|
1478
|
-
*/
|
|
1479
|
-
}, {
|
|
1480
|
-
key: "on",
|
|
1481
|
-
value: function(t, n) {
|
|
1482
|
-
if (!t)
|
|
1483
|
-
throw new TypeError("You must pass an event name.");
|
|
1484
|
-
if (!n)
|
|
1485
|
-
throw new TypeError("You must pass a callback function.");
|
|
1486
|
-
if (typeof n != "function")
|
|
1487
|
-
throw new TypeError("The callback must be a function.");
|
|
1488
|
-
var i = ee(this, "event:".concat(t));
|
|
1489
|
-
i.length === 0 && this.callMethod("addEventListener", t).catch(function() {
|
|
1490
|
-
}), Q(this, "event:".concat(t), n);
|
|
1491
|
-
}
|
|
1492
|
-
/**
|
|
1493
|
-
* Remove an event listener for the specified event. Will remove all
|
|
1494
|
-
* listeners for that event if a `callback` isn’t passed, or only that
|
|
1495
|
-
* specific callback if it is passed.
|
|
1496
|
-
*
|
|
1497
|
-
* @param {string} eventName The name of the event.
|
|
1498
|
-
* @param {function} [callback] The specific callback to remove.
|
|
1499
|
-
* @return {void}
|
|
1500
|
-
*/
|
|
1501
|
-
}, {
|
|
1502
|
-
key: "off",
|
|
1503
|
-
value: function(t, n) {
|
|
1504
|
-
if (!t)
|
|
1505
|
-
throw new TypeError("You must pass an event name.");
|
|
1506
|
-
if (n && typeof n != "function")
|
|
1507
|
-
throw new TypeError("The callback must be a function.");
|
|
1508
|
-
var i = te(this, "event:".concat(t), n);
|
|
1509
|
-
i && this.callMethod("removeEventListener", t).catch(function(a) {
|
|
1510
|
-
});
|
|
1511
|
-
}
|
|
1512
|
-
/**
|
|
1513
|
-
* A promise to load a new video.
|
|
1514
|
-
*
|
|
1515
|
-
* @promise LoadVideoPromise
|
|
1516
|
-
* @fulfill {number} The video with this id or url successfully loaded.
|
|
1517
|
-
* @reject {TypeError} The id was not a number.
|
|
1518
|
-
*/
|
|
1519
|
-
/**
|
|
1520
|
-
* Load a new video into this embed. The promise will be resolved if
|
|
1521
|
-
* the video is successfully loaded, or it will be rejected if it could
|
|
1522
|
-
* not be loaded.
|
|
1523
|
-
*
|
|
1524
|
-
* @param {number|string|object} options The id of the video, the url of the video, or an object with embed options.
|
|
1525
|
-
* @return {LoadVideoPromise}
|
|
1526
|
-
*/
|
|
1527
|
-
}, {
|
|
1528
|
-
key: "loadVideo",
|
|
1529
|
-
value: function(t) {
|
|
1530
|
-
return this.callMethod("loadVideo", t);
|
|
1531
|
-
}
|
|
1532
|
-
/**
|
|
1533
|
-
* A promise to perform an action when the Player is ready.
|
|
1534
|
-
*
|
|
1535
|
-
* @todo document errors
|
|
1536
|
-
* @promise LoadVideoPromise
|
|
1537
|
-
* @fulfill {void}
|
|
1538
|
-
*/
|
|
1539
|
-
/**
|
|
1540
|
-
* Trigger a function when the player iframe has initialized. You do not
|
|
1541
|
-
* need to wait for `ready` to trigger to begin adding event listeners
|
|
1542
|
-
* or calling other methods.
|
|
1543
|
-
*
|
|
1544
|
-
* @return {ReadyPromise}
|
|
1545
|
-
*/
|
|
1546
|
-
}, {
|
|
1547
|
-
key: "ready",
|
|
1548
|
-
value: function() {
|
|
1549
|
-
var t = ie.get(this) || new q(function(n, i) {
|
|
1550
|
-
i(new Error("Unknown player. Probably unloaded."));
|
|
1551
|
-
});
|
|
1552
|
-
return q.resolve(t);
|
|
1553
|
-
}
|
|
1554
|
-
/**
|
|
1555
|
-
* A promise to add a cue point to the player.
|
|
1556
|
-
*
|
|
1557
|
-
* @promise AddCuePointPromise
|
|
1558
|
-
* @fulfill {string} The id of the cue point to use for removeCuePoint.
|
|
1559
|
-
* @reject {RangeError} the time was less than 0 or greater than the
|
|
1560
|
-
* video’s duration.
|
|
1561
|
-
* @reject {UnsupportedError} Cue points are not supported with the current
|
|
1562
|
-
* player or browser.
|
|
1563
|
-
*/
|
|
1564
|
-
/**
|
|
1565
|
-
* Add a cue point to the player.
|
|
1566
|
-
*
|
|
1567
|
-
* @param {number} time The time for the cue point.
|
|
1568
|
-
* @param {object} [data] Arbitrary data to be returned with the cue point.
|
|
1569
|
-
* @return {AddCuePointPromise}
|
|
1570
|
-
*/
|
|
1571
|
-
}, {
|
|
1572
|
-
key: "addCuePoint",
|
|
1573
|
-
value: function(t) {
|
|
1574
|
-
var n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {};
|
|
1575
|
-
return this.callMethod("addCuePoint", {
|
|
1576
|
-
time: t,
|
|
1577
|
-
data: n
|
|
1578
|
-
});
|
|
1579
|
-
}
|
|
1580
|
-
/**
|
|
1581
|
-
* A promise to remove a cue point from the player.
|
|
1582
|
-
*
|
|
1583
|
-
* @promise AddCuePointPromise
|
|
1584
|
-
* @fulfill {string} The id of the cue point that was removed.
|
|
1585
|
-
* @reject {InvalidCuePoint} The cue point with the specified id was not
|
|
1586
|
-
* found.
|
|
1587
|
-
* @reject {UnsupportedError} Cue points are not supported with the current
|
|
1588
|
-
* player or browser.
|
|
1589
|
-
*/
|
|
1590
|
-
/**
|
|
1591
|
-
* Remove a cue point from the video.
|
|
1592
|
-
*
|
|
1593
|
-
* @param {string} id The id of the cue point to remove.
|
|
1594
|
-
* @return {RemoveCuePointPromise}
|
|
1595
|
-
*/
|
|
1596
|
-
}, {
|
|
1597
|
-
key: "removeCuePoint",
|
|
1598
|
-
value: function(t) {
|
|
1599
|
-
return this.callMethod("removeCuePoint", t);
|
|
1600
|
-
}
|
|
1601
|
-
/**
|
|
1602
|
-
* A representation of a text track on a video.
|
|
1603
|
-
*
|
|
1604
|
-
* @typedef {Object} VimeoTextTrack
|
|
1605
|
-
* @property {string} language The ISO language code.
|
|
1606
|
-
* @property {string} kind The kind of track it is (captions or subtitles).
|
|
1607
|
-
* @property {string} label The human‐readable label for the track.
|
|
1608
|
-
*/
|
|
1609
|
-
/**
|
|
1610
|
-
* A promise to enable a text track.
|
|
1611
|
-
*
|
|
1612
|
-
* @promise EnableTextTrackPromise
|
|
1613
|
-
* @fulfill {VimeoTextTrack} The text track that was enabled.
|
|
1614
|
-
* @reject {InvalidTrackLanguageError} No track was available with the
|
|
1615
|
-
* specified language.
|
|
1616
|
-
* @reject {InvalidTrackError} No track was available with the specified
|
|
1617
|
-
* language and kind.
|
|
1618
|
-
*/
|
|
1619
|
-
/**
|
|
1620
|
-
* Enable the text track with the specified language, and optionally the
|
|
1621
|
-
* specified kind (captions or subtitles).
|
|
1622
|
-
*
|
|
1623
|
-
* When set via the API, the track language will not change the viewer’s
|
|
1624
|
-
* stored preference.
|
|
1625
|
-
*
|
|
1626
|
-
* @param {string} language The two‐letter language code.
|
|
1627
|
-
* @param {string} [kind] The kind of track to enable (captions or subtitles).
|
|
1628
|
-
* @return {EnableTextTrackPromise}
|
|
1629
|
-
*/
|
|
1630
|
-
}, {
|
|
1631
|
-
key: "enableTextTrack",
|
|
1632
|
-
value: function(t, n) {
|
|
1633
|
-
if (!t)
|
|
1634
|
-
throw new TypeError("You must pass a language.");
|
|
1635
|
-
return this.callMethod("enableTextTrack", {
|
|
1636
|
-
language: t,
|
|
1637
|
-
kind: n
|
|
1638
|
-
});
|
|
1639
|
-
}
|
|
1640
|
-
/**
|
|
1641
|
-
* A promise to disable the active text track.
|
|
1642
|
-
*
|
|
1643
|
-
* @promise DisableTextTrackPromise
|
|
1644
|
-
* @fulfill {void} The track was disabled.
|
|
1645
|
-
*/
|
|
1646
|
-
/**
|
|
1647
|
-
* Disable the currently-active text track.
|
|
1648
|
-
*
|
|
1649
|
-
* @return {DisableTextTrackPromise}
|
|
1650
|
-
*/
|
|
1651
|
-
}, {
|
|
1652
|
-
key: "disableTextTrack",
|
|
1653
|
-
value: function() {
|
|
1654
|
-
return this.callMethod("disableTextTrack");
|
|
1655
|
-
}
|
|
1656
|
-
/**
|
|
1657
|
-
* A promise to pause the video.
|
|
1658
|
-
*
|
|
1659
|
-
* @promise PausePromise
|
|
1660
|
-
* @fulfill {void} The video was paused.
|
|
1661
|
-
*/
|
|
1662
|
-
/**
|
|
1663
|
-
* Pause the video if it’s playing.
|
|
1664
|
-
*
|
|
1665
|
-
* @return {PausePromise}
|
|
1666
|
-
*/
|
|
1667
|
-
}, {
|
|
1668
|
-
key: "pause",
|
|
1669
|
-
value: function() {
|
|
1670
|
-
return this.callMethod("pause");
|
|
1671
|
-
}
|
|
1672
|
-
/**
|
|
1673
|
-
* A promise to play the video.
|
|
1674
|
-
*
|
|
1675
|
-
* @promise PlayPromise
|
|
1676
|
-
* @fulfill {void} The video was played.
|
|
1677
|
-
*/
|
|
1678
|
-
/**
|
|
1679
|
-
* Play the video if it’s paused. **Note:** on iOS and some other
|
|
1680
|
-
* mobile devices, you cannot programmatically trigger play. Once the
|
|
1681
|
-
* viewer has tapped on the play button in the player, however, you
|
|
1682
|
-
* will be able to use this function.
|
|
1683
|
-
*
|
|
1684
|
-
* @return {PlayPromise}
|
|
1685
|
-
*/
|
|
1686
|
-
}, {
|
|
1687
|
-
key: "play",
|
|
1688
|
-
value: function() {
|
|
1689
|
-
return this.callMethod("play");
|
|
1690
|
-
}
|
|
1691
|
-
/**
|
|
1692
|
-
* Request that the player enters fullscreen.
|
|
1693
|
-
* @return {Promise}
|
|
1694
|
-
*/
|
|
1695
|
-
}, {
|
|
1696
|
-
key: "requestFullscreen",
|
|
1697
|
-
value: function() {
|
|
1698
|
-
return L.isEnabled ? L.request(this.element) : this.callMethod("requestFullscreen");
|
|
1699
|
-
}
|
|
1700
|
-
/**
|
|
1701
|
-
* Request that the player exits fullscreen.
|
|
1702
|
-
* @return {Promise}
|
|
1703
|
-
*/
|
|
1704
|
-
}, {
|
|
1705
|
-
key: "exitFullscreen",
|
|
1706
|
-
value: function() {
|
|
1707
|
-
return L.isEnabled ? L.exit() : this.callMethod("exitFullscreen");
|
|
1708
|
-
}
|
|
1709
|
-
/**
|
|
1710
|
-
* Returns true if the player is currently fullscreen.
|
|
1711
|
-
* @return {Promise}
|
|
1712
|
-
*/
|
|
1713
|
-
}, {
|
|
1714
|
-
key: "getFullscreen",
|
|
1715
|
-
value: function() {
|
|
1716
|
-
return L.isEnabled ? q.resolve(L.isFullscreen) : this.get("fullscreen");
|
|
1717
|
-
}
|
|
1718
|
-
/**
|
|
1719
|
-
* Request that the player enters picture-in-picture.
|
|
1720
|
-
* @return {Promise}
|
|
1721
|
-
*/
|
|
1722
|
-
}, {
|
|
1723
|
-
key: "requestPictureInPicture",
|
|
1724
|
-
value: function() {
|
|
1725
|
-
return this.callMethod("requestPictureInPicture");
|
|
1726
|
-
}
|
|
1727
|
-
/**
|
|
1728
|
-
* Request that the player exits picture-in-picture.
|
|
1729
|
-
* @return {Promise}
|
|
1730
|
-
*/
|
|
1731
|
-
}, {
|
|
1732
|
-
key: "exitPictureInPicture",
|
|
1733
|
-
value: function() {
|
|
1734
|
-
return this.callMethod("exitPictureInPicture");
|
|
1735
|
-
}
|
|
1736
|
-
/**
|
|
1737
|
-
* Returns true if the player is currently picture-in-picture.
|
|
1738
|
-
* @return {Promise}
|
|
1739
|
-
*/
|
|
1740
|
-
}, {
|
|
1741
|
-
key: "getPictureInPicture",
|
|
1742
|
-
value: function() {
|
|
1743
|
-
return this.get("pictureInPicture");
|
|
1744
|
-
}
|
|
1745
|
-
/**
|
|
1746
|
-
* A promise to prompt the viewer to initiate remote playback.
|
|
1747
|
-
*
|
|
1748
|
-
* @promise RemotePlaybackPromptPromise
|
|
1749
|
-
* @fulfill {void}
|
|
1750
|
-
* @reject {NotFoundError} No remote playback device is available.
|
|
1751
|
-
*/
|
|
1752
|
-
/**
|
|
1753
|
-
* Request to prompt the user to initiate remote playback.
|
|
1754
|
-
*
|
|
1755
|
-
* @return {RemotePlaybackPromptPromise}
|
|
1756
|
-
*/
|
|
1757
|
-
}, {
|
|
1758
|
-
key: "remotePlaybackPrompt",
|
|
1759
|
-
value: function() {
|
|
1760
|
-
return this.callMethod("remotePlaybackPrompt");
|
|
1761
|
-
}
|
|
1762
|
-
/**
|
|
1763
|
-
* A promise to unload the video.
|
|
1764
|
-
*
|
|
1765
|
-
* @promise UnloadPromise
|
|
1766
|
-
* @fulfill {void} The video was unloaded.
|
|
1767
|
-
*/
|
|
1768
|
-
/**
|
|
1769
|
-
* Return the player to its initial state.
|
|
1770
|
-
*
|
|
1771
|
-
* @return {UnloadPromise}
|
|
1772
|
-
*/
|
|
1773
|
-
}, {
|
|
1774
|
-
key: "unload",
|
|
1775
|
-
value: function() {
|
|
1776
|
-
return this.callMethod("unload");
|
|
1777
|
-
}
|
|
1778
|
-
/**
|
|
1779
|
-
* Cleanup the player and remove it from the DOM
|
|
1780
|
-
*
|
|
1781
|
-
* It won't be usable and a new one should be constructed
|
|
1782
|
-
* in order to do any operations.
|
|
1783
|
-
*
|
|
1784
|
-
* @return {Promise}
|
|
1785
|
-
*/
|
|
1786
|
-
}, {
|
|
1787
|
-
key: "destroy",
|
|
1788
|
-
value: function() {
|
|
1789
|
-
var t = this;
|
|
1790
|
-
return new q(function(n) {
|
|
1791
|
-
if (ie.delete(t), B.delete(t.element), t._originalElement && (B.delete(t._originalElement), t._originalElement.removeAttribute("data-vimeo-initialized")), t.element && t.element.nodeName === "IFRAME" && t.element.parentNode && (t.element.parentNode.parentNode && t._originalElement && t._originalElement !== t.element.parentNode ? t.element.parentNode.parentNode.removeChild(t.element.parentNode) : t.element.parentNode.removeChild(t.element)), t.element && t.element.nodeName === "DIV" && t.element.parentNode) {
|
|
1792
|
-
t.element.removeAttribute("data-vimeo-initialized");
|
|
1793
|
-
var i = t.element.querySelector("iframe");
|
|
1794
|
-
i && i.parentNode && (i.parentNode.parentNode && t._originalElement && t._originalElement !== i.parentNode ? i.parentNode.parentNode.removeChild(i.parentNode) : i.parentNode.removeChild(i));
|
|
1795
|
-
}
|
|
1796
|
-
t._window.removeEventListener("message", t._onMessage), L.isEnabled && L.off("fullscreenchange", t.fullscreenchangeHandler), n();
|
|
1797
|
-
});
|
|
1798
|
-
}
|
|
1799
|
-
/**
|
|
1800
|
-
* A promise to get the autopause behavior of the video.
|
|
1801
|
-
*
|
|
1802
|
-
* @promise GetAutopausePromise
|
|
1803
|
-
* @fulfill {boolean} Whether autopause is turned on or off.
|
|
1804
|
-
* @reject {UnsupportedError} Autopause is not supported with the current
|
|
1805
|
-
* player or browser.
|
|
1806
|
-
*/
|
|
1807
|
-
/**
|
|
1808
|
-
* Get the autopause behavior for this player.
|
|
1809
|
-
*
|
|
1810
|
-
* @return {GetAutopausePromise}
|
|
1811
|
-
*/
|
|
1812
|
-
}, {
|
|
1813
|
-
key: "getAutopause",
|
|
1814
|
-
value: function() {
|
|
1815
|
-
return this.get("autopause");
|
|
1816
|
-
}
|
|
1817
|
-
/**
|
|
1818
|
-
* A promise to set the autopause behavior of the video.
|
|
1819
|
-
*
|
|
1820
|
-
* @promise SetAutopausePromise
|
|
1821
|
-
* @fulfill {boolean} Whether autopause is turned on or off.
|
|
1822
|
-
* @reject {UnsupportedError} Autopause is not supported with the current
|
|
1823
|
-
* player or browser.
|
|
1824
|
-
*/
|
|
1825
|
-
/**
|
|
1826
|
-
* Enable or disable the autopause behavior of this player.
|
|
1827
|
-
*
|
|
1828
|
-
* By default, when another video is played in the same browser, this
|
|
1829
|
-
* player will automatically pause. Unless you have a specific reason
|
|
1830
|
-
* for doing so, we recommend that you leave autopause set to the
|
|
1831
|
-
* default (`true`).
|
|
1832
|
-
*
|
|
1833
|
-
* @param {boolean} autopause
|
|
1834
|
-
* @return {SetAutopausePromise}
|
|
1835
|
-
*/
|
|
1836
|
-
}, {
|
|
1837
|
-
key: "setAutopause",
|
|
1838
|
-
value: function(t) {
|
|
1839
|
-
return this.set("autopause", t);
|
|
1840
|
-
}
|
|
1841
|
-
/**
|
|
1842
|
-
* A promise to get the buffered property of the video.
|
|
1843
|
-
*
|
|
1844
|
-
* @promise GetBufferedPromise
|
|
1845
|
-
* @fulfill {Array} Buffered Timeranges converted to an Array.
|
|
1846
|
-
*/
|
|
1847
|
-
/**
|
|
1848
|
-
* Get the buffered property of the video.
|
|
1849
|
-
*
|
|
1850
|
-
* @return {GetBufferedPromise}
|
|
1851
|
-
*/
|
|
1852
|
-
}, {
|
|
1853
|
-
key: "getBuffered",
|
|
1854
|
-
value: function() {
|
|
1855
|
-
return this.get("buffered");
|
|
1856
|
-
}
|
|
1857
|
-
/**
|
|
1858
|
-
* @typedef {Object} CameraProperties
|
|
1859
|
-
* @prop {number} props.yaw - Number between 0 and 360.
|
|
1860
|
-
* @prop {number} props.pitch - Number between -90 and 90.
|
|
1861
|
-
* @prop {number} props.roll - Number between -180 and 180.
|
|
1862
|
-
* @prop {number} props.fov - The field of view in degrees.
|
|
1863
|
-
*/
|
|
1864
|
-
/**
|
|
1865
|
-
* A promise to get the camera properties of the player.
|
|
1866
|
-
*
|
|
1867
|
-
* @promise GetCameraPromise
|
|
1868
|
-
* @fulfill {CameraProperties} The camera properties.
|
|
1869
|
-
*/
|
|
1870
|
-
/**
|
|
1871
|
-
* For 360° videos get the camera properties for this player.
|
|
1872
|
-
*
|
|
1873
|
-
* @return {GetCameraPromise}
|
|
1874
|
-
*/
|
|
1875
|
-
}, {
|
|
1876
|
-
key: "getCameraProps",
|
|
1877
|
-
value: function() {
|
|
1878
|
-
return this.get("cameraProps");
|
|
1879
|
-
}
|
|
1880
|
-
/**
|
|
1881
|
-
* A promise to set the camera properties of the player.
|
|
1882
|
-
*
|
|
1883
|
-
* @promise SetCameraPromise
|
|
1884
|
-
* @fulfill {Object} The camera was successfully set.
|
|
1885
|
-
* @reject {RangeError} The range was out of bounds.
|
|
1886
|
-
*/
|
|
1887
|
-
/**
|
|
1888
|
-
* For 360° videos set the camera properties for this player.
|
|
1889
|
-
*
|
|
1890
|
-
* @param {CameraProperties} camera The camera properties
|
|
1891
|
-
* @return {SetCameraPromise}
|
|
1892
|
-
*/
|
|
1893
|
-
}, {
|
|
1894
|
-
key: "setCameraProps",
|
|
1895
|
-
value: function(t) {
|
|
1896
|
-
return this.set("cameraProps", t);
|
|
1897
|
-
}
|
|
1898
|
-
/**
|
|
1899
|
-
* A representation of a chapter.
|
|
1900
|
-
*
|
|
1901
|
-
* @typedef {Object} VimeoChapter
|
|
1902
|
-
* @property {number} startTime The start time of the chapter.
|
|
1903
|
-
* @property {object} title The title of the chapter.
|
|
1904
|
-
* @property {number} index The place in the order of Chapters. Starts at 1.
|
|
1905
|
-
*/
|
|
1906
|
-
/**
|
|
1907
|
-
* A promise to get chapters for the video.
|
|
1908
|
-
*
|
|
1909
|
-
* @promise GetChaptersPromise
|
|
1910
|
-
* @fulfill {VimeoChapter[]} The chapters for the video.
|
|
1911
|
-
*/
|
|
1912
|
-
/**
|
|
1913
|
-
* Get an array of all the chapters for the video.
|
|
1914
|
-
*
|
|
1915
|
-
* @return {GetChaptersPromise}
|
|
1916
|
-
*/
|
|
1917
|
-
}, {
|
|
1918
|
-
key: "getChapters",
|
|
1919
|
-
value: function() {
|
|
1920
|
-
return this.get("chapters");
|
|
1921
|
-
}
|
|
1922
|
-
/**
|
|
1923
|
-
* A promise to get the currently active chapter.
|
|
1924
|
-
*
|
|
1925
|
-
* @promise GetCurrentChaptersPromise
|
|
1926
|
-
* @fulfill {VimeoChapter|undefined} The current chapter for the video.
|
|
1927
|
-
*/
|
|
1928
|
-
/**
|
|
1929
|
-
* Get the currently active chapter for the video.
|
|
1930
|
-
*
|
|
1931
|
-
* @return {GetCurrentChaptersPromise}
|
|
1932
|
-
*/
|
|
1933
|
-
}, {
|
|
1934
|
-
key: "getCurrentChapter",
|
|
1935
|
-
value: function() {
|
|
1936
|
-
return this.get("currentChapter");
|
|
1937
|
-
}
|
|
1938
|
-
/**
|
|
1939
|
-
* A promise to get the accent color of the player.
|
|
1940
|
-
*
|
|
1941
|
-
* @promise GetColorPromise
|
|
1942
|
-
* @fulfill {string} The hex color of the player.
|
|
1943
|
-
*/
|
|
1944
|
-
/**
|
|
1945
|
-
* Get the accent color for this player. Note this is deprecated in place of `getColorTwo`.
|
|
1946
|
-
*
|
|
1947
|
-
* @return {GetColorPromise}
|
|
1948
|
-
*/
|
|
1949
|
-
}, {
|
|
1950
|
-
key: "getColor",
|
|
1951
|
-
value: function() {
|
|
1952
|
-
return this.get("color");
|
|
1953
|
-
}
|
|
1954
|
-
/**
|
|
1955
|
-
* A promise to get all colors for the player in an array.
|
|
1956
|
-
*
|
|
1957
|
-
* @promise GetColorsPromise
|
|
1958
|
-
* @fulfill {string[]} The hex colors of the player.
|
|
1959
|
-
*/
|
|
1960
|
-
/**
|
|
1961
|
-
* Get all the colors for this player in an array: [colorOne, colorTwo, colorThree, colorFour]
|
|
1962
|
-
*
|
|
1963
|
-
* @return {GetColorPromise}
|
|
1964
|
-
*/
|
|
1965
|
-
}, {
|
|
1966
|
-
key: "getColors",
|
|
1967
|
-
value: function() {
|
|
1968
|
-
return q.all([this.get("colorOne"), this.get("colorTwo"), this.get("colorThree"), this.get("colorFour")]);
|
|
1969
|
-
}
|
|
1970
|
-
/**
|
|
1971
|
-
* A promise to set the accent color of the player.
|
|
1972
|
-
*
|
|
1973
|
-
* @promise SetColorPromise
|
|
1974
|
-
* @fulfill {string} The color was successfully set.
|
|
1975
|
-
* @reject {TypeError} The string was not a valid hex or rgb color.
|
|
1976
|
-
* @reject {ContrastError} The color was set, but the contrast is
|
|
1977
|
-
* outside of the acceptable range.
|
|
1978
|
-
* @reject {EmbedSettingsError} The owner of the player has chosen to
|
|
1979
|
-
* use a specific color.
|
|
1980
|
-
*/
|
|
1981
|
-
/**
|
|
1982
|
-
* Set the accent color of this player to a hex or rgb string. Setting the
|
|
1983
|
-
* color may fail if the owner of the video has set their embed
|
|
1984
|
-
* preferences to force a specific color.
|
|
1985
|
-
* Note this is deprecated in place of `setColorTwo`.
|
|
1986
|
-
*
|
|
1987
|
-
* @param {string} color The hex or rgb color string to set.
|
|
1988
|
-
* @return {SetColorPromise}
|
|
1989
|
-
*/
|
|
1990
|
-
}, {
|
|
1991
|
-
key: "setColor",
|
|
1992
|
-
value: function(t) {
|
|
1993
|
-
return this.set("color", t);
|
|
1994
|
-
}
|
|
1995
|
-
/**
|
|
1996
|
-
* A promise to set all colors for the player.
|
|
1997
|
-
*
|
|
1998
|
-
* @promise SetColorsPromise
|
|
1999
|
-
* @fulfill {string[]} The colors were successfully set.
|
|
2000
|
-
* @reject {TypeError} The string was not a valid hex or rgb color.
|
|
2001
|
-
* @reject {ContrastError} The color was set, but the contrast is
|
|
2002
|
-
* outside of the acceptable range.
|
|
2003
|
-
* @reject {EmbedSettingsError} The owner of the player has chosen to
|
|
2004
|
-
* use a specific color.
|
|
2005
|
-
*/
|
|
2006
|
-
/**
|
|
2007
|
-
* Set the colors of this player to a hex or rgb string. Setting the
|
|
2008
|
-
* color may fail if the owner of the video has set their embed
|
|
2009
|
-
* preferences to force a specific color.
|
|
2010
|
-
* The colors should be passed in as an array: [colorOne, colorTwo, colorThree, colorFour].
|
|
2011
|
-
* If a color should not be set, the index in the array can be left as null.
|
|
2012
|
-
*
|
|
2013
|
-
* @param {string[]} colors Array of the hex or rgb color strings to set.
|
|
2014
|
-
* @return {SetColorsPromise}
|
|
2015
|
-
*/
|
|
2016
|
-
}, {
|
|
2017
|
-
key: "setColors",
|
|
2018
|
-
value: function(t) {
|
|
2019
|
-
if (!Array.isArray(t))
|
|
2020
|
-
return new q(function(a, u) {
|
|
2021
|
-
return u(new TypeError("Argument must be an array."));
|
|
2022
|
-
});
|
|
2023
|
-
var n = new q(function(a) {
|
|
2024
|
-
return a(null);
|
|
2025
|
-
}), i = [t[0] ? this.set("colorOne", t[0]) : n, t[1] ? this.set("colorTwo", t[1]) : n, t[2] ? this.set("colorThree", t[2]) : n, t[3] ? this.set("colorFour", t[3]) : n];
|
|
2026
|
-
return q.all(i);
|
|
2027
|
-
}
|
|
2028
|
-
/**
|
|
2029
|
-
* A representation of a cue point.
|
|
2030
|
-
*
|
|
2031
|
-
* @typedef {Object} VimeoCuePoint
|
|
2032
|
-
* @property {number} time The time of the cue point.
|
|
2033
|
-
* @property {object} data The data passed when adding the cue point.
|
|
2034
|
-
* @property {string} id The unique id for use with removeCuePoint.
|
|
2035
|
-
*/
|
|
2036
|
-
/**
|
|
2037
|
-
* A promise to get the cue points of a video.
|
|
2038
|
-
*
|
|
2039
|
-
* @promise GetCuePointsPromise
|
|
2040
|
-
* @fulfill {VimeoCuePoint[]} The cue points added to the video.
|
|
2041
|
-
* @reject {UnsupportedError} Cue points are not supported with the current
|
|
2042
|
-
* player or browser.
|
|
2043
|
-
*/
|
|
2044
|
-
/**
|
|
2045
|
-
* Get an array of the cue points added to the video.
|
|
2046
|
-
*
|
|
2047
|
-
* @return {GetCuePointsPromise}
|
|
2048
|
-
*/
|
|
2049
|
-
}, {
|
|
2050
|
-
key: "getCuePoints",
|
|
2051
|
-
value: function() {
|
|
2052
|
-
return this.get("cuePoints");
|
|
2053
|
-
}
|
|
2054
|
-
/**
|
|
2055
|
-
* A promise to get the current time of the video.
|
|
2056
|
-
*
|
|
2057
|
-
* @promise GetCurrentTimePromise
|
|
2058
|
-
* @fulfill {number} The current time in seconds.
|
|
2059
|
-
*/
|
|
2060
|
-
/**
|
|
2061
|
-
* Get the current playback position in seconds.
|
|
2062
|
-
*
|
|
2063
|
-
* @return {GetCurrentTimePromise}
|
|
2064
|
-
*/
|
|
2065
|
-
}, {
|
|
2066
|
-
key: "getCurrentTime",
|
|
2067
|
-
value: function() {
|
|
2068
|
-
return this.get("currentTime");
|
|
2069
|
-
}
|
|
2070
|
-
/**
|
|
2071
|
-
* A promise to set the current time of the video.
|
|
2072
|
-
*
|
|
2073
|
-
* @promise SetCurrentTimePromise
|
|
2074
|
-
* @fulfill {number} The actual current time that was set.
|
|
2075
|
-
* @reject {RangeError} the time was less than 0 or greater than the
|
|
2076
|
-
* video’s duration.
|
|
2077
|
-
*/
|
|
2078
|
-
/**
|
|
2079
|
-
* Set the current playback position in seconds. If the player was
|
|
2080
|
-
* paused, it will remain paused. Likewise, if the player was playing,
|
|
2081
|
-
* it will resume playing once the video has buffered.
|
|
2082
|
-
*
|
|
2083
|
-
* You can provide an accurate time and the player will attempt to seek
|
|
2084
|
-
* to as close to that time as possible. The exact time will be the
|
|
2085
|
-
* fulfilled value of the promise.
|
|
2086
|
-
*
|
|
2087
|
-
* @param {number} currentTime
|
|
2088
|
-
* @return {SetCurrentTimePromise}
|
|
2089
|
-
*/
|
|
2090
|
-
}, {
|
|
2091
|
-
key: "setCurrentTime",
|
|
2092
|
-
value: function(t) {
|
|
2093
|
-
return this.set("currentTime", t);
|
|
2094
|
-
}
|
|
2095
|
-
/**
|
|
2096
|
-
* A promise to get the duration of the video.
|
|
2097
|
-
*
|
|
2098
|
-
* @promise GetDurationPromise
|
|
2099
|
-
* @fulfill {number} The duration in seconds.
|
|
2100
|
-
*/
|
|
2101
|
-
/**
|
|
2102
|
-
* Get the duration of the video in seconds. It will be rounded to the
|
|
2103
|
-
* nearest second before playback begins, and to the nearest thousandth
|
|
2104
|
-
* of a second after playback begins.
|
|
2105
|
-
*
|
|
2106
|
-
* @return {GetDurationPromise}
|
|
2107
|
-
*/
|
|
2108
|
-
}, {
|
|
2109
|
-
key: "getDuration",
|
|
2110
|
-
value: function() {
|
|
2111
|
-
return this.get("duration");
|
|
2112
|
-
}
|
|
2113
|
-
/**
|
|
2114
|
-
* A promise to get the ended state of the video.
|
|
2115
|
-
*
|
|
2116
|
-
* @promise GetEndedPromise
|
|
2117
|
-
* @fulfill {boolean} Whether or not the video has ended.
|
|
2118
|
-
*/
|
|
2119
|
-
/**
|
|
2120
|
-
* Get the ended state of the video. The video has ended if
|
|
2121
|
-
* `currentTime === duration`.
|
|
2122
|
-
*
|
|
2123
|
-
* @return {GetEndedPromise}
|
|
2124
|
-
*/
|
|
2125
|
-
}, {
|
|
2126
|
-
key: "getEnded",
|
|
2127
|
-
value: function() {
|
|
2128
|
-
return this.get("ended");
|
|
2129
|
-
}
|
|
2130
|
-
/**
|
|
2131
|
-
* A promise to get the loop state of the player.
|
|
2132
|
-
*
|
|
2133
|
-
* @promise GetLoopPromise
|
|
2134
|
-
* @fulfill {boolean} Whether or not the player is set to loop.
|
|
2135
|
-
*/
|
|
2136
|
-
/**
|
|
2137
|
-
* Get the loop state of the player.
|
|
2138
|
-
*
|
|
2139
|
-
* @return {GetLoopPromise}
|
|
2140
|
-
*/
|
|
2141
|
-
}, {
|
|
2142
|
-
key: "getLoop",
|
|
2143
|
-
value: function() {
|
|
2144
|
-
return this.get("loop");
|
|
2145
|
-
}
|
|
2146
|
-
/**
|
|
2147
|
-
* A promise to set the loop state of the player.
|
|
2148
|
-
*
|
|
2149
|
-
* @promise SetLoopPromise
|
|
2150
|
-
* @fulfill {boolean} The loop state that was set.
|
|
2151
|
-
*/
|
|
2152
|
-
/**
|
|
2153
|
-
* Set the loop state of the player. When set to `true`, the player
|
|
2154
|
-
* will start over immediately once playback ends.
|
|
2155
|
-
*
|
|
2156
|
-
* @param {boolean} loop
|
|
2157
|
-
* @return {SetLoopPromise}
|
|
2158
|
-
*/
|
|
2159
|
-
}, {
|
|
2160
|
-
key: "setLoop",
|
|
2161
|
-
value: function(t) {
|
|
2162
|
-
return this.set("loop", t);
|
|
2163
|
-
}
|
|
2164
|
-
/**
|
|
2165
|
-
* A promise to set the muted state of the player.
|
|
2166
|
-
*
|
|
2167
|
-
* @promise SetMutedPromise
|
|
2168
|
-
* @fulfill {boolean} The muted state that was set.
|
|
2169
|
-
*/
|
|
2170
|
-
/**
|
|
2171
|
-
* Set the muted state of the player. When set to `true`, the player
|
|
2172
|
-
* volume will be muted.
|
|
2173
|
-
*
|
|
2174
|
-
* @param {boolean} muted
|
|
2175
|
-
* @return {SetMutedPromise}
|
|
2176
|
-
*/
|
|
2177
|
-
}, {
|
|
2178
|
-
key: "setMuted",
|
|
2179
|
-
value: function(t) {
|
|
2180
|
-
return this.set("muted", t);
|
|
2181
|
-
}
|
|
2182
|
-
/**
|
|
2183
|
-
* A promise to get the muted state of the player.
|
|
2184
|
-
*
|
|
2185
|
-
* @promise GetMutedPromise
|
|
2186
|
-
* @fulfill {boolean} Whether or not the player is muted.
|
|
2187
|
-
*/
|
|
2188
|
-
/**
|
|
2189
|
-
* Get the muted state of the player.
|
|
2190
|
-
*
|
|
2191
|
-
* @return {GetMutedPromise}
|
|
2192
|
-
*/
|
|
2193
|
-
}, {
|
|
2194
|
-
key: "getMuted",
|
|
2195
|
-
value: function() {
|
|
2196
|
-
return this.get("muted");
|
|
2197
|
-
}
|
|
2198
|
-
/**
|
|
2199
|
-
* A promise to get the paused state of the player.
|
|
2200
|
-
*
|
|
2201
|
-
* @promise GetLoopPromise
|
|
2202
|
-
* @fulfill {boolean} Whether or not the video is paused.
|
|
2203
|
-
*/
|
|
2204
|
-
/**
|
|
2205
|
-
* Get the paused state of the player.
|
|
2206
|
-
*
|
|
2207
|
-
* @return {GetLoopPromise}
|
|
2208
|
-
*/
|
|
2209
|
-
}, {
|
|
2210
|
-
key: "getPaused",
|
|
2211
|
-
value: function() {
|
|
2212
|
-
return this.get("paused");
|
|
2213
|
-
}
|
|
2214
|
-
/**
|
|
2215
|
-
* A promise to get the playback rate of the player.
|
|
2216
|
-
*
|
|
2217
|
-
* @promise GetPlaybackRatePromise
|
|
2218
|
-
* @fulfill {number} The playback rate of the player on a scale from 0 to 2.
|
|
2219
|
-
*/
|
|
2220
|
-
/**
|
|
2221
|
-
* Get the playback rate of the player on a scale from `0` to `2`.
|
|
2222
|
-
*
|
|
2223
|
-
* @return {GetPlaybackRatePromise}
|
|
2224
|
-
*/
|
|
2225
|
-
}, {
|
|
2226
|
-
key: "getPlaybackRate",
|
|
2227
|
-
value: function() {
|
|
2228
|
-
return this.get("playbackRate");
|
|
2229
|
-
}
|
|
2230
|
-
/**
|
|
2231
|
-
* A promise to set the playbackrate of the player.
|
|
2232
|
-
*
|
|
2233
|
-
* @promise SetPlaybackRatePromise
|
|
2234
|
-
* @fulfill {number} The playback rate was set.
|
|
2235
|
-
* @reject {RangeError} The playback rate was less than 0 or greater than 2.
|
|
2236
|
-
*/
|
|
2237
|
-
/**
|
|
2238
|
-
* Set the playback rate of the player on a scale from `0` to `2`. When set
|
|
2239
|
-
* via the API, the playback rate will not be synchronized to other
|
|
2240
|
-
* players or stored as the viewer's preference.
|
|
2241
|
-
*
|
|
2242
|
-
* @param {number} playbackRate
|
|
2243
|
-
* @return {SetPlaybackRatePromise}
|
|
2244
|
-
*/
|
|
2245
|
-
}, {
|
|
2246
|
-
key: "setPlaybackRate",
|
|
2247
|
-
value: function(t) {
|
|
2248
|
-
return this.set("playbackRate", t);
|
|
2249
|
-
}
|
|
2250
|
-
/**
|
|
2251
|
-
* A promise to get the played property of the video.
|
|
2252
|
-
*
|
|
2253
|
-
* @promise GetPlayedPromise
|
|
2254
|
-
* @fulfill {Array} Played Timeranges converted to an Array.
|
|
2255
|
-
*/
|
|
2256
|
-
/**
|
|
2257
|
-
* Get the played property of the video.
|
|
2258
|
-
*
|
|
2259
|
-
* @return {GetPlayedPromise}
|
|
2260
|
-
*/
|
|
2261
|
-
}, {
|
|
2262
|
-
key: "getPlayed",
|
|
2263
|
-
value: function() {
|
|
2264
|
-
return this.get("played");
|
|
2265
|
-
}
|
|
2266
|
-
/**
|
|
2267
|
-
* A promise to get the qualities available of the current video.
|
|
2268
|
-
*
|
|
2269
|
-
* @promise GetQualitiesPromise
|
|
2270
|
-
* @fulfill {Array} The qualities of the video.
|
|
2271
|
-
*/
|
|
2272
|
-
/**
|
|
2273
|
-
* Get the qualities of the current video.
|
|
2274
|
-
*
|
|
2275
|
-
* @return {GetQualitiesPromise}
|
|
2276
|
-
*/
|
|
2277
|
-
}, {
|
|
2278
|
-
key: "getQualities",
|
|
2279
|
-
value: function() {
|
|
2280
|
-
return this.get("qualities");
|
|
2281
|
-
}
|
|
2282
|
-
/**
|
|
2283
|
-
* A promise to get the current set quality of the video.
|
|
2284
|
-
*
|
|
2285
|
-
* @promise GetQualityPromise
|
|
2286
|
-
* @fulfill {string} The current set quality.
|
|
2287
|
-
*/
|
|
2288
|
-
/**
|
|
2289
|
-
* Get the current set quality of the video.
|
|
2290
|
-
*
|
|
2291
|
-
* @return {GetQualityPromise}
|
|
2292
|
-
*/
|
|
2293
|
-
}, {
|
|
2294
|
-
key: "getQuality",
|
|
2295
|
-
value: function() {
|
|
2296
|
-
return this.get("quality");
|
|
2297
|
-
}
|
|
2298
|
-
/**
|
|
2299
|
-
* A promise to set the video quality.
|
|
2300
|
-
*
|
|
2301
|
-
* @promise SetQualityPromise
|
|
2302
|
-
* @fulfill {number} The quality was set.
|
|
2303
|
-
* @reject {RangeError} The quality is not available.
|
|
2304
|
-
*/
|
|
2305
|
-
/**
|
|
2306
|
-
* Set a video quality.
|
|
2307
|
-
*
|
|
2308
|
-
* @param {string} quality
|
|
2309
|
-
* @return {SetQualityPromise}
|
|
2310
|
-
*/
|
|
2311
|
-
}, {
|
|
2312
|
-
key: "setQuality",
|
|
2313
|
-
value: function(t) {
|
|
2314
|
-
return this.set("quality", t);
|
|
2315
|
-
}
|
|
2316
|
-
/**
|
|
2317
|
-
* A promise to get the remote playback availability.
|
|
2318
|
-
*
|
|
2319
|
-
* @promise RemotePlaybackAvailabilityPromise
|
|
2320
|
-
* @fulfill {boolean} Whether remote playback is available.
|
|
2321
|
-
*/
|
|
2322
|
-
/**
|
|
2323
|
-
* Get the availability of remote playback.
|
|
2324
|
-
*
|
|
2325
|
-
* @return {RemotePlaybackAvailabilityPromise}
|
|
2326
|
-
*/
|
|
2327
|
-
}, {
|
|
2328
|
-
key: "getRemotePlaybackAvailability",
|
|
2329
|
-
value: function() {
|
|
2330
|
-
return this.get("remotePlaybackAvailability");
|
|
2331
|
-
}
|
|
2332
|
-
/**
|
|
2333
|
-
* A promise to get the current remote playback state.
|
|
2334
|
-
*
|
|
2335
|
-
* @promise RemotePlaybackStatePromise
|
|
2336
|
-
* @fulfill {string} The state of the remote playback: connecting, connected, or disconnected.
|
|
2337
|
-
*/
|
|
2338
|
-
/**
|
|
2339
|
-
* Get the current remote playback state.
|
|
2340
|
-
*
|
|
2341
|
-
* @return {RemotePlaybackStatePromise}
|
|
2342
|
-
*/
|
|
2343
|
-
}, {
|
|
2344
|
-
key: "getRemotePlaybackState",
|
|
2345
|
-
value: function() {
|
|
2346
|
-
return this.get("remotePlaybackState");
|
|
2347
|
-
}
|
|
2348
|
-
/**
|
|
2349
|
-
* A promise to get the seekable property of the video.
|
|
2350
|
-
*
|
|
2351
|
-
* @promise GetSeekablePromise
|
|
2352
|
-
* @fulfill {Array} Seekable Timeranges converted to an Array.
|
|
2353
|
-
*/
|
|
2354
|
-
/**
|
|
2355
|
-
* Get the seekable property of the video.
|
|
2356
|
-
*
|
|
2357
|
-
* @return {GetSeekablePromise}
|
|
2358
|
-
*/
|
|
2359
|
-
}, {
|
|
2360
|
-
key: "getSeekable",
|
|
2361
|
-
value: function() {
|
|
2362
|
-
return this.get("seekable");
|
|
2363
|
-
}
|
|
2364
|
-
/**
|
|
2365
|
-
* A promise to get the seeking property of the player.
|
|
2366
|
-
*
|
|
2367
|
-
* @promise GetSeekingPromise
|
|
2368
|
-
* @fulfill {boolean} Whether or not the player is currently seeking.
|
|
2369
|
-
*/
|
|
2370
|
-
/**
|
|
2371
|
-
* Get if the player is currently seeking.
|
|
2372
|
-
*
|
|
2373
|
-
* @return {GetSeekingPromise}
|
|
2374
|
-
*/
|
|
2375
|
-
}, {
|
|
2376
|
-
key: "getSeeking",
|
|
2377
|
-
value: function() {
|
|
2378
|
-
return this.get("seeking");
|
|
2379
|
-
}
|
|
2380
|
-
/**
|
|
2381
|
-
* A promise to get the text tracks of a video.
|
|
2382
|
-
*
|
|
2383
|
-
* @promise GetTextTracksPromise
|
|
2384
|
-
* @fulfill {VimeoTextTrack[]} The text tracks associated with the video.
|
|
2385
|
-
*/
|
|
2386
|
-
/**
|
|
2387
|
-
* Get an array of the text tracks that exist for the video.
|
|
2388
|
-
*
|
|
2389
|
-
* @return {GetTextTracksPromise}
|
|
2390
|
-
*/
|
|
2391
|
-
}, {
|
|
2392
|
-
key: "getTextTracks",
|
|
2393
|
-
value: function() {
|
|
2394
|
-
return this.get("textTracks");
|
|
2395
|
-
}
|
|
2396
|
-
/**
|
|
2397
|
-
* A promise to get the embed code for the video.
|
|
2398
|
-
*
|
|
2399
|
-
* @promise GetVideoEmbedCodePromise
|
|
2400
|
-
* @fulfill {string} The `<iframe>` embed code for the video.
|
|
2401
|
-
*/
|
|
2402
|
-
/**
|
|
2403
|
-
* Get the `<iframe>` embed code for the video.
|
|
2404
|
-
*
|
|
2405
|
-
* @return {GetVideoEmbedCodePromise}
|
|
2406
|
-
*/
|
|
2407
|
-
}, {
|
|
2408
|
-
key: "getVideoEmbedCode",
|
|
2409
|
-
value: function() {
|
|
2410
|
-
return this.get("videoEmbedCode");
|
|
2411
|
-
}
|
|
2412
|
-
/**
|
|
2413
|
-
* A promise to get the id of the video.
|
|
2414
|
-
*
|
|
2415
|
-
* @promise GetVideoIdPromise
|
|
2416
|
-
* @fulfill {number} The id of the video.
|
|
2417
|
-
*/
|
|
2418
|
-
/**
|
|
2419
|
-
* Get the id of the video.
|
|
2420
|
-
*
|
|
2421
|
-
* @return {GetVideoIdPromise}
|
|
2422
|
-
*/
|
|
2423
|
-
}, {
|
|
2424
|
-
key: "getVideoId",
|
|
2425
|
-
value: function() {
|
|
2426
|
-
return this.get("videoId");
|
|
2427
|
-
}
|
|
2428
|
-
/**
|
|
2429
|
-
* A promise to get the title of the video.
|
|
2430
|
-
*
|
|
2431
|
-
* @promise GetVideoTitlePromise
|
|
2432
|
-
* @fulfill {number} The title of the video.
|
|
2433
|
-
*/
|
|
2434
|
-
/**
|
|
2435
|
-
* Get the title of the video.
|
|
2436
|
-
*
|
|
2437
|
-
* @return {GetVideoTitlePromise}
|
|
2438
|
-
*/
|
|
2439
|
-
}, {
|
|
2440
|
-
key: "getVideoTitle",
|
|
2441
|
-
value: function() {
|
|
2442
|
-
return this.get("videoTitle");
|
|
2443
|
-
}
|
|
2444
|
-
/**
|
|
2445
|
-
* A promise to get the native width of the video.
|
|
2446
|
-
*
|
|
2447
|
-
* @promise GetVideoWidthPromise
|
|
2448
|
-
* @fulfill {number} The native width of the video.
|
|
2449
|
-
*/
|
|
2450
|
-
/**
|
|
2451
|
-
* Get the native width of the currently‐playing video. The width of
|
|
2452
|
-
* the highest‐resolution available will be used before playback begins.
|
|
2453
|
-
*
|
|
2454
|
-
* @return {GetVideoWidthPromise}
|
|
2455
|
-
*/
|
|
2456
|
-
}, {
|
|
2457
|
-
key: "getVideoWidth",
|
|
2458
|
-
value: function() {
|
|
2459
|
-
return this.get("videoWidth");
|
|
2460
|
-
}
|
|
2461
|
-
/**
|
|
2462
|
-
* A promise to get the native height of the video.
|
|
2463
|
-
*
|
|
2464
|
-
* @promise GetVideoHeightPromise
|
|
2465
|
-
* @fulfill {number} The native height of the video.
|
|
2466
|
-
*/
|
|
2467
|
-
/**
|
|
2468
|
-
* Get the native height of the currently‐playing video. The height of
|
|
2469
|
-
* the highest‐resolution available will be used before playback begins.
|
|
2470
|
-
*
|
|
2471
|
-
* @return {GetVideoHeightPromise}
|
|
2472
|
-
*/
|
|
2473
|
-
}, {
|
|
2474
|
-
key: "getVideoHeight",
|
|
2475
|
-
value: function() {
|
|
2476
|
-
return this.get("videoHeight");
|
|
2477
|
-
}
|
|
2478
|
-
/**
|
|
2479
|
-
* A promise to get the vimeo.com url for the video.
|
|
2480
|
-
*
|
|
2481
|
-
* @promise GetVideoUrlPromise
|
|
2482
|
-
* @fulfill {number} The vimeo.com url for the video.
|
|
2483
|
-
* @reject {PrivacyError} The url isn’t available because of the video’s privacy setting.
|
|
2484
|
-
*/
|
|
2485
|
-
/**
|
|
2486
|
-
* Get the vimeo.com url for the video.
|
|
2487
|
-
*
|
|
2488
|
-
* @return {GetVideoUrlPromise}
|
|
2489
|
-
*/
|
|
2490
|
-
}, {
|
|
2491
|
-
key: "getVideoUrl",
|
|
2492
|
-
value: function() {
|
|
2493
|
-
return this.get("videoUrl");
|
|
2494
|
-
}
|
|
2495
|
-
/**
|
|
2496
|
-
* A promise to get the volume level of the player.
|
|
2497
|
-
*
|
|
2498
|
-
* @promise GetVolumePromise
|
|
2499
|
-
* @fulfill {number} The volume level of the player on a scale from 0 to 1.
|
|
2500
|
-
*/
|
|
2501
|
-
/**
|
|
2502
|
-
* Get the current volume level of the player on a scale from `0` to `1`.
|
|
2503
|
-
*
|
|
2504
|
-
* Most mobile devices do not support an independent volume from the
|
|
2505
|
-
* system volume. In those cases, this method will always return `1`.
|
|
2506
|
-
*
|
|
2507
|
-
* @return {GetVolumePromise}
|
|
2508
|
-
*/
|
|
2509
|
-
}, {
|
|
2510
|
-
key: "getVolume",
|
|
2511
|
-
value: function() {
|
|
2512
|
-
return this.get("volume");
|
|
2513
|
-
}
|
|
2514
|
-
/**
|
|
2515
|
-
* A promise to set the volume level of the player.
|
|
2516
|
-
*
|
|
2517
|
-
* @promise SetVolumePromise
|
|
2518
|
-
* @fulfill {number} The volume was set.
|
|
2519
|
-
* @reject {RangeError} The volume was less than 0 or greater than 1.
|
|
2520
|
-
*/
|
|
2521
|
-
/**
|
|
2522
|
-
* Set the volume of the player on a scale from `0` to `1`. When set
|
|
2523
|
-
* via the API, the volume level will not be synchronized to other
|
|
2524
|
-
* players or stored as the viewer’s preference.
|
|
2525
|
-
*
|
|
2526
|
-
* Most mobile devices do not support setting the volume. An error will
|
|
2527
|
-
* *not* be triggered in that situation.
|
|
2528
|
-
*
|
|
2529
|
-
* @param {number} volume
|
|
2530
|
-
* @return {SetVolumePromise}
|
|
2531
|
-
*/
|
|
2532
|
-
}, {
|
|
2533
|
-
key: "setVolume",
|
|
2534
|
-
value: function(t) {
|
|
2535
|
-
return this.set("volume", t);
|
|
2536
|
-
}
|
|
2537
|
-
/** @typedef {import('./lib/timing-object.types').TimingObject} TimingObject */
|
|
2538
|
-
/** @typedef {import('./lib/timing-src-connector.types').TimingSrcConnectorOptions} TimingSrcConnectorOptions */
|
|
2539
|
-
/** @typedef {import('./lib/timing-src-connector').TimingSrcConnector} TimingSrcConnector */
|
|
2540
|
-
/**
|
|
2541
|
-
* Connects a TimingObject to the video player (https://webtiming.github.io/timingobject/)
|
|
2542
|
-
*
|
|
2543
|
-
* @param {TimingObject} timingObject
|
|
2544
|
-
* @param {TimingSrcConnectorOptions} options
|
|
2545
|
-
*
|
|
2546
|
-
* @return {Promise<TimingSrcConnector>}
|
|
2547
|
-
*/
|
|
2548
|
-
}, {
|
|
2549
|
-
key: "setTimingSrc",
|
|
2550
|
-
value: (function() {
|
|
2551
|
-
var e = W(/* @__PURE__ */ R().mark(function n(i, a) {
|
|
2552
|
-
var u = this, s;
|
|
2553
|
-
return R().wrap(function(o) {
|
|
2554
|
-
for (; ; ) switch (o.prev = o.next) {
|
|
2555
|
-
case 0:
|
|
2556
|
-
if (i) {
|
|
2557
|
-
o.next = 2;
|
|
2558
|
-
break;
|
|
2559
|
-
}
|
|
2560
|
-
throw new TypeError("A Timing Object must be provided.");
|
|
2561
|
-
case 2:
|
|
2562
|
-
return o.next = 4, this.ready();
|
|
2563
|
-
case 4:
|
|
2564
|
-
return s = new tt(this, i, a), x(this, "notifyTimingObjectConnect"), s.addEventListener("disconnect", function() {
|
|
2565
|
-
return x(u, "notifyTimingObjectDisconnect");
|
|
2566
|
-
}), o.abrupt("return", s);
|
|
2567
|
-
case 8:
|
|
2568
|
-
case "end":
|
|
2569
|
-
return o.stop();
|
|
2570
|
-
}
|
|
2571
|
-
}, n, this);
|
|
2572
|
-
}));
|
|
2573
|
-
function t(n, i) {
|
|
2574
|
-
return e.apply(this, arguments);
|
|
2575
|
-
}
|
|
2576
|
-
return t;
|
|
2577
|
-
})()
|
|
2578
|
-
}]), r;
|
|
2579
|
-
})();
|
|
2580
|
-
Me || (L = Ze(), Ye(), Je(), Xe(), Ke());
|
|
2581
|
-
const rt = "https://player.vimeo.com/video", nt = "https://vimeo.com/event", it = /vimeo\.com\/(video\/|event\/)?(\d+)(?:\/([\w-]+))?/;
|
|
2582
|
-
function ve(r, e = {}) {
|
|
2583
|
-
const t = {
|
|
2584
|
-
src: at(r, e),
|
|
2585
|
-
frameborder: 0,
|
|
2586
|
-
width: "100%",
|
|
2587
|
-
height: "100%",
|
|
2588
|
-
allow: "accelerometer; fullscreen; autoplay; encrypted-media; gyroscope; picture-in-picture"
|
|
2589
|
-
};
|
|
2590
|
-
return e.config && (t["data-config"] = JSON.stringify(e.config)), /*html*/
|
|
2591
|
-
`
|
|
2592
|
-
<style>
|
|
2593
|
-
:host {
|
|
2594
|
-
display: inline-block;
|
|
2595
|
-
min-width: 300px;
|
|
2596
|
-
min-height: 150px;
|
|
2597
|
-
position: relative;
|
|
2598
|
-
}
|
|
2599
|
-
iframe {
|
|
2600
|
-
position: absolute;
|
|
2601
|
-
top: 0;
|
|
2602
|
-
left: 0;
|
|
2603
|
-
}
|
|
2604
|
-
:host(:not([controls])) {
|
|
2605
|
-
pointer-events: none;
|
|
2606
|
-
}
|
|
2607
|
-
</style>
|
|
2608
|
-
<iframe${ot(t)}></iframe>
|
|
2609
|
-
`;
|
|
2610
|
-
}
|
|
2611
|
-
function at(r, e) {
|
|
2612
|
-
if (!r.src) return;
|
|
2613
|
-
let t = new URL(r.src);
|
|
2614
|
-
const n = r.src.match(it), i = n && n[1], a = n && n[2], u = t.searchParams.get("h") || void 0, s = {
|
|
2615
|
-
// ?controls=true is enabled by default in the iframe
|
|
2616
|
-
controls: r.controls === "" ? null : 0,
|
|
2617
|
-
autoplay: r.autoplay,
|
|
2618
|
-
loop: r.loop,
|
|
2619
|
-
muted: r.muted,
|
|
2620
|
-
playsinline: r.playsinline,
|
|
2621
|
-
preload: r.preload ?? "metadata",
|
|
2622
|
-
transparent: !1,
|
|
2623
|
-
autopause: r.autopause,
|
|
2624
|
-
h: u,
|
|
2625
|
-
// This param is required when the video is Unlisted.
|
|
2626
|
-
...e.config
|
|
2627
|
-
};
|
|
2628
|
-
return i === "event/" ? `${nt}/${a}/embed?${me(s)}` : `${rt}/${a}?${me(s)}`;
|
|
2629
|
-
}
|
|
2630
|
-
class Ae extends (globalThis.HTMLElement ?? class {
|
|
2631
|
-
}) {
|
|
2632
|
-
static getTemplateHTML = ve;
|
|
2633
|
-
static shadowRootOptions = { mode: "open" };
|
|
2634
|
-
static observedAttributes = [
|
|
2635
|
-
"autoplay",
|
|
2636
|
-
"controls",
|
|
2637
|
-
"crossorigin",
|
|
2638
|
-
"loop",
|
|
2639
|
-
"muted",
|
|
2640
|
-
"playsinline",
|
|
2641
|
-
"poster",
|
|
2642
|
-
"preload",
|
|
2643
|
-
"src"
|
|
2644
|
-
];
|
|
2645
|
-
loadComplete = new ge();
|
|
2646
|
-
#c;
|
|
2647
|
-
#f;
|
|
2648
|
-
#p;
|
|
2649
|
-
#t = 0;
|
|
2650
|
-
#r = NaN;
|
|
2651
|
-
#n = !1;
|
|
2652
|
-
#e = !this.autoplay;
|
|
2653
|
-
#o = 1;
|
|
2654
|
-
#u = 0;
|
|
2655
|
-
#i = 0;
|
|
2656
|
-
#s = !1;
|
|
2657
|
-
#a = 1;
|
|
2658
|
-
#h = NaN;
|
|
2659
|
-
#d = NaN;
|
|
2660
|
-
#l = null;
|
|
2661
|
-
constructor() {
|
|
2662
|
-
super(), this.#v("config");
|
|
2663
|
-
}
|
|
2664
|
-
requestFullscreen() {
|
|
2665
|
-
var e, t;
|
|
2666
|
-
return (t = (e = this.api) == null ? void 0 : e.requestFullscreen) == null ? void 0 : t.call(e);
|
|
2667
|
-
}
|
|
2668
|
-
exitFullscreen() {
|
|
2669
|
-
var e, t;
|
|
2670
|
-
return (t = (e = this.api) == null ? void 0 : e.exitFullscreen) == null ? void 0 : t.call(e);
|
|
2671
|
-
}
|
|
2672
|
-
requestPictureInPicture() {
|
|
2673
|
-
var e, t;
|
|
2674
|
-
return (t = (e = this.api) == null ? void 0 : e.requestPictureInPicture) == null ? void 0 : t.call(e);
|
|
2675
|
-
}
|
|
2676
|
-
exitPictureInPicture() {
|
|
2677
|
-
var e, t;
|
|
2678
|
-
return (t = (e = this.api) == null ? void 0 : e.exitPictureInPicture) == null ? void 0 : t.call(e);
|
|
2679
|
-
}
|
|
2680
|
-
get config() {
|
|
2681
|
-
return this.#l;
|
|
2682
|
-
}
|
|
2683
|
-
set config(e) {
|
|
2684
|
-
this.#l = e;
|
|
2685
|
-
}
|
|
2686
|
-
async load() {
|
|
2687
|
-
var e;
|
|
2688
|
-
if (this.#c) return;
|
|
2689
|
-
const t = !this.#f;
|
|
2690
|
-
this.#f && (this.loadComplete = new ge()), this.#f = !0, await (this.#c = Promise.resolve()), this.#c = null, this.#t = 0, this.#r = NaN, this.#n = !1, this.#e = !this.autoplay, this.#o = 1, this.#u = 0, this.#i = 0, this.#s = !1, this.#a = 1, this.#i = 0, this.#h = NaN, this.#d = NaN, this.dispatchEvent(new Event("emptied"));
|
|
2691
|
-
let n = this.api;
|
|
2692
|
-
if (this.api = null, !this.src)
|
|
2693
|
-
return;
|
|
2694
|
-
this.dispatchEvent(new Event("loadstart"));
|
|
2695
|
-
const i = {
|
|
2696
|
-
autoplay: this.autoplay,
|
|
2697
|
-
controls: this.controls,
|
|
2698
|
-
loop: this.loop,
|
|
2699
|
-
muted: this.defaultMuted,
|
|
2700
|
-
playsinline: this.playsInline,
|
|
2701
|
-
preload: this.preload ?? "metadata",
|
|
2702
|
-
transparent: !1,
|
|
2703
|
-
autopause: this.hasAttribute("autopause"),
|
|
2704
|
-
...this.#l
|
|
2705
|
-
}, a = async () => {
|
|
2706
|
-
this.#i = 1, this.dispatchEvent(new Event("loadedmetadata")), this.api && (this.#n = await this.api.getMuted(), this.#a = await this.api.getVolume(), this.dispatchEvent(new Event("volumechange")), this.#r = await this.api.getDuration(), this.dispatchEvent(new Event("durationchange"))), this.dispatchEvent(new Event("loadcomplete")), this.loadComplete.resolve();
|
|
2707
|
-
};
|
|
2708
|
-
if (this.#p) {
|
|
2709
|
-
this.api = n, await this.api.loadVideo({
|
|
2710
|
-
...i,
|
|
2711
|
-
url: this.src
|
|
2712
|
-
}), await a(), await this.loadComplete;
|
|
2713
|
-
return;
|
|
2714
|
-
}
|
|
2715
|
-
this.#p = !0;
|
|
2716
|
-
let u = (e = this.shadowRoot) == null ? void 0 : e.querySelector("iframe");
|
|
2717
|
-
t && u && (this.#l = JSON.parse(u.getAttribute("data-config") || "{}")), this.shadowRoot || (this.attachShadow({ mode: "open" }), this.shadowRoot.innerHTML = ve(st(this.attributes), this), u = this.shadowRoot.querySelector("iframe")), this.api = new le(u);
|
|
2718
|
-
const s = document.createElement("video");
|
|
2719
|
-
this.textTracks = s.textTracks, this.api.getTextTracks().then((o) => {
|
|
2720
|
-
o.forEach((b) => {
|
|
2721
|
-
s.addTextTrack(b.kind, b.label, b.language);
|
|
2722
|
-
});
|
|
2723
|
-
}), this.textTracks.addEventListener("change", () => {
|
|
2724
|
-
const o = Array.from(this.textTracks).find((b) => b.mode === "showing");
|
|
2725
|
-
o ? this.api.enableTextTrack(o.language, o.kind) : this.api.disableTextTrack();
|
|
2726
|
-
});
|
|
2727
|
-
const h = () => {
|
|
2728
|
-
this.api.off("loaded", h), a();
|
|
2729
|
-
};
|
|
2730
|
-
this.api.on("loaded", h), this.api.on("bufferstart", () => {
|
|
2731
|
-
this.#e && (this.#e = !1, this.dispatchEvent(new Event("play"))), this.dispatchEvent(new Event("waiting"));
|
|
2732
|
-
}), this.api.on("play", () => {
|
|
2733
|
-
this.#e && (this.#e = !1, this.dispatchEvent(new Event("play")));
|
|
2734
|
-
}), this.api.on("playing", () => {
|
|
2735
|
-
this.#i = 3, this.#e = !1, this.dispatchEvent(new Event("playing"));
|
|
2736
|
-
}), this.api.on("seeking", () => {
|
|
2737
|
-
this.#s = !0, this.dispatchEvent(new Event("seeking"));
|
|
2738
|
-
}), this.api.on("seeked", () => {
|
|
2739
|
-
this.#s = !1, this.dispatchEvent(new Event("seeked"));
|
|
2740
|
-
}), this.api.on("pause", () => {
|
|
2741
|
-
this.#e = !0, this.dispatchEvent(new Event("pause"));
|
|
2742
|
-
}), this.api.on("ended", () => {
|
|
2743
|
-
this.#e = !0, this.dispatchEvent(new Event("ended"));
|
|
2744
|
-
}), this.api.on("ratechange", ({ playbackRate: o }) => {
|
|
2745
|
-
this.#o = o, this.dispatchEvent(new Event("ratechange"));
|
|
2746
|
-
}), this.api.on("volumechange", async ({ volume: o }) => {
|
|
2747
|
-
this.#a = o, this.api && (this.#n = await this.api.getMuted()), this.dispatchEvent(new Event("volumechange"));
|
|
2748
|
-
}), this.api.on("durationchange", ({ duration: o }) => {
|
|
2749
|
-
this.#r = o, this.dispatchEvent(new Event("durationchange"));
|
|
2750
|
-
}), this.api.on("timeupdate", ({ seconds: o }) => {
|
|
2751
|
-
this.#t = o, this.dispatchEvent(new Event("timeupdate"));
|
|
2752
|
-
}), this.api.on("progress", ({ seconds: o }) => {
|
|
2753
|
-
this.#u = o, this.dispatchEvent(new Event("progress"));
|
|
2754
|
-
}), this.api.on("resize", ({ videoWidth: o, videoHeight: b }) => {
|
|
2755
|
-
this.#h = o, this.#d = b, this.dispatchEvent(new Event("resize"));
|
|
2756
|
-
}), await this.loadComplete;
|
|
2757
|
-
}
|
|
2758
|
-
async attributeChangedCallback(e, t, n) {
|
|
2759
|
-
if (t !== n) {
|
|
2760
|
-
switch (e) {
|
|
2761
|
-
case "autoplay":
|
|
2762
|
-
case "controls":
|
|
2763
|
-
case "src": {
|
|
2764
|
-
this.load();
|
|
2765
|
-
return;
|
|
2766
|
-
}
|
|
2767
|
-
}
|
|
2768
|
-
await this.loadComplete, e === "loop" && this.api.setLoop(this.loop);
|
|
2769
|
-
}
|
|
2770
|
-
}
|
|
2771
|
-
async play() {
|
|
2772
|
-
var e;
|
|
2773
|
-
this.#e = !1, this.dispatchEvent(new Event("play")), await this.loadComplete;
|
|
2774
|
-
try {
|
|
2775
|
-
await ((e = this.api) == null ? void 0 : e.play());
|
|
2776
|
-
} catch (t) {
|
|
2777
|
-
throw this.#e = !0, this.dispatchEvent(new Event("pause")), t;
|
|
2778
|
-
}
|
|
2779
|
-
}
|
|
2780
|
-
async pause() {
|
|
2781
|
-
var e;
|
|
2782
|
-
return await this.loadComplete, (e = this.api) == null ? void 0 : e.pause();
|
|
2783
|
-
}
|
|
2784
|
-
get ended() {
|
|
2785
|
-
return this.#t >= this.#r;
|
|
2786
|
-
}
|
|
2787
|
-
get seeking() {
|
|
2788
|
-
return this.#s;
|
|
2789
|
-
}
|
|
2790
|
-
get readyState() {
|
|
2791
|
-
return this.#i;
|
|
2792
|
-
}
|
|
2793
|
-
get videoWidth() {
|
|
2794
|
-
return this.#h;
|
|
2795
|
-
}
|
|
2796
|
-
get videoHeight() {
|
|
2797
|
-
return this.#d;
|
|
2798
|
-
}
|
|
2799
|
-
get src() {
|
|
2800
|
-
return this.getAttribute("src");
|
|
2801
|
-
}
|
|
2802
|
-
set src(e) {
|
|
2803
|
-
this.src != e && this.setAttribute("src", e);
|
|
2804
|
-
}
|
|
2805
|
-
get paused() {
|
|
2806
|
-
return this.#e;
|
|
2807
|
-
}
|
|
2808
|
-
get duration() {
|
|
2809
|
-
return this.#r;
|
|
2810
|
-
}
|
|
2811
|
-
get autoplay() {
|
|
2812
|
-
return this.hasAttribute("autoplay");
|
|
2813
|
-
}
|
|
2814
|
-
set autoplay(e) {
|
|
2815
|
-
this.autoplay != e && this.toggleAttribute("autoplay", !!e);
|
|
2816
|
-
}
|
|
2817
|
-
get buffered() {
|
|
2818
|
-
return this.#u > 0 ? ye(0, this.#u) : ye();
|
|
2819
|
-
}
|
|
2820
|
-
get controls() {
|
|
2821
|
-
return this.hasAttribute("controls");
|
|
2822
|
-
}
|
|
2823
|
-
set controls(e) {
|
|
2824
|
-
this.controls != e && this.toggleAttribute("controls", !!e);
|
|
2825
|
-
}
|
|
2826
|
-
get currentTime() {
|
|
2827
|
-
return this.#t;
|
|
2828
|
-
}
|
|
2829
|
-
set currentTime(e) {
|
|
2830
|
-
this.currentTime != e && (this.#t = e, this.loadComplete.then(() => {
|
|
2831
|
-
var t;
|
|
2832
|
-
(t = this.api) == null || t.setCurrentTime(e).catch(() => {
|
|
2833
|
-
});
|
|
2834
|
-
}));
|
|
2835
|
-
}
|
|
2836
|
-
get defaultMuted() {
|
|
2837
|
-
return this.hasAttribute("muted");
|
|
2838
|
-
}
|
|
2839
|
-
set defaultMuted(e) {
|
|
2840
|
-
this.defaultMuted != e && this.toggleAttribute("muted", !!e);
|
|
2841
|
-
}
|
|
2842
|
-
get loop() {
|
|
2843
|
-
return this.hasAttribute("loop");
|
|
2844
|
-
}
|
|
2845
|
-
set loop(e) {
|
|
2846
|
-
this.loop != e && this.toggleAttribute("loop", !!e);
|
|
2847
|
-
}
|
|
2848
|
-
get muted() {
|
|
2849
|
-
return this.#n;
|
|
2850
|
-
}
|
|
2851
|
-
set muted(e) {
|
|
2852
|
-
this.muted != e && (this.#n = e, this.loadComplete.then(() => {
|
|
2853
|
-
var t;
|
|
2854
|
-
(t = this.api) == null || t.setMuted(e).catch(() => {
|
|
2855
|
-
});
|
|
2856
|
-
}));
|
|
2857
|
-
}
|
|
2858
|
-
get playbackRate() {
|
|
2859
|
-
return this.#o;
|
|
2860
|
-
}
|
|
2861
|
-
set playbackRate(e) {
|
|
2862
|
-
this.playbackRate != e && (this.#o = e, this.loadComplete.then(() => {
|
|
2863
|
-
var t;
|
|
2864
|
-
(t = this.api) == null || t.setPlaybackRate(e).catch(() => {
|
|
2865
|
-
});
|
|
2866
|
-
}));
|
|
2867
|
-
}
|
|
2868
|
-
get playsInline() {
|
|
2869
|
-
return this.hasAttribute("playsinline");
|
|
2870
|
-
}
|
|
2871
|
-
set playsInline(e) {
|
|
2872
|
-
this.playsInline != e && this.toggleAttribute("playsinline", !!e);
|
|
2873
|
-
}
|
|
2874
|
-
get poster() {
|
|
2875
|
-
return this.getAttribute("poster");
|
|
2876
|
-
}
|
|
2877
|
-
set poster(e) {
|
|
2878
|
-
this.poster != e && this.setAttribute("poster", `${e}`);
|
|
2879
|
-
}
|
|
2880
|
-
get volume() {
|
|
2881
|
-
return this.#a;
|
|
2882
|
-
}
|
|
2883
|
-
set volume(e) {
|
|
2884
|
-
this.volume != e && (this.#a = e, this.loadComplete.then(() => {
|
|
2885
|
-
var t;
|
|
2886
|
-
(t = this.api) == null || t.setVolume(e).catch(() => {
|
|
2887
|
-
});
|
|
2888
|
-
}));
|
|
2889
|
-
}
|
|
2890
|
-
// This is a pattern to update property values that are set before
|
|
2891
|
-
// the custom element is upgraded.
|
|
2892
|
-
// https://web.dev/custom-elements-best-practices/#make-properties-lazy
|
|
2893
|
-
#v(e) {
|
|
2894
|
-
if (Object.prototype.hasOwnProperty.call(this, e)) {
|
|
2895
|
-
const t = this[e];
|
|
2896
|
-
delete this[e], this[e] = t;
|
|
2897
|
-
}
|
|
2898
|
-
}
|
|
2899
|
-
}
|
|
2900
|
-
function ot(r) {
|
|
2901
|
-
let e = "";
|
|
2902
|
-
for (const t in r) {
|
|
2903
|
-
const n = r[t];
|
|
2904
|
-
n === "" ? e += ` ${ae(t)}` : e += ` ${ae(t)}="${ae(`${n}`)}"`;
|
|
2905
|
-
}
|
|
2906
|
-
return e;
|
|
2907
|
-
}
|
|
2908
|
-
function ae(r) {
|
|
2909
|
-
return r.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'").replace(/`/g, "`");
|
|
2910
|
-
}
|
|
2911
|
-
function me(r) {
|
|
2912
|
-
return String(new URLSearchParams(ut(r)));
|
|
2913
|
-
}
|
|
2914
|
-
function ut(r) {
|
|
2915
|
-
let e = {};
|
|
2916
|
-
for (let t in r) {
|
|
2917
|
-
let n = r[t];
|
|
2918
|
-
n === !0 || n === "" ? e[t] = 1 : n === !1 ? e[t] = 0 : n != null && (e[t] = n);
|
|
2919
|
-
}
|
|
2920
|
-
return e;
|
|
2921
|
-
}
|
|
2922
|
-
function st(r) {
|
|
2923
|
-
let e = {};
|
|
2924
|
-
for (let t of r)
|
|
2925
|
-
e[t.name] = t.value;
|
|
2926
|
-
return e;
|
|
2927
|
-
}
|
|
2928
|
-
let ge = class extends Promise {
|
|
2929
|
-
constructor(e = () => {
|
|
2930
|
-
}) {
|
|
2931
|
-
let t, n;
|
|
2932
|
-
super((i, a) => {
|
|
2933
|
-
e(i, a), t = i, n = a;
|
|
2934
|
-
}), this.resolve = t, this.reject = n;
|
|
2935
|
-
}
|
|
2936
|
-
};
|
|
2937
|
-
function ye(r, e) {
|
|
2938
|
-
return Array.isArray(r) ? oe(r) : r == null || e == null || r === 0 && e === 0 ? oe([[0, 0]]) : oe([[r, e]]);
|
|
2939
|
-
}
|
|
2940
|
-
function oe(r) {
|
|
2941
|
-
return Object.defineProperties(r, {
|
|
2942
|
-
start: {
|
|
2943
|
-
value: (e) => r[e][0]
|
|
2944
|
-
},
|
|
2945
|
-
end: {
|
|
2946
|
-
value: (e) => r[e][1]
|
|
2947
|
-
}
|
|
2948
|
-
}), r;
|
|
2949
|
-
}
|
|
2950
|
-
globalThis.customElements && !globalThis.customElements.get("vimeo-video") && globalThis.customElements.define("vimeo-video", Ae);
|
|
2951
|
-
var lt = Ae, ct = /* @__PURE__ */ new Set([
|
|
2952
|
-
"style",
|
|
2953
|
-
"children",
|
|
2954
|
-
"ref",
|
|
2955
|
-
"key",
|
|
2956
|
-
"suppressContentEditableWarning",
|
|
2957
|
-
"suppressHydrationWarning",
|
|
2958
|
-
"dangerouslySetInnerHTML"
|
|
2959
|
-
]), ft = {
|
|
2960
|
-
className: "class",
|
|
2961
|
-
htmlFor: "for"
|
|
2962
|
-
};
|
|
2963
|
-
function Ne(r) {
|
|
2964
|
-
return r.toLowerCase();
|
|
2965
|
-
}
|
|
2966
|
-
function we(r) {
|
|
2967
|
-
if (typeof r == "boolean") return r ? "" : void 0;
|
|
2968
|
-
if (typeof r != "function" && !(typeof r == "object" && r !== null))
|
|
2969
|
-
return r;
|
|
2970
|
-
}
|
|
2971
|
-
function ht({
|
|
2972
|
-
react: r,
|
|
2973
|
-
tagName: e,
|
|
2974
|
-
elementClass: t,
|
|
2975
|
-
events: n,
|
|
2976
|
-
displayName: i,
|
|
2977
|
-
defaultProps: a,
|
|
2978
|
-
toAttributeName: u = Ne,
|
|
2979
|
-
toAttributeValue: s = we
|
|
2980
|
-
}) {
|
|
2981
|
-
const h = Number.parseInt(r.version) >= 19, o = r.forwardRef((b, k) => {
|
|
2982
|
-
var T, P;
|
|
2983
|
-
const g = r.useRef(null), _ = r.useRef(/* @__PURE__ */ new Map()), O = {}, N = {}, m = {}, p = {};
|
|
2984
|
-
for (const [f, v] of Object.entries(b)) {
|
|
2985
|
-
if (ct.has(f)) {
|
|
2986
|
-
m[f] = v;
|
|
2987
|
-
continue;
|
|
2988
|
-
}
|
|
2989
|
-
const E = u(ft[f] ?? f);
|
|
2990
|
-
if (t.prototype && f in t.prototype && !(f in (((T = globalThis.HTMLElement) == null ? void 0 : T.prototype) ?? {})) && !((P = t.observedAttributes) != null && P.some((y) => y === E))) {
|
|
2991
|
-
p[f] = v;
|
|
2992
|
-
continue;
|
|
2993
|
-
}
|
|
2994
|
-
if (f.startsWith("on")) {
|
|
2995
|
-
O[f] = v;
|
|
2996
|
-
continue;
|
|
2997
|
-
}
|
|
2998
|
-
const S = s(v);
|
|
2999
|
-
if (E && S != null && (N[E] = String(S), h || (m[E] = S)), E && h) {
|
|
3000
|
-
const y = we(v);
|
|
3001
|
-
S !== y ? m[E] = S : m[E] = v;
|
|
3002
|
-
}
|
|
3003
|
-
}
|
|
3004
|
-
if (typeof window < "u") {
|
|
3005
|
-
for (const f in O) {
|
|
3006
|
-
const v = O[f], E = f.endsWith("Capture"), S = (n?.[f] ?? f.slice(2).toLowerCase()).slice(
|
|
3007
|
-
0,
|
|
3008
|
-
E ? -7 : void 0
|
|
3009
|
-
);
|
|
3010
|
-
r.useLayoutEffect(() => {
|
|
3011
|
-
const y = g?.current;
|
|
3012
|
-
if (!(!y || typeof v != "function"))
|
|
3013
|
-
return y.addEventListener(S, v, E), () => {
|
|
3014
|
-
y.removeEventListener(S, v, E);
|
|
3015
|
-
};
|
|
3016
|
-
}, [g?.current, v]);
|
|
3017
|
-
}
|
|
3018
|
-
r.useLayoutEffect(() => {
|
|
3019
|
-
if (g.current === null) return;
|
|
3020
|
-
const f = /* @__PURE__ */ new Map();
|
|
3021
|
-
for (const v in p)
|
|
3022
|
-
be(g.current, v, p[v]), _.current.delete(v), f.set(v, p[v]);
|
|
3023
|
-
for (const [v, E] of _.current)
|
|
3024
|
-
be(g.current, v, void 0);
|
|
3025
|
-
_.current = f;
|
|
3026
|
-
});
|
|
3027
|
-
}
|
|
3028
|
-
if (typeof window > "u" && t?.getTemplateHTML && t?.shadowRootOptions) {
|
|
3029
|
-
const { mode: f, delegatesFocus: v } = t.shadowRootOptions, E = r.createElement("template", {
|
|
3030
|
-
shadowrootmode: f,
|
|
3031
|
-
shadowrootdelegatesfocus: v,
|
|
3032
|
-
dangerouslySetInnerHTML: {
|
|
3033
|
-
__html: t.getTemplateHTML(N, b)
|
|
3034
|
-
},
|
|
3035
|
-
key: "ce-la-react-ssr-template-shadow-root"
|
|
3036
|
-
});
|
|
3037
|
-
m.children = [E, m.children];
|
|
3038
|
-
}
|
|
3039
|
-
return r.createElement(e, {
|
|
3040
|
-
...a,
|
|
3041
|
-
...m,
|
|
3042
|
-
ref: r.useCallback(
|
|
3043
|
-
(f) => {
|
|
3044
|
-
g.current = f, typeof k == "function" ? k(f) : k !== null && (k.current = f);
|
|
3045
|
-
},
|
|
3046
|
-
[k]
|
|
3047
|
-
)
|
|
3048
|
-
}, m.children);
|
|
3049
|
-
});
|
|
3050
|
-
return o.displayName = i ?? t.name, o;
|
|
3051
|
-
}
|
|
3052
|
-
function be(r, e, t) {
|
|
3053
|
-
var n;
|
|
3054
|
-
r[e] = t, t == null && e in (((n = globalThis.HTMLElement) == null ? void 0 : n.prototype) ?? {}) && r.removeAttribute(e);
|
|
3055
|
-
}
|
|
3056
|
-
var vt = ht({
|
|
3057
|
-
react: Re,
|
|
3058
|
-
tagName: "vimeo-video",
|
|
3059
|
-
elementClass: lt,
|
|
3060
|
-
toAttributeName(r) {
|
|
3061
|
-
return r === "muted" ? "" : r === "defaultMuted" ? "muted" : Ne(r);
|
|
3062
|
-
}
|
|
3063
|
-
});
|
|
3064
|
-
export {
|
|
3065
|
-
vt as default
|
|
3066
|
-
};
|
|
3067
|
-
//# sourceMappingURL=react-b5Gp0-6S.js.map
|