diff --git a/dist/index.html b/dist/index.html
index 2fb646c71..4832a297f 100644
--- a/dist/index.html
+++ b/dist/index.html
@@ -27,6 +27,7 @@
+
diff --git a/js/.DS_Store b/js/.DS_Store
new file mode 100644
index 000000000..7b0ba57c7
Binary files /dev/null and b/js/.DS_Store differ
diff --git a/js/app.js b/js/app.js
index 7d35237b5..0d05fb9c7 100644
--- a/js/app.js
+++ b/js/app.js
@@ -5,15 +5,19 @@ var appStyles = {
};
var App = React.createClass({
getInitialState: function() {
- var query = window.location.search.slice(1);
- if (['settings', 'help', 'start'].indexOf(query) != -1) {
- var viewingPage = query;
+ // For now, routes are in format ?page or ?page=args
+ var match, param, val;
+ [match, param, val] = window.location.search.match(/\??([^=]*)(?:=(.*))?/);
+
+ if (['settings', 'help', 'start', 'watch'].indexOf(param) != -1) {
+ var viewingPage = param;
} else {
var viewingPage = 'home';
}
return {
- viewingPage: viewingPage
+ viewingPage: viewingPage,
+ pageArgs: val,
};
},
componentWillMount: function() {
@@ -54,6 +58,8 @@ var App = React.createClass({
var content = ;
} else if (this.state.viewingPage == 'help') {
var content = ;
+ } else if (this.state.viewingPage == 'watch') {
+ var content = ;
} else if (this.state.viewingPage == 'start') {
var content = ;
}
diff --git a/js/page/home.js b/js/page/home.js
index 092a5f32c..2a8877b8f 100644
--- a/js/page/home.js
+++ b/js/page/home.js
@@ -92,7 +92,7 @@ var SearchResultRow = React.createClass({
// No support for lbry:// URLs in Windows or on Chrome yet
if (/windows|win32/i.test(navigator.userAgent) || (window.chrome && window.navigator.vendor == "Google Inc.")) {
- var linkURI = "/view?name=" + this.props.name;
+ var linkURI = "/?watch=" + this.props.name;
} else {
var linkURI = displayURI;
}
diff --git a/js/page/watch.js b/js/page/watch.js
new file mode 100644
index 000000000..ea7d2c91a
--- /dev/null
+++ b/js/page/watch.js
@@ -0,0 +1,18 @@
+var videoStyle = {
+ width: '100%',
+ height: '100%',
+ backgroundColor: '#000'
+};
+
+var WatchPage = React.createClass({
+ propTypes: {
+ name: React.PropTypes.string,
+ },
+ render: function() {
+ return (
+
+
+
+ );
+ }
+});