Skip to content

Build your personal knowledge base with Trilium Notes

split UI to 3 different font sizes #326

azivner424c22dcdea3
diff --git a/src/public/stylesheets/desktop.css b/src/public/stylesheets/desktop.css
index 174c004c71..b1287d0d6c 100644
--- a/src/public/stylesheets/desktop.css
+++ b/src/public/stylesheets/desktop.css
@@ -1,3 +1,7 @@
+body {
+ font-size: var(--main-font-size);
+}
+
#container {
margin: 0 auto; /* center */
height: 100vh;
@@ -26,6 +30,7 @@
flex-shrink: 1;
flex-basis: 60%;
margin-top: 10px;
+ font-size: var(--tree-font-size);
}
#left-pane {
@@ -85,4 +90,8 @@
margin-top: 2px;
border-width: 1px;
border-style: solid;
+}
+
+#note-detail-wrapper {
+ font-size: var(--detail-font-size);
}
\ No newline at end of file
diff --git a/src/public/stylesheets/style.css b/src/public/stylesheets/style.css
index 61f7899d4a..91d92692d0 100644
--- a/src/public/stylesheets/style.css
+++ b/src/public/stylesheets/style.css
@@ -1,4 +1,8 @@
:root {
+ --main-font-size: normal;
+ --tree-font-size: normal;
+ --detail-font-size: normal;
+
--main-background-color: white;
--main-text-color: black;
--accented-background-color: #eee;
@@ -20,7 +24,7 @@
--menu-background-color: white;
}
-html.theme-black {
+body.theme-black {
--main-background-color: black;
--main-text-color: white;
--accented-background-color: #222;
@@ -42,7 +46,7 @@ html.theme-black {
--menu-background-color: #222;
}
-html.theme-black .CodeMirror {
+body.theme-black .CodeMirror {
filter: invert(100%) hue-rotate(180deg);
}
@@ -167,8 +171,6 @@ ul.fancytree-container {
display: none;
}
-#note-detail-text { font-size: 1.1em; }
-
#note-detail-text h1 { font-size: 2.0em; }
#note-detail-text h2 { font-size: 1.8em; }
#note-detail-text h3 { font-size: 1.6em; }
diff --git a/src/views/desktop.ejs b/src/views/desktop.ejs
index 203e2bafe2..b7faa90536 100644
--- a/src/views/desktop.ejs
+++ b/src/views/desktop.ejs
@@ -1,10 +1,10 @@
<!DOCTYPE html>
-<html lang="en" class="theme-<%= theme %>">
+<html lang="en">
<head>
<meta charset="utf-8">
<title>Trilium Notes</title>
</head>
-<body class="desktop">
+<body class="desktop theme-<%= theme %>">
<div id="container" style="display: none; grid-template-columns: minmax(<%= leftPaneMinWidth %>px, <%= leftPaneWidthPercent %>fr) <%= rightPaneWidthPercent %>fr">
<div id="header" class="hide-toggle">
<div id="history-navigation" style="display: none;">