Move `Controller/ClipboardData` to `Controller/Clipboard/Data`
authorMatthias Schmidt <gravatronics@live.com>
Mon, 15 Mar 2021 09:00:04 +0000 (10:00 +0100)
committerMatthias Schmidt <gravatronics@live.com>
Sun, 21 Mar 2021 09:21:39 +0000 (10:21 +0100)
ts/WoltLabSuite/Core/Controller/Clipboard.ts
ts/WoltLabSuite/Core/Controller/Clipboard/Data.ts [new file with mode: 0644]
ts/WoltLabSuite/Core/Controller/ClipboardData.ts [deleted file]
ts/WoltLabSuite/Core/Ui/Object/Data.ts
wcfsetup/install/files/js/WoltLabSuite/Core/Controller/Clipboard/Data.js [new file with mode: 0644]
wcfsetup/install/files/js/WoltLabSuite/Core/Controller/ClipboardData.js [deleted file]

index 123b3f381dc5dac137492b2adeb55532bbfc57ce..9dde00d6c47fc4465050b32f9ff46bbd75a46488 100644 (file)
@@ -18,7 +18,7 @@ import * as UiConfirmation from "../Ui/Confirmation";
 import UiDropdownSimple from "../Ui/Dropdown/Simple";
 import * as UiPageAction from "../Ui/Page/Action";
 import * as UiScreen from "../Ui/Screen";
-import { ClipboardOptions, ContainerData, ClipboardActionData, AjaxResponse } from "./ClipboardData";
+import { ClipboardOptions, ContainerData, ClipboardActionData, AjaxResponse } from "./Clipboard/Data";
 
 const _specialCheckboxSelector =
   '.messageCheckboxLabel > input[type="checkbox"], .message .messageClipboardCheckbox > input[type="checkbox"], .messageGroupList .columnMark > label > input[type="checkbox"]';
diff --git a/ts/WoltLabSuite/Core/Controller/Clipboard/Data.ts b/ts/WoltLabSuite/Core/Controller/Clipboard/Data.ts
new file mode 100644 (file)
index 0000000..5e3a26c
--- /dev/null
@@ -0,0 +1,49 @@
+import { DatabaseObjectActionResponse } from "../../Ajax/Data";
+
+export interface ClipboardOptions {
+  hasMarkedItems: boolean;
+  pageClassName: string;
+  pageObjectId?: number;
+}
+
+export interface ContainerData {
+  checkboxes: HTMLCollectionOf<HTMLInputElement>;
+  element: HTMLElement;
+  markAll: HTMLInputElement | null;
+  markedObjectIds: Set<number>;
+}
+
+export interface ClipboardItemData {
+  items: { [key: string]: ClipboardActionData };
+  label: string;
+  reloadPageOnSuccess: string[];
+}
+
+export interface ClipboardActionData {
+  actionName: string;
+  internalData: ArbitraryObject;
+  label: string;
+  parameters: {
+    actionName?: string;
+    className?: string;
+    objectIDs: number[];
+    template: string;
+  };
+  url: string;
+}
+
+export interface AjaxResponseMarkedItems {
+  [key: string]: number[];
+}
+
+export interface AjaxResponse extends DatabaseObjectActionResponse {
+  returnValues: {
+    action: string;
+    items?: {
+      // They key is the `typeName`
+      [key: string]: ClipboardItemData;
+    };
+    markedItems?: AjaxResponseMarkedItems;
+    objectType: string;
+  };
+}
diff --git a/ts/WoltLabSuite/Core/Controller/ClipboardData.ts b/ts/WoltLabSuite/Core/Controller/ClipboardData.ts
deleted file mode 100644 (file)
index 3fa82d5..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-import { DatabaseObjectActionResponse } from "../Ajax/Data";
-
-export interface ClipboardOptions {
-  hasMarkedItems: boolean;
-  pageClassName: string;
-  pageObjectId?: number;
-}
-
-export interface ContainerData {
-  checkboxes: HTMLCollectionOf<HTMLInputElement>;
-  element: HTMLElement;
-  markAll: HTMLInputElement | null;
-  markedObjectIds: Set<number>;
-}
-
-export interface ClipboardItemData {
-  items: { [key: string]: ClipboardActionData };
-  label: string;
-  reloadPageOnSuccess: string[];
-}
-
-export interface ClipboardActionData {
-  actionName: string;
-  internalData: ArbitraryObject;
-  label: string;
-  parameters: {
-    actionName?: string;
-    className?: string;
-    objectIDs: number[];
-    template: string;
-  };
-  url: string;
-}
-
-export interface AjaxResponseMarkedItems {
-  [key: string]: number[];
-}
-
-export interface AjaxResponse extends DatabaseObjectActionResponse {
-  returnValues: {
-    action: string;
-    items?: {
-      // They key is the `typeName`
-      [key: string]: ClipboardItemData;
-    };
-    markedItems?: AjaxResponseMarkedItems;
-    objectType: string;
-  };
-}
index a13077781574bab9bb8ab2cc471649ffd00a24e2..e67f778d9afa681c0cfa51a6b289b289a8edf954 100644 (file)
@@ -1,5 +1,5 @@
 import { DatabaseObjectActionResponse } from "../../Ajax/Data";
-import { ClipboardActionData } from "../../Controller/ClipboardData";
+import { ClipboardActionData } from "../../Controller/Clipboard/Data";
 
 export interface ObjectActionData {
   data: DatabaseObjectActionResponse;
diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Controller/Clipboard/Data.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Controller/Clipboard/Data.js
new file mode 100644 (file)
index 0000000..2ae92b6
--- /dev/null
@@ -0,0 +1,4 @@
+define(["require", "exports"], function (require, exports) {
+    "use strict";
+    Object.defineProperty(exports, "__esModule", { value: true });
+});
diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Controller/ClipboardData.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Controller/ClipboardData.js
deleted file mode 100644 (file)
index 2ae92b6..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-define(["require", "exports"], function (require, exports) {
-    "use strict";
-    Object.defineProperty(exports, "__esModule", { value: true });
-});