mirror of
https://github.com/GNS3/gns3-web-ui.git
synced 2025-04-08 11:04:15 +00:00
Fonts&icons offline in electron app, Fixes: #94
This commit is contained in:
parent
99fceed253
commit
fe4cd9082b
11
main.js
11
main.js
@ -18,8 +18,10 @@ let isDev = false;
|
||||
const argv = yargs
|
||||
.describe('m', 'Maximizes window on startup.')
|
||||
.boolean('m')
|
||||
.describe('e', 'Environment, `dev` for developer mode and when not specified then production mode. ')
|
||||
.describe('e', 'Environment, `dev` for developer mode and when not specified then production mode.')
|
||||
.choices('e', ['dev', null])
|
||||
.describe('d', 'Enable developer tools.')
|
||||
.boolean('d')
|
||||
.argv;
|
||||
|
||||
if (argv.e == 'dev') {
|
||||
@ -75,7 +77,6 @@ function createWindow () {
|
||||
|
||||
if(isDev) {
|
||||
mainWindow.loadURL('http://localhost:4200/');
|
||||
mainWindow.webContents.openDevTools();
|
||||
}
|
||||
else {
|
||||
mainWindow.loadURL(url.format({
|
||||
@ -85,8 +86,10 @@ function createWindow () {
|
||||
}));
|
||||
}
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools();
|
||||
if(argv.d) {
|
||||
// Open the DevTools.
|
||||
mainWindow.webContents.openDevTools();
|
||||
}
|
||||
|
||||
if(argv.m) {
|
||||
mainWindow.maximize();
|
||||
|
@ -45,10 +45,12 @@
|
||||
"core-js": "^2.4.1",
|
||||
"d3-ng2-service": "^1.23.3",
|
||||
"electron-settings": "^3.1.4",
|
||||
"material-design-icons": "^3.0.1",
|
||||
"ngx-electron": "^1.0.4",
|
||||
"npm-check-updates": "^2.13.0",
|
||||
"raven-js": "^3.24.0",
|
||||
"rxjs": "^5.4.1",
|
||||
"typeface-roboto": "^0.0.54",
|
||||
"yargs": "^11.0.0",
|
||||
"zone.js": "^0.8.20"
|
||||
},
|
||||
|
@ -23,16 +23,6 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" type="image/x-icon" href="assets/favicon.ico">
|
||||
|
||||
<!--
|
||||
angular/angular-cli has an issue with handling imports with leading ~ (like: @import '~https://url.url';)
|
||||
#Ref. https://github.com/angular/angular-cli/issues/9181
|
||||
/* @TODO: make Material Icons self hosted */
|
||||
//-->
|
||||
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
|
||||
|
||||
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto:300,400,500,700" type="text/css">
|
||||
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto+Slab:400,700" type="text/css">
|
||||
|
||||
<script type="application/javascript">
|
||||
// Github Pages redirection
|
||||
(function(){
|
||||
|
@ -1,4 +1,6 @@
|
||||
@import '~@angular/material/theming';
|
||||
@import '~material-design-icons/iconfont/material-icons.css';
|
||||
@import '~typeface-roboto/index.css';
|
||||
|
||||
// Include non-theme styles for core.
|
||||
@include mat-core();
|
||||
|
@ -5380,6 +5380,10 @@ map-visit@^1.0.0:
|
||||
dependencies:
|
||||
object-visit "^1.0.0"
|
||||
|
||||
material-design-icons@^3.0.1:
|
||||
version "3.0.1"
|
||||
resolved "https://registry.yarnpkg.com/material-design-icons/-/material-design-icons-3.0.1.tgz#9a71c48747218ebca51e51a66da682038cdcb7bf"
|
||||
|
||||
md5.js@^1.3.4:
|
||||
version "1.3.4"
|
||||
resolved "https://registry.yarnpkg.com/md5.js/-/md5.js-1.3.4.tgz#e9bdbde94a20a5ac18b04340fc5764d5b09d901d"
|
||||
@ -8794,6 +8798,10 @@ typedarray@^0.0.6, typedarray@~0.0.5:
|
||||
version "0.0.6"
|
||||
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
|
||||
|
||||
typeface-roboto@^0.0.54:
|
||||
version "0.0.54"
|
||||
resolved "https://registry.yarnpkg.com/typeface-roboto/-/typeface-roboto-0.0.54.tgz#8f02c9a18d1cfa7f49381a6ff0d21ff061f38ad2"
|
||||
|
||||
"typescript@>=2.4.0 <2.6.0":
|
||||
version "2.5.3"
|
||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.5.3.tgz#df3dcdc38f3beb800d4bc322646b04a3f6ca7f0d"
|
||||
|
Loading…
x
Reference in New Issue
Block a user