Commit 0a189e71 by wd

修改logo样式,添加返回顶部按钮,添加搜索框复原

parent 83cde5c0
...@@ -13,15 +13,21 @@ ...@@ -13,15 +13,21 @@
padding-top: 2px; padding-top: 2px;
} }
@media (max-width: 768px) { @media (max-width: 768px) {
.banner1,.banner1 >.imgbox, .banner1 >.imgbox > a,.banner1 >.imgbox > a >img{ .banner1, .banner1 > .imgbox, .banner1 > .imgbox > a, .banner1 > .imgbox > a > img {
height: 577px !important; height: 577px !important;
margin-top: 6.5%; / / margin-top: 6.5 %;
} }
input#left,input#right{
input#left, input#right {
top: 280px !important; top: 280px !important;
padding: 1px; padding: 1px;
} }
#topBtn {
width: 8% !important;
}
} }
@media (max-width: 1024px) { @media (max-width: 1024px) {
.rating-result::before, .rating-result>span::before { .rating-result::before, .rating-result>span::before {
-webkit-mask-size: 1rem 1rem; -webkit-mask-size: 1rem 1rem;
...@@ -33,10 +39,25 @@ ...@@ -33,10 +39,25 @@
p.flashsale-title{ p.flashsale-title{
font-size: 18px; font-size: 18px;
} }
#topBtn{
width: 6% !important;
}
}
#topBtn{
bottom: 5%;
right: 2%;
position:fixed;
width: 4%;
} }
</style> </style>
<div class="banner1"></div> <div class="banner1"></div>
<a href="#top" title="go to header" id="topBtn" style="display: none;">
<img data-src="/media/wysiwyg/goTop.png" src="/media/wysiwyg/goTop.png">
</a>
<script> <script>
require([ require([
'jquery' 'jquery'
...@@ -236,6 +257,34 @@ ...@@ -236,6 +257,34 @@
} }
return mobile_flag; return mobile_flag;
} }
window.onscroll = function (){
var top = document.getElementById("topBtn");
if (document.documentElement.scrollTop > 200 || document.body.scrollTop > 200){
top.style.display="block";
}else {
top.style.display="none";
}
}
var userAgentInfo = navigator.userAgent;
var Agents = new Array("Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod");
var flag = true;
for (var v = 0; v < Agents.length; v++) {
if (userAgentInfo.indexOf(Agents[v]) > 0) { flag = false; break; }
}
require(['jquery'],function ($){
if (flag){
var imgH = $('.logo').height();
imgH= Math.ceil(imgH/3);
$('.header ').css('margin-bottom',imgH);
}else{
var headerH = $('.page-header').outerHeight(true);
$('.columns').css('margin-top',headerH);
}
});
</script> </script>
<?php echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('home_top_category_thumnail')->toHtml();?> <?php echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('home_top_category_thumnail')->toHtml();?>
<?php echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('home_new_arrivals')->toHtml();?> <?php echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('home_new_arrivals')->toHtml();?>
......
...@@ -65,8 +65,13 @@ $quickSearchUrl = $allowedSuggestion ? $escaper->escapeUrl($helper->getSuggestUr ...@@ -65,8 +65,13 @@ $quickSearchUrl = $allowedSuggestion ? $escaper->escapeUrl($helper->getSuggestUr
require([ require([
'jquery' 'jquery'
], function ($) { ], function ($) {
$("#search").on("focus",function () { $("#search").on("click",function () {
$(this).css("width","500px").css("font-size","20px"); $(this).css("width","500px").css("font-size","20px");
}); });
$('#search').on('blur',function (){
$(this).attr("style","");
});
}); });
</script> </script>
...@@ -1980,7 +1980,7 @@ background-color: #000; ...@@ -1980,7 +1980,7 @@ background-color: #000;
@media (min-width: 768px){ @media (min-width: 768px){
.header-top.header-fixed .header.content{ .header-top.header-fixed .header.content{
padding-bottom: 15px; //padding-bottom: 15px;
margin-top: 3%; margin-top: 3%;
} }
.review-list .review-details{ .review-list .review-details{
...@@ -2158,7 +2158,7 @@ background-color: #000; ...@@ -2158,7 +2158,7 @@ background-color: #000;
} }
.header-top.header-fixed{ .header-top.header-fixed{
height: 110px !important; //height: 110px !important;
} }
.page-with-filter .toolbar .modes{ .page-with-filter .toolbar .modes{
...@@ -2565,5 +2565,7 @@ button.primary.action.create { ...@@ -2565,5 +2565,7 @@ button.primary.action.create {
strong#block-related-heading,strong#block-upsell-heading{ font-weight: 600; color: #000;font-size: 16px;} strong#block-related-heading,strong#block-upsell-heading{ font-weight: 600; color: #000;font-size: 16px;}
.breeze-block-sidebar > .title, .breeze-block-sidebar .block-title, .paypal-review .paypal-review-title, .block > .title, .block .block-title{
padding:0 !important;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment