feat: icon

This commit is contained in:
cha0s 2022-04-05 16:18:34 -05:00
parent 143052805e
commit b0a68d4e8c
4 changed files with 38 additions and 0 deletions

View File

@ -3,6 +3,7 @@
<head> <head>
<base href="/" /> <base href="/" />
<meta charset="utf-8"> <meta charset="utf-8">
<link rel="icon" type="image/png" href="/icon.png" />
<meta name="viewport" content="width=device-width, user-scalable=no" /> <meta name="viewport" content="width=device-width, user-scalable=no" />
<title>Humus</title> <title>Humus</title>
<style> <style>

21
build/web.neutrinorc.js Normal file
View File

@ -0,0 +1,21 @@
/* eslint-disable import/no-extraneous-dependencies */
const copy = require('@neutrinojs/copy');
module.exports = async (flecks) => {
// eslint-disable-next-line global-require
const config = await require('@flecks/web/server/build/web.neutrinorc')(flecks);
config.use.push(
copy({
copyUnmodified: true,
patterns: [
{
from: 'icon.png',
to: 'web/assets/icon.png',
},
],
}),
);
return config;
};

BIN
icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

View File

@ -0,0 +1,16 @@
import {join} from 'path';
import {Hooks} from '@flecks/core';
const {
FLECKS_CORE_ROOT = process.cwd(),
} = process.env;
export default {
[Hooks]: {
'@flecks/core.starting': (flecks) => {
const {browserWindowOptions} = flecks.get('@flecks/electron/server');
browserWindowOptions.icon = join(FLECKS_CORE_ROOT, 'icon.png');
},
},
};