mirror of
https://github.com/discourse/discourse.git
synced 2024-11-27 17:13:39 +08:00
DEV: Update welcome-topic-banner to use @glimmer/component
(#17876)
Now that all of our singletons have been converted to true Ember Services, we can remove our custom `discourse/component/glimmer` superclass and use explicit injection
This commit is contained in:
parent
c789c689c2
commit
cef264ab1f
|
@ -1,10 +1,14 @@
|
||||||
import GlimmerComponent from "discourse/components/glimmer";
|
import Component from "@glimmer/component";
|
||||||
import { action } from "@ember/object";
|
import { action } from "@ember/object";
|
||||||
import { getOwner } from "discourse-common/lib/get-owner";
|
import { getOwner } from "discourse-common/lib/get-owner";
|
||||||
import Topic from "discourse/models/topic";
|
import Topic from "discourse/models/topic";
|
||||||
import Composer from "discourse/models/composer";
|
import Composer from "discourse/models/composer";
|
||||||
|
import { inject as service } from "@ember/service";
|
||||||
|
|
||||||
|
export default class WelcomeTopicBanner extends Component {
|
||||||
|
@service siteSettings;
|
||||||
|
@service store;
|
||||||
|
|
||||||
export default class WelcomeTopicBanner extends GlimmerComponent {
|
|
||||||
@action
|
@action
|
||||||
editWelcomeTopic() {
|
editWelcomeTopic() {
|
||||||
const topicController = getOwner(this).lookup("controller:topic");
|
const topicController = getOwner(this).lookup("controller:topic");
|
||||||
|
|
Loading…
Reference in New Issue
Block a user