VueJs 2.6.11 + Vuetify - vdata-table - BUG?? - 即使标题被隐藏,我如何保持宽度列?

问题描述

我有同样的问题,但使用 Vuejs2 :Vuetify v1.5 data table,how to determine column widths when the header is hidden

这是我所拥有的:

<v-data-table 
:headers="headers" 
:items="items"
item-key="id"
hide-default-footer 
disable-pagination 
:hide-default-header="false"
>

对于标题

headers: [
  { text: 'a',value: 'a',width: "4%" },{ text: 'b',value: 'b',{ text: 'c',value: 'c',width: "7%" },{ text: 'd',value: 'd',width: "10%" },{ text: 'e',value: 'e',width: "8%" },{ text: 'f',value: 'f',width: "13%" },{ text: 'g',value: 'g',{ text: 'h',value: 'h',{ text: 'i',value: 'i',width: "31%" }
]

宽度总和为 100%,因此不应出现奇怪的行为。 当我设置 :hide-default-header="true" 时,所有列都会更改宽度。 我怎样才能强制列的宽度??

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)