Skip to content

Commit 850892b

Browse files
committed
Cleanup CSS
1 parent 94debc6 commit 850892b

File tree

2 files changed

+39
-33
lines changed

2 files changed

+39
-33
lines changed

packages/app/src/app/pages/Sandbox/Editor/Workspace/items/Live/LiveInfo/elements.ts

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,24 @@ export const Container = styled.div`
1010
`};
1111
`;
1212

13-
export const Title = styled.div`
14-
color: #fd2439fa;
15-
font-weight: 800;
13+
export const Input = styled(InputBase)`
14+
width: calc(100% - 1.5rem);
15+
margin: 0 0.75rem;
16+
font-size: 0.875rem;
17+
`;
18+
19+
export const LiveMessage = styled.div`
20+
font-size: 1rem;
21+
flex: 1;
1622
display: flex;
1723
align-items: center;
18-
vertical-align: middle;
19-
20-
padding: 0 1rem 0.5rem;
21-
22-
svg {
23-
margin-right: 0.25rem;
24-
}
2524
`;
2625

27-
export const Input = styled(InputBase)`
28-
width: calc(100% - 1.5rem);
29-
margin: 0 0.75rem;
26+
export const NoOtherUsers = styled.div`
27+
color: rgba(255, 255, 255, 0.8);
28+
font-weight: 600;
3029
font-size: 0.875rem;
30+
margin-top: 0.25rem;
3131
`;
3232

3333
export const SubTitle = styled.div`
@@ -39,6 +39,20 @@ export const SubTitle = styled.div`
3939
font-size: 0.875rem;
4040
`;
4141

42+
export const Title = styled.div`
43+
color: #fd2439fa;
44+
font-weight: 800;
45+
display: flex;
46+
align-items: center;
47+
vertical-align: middle;
48+
49+
padding: 0 1rem 0.5rem;
50+
51+
svg {
52+
margin-right: 0.25rem;
53+
}
54+
`;
55+
4256
export const Users = styled.div`
4357
${({ theme }) => css`
4458
padding: 0 1rem 0.25rem;

packages/app/src/app/pages/Sandbox/Editor/Workspace/items/Live/LiveInfo/index.tsx

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,15 @@ import { Description, WorkspaceInputContainer } from '../../../elements';
1010
import LiveButton from '../LiveButton';
1111

1212
import Countdown from './Countdown';
13-
import { Container, Input, SubTitle, Title, Users } from './elements';
13+
import {
14+
Container,
15+
Input,
16+
LiveMessage,
17+
NoOtherUsers,
18+
SubTitle,
19+
Title,
20+
Users,
21+
} from './elements';
1422
import { FollowButton } from './FollowButton';
1523
import { LiveMode } from './LiveMode';
1624
import { MakeEditorButton } from './MakeEditorButton';
@@ -58,22 +66,15 @@ export const LiveInfo: FunctionComponent = () => {
5866
return (
5967
<Container>
6068
<Title>
61-
<div
62-
style={{
63-
fontSize: '1rem',
64-
flex: 1,
65-
display: 'flex',
66-
alignItems: 'center',
67-
}}
68-
>
69+
<LiveMessage>
6970
{reconnecting ? (
7071
'Reconnecting...'
7172
) : (
7273
<>
7374
<RecordIcon /> {getLiveMessage()}
7475
</>
7576
)}
76-
</div>
77+
</LiveMessage>
7778

7879
<div>{startTime !== null && <Countdown time={startTime} />}</div>
7980
</Title>
@@ -162,16 +163,7 @@ export const LiveInfo: FunctionComponent = () => {
162163
/>
163164
))
164165
) : (
165-
<div
166-
style={{
167-
color: 'rgba(255, 255, 255, 0.8)',
168-
fontWeight: 600,
169-
fontSize: '.875rem',
170-
marginTop: '0.25rem',
171-
}}
172-
>
173-
No other users in session, invite them!
174-
</div>
166+
<NoOtherUsers>No other users in session, invite them!</NoOtherUsers>
175167
)}
176168
</Users>
177169
</Margin>

0 commit comments

Comments
 (0)