aboutsummaryrefslogtreecommitdiffstats
path: root/src/js/plugins/vimeo.js
diff options
context:
space:
mode:
authorSam Potts <me@sampotts.me>2017-11-05 11:45:02 +1100
committerSam Potts <me@sampotts.me>2017-11-05 11:45:02 +1100
commit1c693df00b44961674a35243f5172716a3735b71 (patch)
tree2df8dd8d252d1f80688cd3a3549de7374dca676c /src/js/plugins/vimeo.js
parent8aaa9320505baec3575bc1e92f37225729ee88f6 (diff)
downloadplyr-1c693df00b44961674a35243f5172716a3735b71.tar.lz
plyr-1c693df00b44961674a35243f5172716a3735b71.tar.xz
plyr-1c693df00b44961674a35243f5172716a3735b71.zip
src getter fix, local storage fix
Diffstat (limited to 'src/js/plugins/vimeo.js')
-rw-r--r--src/js/plugins/vimeo.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/js/plugins/vimeo.js b/src/js/plugins/vimeo.js
index f75b16aa..b9cc92c2 100644
--- a/src/js/plugins/vimeo.js
+++ b/src/js/plugins/vimeo.js
@@ -126,6 +126,19 @@ const vimeo = {
},
});
+ // Source
+ let currentSrc;
+
+ player.embed.getVideoUrl.then(value => {
+ currentSrc = value;
+ });
+
+ Object.defineProperty(player.media, 'currentSrc', {
+ get() {
+ return currentSrc;
+ },
+ });
+
// Rebuild UI
window.setTimeout(() => ui.build.call(player), 0);