feat: 新增水印

This commit is contained in:
hxr
2024-02-21 00:14:04 +08:00
parent d26cbbfbb0
commit 4b2f74aa11
7 changed files with 66 additions and 40 deletions

View File

@@ -73,7 +73,13 @@ const cachedViews = computed(() => tagsViewStore.cachedViews); // 缓存页面
.layout-top {
.fixed-header + .app-main {
padding-top: $tags-view-height;
padding-top: 0;
}
.hasTagsView {
.fixed-header + .app-main {
padding-top: $tags-view-height;
}
}
}
</style>

View File

@@ -30,7 +30,7 @@
<div class="py-[8px] flex-x-between">
<span class="text-xs">开启水印</span>
<el-switch v-model="settingsStore.sidebarLogo" />
<el-switch v-model="settingsStore.watermarkEnabled" />
</div>
<el-divider>主题颜色</el-divider>

View File

@@ -25,7 +25,7 @@
<TagsView v-if="showTagsView" />
</div>
<AppMain />
<RightPanel v-if="showSettings">
<RightPanel v-if="defaultSettings.showSettings">
<Settings />
</RightPanel>
</div>
@@ -38,7 +38,7 @@
<TagsView v-if="showTagsView" />
</div>
<AppMain />
<RightPanel v-if="showSettings">
<RightPanel v-if="defaultSettings.showSettings">
<Settings />
</RightPanel>
</div>
@@ -47,6 +47,7 @@
<script setup lang="ts">
import { useAppStore, useSettingsStore, usePermissionStore } from "@/store";
import defaultSettings from "@/settings";
const appStore = useAppStore();
const settingsStore = useSettingsStore();
@@ -54,7 +55,6 @@ const permissionStore = usePermissionStore();
const fixedHeader = computed(() => settingsStore.fixedHeader);
const showTagsView = computed(() => settingsStore.tagsView);
const showSettings = computed(() => settingsStore.showSettings);
const layout = computed(() => settingsStore.layout);
const activeTopMenuPath = computed(() => {
@@ -176,7 +176,8 @@ function toggleSidebar() {
}
.main-container {
margin-top: $navbar-height;
min-height: (100vh - $navbar-height);
padding-top: $navbar-height;
margin-left: 0;
}
}