From 0622a4bd3d8320400bce96278e57955a9fbc8f34 Mon Sep 17 00:00:00 2001 From: Szymon20000 Date: Tue, 21 Sep 2021 13:04:16 +0200 Subject: [PATCH] Fix default layout transition (#2442) ## Description Fix native stack modal example --- .../layoutReanimation/defaultAnimations/Default.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/reanimated2/layoutReanimation/defaultAnimations/Default.ts b/src/reanimated2/layoutReanimation/defaultAnimations/Default.ts index 8a7785989689..a4b3a1814f75 100644 --- a/src/reanimated2/layoutReanimation/defaultAnimations/Default.ts +++ b/src/reanimated2/layoutReanimation/defaultAnimations/Default.ts @@ -3,10 +3,15 @@ import { EntryExitAnimationFunction, } from '../animationBuilder/commonTypes'; -export const DefaultLayout: LayoutAnimationFunction = (_) => { +export const DefaultLayout: LayoutAnimationFunction = (values) => { 'worklet'; return { - initialValues: {}, + initialValues: { + originX: values.originX, + originY: values.originY, + width: values.width, + height: values.height, + }, animations: {}, }; };