This commit is contained in:
底层用户 2022-03-24 23:01:10 +08:00
parent 944d1d4efe
commit e9bb396795
4 changed files with 17 additions and 51 deletions

View File

@ -250,14 +250,11 @@ img.error {
.sou form .s {
width: 40px;
height: 40px;
display: flex;
padding: 10px;
cursor: pointer;
}
.sou form .se {
display: flex;
align-items: center;
justify-content: center;
align-items: center;
}
#icon-se,
@ -278,7 +275,6 @@ img.error {
}
.sou-button {
padding: 10px;
transition: 0.3s;
border-radius: 30px 0px 0px 30px;
}

View File

@ -53,7 +53,6 @@
</div>
<!-- 主体内容 -->
<section id="section" class="section">
<!-- 搜索框 -->
<div id="content">
<div class="con">
<!-- 时间天气 -->
@ -74,14 +73,14 @@
<div class="se" title="点击切换搜索引擎">
<i id="icon-se" class="iconfont icon-baidu"></i>
</div>
<input class="wd" type="text" name="wd" placeholder="想要搜点什么" onfocus="this.placeholder=''"
onblur="this.placeholder='想要搜点什么'" autocomplete="off">
<input class="wd" type="text" name="wd" placeholder="想要搜点什么" autocomplete="off">
<div class="sou-button">
<button class="s" id="s-button">
<div class="s" id="s-button">
<i id="icon-sou" class="iconfont icon-sousuo"></i>
</button>
</div>
</div>
</div>
<input type="submit" id="search-submit" style="display: none;">
</form>
<div id="keywords" style="display: none;"></div>
<div class="search-engine" style="display: none;">
@ -503,7 +502,6 @@
</div>
</div>
</div>
<!-- 主体内容结束 -->
<!-- 版权信息 -->
<div class="foot">
<div class="power">Copyright&nbsp;&copy;&nbsp;2020
@ -515,6 +513,7 @@
</div>
</div>
</section>
<!-- 主体内容结束 -->
<!-- noscript -->
<noscript>
<div class="noscript fixed-top">请开启 JavaScript</div>

View File

@ -121,6 +121,14 @@ $(function () {
})
})
//点击搜索按钮
$(".sou-button").click(function () {
iziToast.show({
message: '问题未修复,请点击键盘上的确认键以搜索',
});
// $('#search-submit').click();
});
//控制台输出
var styleTitle1 = `
font-size: 20px;

View File

@ -100,52 +100,26 @@ var quick_list_preinstall = {
'1': {
title: "哔哩哔哩",
url: "https://www.bilibili.com/",
explain: "哔哩哔哩 (゜-゜)つロ 干杯~",
},
'2': {
title: "GitHub",
url: "https://github.com/",
explain: "GitHub",
},
'3': {
title: "V2EX",
url: "https://www.v2ex.com/",
explain: "V2EX",
},
'4': {
title: "Steam",
url: "https://store.steampowered.com/",
explain: "Steam",
},
'5': {
title: "Github",
url: "https://github.com/",
explain: "GitHub",
},
'6': {
title: "Github",
url: "https://github.com/",
explain: "GitHub",
},
'7': {
title: "Github",
url: "https://github.com/",
explain: "GitHub",
},
'8': {
title: "Github",
url: "https://github.com/",
explain: "GitHub",
},
'9': {
title: "Github",
url: "https://github.com/",
explain: "GitHub",
},
'10': {
title: "Github",
url: "https://github.com/",
explain: "GitHub",
}
};
@ -366,7 +340,6 @@ function seList() {
var html = "";
var se_list = getSeList();
for (var i in se_list) {
//html += "<div class='se-li' data-url='" + se_list[i]["url"] + "' data-name='" + se_list[i]["name"] + "' data-img='" + se_list[i]["img"] + "'><img src='" + se_list[i]["img"] + "'>" + se_list[i]["title"] + "</div>";
html += "<div class='se-li' data-url='" + se_list[i]["url"] + "' data-name='" + se_list[i]["name"] + "' data-icon='" + se_list[i]["icon"] + "'><a class='se-li-text'><i id='icon-sou-list' class=' " + se_list[i]["icon"] + " '></i><span>" + se_list[i]["title"] + "</span></a></div>";
}
$(".search-engine-list").html(html);
@ -424,7 +397,7 @@ function quickData() {
var html = "";
var quick_list = getQuickList();
for (var i in quick_list) {
html += "<div class='quick' title='" + quick_list[i]['explain'] + "'>\
html += "<div class='quick'>\
<a href='" + quick_list[i]['url'] + "' target='_blank'>\
" + quick_list[i]['title'] + "\
</a>\
@ -635,21 +608,11 @@ $(document).ready(function () {
$(".search-engine").slideUp(160);
});
$("#s-button").focus(function () {
focusWd();
keywordReminder();
$(".search-engine").slideUp(160);
});
// 搜索框失去焦点事件
$(".wd").blur(function () {
blurWd();
});
$("#s-button").blur(function () {
blurWd();
});
// 自动提示( 调用百度 api
$('.wd').keyup(function (event) {
var key = event.keyCode;