Reverted weird space changes
diff --git a/api.php b/api.php
index e6957b6..176fdfe 100644
--- a/api.php
+++ b/api.php
@@ -1,33 +1,33 @@
-<?php
-require_once("config.php");
-
-class write {
- public static function output($json) {
- print_r(json_encode($json));
- exit();
- }
-
- public static function error($n, $msg) {
- self::output(["error" => $n, "msg" => $msg]);
- }
-}
-
-function get_graph() {
- global $conf;
- return json_decode(file_get_contents($conf["apiurl"]), true);
-}
-
-if (!isset($_GET["action"])) {
- write::error(1, "No action provided");
-}
-
-switch ($_GET["action"]) {
- case "getgraf":
- $graf = file_get_contents($conf["apiurl"]);
- echo $graf;
- break;
-
- default:
- write::error(2, "Unknown action");
-}
-?>
+<?php
+require_once("config.php");
+
+class write {
+ public static function output($json) {
+ print_r(json_encode($json));
+ exit();
+ }
+
+ public static function error($n, $msg) {
+ self::output(["error" => $n, "msg" => $msg]);
+ }
+}
+
+function get_graph() {
+ global $conf;
+ return json_decode(file_get_contents($conf["apiurl"]), true);
+}
+
+if (!isset($_GET["action"])) {
+ write::error(1, "No action provided");
+}
+
+switch ($_GET["action"]) {
+ case "getgraf":
+ $graf = file_get_contents($conf["apiurl"]);
+ echo $graf;
+ break;
+
+ default:
+ write::error(2, "Unknown action");
+}
+?>
diff --git a/assistant/en.json b/assistant/en.json
index e7aa8f9..cadd504 100644
--- a/assistant/en.json
+++ b/assistant/en.json
@@ -1,25 +1,25 @@
-{
- "new_to_graph": "It seems like {person} is new to the graph, because they don't share any edges with another person.",
- "edges_1": "Alright, {person} shares an edge with {count}: {edges}.",
- "edges_2": "Ok, {person} shares an edge with {count}: {edges}.",
- "edges_3": "{person} shares an edge with {count}: {edges}.",
- "edges_display": "{person} shares an edge with {count}.",
- "count_singular": "one person",
- "count_plural": "{count} people",
- "not_found": "I'm sorry, but I didn't find anyone called {person} in the graph.",
- "random_fact": "Here's a random fact: {fact}",
- "num_vertices": "The number of vertices in the graph is {count}.",
- "num_edges": "The number of edges in the graph is {count}.",
- "didyouknow_last_edge": "did you know that the last edge is the one between {person1} and {person2}?",
- "didyouknow_num_vertices": "Did you know that the number of vertices in the graph is {count}?",
- "didyouknow_num_edges": "Did you know that the number of edges in the graph is {count}?",
- "didyouknow_k3": "did you know that the first three vertices of the graph form a K3?",
- "didyouknow_creator": "Did you know that Dario currently hosts the graph and that he is thought to be its creator?",
- "didyouknow_groph": "did you know that for a while, the graph wasn't connex and the smallest component was named 'the groph'? Fortunately, right now the Groph is connected to the rest of the graph.",
- "followup_1": "Is there anything else I can do for you?",
- "followup_2": "Now, is there anything else you want to know?",
- "followup_3": "Is there anything else you want to know?",
- "latest_news": "<speak>These are the latest edges in the graph: {edges}.</speak>",
- "latest_news_count": "<speak>These are the last {count} edges in the graph: {edges}.</speak>",
- "and": "and"
-}
+{
+ "new_to_graph": "It seems like {person} is new to the graph, because they don't share any edges with another person.",
+ "edges_1": "Alright, {person} shares an edge with {count}: {edges}.",
+ "edges_2": "Ok, {person} shares an edge with {count}: {edges}.",
+ "edges_3": "{person} shares an edge with {count}: {edges}.",
+ "edges_display": "{person} shares an edge with {count}.",
+ "count_singular": "one person",
+ "count_plural": "{count} people",
+ "not_found": "I'm sorry, but I didn't find anyone called {person} in the graph.",
+ "random_fact": "Here's a random fact: {fact}",
+ "num_vertices": "The number of vertices in the graph is {count}.",
+ "num_edges": "The number of edges in the graph is {count}.",
+ "didyouknow_last_edge": "did you know that the last edge is the one between {person1} and {person2}?",
+ "didyouknow_num_vertices": "Did you know that the number of vertices in the graph is {count}?",
+ "didyouknow_num_edges": "Did you know that the number of edges in the graph is {count}?",
+ "didyouknow_k3": "did you know that the first three vertices of the graph form a K3?",
+ "didyouknow_creator": "Did you know that Dario currently hosts the graph and that he is thought to be its creator?",
+ "didyouknow_groph": "did you know that for a while, the graph wasn't connex and the smallest component was named 'the groph'? Fortunately, right now the Groph is connected to the rest of the graph.",
+ "followup_1": "Is there anything else I can do for you?",
+ "followup_2": "Now, is there anything else you want to know?",
+ "followup_3": "Is there anything else you want to know?",
+ "latest_news": "<speak>These are the latest edges in the graph: {edges}.</speak>",
+ "latest_news_count": "<speak>These are the last {count} edges in the graph: {edges}.</speak>",
+ "and": "and"
+}
diff --git a/config.default.php b/config.default.php
index 8d304dc..943d1d8 100644
--- a/config.default.php
+++ b/config.default.php
@@ -1,6 +1,6 @@
-<?php
-// Rename this file as config.php and fill in the details below.
-$conf = array();
-$conf["apiurl"] = ""; // L'adreça de l'API del graf original.
-$conf["password"] = ""; // La contrasenya perquè la gent pugui entrar al graf.
-
+<?php
+// Rename this file as config.php and fill in the details below.
+$conf = array();
+$conf["apiurl"] = ""; // L'adreça de l'API del graf original.
+$conf["password"] = ""; // La contrasenya perquè la gent pugui entrar al graf.
+
diff --git a/img/graf.svg b/img/graf.svg
index eee8b0a..271d998 100644
--- a/img/graf.svg
+++ b/img/graf.svg
@@ -1,28 +1,28 @@
-<svg width="194" height="194" xmlns="http://www.w3.org/2000/svg">
- <g>
- <title>Layer 1</title>
- <ellipse fill="#060606" stroke-width="0" fill-opacity="null" cx="97" cy="97" id="svg_10" rx="88" ry="88"/>
- </g>
- <g>
- <title>Layer 2</title>
- <g id="svg_9">
- <line fill-opacity="null" x1="48" y1="138" x2="98.5" y2="99" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- <line fill-opacity="null" x1="98.5" y1="99" x2="105" y2="150" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- <line fill-opacity="null" x1="53" y1="76" x2="149" y2="84" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- <line fill-opacity="null" x1="53" y1="76" x2="105" y2="150" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- <line fill-opacity="null" x1="98.5" y1="99" x2="149" y2="84" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- <line fill-opacity="null" x1="53" y1="76" x2="98.5" y2="99" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- <line fill-opacity="null" x1="53" y1="76" x2="121" y2="35" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
- </g>
- </g>
- <g>
- <title>Layer 3</title>
- <ellipse fill="#d61c08" cx="48" cy="138" id="svg_2" rx="8" ry="8"/>
- <ellipse fill="#0159aa" cx="98.5" cy="99" id="svg_3" rx="8" ry="8"/>
- <ellipse fill="#0159aa" cx="105" cy="150" id="svg_4" rx="8" ry="8"/>
- <ellipse fill="#d61c08" cx="53" cy="76" id="svg_5" rx="8" ry="8"/>
- <ellipse fill="#d61c08" cx="149" cy="84" id="svg_6" rx="8" ry="8"/>
- <ellipse fill="#0159aa" cx="121" cy="35" id="svg_7" rx="8" ry="8"/>
- <ellipse fill="#0ca80a" cx="147" cy="123" id="svg_8" rx="8" ry="8"/>
- </g>
-</svg>
+<svg width="194" height="194" xmlns="http://www.w3.org/2000/svg">
+ <g>
+ <title>Layer 1</title>
+ <ellipse fill="#060606" stroke-width="0" fill-opacity="null" cx="97" cy="97" id="svg_10" rx="88" ry="88"/>
+ </g>
+ <g>
+ <title>Layer 2</title>
+ <g id="svg_9">
+ <line fill-opacity="null" x1="48" y1="138" x2="98.5" y2="99" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ <line fill-opacity="null" x1="98.5" y1="99" x2="105" y2="150" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ <line fill-opacity="null" x1="53" y1="76" x2="149" y2="84" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ <line fill-opacity="null" x1="53" y1="76" x2="105" y2="150" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ <line fill-opacity="null" x1="98.5" y1="99" x2="149" y2="84" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ <line fill-opacity="null" x1="53" y1="76" x2="98.5" y2="99" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ <line fill-opacity="null" x1="53" y1="76" x2="121" y2="35" id="svg_1" stroke-linejoin="null" stroke-linecap="null" fill="none" stroke="#FFF" stroke-width="2" stroke-opacity="null"/>
+ </g>
+ </g>
+ <g>
+ <title>Layer 3</title>
+ <ellipse fill="#d61c08" cx="48" cy="138" id="svg_2" rx="8" ry="8"/>
+ <ellipse fill="#0159aa" cx="98.5" cy="99" id="svg_3" rx="8" ry="8"/>
+ <ellipse fill="#0159aa" cx="105" cy="150" id="svg_4" rx="8" ry="8"/>
+ <ellipse fill="#d61c08" cx="53" cy="76" id="svg_5" rx="8" ry="8"/>
+ <ellipse fill="#d61c08" cx="149" cy="84" id="svg_6" rx="8" ry="8"/>
+ <ellipse fill="#0159aa" cx="121" cy="35" id="svg_7" rx="8" ry="8"/>
+ <ellipse fill="#0ca80a" cx="147" cy="123" id="svg_8" rx="8" ry="8"/>
+ </g>
+</svg>
diff --git a/img/graf_square.svg b/img/graf_square.svg
index e7af204..14f51c7 100644
--- a/img/graf_square.svg
+++ b/img/graf_square.svg
@@ -1,28 +1,28 @@
-<svg width="194" height="194" xmlns="http://www.w3.org/2000/svg">
- <g>
- <title>Layer 1</title>
- <rect fill="#060606" stroke-width="0" id="svg_10" width="100%" height="100%"/>
- </g>
- <g>
- <title>Layer 2</title>
- <g id="svg_9">
- <line fill-opacity="null" x1="48" y1="138" x2="98.5" y2="99" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- <line fill-opacity="null" x1="98.5" y1="99" x2="105" y2="150" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- <line fill-opacity="null" x1="53" y1="76" x2="149" y2="84" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- <line fill-opacity="null" x1="53" y1="76" x2="105" y2="150" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- <line fill-opacity="null" x1="98.5" y1="99" x2="149" y2="84" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- <line fill-opacity="null" x1="53" y1="76" x2="98.5" y2="99" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- <line fill-opacity="null" x1="53" y1="76" x2="121" y2="35" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
- </g>
- </g>
- <g>
- <title>Layer 3</title>
- <ellipse fill="#d61c08" cx="48" cy="138" id="svg_2" rx="8" ry="8"/>
- <ellipse fill="#0159aa" cx="98.5" cy="99" id="svg_3" rx="8" ry="8"/>
- <ellipse fill="#0159aa" cx="105" cy="150" id="svg_4" rx="8" ry="8"/>
- <ellipse fill="#d61c08" cx="53" cy="76" id="svg_5" rx="8" ry="8"/>
- <ellipse fill="#d61c08" cx="149" cy="84" id="svg_6" rx="8" ry="8"/>
- <ellipse fill="#0159aa" cx="121" cy="35" id="svg_7" rx="8" ry="8"/>
- <ellipse fill="#0ca80a" cx="147" cy="123" id="svg_8" rx="8" ry="8"/>
- </g>
-</svg>
+<svg width="194" height="194" xmlns="http://www.w3.org/2000/svg">
+ <g>
+ <title>Layer 1</title>
+ <rect fill="#060606" stroke-width="0" id="svg_10" width="100%" height="100%"/>
+ </g>
+ <g>
+ <title>Layer 2</title>
+ <g id="svg_9">
+ <line fill-opacity="null" x1="48" y1="138" x2="98.5" y2="99" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ <line fill-opacity="null" x1="98.5" y1="99" x2="105" y2="150" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ <line fill-opacity="null" x1="53" y1="76" x2="149" y2="84" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ <line fill-opacity="null" x1="53" y1="76" x2="105" y2="150" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ <line fill-opacity="null" x1="98.5" y1="99" x2="149" y2="84" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ <line fill-opacity="null" x1="53" y1="76" x2="98.5" y2="99" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ <line fill-opacity="null" x1="53" y1="76" x2="121" y2="35" id="svg_1" fill="none" stroke="#FFF" stroke-width="2" />
+ </g>
+ </g>
+ <g>
+ <title>Layer 3</title>
+ <ellipse fill="#d61c08" cx="48" cy="138" id="svg_2" rx="8" ry="8"/>
+ <ellipse fill="#0159aa" cx="98.5" cy="99" id="svg_3" rx="8" ry="8"/>
+ <ellipse fill="#0159aa" cx="105" cy="150" id="svg_4" rx="8" ry="8"/>
+ <ellipse fill="#d61c08" cx="53" cy="76" id="svg_5" rx="8" ry="8"/>
+ <ellipse fill="#d61c08" cx="149" cy="84" id="svg_6" rx="8" ry="8"/>
+ <ellipse fill="#0159aa" cx="121" cy="35" id="svg_7" rx="8" ry="8"/>
+ <ellipse fill="#0ca80a" cx="147" cy="123" id="svg_8" rx="8" ry="8"/>
+ </g>
+</svg>
diff --git a/js/service-worker.js b/js/service-worker.js
index a70346f..f5ed189 100644
--- a/js/service-worker.js
+++ b/js/service-worker.js
@@ -1,102 +1,102 @@
-/*
- Copyright 2015 Google Inc. All Rights Reserved.
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
- http://www.apache.org/licenses/LICENSE-2.0
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-'use strict';
-
-// Incrementing CACHE_VERSION will kick off the install event and force previously cached
-// resources to be cached again.
-const CACHE_VERSION = 1;
-let CURRENT_CACHES = {
- offline: 'offline-v' + CACHE_VERSION
-};
-const OFFLINE_URL = 'offline.html';
-
-function createCacheBustedRequest(url) {
- let request = new Request(url, {cache: 'reload'});
- // See https://fetch.spec.whatwg.org/#concept-request-mode
- // This is not yet supported in Chrome as of M48, so we need to explicitly check to see
- // if the cache: 'reload' option had any effect.
- if ('cache' in request) {
- return request;
- }
-
- // If {cache: 'reload'} didn't have any effect, append a cache-busting URL parameter instead.
- let bustedUrl = new URL(url, self.location.href);
- bustedUrl.search += (bustedUrl.search ? '&' : '') + 'cachebust=' + Date.now();
- return new Request(bustedUrl);
-}
-
-self.addEventListener('install', event => {
- event.waitUntil(
- // We can't use cache.add() here, since we want OFFLINE_URL to be the cache key, but
- // the actual URL we end up requesting might include a cache-busting parameter.
- fetch(createCacheBustedRequest(OFFLINE_URL)).then(function(response) {
- return caches.open(CURRENT_CACHES.offline).then(function(cache) {
- return cache.put(OFFLINE_URL, response);
- });
- })
- );
-});
-
-self.addEventListener('activate', event => {
- // Delete all caches that aren't named in CURRENT_CACHES.
- // While there is only one cache in this example, the same logic will handle the case where
- // there are multiple versioned caches.
- let expectedCacheNames = Object.keys(CURRENT_CACHES).map(function(key) {
- return CURRENT_CACHES[key];
- });
-
- event.waitUntil(
- caches.keys().then(cacheNames => {
- return Promise.all(
- cacheNames.map(cacheName => {
- if (expectedCacheNames.indexOf(cacheName) === -1) {
- // If this cache name isn't present in the array of "expected" cache names,
- // then delete it.
- console.log('Deleting out of date cache:', cacheName);
- return caches.delete(cacheName);
- }
- })
- );
- })
- );
-});
-
-self.addEventListener('fetch', event => {
- // We only want to call event.respondWith() if this is a navigation request
- // for an HTML page.
- // request.mode of 'navigate' is unfortunately not supported in Chrome
- // versions older than 49, so we need to include a less precise fallback,
- // which checks for a GET request with an Accept: text/html header.
- if (event.request.mode === 'navigate' ||
- (event.request.method === 'GET' &&
- event.request.headers.get('accept').includes('text/html'))) {
- console.log('Handling fetch event for', event.request.url);
- event.respondWith(
- fetch(event.request).catch(error => {
- // The catch is only triggered if fetch() throws an exception, which will most likely
- // happen due to the server being unreachable.
- // If fetch() returns a valid HTTP response with an response code in the 4xx or 5xx
- // range, the catch() will NOT be called. If you need custom handling for 4xx or 5xx
- // errors, see https://github.com/GoogleChrome/samples/tree/gh-pages/service-worker/fallback-response
- console.log('Fetch failed; returning offline page instead.', error);
- return caches.match(OFFLINE_URL);
- })
- );
- }
-
- // If our if() condition is false, then this fetch handler won't intercept the request.
- // If there are any other fetch handlers registered, they will get a chance to call
- // event.respondWith(). If no fetch handlers call event.respondWith(), the request will be
- // handled by the browser as if there were no service worker involvement.
-});
+/*
+ Copyright 2015 Google Inc. All Rights Reserved.
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+ http://www.apache.org/licenses/LICENSE-2.0
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+'use strict';
+
+// Incrementing CACHE_VERSION will kick off the install event and force previously cached
+// resources to be cached again.
+const CACHE_VERSION = 1;
+let CURRENT_CACHES = {
+ offline: 'offline-v' + CACHE_VERSION
+};
+const OFFLINE_URL = 'offline.html';
+
+function createCacheBustedRequest(url) {
+ let request = new Request(url, {cache: 'reload'});
+ // See https://fetch.spec.whatwg.org/#concept-request-mode
+ // This is not yet supported in Chrome as of M48, so we need to explicitly check to see
+ // if the cache: 'reload' option had any effect.
+ if ('cache' in request) {
+ return request;
+ }
+
+ // If {cache: 'reload'} didn't have any effect, append a cache-busting URL parameter instead.
+ let bustedUrl = new URL(url, self.location.href);
+ bustedUrl.search += (bustedUrl.search ? '&' : '') + 'cachebust=' + Date.now();
+ return new Request(bustedUrl);
+}
+
+self.addEventListener('install', event => {
+ event.waitUntil(
+ // We can't use cache.add() here, since we want OFFLINE_URL to be the cache key, but
+ // the actual URL we end up requesting might include a cache-busting parameter.
+ fetch(createCacheBustedRequest(OFFLINE_URL)).then(function(response) {
+ return caches.open(CURRENT_CACHES.offline).then(function(cache) {
+ return cache.put(OFFLINE_URL, response);
+ });
+ })
+ );
+});
+
+self.addEventListener('activate', event => {
+ // Delete all caches that aren't named in CURRENT_CACHES.
+ // While there is only one cache in this example, the same logic will handle the case where
+ // there are multiple versioned caches.
+ let expectedCacheNames = Object.keys(CURRENT_CACHES).map(function(key) {
+ return CURRENT_CACHES[key];
+ });
+
+ event.waitUntil(
+ caches.keys().then(cacheNames => {
+ return Promise.all(
+ cacheNames.map(cacheName => {
+ if (expectedCacheNames.indexOf(cacheName) === -1) {
+ // If this cache name isn't present in the array of "expected" cache names,
+ // then delete it.
+ console.log('Deleting out of date cache:', cacheName);
+ return caches.delete(cacheName);
+ }
+ })
+ );
+ })
+ );
+});
+
+self.addEventListener('fetch', event => {
+ // We only want to call event.respondWith() if this is a navigation request
+ // for an HTML page.
+ // request.mode of 'navigate' is unfortunately not supported in Chrome
+ // versions older than 49, so we need to include a less precise fallback,
+ // which checks for a GET request with an Accept: text/html header.
+ if (event.request.mode === 'navigate' ||
+ (event.request.method === 'GET' &&
+ event.request.headers.get('accept').includes('text/html'))) {
+ console.log('Handling fetch event for', event.request.url);
+ event.respondWith(
+ fetch(event.request).catch(error => {
+ // The catch is only triggered if fetch() throws an exception, which will most likely
+ // happen due to the server being unreachable.
+ // If fetch() returns a valid HTTP response with an response code in the 4xx or 5xx
+ // range, the catch() will NOT be called. If you need custom handling for 4xx or 5xx
+ // errors, see https://github.com/GoogleChrome/samples/tree/gh-pages/service-worker/fallback-response
+ console.log('Fetch failed; returning offline page instead.', error);
+ return caches.match(OFFLINE_URL);
+ })
+ );
+ }
+
+ // If our if() condition is false, then this fetch handler won't intercept the request.
+ // If there are any other fetch handlers registered, they will get a chance to call
+ // event.respondWith(). If no fetch handlers call event.respondWith(), the request will be
+ // handled by the browser as if there were no service worker involvement.
+});
diff --git a/login.php b/login.php
index eed968f..4c3ccec 100644
--- a/login.php
+++ b/login.php
@@ -1,50 +1,50 @@
-<!DOCTYPE html>
-<html>
- <head>
- <meta charset="utf-8">
- <title>Graf alternatiu FME</title>
-
- <meta name=viewport content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
-
- <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
- <link rel="stylesheet" href="https://code.getmdl.io/1.3.0/material.blue_grey-blue.min.css" />
-
- <style>
- .page-content {
- display: block;
- max-width: 500px;
- margin-top: 16px;
- margin-left: auto;
- margin-right: auto;
- padding: 16px;
- }
- </style>
- </head>
- <body>
- <div class="mdl-layout mdl-js-layout mdl-layout--fixed-header">
- <header class="mdl-layout__header">
- <div class="mdl-layout__header-row">
- <!-- Title -->
- <span class="mdl-layout-title">Graf alternatiu FME</span>
- </div>
- </header>
- <main class="mdl-layout__content">
- <div class="page-content mdl-shadow--4dp">
- <form action="graf.php" method="POST">
- <div class="mdl-textfield mdl-textfield--floating-label mdl-js-textfield"><input class="mdl-textfield__input" type="password" name="password" id="password"><label class="mdl-textfield__label" for="password">Contrasenya</label></div>
- <p><button class="mdl-button mdl-js-button mdl-button--raised mdl-button--accent mdl-js-ripple-effect" type="submit">Entrar</button></p>
- </form>
- </div>
- </main>
- </div>
- <div class="mdl-snackbar mdl-js-snackbar"><div class="mdl-snackbar__text"></div><button type="button" class="mdl-snackbar__action"></button></div>
-
- <script src="https://code.getmdl.io/1.3.0/material.min.js"></script>
-
- <?php
- if (isset($_GET["msg"]) && $_GET["msg"] == "wrong") {
- echo "<script>window.addEventListener('load', function() { var notification = document.querySelector('.mdl-js-snackbar'); notification.MaterialSnackbar.showSnackbar({ message: 'Contrasenya incorrecta' }); });</script>";
- }
- ?>
- </body>
-</html>
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta charset="utf-8">
+ <title>Graf alternatiu FME</title>
+
+ <meta name=viewport content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
+
+ <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
+ <link rel="stylesheet" href="https://code.getmdl.io/1.3.0/material.blue_grey-blue.min.css" />
+
+ <style>
+ .page-content {
+ display: block;
+ max-width: 500px;
+ margin-top: 16px;
+ margin-left: auto;
+ margin-right: auto;
+ padding: 16px;
+ }
+ </style>
+ </head>
+ <body>
+ <div class="mdl-layout mdl-js-layout mdl-layout--fixed-header">
+ <header class="mdl-layout__header">
+ <div class="mdl-layout__header-row">
+ <!-- Title -->
+ <span class="mdl-layout-title">Graf alternatiu FME</span>
+ </div>
+ </header>
+ <main class="mdl-layout__content">
+ <div class="page-content mdl-shadow--4dp">
+ <form action="graf.php" method="POST">
+ <div class="mdl-textfield mdl-textfield--floating-label mdl-js-textfield"><input class="mdl-textfield__input" type="password" name="password" id="password"><label class="mdl-textfield__label" for="password">Contrasenya</label></div>
+ <p><button class="mdl-button mdl-js-button mdl-button--raised mdl-button--accent mdl-js-ripple-effect" type="submit">Entrar</button></p>
+ </form>
+ </div>
+ </main>
+ </div>
+ <div class="mdl-snackbar mdl-js-snackbar"><div class="mdl-snackbar__text"></div><button type="button" class="mdl-snackbar__action"></button></div>
+
+ <script src="https://code.getmdl.io/1.3.0/material.min.js"></script>
+
+ <?php
+ if (isset($_GET["msg"]) && $_GET["msg"] == "wrong") {
+ echo "<script>window.addEventListener('load', function() { var notification = document.querySelector('.mdl-js-snackbar'); notification.MaterialSnackbar.showSnackbar({ message: 'Contrasenya incorrecta' }); });</script>";
+ }
+ ?>
+ </body>
+</html>
diff --git a/manifest.json b/manifest.json
index 85ff23f..7560119 100644
--- a/manifest.json
+++ b/manifest.json
@@ -1,15 +1,15 @@
-{
- "short_name": "Graf FME",
- "name": "El graf alternatiu de la FME",
- "icons": [
- {
- "src": "img/graf.png",
- "type": "image/png",
- "sizes": "192x192"
- }
- ],
- "background_color": "#060606",
- "theme_color": "#060606",
- "display": "fullscreen",
- "start_url": "graf.php?utm_source=homescreen"
-}
+{
+ "short_name": "Graf FME",
+ "name": "El graf alternatiu de la FME",
+ "icons": [
+ {
+ "src": "img/graf.png",
+ "type": "image/png",
+ "sizes": "192x192"
+ }
+ ],
+ "background_color": "#060606",
+ "theme_color": "#060606",
+ "display": "fullscreen",
+ "start_url": "graf.php?utm_source=homescreen"
+}