Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Table]: 表头分组无数据状态下Empty展示问题 #768

Closed
xingyuefeng opened this issue Apr 15, 2022 · 1 comment
Closed

[Table]: 表头分组无数据状态下Empty展示问题 #768

xingyuefeng opened this issue Apr 15, 2022 · 1 comment
Assignees
Projects

Comments

@xingyuefeng
Copy link
Member

注意:根据下面内容复现错误问题,以方便测试。

描述错误

表头分组无数据Empty组件宽度不全

提供在线重现示例

import ReactDOM from 'react-dom';
import { Table, Button, Empty } from 'uiw';

const columns = [
  {
    ellipsis: true, 
    title: '姓名',
    key: 'name', 
  }, {
    title: '年龄',
    key: 'age',
  }, {
    title: '地址',
    key: 'info',
    children: [{
        title: '地址2',
        key: 'info2',
    }, {
      title: '地址3',
        key: 'info3',
    }]
  }, {
    title: '操作',
    key: 'edit',
   
  },
];
const dataSource = [];
const Demo = () => (
  <div>
    <Table
      columns={columns}
      data={dataSource}
      empty={<Empty />}  
    />
  </div>
);
ReactDOM.render(<Demo />, _mount_);

预期行为

Empty组件能完整铺满Table

截图

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

No branches or pull requests

3 participants