update
This commit is contained in:
parent
8f8b34763f
commit
0410fea3a1
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "ant-design-pro",
|
||||
"version": "4.5.54",
|
||||
"version": "4.5.57",
|
||||
"private": true,
|
||||
"description": "An out-of-box UI solution for enterprise applications",
|
||||
"scripts": {
|
||||
|
||||
@ -5,9 +5,18 @@
|
||||
// export default PageLoading;
|
||||
import React from 'react';
|
||||
import SkeletonLoading from '../SkeletonLoading';
|
||||
import { SimplePageTransition } from '../PageTransition';
|
||||
|
||||
const PageLoading: React.FC = () => {
|
||||
return <SkeletonLoading type="page" />;
|
||||
interface PageLoadingProps {
|
||||
enableAnimation?: boolean;
|
||||
}
|
||||
|
||||
const PageLoading: React.FC<PageLoadingProps> = ({ enableAnimation = false }) => {
|
||||
return (
|
||||
<SimplePageTransition enableAnimation={enableAnimation}>
|
||||
<SkeletonLoading type="page" />
|
||||
</SimplePageTransition>
|
||||
);
|
||||
};
|
||||
|
||||
export default PageLoading;
|
||||
@ -23,6 +23,8 @@ import type { ConnectState } from '@/models/connect';
|
||||
import { getMatchMenu } from '@umijs/route-utils';
|
||||
import logo from '../assets/logo.png';
|
||||
import './BasicLayout.less'
|
||||
import PageLoading from '@/components/PageLoading';
|
||||
import { SimplePageTransition } from '@/components/PageTransition';
|
||||
import { DoubleRightOutlined } from '@ant-design/icons';
|
||||
import * as Icon from '@ant-design/icons'
|
||||
import IconFont from '@/components/IconFont';
|
||||
@ -92,6 +94,7 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
|
||||
|
||||
|
||||
const [activeKey, setActiveKey] = useState<string>(location?.pathname || '/')
|
||||
const [isFromMenu, setIsFromMenu] = useState<boolean>(true) // 默认为true,首次加载显示动画
|
||||
const menuDataRef = useRef<MenuDataItem[]>([]);
|
||||
const { formatMessage } = useIntl();
|
||||
|
||||
@ -915,6 +918,7 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
|
||||
return defaultDom;
|
||||
}
|
||||
return <Link to={menuItemProps.path || '/'} onClick={() => {
|
||||
setIsFromMenu(true) // 左侧菜单点击,启用动画
|
||||
}}>
|
||||
{defaultDom}
|
||||
{/* {menuItemProps.name} */}
|
||||
@ -980,6 +984,7 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
|
||||
hideAdd
|
||||
type="editable-card"
|
||||
onChange={(value) => {
|
||||
setIsFromMenu(false) // tab切换,禁用动画
|
||||
history.push(value)
|
||||
setActiveKey(value)
|
||||
}}
|
||||
@ -1039,9 +1044,11 @@ const BasicLayout: React.FC<BasicLayoutProps> = (props) => {
|
||||
<TabPane
|
||||
tab={item.title} key={item?.path}
|
||||
style={{ padding: 24, paddingTop: 0 }}>
|
||||
<Suspense fallback={<div>Loading...</div>}>
|
||||
<Suspense fallback={<PageLoading enableAnimation={isFromMenu} />}>
|
||||
<Authorized authority={authorized!.authority} noMatch={noMatch}>
|
||||
{item.children}
|
||||
<SimplePageTransition enableAnimation={isFromMenu}>
|
||||
{item.children}
|
||||
</SimplePageTransition>
|
||||
</Authorized>
|
||||
</Suspense>
|
||||
</TabPane>)
|
||||
|
||||
@ -56,18 +56,18 @@ const UserLayout: React.FC<UserLayoutProps> = (props) => {
|
||||
<div className={styles.lang}>
|
||||
<Link to="/">
|
||||
<img alt="logo" className={styles.logo} src={logo} />
|
||||
<span className={styles.headtitle}>云南交投</span>
|
||||
<span className={styles.headtitle}>驿商云</span>
|
||||
</Link>
|
||||
</div>
|
||||
<div className={styles.content}>
|
||||
|
||||
{children}
|
||||
</div>
|
||||
{/* <DefaultFooter
|
||||
<DefaultFooter
|
||||
copyright={`Copyright © 2013-${new Date().getFullYear()} Eshang Cloud. All Rights Reserved. 驿商云 版权所有 V${VERSION || ''}`}
|
||||
// copyright={`Copyright © 2013-${new Date().getFullYear()} Eshang Cloud. All Rights Reserved. 驿商云 版权所有 V6.6.6`}
|
||||
links={[]}
|
||||
/> */}
|
||||
/>
|
||||
</div>
|
||||
</HelmetProvider>
|
||||
);
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
// 由 scripts/writeVersion.js 自动生成
|
||||
export const VERSION = "4.5.54";
|
||||
export const GIT_HASH = "26ef480";
|
||||
export const BUILD_TIME = "2025-09-10T08:05:17.397Z";
|
||||
export const VERSION = "4.5.57";
|
||||
export const GIT_HASH = "8f8b347";
|
||||
export const BUILD_TIME = "2025-09-18T01:29:44.333Z";
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user