Tweaks to themes

And shaking out some paragraph tags in the sidebar
This commit is contained in:
Jermolene 2014-04-14 18:37:09 +01:00
parent aa243e4478
commit fe0ed5e4ce
7 changed files with 77 additions and 23 deletions

View File

@ -46,6 +46,13 @@ background-image: -ms-linear-gradient($gradient$);
\define datauri(title)
<$macrocall $name="makedatauri" type={{$title$!!type}} text={{$title$}}/>
\end
\define if-sidebar(text)
<$reveal state="$:/state/sidebar" type="match" text="yes" default="yes">$text$</$reveal>
\end
\define if-no-sidebar(text)
<$reveal state="$:/state/sidebar" type="nomatch" text="yes" default="yes">$text$</$reveal>
\end
<$list filter="[all[tiddlers+shadows]tag[$:/tags/stylesheet]]">
<$transclude/>

View File

@ -2,14 +2,37 @@ title: $:/core/ui/PageTemplate/sidebar
tags: $:/tags/PageTemplate
<$scrollable fallthrough="no" class="tw-sidebar-scrollable">
<div class="sidebar-header">
<$reveal state="$:/state/sidebar" type="match" text="yes" default="yes" retain="yes">
<div class="tw-site-title">{{$:/SiteTitle}}</div>
<div class="tw-site-subtitle">{{$:/SiteSubtitle}}</div>
<div class="tw-page-controls">
<$list filter="[all[tiddlers+shadows]tag[$:/tags/PageControls]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
</div>
{{$:/core/ui/SideBarLists}}
</$reveal>
</div>
<div class="sidebar-header">
<$reveal state="$:/state/sidebar" type="match" text="yes" default="yes" retain="yes">
<div class="tw-site-title">
<$transclude tiddler="$:/SiteTitle" mode="inline"/>
</div>
<div class="tw-site-subtitle">
<$transclude tiddler="$:/SiteSubtitle" mode="inline"/>
</div>
<div class="tw-page-controls">
<$list filter="[all[tiddlers+shadows]tag[$:/tags/PageControls]!has[draft.of]]" variable="listItem">
<$transclude tiddler=<<listItem>> mode="inline"/>
</$list>
</div>
<$transclude tiddler="$:/core/ui/SideBarLists" mode="inline"/>
</$reveal>
</div>
</$scrollable>

View File

@ -2,5 +2,7 @@ title: $:/core/ui/PageTemplate/topleftbar
tags: $:/tags/PageTemplate
<span class="tw-topbar tw-topbar-left">
<$list filter="[all[tiddlers+shadows]tag[$:/tags/TopLeftBar]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
</span>

View File

@ -2,5 +2,7 @@ title: $:/core/ui/PageTemplate/toprightbar
tags: $:/tags/PageTemplate
<span class="tw-topbar tw-topbar-right">
<$list filter="[all[tiddlers+shadows]tag[$:/tags/TopRightBar]!has[draft.of]]" variable="listItem"><$transclude tiddler=<<listItem>>/></$list>
</span>

View File

@ -1,8 +1,4 @@
title: $:/editions/tw5.com/github-fork-ribbon
tags: $:/tags/PageControls
<div class="github-fork-ribbon-wrapper right" style>
<div class="github-fork-ribbon" style="background-color:#FFBB3D;"><$link to="ReleaseHistory"><<version>></$link></div>
</div>
<div class="github-fork-ribbon-wrapper right" style><div class="github-fork-ribbon" style="background-color:#FFBB3D;"><$link to="ReleaseHistory"><<version>></$link></div></div>

View File

@ -3,6 +3,10 @@ tags: [[$:/tags/stylesheet]]
\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline
/*
Rules copied from Snow White
*/
.tw-page-controls button svg, .tw-tiddler-controls button svg, .tw-topbar button svg {
<<transition "fill 150ms ease-in-out">>
}
@ -50,26 +54,49 @@ tags: [[$:/tags/stylesheet]]
<<box-shadow "1px 1px 3px rgba(0,0,0,0.5)">>
}
/*
Seamless modifications
*/
@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics##storywidth}}) {
<<if-sidebar "
/* Drop the tiddler frame padding */
body.tw-body .tw-tiddler-frame {
padding: 0;
}
">>
/* Move the sidebar up so that the title lines up */
body.tw-body .tw-sidebar-scrollable {
padding: 57px 0 28px 42px;
padding: 43px 0 28px 42px;
}
/* Stop the tiddler info panel from bleeding into the tiddler frame padding */
body.tw-body .tw-tiddler-info {
margin: 0;
}
/* Stop message boxes from bleeding into the tiddler frame padding */
body.tw-body .tw-message-box {
margin: 21px 0 21px 0;
}
}
/* Use the tiddler background colour for the page background */
html body.tw-body {
background-color: <<colour background>>;
}
/* Adjust the colour of the page controls */
body.tw-body .tw-page-controls svg {
fill: <<colour muted-foreground>>;
}
/* Adjust the colour of the sidebar selected tabs */
body.tw-body .tw-sidebar-lists .tw-tab-buttons button.tw-tab-selected {
background-color: <<colour background>>;
}

View File

@ -1,9 +1,6 @@
title: $:/themes/tiddlywiki/vanilla/base
tags: [[$:/tags/stylesheet]]
\define if-no-sidebar(text)
<$reveal state="$:/state/sidebar" type="nomatch" text="yes" default="yes">$text$</$reveal>
\end
\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline
/*
** Start with the normalize CSS reset, and then belay some of its effects
@ -456,7 +453,7 @@ a.tw-tiddlylink-external:hover {
overflow-x: auto;
-webkit-overflow-scrolling: touch;
margin: 0 0 0 -42px;
padding: 84px 0 28px 42px;
padding: 71px 0 28px 42px;
}
.story-river {
@ -467,12 +464,11 @@ a.tw-tiddlylink-external:hover {
padding: 42px 42px 42px 42px;
}
<<if-no-sidebar "
.story-river {
width: auto;
padding: 0;
}
">>
@ -543,7 +539,8 @@ a.tw-tiddlylink-external:hover {
<<if-no-sidebar "
.tw-tiddler-frame {
width: auto;
width: 100%;
margin-bottom: 0;
}
">>