mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-16 14:54:51 +00:00
9635e2d8af
See discussion at https://github.com/TiddlyWiki/TiddlyWiki5/pull/7987#issuecomment-2431123638
81 lines
1.9 KiB
Plaintext
81 lines
1.9 KiB
Plaintext
title: $:/core/macros/CSS
|
|
tags: $:/tags/Macro
|
|
|
|
<!-- Needs to stay that way for backwards compatibility. See GH issue: #8326 -->
|
|
\define colour(name)
|
|
\whitespace trim
|
|
<$transclude tiddler={{$:/palette}} index="$name$">
|
|
<$transclude tiddler="$:/palettes/Vanilla" index="$name$">
|
|
<$transclude tiddler="$:/config/DefaultColourMappings/$name$"/>
|
|
</$transclude>
|
|
</$transclude>
|
|
\end
|
|
|
|
\define color(name) <<colour $name$>>
|
|
|
|
\define box-shadow(shadow)
|
|
``
|
|
-webkit-box-shadow: $shadow$;
|
|
-moz-box-shadow: $shadow$;
|
|
box-shadow: $shadow$;
|
|
``
|
|
\end
|
|
|
|
\define filter(filter)
|
|
``
|
|
-webkit-filter: $filter$;
|
|
-moz-filter: $filter$;
|
|
filter: $filter$;
|
|
``
|
|
\end
|
|
|
|
\define transition(transition)
|
|
``
|
|
-webkit-transition: $transition$;
|
|
-moz-transition: $transition$;
|
|
transition: $transition$;
|
|
``
|
|
\end
|
|
|
|
\define transform-origin(origin)
|
|
``
|
|
-webkit-transform-origin: $origin$;
|
|
-moz-transform-origin: $origin$;
|
|
transform-origin: $origin$;
|
|
``
|
|
\end
|
|
|
|
\define background-linear-gradient(gradient)
|
|
``
|
|
background-image: linear-gradient($gradient$);
|
|
background-image: -o-linear-gradient($gradient$);
|
|
background-image: -moz-linear-gradient($gradient$);
|
|
background-image: -webkit-linear-gradient($gradient$);
|
|
background-image: -ms-linear-gradient($gradient$);
|
|
``
|
|
\end
|
|
|
|
\define column-count(columns)
|
|
``
|
|
-moz-column-count: $columns$;
|
|
-webkit-column-count: $columns$;
|
|
column-count: $columns$;
|
|
``
|
|
\end
|
|
|
|
\procedure datauri(title)
|
|
<$macrocall $name="makedatauri" type={{{ [<title>get[type]] }}} text={{{ [<title>get[text]] }}} _canonical_uri={{{ [<title>get[_canonical_uri]] }}}/>
|
|
\end
|
|
|
|
\procedure if-sidebar(text)
|
|
<$reveal state="$:/state/sidebar" type="match" text="yes" default="yes"><<text>></$reveal>
|
|
\end
|
|
|
|
\procedure if-no-sidebar(text)
|
|
<$reveal state="$:/state/sidebar" type="nomatch" text="yes" default="yes"><<text>></$reveal>
|
|
\end
|
|
|
|
\procedure if-background-attachment(text)
|
|
<$reveal state="$:/themes/tiddlywiki/vanilla/settings/backgroundimage" type="nomatch" text=""><<text>></$reveal>
|
|
\end
|