diff --git a/apps/client/src/widgets/bulk_actions/relation/delete_relation.ts b/apps/client/src/widgets/bulk_actions/relation/delete_relation.ts
deleted file mode 100644
index e88350757..000000000
--- a/apps/client/src/widgets/bulk_actions/relation/delete_relation.ts
+++ /dev/null
@@ -1,45 +0,0 @@
-import SpacedUpdate from "../../../services/spaced_update.js";
-import AbstractBulkAction from "../abstract_bulk_action.js";
-import { t } from "../../../services/i18n.js";
-
-const TPL = /*html*/`
-
-
- ${t("delete_relation.delete_relation")}
- |
-
-
-
-
- |
-
-
- |
-
`;
-
-export default class DeleteRelationBulkAction extends AbstractBulkAction {
- static get actionName() {
- return "deleteRelation";
- }
- static get actionTitle() {
- return t("delete_relation.delete_relation");
- }
-
- doRender() {
- const $action = $(TPL);
- const $relationName = $action.find(".relation-name");
- $relationName.val(this.actionDef.relationName || "");
-
- const spacedUpdate = new SpacedUpdate(async () => {
- await this.saveAction({ relationName: $relationName.val() });
- }, 1000);
-
- $relationName.on("input", () => spacedUpdate.scheduleUpdate());
-
- return $action;
- }
-}
diff --git a/apps/client/src/widgets/bulk_actions/relation/delete_relation.tsx b/apps/client/src/widgets/bulk_actions/relation/delete_relation.tsx
new file mode 100644
index 000000000..bf8e3f352
--- /dev/null
+++ b/apps/client/src/widgets/bulk_actions/relation/delete_relation.tsx
@@ -0,0 +1,41 @@
+import AbstractBulkAction, { ActionDefinition } from "../abstract_bulk_action.js";
+import { t } from "../../../services/i18n.js";
+import BulkAction from "../BulkAction.jsx";
+import FormTextBox from "../../react/FormTextBox.jsx";
+import { useEffect, useState } from "preact/hooks";
+import { useSpacedUpdate } from "../../react/hooks.jsx";
+
+function DeleteRelationBulkActionComponent({ bulkAction, actionDef }: { bulkAction: AbstractBulkAction, actionDef: ActionDefinition }) {
+ const [ relationName, setRelationName ] = useState(actionDef.relationName);
+ const spacedUpdate = useSpacedUpdate(() => bulkAction.saveAction({ relationName }));
+ useEffect(() => spacedUpdate.scheduleUpdate(), [ relationName ]);
+
+ return (
+
+
+
+ )
+}
+
+export default class DeleteRelationBulkAction extends AbstractBulkAction {
+
+ static get actionName() {
+ return "deleteRelation";
+ }
+
+ static get actionTitle() {
+ return t("delete_relation.delete_relation");
+ }
+
+ doRender() {
+ return
+ }
+}