新增图库

This commit is contained in:
jiangh277
2025-08-04 16:56:39 +08:00
parent 56a0042011
commit 63ae33288d
25 changed files with 1184 additions and 38 deletions

View File

@@ -1,4 +1,4 @@
import { Badge, Col, Drawer, Row, Timeline } from 'antd';
import { Badge, Col, Row, Timeline } from 'antd';
import React from 'react';
import TimelineImage from '@/components/TimelineImage';
@@ -15,9 +15,6 @@ const TimelineItem = ({ event: initialEvent, onUpdate }: TimelineItemProps) => {
const [openMainDrawer, setOpenMainDrawer] = React.useState(false);
const [expanded, setExpanded] = React.useState(false); // 控制子项展开状态
const [openSubDrawer, setOpenSubDrawer] = React.useState(false);
const [selectedSubItem, setSelectedSubItem] = React.useState<TimelineEvent | null>(null);
const showMainDrawer = () => {
setOpenMainDrawer(true);
};
@@ -128,25 +125,6 @@ const TimelineItem = ({ event: initialEvent, onUpdate }: TimelineItemProps) => {
setOpen={setOpenMainDrawer}
/>
{/* 子时间点详情抽屉 */}
{selectedSubItem && (
<Drawer
width={640}
placement="right"
onClose={() => setOpenSubDrawer(false)}
open={openSubDrawer}
title={selectedSubItem.title}
>
<p style={{ marginBottom: 24 }}>
<strong></strong>
{selectedSubItem.description}
</p>
<p>
<strong></strong>
{selectedSubItem.time || '未设置'}
</p>
</Drawer>
)}
</div>
</div>
);