File tree Expand file tree Collapse file tree 3 files changed +17
-5
lines changed Expand file tree Collapse file tree 3 files changed +17
-5
lines changed Original file line number Diff line number Diff line change @@ -1157,6 +1157,9 @@ blockquote.caution {
1157
1157
background-color : oklch (var (--color-callout-caution-shadow ));
1158
1158
border-bottom : 1px solid oklch (var (--color-callout-caution-primary ));
1159
1159
}
1160
+ .call-out-type .feather {
1161
+ color : oklch (var (--color-callout-caution-primary ));
1162
+ }
1160
1163
}
1161
1164
1162
1165
blockquote .warning {
@@ -1167,6 +1170,9 @@ blockquote.warning {
1167
1170
background-color : oklch (var (--color-callout-warning-shadow ));
1168
1171
border-bottom : 1px solid oklch (var (--color-callout-warning-primary ));
1169
1172
}
1173
+ .call-out-type .feather {
1174
+ color : oklch (var (--color-callout-warning-primary ));
1175
+ }
1170
1176
}
1171
1177
1172
1178
blockquote .important {
Original file line number Diff line number Diff line change 35
35
36
36
{{/* Render a different block, if "loud" callouts are used */}}
37
37
{{ $specialTitles := slice "Caution" "Warning" "Deprecated" "Important" }}
38
+ {{ $specialTitleIcons := dict
39
+ "Caution" "alert-triangle"
40
+ "Warning" "alert-octagon"
41
+ "Deprecated" "alert-octagon"
42
+ "Important" "arrow-right-circle"
43
+ }}
44
+ {{ $icon := index $specialTitleIcons $title | default "" }}
45
+
38
46
{{ $isSpecialTitle := in $specialTitles $title }}
39
47
{{ if $isSpecialTitle }}
40
48
{{/* Loud callouts */}}
41
49
< blockquote class ="{{ $class }} " data-mf ="true " style ="display: none; ">
42
50
< div >
43
- {{ with $icon }}
44
- < i class ="{{ . }} "> </ i >
45
- {{ end }}
46
51
< div class ="call-out-type ">
52
+ {{ partial "feather" (dict "context" . "icon" $icon) .}}
47
53
{{ $title }}
48
54
</ div >
49
- < div class =" special-content " >
55
+ < div >
50
56
{{ .content | markdownify }}
51
57
</ div >
52
58
</ div >
Original file line number Diff line number Diff line change 6
6
{{</ call-out > }}
7
7
8
8
Backwards compatibility usage:
9
- {{< call-out "warning" "Custom title""fa fa-check-circle" "true"> }}
9
+ {{< call-out "warning" "Custom title" "fa fa-check-circle" "true"> }}
10
10
This callout uses the icon check-circle. **This should be an inline callout.**
11
11
{{</ call-out > }}
12
12
You can’t perform that action at this time.
0 commit comments