liushengqiang 2 سال پیش
والد
کامیت
085a72b00f
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      src/views/courseware-list/component/book/index.tsx

+ 2 - 2
src/views/courseware-list/component/book/index.tsx

@@ -64,7 +64,7 @@ export default defineComponent({
       const height = document.body.clientHeight * 0.8;
 
       data.height = height;
-      data.width = height * 0.8 * 2;
+      data.width = height * (210 / 297) * 2;
       book.turn({
         autoCenter: true,
         duration: 1000,
@@ -133,7 +133,7 @@ export default defineComponent({
     });
     const getList = () => {
       if (!props.bookData?.lessonList) return;
-      const step = (document.body.clientHeight * 0.8 - 40) / 50;
+      const step = Math.floor((document.body.clientHeight * 0.8 - 40) / 50);
       console.log("🚀 ~ step:", step)
       const list = [];
       let listItem = [] as any[];