blob: 719d82c1cd92c036d275b59c2d06deda101cdfc3 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
#
# == About ==
#
# A collection of ftags that generate an image HTML tag, containing the specified
# flag. This is done, because these tags need to have specific classes, which is
# supported in Markdown, but is less flexible and more tedious.
# == ftags ==
#
# &&gb Great Britain flag
# &&bg Bulgarian flag
#
# -- Placement/Flow --
#
# They can reside absolutely anywhere in text.
function flagSub(name, alt) {
gsub("&&" name, "<img src=\"/img/" name ".svg\" class=\"flag unzoomable svg\" alt=\"" name "\" height=18>")
}
/&&gb/ {
flagSub("gb", "ENG")
}
/&&bg/ {
flagSub("bg", "BGN")
}
|