summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile5
-rw-r--r--README13
-rw-r--r--www/css/index.css1
-rw-r--r--www/js/html5ks.js11
4 files changed, 21 insertions, 9 deletions
diff --git a/Makefile b/Makefile
index 011a004..41315c5 100644
--- a/Makefile
+++ b/Makefile
@@ -13,6 +13,9 @@ WEBPMUX ?= webpmux
CONVERT ?= convert
APNGASM ?= apngasm
UGLIFYJS ?= uglifyjs
+GRUNT ?= grunt
+#JPEGTRAN ?= jpegtran
+#JPEGRESCAN ?= jpegrescan
DUMP ?= www/dump
@@ -22,7 +25,7 @@ all: .modules video audio images js
.modules: .gitmodules
git submodule update --init
ln -fs ../../config-all.json Modernizr/lib/config-all.json
- cd Modernizr && npm update && grunt build
+ cd Modernizr && npm update && $(GRUNT) build
touch .modules
# === VIDEO ===
diff --git a/README b/README
index 14db758..f3f757a 100644
--- a/README
+++ b/README
@@ -3,13 +3,14 @@ This is a WIP HTML5 implementation of the game Katawa Shoujo. [0]
== Requirements ==
- Katawa Shoujo (obviously)
- Firefox/Chrome/a sensible browser (i.e. not IE)
-- a shell (Bash, dash, zsh, etc)
-- GNU make
-- ffmpeg with fdk-aac, libopus, libtheora, libvpx, libx264 (preferably git HEAD)
+- A shell (Bash, dash, zsh, etc)
+- GNU Make
+- FFmpeg with fdk-aac, libopus, libtheora, libvpx, libx264 (preferably git HEAD)
- cwebp and webpmux from libwebp
- convert from ImageMagick
- apngasm
- uglifyjs
+- Node.js, npm, grunt
=== Recommended ===
- jpegmini
@@ -36,10 +37,8 @@ This is a WIP HTML5 implementation of the game Katawa Shoujo. [0]
-- or --
4. Open www/index.html in a browser.
-== Reducing setup time ==
-To reduce the setup time (many hours), try the following:
-
-Turn off zopflipng recompression by passing ZOPFLIPNG=: as an environment variable to setup.sh. It saves only a few MB but takes several hours to complete, depending on CPU. Useful if you're serving many, MANY copies, but not useful if you're serving one locally.
+== Disabling conversions ==
+Some conversions can be safely disabled.
== Reducing file size ==
Run `make space`. Warning: This will remove source files from dump.
diff --git a/www/css/index.css b/www/css/index.css
index e0136c1..b94f40d 100644
--- a/www/css/index.css
+++ b/www/css/index.css
@@ -338,6 +338,7 @@ input[type="checkbox"]:checked + span:before {
}
.spinner {
+ display: none;
opacity: 0;
-webkit-transition: opacity 2s;
transition: opacity 2s;
diff --git a/www/js/html5ks.js b/www/js/html5ks.js
index 40765e1..f9572b0 100644
--- a/www/js/html5ks.js
+++ b/www/js/html5ks.js
@@ -93,7 +93,16 @@ window.html5ks = {
spin: function (mod) {
clearTimeout(this._spintm);
this._spintm = setTimeout(function () {
- html5ks.elements.spinner.style.opacity = html5ks._spinners === 0 ? 0 : 1;
+ var spinner = html5ks.elements.spinner;
+ if (html5ks._spinners) {
+ spinner.style.display = "block";
+ spinner.style.opacity = 1;
+ } else {
+ spinner.style.opacity = 0;
+ this._spintm = setTimeout(function () {
+ spinner.removeAttribute("style");
+ }, 2000);
+ }
}, 1000);
this._spinners += mod;
console.assert(this._spinners >= 0);