import React, { Fragment } from 'react'; import { ArrowRightOutlined, EditOutlined } from '@ant-design/icons'; import { Button, Divider } from 'antd'; import { WebsiteOverview } from '../components/WebsiteOverview'; import { useCurrentWorkspaceId } from '../store/user'; import { Loading } from '../components/Loading'; import { useWorspaceWebsites } from '../api/model/website'; import { NoWorkspaceTip } from '../components/NoWorkspaceTip'; import { useNavigate } from 'react-router'; export const Dashboard: React.FC = React.memo(() => { const workspaceId = useCurrentWorkspaceId()!; const { isLoading, websites } = useWorspaceWebsites(workspaceId); const navigate = useNavigate(); if (!workspaceId) { return ; } if (isLoading) { return ; } return (
Dashboard
{websites.map((website, i) => ( {i !== 0 && } } /> ))}
); }); Dashboard.displayName = 'Dashboard';