diff --git a/css/details.css b/css/details.css index 6095fd6..38a6406 100644 --- a/css/details.css +++ b/css/details.css @@ -1287,7 +1287,29 @@ z-index: 1; background-color: rgba(0, 0, 0, 0.20392157); } +@media screen and (max-width: 1200px) { + header.page-header { + min-width: auto !important; + } + header.page-header .box { + width: 100vw; + } + .head-top.flexacenter { + max-width: 1200px !important; + width: initial !important; + margin: 20px 10px 30px !important; + } + .head-top.flexacenter .input-box { + margin-right: 0; + } +} @media screen and (max-width: 850px) { + header.page-header { + display: none !important; + } + .head-top .post-list { + display: none !important; + } #details { padding: 10px 10px 0; } @@ -1360,6 +1382,13 @@ } } @media screen and (max-width: 500px) { + .head-top.flexacenter .input-box { + width: inherit; + } + .head-top.flexacenter .input-box .input, + .head-top.flexacenter .input-box .placeholder { + display: none; + } #details .answer-discuss .comments-box .comments-item .comments-header { font-size: 12px; } diff --git a/css/details.less b/css/details.less index a4c07dd..a278c7e 100644 --- a/css/details.less +++ b/css/details.less @@ -1524,8 +1524,35 @@ background-color: rgba(0, 0, 0, 0.20392157); } +@media screen and (max-width: 1200px) { + header.page-header { + min-width: auto !important; + .box { + width: 100vw; + } + } + + .head-top.flexacenter { + max-width: 1200px !important; + width: initial !important; + margin: 20px 10px 30px !important; + + .input-box { + margin-right: 0; + } + } +} + // 媒体查询 最大宽度 850px 时 @media screen and (max-width: 850px) { + header.page-header { + display: none !important; + } + + .head-top .post-list { + display: none !important; + } + #details { padding: 10px 10px 0; @@ -1640,6 +1667,13 @@ } @media screen and (max-width: 500px) { + .head-top.flexacenter .input-box { + width: inherit; + .input, + .placeholder { + display: none; + } + } #details { .answer-discuss { .comments-box { diff --git a/css/public.css b/css/public.css index 124ec8f..9dadbc0 100644 --- a/css/public.css +++ b/css/public.css @@ -1576,6 +1576,7 @@ body { } .head-top .logo { height: 52px; + margin-right: 10px; } .head-top .input-box { width: 370px; @@ -1949,3 +1950,140 @@ td { -webkit-transform: scale(1); } } +.head-pop { + position: fixed; + top: 0; + left: 100%; + width: 100vw; + height: 100vh; + background-color: rgba(0, 0, 0, 0.70588235); + z-index: 100; +} +.head-pop.head-pop-show { + left: 0; +} +.head-pop.head-pop-show .head-more-pop { + animation: slide-in-left 0.5s ease-out forwards; +} +.head-pop .head-more-pop { + position: absolute; + top: 0; + height: 100vh; + width: 80vw; + right: 0; + background-color: #fff; + overflow: auto; + transition: all 0.2s; + right: -100%; + opacity: 0; + z-index: 100; +} +@keyframes slide-in-left { + 0% { + right: -100%; + opacity: 0; + } + 100% { + right: 0; + opacity: 1; + } +} +.head-pop .head-more-pop .head-more-userinfo { + height: 108px; + margin-left: 24px; + padding-right: 27px; + box-sizing: border-box; + border-bottom: 0.5px solid #ebebeb; + justify-content: space-between; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-left .head-more-userinfo-avatar { + margin-right: 9px; + width: 48px; + height: 48px; + border-radius: 50%; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-left .head-more-userinfo-username { + font-size: 13.5px; + color: #333333; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-right { + width: 84px; + height: 30px; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-right .information-box { + position: relative; + width: 16.5px; + height: 16.5px; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-right .information-box .information-icon { + width: 16.5px; + height: 16.5px; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-right .red-dot { + position: absolute; + right: -7.5px; + top: -7.5px; + width: 13.5px; + height: 13.5px; + color: #fff; + border-radius: 24px; + background-color: #fd3f5d; + font-size: 9.75px; +} +.head-pop .head-more-pop .head-more-userinfo .head-more-right .loginBtn { + width: 84px; + height: 30px; + border-radius: 117px; + background-color: #62b1ff; + color: #fff; + font-size: 12.75px; +} +.head-pop .head-more-pop .tab-list { + padding-right: 27px; + margin-left: 24px; + border-bottom: 0.5px solid #ebebeb; +} +.head-pop .head-more-pop .tab-list .tab-item { + height: 54px; + margin: 12.3px 0; + border-radius: 8.25px; + padding-left: 24px; + font-size: 13.5px; + color: #555555; + text-decoration: none; +} +.head-pop .head-more-pop .tab-list .tab-item.pitch { + background-color: #50e3c2; + font-weight: 650; + color: #000; +} +.head-pop .head-more-pop .head-more-post { + color: #000; + font-size: 15px; + margin: 48px 0 100px; +} +.head-pop .head-more-pop .head-more-post .head-more-post-icon { + width: 18px; + height: 18px; + margin-right: 5px; + background-color: #fddf6d; + border-radius: 50%; +} +.head-pop .head-more-pop .head-more-post .head-more-post-icon .head-more-post-img { + width: 9px; + height: 9px; +} +.head-pop .head-more-pop .cross-icon { + width: 12px; + height: 12px; + padding: 15px; + position: fixed; + bottom: 11.25px; + left: calc(50% + 45px); + transform: translateX(-50%); + display: flex; + align-items: center; + justify-content: center; + margin: 0 auto; + box-sizing: content-box; +} diff --git a/css/public.less b/css/public.less index 4972a2d..107a286 100644 --- a/css/public.less +++ b/css/public.less @@ -1903,6 +1903,7 @@ body { .logo { height: 52px; + margin-right: 10px; } .input-box { @@ -2343,3 +2344,162 @@ td { -webkit-transform: scale(1); } } + +.head-pop { + position: fixed; + top: 0; + left: 100%; + width: 100vw; + height: 100vh; + background-color: rgba(0, 0, 0, 0.70588235); + z-index: 100; + + &.head-pop-show { + left: 0; + + .head-more-pop { + animation: slide-in-left 0.5s ease-out forwards; + } + } + + .head-more-pop { + position: absolute; + top: 0; + height: 100vh; + width: 80vw; + right: 0; + background-color: #fff; + overflow: auto; + transition: all 0.2s; + right: -100%; + opacity: 0; + z-index: 100; + + @keyframes slide-in-left { + 0% { + right: -100%; + opacity: 0; + } + 100% { + right: 0; + opacity: 1; + } + } + + .head-more-userinfo { + height: 108px; + margin-left: 24px; + padding-right: 27px; + box-sizing: border-box; + border-bottom: 0.5px solid #ebebeb; + justify-content: space-between; + + .head-more-left { + .head-more-userinfo-avatar { + margin-right: 9px; + width: 48px; + height: 48px; + border-radius: 50%; + } + + .head-more-userinfo-username { + font-size: 13.5px; + color: #333333; + } + } + + .head-more-right { + width: 84px; + height: 30px; + + .information-box { + position: relative; + width: 16.5px; + height: 16.5px; + + .information-icon { + width: 16.5px; + height: 16.5px; + } + } + + .red-dot { + position: absolute; + right: -7.5px; + top: -7.5px; + width: 13.5px; + height: 13.5px; + color: #fff; + border-radius: 24px; + background-color: #fd3f5d; + font-size: 9.75px; + } + + .loginBtn { + width: 84px; + height: 30px; + border-radius: 117px; + background-color: #62b1ff; + color: #fff; + font-size: 12.75px; + } + } + } + + .tab-list { + padding-right: 27px; + margin-left: 24px; + border-bottom: 0.5px solid #ebebeb; + + .tab-item { + height: 54px; + margin: 12.3px 0; + border-radius: 8.25px; + padding-left: 24px; + font-size: 13.5px; + color: #555555; + text-decoration: none; + + &.pitch { + background-color: #50e3c2; + font-weight: 650; + color: #000; + } + } + } + + .head-more-post { + color: #000; + font-size: 15px; + margin: 48px 0 100px; + + .head-more-post-icon { + width: 18px; + height: 18px; + margin-right: 5px; + background-color: #fddf6d; + border-radius: 50%; + + .head-more-post-img { + width: 9px; + height: 9px; + } + } + } + + .cross-icon { + width: 12px; + height: 12px; + padding: 15px; + position: fixed; + bottom: 11.25px; + left: calc(50% + 45px); + transform: translateX(-50%); + display: flex; + align-items: center; + justify-content: center; + margin: 0 auto; + box-sizing: content-box; + } + } +} diff --git a/details.html b/details.html index f6600ce..ef041a9 100644 --- a/details.html +++ b/details.html @@ -16,6 +16,62 @@
+ + + + + +