1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-12-28 02:50:27 +00:00

Tweaks to fold button

This commit is contained in:
Jermolene 2015-08-09 16:11:34 +01:00
parent 27ec05e521
commit 16c69bb419
5 changed files with 11 additions and 11 deletions

View File

@ -1,9 +1,10 @@
title: $:/core/images/fold-button
tags: $:/tags/Image
<svg class="tc-image-fold tc-image-button" width="22pt" height="22pt" viewBox="0 0 128 128">
<svg class="tc-image-unfold tc-image-button" width="22pt" height="22pt" viewBox="0 0 128 128">
<g fill-rule="evenodd">
<rect x="0" y="0" width="128" height="16" rx="8"></rect>
<path d="M40,118 L40,62.0000511 C40,57.5797863 36.418278,54 32,54 C27.5907123,54 24,57.5817449 24,62.0000511 L24,125.999949 C24,130.409288 27.5817449,134 32.0000511,134 L95.9999489,134 C100.420214,134 104,130.418278 104,126 C104,121.590712 100.418255,118 95.9999489,118 L40,118 Z" id="Rectangle-432-Copy" transform="translate(64.000000, 94.000000) scale(1, -1) rotate(-45.000000) translate(-64.000000, -94.000000) "></path>
<path d="M64.0292774,63.6235628 C61.9791013,63.6242848 59.9275217,62.8435723 58.3632024,61.279253 L35.7458219,38.6618725 C32.6211696,35.5372202 32.6166093,30.4673401 35.7408036,27.3431458 C38.8586409,24.2253085 43.9325646,24.2211982 47.0595304,27.348164 L64.0250749,44.3137085 L80.9906194,27.348164 C84.1152717,24.2235117 89.1851518,24.2189514 92.3093461,27.3431458 C95.4271834,30.460983 95.4312937,35.5349067 92.3043279,38.6618725 L69.6869474,61.279253 C68.1237851,62.8424153 66.0737951,63.6247195 64.0241231,63.6250809 Z" transform="translate(64.024316, 44.313708) scale(1, -1) translate(-64.024316, -44.313708) "></path>
<path d="M64.0049614,105.998482 C61.9547853,105.999204 59.9032057,105.218491 58.3388864,103.654172 L35.7215059,81.0367916 C32.5968535,77.9121393 32.5922933,72.8422592 35.7164876,69.7180649 C38.8343248,66.6002276 43.9082485,66.5961173 47.0352144,69.7230831 L64.0007589,86.6886276 L80.9663034,69.7230831 C84.0909557,66.5984308 89.1608358,66.5938705 92.2850301,69.7180649 C95.4028673,72.8359021 95.4069777,77.9098258 92.2800119,81.0367916 L69.6626314,103.654172 C68.099469,105.217334 66.0494791,105.999639 63.999807,106 Z" transform="translate(64.000000, 86.688628) scale(1, -1) translate(-64.000000, -86.688628) "></path>
</g>
</svg>

View File

