From 343207fc357a88f0bfaf8b35848b27e6c5c7f5ec Mon Sep 17 00:00:00 2001 From: Simon Huber Date: Sun, 8 Nov 2020 23:38:08 +0100 Subject: [PATCH] MenuBar: Add fallback value to breakpoint-plus-one and ... (#5009) * Add fallback value to breakpoint-plus-one and ... ... sidebarbreakpoint-minus-one in case that widths aren't given in px units * Update styles.tid --- plugins/tiddlywiki/menubar/styles.tid | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/tiddlywiki/menubar/styles.tid b/plugins/tiddlywiki/menubar/styles.tid index 2914e85bf..b33e805c8 100644 --- a/plugins/tiddlywiki/menubar/styles.tid +++ b/plugins/tiddlywiki/menubar/styles.tid @@ -2,11 +2,11 @@ title: $:/plugins/tiddlywiki/menubar/styles tags: [[$:/tags/Stylesheet]] \define breakpoint-plus-one() -<$text text={{{ [{$:/config/plugins/menubar/breakpoint}removesuffix[px]add[1]addsuffix[px]] }}} /> +<$text text={{{ [{$:/config/plugins/menubar/breakpoint}removesuffix[px]add[1]addsuffix[px]] ~[{$:/config/plugins/menubar/breakpoint}] }}} /> \end \define sidebarbreakpoint-minus-one() -<$text text={{{ [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] }}} /> +<$text text={{{ [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] ~[{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}] }}} /> \end \define set-sidebar-scrollable-top-if-hamburger() @@ -61,7 +61,7 @@ nav.tc-menubar ul.tc-menubar-list { <> } -@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) { +@media (max-width: <>) { html nav.tc-menubar ul.tc-menubar-list { padding: 0 0 0 8px;