1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-12-18 14:10:28 +00:00
TiddlyWiki5/core/wiki/macros/thumbnails.tid

23 lines
1.3 KiB
Plaintext
Raw Normal View History

2015-09-09 16:46:42 +00:00
title: $:/core/macros/thumbnails
tags: $:/tags/Macro
\define thumbnail(link,icon,color,background-color,image,caption,width:"280",height:"157")
2015-03-25 11:11:18 +00:00
<$link to="""$link$"""><div class="tc-thumbnail-wrapper">
<div class="tc-thumbnail-image" style="width:$width$px;height:$height$px;"><$reveal type="nomatch" text="" default="""$image$""" tag="div" style="width:$width$px;height:$height$px;">
[img[$image$]]
</$reveal><$reveal type="match" text="" default="""$image$""" tag="div" class="tc-thumbnail-background" style="width:$width$px;height:$height$px;background-color:$background-color$;"></$reveal></div><div class="tc-thumbnail-icon" style="fill:$color$;color:$color$;">
$icon$
2015-03-25 11:11:18 +00:00
</div><div class="tc-thumbnail-caption">
$caption$
</div>
</div></$link>
\end
\define thumbnail-right(link,icon,color,background-color,image,caption,width:"280",height:"157")
2015-03-25 11:11:18 +00:00
<div class="tc-thumbnail-right-wrapper"><<thumbnail """$link$""" """$icon$""" """$color$""" """$background-color$""" """$image$""" """$caption$""" """$width$""" """$height$""">></div>
\end
\define list-thumbnails(filter,width:"280",height:"157")
2015-03-25 11:11:18 +00:00
<$list filter="""$filter$"""><$macrocall $name="thumbnail" link={{!!link}} icon={{!!icon}} color={{!!color}} background-color={{!!background-color}} image={{!!image}} caption={{!!caption}} width="""$width$""" height="""$height$"""/></$list>
\end