diff --git a/src/status_im/ui/components/list/views.cljs b/src/status_im/ui/components/list/views.cljs index 97c1919279..fb58585f70 100644 --- a/src/status_im/ui/components/list/views.cljs +++ b/src/status_im/ui/components/list/views.cljs @@ -309,7 +309,8 @@ swipe-pan-responder (responder/swipe-pan-responder offset-x styles/delete-button-width id swiped?) swipe-pan-handler (responder/pan-handlers swipe-pan-responder)] [react/view swipe-pan-handler - [react/animated-view {:style {:flex 1 :right offset-x}} + [react/animated-view {:style {:flex 1 + :transform [{:translateX offset-x}]}} body [react/touchable-highlight {:style styles/delete-icon-highlight :on-press on-delete} diff --git a/src/status_im/ui/screens/home/animations/responder.cljs b/src/status_im/ui/screens/home/animations/responder.cljs index d611faf03d..f75895fef5 100644 --- a/src/status_im/ui/screens/home/animations/responder.cljs +++ b/src/status_im/ui/screens/home/animations/responder.cljs @@ -13,7 +13,9 @@ (defn on-move [animated-offset-x end-offset-x swiped?] (fn [_ gesture] (let [to-value (get-updated-value gesture end-offset-x swiped?)] - (animation/start (animation/spring animated-offset-x {:toValue to-value}))))) + (animation/start (animation/spring animated-offset-x + {:toValue (- to-value) + :useNativeDriver true}))))) (defn on-release [animated-offset-x end-offset-x chat-id swiped?] (fn [_ gesture] @@ -21,7 +23,9 @@ should-open? (> updated-value (/ end-offset-x 2)) to-value (if should-open? end-offset-x 0)] (re-frame/dispatch [:set-swipe-position :chats chat-id should-open?]) - (animation/start (animation/spring animated-offset-x {:toValue to-value}))))) + (animation/start (animation/spring animated-offset-x + {:toValue (- to-value) + :useNativeDriver true}))))) (defn swipe-pan-responder [animated-offset-x end-offset-x chat-id swiped?] (.create (react/pan-responder)