Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,11 @@ import 'react-phone-input-2/lib/style.css'

### Style
<table>
<tr>
<td> className </td>
<td> string </td>
<td colspan="2"> general class for the component to work with styled components </td>
</tr>
<tr>
<td> containerClass </td>
<td> string </td>
Expand Down
3 changes: 2 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ class PhoneInput extends React.Component {
buttonClass: PropTypes.string,
dropdownClass: PropTypes.string,
searchClass: PropTypes.string,
className: PropTypes.string,

autoFormat: PropTypes.bool,

Expand Down Expand Up @@ -935,7 +936,7 @@ class PhoneInput extends React.Component {

return (
<div
className={containerClasses}
className={`${className} ${containerClasses}`}
style={this.props.style || this.props.containerStyle}
onKeyDown={this.handleKeydown}>
{specialLabel && <div className='special-label'>{specialLabel}</div>}
Expand Down