use circle logo and cache fonts
This commit is contained in:
parent
2d8318633c
commit
9f8b9730bc
4 changed files with 35 additions and 3 deletions
|
@ -46,6 +46,8 @@
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
margin-right: 5px;
|
margin-right: 5px;
|
||||||
@include arrow(12px, -90deg, white);
|
@include arrow(12px, -90deg, white);
|
||||||
|
|
||||||
|
transition: border-color 400ms;
|
||||||
}
|
}
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
|
|
|
@ -21,9 +21,15 @@ module.exports = {
|
||||||
author: "Moritz Ruth",
|
author: "Moritz Ruth",
|
||||||
mobileAppIOS: false,
|
mobileAppIOS: false,
|
||||||
nativeUI: true,
|
nativeUI: true,
|
||||||
"short_name": "ctexxx",
|
shortName: "ctexxx",
|
||||||
"background_color": "#212121",
|
backgroundColor: "#212121",
|
||||||
"theme_color": "#212121"
|
themeColor: "#212121"
|
||||||
|
},
|
||||||
|
|
||||||
|
workbox: {
|
||||||
|
importScripts: [
|
||||||
|
"fontSW.js"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
24
static/fontSW.js
Normal file
24
static/fontSW.js
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
// Cache the Google Fonts stylesheets with a stale-while-revalidate strategy.
|
||||||
|
workbox.routing.registerRoute(
|
||||||
|
/^https:\/\/fonts\.googleapis\.com/,
|
||||||
|
new workbox.strategies.StaleWhileRevalidate({
|
||||||
|
cacheName: 'google-fonts-stylesheets',
|
||||||
|
})
|
||||||
|
);
|
||||||
|
|
||||||
|
// Cache the underlying font files with a cache-first strategy for 1 year.
|
||||||
|
workbox.routing.registerRoute(
|
||||||
|
/^https:\/\/fonts\.gstatic\.com/,
|
||||||
|
new workbox.strategies.CacheFirst({
|
||||||
|
cacheName: 'google-fonts-webfonts',
|
||||||
|
plugins: [
|
||||||
|
new workbox.cacheableResponse.Plugin({
|
||||||
|
statuses: [0, 200],
|
||||||
|
}),
|
||||||
|
new workbox.expiration.Plugin({
|
||||||
|
maxAgeSeconds: 60 * 60 * 24 * 365,
|
||||||
|
maxEntries: 30,
|
||||||
|
}),
|
||||||
|
],
|
||||||
|
})
|
||||||
|
);
|
BIN
static/icon.png
BIN
static/icon.png
Binary file not shown.
Before Width: | Height: | Size: 61 KiB After Width: | Height: | Size: 52 KiB |
Loading…
Add table
Add a link
Reference in a new issue