From bdfdf687a44147b5e7f8c76a1b01ca9283f99639 Mon Sep 17 00:00:00 2001 From: Ibrahem Khalil Date: Mon, 21 Aug 2023 11:49:41 +0300 Subject: [PATCH] [16827] Disable transparent video looping (#17000) --- package.json | 4 ++-- src/status_im2/common/parallax/view.cljs | 10 ++++++---- .../contexts/onboarding/generating_keys/view.cljs | 3 ++- yarn.lock | 4 ++-- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/package.json b/package.json index 2501d2bd74..71546ea037 100644 --- a/package.json +++ b/package.json @@ -66,13 +66,13 @@ "react-native-randombytes": "^3.6.1", "react-native-reanimated": "2.11.0", "react-native-redash": "^16.0.11", - "react-native-svg": "13.10.0", "react-native-shake": "^3.3.1", "react-native-share": "^8.2.2", "react-native-static-safe-area-insets": "^2.2.0", "react-native-status-keycard": "git+https://github.com/status-im/react-native-status-keycard.git#refs/tags/v2.5.39", + "react-native-svg": "13.10.0", "react-native-touch-id": "^4.4.1", - "react-native-transparent-video": "git+https://github.com/status-im/react-native-transparent-video.git#refs/tags/0.0.9", + "react-native-transparent-video": "git+https://github.com/status-im/react-native-transparent-video.git#refs/tags/0.1.1", "react-native-webview": "git+https://github.com/status-im/react-native-webview.git#refs/tags/v11.16.0-status", "react-syntax-highlighter": "^15.5.0", "rn-emoji-keyboard": "0.7.0", diff --git a/src/status_im2/common/parallax/view.cljs b/src/status_im2/common/parallax/view.cljs index ece499fb31..402144450a 100644 --- a/src/status_im2/common/parallax/view.cljs +++ b/src/status_im2/common/parallax/view.cljs @@ -6,7 +6,7 @@ [status-im2.common.parallax.style :as style])) (defn f-sensor-animated-video - [{:keys [offset stretch order source disable-parallax?]}] + [{:keys [offset stretch order source disable-parallax? enable-looping?]}] (let [double-stretch (* 2 stretch) {window-width :width window-height :height} (rn/get-window) @@ -25,14 +25,15 @@ image-style]} [transparent-video/view {:source source - :style style/video}]]))) + :style style/video + :loop enable-looping?}]]))) (defn sensor-animated-video [props] [:f> f-sensor-animated-video props]) (defn f-video - [{:keys [layers disable-parallax? offset stretch container-style] + [{:keys [layers disable-parallax? offset stretch container-style enable-looping?] :or {offset 50 stretch 0}}] [rn/view @@ -44,7 +45,8 @@ :offset offset :stretch stretch :order (inc idx) - :disable-parallax? disable-parallax?}]) + :disable-parallax? disable-parallax? + :enable-looping? enable-looping?}]) layers)]) (defn video diff --git a/src/status_im2/contexts/onboarding/generating_keys/view.cljs b/src/status_im2/contexts/onboarding/generating_keys/view.cljs index 10976c16e9..db7c3dd1da 100644 --- a/src/status_im2/contexts/onboarding/generating_keys/view.cljs +++ b/src/status_im2/contexts/onboarding/generating_keys/view.cljs @@ -125,7 +125,8 @@ :container-style {:top 40 :left 20} :layers (:generate-keys resources/parallax-video) - :disable-parallax? true}] + :disable-parallax? true + :enable-looping? false}] [:f> f-page-title insets]]) (defn f-simple-page diff --git a/yarn.lock b/yarn.lock index 1d2c94af75..34226e2963 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9012,9 +9012,9 @@ react-native-touch-id@^4.4.1: resolved "https://registry.yarnpkg.com/react-native-touch-id/-/react-native-touch-id-4.4.1.tgz#8b1bb2d04c30bac36bb9696d2d723e719c4a8b08" integrity sha512-1jTl8fC+0fxvqegy/XXTyo6vMvPhjzkoDdaqoYZx0OH8AT250NuXnNPyKktvigIcys3+2acciqOeaCall7lrvg== -"react-native-transparent-video@git+https://github.com/status-im/react-native-transparent-video.git#refs/tags/0.0.9": +"react-native-transparent-video@git+https://github.com/status-im/react-native-transparent-video.git#refs/tags/0.1.1": version "0.1.0" - resolved "git+https://github.com/status-im/react-native-transparent-video.git#97d8c773eae82851b170b53c9fc13020f74eefe7" + resolved "git+https://github.com/status-im/react-native-transparent-video.git#1327fc622f7521269f66299c3aca610494c76fe1" "react-native-webview@git+https://github.com/status-im/react-native-webview.git#refs/tags/v11.16.0-status": version "11.16.0"