A platform for community discussion. Free, open, simple.
DEV: Deprecate PluginOutlet tagName argument
David Taylorf9d5203610ad
diff --git a/app/assets/javascripts/discourse/app/components/plugin-outlet.js b/app/assets/javascripts/discourse/app/components/plugin-outlet.jsindex 11a7f28641c..ef837a68314 100644--- a/app/assets/javascripts/discourse/app/components/plugin-outlet.js+++ b/app/assets/javascripts/discourse/app/components/plugin-outlet.js@@ -14,6 +14,8 @@ const PARENT_VIEW_DEPRECATION_MSG ="parentView should not be used within plugin outlets. Use the available outlet arguments, or inject a service which can provide the context you need.";const GET_DEPRECATION_MSG ="Plugin outlet context is no longer an EmberObject - using `get()` is deprecated.";+const TAG_NAME_DEPRECATION_MSG =+ "The `tagName` argument to PluginOutlet is deprecated. If a wrapper element is required, define it manually around the outlet call.";/**A plugin outlet is an extension point for templates where other templates can@@ -56,6 +58,18 @@ export default class PluginOutletComponent extends GlimmerComponentWithDeprecate},};+ constructor() {+ const result = super(...arguments);++ if (this.args.tagName) {+ deprecated(`${TAG_NAME_DEPRECATION_MSG} (outlet: ${this.args.name})`, {+ id: "discourse.plugin-outlet-tag-name",+ });+ }++ return result;+ }+get connectors() {return renderedConnectorsFor(this.args.name,