日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

html无效的属性值,html – grid-template-areas无效的属性值

發(fā)布時(shí)間:2024/3/26 编程问答 38 豆豆
生活随笔 收集整理的這篇文章主要介紹了 html无效的属性值,html – grid-template-areas无效的属性值 小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.

@TemaniAfif提供了一個(gè)有效的解決方案但刪除了他的帖子.

簡短回答:

對于只有一列而不是兩列的行,我必須編寫“myArea myArea”以使每行的列數(shù)相同.

答案很長:如果可以縮短CSS代碼,請告訴我!

#contactForm {

display: grid;

grid-template-columns: 50% 50%;

grid-template-areas:

"lblFirstName lblLastName"

"edtFirstName edtLastName"

"lblCompany lblCompany"

"edtCompany edtCompany"

"lblEmail lblPhone"

"edtEmail edtPhone"

"lblMessage lblMessage"

"edtMessage edtMessage"

"btnSubmit btnSubmit";

grid-gap: 20px;

padding: 100px 300px;

}

label[for=firstname]

{

grid-area: lblFirstName;

}

label[for=lastName]

{

grid-area: lblLastName;

}

label[for=company]

{

grid-area: lblCompany;

}

label[for=email]

{

grid-area: lblEmail;

}

label[for=phone]

{

grid-area: lblPhone;

}

label[for=message]

{

grid-area: lblMessage;

}

input[name=firstname]

{

grid-area: edtFirstName;

}

input[name=lastName]

{

grid-area: edtLastName;

}

input[name=company]

{

grid-area: edtCompany;

}

input[name=email]

{

grid-area: edtEmail;

}

input[name=phone]

{

grid-area: edtPhone;

}

textarea[name=message]

{

grid-area: edtMessage;

}

input[type=submit]

{

grid-area: btnSubmit;

}

.inputTitle {

font-size: 20px;

}

.txtInput {

outline: none;

padding: 14px 10px;

border-radius: 3px;

border: 1px solid #d1d5da;

box-shadow: inset 0 1px 2px rgba(27,31,35,.075);

background: #fafbfc;

color: #24292e;

}

#contactSubmitBtn {

padding: 10px;

cursor: pointer;

border: none;

border-radius: 3px;

font-weight: 300px;

font-size: 18px;

background: #4285f4;

color: #ffffff;

transition: 0.3s;

}

#contactSubmitBtn:hover {

transform: translateY(-3px);

box-shadow: 0 1px 3px #343434;

background: #5396f5;

transition: 0.3s;

}

#contactMessageInput {

resize: none;

}

@media only screen and (max-width: 1300px) {

#contactForm {

padding: 100px 200px;

}

}

@media only screen and (max-width: 1100px) {

#contactForm {

padding: 100px 150px;

}

}

@media only screen and (max-width: 900px) {

#contactForm {

padding: 100px 100px;

}

}

@media only screen and (max-width: 700px) {

#contactForm {

padding: 100px 50px;

}

}

@media only screen and (max-width: 500px) {

#contactForm {

grid-template-columns: 100%;

grid-template-areas:

"lblFirstName"

"edtFirstName"

"lblLastName"

"edtLastName"

"lblCompany"

"edtCompany"

"lblEmail"

"edtEmail"

"lblPhone"

"edtPhone"

"lblMessage"

"edtMessage"

"btnSubmit";

}

}

First Name *

Last Name *

Company

E-Mail *

Phone

Your Message *

總結(jié)

以上是生活随笔為你收集整理的html无效的属性值,html – grid-template-areas无效的属性值的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯(cuò),歡迎將生活随笔推薦給好友。