Skip to content

Commit

Permalink
add version of react package v0.12.2
Browse files Browse the repository at this point in the history
  • Loading branch information
pedronauck committed Jan 30, 2015
1 parent fe6039b commit 102b938
Show file tree
Hide file tree
Showing 11 changed files with 27 additions and 27 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Installing this component is very easy and it has just one dependency: [React](h
$ bower install --save react-video
```

- Or if you want to [download the lastest release](https://github.com/pedronauck/react-video/archive/v1.3.0.zip) and put in your website, it will work too!
- Or if you want to [download the lastest release](https://github.com/pedronauck/react-video/archive/v1.4.0.zip) and put in your website, it will work too!

**NOTICE:** You need just one thing to make the component work. Put the [base component style](./dist/react-video.css) at the `<header>` tag. If you don't wanna use the `.css` extension, you can get the `.styl` or `.scss` extension at the folder `./lib`.

Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-video",
"version": "1.3.0",
"version": "1.4.0",
"description": "React component to load video from Vimeo or Youtube across any device",
"homepage": "https://github.com/pedronauck/react-video",
"authors": [
Expand Down
2 changes: 1 addition & 1 deletion dist/react-video.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* React Video - React component to load video from Vimeo or Youtube across any device
* @version v1.3.0
* @version v1.4.0
* @link https://github.com/pedronauck/react-video
* @license MIT
* @author Pedro Nauck (https://github.com/pedronauck)
Expand Down
6 changes: 3 additions & 3 deletions dist/react-video.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* React Video - React component to load video from Vimeo or Youtube across any device
* @version v1.3.0
* @version v1.4.0
* @link https://github.com/pedronauck/react-video
* @license MIT
* @author Pedro Nauck (https://github.com/pedronauck)
Expand Down Expand Up @@ -87,10 +87,10 @@ return /******/ (function(modules) { // webpackBootstrap
};
},
isYoutube:function() {
return this.props.from === 'youtube' || isNaN(this.props.id);
return this.props.from === 'youtube' || isNaN(this.props.videoId);
},
isVimeo:function() {
return this.props.from === 'vimeo' || !isNaN(this.props.id);
return this.props.from === 'vimeo' || !isNaN(this.props.videoId);
},
componentDidMount:function() {
this.isYoutube() && this.fetchYoutubeData();
Expand Down
2 changes: 1 addition & 1 deletion dist/react-video.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions dist/react-video.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<h1 class="title">React Video</h1>
<ul class="github-buttons">
<li>
<a href="https://github.com/pedronauck/react-video/archive/v1.3.0.zip">Download v1.3.0</a>
<a href="https://github.com/pedronauck/react-video/archive/v1.4.0.zip">Download v1.4.0</a>
</li>
<li>
<a href="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/pedronauck/react-video">
Expand Down Expand Up @@ -113,8 +113,8 @@ <h2 class="section-title">Usage</h2>
Made with ❤︎ by <a href="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/pedronauck">Pedro Nauck</a>
</footer>

<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.11.2/react-with-addons.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.11.2/JSXTransformer.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.12.2/react-with-addons.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.12.2/JSXTransformer.js"></script>
<script src="js/react-video.min.js"></script>
<script src="js/highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
Expand Down
6 changes: 3 additions & 3 deletions docs/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
var $vimeoBtn = document.querySelector('.cover-button-item[data-from="vimeo"]');
var mountNode = document.querySelector('#cover-video');

React.renderComponent(<Video from='youtube' videoId='gZD0ahZHgBM' />, mountNode);
React.render(<Video from='youtube' videoId='gZD0ahZHgBM' />, mountNode);

$youtubeBtn.addEventListener('click', function(ev) {
$youtubeBtn.classList.add('is-active');
$vimeoBtn.classList.remove('is-active');

React.unmountComponentAtNode(mountNode);
React.renderComponent(<Video from='youtube' videoId='gZD0ahZHgBM' />, mountNode);
React.render(<Video from='youtube' videoId='gZD0ahZHgBM' />, mountNode);
ev.preventDefault();
});

Expand All @@ -22,7 +22,7 @@
$youtubeBtn.classList.remove('is-active');

React.unmountComponentAtNode(mountNode);
React.renderComponent(<Video from='vimeo' videoId='63836620' />, mountNode);
React.render(<Video from='vimeo' videoId='63836620' />, mountNode);
ev.preventDefault();
});
})();
12 changes: 6 additions & 6 deletions example/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -32,20 +32,20 @@
<div id="video-vimeo"></div>
</div>

<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.11.2/react-with-addons.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.11.2/JSXTransformer.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.12.2/react-with-addons.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/react/0.12.2/JSXTransformer.js"></script>
<script src="react-video.js"></script>
<script type="text/jsx">
/** @jsx React.DOM */
var Video = ReactVideo;

React.renderComponent(
<Video from='youtube' videoId='jhg8XRTorYg' />,
React.render(
<Video videoId='jhg8XRTorYg' />,
document.getElementById('video-youtube')
);

React.renderComponent(
<Video from='vimeo' videoId='108843586' />,
React.render(
<Video videoId='108843586' />,
document.getElementById('video-vimeo')
);
</script>
Expand Down
4 changes: 2 additions & 2 deletions lib/react-video.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ module.exports = React.createClass({
};
},
isYoutube() {
return this.props.from === 'youtube' || isNaN(this.props.id);
return this.props.from === 'youtube' || isNaN(this.props.videoId);
},
isVimeo() {
return this.props.from === 'vimeo' || !isNaN(this.props.id);
return this.props.from === 'vimeo' || !isNaN(this.props.videoId);
},
componentDidMount() {
this.isYoutube() && this.fetchYoutubeData();
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-video",
"version": "1.3.0",
"version": "1.4.0",
"description": "React component to load video from Vimeo or Youtube across any device",
"author": {
"name": "Pedro Nauck",
Expand Down Expand Up @@ -47,7 +47,7 @@
]
},
"peerDependencies": {
"react": ">=0.11.0"
"react": ">=0.12.2"
},
"devDependencies": {
"browser-sync": "^1.5.2",
Expand All @@ -60,10 +60,10 @@
"gulp-stylus": "^1.3.3",
"gulp-util": "^3.0.1",
"jest-cli": "^0.1.18",
"jsx-loader": "^0.11.2",
"jsx-loader": "^0.12.2",
"lodash": "^2.4.1",
"nib": "^1.0.4",
"react-tools": "^0.11.2",
"react-tools": "^0.12.2",
"webpack": "^1.4.4",
"yargs": "^1.3.2"
}
Expand Down

0 comments on commit 102b938

Please sign in to comment.