mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 01:41:22 +01:00
cleanup
This commit is contained in:
parent
6a6264e21c
commit
4bdf08e3aa
2 changed files with 5 additions and 2 deletions
2
main.js
2
main.js
|
|
@ -10,7 +10,7 @@ const TIME = DEBUG || !PRODUCTION;
|
|||
const WARN = true;
|
||||
const ERROR = true;
|
||||
|
||||
if ("serviceWorker" in navigator) {
|
||||
if (PRODUCTION && "serviceWorker" in navigator) {
|
||||
window.addEventListener("load", () => {
|
||||
navigator.serviceWorker.register("./sw.js").catch(err => {
|
||||
console.error("ServiceWorker registration failed: ", err);
|
||||
|
|
|
|||
|
|
@ -33,10 +33,13 @@ function createButton() {
|
|||
}
|
||||
|
||||
function openDialog() {
|
||||
alertMessage.innerHTML = /* html */ `You can install the tool so that it will look and feel like desktop application`;
|
||||
alertMessage.innerHTML = /* html */ `You can install the tool so that it will look and feel like desktop application:
|
||||
have its own icon on your home screen and work offline with some limitations
|
||||
`;
|
||||
$("#alert").dialog({
|
||||
resizable: false,
|
||||
title: "Install the Application",
|
||||
width: "38em",
|
||||
buttons: {
|
||||
Install: function () {
|
||||
$(this).dialog("close");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue