diff --git a/README.md b/README.md
index a973f5e..9990b2f 100644
--- a/README.md
+++ b/README.md
@@ -30,7 +30,7 @@ firebase serve
- That will build it all and watch the css, img, and js assets.
- Then you can load up `http://localhost:5000` or `public/index.html` in a browser. narf!
-`/src/index.js` is the main file you'll want to edit for functionality.
+`/src/index.js`, `/src/css/style.scss`, and `/src/html/index.html` are the main files you'll want to edit for functionality.
- If you have the [LiveReload Chrome extension](https://chrome.google.com/webstore/detail/livereload/jnihajbhpnppcggbcgedagnkighmdlei) installed, it should do live css updates in your browser while gulp watch is running
- CSS is auto-prefixed for the supported browserslist, so don't manually add any browser prefixes to CSS src.
- NOTE: If you change the UI, please update the screenshot at top of this README
diff --git a/gulpfile.js b/gulpfile.js
index dbde83d..039a5d9 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -15,6 +15,7 @@ const cssnano = require('cssnano');
const svgo = require('gulp-svgo');
const sass = require('gulp-sass');
const livereload = require('gulp-livereload');
+const htmlmin = require('gulp-htmlmin');
// CONFIG
// ============================================================
@@ -31,6 +32,12 @@ const opts = {
const uglifyConf = {};
+const htmlminConfig = {
+ collapseWhitespace: true,
+ minifyCSS: true,
+ minifyJS: true
+};
+
// TASKS
// ============================================================
@@ -123,6 +130,21 @@ imgWatcher.on('change', event => {
console.log('File ' + event.path + ' was ' + event.type + ', running tasks...');
});
+// HTML
+// ============================================================
+
+gulp.task('html', () => {
+ return gulp.src('./src/html/*.html')
+ .pipe(htmlmin(htmlminConfig))
+ .pipe(gulp.dest('./public/')); // Output goes to root of /public, as per firebase hosting
+});
+
+const htmlWatcher = gulp.watch('src/html/*.html', ['html']);
+
+htmlWatcher.on('change', event => {
+ console.log('File ' + event.path + ' was ' + event.type + ', running tasks...');
+});
+
// BUILD
// ============================================================
diff --git a/package.json b/package.json
index f3eb978..59c460b 100644
--- a/package.json
+++ b/package.json
@@ -48,6 +48,7 @@
"babelify": "^7.3.0",
"cssnano": "^3.10.0",
"gulp": "^3.9.1",
+ "gulp-htmlmin": "^3.0.0",
"gulp-postcss": "^6.4.0",
"gulp-sourcemaps": "^2.5.1",
"gulp-uglify": "^2.1.2",
@@ -66,6 +67,7 @@
"babel-preset-latest": "^6.24.1",
"browserify": "^14.1.0",
"chai": "^3.5.0",
+ "gulp-htmlmin": "^3.0.0",
"gulp-livereload": "^3.8.1",
"gulp-sass": "^3.1.0",
"gulp-svgo": "^1.0.3",
diff --git a/public/404.html b/public/404.html
index 829eda8..d1cc5a7 100644
--- a/public/404.html
+++ b/public/404.html
@@ -1,33 +1 @@
-
-
-
-
-
404
-
Page Not Found
-
The specified file was not found on this website. Please check the URL for mistakes and try again.
-
Why am I seeing this?
-
This page was generated by the Firebase Command-Line Interface. To modify it, edit the 404.html
file in your project's configured public
directory.
-
-
-
+404
Page Not Found
The specified file was not found on this website. Please check the URL for mistakes and try again.
Why am I seeing this?
This page was generated by the Firebase Command-Line Interface. To modify it, edit the 404.html
file in your project's configured public
directory.
\ No newline at end of file
diff --git a/public/dist/css/min.min.css b/public/dist/css/min.min.css
deleted file mode 100644
index 457e782..0000000
--- a/public/dist/css/min.min.css
+++ /dev/null
@@ -1 +0,0 @@
-body{font-family:sans-serif;text-align:center;margin:0;font-size:16px}.smooth{transition:all .2s}hr,hr.mediumwidth{margin:2.5em auto}.mediumwidth{font-size:16px;width:40%;margin-left:30%;margin-top:.3em;margin-bottom:.3em}@media(max-width:870px){.mediumwidth{width:70%;margin-left:15%}.row [class*=c]{width:100%;display:block;margin:1% auto}.row:last-child column{margin-bottom:2.5em}}@media(max-width:520px){.mediumwidth{width:100%;margin-left:0}hr.mediumwidth{width:auto}}button,i{font-family:Lucida Sans Unicode,Lucida Grande,sans-serif}button{background:#aaa;box-shadow:3px 3px #000;color:#fff;font-size:2.5em;padding:15px 40px 16px;text-decoration:none;margin:.3em .7em;cursor:pointer;border:0}button.btn-a{background:#0ae}button.btn-a:hover{background:#09d}button.btn-a:active{background:#08b}button.btn-b{background:#3c5}button.btn-b:hover{background:#2b4}button.btn-b:active{background:#2a4}button.btn-c{background:#d33}button.btn-c:hover{background:#c22}button.btn-c:active{background:#b22}button.btn-small{padding:7px 19px;font-size:16px}.row{line-height:2em;margin-top:2%;height:2em}column{float:left;margin:auto 1%}.ie column{margin:auto .7%}.c10{width:98%}.c9{width:88%}.c8{width:78%}.c7{width:68%}.c6{width:58%}.c5{width:48%}.c4{width:38%}.c3{width:28%}.c2{width:18%}.c1{width:8%}h1{font-size:4em;margin:0}h1.title{font-size:7em}h2{font-size:2em}ico{font-size:2.04em}.ie .mediumwidth{width:70%;margin-left:0}.ie .mediumwidth hr{margin:100px auto;padding-left:200px}input,textarea{outline:0;padding:6px;font-family:sans-serif}input:focus,textarea:focus{border:1px solid #5ab}input[type=text],textarea{width:13em}.addon-front{padding:6px 11px 6px 10px;margin-right:-2px;border-right:0}.addon-front,input,textarea{border:1px solid #ccc;font-size:.8em}message{display:block;padding:2em 0;background:#ace}message.warning{background:#d99}message.great{background:#9d9}.navbar{width:100%;background:#000;color:#fff;text-align:left;height:1.5em;padding:1em 0 .6em}.navbar a{text-decoration:none}.pagename{color:#fff;padding:0 1em 0 2em;font-weight:700}.navbar-link{padding:.5em;color:#aaa}.navbar-link:hover{color:#fff}.navbar button,.navbar input{margin-top:-20px}@media(max-width:500px){.navbar a{text-align:center;display:block}.navbar{height:7.5em}}table{width:100%;border-spacing:0}.table td,.table th{padding:.5em;line-height:1.4em;text-align:left}tbody tr:nth-child(2n-1){background:#ccc}
\ No newline at end of file
diff --git a/public/dist/css/style.css b/public/dist/css/style.css
index f8bf6ff..afb324e 100644
--- a/public/dist/css/style.css
+++ b/public/dist/css/style.css
@@ -1 +1 @@
-html{background-color:#0c141f;min-height:100%}body{margin:0}body,input,select,textarea{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,Arial,sans-serif;font-size:16pt;box-sizing:border-box;color:#e6ffff;-webkit-font-smoothing:antialiased}a{color:#6fc3df}.monospace{font-family:Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.hidden,.hide-until-load{visibility:hidden}body{opacity:1;-webkit-transition:opacity .2s ease-in-out;transition:opacity .2s ease-in-out}.container{display:block}.site-heading{padding:.5em;text-align:center;margin:0;display:-webkit-box;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column}.site-heading span{display:-webkit-box;display:flex;-webkit-box-align:center;align-items:center;-webkit-box-pack:center;justify-content:center;text-shadow:0 0 10px #fff,0 0 40px #6fc3df}.site-heading h1{font-size:200%;margin:.3em 0 .5em .5em;letter-spacing:0;font-weight:200}.site-heading img.logo{display:none}.controls{cursor:pointer;display:-webkit-box;display:flex;justify-content:space-around;font-size:60%;text-transform:uppercase}.controls img{padding:1em;border-radius:1em;background-color:transparent;height:30px}.controls>div>.active,.controls>div>:active{background-color:#6fc3df;-webkit-transition:color .1s ease-in-out;transition:color .1s ease-in-out}.problem-group{display:block;margin:.7em 0;-webkit-box-align:center;align-items:center}.problem{display:block;margin:1em}.code-and-tests{vertical-align:top;display:block}.code{font-size:80%;color:#f8f8f2;color:#fff;overflow-x:auto;padding:.5em;background:#23241f;background:#1a1a1a;border-radius:3px;padding:.25em .65em}.code,.test-area{display:inline-block;width:100%}.test-area{vertical-align:top}.test-suite{font-size:60%}.test{display:block;margin:.7em 0}.test-state{display:inline-block;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.test-state.pass{color:#6fc3df}.test-state.fail{color:#df740c}.test-name{display:inline-block}.test-total{background-color:gray;color:#fff;text-align:center;padding:.5em;-webkit-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.test-total.working{background:url(/dist/img/reload.svg)}.test-total.pass{background-color:#6fc3df}.test-total.fail{background-color:#df740c}.console{font-size:70%;margin:.5em 0;vertical-align:top}.console>h4{text-align:center}.ads-bottom{display:-webkit-box;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;-webkit-box-align:center;align-items:center;-webkit-box-pack:center;justify-content:center;margin:5em 0 1em}footer{margin:0 auto;text-align:center;left:0;bottom:0;height:70px;width:100%;font-size:60%}footer>div{margin:.4em auto}@media (min-width:760px){.container{width:92%;margin:0 auto;display:-webkit-box;display:flex}.left-spacer{-webkit-box-flex:0.5;flex:0.5}main{-webkit-box-flex:30;flex:30}.site-heading .container{-webkit-box-pack:justify;justify-content:space-between;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;-webkit-box-align:center;align-items:center}.site-heading>.container>h1{font-size:200%}.site-heading img.logo{height:60px;display:-webkit-box;display:flex}.problem-name{display:block}.problem-group{display:-webkit-box;display:flex;-webkit-box-pack:justify;justify-content:space-between}.problem{display:block;margin-right:.6em}.code-and-tests{display:-webkit-box;display:flex}.test-area{width:30%}.code-and-eval-console{width:70%}}
\ No newline at end of file
+html{background-color:#0c141f;min-height:100%}body{margin:0}body,input,select,textarea{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,Arial,sans-serif;font-size:16pt;box-sizing:border-box;color:#e6ffff;-webkit-font-smoothing:antialiased}a{color:#6fc3df}.monospace{font-family:Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.hidden,.hide-until-load{visibility:hidden}body{opacity:1;transition:opacity .2s ease-in-out}.container{display:block}.site-heading{padding:.5em;text-align:center;margin:0;display:-webkit-box;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;flex-direction:column}.site-heading span{display:-webkit-box;display:flex;-webkit-box-align:center;align-items:center;-webkit-box-pack:center;justify-content:center;text-shadow:0 0 10px #fff,0 0 40px #6fc3df}.site-heading h1{font-size:200%;margin:.3em 0 .5em .5em;letter-spacing:0;font-weight:200}.site-heading img.logo{display:none}.controls{cursor:pointer;display:-webkit-box;display:flex;justify-content:space-around;font-size:60%;text-transform:uppercase}.controls img{padding:1em;border-radius:1em;background-color:transparent;height:30px}.controls>div>.active,.controls>div>:active{background-color:#6fc3df;transition:color .1s ease-in-out}.problem-group{display:block;margin:.7em 0;-webkit-box-align:center;align-items:center}.problem{display:block;margin:1em}.code-and-tests{vertical-align:top;display:block}.code{font-size:80%;color:#f8f8f2;color:#fff;overflow-x:auto;padding:.5em;background:#23241f;background:#1a1a1a;border-radius:3px;padding:.25em .65em}.code,.test-area{display:inline-block;width:100%}.test-area{vertical-align:top}.test-suite{font-size:60%}.test{display:block;margin:.7em 0}.test-state{display:inline-block;transition:all .2s ease-in-out}.test-state.pass{color:#6fc3df}.test-state.fail{color:#df740c}.test-name{display:inline-block}.test-total{background-color:gray;color:#fff;text-align:center;padding:.5em;transition:all .2s ease-in-out}.test-total.working{background:url(/dist/img/reload.svg)}.test-total.pass{background-color:#6fc3df}.test-total.fail{background-color:#df740c}.console{font-size:70%;margin:.5em 0;vertical-align:top}.console>h4{text-align:center}.ads-bottom{display:-webkit-box;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;-webkit-box-align:center;align-items:center;-webkit-box-pack:center;justify-content:center;margin:5em 0 1em}footer{margin:0 auto;text-align:center;left:0;bottom:0;height:70px;width:100%;font-size:60%}footer>div{margin:.4em auto}@media (min-width:760px){.container{width:92%;margin:0 auto;display:-webkit-box;display:flex}.left-spacer{-webkit-box-flex:0.5;flex:0.5}main{-webkit-box-flex:30;flex:30}.site-heading .container{-webkit-box-pack:justify;justify-content:space-between;-webkit-box-orient:horizontal;-webkit-box-direction:normal;flex-direction:row;-webkit-box-align:center;align-items:center}.site-heading>.container>h1{font-size:200%}.site-heading img.logo{height:60px;display:-webkit-box;display:flex}.problem-name{display:block}.problem-group{display:-webkit-box;display:flex;-webkit-box-pack:justify;justify-content:space-between}.problem{display:block;margin-right:.6em}.code-and-tests{display:-webkit-box;display:flex}.test-area{width:30%}.code-and-eval-console{width:70%}}
\ No newline at end of file
diff --git a/public/dist/js/bundle.min.js b/public/dist/js/bundle.min.js
index 7651078..6f32d4e 100644
--- a/public/dist/js/bundle.min.js
+++ b/public/dist/js/bundle.min.js
@@ -1,4 +1,4 @@
!function e(t,n,r){function o(a,s){if(!n[a]){if(!t[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(i)return i(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var f=n[a]={exports:{}};t[a][0].call(f.exports,function(e){var n=t[a][1][e];return o(n||e)},f,f.exports,e,t,n,r)}return n[a].exports}for(var i="function"==typeof require&&require,a=0;a