Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 00ea9b1

Browse files
Use a better PropTypes definition for the text styles.
1 parent 1a1d289 commit 00ea9b1

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

‎VirtualKeyboard.js‎

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,9 @@ class VirtualKeyboard extends Component {
288288
}
289289
}
290290

291+
292+
const stylePropType = PropTypes.oneOfType([PropTypes.number, PropTypes.object, PropTypes.array, PropTypes.bool]);
293+
291294
VirtualKeyboard.propTypes = {
292295
onRef: PropTypes.any.isRequired,
293296
onKeyDown: PropTypes.func,
@@ -299,13 +302,13 @@ VirtualKeyboard.propTypes = {
299302
keyboardMessageDisplayTime: PropTypes.number,
300303
vibration: PropTypes.bool,
301304
// Style props
302-
keyboardStyle: PropTypes.object,
303-
keyboardDisabledStyle: PropTypes.object,
304-
keyStyle: PropTypes.object,
305-
keyTextStyle: PropTypes.object,
306-
keyImageStyle: PropTypes.object,
307-
messageStyle: PropTypes.object,
308-
messageTextStyle: PropTypes.object
305+
keyboardStyle: stylePropType,
306+
keyboardDisabledStyle: stylePropType,
307+
keyStyle: stylePropType,
308+
keyTextStyle: stylePropType,
309+
keyImageStyle: stylePropType,
310+
messageStyle: stylePropType,
311+
messageTextStyle: stylePropType
309312
};
310313

311314
VirtualKeyboard.defaultProps = {

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /