Add a webmanifest

This commit is contained in:
Lucas Verney 2018-06-27 22:51:50 +02:00
parent 57bf538325
commit e682c9818e
11 changed files with 106 additions and 1 deletions

View File

@ -63,6 +63,11 @@ const devWebpackConfig = merge(baseWebpackConfig, {
from: path.resolve(__dirname, '../static'),
to: config.dev.assetsSubDirectory,
ignore: ['.*']
},
{
from: path.resolve(__dirname, '../manifest.webmanifest'),
to: config.build.assetsRoot,
ignore: ['.*']
}
])
]

View File

@ -46,7 +46,7 @@ const webpackConfig = merge(baseWebpackConfig, {
filename: utils.assetsPath('css/[name].[contenthash].css'),
// Setting the following option to `false` will not extract CSS from codesplit chunks.
// Their CSS will instead be inserted dynamically with style-loader when the codesplit chunk has been loaded by webpack.
// It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`,
// It's currently set to `true` because we are seeing that sourcemaps are included in the codesplit bundle as well when it's `false`,
// increasing file size: https://github.com/vuejs-templates/webpack/issues/1110
allChunks: true,
}),
@ -114,6 +114,11 @@ const webpackConfig = merge(baseWebpackConfig, {
from: path.resolve(__dirname, '../static'),
to: config.build.assetsSubDirectory,
ignore: ['.*']
},
{
from: path.resolve(__dirname, '../manifest.webmanifest'),
to: config.build.assetsRoot,
ignore: ['.*']
}
])
]

View File

@ -3,6 +3,8 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="manifest" href="manifest.webmanifest">
<link rel="shortcut icon" type="image/png" href="static/icon192.png">
<title>cyclassist</title>
</head>
<body>

39
manifest.webmanifest Normal file
View File

@ -0,0 +1,39 @@
{
"name": "Cyclassist",
"short_name": "Cyclassist",
"description": "Report and share issues with bike routes!",
"start_url": ".",
"display": "standalone",
"icons": [
{
"src": "static/icon48.png",
"sizes": "48x48",
"type": "image/png"
},
{
"src": "static/icon72.png",
"sizes": "72x72",
"type": "image/png"
},
{
"src": "static/icon96.png",
"sizes": "96x96",
"type": "image/png"
},
{
"src": "static/icon144.png",
"sizes": "144x144",
"type": "image/png"
},
{
"src": "static/icon168.png",
"sizes": "168x168",
"type": "image/png"
},
{
"src": "static/icon192.png",
"sizes": "192x192",
"type": "image/png"
}
]
}

54
static/icon.svg Normal file
View File

@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
id="svg8"
version="1.1"
viewBox="0 0 50.799999 50.800002"
height="192"
width="192">
<defs
id="defs2" />
<metadata
id="metadata5">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
transform="translate(0,-246.19998)"
id="layer1">
<g
transform="matrix(0.60218115,0,0,0.60218115,2.6432865,249.18067)"
id="g1611">
<path
style="fill:none"
d="M 0,0 48,0 48,48 0,48 Z"
id="path1597" />
<path
style="fill:#231f20;fill-opacity:1"
d="m 32,9.6 c 1.98,0 3.6,-1.61 3.6,-3.6 0,-1.99 -1.62,-3.6 -3.6,-3.6 -1.99,0 -3.6,1.61 -3.6,3.6 0,1.99 1.61,3.6 3.6,3.6 z M 38,24 c -5.52,0 -10,4.48 -10,10 0,5.52 4.48,10 10,10 5.52,0 10,-4.48 10,-10 0,-5.52 -4.48,-10 -10,-10 z m 0,17 c -3.87,0 -7,-3.13 -7,-7 0,-3.87 3.13,-7 7,-7 3.87,0 7,3.13 7,7 0,3.87 -3.13,7 -7,7 z m -8.4,-21 8.4,0 0,-3.6 -6.4,0 -3.87,-6.53 C 27.14,8.87 26.05,8.2 24.8,8.2 c -0.94,0 -1.79,0.38 -2.4,1 L 15,16.59 c -0.62,0.62 -1,1.47 -1,2.41 0,1.26 0.67,2.32 1.7,2.94 l 6.7,4.06 0,10 3.6,0 0,-12.96 -4.5,-3.34 4.64,-4.66 z M 10,24 C 4.48,24 0,28.48 0,34 0,39.52 4.48,44 10,44 15.52,44 20,39.52 20,34 20,28.48 15.52,24 10,24 Z m 0,17 c -3.87,0 -7,-3.13 -7,-7 0,-3.87 3.13,-7 7,-7 3.87,0 7,3.13 7,7 0,3.87 -3.13,7 -7,7 z"
id="path1599" />
</g>
<g
transform="matrix(1.0442734,0,0,1.0442734,24.587076,272.65832)"
id="g4296">
<path
style="fill:none"
d="M 0,0 24,0 24,24 0,24 Z"
id="path4286" />
<path
d="M 1,21 23,21 12,2 1,21 Z m 12,-3 -2,0 0,-2 2,0 0,2 z m 0,-4 -2,0 0,-4 2,0 0,4 z"
id="path4288" />
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 2.1 KiB

BIN
static/icon144.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

BIN
static/icon168.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

BIN
static/icon192.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

BIN
static/icon48.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
static/icon72.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

BIN
static/icon96.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB