web书架: 判断同步的阅读宽度是否超出当前设备

This commit is contained in:
Xwite committed 2023-05-15 22:51:01 +08:00
1 parent ed803f0c94
commit de9d9c3562
13 files changed
+37 -37

No files matched your search

+3 -2
View File
@@ -163,7 +163,7 @@
<script setup>
import "../assets/fonts/popfont.css";
import "../assets/fonts/iconfont.css";
import settings from "../plugins/config";
import settings from "../config/themeConfig";
import API from "@api";
const store = useBookStore();
@@ -295,7 +295,8 @@ const readWidth = computed(() => {
return store.config.readWidth;
});
const moreReadWidth = () => {
/*if (config.value.readWidth < 960)*/
// 此时会截断页面
if (config.value.readWidth + 160 + 2 * 68 > window.innerWidth) return;
config.value.readWidth += 160;
saveConfig(config.value);
};