From 8f11e9fab4817808c4141aaa019e10516a2d9787 Mon Sep 17 00:00:00 2001 From: crossdark Date: Fri, 20 Sep 2024 19:50:26 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E5=A5=BD=E4=BA=86=E4=BD=86?= =?UTF-8?q?=E5=8F=88=E6=B2=A1=E6=9C=89=E5=AE=8C=E5=85=A8=E5=A5=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SinkDark/publicStatic/css/base.css | 22 +++++++++++++++++----- SinkDark/templates/base.html | 8 ++++++++ 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/SinkDark/publicStatic/css/base.css b/SinkDark/publicStatic/css/base.css index f9957a3..09e3702 100644 --- a/SinkDark/publicStatic/css/base.css +++ b/SinkDark/publicStatic/css/base.css @@ -22,7 +22,19 @@ article { width: 1000px; margin: 80px auto 0; overflow: hidden; zoom: 1; } /* 左边栏CSS样式规则 */ float: left; /* 举例:让这个aside元素向左浮动 */ width: 20%; /* 举例:设置宽度为父容器的25% */ - margin-right: 20px; /* 举例:设置右边距为20px */ + margin-right: 10px; /* 举例:设置右边距为20px */ + background-color: #f0f0f0; /* 举例:设置背景颜色为浅灰色 */ + /* 您可以添加更多的样式规则 */ + overflow: hidden; + display: block; + position: relative; + z-index: 1 +} +.rt_box { + /* 右边栏CSS样式规则 */ + float: right; /* 举例:让这个aside元素向右浮动 */ + width: 20%; /* 举例:设置宽度为父容器的20% */ + margin-left: 10px; /* 举例:设置右边距为20px */ background-color: #f0f0f0; /* 举例:设置背景颜色为浅灰色 */ /* 您可以添加更多的样式规则 */ overflow: hidden; @@ -31,10 +43,9 @@ article { width: 1000px; margin: 80px auto 0; overflow: hidden; zoom: 1; } z-index: 1 } .r_box { - /* 右边栏CSS样式规则 */ - float: right; /* 举例:让这个aside元素向右浮动 */ - width: 20%; /* 举例:设置宽度为父容器的20% */ - margin-left: 20px; /* 举例:设置右边距为20px */ +/* 右边栏CSS样式规则 */ + float: center; /* 举例:让这个aside元素向右浮动 */ + width: 70%; /* 举例:设置宽度为父容器的20% */ background-color: #f0f0f0; /* 举例:设置背景颜色为浅灰色 */ /* 您可以添加更多的样式规则 */ overflow: hidden; @@ -42,6 +53,7 @@ article { width: 1000px; margin: 80px auto 0; overflow: hidden; zoom: 1; } position: relative; z-index: 1 } + main { overflow: hidden; width: 68%; float: right; display: block; } .container { width: 1000px; margin: auto } nav { width: 1000px; margin: auto } diff --git a/SinkDark/templates/base.html b/SinkDark/templates/base.html index 999e21e..5c41c8f 100644 --- a/SinkDark/templates/base.html +++ b/SinkDark/templates/base.html @@ -71,6 +71,14 @@ + {% endblock %} {% block content %}{% endblock %}