网页隐藏版之一行小说阅读器
显示效果:
懒人操作:
页面鼠标右键,新建文本文档,复制黏贴以下代码,点击左上角【文件】,点击【另存为】,如下设置,后缀为.html,这样一个本地网页就完成啦~
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>
https://baidu.com
</title>
<style>
body {
margin: 0;
padding: 0;
}
p {
font-size: 15px;
margin: 0;
padding: 0;
}
/* 设置文件输入框的样式 */
#fileInput {
font-size: 10px;
margin: 0;
padding: 0;
position: absolute;
bottom: 1px;
left: 1px;
}
/* txt内容显示框 */
#fileContent {
POSITION: absolute;
white-space: pre-wrap;
BOTTOM: 0px;
LEFT: 400px;
font-size: 0.7em;
line-height: normal;
text-align: left;
}
/* url内容显示框 */
iframe {
width: 100%;
height: calc(98vh);
margin: 0;
padding: 0;
border: none;
}
/* 当前行数 */
#currentLine {
font-size: 12px;
position: absolute;
bottom: 0px;
left: 4px;
color: #9c9c9c;
}
/* 用于隐藏/显示txt内容和当前行数 功能区 */
.content {
position: absolute;
bottom: 40px;
right: 30px;
margin: 0;
padding: 0;
display: flex;
justify-content: flex-end;
margin-top: 10px;
}
/* 用于隐藏/显示txt内容和当前行数 的S/H 按钮 */
#BtnsBtn,
#RowsBtn,
#nextBtn,
#preBtn {
margin-right: 6px;
width: 20px;
height: 20px;
text-align: center;
display: flex;
align-items: center;
justify-content: center;
}
#BtnsBtn {
background-color: rgb(187 187 187);
border: none;
border-radius: 20%;
}
#BtnsBtn:active {
background-color: rgb(27, 152, 255);
}
#RowsBtn:active {
background-color: rgb(114, 114, 114);
}
/* 跳转、重置行数\重置、清空url功能区 */
.updataRowsDiv,
.updataUrlDiv,
.updataLeftDiv,
#resetKeyborderDiv {
position: absolute;
right: 30px;
margin: 0;
padding: 0;
display: flex;
justify-content: flex-end;
margin-top: 10px;
}
.updataRowsDiv {
bottom: 111px;
}
.updataUrlDiv {
bottom: 75px;
}
.updataLeftDiv {
bottom: 180px
}
#resetKeyborderDiv {
bottom: 150px;
}
#resetKeyborderDiv label {
margin-right: 3px;
font-size: 12px;
line-height: 23px;
background: #e9e9e9;
}
#resetKeyborderDiv #resetKeyborder {
margin-right: 5px;
background-color: rgb(0, 69, 126);
color: white;
border-radius: 4px;
border: none;
width: 83px;
height: 27px;
font-size: 11px;
}
#resetKeyborderDiv #resetKeyborder:active {
background-color: rgb(2, 141, 255);
}
/* 行数输入框、url输入框 、调整行数输入框*/
#jumpLineInput,
#urlInput,
#leftInput {
width: 120px;
margin-right: 5px;
padding: 2px;
font-size: 11px;
border-radius: 4px;
border: 1px solid rgb(189, 188, 188);
}
#leftInput {
width: 117px;
height: 23px;
font-size: 12px;
color: #707070;
}
/* 跳转、重置行数、重置、清空url按钮 */