This repository was archived by the owner on Sep 7, 2020. It is now read-only.
File tree 2 files changed +22
-18
lines changed
2 files changed +22
-18
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ import {
26
26
OtherChannelHeader ,
27
27
} from '../components/ChannelView'
28
28
import { UserDescriptor } from 'twilio-chat/lib/userdescriptor'
29
+ import { XSquare , Maximize2 , Minimize2 } from 'react-feather'
29
30
30
31
type AuthorMap = { [ key : string ] : User }
31
32
type AuthorNicks = { [ key : string ] : string | undefined }
@@ -360,7 +361,7 @@ export const ChannelView = ({
360
361
onCloseChannel ( otherChannel )
361
362
} }
362
363
>
363
- X
364
+ < XSquare />
364
365
</ MinimizeButton >
365
366
</ OtherChannelHeader >
366
367
) ) }
@@ -372,26 +373,13 @@ export const ChannelView = ({
372
373
Chat: < strong > #{ selectedChannel } </ strong >
373
374
</ Title >
374
375
< span >
375
- { joinedChannels . length > 1 && (
376
- < MinimizeButton
377
- onClick = { e => {
378
- e . stopPropagation ( )
379
- onSwitchChannel (
380
- joinedChannels . find ( c => c !== selectedChannel ) as string ,
381
- )
382
- onCloseChannel ( selectedChannel )
383
- } }
384
- >
385
- X
386
- </ MinimizeButton >
387
- ) }
388
376
{ ! isMinimized && (
389
377
< MinimizeButton
390
378
onClick = { ( ) => {
391
379
memoMinimized ( true )
392
380
} }
393
381
>
394
- _
382
+ < Minimize2 />
395
383
</ MinimizeButton >
396
384
) }
397
385
{ isMinimized && (
@@ -400,7 +388,20 @@ export const ChannelView = ({
400
388
memoMinimized ( false )
401
389
} }
402
390
>
403
- +
391
+ < Maximize2 />
392
+ </ MinimizeButton >
393
+ ) }
394
+ { joinedChannels . length > 1 && (
395
+ < MinimizeButton
396
+ onClick = { e => {
397
+ e . stopPropagation ( )
398
+ onSwitchChannel (
399
+ joinedChannels . find ( c => c !== selectedChannel ) as string ,
400
+ )
401
+ onCloseChannel ( selectedChannel )
402
+ } }
403
+ >
404
+ < XSquare />
404
405
</ MinimizeButton >
405
406
) }
406
407
</ span >
Original file line number Diff line number Diff line change @@ -44,12 +44,15 @@ export const Button = styled.button`
44
44
margin: 0.5rem;
45
45
`
46
46
47
- export const MinimizeButton = styled ( Button ) `
47
+ export const MinimizeButton = styled . button `
48
48
width: 30px;
49
- border-color: #fff;
49
+ height: 30px;
50
+ border: 0;
51
+ padding: 0;
50
52
${ Header } & {
51
53
color: inherit;
52
54
}
55
+ background-color: transparent;
53
56
cursor: pointer;
54
57
`
55
58
You can’t perform that action at this time.
0 commit comments