@ -3,9 +3,8 @@ tags: $:/tags/Image
<svg class="tc-image-fold-others tc-image-button" width="22pt" height="22pt" viewBox="0 0 128 128">
<g fill-rule="evenodd">
<rect x="0" y="69" width="128" height="16" rx="8"></rect>
<rect x="0" y="43" width="128" height="16" rx="8"></rect>
<path d="M101.657101,114.348843 C100.207918,112.898639 98.2051847,112 95.9929031,112 L72,112 L72,88.0070969 C72,85.7964515 71.1036108,83.7937171 69.6545293,82.3441246 L69.6571005,82.3488427 C68.2079177,80.8986387 66.2051847,80 63.9929031,80 L32.0070969,80 C27.5881712,80 24,83.581722 24,88 C24,92.4092877 27.5848994,96 32.0070969,96 L56,96 L56,119.992903 C56,122.203549 56.8963895,124.206283 58.3454713,125.655876 L58.3429,125.651158 C59.7920828,127.101361 61.7948156,128 64.0070969,128 L88,128 L88,151.992903 C88,156.411829 91.581722,160 96,160 C100.409288,160 104,156.415101 104,151.992903 L104,120.007097 C104,117.796452 103.103611,115.793717 101.654529,114.344125 Z" id="Rectangle-440" transform="translate(64.000000, 120.000000) rotate(-45.000000) translate(-64.000000, -120.000000) "></path>
<path d="M101.657101,2.34884273 C100.207918,0.898638749 98.2051847,0 95.9929031,0 L72,7.10542736e-15 L72,-23.9929031 C72,-26.2035485 71.1036108,-28.2062829 69.6545293,-29.6558754 L69.6571005,-29.6511573 C68.2079177,-31.1013613 66.2051847,-32 63.9929031,-32 L32.0070969,-32 C27.5881712,-32 24,-28.418278 24,-24 C24,-19.5907123 27.5848994,-16 32.0070969,-16 L56,-16 L56,7.99290312 C56,10.2035488 56.8963895,12.2062834 58.3454713,13.655876 L58.3429,13.6511579 C59.7920828,15.1013615 61.7948156,16 64.0070969,16 L88,16 L88,39.9929031 C88,44.4118288 91.581722,48 96,48 C100.409288,48 104,44.4151006 104,39.9929031 L104,8.00709688 C104,5.79645151 103.103611,3.79371715 101.654529,2.34412458 Z" id="Rectangle-440-Copy" transform="translate(64.000000, 8.000000) scale(1, -1) rotate(-45.000000) translate(-64.000000, -8.000000) "></path>
<rect x="0" y="56.0314331" width="128" height="16" rx="8"></rect>
<path d="M101.657101,104.948818 C100.207918,103.498614 98.2051847,102.599976 95.9929031,102.599976 L72,102.599976 L72,78.6070725 C72,76.3964271 71.1036108,74.3936927 69.6545293,72.9441002 L69.6571005,72.9488183 C68.2079177,71.4986143 66.2051847,70.5999756 63.9929031,70.5999756 L32.0070969,70.5999756 C27.5881712,70.5999756 24,74.1816976 24,78.5999756 C24,83.0092633 27.5848994,86.5999756 32.0070969,86.5999756 L56,86.5999756 L56,110.592879 C56,112.803524 56.8963895,114.806259 58.3454713,116.255852 L58.3429,116.251133 C59.7920828,117.701337 61.7948156,118.599976 64.0070969,118.599976 L88,118.599976 L88,142.592879 C88,147.011804 91.581722,150.599976 96,150.599976 C100.409288,150.599976 104,147.015076 104,142.592879 L104,110.607072 C104,108.396427 103.103611,106.393693 101.654529,104.9441 Z" transform="translate(64.000000, 110.599976) rotate(-45.000000) translate(-64.000000, -110.599976) "></path>
<path d="M101.725643,11.7488671 C100.27646,10.2986632 98.2737272,9.40002441 96.0614456,9.40002441 L72.0685425,9.40002441 L72.0685425,-14.5928787 C72.0685425,-16.8035241 71.1721533,-18.8062584 69.7230718,-20.255851 L69.725643,-20.2511329 C68.2764602,-21.7013368 66.2737272,-22.5999756 64.0614456,-22.5999756 L32.0756394,-22.5999756 C27.6567137,-22.5999756 24.0685425,-19.0182536 24.0685425,-14.5999756 C24.0685425,-10.1906879 27.6534419,-6.59997559 32.0756394,-6.59997559 L56.0685425,-6.59997559 L56.0685425,17.3929275 C56.0685425,19.6035732 56.964932,21.6063078 58.4140138,23.0559004 L58.4114425,23.0511823 C59.8606253,24.5013859 61.8633581,25.4000244 64.0756394,25.4000244 L88.0685425,25.4000244 L88.0685425,49.3929275 C88.0685425,53.8118532 91.6502645,57.4000244 96.0685425,57.4000244 C100.47783,57.4000244 104.068542,53.815125 104.068542,49.3929275 L104.068542,17.4071213 C104.068542,15.1964759 103.172153,13.1937416 101.723072,11.744149 Z" transform="translate(64.068542, 17.400024) scale(1, -1) rotate(-45.000000) translate(-64.068542, -17.400024) "></path>
</g>
</svg>

View File

