Skip to content

Commit

Permalink
Merge pull request #13 from dongy7/sprint3/build
Browse files Browse the repository at this point in the history
Sprint3/build
  • Loading branch information
dongy7 authored Nov 7, 2016
2 parents 2d8bd1e + 574ba85 commit 8a82538
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 14 deletions.
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,13 @@ using [Electron](http://electron.atom.io/apps/) with

## Pre-requisites

We use the [Node](https://nodejs.org/en/) runtime and [npm](https://www.npmjs.com/)
to run Electron. You can find the latest release for Node [here](https://nodejs.org/en/download/).

For package management, we use the [Yarn](https://yarnpkg.com/) package manger.
```bash
npm install -g yarn
```

Install the dependencies:

Expand All @@ -21,7 +27,7 @@ yarn install
## Running

```bash
yarn run dev
npm run dev
```

This will start up the build server that bundles the application
Expand All @@ -38,7 +44,7 @@ electron application.
To lint run the following command:

```bash
yarn lint
npm lint
```

## Testing
Expand All @@ -48,5 +54,5 @@ The following command will run the test suite defined under the `test`
directory.

```bash
yarn test
npm test
```
6 changes: 3 additions & 3 deletions app/api/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const mockDatabase = {
date: '10/1/2016',
uploaded: false,
flagged: true,
uri: '../static/cam1.mp4',
uri: 'https://vimeo.com/190568226',
},
{
id: v4(),
Expand All @@ -18,7 +18,7 @@ const mockDatabase = {
date: '10/2/2016',
uploaded: true,
flagged: false,
uri: '../static/cam2.mp4',
uri: 'https://vimeo.com/190568227',
},
{
id: v4(),
Expand All @@ -27,7 +27,7 @@ const mockDatabase = {
date: '10/3/2016',
uploaded: false,
flagged: true,
uri: '../static/cam3.mp4',
uri: 'https://vimeo.com/190568228',
},
],
};
Expand Down
1 change: 0 additions & 1 deletion app/app.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
<head>
<meta charset="utf-8">
<title>360ls</title>
<link rel="stylesheet" href="../node_modules/font-awesome/css/font-awesome.min.css" />
<link rel="stylesheet" href="app.global.css" />
</head>
<body>
Expand Down
6 changes: 5 additions & 1 deletion app/components/Video.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import React, { PropTypes } from 'react';
import ReactPlayer from 'react-player';

const Video = ({ uri }) => (
<video controls autoPlay src={uri} width="100%" />
<ReactPlayer
url={uri}
width={'100%'}
/>
);

Video.propTypes = {
Expand Down
12 changes: 8 additions & 4 deletions app/components/VideoTable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@ import {
TableHeaderColumn,
TableRow,
TableRowColumn } from 'material-ui/Table';
import FontIcon from 'material-ui/FontIcon';
import Done from 'material-ui/svg-icons/action/done';
import Close from 'material-ui/svg-icons/navigation/close';
import Error from 'material-ui/svg-icons/alert/error';
import { red500, green500, yellow500 } from 'material-ui/styles/colors';

const rowHeader = [
'Name',
Expand All @@ -15,9 +18,10 @@ const rowHeader = [
'Upload Status',
'Flag',
];
const flagIcon = <FontIcon className="fa-flag" />;
const checkIcon = <FontIcon className="fa-check" />;
const closeIcon = <FontIcon className="fa-close" />;

const flagIcon = <Error color={yellow500} />;
const checkIcon = <Done color={green500} />;
const closeIcon = <Close color={red500} />;

const VideoTable = ({ videos, onClick, router, path }) => (
<Table
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"start": "cross-env NODE_ENV=production electron ./app/",
"start-hot": "cross-env HOT=1 NODE_ENV=development electron -r babel-register -r babel-polyfill ./app/main.development",
"postinstall": "concurrently \"install-app-deps\" \"node node_modules/fbjs-scripts/node/check-dev-engines.js package.json\"",
"dev": "npm run hot-server -- --start-hot",
"package": "npm run build && build --publish never",
"package-win": "npm run build && build --win --x64",
"package-linux": "npm run build && build --linux",
Expand Down Expand Up @@ -145,6 +144,7 @@
"normalizr": "^2.2.1",
"react": "^15.3.2",
"react-dom": "^15.3.2",
"react-player": "^0.12.0",
"react-redux": "^4.4.5",
"react-router": "^3.0.0",
"react-router-redux": "^4.0.6",
Expand Down
24 changes: 23 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2785,6 +2785,10 @@ es6-map@^0.1.3:
es6-symbol "~3.1.0"
event-emitter "~0.3.4"

es6-promise@^2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-2.3.0.tgz#96edb9f2fdb01995822b263dd8aadab6748181bc"

es6-promise@^3.2.1:
version "3.3.1"
resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-3.3.1.tgz#a08cdde84ccdbf34d027a1451bc91d4bcd28a613"
Expand Down Expand Up @@ -3215,6 +3219,12 @@ fd-slicer@~1.0.1:
dependencies:
pend "~1.2.0"

fetch-jsonp@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/fetch-jsonp/-/fetch-jsonp-1.0.2.tgz#70684888c3ec6323d0ff757b48f30587ef847647"
dependencies:
es6-promise "^2.3.0"

figures@^1.3.5:
version "1.7.0"
resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e"
Expand Down Expand Up @@ -4843,6 +4853,10 @@ load-json-file@^1.0.0, load-json-file@^1.1.0:
pinkie-promise "^2.0.0"
strip-bom "^2.0.0"

load-script@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/load-script/-/load-script-1.0.0.tgz#0491939e0bee5643ee494a7e3da3d2bac70c6ca4"

loader-utils@^0.2.11, loader-utils@^0.2.16, loader-utils@^0.2.3, loader-utils@^0.2.7, loader-utils@~0.2.2:
version "0.2.16"
resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-0.2.16.tgz#f08632066ed8282835dff88dfb52704765adee6d"
Expand Down Expand Up @@ -6478,7 +6492,7 @@ [email protected]:
version "6.2.0"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.2.0.tgz#3b7848c03c2dece69a9522b0fae8c4126d745f3b"

query-string@^4.1.0, query-string@^4.2.2:
query-string@^4.1.0, query-string@^4.2.2, query-string@^4.2.3:
version "4.2.3"
resolved "https://registry.yarnpkg.com/query-string/-/query-string-4.2.3.tgz#9f27273d207a25a8ee4c7b8c74dcd45d556db822"
dependencies:
Expand Down Expand Up @@ -6552,6 +6566,14 @@ react-event-listener@^0.4.0:
react-addons-shallow-compare "^0.14.0 || ^15.0.0"
warning "^3.0.0"

react-player:
version "0.12.0"
resolved "https://registry.yarnpkg.com/react-player/-/react-player-0.12.0.tgz#35a562c2db907f2a4ba3bf7f4dc1919af55660dc"
dependencies:
fetch-jsonp "^1.0.2"
load-script "^1.0.0"
query-string "^4.2.3"

react-proxy@^1.1.7:
version "1.1.8"
resolved "https://registry.yarnpkg.com/react-proxy/-/react-proxy-1.1.8.tgz#9dbfd9d927528c3aa9f444e4558c37830ab8c26a"
Expand Down

0 comments on commit 8a82538

Please sign in to comment.