Lock table cells to their default size regardless of content

前端 未结 8 1936
栀梦
栀梦 2021-01-02 13:25

If I have

8条回答
  •  醉梦人生
    2021-01-02 13:52

    I have managed to do this without fixed table layout. The cell's css:

    .dataCell {
      display: table-cell;
      padding: 2px 15px 2px 15px;
      white-space: nowrap;
      text-overflow: ellipsis;
      overflow: hidden;
      width: auto;
      max-width: 1px;
    }
    

提交回复
热议问题