wsm在html中设置td高度无效,td为什么设置了宽度却无效

如下图所示,我对td设置了196px,结果computed显示的却是233px.

百度说什么对table设置如下,也不起作用~~

border-collapse: collapse;

border-spacing: 0;

word-wrap: break-word;

word-break: break-all;

bVbwiMi?w=532&h=166

#common-box {

width: 550px;

border-radius: 4px;

margin: 0 auto;

box-sizing: border-box;

background: #ffffff;

}

#common-box .regist-login-button {

display: inline-block;

width: 100%;

height: 50px;

line-height: 50px;

text-align: center;

border-radius: 4px;

color: #ffffff;

background: pink;

font-size: 18px;

}

#common-box table tbody tr {

width: 100%;

}

#common-box table tbody tr td {

height: 50px;

color: #999999;

font-size: 14px;

position: relative;

padding: 0;

}

#common-box table tbody tr td input,

#common-box table tbody tr td select {

width: 100%;

height: 50px;

line-height: 50px;

padding-left: 20px;

border: 1px solid pink;

border-radius: 4px;

box-sizing: border-box;

}

#common-box table tbody tr td button {

width: 100%;

height: 100%;

appearance: none;

border: none;

}

#common-box table tbody tr td:first-of-type {

width: 95px;

color: #666666;

font-size: 14px;

}

#common-box table tbody tr td select {}

#common-box table tbody tr td.select-ele::after {

content: '';

display: block;

width: 36px;

height: 50px;

position: absolute;

top: 0;

right: 0;

background: pink url(../../../static/img/more.png) center center no-repeat;

border-radius: 0 4px 4px 0;

cursor: pointer;

pointer-events: none;

}

#common-box table tr .rl-td-h80 {

height: 80px;

}

#common-box table tr .rl-td-h60 {

height: 60px;

}

#common-box table tr .rl-td-h50 {

height: 50px;

}

#common-box table tr .rl-td-h40 {

height: 40px;

}

#common-box table tr .rl-td-h30 {

height: 30px;

}

#common-box table tr .rl-td-w335 {

width: 335px;

}

#common-box table tr .rl-td-w220 {

width: 220px;

}

#common-box table tr .rl-td-w205 {

width: 205px;

}

#common-box table tr .rl-td-w105 {

width: 105px;

}

#common-box table tr .rl-td-w20 {

width: 20px;

}

#common-box table tr .rl-td-w10 {

width: 10px;

}

#common-box table tr .notice {

display: none;

font-size: 12px;

color: #ff2a14;

}

#common-box #validate {

width: 100%;

height: 100%;

border: 1px solid pink;

border-radius: 4px;

font-size: 0;

}

#common-box #validate canvas {

width: 100%;

height: 100%;

border-radius: 4px;

}

#login_form {

margin-top: 50px;

padding: 0 60px;

}

#login_form table {

width: 100%;

border-collapse: collapse;

border-spacing: 0;

word-wrap: break-word;

word-break: break-all;

}

#common-box #login_form table tbody tr td:first-of-type {

width: 42px;

}

#common-box #login_form table tbody tr:last-of-type td:first-of-type {

width: 205px;

text-align: right;

}

用户名
密码

placeholder="请输入您的密码">

验证码
注册账号忘记密码

#common-box {

width: 550px;

border-radius: 4px;

margin: 0 auto;

box-sizing: border-box;

background: #ffffff;

}

#common-box .regist-login-button {

display: inline-block;

width: 100%;

height: 50px;

line-height: 50px;

text-align: center;

border-radius: 4px;

color: #ffffff;

background: pink;

font-size: 18px;

}

#common-box table tbody tr {

width: 100%;

}

#common-box table tbody tr td {

height: 50px;

color: #999999;

font-size: 14px;

position: relative;

padding: 0;

}

#common-box table tbody tr td input,

#common-box table tbody tr td select {

width: 100%;

height: 50px;

line-height: 50px;

padding-left: 20px;

border: 1px solid pink;

border-radius: 4px;

box-sizing: border-box;

}

#common-box table tbody tr td button {

width: 100%;

height: 100%;

appearance: none;

border: none;

}

#common-box table tbody tr td:first-of-type {

/* width: 95px; */

color: #666666;

font-size: 14px;

}

#common-box table tbody tr td select {}

#common-box table tbody tr td.select-ele::after {

content: '';

display: block;

width: 36px;

height: 50px;

position: absolute;

top: 0;

right: 0;

background: pink url(../../../static/img/more.png) center center no-repeat;

border-radius: 0 4px 4px 0;

cursor: pointer;

pointer-events: none;

}

#common-box table tr .rl-td-h80 {

height: 80px;

}

#common-box table tr .rl-td-h60 {

height: 60px;

}

#common-box table tr .rl-td-h50 {

height: 50px;

}

#common-box table tr .rl-td-h40 {

height: 40px;

}

#common-box table tr .rl-td-h30 {

height: 30px;

}

#common-box table tr .rl-td-w365 {

width: 365px;

}

#common-box table tr .rl-td-w255 {

width: 255px;

}

#common-box table tr .rl-td-w220 {

width: 220px;

}

#common-box table tr .rl-td-w205 {

width: 205px;

}

#common-box table tr .rl-td-w105 {

width: 105px;

}

#common-box table tr .rl-td-w100 {

width: 100px;

}

#common-box table tr .rl-td-w95 {

width: 95px;

}

#common-box table tr .rl-td-w45 {

width: 45px;

}

#common-box table tr .rl-td-w20 {

width: 20px;

}

#common-box table tr .rl-td-w10 {

width: 10px;

}

#common-box table tr .notice {

display: none;

font-size: 12px;

color: #ff2a14;

}

#common-box #validate {

width: 100%;

height: 100%;

border: 1px solid pink;

border-radius: 4px;

font-size: 0;

}

#common-box #validate canvas {

width: 100%;

height: 100%;

border-radius: 4px;

}

#login_form {

padding: 0 60px;

}

#login_form table {

width: 100%;

}

#common-box #login_form table tbody tr td:first-of-type {

/* width: 45px; */

}

#common-box #login_form table tbody tr:last-of-type td:first-of-type {

text-align: right;

}

用户登录

用户名密码

placeholder="请输入您的密码">

验证码 注册账号 忘记密码
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值