mirror of
https://github.com/zadam/trilium.git
synced 2025-11-10 00:19:04 +01:00
client: rework max content width handling
This commit is contained in:
parent
e510653edb
commit
1ef03b7a77
@ -1809,12 +1809,15 @@ body:not(.mobile) #launcher-pane.horizontal .dropdown-submenu > .dropdown-menu {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.note-split {
|
.note-split {
|
||||||
|
/* Limits the maximum width of the note */
|
||||||
|
--max-content-width: var(--preferred-max-content-width);
|
||||||
|
|
||||||
margin-inline-start: auto;
|
margin-inline-start: auto;
|
||||||
margin-inline-end: auto;
|
margin-inline-end: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.note-split.full-content-width {
|
.note-split.full-content-width {
|
||||||
max-width: 999999px;
|
--max-content-width: unset;
|
||||||
}
|
}
|
||||||
|
|
||||||
button.close:hover {
|
button.close:hover {
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
.note-list-widget {
|
.note-list-widget {
|
||||||
min-height: 0;
|
min-height: 0;
|
||||||
|
max-width: var(--max-content-width); /* Inherited from .note-split */
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
contain: none !important;
|
contain: none !important;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -39,6 +39,7 @@ const TPL = /*html*/`
|
|||||||
<div class="note-detail">
|
<div class="note-detail">
|
||||||
<style>
|
<style>
|
||||||
.note-detail {
|
.note-detail {
|
||||||
|
max-width: var(--max-content-width); /* Inherited from .note-split */
|
||||||
font-family: var(--detail-font-family);
|
font-family: var(--detail-font-family);
|
||||||
font-size: var(--detail-font-size);
|
font-size: var(--detail-font-size);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -29,8 +29,8 @@
|
|||||||
<%- include("./partials/windowGlobal.ejs", locals) %>
|
<%- include("./partials/windowGlobal.ejs", locals) %>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.note-split {
|
:root {
|
||||||
max-width: <%= maxContentWidth %>px;
|
--preferred-max-content-width: <%= maxContentWidth %>px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user