diff --git a/docs/hexascript/css/styles.css b/docs/hexascript/css/styles.css index bc425d8..90c665c 100644 --- a/docs/hexascript/css/styles.css +++ b/docs/hexascript/css/styles.css @@ -1,6 +1,6 @@ body { background-color: #111111; - color: #cccccc; + color: var(--accent-primary); font-family: Consolas, "Courier New", monospace; line-height: 1.5; padding: 2rem; @@ -29,7 +29,7 @@ h2 { color: #ffaa00; - border-bottom: 1px solid #333333; + border-bottom: 1px solid var(--accent-primary); padding-bottom: 5px; margin-top: 0; } @@ -48,7 +48,7 @@ color: #ffffff; } small { - color: #777777; + color: var(--text-muted-alt)777; font-style: normal; } @@ -68,7 +68,7 @@ /* Box styling for top level items */ main > ul > li { background: #1a1a1a; - border: 1px solid #333333; + border: 1px solid var(--accent-primary); padding: 2em; margin-bottom: 2em; } @@ -95,5 +95,5 @@ /* Dim the bullet points and numbers */ li::marker { - color: #555555; + color: var(--accent-primary); } diff --git a/docs/hexascript/src/script.js b/docs/hexascript/src/script.js index 3f79199..44c1cdd 100644 --- a/docs/hexascript/src/script.js +++ b/docs/hexascript/src/script.js @@ -7,12 +7,12 @@ path.join(__dirname, "../../../../src/utils/processMenuLinks"), ); -const { winstonLogger } = require("../../../../src/utils/logging"); +const { logger } = require("../../../../src/utils/logging"); async function getContext(type, pathPrefix, navLink) { let filePath = null; let fileName = null; - let controllor; + let controller; let route; switch (type) { case "html": @@ -54,7 +54,7 @@ ? Promise.resolve(fs.readFile(filePath, "utf8")) : null; } catch (e) { - winstonLogger.error(e.stack); + logger.error(e.stack); } return { type, @@ -67,7 +67,7 @@ const rootPath = path.join("..", ".."); const layoutPath = path.join(rootPath, "src/views/layouts/main.handlebars"); const hbs = require("hbs"); -function controllor(context) { +function controller(context) { return (req, res) => { hbs.registerPartials(__dirname); const links = processMenuLinks(navLinks, req.isAuthenticated, req.path); @@ -96,33 +96,31 @@ // -- Frame Injection else if (navLink.frame) { context = getContext("frame", pathPrefix, navLink); - // winstonLogger.info(context); + // logger.info(context); } // -- Submenu else if (navLink.submenu) { // Loop again generateRouter(navLink.submenu, pathPrefix); - // winstonLogger.info(context); + // logger.info(context); } else { throw new Error("No options found", navLink); } - let route; - winstonLogger.info( - "Route: ", - context["route"], // If i remove await, the routes only appear in the line above - context.route, - ); + // let route; + // logger.info("Route: ", { + // debug: [context, context["route"], context.route], + // }); if (context.route) { route = path.join(pathPrefix, context.route); - router.get(route, controllor(context)); - winstonLogger.info(`Registered Route: ${route}`); + router.get(route, controller(context)); + logger.info(`Registered Route: ${route}`); } } catch (e) { - winstonLogger.error("Context: ", e); + logger.error("Context: ", e); } } - router.get("/", controllor({})); + router.get("/", controller({})); return router; }