mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-23 23:16:58 +08:00
### What problem does this PR solve? feat: create blank canvas #918 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -1,8 +1,8 @@
|
||||
import { ReactComponent as NothingIcon } from '@/assets/svg/nothing.svg';
|
||||
import { IModalManagerChildrenProps } from '@/components/modal-manager';
|
||||
import { useTranslate } from '@/hooks/commonHooks';
|
||||
import { useFetchFlowTemplates } from '@/hooks/flow-hooks';
|
||||
import { useSelectItem } from '@/hooks/logicHooks';
|
||||
import { UserOutlined } from '@ant-design/icons';
|
||||
import {
|
||||
Avatar,
|
||||
Card,
|
||||
@ -79,7 +79,7 @@ const CreateFlowModal = ({
|
||||
<Input />
|
||||
</Form.Item>
|
||||
</Form>
|
||||
<Title level={5}>Choose from templates</Title>
|
||||
<Title level={5}>Create from templates</Title>
|
||||
<Flex vertical gap={16}>
|
||||
{list?.map((x) => (
|
||||
<Card
|
||||
@ -90,7 +90,11 @@ const CreateFlowModal = ({
|
||||
onClick={handleItemClick(x.id)}
|
||||
>
|
||||
<Space size={'middle'}>
|
||||
<Avatar size={40} icon={<UserOutlined />} src={x.avatar} />
|
||||
{x.avatar ? (
|
||||
<Avatar size={40} icon={<NothingIcon />} src={x.avatar} />
|
||||
) : (
|
||||
<NothingIcon width={40} height={30} />
|
||||
)}
|
||||
<b>{x.title}</b>
|
||||
</Space>
|
||||
<p>{x.description}</p>
|
||||
|
||||
Reference in New Issue
Block a user