summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2018-03-08 16:47:50 +0300
committerAndrew Dolgov <[email protected]>2018-03-08 16:47:50 +0300
commitcfc197038ff9709cca3708e71f5d291ae7d54b0a (patch)
tree676962dd0c1bf642f97bb0ba11b21094815ad1fb /js
parent59ddd75559d9a31b9870fcda06fbb8d1abe4627b (diff)
js: enable strict mode
Diffstat (limited to 'js')
-rw-r--r--js/common.js2
-rw-r--r--js/dict.js2
-rw-r--r--js/index.js2
-rw-r--r--js/offline.js2
-rw-r--r--js/read.js2
-rw-r--r--js/reader.js2
6 files changed, 12 insertions, 0 deletions
diff --git a/js/common.js b/js/common.js
index 9843c59..8367034 100644
--- a/js/common.js
+++ b/js/common.js
@@ -1,3 +1,5 @@
+'use strict';
+
$.urlParam = function(name){
try {
var results = new RegExp('[\?&]' + name + '=([^&#]*)').exec(window.location.href);
diff --git a/js/dict.js b/js/dict.js
index 22bbf98..8db1718 100644
--- a/js/dict.js
+++ b/js/dict.js
@@ -1,3 +1,5 @@
+'use strict';
+
$(document).ready(function() {
$(window).on("mouseup touchend", function() {
if (!navigator.onLine) return;
diff --git a/js/index.js b/js/index.js
index 785dc32..b6ec4ee 100644
--- a/js/index.js
+++ b/js/index.js
@@ -1,3 +1,5 @@
+'use strict';
+
function cache_refresh(force) {
if ('serviceWorker' in navigator) {
localforage.getItem("epube.cache-timestamp").then(function(stamp) {
diff --git a/js/offline.js b/js/offline.js
index 40e230b..749b3ff 100644
--- a/js/offline.js
+++ b/js/offline.js
@@ -1,3 +1,5 @@
+'use strict';
+
function offline_search(form) {
var query = $(".search_query").val();
diff --git a/js/read.js b/js/read.js
index 295a530..61fa44e 100644
--- a/js/read.js
+++ b/js/read.js
@@ -1,3 +1,5 @@
+'use strict';
+
var _store_position = 0;
var _enable_fullscreen = 0;
diff --git a/js/reader.js b/js/reader.js
index 453c925..34c5e06 100644
--- a/js/reader.js
+++ b/js/reader.js
@@ -1,3 +1,5 @@
+'use strict';
+
$(document).ready(function() {
$(window).on("click tap", function() {
if (parent.$(".header").is(":visible")) {