最近项目中遇到一个需求调整:table中的文字过长居左排列,数字居右排列

然后看了一下官方文档:

先上图展示一下react——Table组件列中靠左 靠右对齐解决方案

 

左边是需要的效果:

  className: 'column-left',

 

{
      title: '执行内容',
      dataIndex: 'implementContent',
      className: 'column-left',
      key: 'implementContent'
    }

//需要加入的样式
td.column-left{
  text-align: left !important;
}
td.column-right{
  text-align: right !important;
}

 

相关文章:

  • 2022-12-23
  • 2021-09-06
  • 2022-12-23
  • 2022-12-23
  • 2021-07-13
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-01-20
  • 2022-02-09
  • 2021-12-23
  • 2021-11-29
  • 2021-06-12
  • 2021-06-07
  • 2022-12-23
相关资源
相似解决方案