added user config for dark mode and navigation

This commit is contained in:
Brian McGonagill 2024-07-25 10:25:56 -05:00
parent 1d7ecc3efa
commit 40af926104
7 changed files with 82 additions and 16 deletions

View file

@ -9,7 +9,7 @@ Template.MainLayout.onRendered(function() {
let myId = Meteor.userId();
let myprefs = UserConfig.findOne({ user: myId });
if (typeof myprefs != 'undefined') {
if (myprefs.darkPref == "light") {
if (myprefs.darkMode == "light") {
console.log("Found theme as light");
// Session.set("myTheme", "light");
document.documentElement.setAttribute('theme', "light");