/* * @Author: cclu * @Date: 2021-12-13 11:01:23 * @LastEditors: cclu 1106109051@qq.com * @LastEditTime: 2025-02-26 11:43:08 * @FilePath: \cloud-platform\src\layouts\UserLayout.tsx * @Description: * * Copyright (c) 2022 by cclu/杭州驿商科技, All Rights Reserved. */ import type { MenuDataItem } from '@ant-design/pro-layout'; import { DefaultFooter, getMenuData, getPageTitle } from '@ant-design/pro-layout'; import { Helmet, HelmetProvider } from 'react-helmet-async'; import type { ConnectProps } from 'umi'; import { Link, useIntl, connect } from 'umi'; import React, { useEffect } from 'react'; import type { ConnectState } from '@/models/connect'; import logo from '../assets/logo.png'; import { VERSION, BUILD_TIME, GIT_HASH } from '../versionEnv'; import styles from './UserLayout.less'; export type UserLayoutProps = { breadcrumbNameMap: Record; } & Partial; const UserLayout: React.FC = (props) => { const { route = { routes: [], }, } = props; const { routes = [] } = route; const { children, location = { pathname: '', }, } = props; const { formatMessage } = useIntl(); const { breadcrumb } = getMenuData(routes); const title = getPageTitle({ pathname: location.pathname, // formatMessage, breadcrumb, ...props, }); return ( {title}
logo 驿商云
{children}
); }; export default connect(({ settings }: ConnectState) => ({ ...settings }))(UserLayout);