Dave wrote:
>
> Mat,
>
> Did you ever get the this left menu to stick instead of scroll with the
> rest of the tiddler story?
>
Very funny you should ask - I made exactly that a mere few days ago!!! I
have not yet put it into the official leftbar site because it is not
polished and I'm not sure it is a good UI (it shows a button to easily
switch between fixed/notfixed).
Here is the basic code. I'm currently too much in a hurry and too
morning-confused to recall or investigate if it required anything more than
this code. Tell me if it works for you:
title:LeftBar
tags: $:/LeftBar
<$reveal type="nomatch"
state="$:/.TWaddle/LeftBar/Reveal!!position" text="absolute">
<$button set="$:/.TWaddle/LeftBar/Reveal!!position"
setTo="absolute"
class="tc-btn-invisible">
⦿
</$button></$reveal>
<$reveal type="match"
state="$:/.TWaddle/LeftBar/Reveal!!position" text="absolute">
<$button set="$:/.TWaddle/LeftBar/Reveal!!position"
setTo="fixed"
class="tc-btn-invisible">
⦾
</$button>
</$reveal>[[LeftBar]]<br>
<$edit-text tiddler="$:/.TWaddle/LeftBar/StyleSheet" field="width"/>
<<list-links "[tag[LeftBar]]">>
And here's the stylesheet... which I assume I must have changed for this
but can't quite remember ATM:
title: $:/.TWaddle/LeftBar/StyleSheet
tags: $:/tags/Stylesheet
html .tc-story-river {
position: absolute;
width:auto;
z-index: 999;
}
.leftbarpin {display:}
.tc-leftbar-scrollable {
position:{{$:/.TWaddle/LeftBar/Reveal!!position}}; top:-2em;
left:0;
overflow-y: hidden;
overflow-x: hidden;
-webkit-overflow-scrolling: touch;
margin: 0 0 0 0px;
}
<<if-no-leftbar "
html .tc-story-river { padding-left: 42px; left:
{{$:/themes/tiddlywiki/vanilla/metrics/storyleft}}; }
.tc-leftbar-scrollable { width: 0; padding:0; }
">>
<<if-leftbar """
.tc-leftbar-scrollable { width: {{!!width}}; padding:{{!!padding}}; }
.tc-sidebar-scrollable { left:calc({{!!width}} +
{{$:/themes/tiddlywiki/vanilla/metrics/storyright}}); margin-left:-84px; }
.tc-story-river { left: {{!!width}}; margin-right:0px; padding-left: 0em;
padding-right:42px; }
""">>
<<if-sidebar "
.tc-story-river { width:
calc({{$:/themes/tiddlywiki/vanilla/metrics/storyright}} - {{!!width}} ); }
">>
<<if-no-sidebar "
.tc-story-river { right:0; }
">>
<:-)
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/d0876967-9b1a-459d-9c50-20824d2a9ef8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.