feat(web): edit/delete authorities in place (#30)

This commit is contained in:
2026-06-05 20:35:26 +02:00
parent 83ca506702
commit c9120848f5
3 changed files with 109 additions and 4 deletions
+2 -4
View File
@@ -6,7 +6,7 @@ import type { components } from "../api/schema";
import { useAuthorities, useCreateAuthority } from "../api/queries";
import { LabelEditor } from "../components/label-editor";
import { Button } from "@/components/ui/button";
import { labelText } from "../lib/labels";
import { AuthorityRow } from "./authority-row";
type LabelInput = components["schemas"]["LabelInput"];
@@ -72,9 +72,7 @@ export function AuthoritiesPage() {
<li className="text-sm text-neutral-500">{t("authorities.empty")}</li>
)}
{authorities?.map((a) => (
<li key={a.id} className="border-b py-1 text-sm">
{labelText(a.labels, lang)}
</li>
<AuthorityRow key={a.id} authority={a} kind={currentKind} lang={lang} />
))}
</ul>