File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -120,7 +120,10 @@ export default class ReactNotification extends React.Component {
120120 }
121121
122122 onClick ( ) {
123- this . removeNotification ( REMOVAL . CLICK ) ;
123+ const { notification : { dismiss } } = this . props ;
124+ if ( dismiss . click || dismiss . showIcon ) {
125+ this . removeNotification ( REMOVAL . CLICK ) ;
126+ }
124127 }
125128
126129 onTouchStart ( { touches } ) {
@@ -314,7 +317,7 @@ export default class ReactNotification extends React.Component {
314317 }
315318
316319 render ( ) {
317- const { notification : { content } } = this . props ;
320+ const { notification : { content, dismiss : { click } } } = this . props ;
318321 const {
319322 parentStyle,
320323 onAnimationEnd,
@@ -325,7 +328,7 @@ export default class ReactNotification extends React.Component {
325328 return (
326329 < div
327330 ref = { this . rootElementRef }
328- onClick = { this . onClick }
331+ onClick = { click ? this . onClick : null }
329332 className = 'n-parent'
330333 style = { parentStyle }
331334 onAnimationEnd = { onAnimationEnd }
You can’t perform that action at this time.
0 commit comments