加入“工具”页面(未完成)
This commit is contained in:
@@ -220,6 +220,37 @@ footer img {
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
/* 工具面板 */
|
||||
|
||||
.tool-panel {
|
||||
position: fixed;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
}
|
||||
|
||||
.tool-panel-bar {
|
||||
height: 5vh;
|
||||
background-color: #F5F5F5;
|
||||
}
|
||||
|
||||
.tool-panel-close {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 8px;
|
||||
height: 5vh;
|
||||
width: 5vh;
|
||||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
|
||||
background-color: #4CAF50;
|
||||
}
|
||||
|
||||
.tool-panel-iframe {
|
||||
}
|
||||
|
||||
.tool-panel-iframe iframe {
|
||||
height: 95vh;
|
||||
width: 100vw;
|
||||
}
|
||||
|
||||
/* 链接的图标 */
|
||||
|
||||
/*
|
||||
|
129
docs/css/tool.css
Normal file
129
docs/css/tool.css
Normal file
@@ -0,0 +1,129 @@
|
||||
@charset "UTF-8";
|
||||
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #F5F5F5;
|
||||
}
|
||||
|
||||
/* 滚动条 */
|
||||
|
||||
::-webkit-scrollbar {
|
||||
height: 8px;
|
||||
width: 8px;
|
||||
}
|
||||
::-webkit-scrollbar-thumb {
|
||||
background: #999;
|
||||
border-radius: 0;
|
||||
}
|
||||
::-webkit-scrollbar-track {
|
||||
background: #eee;
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
/* 选中 */
|
||||
|
||||
::selection {
|
||||
background:#03A9F4;
|
||||
color:#FFF;
|
||||
}
|
||||
::-moz-selection {
|
||||
background:#03A9F4;
|
||||
color:#FFF;
|
||||
}
|
||||
::-webkit-selection {
|
||||
background:#03A9F4;
|
||||
color:#FFF;
|
||||
}
|
||||
|
||||
/* 主要 */
|
||||
|
||||
.main {
|
||||
margin: 0 auto;
|
||||
width: 90%;
|
||||
max-width: 400px;
|
||||
}
|
||||
|
||||
.main > div {
|
||||
margin: 20px 0;
|
||||
padding: 15px;
|
||||
box-sizing: border-box;
|
||||
width: 100%;
|
||||
background-color: #FFF;
|
||||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.main > div header {
|
||||
margin-bottom: 10px;
|
||||
text-align: center;
|
||||
font-size: 20px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.main > div textarea {
|
||||
padding: 5px;
|
||||
box-sizing: border-box;
|
||||
border: 1px solid #03A9F4;
|
||||
font-size: 16px;
|
||||
box-shadow: 0 0 5px rgba(3, 169, 244, 0.2);
|
||||
}
|
||||
|
||||
.tool-button {
|
||||
display: inline-block;
|
||||
user-select: none;
|
||||
padding: 5px 10px;
|
||||
background-color: #03A9F4;
|
||||
text-align: center;
|
||||
font-size: 14px;
|
||||
color: #FFF;
|
||||
border-radius: 5px;
|
||||
box-shadow: 2px 2px 5px rgba(3, 169, 244, 0.4);
|
||||
}
|
||||
|
||||
.tool-button:hover {
|
||||
background-color: #2196F3;
|
||||
}
|
||||
|
||||
/* 计算 */
|
||||
|
||||
.tool-calculate textarea {
|
||||
width: 100%;
|
||||
resize: none;
|
||||
}
|
||||
|
||||
.tool-calculate-tofixed {
|
||||
width: 20px;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.tool-calculate .tool-button {
|
||||
margin: 5px 5px 2px 0;
|
||||
}
|
||||
|
||||
/* 生成批量下载链接 */
|
||||
|
||||
.tool-genlink-link input {
|
||||
margin-bottom: 10px;
|
||||
height: 20px;
|
||||
width: 80%;
|
||||
}
|
||||
|
||||
.tool-genlink-settings {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.tool-genlink .tool-button {
|
||||
position: relative;
|
||||
left: 50%;
|
||||
margin-bottom: 10px;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
|
||||
.tool-genlink textarea {
|
||||
width: 100%;
|
||||
resize: none;
|
||||
font-size: 14px;
|
||||
}
|
@@ -518,6 +518,17 @@
|
||||
<li><a href="https://apsgo.com/">APSGO 软购</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#">饮食</a>
|
||||
<ul>
|
||||
<li><a href="http://www.pizzahut.com.cn/">必胜客</a></li>
|
||||
<li><a href="https://www.4008123123.com/">必胜客宅急送</a></li>
|
||||
<li><a href="https://www.ele.me/">饿了么</a></li>
|
||||
<li><a href="http://www.kfc.com.cn/">肯德基</a></li>
|
||||
<li><a href="https://www.4008823823.com.cn/">肯德基宅急送</a></li>
|
||||
<li><a href="https://h5.waimai.meituan.com/">美团外卖</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</section>
|
||||
@@ -886,6 +897,7 @@
|
||||
<li>
|
||||
<a href="#">开发</a>
|
||||
<ul>
|
||||
<li><a href="https://mcforge-cn.readthedocs.io/zh/latest/">Forge 文档</a></li>
|
||||
<li><a href="https://mcforge-cn.readthedocs.io/zh/latest/gettingstarted/structuring/">Forge 文档 - Mod 的结构</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
@@ -1217,6 +1229,16 @@
|
||||
</div>
|
||||
<div class="search-result"></div>
|
||||
</div>
|
||||
<!--
|
||||
<div class="tool-panel">
|
||||
<div class="tool-panel-bar">
|
||||
<div class="tool-panel-close"></div>
|
||||
</div>
|
||||
<div class="tool-panel-iframe">
|
||||
<iframe src="tool.html" frameborder="0"></iframe>
|
||||
</div>
|
||||
</div>
|
||||
-->
|
||||
<div class="fullscreen-text">加载中...</div>
|
||||
<div class="floating-bar">
|
||||
<div class="floating-bar-search" onclick="SearchPanel.style.visibility = 'visible'; SearchInput.focus();">搜索</div>
|
||||
|
16
docs/js/tool.js
Normal file
16
docs/js/tool.js
Normal file
@@ -0,0 +1,16 @@
|
||||
function toolCalculateSubmit() {
|
||||
getInput = document.getElementById("tool-calculate-input");
|
||||
getToFixed = document.getElementsByClassName("tool-calculate-tofixed")[0];
|
||||
getResult = document.getElementsByClassName("tool-calculate-result")[0].getElementsByTagName("span")[0];
|
||||
if (getToFixed.value >= 0 && getToFixed.value <= 16) {
|
||||
getResult.innerText = eval(getInput.value).toFixed(getToFixed.value);
|
||||
} else {
|
||||
getResult.innerText = "错误";
|
||||
}
|
||||
}
|
||||
|
||||
function toolCalculateClear() {
|
||||
getInput = document.getElementById("tool-calculate-input");
|
||||
getInput.value = '';
|
||||
getResult.innerText = '';
|
||||
}
|
41
docs/tool.html
Normal file
41
docs/tool.html
Normal file
@@ -0,0 +1,41 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-cmn-Hans">
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
|
||||
<title>Frost 网址导航 - 工具</title>
|
||||
<link rel="stylesheet" href="css/tool.css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div class="main">
|
||||
<div class="tool-calculate">
|
||||
<header>简易计算</header>
|
||||
<textarea id="tool-calculate-input" rows="5" placeholder="请输入算式"></textarea>
|
||||
<div>保留小数点后 <input class="tool-calculate-tofixed" type="text" title="0 ~ 16 之间(默认:4)" value="4" /> 位数</div>
|
||||
<div class="tool-calculate-result">结果:<span></span></div>
|
||||
<div class="tool-button" onclick="toolCalculateSubmit()">计算</div>
|
||||
<div class="tool-button" onclick="toolCalculateClear()">清空</div>
|
||||
</div>
|
||||
<div class="tool-genlink">
|
||||
<header>生成批量下载链接</header>
|
||||
<div class="tool-genlink-link">
|
||||
网址:<input type="text" placeholder="变量用 (*) 表示" />
|
||||
</div>
|
||||
<div class="tool-genlink-settings">
|
||||
<input type="radio" name="genlink-settings" value="a" />
|
||||
等差数列 首项:项数:公差:
|
||||
<br />
|
||||
<input type="radio" name="genlink-settings" value="b" />
|
||||
等比数列 首项:项数:公比:
|
||||
<br />
|
||||
<input type="radio" name="genlink-settings" value="c" />
|
||||
字母变化 从:到:
|
||||
</div>
|
||||
<div class="tool-button" onclick="">生成</div>
|
||||
<textarea id="tool-genlink-result" rows="8" placeholder="结果"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
<script src="js/tool.js"></script>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user