insomnia/app/ui/components/base/dropdown/dropdown-hint.js

27 lines
495 B
JavaScript
Raw Normal View History

import React, {PropTypes, PureComponent} from 'react';
import Hotkey from '../../hotkey';
2016-07-21 21:55:03 +00:00
class DropdownHint extends PureComponent {
render () {
const {char, shift, alt} = this.props;
return (
<Hotkey
className="dropdown__hint"
char={char}
alt={alt}
shift={shift}
/>
);
}
}
2016-07-21 21:55:03 +00:00
DropdownHint.propTypes = {
char: PropTypes.string.isRequired,
// Optional
alt: PropTypes.bool,
shift: PropTypes.bool
2016-07-21 21:55:03 +00:00
};
export default DropdownHint;