mirror of
https://github.com/kovetskiy/mark.git
synced 2025-04-23 21:32:41 +08:00
feat(macro): Add emoticon support
This commit is contained in:
parent
74e67141ba
commit
99119d8aff
25
README.md
25
README.md
@ -165,6 +165,31 @@ By default, mark provides several built-in templates and macros:
|
||||
|
||||
See: https://confluence.atlassian.com/conf59/status-macro-792499207.html
|
||||
|
||||
* template: `ac:emoticon` to include emoticons. Parameters:
|
||||
- Name: select emoticon
|
||||
- smile
|
||||
- sad
|
||||
- cheeky
|
||||
- laugh
|
||||
- wink
|
||||
- thumbs-up
|
||||
- thumbs-down
|
||||
- information
|
||||
- tick
|
||||
- cross
|
||||
- warning
|
||||
- plus
|
||||
- minus
|
||||
- question
|
||||
- light-on
|
||||
- light-off
|
||||
- yellow-star
|
||||
- red-star
|
||||
- green-star
|
||||
- blue-star
|
||||
|
||||
See: https://confluence.atlassian.com/doc/confluence-storage-format-790796544.html
|
||||
|
||||
* macro `@{...}` to mention user by name specified in the braces.
|
||||
|
||||
## Template & Macros Usecases
|
||||
|
@ -172,6 +172,12 @@ func templates(api *confluence.API) (*template.Template, error) {
|
||||
`</ac:structured-macro>{{printf "\n"}}`,
|
||||
),
|
||||
|
||||
/* https://confluence.atlassian.com/doc/confluence-storage-format-790796544.html */
|
||||
|
||||
`ac:emoticon`: text(
|
||||
`<ac:emoticon ac:name="{{ .Name }}"/>`,
|
||||
),
|
||||
|
||||
// TODO(seletskiy): more templates here
|
||||
} {
|
||||
templates, err = templates.New(name).Parse(body)
|
||||
|
Loading…
x
Reference in New Issue
Block a user