|
|
|
@ -5,6 +5,8 @@ import { Icon } from '@iconify/react';
|
|
|
|
|
import { Button, Tooltip } from 'antd';
|
|
|
|
|
import { MembersPanel } from './MembersPanel';
|
|
|
|
|
import { CommonPanelWrapper } from '../common/Wrapper';
|
|
|
|
|
import { usePanelWindow } from '@/hooks/usePanelWindow';
|
|
|
|
|
import { OpenedPanelTip } from '@/components/OpenedPanelTip';
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 群组面板通用包装器
|
|
|
|
@ -21,10 +23,24 @@ export const GroupPanelWrapper: React.FC<GroupPanelWrapperProps> = React.memo(
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const { hasOpenedPanel, openPanelWindow, closePanelWindow } =
|
|
|
|
|
usePanelWindow(`/panel/group/${props.groupId}/${props.panelId}`);
|
|
|
|
|
if (hasOpenedPanel) {
|
|
|
|
|
return <OpenedPanelTip onClosePanelWindow={closePanelWindow} />;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<CommonPanelWrapper
|
|
|
|
|
header={panelInfo.name}
|
|
|
|
|
actions={(setRightPanel) => [
|
|
|
|
|
<Tooltip key="open" title={t('在新窗口打开')}>
|
|
|
|
|
<Button
|
|
|
|
|
icon={
|
|
|
|
|
<Icon className="anticon text-2xl" icon="mdi:dock-window" />
|
|
|
|
|
}
|
|
|
|
|
onClick={openPanelWindow}
|
|
|
|
|
/>
|
|
|
|
|
</Tooltip>,
|
|
|
|
|
<Tooltip key="members" title={t('成员列表')}>
|
|
|
|
|
<Button
|
|
|
|
|
icon={
|
|
|
|
|