aboutsummaryrefslogtreecommitdiff
path: root/FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2023-07-31 00:08:48 +0800
committercrupest <crupest@outlook.com>2023-07-31 00:09:12 +0800
commitd9c1d512fa64ef4f8c08ca34f7a5842642879bcc (patch)
treee71cd57b30ed67462ecaf010812b6d902c7fa675 /FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx
parent538d6830a0022b49b99695095d85e567b0c86e71 (diff)
downloadtimeline-d9c1d512fa64ef4f8c08ca34f7a5842642879bcc.tar.gz
timeline-d9c1d512fa64ef4f8c08ca34f7a5842642879bcc.tar.bz2
timeline-d9c1d512fa64ef4f8c08ca34f7a5842642879bcc.zip
...
Diffstat (limited to 'FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx')
-rw-r--r--FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx42
1 files changed, 0 insertions, 42 deletions
diff --git a/FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx b/FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx
deleted file mode 100644
index fc55185c..00000000
--- a/FrontEnd/src/views/timeline/PostPropertyChangeDialog.tsx
+++ /dev/null
@@ -1,42 +0,0 @@
-import * as React from "react";
-
-import { getHttpTimelineClient, HttpTimelinePostInfo } from "@/http/timeline";
-
-import OperationDialog from "../common/dialog/OperationDialog";
-
-function PostPropertyChangeDialog(props: {
- open: boolean;
- onClose: () => void;
- post: HttpTimelinePostInfo;
- onSuccess: (post: HttpTimelinePostInfo) => void;
-}): React.ReactElement | null {
- const { open, onClose, post, onSuccess } = props;
-
- return (
- <OperationDialog
- title="timeline.changePostPropertyDialog.title"
- onClose={onClose}
- open={open}
- inputScheme={[
- {
- label: "timeline.changePostPropertyDialog.time",
- type: "datetime",
- initValue: post.time,
- },
- ]}
- onProcess={([time]) => {
- return getHttpTimelineClient().patchPost(
- post.timelineOwnerV2,
- post.timelineNameV2,
- post.id,
- {
- time: time === "" ? undefined : new Date(time).toISOString(),
- }
- );
- }}
- onSuccessAndClose={onSuccess}
- />
- );
-}
-
-export default PostPropertyChangeDialog;