Skip to content

Commit

Permalink
Rich PWA support
Browse files Browse the repository at this point in the history
aryanpingle committed Jun 24, 2022
1 parent 570f96f commit ba9264c
Showing 10 changed files with 76 additions and 5 deletions.
Binary file modified Assets/Images/favicon-opaque.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/screenshots/hbd-isaac.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/screenshots/home.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/screenshots/horizon-dlc.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/images/screenshots/horizon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -19,6 +19,12 @@
<meta name="author" content="Aryan Pingle">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<!-- PWA -->
<link rel="shortcut icon" href="/assets/images/favicon-62.png" type="image/PNG">
<meta name="theme-color" content="#121212">
<link rel="apple-touch-icon" href="/assets/images/logos/favicon-opaque.png">
<link rel="manifest" href="manifest.json">

<!-- Twitter -->
<meta property="twitter:card" content="summary">
<meta property="twitter:creator" content="@aryan_pingle">
53 changes: 53 additions & 0 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"short_name": "Apollo Archive",
"name": "Apollo Archive",
"start_url": "/",
"display": "standalone",
"background_color": "#121212",
"theme_color": "#121212",
"description": "A database of all lore-related collectibles in the 'Horizon' video game franchise - in Horizon: Zero Dawn, and the DLC Horizon: The Frozen Wilds\n\nWorks Offline • Skeumorphic desktop UI that mirrors the in-game menu • (NEW) Supports The Frozen Wilds DLC",
"icons": [
{
"src": "/assets/images/favicon-opaque.png",
"type": "image/png",
"sizes": "660x660",
"purpose": "any"
},
{
"src": "/assets/images/favicon-opaque.png",
"type": "image/png",
"sizes": "660x660",
"purpose": "maskable"
}
],
"screenshots": [
{
"src": "/assets/images/screenshots/home.png",
"type": "image/png",
"sizes": "562x1218",
"platform": "android",
"label": "Description"
},
{
"src": "/assets/images/screenshots/horizon.png",
"type": "image/png",
"sizes": "562x1218",
"platform": "android",
"label": "Description"
},
{
"src": "/assets/images/screenshots/hbd-isaac.png",
"type": "image/png",
"sizes": "562x1218",
"platform": "android",
"label": "Description"
},
{
"src": "/assets/images/screenshots/horizon-dlc.png",
"type": "image/png",
"sizes": "562x1218",
"platform": "android",
"label": "Description"
}
]
}
10 changes: 5 additions & 5 deletions sw.js
Original file line number Diff line number Diff line change
@@ -5,13 +5,13 @@
// Suck it WorkboxJS //
///////////////////////////////////

const APP_VERSION = 6.00
const APP_VERSION = 6.10

// Document Cache is a cache of document files - html, js, css, etc
const DOCUMENT_CACHE_NAME = `DOC`
var DOCUMENT_CACHE = null
// Resource Cache is a cache of almost always static resources - images, fonts, and everything in the Texts folder
const RESOURCE_VERSION = 6.00
const RESOURCE_VERSION = 6.10
const RESOURCE_CACHE_NAME = `RESv${RESOURCE_VERSION.toFixed(2)}`
var RESOURCE_CACHE = null

@@ -21,9 +21,9 @@ String.prototype.containsAny = function (substrings=[]) {
}

// For Debugging
STOP_CACHING = self.registration.scope.includes("127.0.0.1")
var log = (text, color="white") => console.log(`%c${text}`, `color: black; background-color: ${color};`)
log = e => e // Comment for testing
IS_TESTING = self.registration.scope.includes("127.0.0.1")
STOP_CACHING = IS_TESTING
var log = (text, color="white") => IS_TESTING ? console.log(`%c${text}`, `color: black; background-color: ${color};`) : 0

self.addEventListener("install", event => {
event.waitUntil((async () => {
6 changes: 6 additions & 0 deletions zero-dawn/index.html
Original file line number Diff line number Diff line change
@@ -20,6 +20,12 @@
<meta name="author" content="Aryan Pingle">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<!-- PWA -->
<link rel="shortcut icon" href="/assets/images/favicon-62.png" type="image/PNG">
<meta name="theme-color" content="#121212">
<link rel="apple-touch-icon" href="/assets/images/logos/favicon-opaque.png">
<link rel="manifest" href="manifest.json">

<!-- Twitter -->
<meta property="twitter:card" content="summary">
<meta property="twitter:creator" content="@aryan_pingle">
6 changes: 6 additions & 0 deletions zero-dawn/the-frozen-wilds/index.html
Original file line number Diff line number Diff line change
@@ -19,6 +19,12 @@
<meta name="keywords" content="Horizon DLC: The Frozen Wilds, The Apollo Archive, Datapoints, Horizon Collectibles">
<meta name="author" content="Aryan Pingle">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<!-- PWA -->
<link rel="shortcut icon" href="/assets/images/favicon-62.png" type="image/PNG">
<meta name="theme-color" content="#121212">
<link rel="apple-touch-icon" href="/assets/images/logos/favicon-opaque.png">
<link rel="manifest" href="manifest.json">

<!-- Twitter -->
<meta property="twitter:card" content="summary">

0 comments on commit ba9264c

Please sign in to comment.