import Component from "@glimmer/component"; import { fn } from "@ember/helper"; import { action } from "@ember/object"; import { service } from "@ember/service"; import { htmlSafe } from "@ember/template"; import { notEq, or } from "truth-helpers"; import DButton from "discourse/components/d-button"; export default class DialogHolder extends Component { @service dialog; @action async handleButtonAction(btn) { if (typeof btn.action === "function") { await btn.action(); } this.dialog.cancel(); } }