header搜索框样式错乱调整
All checks were successful
Gitea Actions Official-website / deploy-dev (push) Successful in 4s
All checks were successful
Gitea Actions Official-website / deploy-dev (push) Successful in 4s
This commit is contained in:
@@ -9,7 +9,7 @@
|
|||||||
<!-- banner-->
|
<!-- banner-->
|
||||||
<div class="oidx-banner">
|
<div class="oidx-banner">
|
||||||
{notempty name="focus_images"}
|
{notempty name="focus_images"}
|
||||||
<div class="swiper-container bannerswiper">
|
<div class="swiper-container bannerswiper" style="background: #fff;">
|
||||||
<div class="swiper-wrapper">
|
<div class="swiper-wrapper">
|
||||||
{volist name="focus_images" id="fi"}
|
{volist name="focus_images" id="fi"}
|
||||||
<div class="swiper-slide">
|
<div class="swiper-slide">
|
||||||
|
|||||||
@@ -324,8 +324,14 @@
|
|||||||
height: 14px;
|
height: 14px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
opacity: 0.6;
|
opacity: 0.6;
|
||||||
}
|
|
||||||
|
|
||||||
|
}
|
||||||
|
.search-clear-box {
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
/* .search-clear-btn {
|
||||||
|
border-right: 1px solid #eee;
|
||||||
|
} */
|
||||||
.search-input-box .search-clear-btn:hover {
|
.search-input-box .search-clear-btn:hover {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
@@ -334,8 +340,13 @@
|
|||||||
width: 18px;
|
width: 18px;
|
||||||
height: 18px;
|
height: 18px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
.search-submit-box {
|
||||||
|
border-left: 1px solid #d9d9d9;
|
||||||
|
padding-left:10px;
|
||||||
|
max-height: 18px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.search-history {
|
.search-history {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
@@ -407,6 +418,10 @@
|
|||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: #aaa;
|
color: #aaa;
|
||||||
}
|
}
|
||||||
|
.mobile-header-right {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<header>
|
<header>
|
||||||
<div class="mobile-header-box">
|
<div class="mobile-header-box">
|
||||||
@@ -514,10 +529,15 @@
|
|||||||
<img src="__IMAGES__/header/x.png" class="modal-close">
|
<img src="__IMAGES__/header/x.png" class="modal-close">
|
||||||
<div class="search-input-box">
|
<div class="search-input-box">
|
||||||
<input type="text" placeholder="{:lang_i18n('请输入搜索关键词')}" id="searchInput">
|
<input type="text" placeholder="{:lang_i18n('请输入搜索关键词')}" id="searchInput">
|
||||||
|
|
||||||
|
<div class="search-clear-box">
|
||||||
<img src="__IMAGES__/header/x.png" alt="{:lang_i18n('清除')}" class="search-clear-btn" id="searchClearBtn" style="display: none;">
|
<img src="__IMAGES__/header/x.png" alt="{:lang_i18n('清除')}" class="search-clear-btn" id="searchClearBtn" style="display: none;">
|
||||||
<span style="width: 1px; color:#d9d9d9;margin: 0 10px;">|</span>
|
</div>
|
||||||
|
<!-- <span style="width: 1px; color:#d9d9d9;margin: 0 10px;">|</span> -->
|
||||||
|
<div class="search-submit-box">
|
||||||
<img src="__IMAGES__/header/search.png" alt="{:lang_i18n('搜索')}" class="search-submit-icon" id="searchSubmit">
|
<img src="__IMAGES__/header/search.png" alt="{:lang_i18n('搜索')}" class="search-submit-icon" id="searchSubmit">
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<div class="search-history">
|
<div class="search-history">
|
||||||
<div class="search-history-header">
|
<div class="search-history-header">
|
||||||
<div class="search-history-title">{:lang_i18n('搜索记录')}</div>
|
<div class="search-history-title">{:lang_i18n('搜索记录')}</div>
|
||||||
@@ -844,16 +864,16 @@
|
|||||||
if (keyword && keyword.trim()) {
|
if (keyword && keyword.trim()) {
|
||||||
const searchKeyword = keyword.trim();
|
const searchKeyword = keyword.trim();
|
||||||
console.log('搜索关键词:', searchKeyword);
|
console.log('搜索关键词:', searchKeyword);
|
||||||
|
if (searchKeyword) {
|
||||||
addSearchHistory(searchKeyword);
|
addSearchHistory(searchKeyword);
|
||||||
alert('搜索: ' + searchKeyword);
|
window.location.href = "{:url('product/search')}?keywords=" + encodeURIComponent(searchKeyword);
|
||||||
searchModal.classList.remove('show');
|
searchModal.classList.remove('show');
|
||||||
searchInput.value = '';
|
searchInput.value = '';
|
||||||
searchClearBtn.style.display = 'none';
|
searchClearBtn.style.display = 'none';
|
||||||
} else {
|
|
||||||
alert('请输入搜索关键词');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}12
|
||||||
searchSubmit.addEventListener('click', function (e)
|
searchSubmit.addEventListener('click', function (e)
|
||||||
{
|
{
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
@@ -862,6 +882,7 @@
|
|||||||
|
|
||||||
searchInput.addEventListener('keypress', function (e)
|
searchInput.addEventListener('keypress', function (e)
|
||||||
{
|
{
|
||||||
|
console.log(e,'========e=============')
|
||||||
if (e.key === 'Enter' || e.key === 'enter' || e.keyCode === 13) {
|
if (e.key === 'Enter' || e.key === 'enter' || e.keyCode === 13) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
doSearch(searchInput.value);
|
doSearch(searchInput.value);
|
||||||
|
|||||||
@@ -31,15 +31,13 @@
|
|||||||
<link rel="stylesheet" href="__CSS__/topic_power_prodline/footer.css">
|
<link rel="stylesheet" href="__CSS__/topic_power_prodline/footer.css">
|
||||||
|
|
||||||
{/block}
|
{/block}
|
||||||
{block name="header"}
|
|
||||||
<!-- 重置header头为空 -->
|
|
||||||
{/block}
|
|
||||||
{block name="main"}
|
{block name="main"}
|
||||||
<a class="header" href="/">
|
<!-- <a class="header" href="/">
|
||||||
<div class="header-img">
|
<div class="header-img">
|
||||||
<img src="__IMAGES__/logo.png" alt="">
|
<img src="__IMAGES__/logo.png" alt="">
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</a> -->
|
||||||
<!-- 轮播核心容器 -->
|
<!-- 轮播核心容器 -->
|
||||||
<div class="swiper-container auto-swiper-container" >
|
<div class="swiper-container auto-swiper-container" >
|
||||||
{notempty name="data.focus_image"}
|
{notempty name="data.focus_image"}
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
<div class="pageMain">
|
<div class="pageMain">
|
||||||
<!-- banner -->
|
<!-- banner -->
|
||||||
{notempty name="focus_images"}
|
{notempty name="focus_images"}
|
||||||
<div class="swiper-container bannerswiper">
|
<div class="swiper-container bannerswiper" style="background: #fff;">
|
||||||
<div class="swiper-wrapper">
|
<div class="swiper-wrapper">
|
||||||
{volist name="focus_images" id="focus"}
|
{volist name="focus_images" id="focus"}
|
||||||
<div class="swiper-slide">
|
<div class="swiper-slide">
|
||||||
|
|||||||
@@ -28,7 +28,10 @@
|
|||||||
position: relative;
|
position: relative;
|
||||||
padding: 0 12.5em;
|
padding: 0 12.5em;
|
||||||
overflow: visible;
|
overflow: visible;
|
||||||
|
height: 64px;
|
||||||
background: #fff;
|
background: #fff;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 顶部导航栏:内容区带左右边距,外框1920px */
|
/* 顶部导航栏:内容区带左右边距,外框1920px */
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
}
|
}
|
||||||
.oricoEGapp .oricoEGapp-index .oidx-banner {
|
.oricoEGapp .oricoEGapp-index .oidx-banner {
|
||||||
margin-top: 3.5rem;
|
margin-top: 46px;
|
||||||
z-index: 9;
|
z-index: 9;
|
||||||
}
|
}
|
||||||
.oricoEGapp .oricoEGapp-index .oidx-banner .swiper-container {
|
.oricoEGapp .oricoEGapp-index .oidx-banner .swiper-container {
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: auto;
|
height: auto;
|
||||||
position: relative;
|
position: relative;
|
||||||
margin-top: 3.75rem;
|
margin-top: 64px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.orico_Page_index .pageMain .bannerswiper .swiper-slide img {
|
.orico_Page_index .pageMain .bannerswiper .swiper-slide img {
|
||||||
|
|||||||
Reference in New Issue
Block a user