Questions tagged [layout-animation]
66 questions
1
vote
0 answers
React-native layout animation for row deletion updates entire section in SectionList
I cannot get LayoutAnimation to just animate the row being deleted, unless it is the last row. For anything else, all rows below the row being deleted get animated and it does not look right.
const layoutConfig = {
duration: 4500,
create: {
…

Agent86
- 424
- 4
- 7
1
vote
1 answer
React Native default LayoutAnimations on iOS
It seems to me that React Native adds default LayoutAnimations only on iOS. I have the exact same code for iOS & Android and on iOS layout and CSS changes are animated. For example hiding/showing some Views have spring or easeIn animations. Or…

raouaoul
- 681
- 2
- 13
- 33
1
vote
1 answer
layoutAnimation causes extra blue background on Android while switching between two views
I am using layoutAnimation in a function component to make it appear smoothly. It works well on IOS, but on Android, it will show an extra blue transparent background while I switch from another view to the view using layoutAnimation.
This is my…

echo
- 11
- 1
1
vote
1 answer
React Native Android crash with LayoutAnimationController.shouldAnimateLayout
My app crashes in the production mode on android devices. Basically it is happening on Android 10(Samsung, Xiaomi, Huawei, LGE).
Stacktrace
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method…

jocoders
- 1,594
- 2
- 19
- 54
1
vote
1 answer
How should LayoutAnimation be activated on component property change?
React Native LayoutAnimation allows automatically animating views to new positions when the next layout occurs.
I have items stored in Redux which are passed as properties into a component that renders them. When the properties change I want the…

Sampo
- 4,308
- 6
- 35
- 51
1
vote
0 answers
Create a new animation from TListViewItem PlaceOffset not working
I have a problem to animate an item in a TListView in the PlaceOffset. How can I do it?
I want to change the X and Y position of an item in a TListView from
position.X = -56 to position.X = 144
and
position.Y = 16 to position.Y = 96
I can do it…

xoras xorpas
- 11
- 1
1
vote
1 answer
React Native's LayoutAnimation animates only some of the UI elements, others jump
This has been tested using React Native 0.59 and 0.60.4 (latest):
As you can see, everything is animated except the title, which just hops to its new position.
This was created by the following code:
import React, { Component } from 'react';
import…

Jonas Sourlier
- 13,684
- 16
- 77
- 148
1
vote
1 answer
How To Make An Edit Text Float on top of toolbar and Main Layout
I want to achieve this kind of design
As you can see the Edit text performs a nice animation to translate from the middle of the screen to the Top of the layout but i would like to know how achieve this.
I was thinking about wrapping the edit text…

AouledIssa
- 2,528
- 2
- 22
- 39
1
vote
0 answers
LayoutAnimation doesn't play well with justifyContent: 'space-between'
Something is really annoying me with LayoutAnimation.
See the video and notice the jump on the counters.
Also, here's a repository on RNPlay:
https://rnplay.org/apps/atSZAA
I'm using a simple config here:
componentWillUpdate() {
…

Ahmad Al Haddad
- 1,124
- 10
- 10
1
vote
0 answers
How to restrict child views to inherit parent view's animation
I have a LinearLayout that have a ListView and a LinearLayout init.
Based on some condition I just change the visibility of the parent linear layout.
Whenever I set visibility as Visible to the parent,I set bottom-up animation programmatically as…

MohanRaj
- 662
- 1
- 6
- 21
1
vote
1 answer
Animate two Views together in Android
In my layout I have one button and an AddView on the top of the screen (Image below explain it better). I need the AddView to show only when it is loaded and for that I made an AdListener. But now I want my button to slide down when the AddView is…

stanete
- 4,062
- 9
- 21
- 30
1
vote
1 answer
TextViews animate only once on Android 4
I have a layout (RelativeLayout) with a number of buttons and two text views. For each change of information I fade out all the views, update the information and then fade in the views. I use layoutanimations for this.
The very strange thing is that…

Snakebunk
- 21
- 5
0
votes
0 answers
Toggle text animation doesn't work properly when using React Native LayoutAnimation with navigation stack
Took code example from documentation to toggle text with React Native LayoutAnimation. It is working fine when is used without navigation stack. But when I push the component in Stack.Screen it starts working incorrectly.
Problem example…
0
votes
0 answers
React Native AnimationLayout only works on Last Element of ListView
In my React Native expo app, I am trying to animate the removal of an element from a ListView when the user clicks on the list element using LayoutAnimation.
However, only the final element at the bottom of the ListView appears to show the "fading…

Athena Wisdom
- 6,101
- 9
- 36
- 60
0
votes
2 answers
Layout Animation does not work on Android even with UIManager experimental settings
I've been trying to implement LayoutAnimation to animate the insertion and deletion of items from scrollView. I've added the below code for the same.
import { LayoutAnimation, NativeModules } from 'react-native';
// Animation setup for…

AMAL MOHAN N
- 1,416
- 2
- 14
- 26