mirror of
https://github.com/codeninjasllc/discourse.git
synced 2025-05-02 08:54:02 -04:00
Expose decoration for plugins such as signatures
This commit is contained in:
parent
f2f49a5e96
commit
8b318f76a1
1 changed files with 4 additions and 0 deletions
|
@ -113,6 +113,10 @@ class PluginApi {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
decorateWidget(name, fn) {
|
||||||
|
decorateWidget(name, fn);
|
||||||
|
}
|
||||||
|
|
||||||
attachWidgetAction(widget, actionName, fn) {
|
attachWidgetAction(widget, actionName, fn) {
|
||||||
const widgetClass = this.container.lookupFactory(`widget:${widget}`);
|
const widgetClass = this.container.lookupFactory(`widget:${widget}`);
|
||||||
widgetClass.prototype[actionName] = fn;
|
widgetClass.prototype[actionName] = fn;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue