mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-03-12 14:38:10 +00:00
updates for sidebarbreakpoint
This commit is contained in:
parent
0c5de5515a
commit
3021154bc3
@ -1,6 +1,24 @@
|
||||
title: $:/core/functions/themes
|
||||
tags: $:/tags/Global
|
||||
|
||||
\function is.pixel.value(value) [<value>removesuffix[px]]
|
||||
\function is.percentage.value(value) [<value>removesuffix[%]]
|
||||
\function is.cm.value(value) [<value>removesuffix[cm]]
|
||||
\function is.mm.value(value) [<value>removesuffix[mm]]
|
||||
\function is.Q.value(value) [<value>removesuffix[Q]]
|
||||
\function is.in.value(value) [<value>removesuffix[in]]
|
||||
\function is.pc.value(value) [<value>removesuffix[pc]]
|
||||
\function is.pt.value(value) [<value>removesuffix[pt]]
|
||||
\function is.em.value(value) [<value>removesuffix[em]]
|
||||
|
||||
\function convert.to.pixels(value,metric) [<metric>match[cm]then<value>multiply[37.8]] [<metric>match[mm]then<value>multiply[37.8]divide[10]] [<metric>match[Q]then<value>multiply[37.8]divide[40]] [<metric>match[in]then<value>multiply[96]] [<metric>match[pc]then<value>multiply[96]divide[6]] [<metric>match[pt]then<value>multiply[96]divide[72]] [<metric>match[em]then<value>multiply{$:/themes/tiddlywiki/vanilla/metrics/fontsize}]
|
||||
|
||||
\function subtract.one.from.sidebarbreakpoint(value) [is.pixel.value<value>subtract[1]addsuffix[px]] :else[is.cm.value<value>function[convert.to.pixels],<value>,[cm]subtract[1]divide[37.8]addsuffix[cm]] :else[is.mm.value<value>function[convert.to.pixels],<value>,[mm]subtract[1]divide[37.8]multiply[10]addsuffix[mm]] :else[is.Q.value<value>function[convert.to.pixels],<value>,[Q]subtract[1]divide[37.8]multiply[40]addsuffix[Q]] :else[is.in.value<value>function[convert.to.pixels],<value>,[in]subtract[1]divide[96]addsuffix[in]] :else[is.pc.value<value>function[convert.to.pixels],<value>,[pc]subtract[1]divide[96]multiply[6]addsuffix[pc]] :else[is.pt.value<value>function[convert.to.pixels],<value>,[pt]subtract[1]divide[96]multiply[72]addsuffix[pt]] :else[is.em.value<value>function[convert.to.pixels],<value>,[em]subtract[1]divide{$:/themes/tiddlywiki/vanilla/metrics/fontsize}addsuffix[em]]
|
||||
|
||||
\function sidebarbreakpoint() [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}]
|
||||
|
||||
\function sidebarbreakpoint-minus-one() [function[subtract.one.from.sidebarbreakpoint],<sidebarbreakpoint>] :else[<sidebarbreakpoint>]
|
||||
|
||||
\function get.base.theme.metric.recursive(theme,metric) [<theme>get[dependents]enlist-input[]] :map[function[get.base.theme.metric],<currentTiddler>,<metric>]
|
||||
|
||||
\function get.base.theme.metric(theme,metric) [<theme>addsuffix[/metrics/]addsuffix<metric>!is[missing]] :else[<theme>addsuffix[/metrics/]addsuffix<metric>is[shadow]] :else[function[get.base.theme.metric.recursive],<theme>,<metric>]
|
||||
|
@ -1,15 +1,5 @@
|
||||
title: $:/core/macros/sidebar-resizer
|
||||
|
||||
\function is.pixel.value(value) [<value>removesuffix[px]]
|
||||
\function is.percentage.value(value) [<value>removesuffix[%]]
|
||||
\function is.cm.value(value) [<value>removesuffix[cm]]
|
||||
\function is.mm.value(value) [<value>removesuffix[mm]]
|
||||
\function is.Q.value(value) [<value>removesuffix[Q]]
|
||||
\function is.in.value(value) [<value>removesuffix[in]]
|
||||
\function is.pc.value(value) [<value>removesuffix[pc]]
|
||||
\function is.pt.value(value) [<value>removesuffix[pt]]
|
||||
\function is.em.value(value) [<value>removesuffix[em]]
|
||||
|
||||
\function convert.to.percentage(value) [<value>divide<widgetNodeWidth>multiply[100]]
|
||||
\function convert.to.cm(value) [<value>divide[37.8]]
|
||||
\function convert.to.mm(value) [convert.to.cm<value>multiply[10]]
|
||||
|
@ -1,10 +1,6 @@
|
||||
title: $:/themes/tiddlywiki/snowwhite/base
|
||||
tags: [[$:/tags/Stylesheet]]
|
||||
|
||||
\define sidebarbreakpoint-minus-one()
|
||||
<$text text={{{ [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] ~[{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}] }}}/>
|
||||
\end
|
||||
|
||||
\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline
|
||||
|
||||
.tc-sidebar-header {
|
||||
|
@ -3,10 +3,10 @@ tags: [[$:/tags/Stylesheet]]
|
||||
|
||||
\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline conditional
|
||||
|
||||
@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {
|
||||
@media (max-width: <<sidebarbreakpoint-minus-one>>) {
|
||||
}
|
||||
|
||||
@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {
|
||||
@media (min-width: <<sidebarbreakpoint>>) {
|
||||
|
||||
html body.tc-body {
|
||||
font-size: 13px;
|
||||
|
@ -23,14 +23,6 @@ background-size:` {{$:/themes/tiddlywiki/vanilla/settings/backgroundimagesize}}`
|
||||
</$set>
|
||||
\end
|
||||
|
||||
\define sidebarbreakpoint()
|
||||
<$text text={{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}/>
|
||||
\end
|
||||
|
||||
\define sidebarbreakpoint-minus-one()
|
||||
<$text text={{{ [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] ~[{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}] }}}/>
|
||||
\end
|
||||
|
||||
\define if-fluid-fixed(text,hiddenSidebarText)
|
||||
<$reveal state="$:/themes/tiddlywiki/vanilla/options/sidebarlayout" type="match" text="fluid-fixed">
|
||||
$text$
|
||||
@ -2318,7 +2310,8 @@ html body.tc-body.tc-single-tiddler-window {
|
||||
border-left: 1px solid <<colour tab-border>>;
|
||||
-webkit-flex: 1 0 70%;
|
||||
flex: 1 0 70%;
|
||||
overflow: auto;
|
||||
overflow-x: auto;
|
||||
overflow-y: hidden;
|
||||
}
|
||||
|
||||
.tc-sidebar-lists .tc-tab-buttons {
|
||||
|
@ -4,10 +4,6 @@ code-body: yes
|
||||
|
||||
\import [function[get.base.functions.theme],{$:/theme}first[]!is[missing]] :else[function[get.base.functions.theme],{$:/theme}first[]is[shadow]] :else[[$:/themes/tiddlywiki/vanilla/functions]]
|
||||
|
||||
\function sidebarbreakpoint() [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}]
|
||||
|
||||
\function sidebarbreakpoint-minus-one() [{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}removesuffix[px]subtract[1]addsuffix[px]] ~[{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}]
|
||||
|
||||
\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline macrocallblock conditional
|
||||
|
||||
@media (min-width: <<sidebarbreakpoint>>) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user