feat(plugin-annotations): Allow setting title and desc via msg
This commit is contained in:
parent
88e6ac6a77
commit
87aaf1f2d9
1 changed files with 5 additions and 0 deletions
|
@ -33,6 +33,11 @@ function flag(type, store, data) {
|
||||||
data = presets[data]
|
data = presets[data]
|
||||||
type = data.type
|
type = data.type
|
||||||
}
|
}
|
||||||
|
if (data.msg) {
|
||||||
|
data.title = data.msg + '.t'
|
||||||
|
data.desc = data.msg + '.d'
|
||||||
|
delete data.msg
|
||||||
|
}
|
||||||
|
|
||||||
if (!data.id && !data.title) {
|
if (!data.id && !data.title) {
|
||||||
store.log.warn(`store.flag.${type} called without an id or title property`)
|
store.log.warn(`store.flag.${type} called without an id or title property`)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue