From 36ec3f043ce7e7e3e6b545ae93830dbdf4b2901e Mon Sep 17 00:00:00 2001 From: Z Date: Tue, 19 Nov 2019 23:34:55 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9style=EF=BC=8C=E7=BD=AE?= =?UTF-8?q?=E9=A1=B6=E6=A0=8F=E5=8F=AF=E5=85=B3=E9=97=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../features/ui/components/tabs_bar.js | 14 ++++++++++- .../styles/closed-social/global.scss | 12 ++++++++++ .../closed-social/timeline_comments.scss | 4 ++-- app/javascript/styles/thu/diff.scss | 24 ++++--------------- 4 files changed, 31 insertions(+), 23 deletions(-) diff --git a/app/javascript/mastodon/features/ui/components/tabs_bar.js b/app/javascript/mastodon/features/ui/components/tabs_bar.js index 8a5b1b5a6..696d40939 100644 --- a/app/javascript/mastodon/features/ui/components/tabs_bar.js +++ b/app/javascript/mastodon/features/ui/components/tabs_bar.js @@ -37,6 +37,10 @@ class TabsBar extends React.PureComponent { history: PropTypes.object.isRequired, } + state = { + showPinned: true, + } + setRef = ref => { this.node = ref; } @@ -73,8 +77,13 @@ class TabsBar extends React.PureComponent { } + handleClear = () => { + this.setState({ showPinned: false}); + } + render () { const { intl: { formatMessage } } = this.props; + const { showPinned } = this.state; return (
@@ -83,9 +92,12 @@ class TabsBar extends React.PureComponent {
- { pinnedInfo && + { pinnedInfo && showPinned &&
{ReactHtmlParser(pinnedInfo)} +
+ +
}
diff --git a/app/javascript/styles/closed-social/global.scss b/app/javascript/styles/closed-social/global.scss index 36ba9094b..a246fa3c2 100644 --- a/app/javascript/styles/closed-social/global.scss +++ b/app/javascript/styles/closed-social/global.scss @@ -1,8 +1,20 @@ .column { flex: 1 0 auto; } + .pinned-info { opacity: 0.85; + font-size: 15px; + padding: 10px 20px; +} + +.pinned-info__icon { + .fa { + position: absolute; + bottom: 16px; + right: 10px; + cursor: pointer; + } } div { diff --git a/app/javascript/styles/closed-social/timeline_comments.scss b/app/javascript/styles/closed-social/timeline_comments.scss index 10eff05d9..dd1f29f49 100644 --- a/app/javascript/styles/closed-social/timeline_comments.scss +++ b/app/javascript/styles/closed-social/timeline_comments.scss @@ -7,12 +7,12 @@ transform-origin: 80% 0%; margin-bottom: -32px; &:hover { - max-height: none; + max-height: 420px; -webkit-mask-image: none; mask-image: none; } &:active { - max-height: none; + max-height: 420px; -webkit-mask-image: none; mask-image: none; } diff --git a/app/javascript/styles/thu/diff.scss b/app/javascript/styles/thu/diff.scss index ecd3977a9..1fa432761 100644 --- a/app/javascript/styles/thu/diff.scss +++ b/app/javascript/styles/thu/diff.scss @@ -16,32 +16,13 @@ body { background-position: center; height: 100vh !important; } -body.app-body { +body.theme-thu { background: rgba(73, 58, 99, 1) url(https://www.tsinghua.edu.cn/publish/thu2018/images/footer.jpg) no-repeat fixed; background-size: cover; background-attachment: fixed; background-position: center; height: 100vh !important; } -body.about-body { - background: rgba(73, 58, 99, 1) url(https://www.tsinghua.edu.cn/publish/thu2018/images/footer.jpg) no-repeat fixed; - background-size: cover; - background-attachment: fixed; - background-position: center; - height: 100vh !important; -} -body.admin { - background: rgba(73, 58, 99, 1) url(https://www.tsinghua.edu.cn/publish/thu2018/images/footer.jpg) no-repeat fixed; - background-size: cover; - background-attachment: fixed; - background-position: center; - height: 100vh !important; -} -.regeneration-indicator { - background: rgba(73, 58, 99, 1) url(https://www.tsinghua.edu.cn/publish/thu2018/images/footer.jpg) no-repeat fixed; - background-size: cover; - background-attachment: fixed; -} .ui { background: rgba(0, 0, 0, .4); } @@ -253,3 +234,6 @@ button.icon-button.active { background: rgba(73, 58, 99, 0.7); } +.tabs-bar__wrapper { + background: rgba(23,25,31); +}