Skip to content

Commit

Permalink
testing ios compatability
Browse files Browse the repository at this point in the history
  • Loading branch information
a456pur committed Aug 4, 2024
1 parent 4bb112e commit a8e057d
Show file tree
Hide file tree
Showing 6 changed files with 62 additions and 0 deletions.
21 changes: 21 additions & 0 deletions app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
self.addEventListener('install', event => {
event.waitUntil(
caches.open('app-cache').then(cache => {
return cache.addAll([
'/',
'/index.html',
'/assets/css/style.css',
'/assets/css/themes.css'
]);
})
);
});

self.addEventListener('fetch', event => {
event.respondWith(
caches.match(event.request).then(response => {
return response || fetch(event.request);
})
);
});

Binary file added images/icons/seraphim-192.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 images/icons/seraphim-512.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 images/icons/seraphim.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,13 @@
<meta property="og:title" content="seraph">
<meta property="og:type" content="website">
<meta property="og:description" content="seraph; an open source unblocked apps website hosting 250+ apps with downloadable support, a clean and centralised user interface and no iframe embedding">

<link rel="manifest" href="/manifest.json">

<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
<link rel="apple-touch-icon" href="images/icons/seraphim-192.png">

</head>
<body>

Expand Down Expand Up @@ -207,5 +214,18 @@ <h3>cloak</h3>

<script src="assets/js/seraphim.js"></script>
<script src="assets/js/cloak.js"></script>

<script>
if ('serviceWorker' in navigator) {
navigator.serviceWorker.register('/service-worker.js')
.then(registration => {
console.log('registered worker');
})
.catch(error => {
console.log('failed to register', error);
});
}

</script>
</body>
</html>
21 changes: 21 additions & 0 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"name": "seraphim",
"short_name": "seraphim",
"start_url": "/",
"display": "standalone",
"background_color": "#000000",
"theme_color": "#000000",
"icons": [
{
"src": "images/icons/seraphim-192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "images/icons/seraphim-512.png",
"sizes": "512x512",
"type": "image/png"
}
]
}

0 comments on commit a8e057d

Please sign in to comment.