Skip to content

Commit

Permalink
Chore(umd): Add umd build of latest
Browse files Browse the repository at this point in the history
  • Loading branch information
Berkeley Martinez authored and Berkeley Martinez committed Sep 2, 2016
1 parent 13b6adc commit 3835adf
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
16 changes: 11 additions & 5 deletions lib/umd/ReactVimeo.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* React-Vimeo - React component to load video from Vimeo
* @version v0.2.0
* @version v0.2.1
* @link https://github.com/freecodecamp/react-vimeo
* @license MIT
* @author Berkeley Martinez (https://github.com/berkeleytrue)
Expand Down Expand Up @@ -221,7 +221,7 @@ return /******/ (function(modules) { // webpackBootstrap
data = JSON.parse(data);
} catch (err) {
debug('error parsing message', err);
dats = { event: '' };
data = { event: '' };
}
}

Expand Down Expand Up @@ -250,7 +250,10 @@ return /******/ (function(modules) { // webpackBootstrap
this.setState({ showingVideo: true });
},
getIframeUrl: function getIframeUrl() {
return '//player.vimeo.com/video/' + this.props.videoId + '?' + this.getIframeUrlQuery();
var videoId = this.props.videoId;

var query = this.getIframeUrlQuery();
return '//player.vimeo.com/video/' + videoId + '?' + query;
},
getIframeUrlQuery: function getIframeUrlQuery() {
var _this2 = this;
Expand All @@ -259,7 +262,8 @@ return /******/ (function(modules) { // webpackBootstrap
Object.keys(this.props.playerOptions).forEach(function (key) {
str.push(key + '=' + _this2.props.playerOptions[key]);
});
return str.join("&");

return str.join('&');
},
fetchVimeoData: function fetchVimeoData() {
var _this3 = this;
Expand Down Expand Up @@ -295,12 +299,14 @@ return /******/ (function(modules) { // webpackBootstrap
width: '100%'
};

var playButton = this.props.playButton ? (0, _react.cloneElement)(this.props.playButton, { onClick: this.playVideo }) : _react2.default.createElement(_PlayButton2.default, { onClick: this.playVideo });

return _react2.default.createElement(
'div',
{
className: 'vimeo-image',
style: style },
_react2.default.createElement(_PlayButton2.default, { onClick: this.playVideo })
playButton
);
},
renderIframe: function renderIframe() {
Expand Down
Loading

0 comments on commit 3835adf

Please sign in to comment.