浏览代码

fix(notifications) remove unused isDismissAllowed prop

master
Saúl Ibarra Corretgé 3 年前
父节点
当前提交
01bd18b86a

+ 1
- 7
react/features/notifications/components/AbstractNotification.js 查看文件

61
      */
61
      */
62
     icon?: String,
62
     icon?: String,
63
 
63
 
64
-    /**
65
-     * Whether or not the dismiss button should be displayed.
66
-     */
67
-    isDismissAllowed: boolean,
68
-
69
     /**
64
     /**
70
      * Maximum lines of the description.
65
      * Maximum lines of the description.
71
      */
66
      */
116
      * @static
111
      * @static
117
      */
112
      */
118
     static defaultProps = {
113
     static defaultProps = {
119
-        appearance: NOTIFICATION_TYPE.NORMAL,
120
-        isDismissAllowed: true
114
+        appearance: NOTIFICATION_TYPE.NORMAL
121
     };
115
     };
122
 
116
 
123
     /**
117
     /**

+ 5
- 10
react/features/notifications/components/native/Notification.js 查看文件

32
      * @returns {ReactElement}
32
      * @returns {ReactElement}
33
      */
33
      */
34
     render() {
34
     render() {
35
-        const { isDismissAllowed } = this.props;
36
-
37
         return (
35
         return (
38
             <View
36
             <View
39
                 pointerEvents = 'box-none'
37
                 pointerEvents = 'box-none'
47
                         }
45
                         }
48
                     </View>
46
                     </View>
49
                 </View>
47
                 </View>
50
-                {
51
-                    isDismissAllowed
52
-                    && <TouchableOpacity onPress = { this._onDismissed }>
53
-                        <Icon
54
-                            src = { IconClose }
55
-                            style = { styles.dismissIcon } />
56
-                    </TouchableOpacity>
57
-                }
48
+                <TouchableOpacity onPress = { this._onDismissed }>
49
+                    <Icon
50
+                        src = { IconClose }
51
+                        style = { styles.dismissIcon } />
52
+                </TouchableOpacity>
58
             </View>
53
             </View>
59
         );
54
         );
60
     }
55
     }

正在加载...
取消
保存