Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit d66c006

Browse files
authored
fix(post-viewer): id sign align (#1298)
1 parent 7a666f0 commit d66c006

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

src/containers/viewer/ArticleViewer/PostViewer/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ const PostViewer: FC<TProps> = ({ article, loading }) => {
3838
<Wrapper>
3939
<Header article={article} />
4040
<Title>
41-
{article.title}
42-
<SubTitle>#{article.id}</SubTitle>
41+
<span>{article.title}</span>
42+
<SubTitle>{article.id}</SubTitle>
4343
</Title>
4444
<ArticleInfo article={article} />
4545
<ViewportTracker onEnter={hideFixedHeader} onLeave={showFixedHeader} />
Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import styled from 'styled-components'
22

3-
import css, { theme } from '@/utils/css'
3+
import { theme } from '@/utils/css'
44

55
export const Wrapper = styled.div`
66
padding: 0 8px;
@@ -11,13 +11,21 @@ export const BodyWrapper = styled.div`
1111
margin-top: 5px;
1212
`
1313
export const Title = styled.div`
14-
${css.flex('align-center')};
1514
color: ${theme('thread.articleTitle')};
1615
font-size: 25px;
1716
`
18-
export const SubTitle = styled.div`
17+
export const SubTitle = styled.span`
18+
display: inline-block;
1919
color: ${theme('thread.articleTitle')};
2020
opacity: 0.4;
21-
font-size: 18px;
21+
font-size: 19px;
2222
margin-left: 10px;
23+
margin-top: -2px;
24+
25+
&:before {
26+
content: '#';
27+
margin-top: 1px;
28+
margin-right: 2px;
29+
font-size: 17px;
30+
}
2331
`

0 commit comments

Comments
 (0)