@ -1,9 +1,10 @@
title: $:/core/images/unfold-button
tags: $:/tags/Image
<svg class="tc-image-unfold tc-image-button" width="22pt" height="22pt" viewBox="0 0 128 128">
<svg class="tc-image-fold tc-image-button" width="22pt" height="22pt" viewBox="0 0 128 128">
<g fill-rule="evenodd">
<rect x="0" y="0" width="128" height="16" rx="8"></rect>
<path d="M40,73 L40,17.0000511 C40,12.5797863 36.418278,9 32,9 C27.5907123,9 24,12.5817449 24,17.0000511 L24,80.9999489 C24,85.4092877 27.5817449,89 32.0000511,89 L95.9999489,89 C100.420214,89 104,85.418278 104,81 C104,76.5907123 100.418255,73 95.9999489,73 L40,73 Z" transform="translate(64.000000, 49.000000) rotate(-45.000000) translate(-64.000000, -49.000000) "></path>
<path d="M85.598226,11.3488427 C84.1490432,9.89863875 82.1463102,9 79.9340286,9 L47.9482224,9 C43.5292967,9 39.9411255,12.581722 39.9411255,17 C39.9411255,21.4092877 43.5260249,25 47.9482224,25 L71.9411255,25 L71.9411255,48.9929031 C71.9411255,53.4118288 75.5228475,57 79.9411255,57 C84.3504132,57 87.9411255,53.4151006 87.9411255,48.9929031 L87.9411255,17.0070969 C87.9411255,14.7964515 87.0447363,12.7937171 85.5956548,11.3441246 Z" transform="translate(63.941125, 33.000000) scale(1, -1) rotate(-45.000000) translate(-63.941125, -33.000000) "></path>
<path d="M85.6571005,53.4077172 C84.2079177,51.9575133 82.2051847,51.0588745 79.9929031,51.0588745 L48.0070969,51.0588745 C43.5881712,51.0588745 40,54.6405965 40,59.0588745 C40,63.4681622 43.5848994,67.0588745 48.0070969,67.0588745 L72,67.0588745 L72,91.0517776 C72,95.4707033 75.581722,99.0588745 80,99.0588745 C84.4092877,99.0588745 88,95.4739751 88,91.0517776 L88,59.0659714 C88,56.855326 87.1036108,54.8525917 85.6545293,53.4029991 Z" transform="translate(64.000000, 75.058875) scale(1, -1) rotate(-45.000000) translate(-64.000000, -75.058875) "></path>
</g>
</svg>

View File

@ -585,8 +585,7 @@ NavigatorWidget.prototype.handleFoldOtherTiddlersEvent = function(event) {
paramObject = event.paramObject || {},
prefix = paramObject.foldedStatePrefix;
$tw.utils.each(this.getStoryList(),function(title) {
var foldedState = self.wiki.getTiddlerText(prefix + title,"show");
self.wiki.setText(prefix + title,"text",null,event.param === title ? foldedState : "hide");
self.wiki.setText(prefix + title,"text",null,event.param === title ? "show" : "hide");
});
};

View File

@ -1,2 +1,2 @@
title: $:/tags/ViewToolbar
list: [[$:/core/ui/Buttons/fold]] [[$:/core/ui/Buttons/more-tiddler-actions]] [[$:/core/ui/Buttons/info]] [[$:/core/ui/Buttons/new-here]] [[$:/core/ui/Buttons/new-journal-here]] [[$:/core/ui/Buttons/clone]] [[$:/core/ui/Buttons/export-tiddler]] [[$:/core/ui/Buttons/edit]] [[$:/core/ui/Buttons/delete]] [[$:/core/ui/Buttons/permalink]] [[$:/core/ui/Buttons/permaview]] [[$:/core/ui/Buttons/open-window]] [[$:/core/ui/Buttons/close-others]] [[$:/core/ui/Buttons/close]]
list: [[$:/core/ui/Buttons/more-tiddler-actions]] [[$:/core/ui/Buttons/info]] [[$:/core/ui/Buttons/new-here]] [[$:/core/ui/Buttons/new-journal-here]] [[$:/core/ui/Buttons/clone]] [[$:/core/ui/Buttons/export-tiddler]] [[$:/core/ui/Buttons/edit]] [[$:/core/ui/Buttons/delete]] [[$:/core/ui/Buttons/permalink]] [[$:/core/ui/Buttons/permaview]] [[$:/core/ui/Buttons/open-window]] [[$:/core/ui/Buttons/close-others]] [[$:/core/ui/Buttons/close]] [[$:/core/ui/Buttons/fold-others]] [[$:/core/ui/Buttons/fold]]