Extend support for apple devices
Add option to specify special icons for apple devices because icons on apple devices are tailored to size differently
This commit is contained in:
@@ -60,6 +60,12 @@ PWA_APP_ICONS = [
|
|||||||
'sizes': '160x160'
|
'sizes': '160x160'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
PWA_APP_ICONS_APPLE = [
|
||||||
|
{
|
||||||
|
'src': '/static/images/my_apple_icon.png',
|
||||||
|
'sizes': '160x160'
|
||||||
|
}
|
||||||
|
]
|
||||||
PWA_APP_SPLASH_SCREEN = [
|
PWA_APP_SPLASH_SCREEN = [
|
||||||
{
|
{
|
||||||
'src': '/static/images/icons/splash-640x1136.png',
|
'src': '/static/images/icons/splash-640x1136.png',
|
||||||
|
|||||||
@@ -13,9 +13,16 @@
|
|||||||
<meta name="apple-mobile-web-app-capable" content="yes">
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||||
<meta name="apple-mobile-web-app-title" content="{{ PWA_APP_NAME }}">
|
<meta name="apple-mobile-web-app-title" content="{{ PWA_APP_NAME }}">
|
||||||
<meta name="apple-mobile-web-app-status-bar-style" content="default">
|
<meta name="apple-mobile-web-app-status-bar-style" content="default">
|
||||||
|
|
||||||
|
{% if PWA_APP_ICONS_APPLE %}
|
||||||
|
{% for icon in PWA_APP_ICONS_APPLE %}
|
||||||
|
<link rel="apple-touch-icon" href="{{ icon.src }}" sizes="{{ icon.size }}">
|
||||||
|
{% endfor %}
|
||||||
|
{% else %}
|
||||||
{% for icon in PWA_APP_ICONS %}
|
{% for icon in PWA_APP_ICONS %}
|
||||||
<link rel="apple-touch-icon" href="{{ icon.src }}" sizes="{{ icon.size }}">
|
<link rel="apple-touch-icon" href="{{ icon.src }}" sizes="{{ icon.size }}">
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
|
||||||
{% for splash in PWA_APP_SPLASH_SCREEN %}
|
{% for splash in PWA_APP_SPLASH_SCREEN %}
|
||||||
|
|||||||
Reference in New Issue
Block a user