Merge branch 'develop' into feature/maproulette
This commit is contained in:
commit
556ed6001f
5 changed files with 10 additions and 9 deletions
|
@ -1,6 +1,8 @@
|
||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
<svg
|
<svg
|
||||||
viewBox="0 0 600 600"
|
viewBox="0 0 600 600"
|
||||||
|
width="600"
|
||||||
|
height="600"
|
||||||
version="1.1"
|
version="1.1"
|
||||||
id="svg20"
|
id="svg20"
|
||||||
sodipodi:docname="crossing.svg"
|
sodipodi:docname="crossing.svg"
|
||||||
|
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="UTF-8" ?>
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 600 600">
|
<svg xmlns="http://www.w3.org/2000/svg" width="600" height="600" viewBox="0 0 600 600">
|
||||||
<rect fill="#750787" width="600" height="600" />
|
<rect fill="#750787" width="600" height="600" />
|
||||||
<rect fill="#004dff" width="500" height="600" />
|
<rect fill="#004dff" width="500" height="600" />
|
||||||
<rect fill="#008026" width="400" height="600" />
|
<rect fill="#008026" width="400" height="600" />
|
||||||
|
|
Before Width: | Height: | Size: 733 B After Width: | Height: | Size: 758 B |
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"name": "index",
|
"name": "MapComplete",
|
||||||
"short_name": "MapComplete",
|
"short_name": "MapComplete",
|
||||||
"start_url": "index.html",
|
"start_url": "index.html",
|
||||||
"lang": "en",
|
"lang": "en",
|
||||||
|
|
|
@ -165,7 +165,7 @@ async function createManifest(layout: LayoutConfig, alreadyWritten: string[]): P
|
||||||
const ogDescr = Translations.T(layout.description ?? "").txt;
|
const ogDescr = Translations.T(layout.description ?? "").txt;
|
||||||
|
|
||||||
const manifest = {
|
const manifest = {
|
||||||
name: name,
|
name: ogTitle,
|
||||||
short_name: ogTitle,
|
short_name: ogTitle,
|
||||||
start_url: `${layout.id.toLowerCase()}.html`,
|
start_url: `${layout.id.toLowerCase()}.html`,
|
||||||
lang: "en",
|
lang: "en",
|
||||||
|
@ -257,7 +257,7 @@ async function createLandingPage(layout: LayoutConfig, manifest, whiteIcons, alr
|
||||||
.replace(/<!-- THEME-SPECIFIC -->.*<!-- THEME-SPECIFIC-END-->/s, themeSpecific)
|
.replace(/<!-- THEME-SPECIFIC -->.*<!-- THEME-SPECIFIC-END-->/s, themeSpecific)
|
||||||
.replace(/<!-- DESCRIPTION START -->.*<!-- DESCRIPTION END -->/s, layout.shortDescription.textFor(targetLanguage))
|
.replace(/<!-- DESCRIPTION START -->.*<!-- DESCRIPTION END -->/s, layout.shortDescription.textFor(targetLanguage))
|
||||||
.replace("<script src=\"./index.ts\"></script>", `<script src='./index_${layout.id}.ts'></script>`);
|
.replace("<script src=\"./index.ts\"></script>", `<script src='./index_${layout.id}.ts'></script>`);
|
||||||
|
0
|
||||||
try {
|
try {
|
||||||
output = output
|
output = output
|
||||||
.replace(/<!-- DECORATION 0 START -->.*<!-- DECORATION 0 END -->/s, `<img src='${icon}' width="100%" height="100%">`)
|
.replace(/<!-- DECORATION 0 START -->.*<!-- DECORATION 0 END -->/s, `<img src='${icon}' width="100%" height="100%">`)
|
||||||
|
@ -320,10 +320,9 @@ async function main(): Promise<void> {
|
||||||
writeFile(manifestLocation, manif, err);
|
writeFile(manifestLocation, manif, err);
|
||||||
|
|
||||||
// Create a landing page for the given theme
|
// Create a landing page for the given theme
|
||||||
createLandingPage(layout, manifest, whiteIcons, alreadyWritten).then(landing => {
|
const landing = await createLandingPage(layout, manifest, whiteIcons, alreadyWritten)
|
||||||
writeFile(enc(layout.id) + ".html", landing, err)
|
writeFile(enc(layout.id) + ".html", landing, err)
|
||||||
});
|
await createIndexFor(layout)
|
||||||
createIndexFor(layout)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -71,7 +71,7 @@ self.addEventListener('fetch',
|
||||||
event.respondWith(new Response(JSON.stringify({"service-worker-version": version})));
|
event.respondWith(new Response(JSON.stringify({"service-worker-version": version})));
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const shouldBeCached = origin.host === requestUrl.host && origin.host !== "127.0.0.1:1234" && origin.host !== "localhost" && !origin.host.endsWith(".gitpod.io")
|
const shouldBeCached = origin.host === requestUrl.host && origin.hostname !== "127.0.0.1" && origin.hostname !== "localhost" && !origin.host.endsWith(".gitpod.io")
|
||||||
if (!shouldBeCached) {
|
if (!shouldBeCached) {
|
||||||
console.log("Not intercepting ", requestUrl.toString(), origin.host, requestUrl.host)
|
console.log("Not intercepting ", requestUrl.toString(), origin.host, requestUrl.host)
|
||||||
// We return _without_ calling event.respondWith, which signals the browser that it'll have to handle it himself
|
// We return _without_ calling event.respondWith, which signals the browser that it'll have to handle it himself
|
||||||
|
|
Loading…
Reference in a new issue