mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-09-21 08:50:05 +00:00
Simplify the link panels
This commit is contained in:
@@ -2,32 +2,20 @@ title: $:/core/macros/thumbails
|
||||
tags: $:/tags/Macro
|
||||
|
||||
\define thumbnail(link,icon,color,background-color,image,caption,width:"280",height:"157")
|
||||
<$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;">
|
||||
<$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$;">
|
||||
</$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$;">
|
||||
$icon$
|
||||
</div>
|
||||
<div class="tc-thumbnail-caption">
|
||||
</div><div class="tc-thumbnail-caption">
|
||||
$caption$
|
||||
</div>
|
||||
</div></$link>
|
||||
</div></div></$link>
|
||||
\end
|
||||
|
||||
\define thumbnail-right(link,icon,color,background-color,image,caption,width:"280",height:"157")
|
||||
<div class="tc-thumbnail-right-wrapper">
|
||||
<<thumbnail """$link$""" """$icon$""" """$color$""" """$background-color$""" """$image$""" """$caption$""" """$width$""" """$height$""">>
|
||||
</div>
|
||||
<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")
|
||||
<$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>
|
||||
<$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
|
||||
|
||||
Reference in New Issue
Block a user