discourse/app/assets/javascripts/admin/addon/components/admin-flags.gjs
Krzysztof Kotlarek 963b9fd157
FEATURE: admin can disable flags (#27171)
UI for admins to disable system flags.
2024-05-29 14:39:58 +10:00

27 lines
758 B
Plaintext

import Component from "@glimmer/component";
import { inject as service } from "@ember/service";
import i18n from "discourse-common/helpers/i18n";
import AdminFlagItem from "admin/components/admin-flag-item";
export default class AdminFlags extends Component {
@service site;
flags = this.site.flagTypes;
<template>
<div class="container admin-flags">
<h1>{{i18n "admin.flags.title"}}</h1>
<table class="flags grid">
<thead>
<th>{{i18n "admin.flags.description"}}</th>
<th>{{i18n "admin.flags.enabled"}}</th>
</thead>
<tbody>
{{#each this.flags as |flag|}}
<AdminFlagItem @flag={{flag}} />
{{/each}}
</tbody>
</table>
</div>
</template>
}