From 24b82c46bd6b67ab3ccfa0614c0a65d707e32a4d Mon Sep 17 00:00:00 2001 From: red-deng-deng <1924913374@qq.com> Date: Fri, 21 Jan 2022 15:38:37 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A8=A1=E6=9D=BF=E4=B8=AD=E5=BF=83=E6=BB=9A?= =?UTF-8?q?=E5=8A=A8=E5=9B=9E=E5=88=B0=E9=A1=B6=E9=83=A8=E6=95=88=E6=9E=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/exchangepage/template/main.js | 24 +++++++++++------------ src/pages/exchangepage/template/main.less | 21 +++++++++++++++----- 2 files changed, 27 insertions(+), 18 deletions(-) diff --git a/src/pages/exchangepage/template/main.js b/src/pages/exchangepage/template/main.js index 5a6d9246..ee94d407 100644 --- a/src/pages/exchangepage/template/main.js +++ b/src/pages/exchangepage/template/main.js @@ -36,6 +36,7 @@ export default class mytemplate extends React.Component{ preview_visible:false, topbar:"", top:"", + toTopshow:false, center:"", bottom:"" } @@ -220,7 +221,12 @@ export default class mytemplate extends React.Component{ onClose(){ this.setState({preview_visible:false}) } - + mouseupFn(){ + this.setState({toTopshow:true}); + } + mouseoverFn(){ + this.setState({toTopshow:false}); + } render(){ return( @@ -334,19 +340,11 @@ export default class mytemplate extends React.Component{ ) }) } - - - - - - - - - - - - +
+ + +
到底部了哟,没有了哦
diff --git a/src/pages/exchangepage/template/main.less b/src/pages/exchangepage/template/main.less index 5100ccd4..0c857a23 100644 --- a/src/pages/exchangepage/template/main.less +++ b/src/pages/exchangepage/template/main.less @@ -2548,13 +2548,24 @@ div.previewclose { background-color: var(--theme-default-hover-bg, var(--theme-primary-8, #e6efff)); z-index: 1; } -.toTopBtn{ +.toTop-canvas{ + width: 60px; + height: 60px; + border-radius: 60px; + background: #fff; + display: flex; + justify-content: center; + align-items: center; + box-shadow: 1px 2px 3px 3px #eee; position: fixed; - bottom: 0; - width: 90px; right: 2vh; + bottom:2vh; cursor: pointer; } -.toTopBtn:hover{ - transform: scale(1.2); +.toTopBtn{ + width: 40px; + fill-opacity: 0.2; +} +.toTop-canvas:hover{ + transform: scale(1.1); } \ No newline at end of file