mirror of
https://github.com/storytold/artcraft.git
synced 2026-11-18 07:35:19 +00:00
add deleted warning to edit page
This commit is contained in:
1 parent
6d406a83ab
commit
5b7efcbc70
1 file changed
+14
@@ -126,6 +126,7 @@ function TtsEditCategoriesPage(props: Props) {
|
||||
{assignedCategories.map(category => {
|
||||
let notApprovedWarning = null;
|
||||
let modelsNotAllowedWarning = null;
|
||||
let deletedWarning = null;
|
||||
|
||||
if (!category.can_directly_have_models) {
|
||||
modelsNotAllowedWarning = (
|
||||
@@ -139,6 +140,18 @@ function TtsEditCategoriesPage(props: Props) {
|
||||
)
|
||||
}
|
||||
|
||||
if (!!category.category_deleted_at) {
|
||||
deletedWarning = (
|
||||
<>
|
||||
<span className="tag is-rounded is-warning is-medium is-light">
|
||||
Deleted category
|
||||
|
||||
<FontAwesomeIcon icon={faExclamationCircle} />
|
||||
</span>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
if (!category.is_mod_approved) {
|
||||
notApprovedWarning = (
|
||||
<>
|
||||
@@ -156,6 +169,7 @@ function TtsEditCategoriesPage(props: Props) {
|
||||
<span className="content is-medium">{category.name}</span>
|
||||
{modelsNotAllowedWarning}
|
||||
{notApprovedWarning}
|
||||
{deletedWarning}
|
||||
|
||||
<button
|
||||
className="button is-rounded is-danger is-small is-light"
|
||||
|
||||
Reference in new issue
Block a user