uView icon indicating copy to clipboard operation
uView copied to clipboard

table表格宽度无效

Open BenXi630 opened this issue 4 years ago • 6 comments

微信小程序table宽度无效果,最新版本。 <u-table> <u-tr> <u-th width="60%">订单号</u-th> <u-th width="30%">姓名</u-th> <u-th width="10%">金额</u-th> </u-tr> <u-tr v-for="item in dataSource" :key="item.id" @click.native="handleDetails" > <u-td width="60%">{{ item.order_sn }}</u-td> <u-td width="30%">{{ item.student.name }}</u-td> <u-td width="10%">{{ item.price }}</u-td> </u-tr> </u-table> image

BenXi630 avatar May 25 '21 05:05 BenXi630

我也使用了table 发现设置宽度无效。

NiBoTe avatar Jun 03 '21 03:06 NiBoTe

我也使用了table 发现设置宽度无效。

有解决办法吗

BenXi630 avatar Jun 03 '21 03:06 BenXi630

只需要给tr 加上  display: flex; 就可以了。  

 

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2021年6月3日(星期四) 中午11:45 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [YanxinNet/uView] table表格宽度无效 (#968)

我也使用了table 发现设置宽度无效。

有解决办法吗

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

NiBoTe avatar Jun 03 '21 03:06 NiBoTe

只需要给tr 加上  display: flex; 就可以了。     ------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2021年6月3日(星期四) 中午11:45 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [YanxinNet/uView] table表格宽度无效 (#968) 我也使用了table 发现设置宽度无效。 有解决办法吗 — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

谢谢

BenXi630 avatar Jun 03 '21 03:06 BenXi630

@BenXi630 , 加上 display: flex 能成功么?我这还是不行。

u-tr {
	display: flex;
}

note: @NiBoTe

jackywu avatar Nov 14 '21 07:11 jackywu

<u-th class="remark">备注</u-th> 样式 .remark{ flex: 3; }

yx1102 avatar Dec 21 '21 06:12 yx1102