Skip to content

Overlay is not animated #8

@St1ggy

Description

@St1ggy

I have diff, but I can't push and create PR

diff --git a/lib/ActionSheetCustom.js b/lib/ActionSheetCustom.js
index 531c2fb..6d35a4a 100644
--- a/lib/ActionSheetCustom.js
+++ b/lib/ActionSheetCustom.js
@@ -175,7 +175,18 @@ class ActionSheet extends Component {
         onRequestClose={this.cancel}
       >
         <View style={styles.wrapper}>
-          <Text style={styles.overlay} onPress={this.cancel} />
+          <Animated.Text
+            style={[
+              styles.overlay,
+              {
+                opacity: sheetPositionY.interpolate({
+                  outputRange: [0.4, 0],
+                  inputRange: [0, this.translateY],
+                  extrapolate: 'clamp',
+                }),
+              },
+            ]}
+            onPress={this.cancel}
+          />
           <Animated.View
             style={[
               styles.backdrop,

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions