Skip to content

newDrawer - add useNativeAnimations #469

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 15, 2019

Conversation

roiberlin
Copy link
Contributor

No description provided.

@@ -59,9 +59,9 @@ export default class Swipeable extends Component<PropType, StateType> {
static defaultProps = {
friction: 1,
overshootFriction: 1,
// useNativeAnimations: true // issue in iPhone 5
useNativeAnimations: true
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you test it on iPhone5?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for react-native-ui-lib we will enable it for all devices
for our private library i will disable it for iPhone5

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But the bug exists in the public repo as well. I can't leave it like this

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@roiberlin keep the default value false here and just expose the prop thru Drawer.
in the private repo we'll turn it on only if it's not iPhone5

btw, @Inbal-Tish in my opinion, the performance here is preferable on the iPhone5 issue.
your call

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't see a hit on performance when I turned it off. We need to find a way to actually measure it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@@ -234,6 +238,7 @@ class NewDrawer extends PureBaseComponent {
leftActionsContainerStyle={this.leftActionsContainerStyle}
onSwipeableWillOpen={this.onSwipeableWillOpen}
onSwipeableWillClose={this.onSwipeableWillClose}
useNativeAnimations={useNativeAnimations}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you don't need to pass it, it will be passed in 'others' if you don't extract it from the props object.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@Inbal-Tish Inbal-Tish merged commit 4e57c5c into master Jul 15, 2019
@ethanshar ethanshar deleted the newDrawer-add-useNativeAnimations- branch December 11, 2019 18:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants