diff --git a/src/renderer/src/pages/home/components/Assistants.tsx b/src/renderer/src/pages/home/components/Assistants.tsx index 28c806ad..cf001976 100644 --- a/src/renderer/src/pages/home/components/Assistants.tsx +++ b/src/renderer/src/pages/home/components/Assistants.tsx @@ -2,8 +2,7 @@ import { FC, useRef } from 'react' import styled from 'styled-components' import useAssistants from '@renderer/hooks/useAssistants' import { Assistant } from '@renderer/types' -import { Button, Dropdown, MenuProps } from 'antd' -import { MoreOutlined } from '@ant-design/icons' +import { Dropdown, MenuProps } from 'antd' import { last } from 'lodash' import AssistantSettingPopup from '@renderer/components/Popups/AssistantSettingPopup' import { DeleteOutlined, EditOutlined } from '@ant-design/icons' @@ -16,7 +15,6 @@ interface Props { const Assistants: FC = ({ activeAssistant, onActive }) => { const { assistants, removeAssistant, updateAssistant } = useAssistants() const targetAssistant = useRef(null) - const menuOpenRef = useRef(false) const onDelete = (assistant: Assistant) => { removeAssistant(assistant.id) @@ -61,17 +59,6 @@ const Assistants: FC = ({ activeAssistant, onActive }) => { onActive(assistant)} className={assistant.id === activeAssistant?.id ? 'active' : ''}> - (targetAssistant.current = assistant)}> - e.stopPropagation()}> - - - {assistant.name} {assistant.description} @@ -134,27 +121,4 @@ const AssistantLastMessage = styled.div` height: 20px; ` -const MenuButton = styled(Button)` - position: absolute; - width: 28px; - height: 28px; - padding: 0; - right: 6px; - top: 6px; - font-size: 18px; - border-radius: 50%; - transition: background-color 0.2s ease; - z-index: 10; - .anticon { - transition: all 0.3s ease; - color: var(--color-icon); - } - &:hover { - background-color: #ffffff30; - .anticon { - color: white; - } - } -` - export default Assistants