feat: support fullscreen layout
This commit is contained in:
+7
-1
@@ -39,6 +39,12 @@ spec:
|
|||||||
value:
|
value:
|
||||||
help: 填写的值为 max-width 属性的值
|
help: 填写的值为 max-width 属性的值
|
||||||
|
|
||||||
|
- $formkit: checkbox
|
||||||
|
label: 启用全屏布局
|
||||||
|
name: fullscreen_layout
|
||||||
|
value: false
|
||||||
|
help: 开启后隐藏左右侧边栏并让正文区域占满可用宽度
|
||||||
|
|
||||||
- $formkit: checkbox
|
- $formkit: checkbox
|
||||||
label: 使用系统字体
|
label: 使用系统字体
|
||||||
name: system_font_enable
|
name: system_font_enable
|
||||||
@@ -330,4 +336,4 @@ spec:
|
|||||||
- $formkit: text
|
- $formkit: text
|
||||||
name: filing_link
|
name: filing_link
|
||||||
label: 公安备案跳转链接
|
label: 公安备案跳转链接
|
||||||
value: https://www.beian.gov.cn/
|
value: https://www.beian.gov.cn/
|
||||||
|
|||||||
+19
-1
@@ -99,6 +99,24 @@ body {
|
|||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
body[layout_mode='fullscreen'] {
|
||||||
|
.wrapper {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sidebar-left,
|
||||||
|
.sidebar-right {
|
||||||
|
display: none;
|
||||||
|
width: 0;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.container {
|
||||||
|
width: 100%;
|
||||||
|
max-width: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@media (max-width: 1024px) {
|
@media (max-width: 1024px) {
|
||||||
.sidebar-left,
|
.sidebar-left,
|
||||||
.sidebar-right {
|
.sidebar-right {
|
||||||
@@ -557,4 +575,4 @@ blockquote.twitter-tweet::before {
|
|||||||
iframe[src*="youtube.com"] {
|
iframe[src*="youtube.com"] {
|
||||||
border: calc(var(--width-theme-border) * 2) var(--style-theme-border) var(--color-theme-accent) !important;
|
border: calc(var(--width-theme-border) * 2) var(--style-theme-border) var(--color-theme-accent) !important;
|
||||||
padding: calc(var(--size-theme-font) * 0.5) !important;
|
padding: calc(var(--size-theme-font) * 0.5) !important;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -113,6 +113,12 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
body[layout_mode='fullscreen'] {
|
||||||
|
.toc.toc-visible {
|
||||||
|
border: calc(var(--size-theme-font) * 0.0625) solid var(--color-theme-foreground);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@media (max-width: 1400px) {
|
@media (max-width: 1400px) {
|
||||||
.toc.toc-visible {
|
.toc.toc-visible {
|
||||||
border: calc(var(--size-theme-font) * 0.0625) solid var(--color-theme-foreground);
|
border: calc(var(--size-theme-font) * 0.0625) solid var(--color-theme-foreground);
|
||||||
|
|||||||
@@ -144,7 +144,7 @@
|
|||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body th:attr="layout_mode=${theme.config.style.fullscreen_layout ? 'fullscreen' : 'normal'}">
|
||||||
<div class="page">
|
<div class="page">
|
||||||
<header role="banner">
|
<header role="banner">
|
||||||
<div id="header-slot" aria-hidden="true"></div>
|
<div id="header-slot" aria-hidden="true"></div>
|
||||||
|
|||||||
Reference in New Issue
Block a user