Skip to content

Commit ad336c6

Browse files
committed
Sets message as required
1 parent c712d48 commit ad336c6

File tree

1 file changed

+2
-3
lines changed
  • app/javascript/components/common/inline-flash-message

1 file changed

+2
-3
lines changed

app/javascript/components/common/inline-flash-message/index.jsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,16 +27,15 @@ const InlineFlashMessage = ({ message, onCloseClick, showCloseButton }) => {
2727

2828
InlineFlashMessage.propTypes = {
2929
message: PropTypes.shape({
30-
kind: PropTypes.oneOf(['success', 'error', 'info', 'warning']),
30+
kind: PropTypes.oneOf(['success', 'error', 'info', 'warning']).isRequired,
3131
title: PropTypes.string,
3232
subtitle: PropTypes.string,
33-
}),
33+
}).isRequired,
3434
onCloseClick: PropTypes.func,
3535
showCloseButton: PropTypes.bool,
3636
};
3737

3838
InlineFlashMessage.defaultProps = {
39-
message: null,
4039
onCloseClick: () => {},
4140
showCloseButton: true,
4241
};

0 commit comments

Comments
 (0)