From 472cebc43e43b7fc6095da7112fa2ecbdc39392e Mon Sep 17 00:00:00 2001 From: troyeguo <13820674+troyeguo@users.noreply.github.com> Date: Tue, 30 Nov 2021 19:12:16 +0800 Subject: [PATCH] fix bug Former-commit-id: 72e40c7486be0f440712daf78f7b14f53628672b --- src/containers/epubReader/index.css | 16 ++++++++-------- src/containers/lists/cardList/cardList.css | 2 ++ .../panels/operationPanel/component.tsx | 3 +++ src/containers/panels/operationPanel/index.tsx | 2 ++ .../panels/operationPanel/interface.tsx | 2 ++ 5 files changed, 17 insertions(+), 8 deletions(-) diff --git a/src/containers/epubReader/index.css b/src/containers/epubReader/index.css index 6f8a99d9..331d79bd 100644 --- a/src/containers/epubReader/index.css +++ b/src/containers/epubReader/index.css @@ -69,10 +69,10 @@ } .left-panel { width: 50px; - height: 200px; + height: 250px; position: absolute; left: 0px; - top: calc(50vh - 100px); + top: calc(50vh - 125px); background-color: rgba(75, 75, 75, 0.3); border-bottom-right-radius: 50px; border-top-right-radius: 50px; @@ -85,10 +85,10 @@ } .right-panel { width: 50px; - height: 200px; + height: 250px; position: absolute; right: 0px; - top: calc(50vh - 100px); + top: calc(50vh - 125px); background-color: rgba(75, 75, 75, 0.3); border-bottom-left-radius: 50px; border-top-left-radius: 50px; @@ -100,10 +100,10 @@ cursor: pointer; } .top-panel { - width: 200px; + width: 250px; height: 50px; position: absolute; - right: calc(50vw - 100px); + right: calc(50vw - 125px); top: 0px; background-color: rgba(75, 75, 75, 0.3); border-bottom-left-radius: 50px; @@ -116,10 +116,10 @@ cursor: pointer; } .bottom-panel { - width: 200px; + width: 250px; height: 50px; position: absolute; - right: calc(50vw - 100px); + right: calc(50vw - 125px); top: calc(100vh - 50px); background-color: rgba(75, 75, 75, 0.3); border-top-left-radius: 50px; diff --git a/src/containers/lists/cardList/cardList.css b/src/containers/lists/cardList/cardList.css index dc177e3f..8feadac3 100644 --- a/src/containers/lists/cardList/cardList.css +++ b/src/containers/lists/cardList/cardList.css @@ -101,6 +101,7 @@ width: calc(100% - 25px); height: 53px; overflow-y: scroll; + overflow-x: hidden; margin: 14px 10px 0px 10px; position: absolute; cursor: text; @@ -118,6 +119,7 @@ line-height: 18px; font-size: 15px; padding-right: 5px; + overflow-x: hidden; } ::-webkit-scrollbar { width: 5px; diff --git a/src/containers/panels/operationPanel/component.tsx b/src/containers/panels/operationPanel/component.tsx index 5209c8d1..f3d18199 100644 --- a/src/containers/panels/operationPanel/component.tsx +++ b/src/containers/panels/operationPanel/component.tsx @@ -124,6 +124,9 @@ class OperationPanel extends React.Component< if (this.props.htmlBook) { this.props.handleHtmlBook(null); } + if (this.props.currentBook.key) { + this.props.handleReadingBook({}); + } } //控制进入全屏 handleFullScreen() { diff --git a/src/containers/panels/operationPanel/index.tsx b/src/containers/panels/operationPanel/index.tsx index 08dd3ca6..00beb40f 100644 --- a/src/containers/panels/operationPanel/index.tsx +++ b/src/containers/panels/operationPanel/index.tsx @@ -7,6 +7,7 @@ import { handleSearch, handleReadingState, handleHtmlBook, + handleReadingBook, } from "../../../store/actions"; import { stateType } from "../../../store"; import { withTranslation } from "react-i18next"; @@ -32,6 +33,7 @@ const actionCreator = { handleShowBookmark, handleSearch, handleHtmlBook, + handleReadingBook, }; export default connect( mapStateToProps, diff --git a/src/containers/panels/operationPanel/interface.tsx b/src/containers/panels/operationPanel/interface.tsx index a1cd2c65..69206730 100644 --- a/src/containers/panels/operationPanel/interface.tsx +++ b/src/containers/panels/operationPanel/interface.tsx @@ -21,6 +21,8 @@ export interface OperationPanelProps extends RouteComponentProps { handleSearch: (isSearch: boolean) => void; handleOpenMenu: (isOpenMenu: boolean) => void; handleShowBookmark: (isShowBookmark: boolean) => void; + handleReadingBook: (currentBook: BookModel | object) => void; + t: (title: string) => string; handleHtmlBook: (htmlBook: HtmlBookModel | null) => void; }