From 62fa7aa368496d6cec3f18bc1aac515386476b6d Mon Sep 17 00:00:00 2001 From: Ylian Saint-Hilaire Date: Mon, 12 Nov 2018 18:36:20 -0800 Subject: [PATCH] Added html hover on some elements of the web application --- meshcentral.js | 11 ++++-- package.json | 2 +- public/styles/style.css | 30 +++++++++++++++ views/default.handlebars | 79 +++++++++++++++++++++++++--------------- 4 files changed, 89 insertions(+), 33 deletions(-) diff --git a/meshcentral.js b/meshcentral.js index fc9a0397..ff047a30 100644 --- a/meshcentral.js +++ b/meshcentral.js @@ -368,7 +368,7 @@ function CreateMeshCentralServer(config, args) { obj.updateMeshCore(); obj.updateMeshCmd(); - // Setup and start the redirection server if needed + // Setup and start the redirection server if needed. We must start the redirection server before Let's Encrypt. if ((obj.args.redirport != null) && (typeof obj.args.redirport == 'number') && (obj.args.redirport != 0)) { obj.redirserver = require('./redirserver.js').CreateRedirServer(obj, obj.db, obj.args, obj.StartEx2); } else { @@ -383,7 +383,7 @@ function CreateMeshCentralServer(config, args) { // Load server certificates obj.certificateOperations = require('./certoperations.js').CertificateOperations(); obj.certificateOperations.GetMeshServerCertificate(obj, obj.args, obj.config, function (certs) { - if (obj.config.letsencrypt == null) { + if ((obj.config.letsencrypt == null) || (obj.redirserver == null)) { obj.StartEx3(certs); // Just use the configured certificates } else { var le = require('./letsencrypt.js'); @@ -448,7 +448,12 @@ function CreateMeshCentralServer(config, args) { var i; // If the certificate is un-configured, force LAN-only mode - if (obj.certificates.CommonName == 'un-configured') { console.log('Server name not configured, running in LAN-only mode.'); obj.args.lanonly = true; } + if (obj.certificates.CommonName == 'un-configured') { /*console.log('Server name not configured, running in LAN-only mode.');*/ obj.args.lanonly = true; } + + // Write server version and run mode + var productionMode = (process.env.NODE_ENV && (process.env.NODE_ENV == 'production')); + var runmode = (obj.args.lanonly ? 2 : (obj.args.wanonly ? 1 : 0)); + console.log('MeshCentral v' + obj.currentVer + ', ' + (['Hybrid (LAN + WAN) mode', 'WAN mode', 'LAN mode'][runmode]) + (productionMode ? ', Production mode.' : '.')); // Check that no sub-domains have the same DNS as the parent for (i in obj.config.domains) { diff --git a/package.json b/package.json index 18200b2a..58be3beb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "meshcentral", - "version": "0.2.2-u", + "version": "0.2.2-v", "keywords": [ "Remote Management", "Intel AMT", diff --git a/public/styles/style.css b/public/styles/style.css index 96f9c411..c3896a34 100644 --- a/public/styles/style.css +++ b/public/styles/style.css @@ -281,6 +281,24 @@ a { font-weight: bold; } +.style3x { + text-align: center; + color: white; + background-color: #808080; + font-weight: bold; +} + + .style3x:hover { + background-color: #606060; + } + +.style3sel { + text-align: center; + color: white; + background-color: #003366; + font-weight: bold; +} + .style4 { color: white; text-decoration: none; @@ -402,6 +420,10 @@ a { background-attachment: scroll; } +.g1s { + background-image: linear-gradient(to right, #ffffff 0%, #b9b9b9 100%); +} + .g2 { background-position: 0% 0%; width: 14px; @@ -416,6 +438,10 @@ a { background-attachment: scroll; } +.g2s { + background-image: linear-gradient(to right, #b9b9b9 0%, #ffffff 100%); +} + .h1 { background-position: 0% 0%; width: 14px; @@ -458,6 +484,10 @@ a { background-color: #c9c9c9; } +.e2s { + background-color: #b9b9b9; +} + .bar { font-size: large; background-color: #C9C9C9; diff --git a/views/default.handlebars b/views/default.handlebars index 430ef0a5..19e975b7 100644 --- a/views/default.handlebars +++ b/views/default.handlebars @@ -95,25 +95,25 @@ - - - - - - + + + + + +