Skip to content

Commit

Permalink
added tooltip
Browse files Browse the repository at this point in the history
tooltip
  • Loading branch information
paras151 authored and akshatnitd committed Nov 28, 2019
1 parent 26c4013 commit bd4cd5b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
13 changes: 10 additions & 3 deletions src/components/ChatApp/MessageSection/MessageSection.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import _Close from '@material-ui/icons/Close';
import _FullScreen from '@material-ui/icons/Fullscreen';
import _FullScreenExit from '@material-ui/icons/FullscreenExit';
import { IconButton as _IconButton } from '@material-ui/core';
import ToolTip from '../../shared/ToolTip';

const MessageList = styled.div`
background: ${props => props.pane};
Expand Down Expand Up @@ -758,15 +759,21 @@ class MessageSection extends Component {
)}
<CustomIconButton width={width}>
{mode === 'fullScreen' ? (
<FullScreenExit onClick={this.openPreview} />
<ToolTip title="Exit full screen">
<FullScreenExit onClick={this.openPreview} />
</ToolTip>
) : (
<FullScreen onClick={this.openFullScreen} />
<ToolTip title="Full screen">
<FullScreen onClick={this.openFullScreen} />
</ToolTip>
)}
</CustomIconButton>
<IconButton
onClick={mode === 'fullScreen' ? this.handleClose : this.toggleChat}
>
<Close />
<ToolTip title="Close">
<Close />
</ToolTip>
</IconButton>
</div>
</ActionBar>
Expand Down
5 changes: 4 additions & 1 deletion src/components/ChatApp/SearchField.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import SearchIcon from '@material-ui/icons/Search';
import _CloseIcon from '@material-ui/icons/Close';
import _UpIcon from '@material-ui/icons/ExpandLess';
import _DownIcon from '@material-ui/icons/ExpandMore';
import ToolTip from '../shared/ToolTip';

const ESCAPE_KEY = 27;
const F_KEY = 70;
Expand Down Expand Up @@ -195,7 +196,9 @@ class ExpandingSearchField extends Component {
<React.Fragment>
<Container>
<IconButton onClick={this.onClick}>
<SearchIcon />
<ToolTip title="Search">
<SearchIcon />
</ToolTip>
</IconButton>
</Container>
{open && (
Expand Down

0 comments on commit bd4cd5b

Please sign in to comment.