Skip to content

Commit

Permalink
Merge pull request #518 from oceanbase/dengfuping-feature-design
Browse files Browse the repository at this point in the history
[Feature Branch] improve(design): hide Table empty when loading
  • Loading branch information
dengfuping authored Mar 20, 2024
2 parents f8642f3 + 8bd8ba7 commit fb38101
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/design/src/spin/style/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ const genNestedSizeStyle = (spinDotSize: number, token: SpinToken): CSSObject =>
const textPaddingTop = (spinDotHight - fontSize) / 2 + 2;
return {
// only work for oceanbase indicator
[`&${componentCls}-oceanbase`]: {
// `& > ${componentCls}-oceanbase` is compatible with double .ant-spin like Table loading
[`&${componentCls}-oceanbase, & > ${componentCls}-oceanbase`]: {
[`${componentCls}-dot`]: {
marginLeft: dotMarginLeft,
marginTop: dotMarginTop,
Expand Down
10 changes: 10 additions & 0 deletions packages/design/src/table/style/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,16 @@ export const genTableStyle: GenerateStyle<TableToken> = (token: TableToken): CSS
},
},

// loading style
[`${componentCls}-wrapper ${antCls}-spin-blur`]: {
[`${componentCls}-tbody`]: {
[`${componentCls}-placeholder`]: {
// hide empty when Table loading
visibility: 'hidden',
},
},
},

// 分页器样式
[`${componentCls}-wrapper`]: {
[`${componentCls}-pagination`]: {
Expand Down

0 comments on commit fb38101

Please sign in to comment.