-
Notifications
You must be signed in to change notification settings - Fork 58
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
210 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
node_modules |
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
var fs = require('fs') | ||
var terser = require("terser") | ||
var ccss = require('clean-css') | ||
|
||
var binPath = './bin/' | ||
var css = [] | ||
var js = [] | ||
css.push("./videojs.css") | ||
css.push("./player.css") | ||
js.push("./lib/lightrpc.min.js") | ||
js.push("./lib/swiftclick.min.js") | ||
js.push("./lib/playerjs.min.js") | ||
js.push("./javascripts/video.js") | ||
js.push("./lib/videojs-contrib-hls.min.js") | ||
js.push("./javascripts/jsoun.js") | ||
js.push("./javascripts/localstorage.js") | ||
js.push("./javascripts/branding.js") | ||
js.push("./javascripts/persistvolume.js") | ||
js.push("./javascripts/resolutionswitcher.js") | ||
js.push("./javascripts/ipfsgatewayswitcher.js") | ||
js.push("./javascripts/settingsmenubuttons.js") | ||
js.push("./javascripts/settingsmenuitem.js") | ||
js.push("./javascripts/hotkeys.js") | ||
js.push("./javascripts/thumbnails.js") | ||
js.push("./javascripts/player.js") | ||
js.push("./javascripts/statistics.js") | ||
js.push("./javascripts/graph.js") | ||
js.push("./javascripts/snap.js") | ||
|
||
var cssBundle = "" | ||
for (let i = 0; i < css.length; i++) { | ||
console.log('minifying '+css[i]) | ||
var code = fs.readFileSync(css[i],'utf8') | ||
var clean = new ccss({}).minify(code) | ||
for (let y = 0; y < clean.errors.length; y++) | ||
console.log('css error:', css[i], clean.errors[y]) | ||
for (let y = 0; y < clean.warnings.length; y++) | ||
console.log('css warn:', css[i], clean.warnings[y]) | ||
|
||
cssBundle += clean.styles+'\n' | ||
} | ||
fs.writeFileSync(binPath+'dtube.css', cssBundle) | ||
console.log('CSS minified in '+binPath+'dtube.css') | ||
|
||
var jsBundle = "" | ||
for (let i = 0; i < js.length; i++) { | ||
console.log('minifying '+js[i]) | ||
var code = fs.readFileSync(js[i],'utf8') | ||
var ugly = terser.minify(code) | ||
if (ugly.error) | ||
throw new Error(ugly.error) | ||
jsBundle += ugly.code+'\n' | ||
} | ||
fs.writeFileSync(binPath+'dtube.min.js', jsBundle) | ||
console.log('JS minified in '+binPath+'dtube.min.js') | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<html> | ||
<head> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
|
||
<link href="videojs.css" rel="stylesheet"> | ||
<link href="player.css" rel="stylesheet"> | ||
|
||
<script src="./lib/lightrpc.min.js"></script> | ||
<script src="./lib/swiftclick.min.js"></script> | ||
<script src="./lib/playerjs.min.js"></script> | ||
<script src="./javascripts/video.js"></script> | ||
<script src="./lib/videojs-contrib-hls.min.js"></script> | ||
<script src="./javascripts/jsoun.js"></script> | ||
<script src="./javascripts/localstorage.js"></script> | ||
<script src="./javascripts/branding.js"></script> | ||
<script src="./javascripts/persistvolume.js"></script> | ||
<script src="./javascripts/resolutionswitcher.js"></script> | ||
<script src="./javascripts/ipfsgatewayswitcher.js"></script> | ||
<script src="./javascripts/settingsmenubuttons.js"></script> | ||
<script src="./javascripts/settingsmenuitem.js"></script> | ||
<script src="./javascripts/hotkeys.js"></script> | ||
<script src="./javascripts/thumbnails.js"></script> | ||
<script src="./javascripts/player.js"></script> | ||
<script src="./javascripts/statistics.js"></script> | ||
<script src="./javascripts/graph.js"></script> | ||
<script src="./javascripts/snap.js"></script> | ||
</head> | ||
<body style='margin:0'> | ||
<canvas style="display: none"></canvas> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,8 @@ | ||
<html> | ||
<head> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
<link href="videojs.css" rel="stylesheet"> | ||
<link href="player.css" rel="stylesheet"> | ||
|
||
<script src="./javascripts/lib/lightrpc.min.js"></script> | ||
<script src="./javascripts/lib/swiftclick.min.js"></script> | ||
<script src="./javascripts/lib/playerjs.min.js"></script> | ||
<script src="./javascripts/jsoun.js"></script> | ||
<script src="./javascripts/localstorage.js"></script> | ||
<script src="./javascripts/video.js"></script> | ||
<script src="./javascripts/videojs-contrib-hls.min.js"></script> | ||
<script src="./javascripts/branding.js"></script> | ||
<script src="./javascripts/persistvolume.js"></script> | ||
<script src="./javascripts/resolutionswitcher.js"></script> | ||
<script src="./javascripts/ipfsgatewayswitcher.js"></script> | ||
<script src="./javascripts/settingsmenubuttons.js"></script> | ||
<script src="./javascripts/settingsmenuitem.js"></script> | ||
<script src="./javascripts/hotkeys.js"></script> | ||
<script src="./javascripts/thumbnails.js"></script> | ||
<script src="./javascripts/player.js"></script> | ||
<script src="./javascripts/statistics.js"></script> | ||
<script src="./javascripts/graph.js"></script> | ||
<script src="./javascripts/snap.js"></script> | ||
<link href="./bin/dtube.css" rel="stylesheet"> | ||
<script src="./bin/dtube.min.js"></script> | ||
</head> | ||
<body style='margin:0'> | ||
<canvas style="display: none"></canvas> | ||
</body> | ||
<body style='margin:0'></body> | ||
</html> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
{ | ||
"name": "dtube-embed", | ||
"version": "0.9.1", | ||
"description": "embed player for d.tube", | ||
"main": "build.js", | ||
"scripts": { | ||
"build": "node build.js" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/dtube/embed.git" | ||
}, | ||
"keywords": [ | ||
"dtube", | ||
"video", | ||
"embed", | ||
"player" | ||
], | ||
"author": "", | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/dtube/embed/issues" | ||
}, | ||
"homepage": "https://github.com/dtube/embed#readme", | ||
"devDependencies": { | ||
"clean-css": "^4.2.3", | ||
"terser": "^4.6.6" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -785,7 +785,7 @@ li { | |
font-size: 1em; | ||
} | ||
|
||
*/ .vjs-menu-item { | ||
.vjs-menu-item { | ||
text-align: center; | ||
} | ||
|
||
|
This file was deleted.
Oops, something went wrong.