diff --git a/frontend/src/components/orgs-list.ts b/frontend/src/components/orgs-list.ts index f7cb9775..493b4ec3 100644 --- a/frontend/src/components/orgs-list.ts +++ b/frontend/src/components/orgs-list.ts @@ -1,8 +1,8 @@ import { localized, msg, str } from "@lit/localize"; -import { - // type SlChangeEvent, - type SlInput, - // type SlMenuItem, +import type { + SlButton, + SlChangeEvent, + SlInput, } from "@shoelace-style/shoelace"; import { serialize } from "@shoelace-style/shoelace/dist/utilities/form.js"; import { css, html, nothing } from "lit"; @@ -52,6 +52,12 @@ export class OrgsList extends TailwindElement { @query("#orgReadOnlyDialog") private readonly orgReadOnlyDialog?: Dialog | null; + @query("#orgDeleteDialog") + private readonly orgDeleteDialog?: Dialog | null; + + @query("#orgDeleteButton") + private readonly orgDeleteButton?: SlButton | null; + private readonly api = new APIController(this); private readonly navigate = new NavigateController(this); private readonly notify = new NotifyController(this); @@ -86,6 +92,7 @@ export class OrgsList extends TailwindElement { ${this.renderOrgQuotas()} ${this.renderOrgReadOnly()} + ${this.renderOrgDelete()} `; } @@ -157,7 +164,7 @@ export class OrgsList extends TailwindElement {
${msg(
html`Are you sure you want to make
- ${org.name}
+ ${org.name}
read-only? Members will no longer be able to crawl, upload
files, create browser profiles, or create collections.`,
)}
@@ -208,6 +215,119 @@ export class OrgsList extends TailwindElement {
`;
}
+ private renderOrgDelete() {
+ return html`
+
+ ${msg(
+ html`Are you sure you want to delete
+ ${org.name}? This
+ cannot be undone.`,
+ )}
+
+ ${msg(
+ html`Deleting an org will delete all
+
+
+
+
+
+