Compare commits

...

2 Commits

Author SHA1 Message Date
skimrme
8f6e09cf0f 再次完善页面缩放比例问题,放大了也不会发生奇怪的错位了 2025-07-27 20:49:18 +08:00
skimrme
3ee0131b0e 添加页面等比例缩放 2025-07-26 20:07:01 +08:00
4 changed files with 38 additions and 27 deletions

View File

@@ -2,11 +2,13 @@
<head> <head>
<title>首页 | ww3</title> <title>首页 | ww3</title>
<meta charset="utf-8" lang="zh-CN"> <meta charset="utf-8" lang="zh-CN">
<meta name="viewport" content="width=1366px, initial-scale=1.0"> <!-- 页面等比例缩小 -->
<link rel="icon" type="image/x-icon" href="./icon/original.ico"> <link rel="icon" type="image/x-icon" href="./icon/original.ico">
</head> </head>
<body> <body>
<div id="black_block">
<div id="navbar1"> <div id="navbar1">
<table border="0"> <table border="0" style="background-color: rgba(147, 185, 255, 0.644);">
<tbody> <tbody>
<tr> <tr>
<td id="td_navbar_40px"><b><a href="https://ww3.tw/" id="url_">首页</a></b></td> <td id="td_navbar_40px"><b><a href="https://ww3.tw/" id="url_">首页</a></b></td>
@@ -16,11 +18,12 @@
<td id="td_navbar_52px"><b><a href="https://gitea.ww3.tw/skimrme/" id="url_">gitea</a></b></td> <td id="td_navbar_52px"><b><a href="https://gitea.ww3.tw/skimrme/" id="url_">gitea</a></b></td>
<td id="td_navbar_135px"><b><a href="https://ww3.tw/docker-registry/" id="url_">docker-registry</a></b></td> <td id="td_navbar_135px"><b><a href="https://ww3.tw/docker-registry/" id="url_">docker-registry</a></b></td>
<td id="td_navbar_40px"><b><a href="https://ww3.tw/api/" id="url_">api</a></b></td> <td id="td_navbar_40px"><b><a href="https://ww3.tw/api/" id="url_">api</a></b></td>
<td id="td_navbar_40px"><b><a href="https://wiki.ww3.tw/" id="url_">wiki</a></b></td> <td id="td_navbar_40px"><b><a href="https://wiki.ww3.tw/" id="url_">wiki</a></b></td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
<br>
<!-- 屑站日志 --> <!-- 屑站日志 -->
<div id="logs"> <div id="logs">
<h3>屑站日志:<br></h3> <h3>屑站日志:<br></h3>
@@ -47,9 +50,14 @@
<div id="js_date"></div> <div id="js_date"></div>
<script> <script>
</script> </script>
</div>
</body> </body>
</html> </html>
<?php
include "../static/html/black-block.html";
?>
<style> <style>
body body
{ {
@@ -59,7 +67,7 @@
#url_ #url_
{ {
text-decoration: none; text-decoration: none;
color: black; color: rgb(0, 0, 0);
} }
#logs #logs
@@ -67,7 +75,7 @@
height: 220px; height: 220px;
width: 450px; width: 450px;
overflow: auto; overflow: auto;
background: #ffffff; background: #ffffffbc;
/* up、right、down、left */ /* up、right、down、left */
margin: 40px 0px 0px 0px; margin: 40px 0px 0px 0px;
} }

View File

@@ -1,6 +1,7 @@
<html> <html>
<head> <head>
<meta charset="utf-8" lang="zh-CN"> <meta charset="utf-8" lang="zh-CN">
<meta name="viewport" content="width=1366px, initial-scale=1.0"> <!-- 页面等比例缩小 -->
<link rel="stylesheet" type="text/css" href="./static/css/navbar/body_color.css"> <link rel="stylesheet" type="text/css" href="./static/css/navbar/body_color.css">
<link rel="icon" type="img/icon" href="./static/icon/original.ico"> <link rel="icon" type="img/icon" href="./static/icon/original.ico">
</head> </head>
@@ -62,7 +63,6 @@
color: rgb(255, 74, 74); color: rgb(255, 74, 74);
text-align: left; text-align: left;
font-size: 18px; font-size: 18px;
} }
#message_video #message_video
@@ -70,30 +70,19 @@
background-color: rgba(0, 0, 0, 0); background-color: rgba(0, 0, 0, 0);
color: white; color: white;
text-align: center; text-align: center;
width: 60%; width: 700px;
height: 69%; height: 410px;
margin: auto;
top: 22%;
left: 0;
right: 0;
bottom: 0;
/* 页面边距 上、右、下、左 */ /* 页面边距 上、右、下、左 */
margin: 1.89% 0px 0px 0%; margin: 1.89% 0px 0px 0%;
} }
#message_com #message_com
{ {
background-color: rgba(255, 255, 255, 0); background-color: rgba(0, 0, 0, 0);
width: 360px;
width: 33%; height: 410px;
height: 69%;
margin: auto;
top: 22%;
left: 0;
right: 0;
bottom: 0;
/* 页面边距 上、右、下、左 */ /* 页面边距 上、右、下、左 */
margin: -38.4% 0px 0px 63.8%; margin: -405px 0px 0px 63.8%;
} }
@@ -109,7 +98,7 @@
right: 0; right: 0;
bottom: 0; bottom: 0;
/* 页面边距 上、右、下、左 */ /* 页面边距 上、右、下、左 */
margin: -30% 0px 0px 36.8%; margin: 4% 0px 0px 36.8%;
} }
#back_url #back_url
@@ -140,8 +129,8 @@ function push_message() {
</script> </script>
<script> <script>
// 这是你的 API 地址,请确保它是正确的 const API_URL = 'https://api.ww3.tw/danmu/get.php'; //连接api的地址
const API_URL = 'https://api.ww3.tw/danmu/index.php';
// 使用 DOMContentLoaded 事件,确保页面 HTML 结构加载完成后再执行 JavaScript // 使用 DOMContentLoaded 事件,确保页面 HTML 结构加载完成后再执行 JavaScript
document.addEventListener('DOMContentLoaded', async () => { document.addEventListener('DOMContentLoaded', async () => {
// 获取用于显示内容的 <pre> 元素 // 获取用于显示内容的 <pre> 元素

View File

@@ -2,10 +2,10 @@
#message_block #message_block
{ {
background-color: rgba(0, 0, 0, 0.68); background-color: rgba(0, 0, 0, 0.68);
width: 85%; position: fixed;
width: 1150px;
height: 100%; height: 100%;
margin: auto; margin: auto;
position: absolute;
top: 0; top: 0;
left: 0; left: 0;
right: 0; right: 0;

View File

@@ -0,0 +1,14 @@
<style>
#black_block
{
background-color: rgba(0, 0, 0, 0.68);
position: fixed;
width: 1150px;
height: 100%;
margin: auto;
top: 0;
left: 0;
right: 0;
bottom: 0;
}
</style>