FIX: Allow HTML in category read-only dialog (#20349)
We allow HTML for this string in `category-read-only-banner.hbs`, this makes it consistent for the dialog.
This commit is contained in:
parent
8144730ebb
commit
a945ca3e01
|
@ -4,6 +4,7 @@ import NavItem from "discourse/models/nav-item";
|
||||||
import discourseComputed from "discourse-common/utils/decorators";
|
import discourseComputed from "discourse-common/utils/decorators";
|
||||||
import { NotificationLevels } from "discourse/lib/notification-levels";
|
import { NotificationLevels } from "discourse/lib/notification-levels";
|
||||||
import { getOwner } from "discourse-common/lib/get-owner";
|
import { getOwner } from "discourse-common/lib/get-owner";
|
||||||
|
import { htmlSafe } from "@ember/template";
|
||||||
import { inject as service } from "@ember/service";
|
import { inject as service } from "@ember/service";
|
||||||
|
|
||||||
export default Component.extend(FilterModeMixin, {
|
export default Component.extend(FilterModeMixin, {
|
||||||
|
@ -157,7 +158,7 @@ export default Component.extend(FilterModeMixin, {
|
||||||
|
|
||||||
clickCreateTopicButton() {
|
clickCreateTopicButton() {
|
||||||
if (this.categoryReadOnlyBanner && !this.hasDraft) {
|
if (this.categoryReadOnlyBanner && !this.hasDraft) {
|
||||||
this.dialog.alert(this.categoryReadOnlyBanner);
|
this.dialog.alert({ message: htmlSafe(this.categoryReadOnlyBanner) });
|
||||||
} else {
|
} else {
|
||||||
this.createTopic();
|
this.createTopic();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue