feat(web): inline status-aware errors on term/authority edit rows + delete dialog (#63)

This commit is contained in:
2026-06-08 17:27:02 +02:00
parent dd131ee740
commit 6e02ac874f
5 changed files with 62 additions and 4 deletions
+3
View File
@@ -5,6 +5,7 @@ import type { components } from "../api/schema";
import { useUpdateAuthority, useDeleteAuthority } from "../api/queries";
import { LabelEditor } from "../components/label-editor";
import { DeleteConfirmDialog } from "../components/delete-confirm-dialog";
import { MutationError } from "../components/mutation-error";
import { ExternalUriLink } from "../components/external-uri-link";
import { Button } from "@/components/ui/button";
import { Input } from "@/components/ui/input";
@@ -56,6 +57,7 @@ export function AuthorityRow({ authority, kind, lang }: { authority: AuthorityVi
{t("form.cancel")}
</Button>
</div>
<MutationError error={updateAuthority.error} />
</li>
);
}
@@ -71,6 +73,7 @@ export function AuthorityRow({ authority, kind, lang }: { authority: AuthorityVi
variant="ghost"
size="sm"
onClick={() => {
updateAuthority.reset();
setLabels(authority.labels as LabelInput[]);
setUri(authority.external_uri ?? "");
setEditing(true);