File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
client/packages/lowcoder-design/src/components Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 1
1
import styled , { css } from "styled-components" ;
2
2
import { CSSProperties } from "react" ;
3
+ import { default as Skeleton } from "antd/es/skeleton" ;
3
4
4
5
type LoadingContainerProps = {
5
6
$backgroundColor : string ;
@@ -12,6 +13,8 @@ const LoadingWrapper = styled.div`
12
13
flex-direction: column;
13
14
align-items: center;
14
15
justify-content: center;
16
+ width: 100%;
17
+ height: 100%;
15
18
` ;
16
19
17
20
// Loading
@@ -61,6 +64,10 @@ const Load2 = styled.div<LoadingContainerProps>`
61
64
linear-gradient(to right, ${ ( props ) => props . $color } a3, ${ ( props ) => props . $color } 1a);
62
65
` ;
63
66
67
+ const StyledSkeleton = styled ( Skeleton . Button ) `
68
+ height: 100%;
69
+ ` ;
70
+
64
71
type LoadingProps = {
65
72
backgroundColor ?: string ;
66
73
color ?: string ;
@@ -77,14 +84,15 @@ export const Loading = (props: LoadingProps) => {
77
84
} ;
78
85
return (
79
86
< LoadingWrapper className = { props . className } style = { props . style } >
80
- < ContainerX { ...loadingProps } >
87
+ { /* <ContainerX {...loadingProps}>
81
88
<Container {...loadingProps}>
82
89
<Load1 {...loadingProps} />
83
90
</Container>
84
91
<Container {...loadingProps}>
85
92
<Load2 {...loadingProps} />
86
93
</Container>
87
- </ ContainerX >
94
+ </ContainerX> */ }
95
+ < StyledSkeleton active block style = { { height : '100%' , animationDuration : '2s' } } />
88
96
</ LoadingWrapper >
89
97
) ;
90
98
} ;
You can’t perform that action at this time.
0 commit comments