学会 制作极简搜索浏览器 —— 并将 ChatGPT 接入浏览器
前期回顾
Vue3 + Ts + Vite + pnpm 项目中集成 —— eslint 、prettier、stylelint、husky、commitizen_0.活在风浪里的博客-CSDN博客搭建VIte + Ts + Vue3项目并集成eslint 、prettier、stylelint、huskyhttps://blog.csdn.net/m0_57904695/article/details/129950163?spm=1001.2014.3001.5502
本次目标:✌
1:🚚 制作一个自己的极简浏览器,并尝试运行!
2:💎在浏览器合并几个或多个ChartGPT,加快搜索,直达答案!
3:💎🚧 做一个墓室跑酷游戏,并尝试玩一把!
🚕 佛伯乐:详细吗?能看懂吗?
🙉 小帅:必然详细,一遍过,一遍懂,极简!我说的是真的!🚀
👙👄 小美:那我想要参考下源码可以吗?你能把游戏源码放上面吗?我能不能线上预览一下?
🙉 小帅:Of course, my little baa north nose,源码在下面 ,可以线上运行,不过进入页面我设置了密码,你可以找我要,免费分享!!!
👄 小美:哦买噶!那太方便了,我现在能看吗?只是在PC可以运行吗?
🙉 小帅:有手机版!游戏兼容移动、PC!网络环境不受限、 目前不支持水果机子😹
念及此!直接开始~
线上预览:主页
仓库地址源码在主页资源!
手机安装包在主页资源,目前不支持水果机子,哎,难办,难办我看就别办了!🔌哈哈
https://download.csdn.net/download/m0_57904695/87697108
目录
index
图例:
index.css
index
<html><head></head><body><meta content="text/html; charset=utf-8" http-equiv="Content-Type" /><metaname="color-scheme"content="light dark"/><metaname="viewport"content="width=device-width, initial-scale=1, user-scalable=no, minimal-ui"/><title>主页</title><link rel="stylesheet" href="homepage.css" /><style></style><div class="frosted-glass" id="gesture-indicator"></div><div id="content"><div class="search_part"><a class="logo" href="" onclick="window.via.cmd(257);" title="书签"><img class="smaller" src="./logo.svg"/></a><form onsubmit="return search()" class="search_bar" title="搜索"><button onclick="search()" id="search_submit" value="" aria-label="搜索"><div class="search icon"></div></button><span><inputautofocus="autofocus"class="search"onfocus="showButton()"onblur="hideButton()"type="text"value=""autocomplete="off"id="search_input"title="搜索"placeholder="活在风浪里________请键入..."/></span></form></div><div id="bookmark_part"><div id="box_container"><div class="box"><p class="title" aria-hidden="true" style="background: #ff0000"></p><divclass="overlay"style="background: url('https://img.51miz.com/preview/element/00/01/04/46/E-1044648-0962B463.jpg')no-repeat;background-size: cover;background-position: center center;"></div><p class="url" aria-hidden="true">AI聊天</p><a href="./Ai/login.html" title="ChartGPT镜像集合"></a></div><div class="box"><p class="title" aria-hidden="true" style="background: hsla(0, 0%, 0%, 0)"></p><divclass="overlay"style="background: url('https://ts1.cn.mm.bing.net/th/id/R-C.1a5a53f1ea9569eb2426b65026110ac1?rik=260ASfM%2b4Stsrg&riu=http%3a%2f%2ficon.chrafz.com%2fuploads%2f151023%2f1-151023205A4619.png&ehk=kJwPRrb8Dsb5aTPUFYNzr4NfDM5%2byqIm7HiEvNaHY68%3d&risl=&pid=ImgRaw&r=0')no-repeat;background-size: cover;background-position: center center;"></div><p class="url" aria-hidden="true">游戏<a href="youxi/index.html" title="墓地逃亡"></a></p></div><div class="box"><p class="title" aria-hidden="true" style="background: hsla(0, 0%, 0%, 0)"></p><divclass="overlay"style="background: url('./img/author.jpg') no-repeat center center/ cover"></div><p class="url" aria-hidden="true">CSDN</p><ahref="https://blog.csdn.net/m0_57904695?spm=1000.2115.3001.5343"title="最新最全一手资讯--我的CSDN"></a></div><div class="box"><p class="title" aria-hidden="true" style="background: #1a729b"></p><divclass="overlay"style="background: url('https://tse4-mm.cn.bing.net/th/id/OIP-C.DwpRopQ0mXFmzwabbrso5gHaHf?pid=ImgDet&rs=1')no-repeat;background-size: cover;background-position: center center;"></div><p class="url" aria-hidden="true">免费音乐</p><a href="https://tools.liumingye.cn/music/#/" title="Burger工具站"></a></div></div></div><script type="text/javascript">function showButton() {document.getElementById("search_submit").style.display = "block";}function hideButton() {"" == document.getElementById("search_input").value &&(document.getElementById("search_submit").style.display = "none");}function search() {var a = document.getElementById("search_input");if ("" != a.value) {try {searchText(a.value);} catch (b) {alert(b);}a.value = "";document.getElementById("search_submit").style.display = "none";document.activeElement.blur();}return !1;}function fadeIn(a) {if (a && a.style)var b = Math.max(0.05, parseFloat(a.style.opacity)),d = setInterval(function () {1 <= b && clearInterval(d);a.style.opacity = Math.min(1, b);b += 0.1 * b;}, 6);}function isGestureDisabled() {return (document.activeElement && "search_input" == document.activeElement.id) ||(window.via && !window.via.cmd(515))? !0: 0 != (document.documentElement.scrollTop || document.body.scrollTop);}function initGesture(d) {var b = document.getElementById("content"),e = 0,f = 1,g = !1,a = 0;d.addEventListener("touchstart",function (c) {g = isGestureDisabled();e = c.touches[0].pageY;a = 0;},!1);d.addEventListener("touchmove",function (c) {g ||(0 < a /*&&(document.body.style.position="fixed")*/,(a = c.touches[0].pageY - e),0 < a &&98 > a &&((f = Math.max(0.1, 1 - Math.min(1, a / 98))),(b.style.opacity = f),(b.style.transform = "translateY(" + a + "px)")));},!1);d.addEventListener("touchend",function (c) {/*document.body.style.position="static";*/if (0 != a) {if (88.2 < a) alert("不使用Via浏览此网页,你再下拉也打不开地址栏!");try {window.via.cmd(514);} catch (h) {}b.style.transform = "translateY(0px)";fadeIn(b);}},!1);}initGesture(document.getElementById("gesture-indicator"));initGesture(document.getElementById("content"));</script><script charset="gbk" src="opensug.js"></script><script type="text/javascript">function show(str) {var searchbox = document.getElementById("search_input");searchbox.innerHTML = str;searchbox.blur();search();}var params = {XOffset: 0,YOffset: 0,fontColor: "#666666",fontColorHI: "#FFF",fontSize: "14px",borderColor: "#eee",bgcolorHI: "#7B90E3",sugSubmit: false,};BaiduSuggestion.bind("search_input", params, show);</script><script>function searchText(text) {// 必应location.href = "https://cn.bing.com/search?q=" + text;// 百度// location.href = "https://www.baidu.com/s?ie=UTF-8&wd==" + text;}</script></div></body>
</html>
目前调用的是必应:

图例:



index.css
* {padding: 0;margin: 0;box-sizing: border-box;
}
html {height: 100%;-webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);-webkit-focus-ring-color: rgba(0, 0, 0, 0);
}
body {min-height: 100%;max-width: 100%;width: 600px;background: translate;margin: auto;text-align: center;
}
#gesture-indicator {height: 100%;width: 100%;position: absolute;top: 0;bottom: 0;z-index: 0;overflow: hidden;word-break: break-all;
}
#content {position: absolute;max-width: 600px;width: 100%;
}
#content {top: 25%;transition: 0.14s;
}
@media only screen and (min-height: 250px) {#content {top: 62px;}
}
@media only screen and (min-height: 350px) {#content {top: 87px;}
}
@media only screen and (min-height: 450px) {#content {top: 135px;}
}
@media only screen and (min-height: 650px) {#content {top: 195px;}
}
@media only screen and (min-height: 850px) {#content {top: 255px;}
}
.logo {font-size: 28px;font-weight: bold;white-space: normal;word-wrap: break-word;overflow: auto;text-decoration: none;color: #1b1b1b;
}
img.smaller {height: 72px;border-radius: 18px;object-fit: cover;
}
span {display: block;overflow: hidden;padding-left: 5px;vertical-align: middle;
}
.search_part {margin-bottom: 20px;
}
.search.icon {color: #1b1b1b;width: 12px;height: 12px;border: solid 2px currentColor;border-radius: 100%;-webkit-transform: rotate(-45deg);transform: rotate(-45deg);text-align: center;margin: auto;
}
.search.icon:before {content: "";position: absolute;top: 10px;left: 3px;height: 5px;width: 2px;background-color: currentColor;
}
.search_bar {display: table;vertical-align: middle;width: 90%;max-width: 600px;margin: 15px auto 0;
}
#search_input {height: 46px;padding: 0 12px;width: 100%;outline: none;border: none;font-size: 15px;background-color: transparent;
}
#search_submit {display: none;outline: none;height: 46px;width: 56px;float: right;font-size: 15px;font-weight: bold;border: none;background-color: transparent;padding: 0 10px;
}
.search_bar {border: 1px solid rgba(0, 0, 0, 0.24);border-radius: 24px;background: rgba(255, 255, 255, 0);
}
#search_input,
#search_submit {color: #1b1b1b;
}
.bdSug_wpr {overflow-y: scroll !important;max-height: 30% !important;background: rgba(255, 255, 255, 1) !important;border: 1px solid !important;border-color: rgba(0, 0, 0, 0.15) !important;border-radius: 0 0 24px 24px;
}
.bdSug_wpr table {background: none !important;
}
.bdSug_wpr td {margin: 4px !important;padding: 10px !important;color: #1b1b1b;background: none;
}
.bdSug_sd {height: 0px !important;
}
.bdSug_app {display: none !important;
}
#bookmark_part {text-align: center;max-width: 600px;background-color: transparent;margin: 0 auto;padding: 0;border-radius: 0px;
}
#box_container {text-align: left;margin: 0 auto;font-size: 0;
}
.box {margin: 4px 9px 4px;width: 46px;border: 0;position: relative;display: inline-block;text-align: center;
}
.box a {width: 100%;height: 100%;position: absolute;left: 0;top: 0;
}
.overlay {position: absolute;left: 0;top: 0;border-radius: 23px;width: 46px;height: 46px;
}
.title {border-radius: 23px;color: #ffffff;width: 46px;line-height: 46px;height: 46px;font-size: 15px;
}
.url {margin: 2px 0 0;width: 46px;height: 20px;line-height: 20px;white-space: normal;word-wrap: break-word;overflow: hidden;text-overflow: clip;-o-text-overflow: clip;ms-text-overflow: clip;color: #1b1b1b;font-size: 10px;
}
@media only screen and (min-width: 128px) {#box_container {width: 64px;}
}
@media only screen and (min-width: 192px) {#box_container {width: 128px;}
}
@media only screen and (min-width: 256px) {#box_container {width: 192px;}
}
@media only screen and (min-width: 320px) {#box_container {width: 256px;}
}
@media only screen and (min-width: 384px) {#box_container {width: 320px;}
}
@media only screen and (min-width: 448px) {#box_container {width: 384px;}
}
@media only screen and (min-width: 512px) {#box_container {width: 448px;}
}
@media only screen and (min-width: 576px) {#box_container {width: 512px;}
}
.sort-ghost {opacity: 0.3;
}
更新中...
相关文章:
学会 制作极简搜索浏览器 —— 并将 ChatGPT 接入浏览器
前期回顾 Vue3 Ts Vite pnpm 项目中集成 —— eslint 、prettier、stylelint、husky、commitizen_0.活在风浪里的博客-CSDN博客搭建VIte Ts Vue3项目并集成eslint 、prettier、stylelint、huskyhttps://blog.csdn.net/m0_57904695/article/details/129950163?spm1001.2…...
NumPy 秘籍中文第二版:六、特殊数组和通用函数
原文:NumPy Cookbook - Second Edition 协议:CC BY-NC-SA 4.0 译者:飞龙 在本章中,我们将介绍以下秘籍: 创建通用函数查找勾股三元组用chararray执行字符串操作创建一个遮罩数组忽略负值和极值使用recarray函数创建一…...
各种交叉编译工具链的区别
目录 1 命名规则 2 实例 2.1 arm-none-eabi-gcc 2.2 arm-none-linux-gnueabi-gcc 2.3 arm-eabi-gcc 2.4 armcc 2.5 arm-none-uclinuxeabi-gcc 和 arm-none-symbianelf-gcc 3 gnueabi和gnueabihf的区别(硬浮点、软浮点) 4 Linaro公司出品的交叉编译工具链 5 ARM公司出…...
密度聚类算法(DBSCAN)实验案例
密度聚类算法(DBSCAN)实验案例 描述 DBSCAN是一种强大的基于密度的聚类算法,从直观效果上看,DBSCAN算法可以找到样本点的全部密集区域,并把这些密集区域当做一个一个的聚类簇。DBSCAN的一个巨大优势是可以对任意形状…...
第07章_面向对象编程(进阶)
第07章_面向对象编程(进阶) 讲师:尚硅谷-宋红康(江湖人称:康师傅) 官网:http://www.atguigu.com 本章专题与脉络 1. 关键字:this 1.1 this是什么? 在Java中,this关键字不算难理解…...
异常的讲解(2)
目录 throws异常处理 基本介绍 throws异常处理注意事项和使用细节 自定义异常 基本概念 自定义异常的步骤 throw 和throws的区别 本章作业 第一题 第二题 第三题 第四题 throws异常处理 基本介绍 1)如果一个方法(中的语句执行时)可能生成某种异常,但是…...
jvm内存结构
1. 栈 程序计数器 2. 虚拟机栈 3. 本地方法栈 4. 堆 5. 方法区 1.2栈内存溢出 栈帧过多导致栈内存溢出 /*** 演示栈内存溢出 java.lang.StackOverflowError* -Xss256k*/ public class Demo1_2 {private static int count;public static void main(String[] args) {try {meth…...
要刹车?生成式AI迎新规、行业连发ChatGPT“警报”、多国考虑严监管
4月13日消息,据中国移动通信联合会元宇宙产业工作委员会网站,中国移动通信联合会元宇宙产业工作委员会、中国通信工业协会区块链专业委员会等,共同发布“关于元宇宙生成式人工智能(类 ChatGPT)应用的行业提示”。提示内…...
轻松掌握Qt FTP 机制:实现高效文件传输
轻松掌握Qt FTP:实现高效文件传输一、简介(Introduction)1.1 文件传输协议(FTP)Qt及其网络模块(Qt and its Network Module)QNetwork:二、QNetworkAccessManager上传实例(Qt FTP Upl…...
用AI帮我写一篇关于FPGA的文章,并推荐最热门的FPGA开源项目
FPGA定义 FPGA(Field Programmable Gate Array)是一种可编程逻辑器件,可以在硬件电路中实现各种不同的逻辑功能。与ASIC(Application Specific Integrated Circuit,特定应用集成电路)相比,FPGA…...
从兴趣或问题出发
当我们还沉寂在移动互联网给生活带来众多便利中,以 ChartGPT 为代表的 AI 时代已彻底到来。科技的发展,时刻在改变着我们的生活,我们需要不断地学习新知识和掌握新技能才能享受变化带来的便利,以及自身不被社会淘汰。 因此&#…...
C++ | 探究拷贝对象时的一些编译器优化
👑作者主页:烽起黎明 🏠学习社区:烈火神盾 🔗专栏链接:C 文章目录前言一、传值传参二、传引用传参三、传值返回拷贝构造和赋值重载的辨析四、传引用返回【❌】五、传匿名对象返回六、总计与提炼前言 在传参…...
linux工具gcc/g++/gdb/git的使用
目录 gcc/g 基本概念 指令集 函数库 (重要) gdb使用 基本概念 指令集 项目自动化构建工具make/makefile 进度条小程序 编辑 git三板斧 创建仓库 git add git commit git push git status git log gcc/g 基本概念 gcc/g称为编译器…...
Direct3D 12——纹理——纹理
纹理不同于缓冲区资源,因为缓冲区资源仅存储数据数组,而纹理却可以具有多个mipmap层级(后 文有介绍),GPU会基于这个层级进行相应的特殊操作,例如运用过滤器以及多重采样。支持这些特殊 的操作纹理资源都被限定为一些特定的数据格式…...
产品经理必读 | 俞军产品经理十二条军规
最近在学习《俞军产品方法论》,觉得俞军总结的十二条产品经理原则非常受用,分享给大家。 01. 产品经理首先是产品的深度用户 自己设计的产品都没使用过的产品经理,如何明白用户使用的问题,如何解决问题,所以产品经理肯…...
【机器视觉1】光源介绍与选择
文章目录一、常见照明光源类型二、照明光源对比三、照明技术3.1 亮视野与暗视野3.2 低角度照明3.3 前向光直射照明3.4 前向光漫射照明3.5 背光照明-测量系统的最佳选择3.6 颜色与补色示例3.7 偏光技术应用四、镜头4.1 镜头的几个概念4.2 影响图像质量的关键因素4.3 成像尺寸4.4…...
【三十天精通Vue 3】第十一天 Vue 3 过渡和动画详解
✅创作者:陈书予 🎉个人主页:陈书予的个人主页 🍁陈书予的个人社区,欢迎你的加入: 陈书予的社区 🌟专栏地址: 三十天精通 Vue 3 文章目录引言一、Vue 3 过度和动画概述1.1过度和动画的简介二、Vue 3 过度2…...
基于多种流量检测引擎识别pcap数据包中的威胁
在很多的场景下,会需要根据数据包判断数据包中存在的威胁。针对已有的数据包,如何判断数据包是何种攻击呢? 方法一可以根据经验,对于常见的WEB类型的攻击,比如SQL注入,命令执行等攻击,是比较容…...
第02章_变量与运算符
第02章_变量与运算符 讲师:尚硅谷-宋红康(江湖人称:康师傅) 官网:http://www.atguigu.com 本章专题与脉络 1. 关键字(keyword) 定义:被Java语言赋予了特殊含义,用做专门…...
仅三行就能学会数据分析——Sweetviz详解
文章目录前言一、准备二、sweetviz 基本用法1.引入库2.读入数据3.调整报告布局总结前言 Sweetviz是一个开源Python库,它只需三行代码就可以生成漂亮的高精度可视化效果来启动EDA(探索性数据分析)。输出一个HTML。 如上图所示,它不仅能根据性别、年龄等…...
23-Oracle 23 ai 区块链表(Blockchain Table)
小伙伴有没有在金融强合规的领域中遇见,必须要保持数据不可变,管理员都无法修改和留痕的要求。比如医疗的电子病历中,影像检查检验结果不可篡改行的,药品追溯过程中数据只可插入无法删除的特性需求;登录日志、修改日志…...
C++.OpenGL (10/64)基础光照(Basic Lighting)
基础光照(Basic Lighting) 冯氏光照模型(Phong Lighting Model) #mermaid-svg-GLdskXwWINxNGHso {font-family:"trebuchet ms",verdana,arial,sans-serif;font-size:16px;fill:#333;}#mermaid-svg-GLdskXwWINxNGHso .error-icon{fill:#552222;}#mermaid-svg-GLd…...
【HTML-16】深入理解HTML中的块元素与行内元素
HTML元素根据其显示特性可以分为两大类:块元素(Block-level Elements)和行内元素(Inline Elements)。理解这两者的区别对于构建良好的网页布局至关重要。本文将全面解析这两种元素的特性、区别以及实际应用场景。 1. 块元素(Block-level Elements) 1.1 基本特性 …...
【HTTP三个基础问题】
面试官您好!HTTP是超文本传输协议,是互联网上客户端和服务器之间传输超文本数据(比如文字、图片、音频、视频等)的核心协议,当前互联网应用最广泛的版本是HTTP1.1,它基于经典的C/S模型,也就是客…...
Linux离线(zip方式)安装docker
目录 基础信息操作系统信息docker信息 安装实例安装步骤示例 遇到的问题问题1:修改默认工作路径启动失败问题2 找不到对应组 基础信息 操作系统信息 OS版本:CentOS 7 64位 内核版本:3.10.0 相关命令: uname -rcat /etc/os-rele…...
安宝特案例丨Vuzix AR智能眼镜集成专业软件,助力卢森堡医院药房转型,赢得辉瑞创新奖
在Vuzix M400 AR智能眼镜的助力下,卢森堡罗伯特舒曼医院(the Robert Schuman Hospitals, HRS)凭借在无菌制剂生产流程中引入增强现实技术(AR)创新项目,荣获了2024年6月7日由卢森堡医院药剂师协会࿰…...
Go 语言并发编程基础:无缓冲与有缓冲通道
在上一章节中,我们了解了 Channel 的基本用法。本章将重点分析 Go 中通道的两种类型 —— 无缓冲通道与有缓冲通道,它们在并发编程中各具特点和应用场景。 一、通道的基本分类 类型定义形式特点无缓冲通道make(chan T)发送和接收都必须准备好࿰…...
【UE5 C++】通过文件对话框获取选择文件的路径
目录 效果 步骤 源码 效果 步骤 1. 在“xxx.Build.cs”中添加需要使用的模块 ,这里主要使用“DesktopPlatform”模块 2. 添加后闭UE编辑器,右键点击 .uproject 文件,选择 "Generate Visual Studio project files",重…...
Linux 下 DMA 内存映射浅析
序 系统 I/O 设备驱动程序通常调用其特定子系统的接口为 DMA 分配内存,但最终会调到 DMA 子系统的dma_alloc_coherent()/dma_alloc_attrs() 等接口。 关于 dma_alloc_coherent 接口详细的代码讲解、调用流程,可以参考这篇文章,我觉得写的非常…...
《信号与系统》第 6 章 信号与系统的时域和频域特性
目录 6.0 引言 6.1 傅里叶变换的模和相位表示 6.2 线性时不变系统频率响应的模和相位表示 6.2.1 线性与非线性相位 6.2.2 群时延 6.2.3 对数模和相位图 6.3 理想频率选择性滤波器的时域特性 6.4 非理想滤波器的时域和频域特性讨论 6.5 一阶与二阶连续时间系统 6.5.1 …...
