From 9f17f95a98a8a6f75c51997f3eeca3f0b70ad3b9 Mon Sep 17 00:00:00 2001 From: xmflsct Date: Tue, 9 Aug 2022 00:44:56 +0200 Subject: [PATCH] Fixed #354 --- ios/Podfile.lock | 516 +++++++++--------- package.json | 1 + src/components/ContextMenu/share.ts | 26 +- src/components/Timeline/Default.tsx | 11 +- src/components/Timeline/Notifications.tsx | 11 +- src/components/Timeline/Shared/Content.tsx | 3 - .../Timeline/Shared/ContextMenu.tsx | 10 +- src/components/Timeline/Shared/Filtered.tsx | 11 + .../Timeline/Shared/HeaderDefault.ios.tsx | 4 +- src/components/Timeline/Shared/Translate.tsx | 8 +- src/i18n/en/components/contextMenu.json | 4 + yarn.lock | 5 + 12 files changed, 333 insertions(+), 277 deletions(-) diff --git a/ios/Podfile.lock b/ios/Podfile.lock index f12e7a14..623d74dc 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -71,14 +71,14 @@ PODS: - EXUpdatesInterface (0.7.0) - EXVideoThumbnails (6.4.0): - ExpoModulesCore - - FBLazyVector (0.69.3) - - FBReactNativeSpec (0.69.3): + - FBLazyVector (0.69.4) + - FBReactNativeSpec (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - RCTRequired (= 0.69.3) - - RCTTypeSafety (= 0.69.3) - - React-Core (= 0.69.3) - - React-jsi (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) + - RCTRequired (= 0.69.4) + - RCTTypeSafety (= 0.69.4) + - React-Core (= 0.69.4) + - React-jsi (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) - Firebase/Core (8.14.0): - Firebase/CoreOnly - FirebaseAnalytics (~> 8.14.0) @@ -257,214 +257,214 @@ PODS: - fmt (~> 6.2.1) - glog - libevent - - RCTRequired (0.69.3) - - RCTTypeSafety (0.69.3): - - FBLazyVector (= 0.69.3) - - RCTRequired (= 0.69.3) - - React-Core (= 0.69.3) - - React (0.69.3): - - React-Core (= 0.69.3) - - React-Core/DevSupport (= 0.69.3) - - React-Core/RCTWebSocket (= 0.69.3) - - React-RCTActionSheet (= 0.69.3) - - React-RCTAnimation (= 0.69.3) - - React-RCTBlob (= 0.69.3) - - React-RCTImage (= 0.69.3) - - React-RCTLinking (= 0.69.3) - - React-RCTNetwork (= 0.69.3) - - React-RCTSettings (= 0.69.3) - - React-RCTText (= 0.69.3) - - React-RCTVibration (= 0.69.3) - - React-bridging (0.69.3): + - RCTRequired (0.69.4) + - RCTTypeSafety (0.69.4): + - FBLazyVector (= 0.69.4) + - RCTRequired (= 0.69.4) + - React-Core (= 0.69.4) + - React (0.69.4): + - React-Core (= 0.69.4) + - React-Core/DevSupport (= 0.69.4) + - React-Core/RCTWebSocket (= 0.69.4) + - React-RCTActionSheet (= 0.69.4) + - React-RCTAnimation (= 0.69.4) + - React-RCTBlob (= 0.69.4) + - React-RCTImage (= 0.69.4) + - React-RCTLinking (= 0.69.4) + - React-RCTNetwork (= 0.69.4) + - React-RCTSettings (= 0.69.4) + - React-RCTText (= 0.69.4) + - React-RCTVibration (= 0.69.4) + - React-bridging (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - React-jsi (= 0.69.3) - - React-callinvoker (0.69.3) - - React-Codegen (0.69.3): - - FBReactNativeSpec (= 0.69.3) + - React-jsi (= 0.69.4) + - React-callinvoker (0.69.4) + - React-Codegen (0.69.4): + - FBReactNativeSpec (= 0.69.4) - RCT-Folly (= 2021.06.28.00-v2) - - RCTRequired (= 0.69.3) - - RCTTypeSafety (= 0.69.3) - - React-Core (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-Core (0.69.3): + - RCTRequired (= 0.69.4) + - RCTTypeSafety (= 0.69.4) + - React-Core (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-Core (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-Core/Default (= 0.69.3) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-Core/Default (= 0.69.4) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/CoreModulesHeaders (0.69.3): + - React-Core/CoreModulesHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/Default (0.69.3): + - React-Core/Default (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/DevSupport (0.69.3): + - React-Core/DevSupport (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-Core/Default (= 0.69.3) - - React-Core/RCTWebSocket (= 0.69.3) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-jsinspector (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-Core/Default (= 0.69.4) + - React-Core/RCTWebSocket (= 0.69.4) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-jsinspector (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTActionSheetHeaders (0.69.3): + - React-Core/RCTActionSheetHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTAnimationHeaders (0.69.3): + - React-Core/RCTAnimationHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTBlobHeaders (0.69.3): + - React-Core/RCTBlobHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTImageHeaders (0.69.3): + - React-Core/RCTImageHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTLinkingHeaders (0.69.3): + - React-Core/RCTLinkingHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTNetworkHeaders (0.69.3): + - React-Core/RCTNetworkHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTSettingsHeaders (0.69.3): + - React-Core/RCTSettingsHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTTextHeaders (0.69.3): + - React-Core/RCTTextHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTVibrationHeaders (0.69.3): + - React-Core/RCTVibrationHeaders (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - React-Core/Default - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-Core/RCTWebSocket (0.69.3): + - React-Core/RCTWebSocket (0.69.4): - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-Core/Default (= 0.69.3) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-perflogger (= 0.69.3) + - React-Core/Default (= 0.69.4) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-perflogger (= 0.69.4) - Yoga - - React-CoreModules (0.69.3): + - React-CoreModules (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.3) - - React-Codegen (= 0.69.3) - - React-Core/CoreModulesHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - React-RCTImage (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-cxxreact (0.69.3): + - RCTTypeSafety (= 0.69.4) + - React-Codegen (= 0.69.4) + - React-Core/CoreModulesHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - React-RCTImage (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-cxxreact (0.69.4): - boost (= 1.76.0) - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-callinvoker (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsinspector (= 0.69.3) - - React-logger (= 0.69.3) - - React-perflogger (= 0.69.3) - - React-runtimeexecutor (= 0.69.3) - - React-hermes (0.69.3): + - React-callinvoker (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsinspector (= 0.69.4) + - React-logger (= 0.69.4) + - React-perflogger (= 0.69.4) + - React-runtimeexecutor (= 0.69.4) + - React-hermes (0.69.4): - DoubleConversion - glog - hermes-engine - RCT-Folly (= 2021.06.28.00-v2) - RCT-Folly/Futures (= 2021.06.28.00-v2) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-jsiexecutor (= 0.69.3) - - React-jsinspector (= 0.69.3) - - React-perflogger (= 0.69.3) - - React-jsi (0.69.3): + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-jsiexecutor (= 0.69.4) + - React-jsinspector (= 0.69.4) + - React-perflogger (= 0.69.4) + - React-jsi (0.69.4): - boost (= 1.76.0) - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-jsi/Default (= 0.69.3) - - React-jsi/Default (0.69.3): + - React-jsi/Default (= 0.69.4) + - React-jsi/Default (0.69.4): - boost (= 1.76.0) - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-jsiexecutor (0.69.3): + - React-jsiexecutor (0.69.4): - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-perflogger (= 0.69.3) - - React-jsinspector (0.69.3) - - React-logger (0.69.3): + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-perflogger (= 0.69.4) + - React-jsinspector (0.69.4) + - React-logger (0.69.4): - glog - react-native-blur (4.2.0): - React-Core @@ -474,7 +474,7 @@ PODS: - React-Core - react-native-context-menu-view (1.5.4): - React - - react-native-image-picker (4.8.4): + - react-native-image-picker (4.8.5): - React-Core - react-native-language-detection (0.1.0): - React @@ -493,104 +493,106 @@ PODS: - ReactCommon/turbomodule/core - react-native-segmented-control (2.2.2): - React-Core - - React-perflogger (0.69.3) - - React-RCTActionSheet (0.69.3): - - React-Core/RCTActionSheetHeaders (= 0.69.3) - - React-RCTAnimation (0.69.3): + - React-perflogger (0.69.4) + - React-RCTActionSheet (0.69.4): + - React-Core/RCTActionSheetHeaders (= 0.69.4) + - React-RCTAnimation (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.3) - - React-Codegen (= 0.69.3) - - React-Core/RCTAnimationHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-RCTBlob (0.69.3): + - RCTTypeSafety (= 0.69.4) + - React-Codegen (= 0.69.4) + - React-Core/RCTAnimationHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-RCTBlob (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - React-Codegen (= 0.69.3) - - React-Core/RCTBlobHeaders (= 0.69.3) - - React-Core/RCTWebSocket (= 0.69.3) - - React-jsi (= 0.69.3) - - React-RCTNetwork (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-RCTImage (0.69.3): + - React-Codegen (= 0.69.4) + - React-Core/RCTBlobHeaders (= 0.69.4) + - React-Core/RCTWebSocket (= 0.69.4) + - React-jsi (= 0.69.4) + - React-RCTNetwork (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-RCTImage (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.3) - - React-Codegen (= 0.69.3) - - React-Core/RCTImageHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - React-RCTNetwork (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-RCTLinking (0.69.3): - - React-Codegen (= 0.69.3) - - React-Core/RCTLinkingHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-RCTNetwork (0.69.3): + - RCTTypeSafety (= 0.69.4) + - React-Codegen (= 0.69.4) + - React-Core/RCTImageHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - React-RCTNetwork (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-RCTLinking (0.69.4): + - React-Codegen (= 0.69.4) + - React-Core/RCTLinkingHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-RCTNetwork (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.3) - - React-Codegen (= 0.69.3) - - React-Core/RCTNetworkHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-RCTSettings (0.69.3): + - RCTTypeSafety (= 0.69.4) + - React-Codegen (= 0.69.4) + - React-Core/RCTNetworkHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-RCTSettings (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.3) - - React-Codegen (= 0.69.3) - - React-Core/RCTSettingsHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-RCTText (0.69.3): - - React-Core/RCTTextHeaders (= 0.69.3) - - React-RCTVibration (0.69.3): + - RCTTypeSafety (= 0.69.4) + - React-Codegen (= 0.69.4) + - React-Core/RCTSettingsHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-RCTText (0.69.4): + - React-Core/RCTTextHeaders (= 0.69.4) + - React-RCTVibration (0.69.4): - RCT-Folly (= 2021.06.28.00-v2) - - React-Codegen (= 0.69.3) - - React-Core/RCTVibrationHeaders (= 0.69.3) - - React-jsi (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - React-runtimeexecutor (0.69.3): - - React-jsi (= 0.69.3) - - ReactCommon (0.69.3): - - React-logger (= 0.69.3) - - ReactCommon/react_debug_core (= 0.69.3) - - ReactCommon/turbomodule (= 0.69.3) - - ReactCommon/react_debug_core (0.69.3): - - React-logger (= 0.69.3) - - ReactCommon/turbomodule (0.69.3): + - React-Codegen (= 0.69.4) + - React-Core/RCTVibrationHeaders (= 0.69.4) + - React-jsi (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - React-runtimeexecutor (0.69.4): + - React-jsi (= 0.69.4) + - ReactCommon (0.69.4): + - React-logger (= 0.69.4) + - ReactCommon/react_debug_core (= 0.69.4) + - ReactCommon/turbomodule (= 0.69.4) + - ReactCommon/react_debug_core (0.69.4): + - React-logger (= 0.69.4) + - ReactCommon/turbomodule (0.69.4): - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-bridging (= 0.69.3) - - React-callinvoker (= 0.69.3) - - React-Core (= 0.69.3) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-logger (= 0.69.3) - - React-perflogger (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - ReactCommon/turbomodule/samples (= 0.69.3) - - ReactCommon/turbomodule/core (0.69.3): + - React-bridging (= 0.69.4) + - React-callinvoker (= 0.69.4) + - React-Core (= 0.69.4) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-logger (= 0.69.4) + - React-perflogger (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - ReactCommon/turbomodule/samples (= 0.69.4) + - ReactCommon/turbomodule/core (0.69.4): - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-bridging (= 0.69.3) - - React-callinvoker (= 0.69.3) - - React-Core (= 0.69.3) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-logger (= 0.69.3) - - React-perflogger (= 0.69.3) - - ReactCommon/turbomodule/samples (0.69.3): + - React-bridging (= 0.69.4) + - React-callinvoker (= 0.69.4) + - React-Core (= 0.69.4) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-logger (= 0.69.4) + - React-perflogger (= 0.69.4) + - ReactCommon/turbomodule/samples (0.69.4): - DoubleConversion - glog - RCT-Folly (= 2021.06.28.00-v2) - - React-bridging (= 0.69.3) - - React-callinvoker (= 0.69.3) - - React-Core (= 0.69.3) - - React-cxxreact (= 0.69.3) - - React-jsi (= 0.69.3) - - React-logger (= 0.69.3) - - React-perflogger (= 0.69.3) - - ReactCommon/turbomodule/core (= 0.69.3) - - RNCAsyncStorage (1.17.7): + - React-bridging (= 0.69.4) + - React-callinvoker (= 0.69.4) + - React-Core (= 0.69.4) + - React-cxxreact (= 0.69.4) + - React-jsi (= 0.69.4) + - React-logger (= 0.69.4) + - React-perflogger (= 0.69.4) + - ReactCommon/turbomodule/core (= 0.69.4) + - RNCAsyncStorage (1.17.8): + - React-Core + - RNCClipboard (1.10.0): - React-Core - RNFastImage (8.5.11): - React-Core @@ -750,6 +752,7 @@ DEPENDENCIES: - React-runtimeexecutor (from `../node_modules/react-native/ReactCommon/runtimeexecutor`) - ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`) - "RNCAsyncStorage (from `../node_modules/@react-native-async-storage/async-storage`)" + - "RNCClipboard (from `../node_modules/@react-native-clipboard/clipboard`)" - RNFastImage (from `../node_modules/react-native-fast-image`) - RNGestureHandler (from `../node_modules/react-native-gesture-handler`) - RNReanimated (from `../node_modules/react-native-reanimated`) @@ -942,6 +945,8 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/ReactCommon" RNCAsyncStorage: :path: "../node_modules/@react-native-async-storage/async-storage" + RNCClipboard: + :path: "../node_modules/@react-native-clipboard/clipboard" RNFastImage: :path: "../node_modules/react-native-fast-image" RNGestureHandler: @@ -993,8 +998,8 @@ SPEC CHECKSUMS: EXUpdates: 0d639074a69862e121706c0d4203a700ecfcc22d EXUpdatesInterface: 2bbc11815dfa2ec3fc02e5534c7592c6b42b5327 EXVideoThumbnails: 486533e1a66c9859f9b9e3b2e1f9f0b275515b48 - FBLazyVector: 1d83d91816fa605d16227a83f1b2e71c8df09d22 - FBReactNativeSpec: 626e35e73f83c637ff166f906d584f4c6750c251 + FBLazyVector: c71b8c429a8af2aff1013934a7152e9d9d0c937d + FBReactNativeSpec: cb0df4f0084281b394f76bb9b4d1d9540f35963f Firebase: 7e8fe528c161b9271d365217a74c16aaf834578e FirebaseAnalytics: 2fc3876e2eb347673ad2f35e249ae7b15d6c88f5 FirebaseCore: b84a44ee7ba999e0f9f76d198a9c7f60a797b848 @@ -1021,44 +1026,45 @@ SPEC CHECKSUMS: OpenSSL-Universal: ebc357f1e6bc71fa463ccb2fe676756aff50e88c PromisesObjC: ab77feca74fa2823e7af4249b8326368e61014cb RCT-Folly: b9d9fe1fc70114b751c076104e52f3b1b5e5a95a - RCTRequired: 66822c147facf02f7774af99825e0a31e39df42e - RCTTypeSafety: 309306c4e711b14a83c55c2816a6cc490ec19827 - React: a779632422a918b26db4f1b57225a41c14d20525 - React-bridging: 96055aa45f0417898d7833e251f4ae79d28acef7 - React-callinvoker: 02df4d620df286381ff3f99180fb24feceaf01cc - React-Codegen: 06613a5e753c3af2dca0d6e7dd02944a3d77c3f6 - React-Core: 638d54d64048aa635e7c583fb0d8425206f446b4 - React-CoreModules: f706ec2a1939387517cadc6ce0d2ef0f20fccb53 - React-cxxreact: ec183b7f6fec01e7167f38c1c64a03f68dca7fb2 - React-hermes: a97962948f74aaefffd4fe00bdafafbc245b08af - React-jsi: ed7dc77f5193dca9c73cec90bfec409e7ddfe401 - React-jsiexecutor: 1842ca163b160aeb224d2c65b2a60c393b273c67 - React-jsinspector: bb2605f98aada5d81f3494690da3ef3b4ff3b716 - React-logger: 23a50ef4c18bf9adbb51e2c979318e6b3a2e44a1 + RCTRequired: bd9d2ab0fda10171fcbcf9ba61a7df4dc15a28f4 + RCTTypeSafety: e44e139bf6ec8042db396201834fc2372f6a21cd + React: 482cd1ba23c471be1aed3800180be2427418d7be + React-bridging: c2ea4fed6fe4ed27c12fd71e88b5d5d3da107fde + React-callinvoker: d4d1f98163fb5e35545e910415ef6c04796bb188 + React-Codegen: ff35fb9c7f6ec2ed34fb6de2e1099d88dfb25f2f + React-Core: 4d3443a45b67c71d74d7243ddde9569d1e4f4fad + React-CoreModules: 70be25399366b5632ab18ecf6fe444a8165a7bea + React-cxxreact: 822d3794fc0bf206f4691592f90e086dd4f92228 + React-hermes: 7f67b8363288258c3b0cd4aef5975cb7f0b9549a + React-jsi: ffa51cbc9a78cc156cf61f79ed52ecb76dc6013b + React-jsiexecutor: a27badbbdbc0ff781813370736a2d1c7261181d4 + React-jsinspector: 8a3d3f5dcd23a91e8c80b1bf0e96902cd1dca999 + React-logger: 1088859f145b8f6dd0d3ed051a647ef0e3e80fad react-native-blur: 3e9c8e8e9f7d17fa1b94e1a0ae9fd816675f5382 react-native-blurhash: add4df9a937b4e021a24bc67a0714f13e0bd40b7 react-native-cameraroll: 2957f2bce63ae896a848fbe0d5352c1bd4d20866 react-native-context-menu-view: b0beca02aad4bd9f9d7d932bf437e0a03baa69ef - react-native-image-picker: cffb727cf2f59bd5c0408e30b3dbe0b935f88835 + react-native-image-picker: cd420f97f6ed6ff74fc4686d27dbcfdbd051db91 react-native-language-detection: 0e43195ad014974f1b7a31b64820eff34a243f2d react-native-netinfo: 129bd99f607a2dc5bb096168f3e5c150fd1f1c95 react-native-pager-view: da490aa1f902c9a5aeecf0909cc975ad0e92e53e react-native-paste-input: 3037f113267c367e863790bcfd57cdb3ace3cad6 react-native-safe-area-context: 6c12e3859b6f27b25de4fee8201cfb858432d8de react-native-segmented-control: 65df6cd0619b780b3843d574a72d4c7cec396097 - React-perflogger: 39d2ba8cbcac54d1bb1d9a980dab348e96aef467 - React-RCTActionSheet: b1ad907a2c8f8e4d037148ca507b7f2d6ab1c66d - React-RCTAnimation: 914a9ba46fb6e7376f7709c7ce825d53b47ca2ee - React-RCTBlob: de62fd5edc5c36951f0b113bf252eb43b7131f79 - React-RCTImage: aa0749a8d748b34942c7e71ac5d9f42be8b70cf3 - React-RCTLinking: 595a9f8fbf4d6634bff28d1175b3523b61466612 - React-RCTNetwork: 0559fd0fccb01f89c638baa43c8d185dc8008626 - React-RCTSettings: 8e492a25a62f1ef6323f82ce652ae87fa59c82ca - React-RCTText: 17457cde6ef8832ba43c886baebb6627c5d7ed18 - React-RCTVibration: dd8099eb46e9cee4692934bc8cbe5e9a4f5e8d31 - React-runtimeexecutor: 607eb048e22a16388c908ee1f6644200e8d1e19b - ReactCommon: af7636436b382db7cde4583bbd642f0978e6e3ed - RNCAsyncStorage: d81ee5c3db1060afd49ea7045ad460eff82d2b7d + React-perflogger: cb386fd44c97ec7f8199c04c12b22066b0f2e1e0 + React-RCTActionSheet: f803a85e46cf5b4066c2ac5e122447f918e9c6e5 + React-RCTAnimation: 19c80fa950ccce7f4db76a2a7f2cf79baae07fc7 + React-RCTBlob: f36ab97e2d515c36df14a1571e50056be80413d5 + React-RCTImage: 2c8f0a329a116248e82f8972ffe806e47c6d1cfa + React-RCTLinking: 670f0223075aff33be3b89714f1da4f5343fc4af + React-RCTNetwork: 09385b73f4ff1f46bd5d749540fb33f69a7e5908 + React-RCTSettings: 33b12d3ac7a1f2eba069ec7bd1b84345263b3bbe + React-RCTText: a1a3ea902403bd9ae4cf6f7960551dc1d25711b5 + React-RCTVibration: 9adb4a3cbb598d1bbd46a05256f445e4b8c70603 + React-runtimeexecutor: 61ee22a8cdf8b6bb2a7fb7b4ba2cc763e5285196 + ReactCommon: 8f67bd7e0a6afade0f20718f859dc8c2275f2e83 + RNCAsyncStorage: 7cbd0d823dbb0e415d40a7e77fea2292483c8bdb + RNCClipboard: f1736c75ab85b627a4d57587edb4b60999c4dd80 RNFastImage: 8e9b5b9e6df94d2e359c0a75a4745ad1311506fd RNGestureHandler: bad495418bcbd3ab47017a38d93d290ebd406f50 RNReanimated: 2cf7451318bb9cc430abeec8d67693f9cf4e039c @@ -1071,7 +1077,7 @@ SPEC CHECKSUMS: Sentry: 30b51086ca9aac23337880152e95538f7e177f7f SocketRocket: fccef3f9c5cedea1353a9ef6ada904fde10d6608 Swime: d7b2c277503b6cea317774aedc2dce05613f8b0b - Yoga: 44c64131616253fa83366295acdbce3d14926041 + Yoga: ff994563b2fd98c982ca58e8cd9db2cdaf4dda74 YogaKit: f782866e155069a2cca2517aafea43200b01fd5a PODFILE CHECKSUM: a2f2cbb9af4b081ba2a1ca88de325713cfa64ec5 diff --git a/package.json b/package.json index c3b8f46f..98983775 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,7 @@ "@mattermost/react-native-paste-input": "^0.5.0", "@neverdull-agency/expo-unlimited-secure-store": "^1.0.10", "@react-native-async-storage/async-storage": "^1.17.8", + "@react-native-clipboard/clipboard": "^1.10.0", "@react-native-community/blur": "^4.2.0", "@react-native-community/cameraroll": "^4.1.2", "@react-native-community/netinfo": "^9.3.0", diff --git a/src/components/ContextMenu/share.ts b/src/components/ContextMenu/share.ts index 7d797847..58df0bbf 100644 --- a/src/components/ContextMenu/share.ts +++ b/src/components/ContextMenu/share.ts @@ -1,15 +1,23 @@ import analytics from '@components/analytics' +import { displayMessage } from '@components/Message' +import Clipboard from '@react-native-clipboard/clipboard' +import { useTheme } from '@utils/styles/ThemeManager' import { useTranslation } from 'react-i18next' import { Platform, Share } from 'react-native' import { ContextMenuAction } from 'react-native-context-menu-view' export interface Props { + copiableContent?: React.MutableRefObject<{ + content?: string | undefined + complete: boolean + }> actions: ContextMenuAction[] type: 'status' | 'account' url: string } -const contextMenuShare = ({ actions, type, url }: Props) => { +const contextMenuShare = ({ copiableContent, actions, type, url }: Props) => { + const { theme } = useTheme() const { t } = useTranslation('componentContextMenu') actions.push({ @@ -17,8 +25,24 @@ const contextMenuShare = ({ actions, type, url }: Props) => { title: t(`share.${type}.action`), systemIcon: 'square.and.arrow.up' }) + Platform.OS !== 'android' && + actions.push({ + id: 'copy', + title: t(`copy.action`), + systemIcon: 'doc.on.doc', + disabled: !copiableContent?.current.content?.length + }) return (index: number) => { + if (actions[index].id === 'copy') { + analytics('timeline_shared_headeractions_copy_press') + Clipboard.setString(copiableContent?.current.content || '') + displayMessage({ + theme, + type: 'success', + message: t(`copy.succeed`) + }) + } if (actions[index].id === 'share') { analytics('timeline_shared_headeractions_share_press') switch (Platform.OS) { diff --git a/src/components/Timeline/Default.tsx b/src/components/Timeline/Default.tsx index d72e427c..c2cd3427 100644 --- a/src/components/Timeline/Default.tsx +++ b/src/components/Timeline/Default.tsx @@ -15,7 +15,7 @@ import { getInstanceAccount } from '@utils/slices/instancesSlice' import { StyleConstants } from '@utils/styles/constants' import { useTheme } from '@utils/styles/ThemeManager' import { uniqBy } from 'lodash' -import React, { useCallback } from 'react' +import React, { useCallback, useEffect, useRef } from 'react' import { Pressable, View } from 'react-native' import { useSelector } from 'react-redux' import TimelineContextMenu from './Shared/ContextMenu' @@ -53,10 +53,15 @@ const TimelineDefault: React.FC = ({ const ownAccount = actualStatus.account?.id === instanceAccount?.id + const copiableContent = useRef<{ content: string; complete: boolean }>({ + content: '', + complete: false + }) + if ( !highlighted && queryKey && - shouldFilter({ status: actualStatus, queryKey }) + shouldFilter({ copiableContent, status: actualStatus, queryKey }) ) { return } @@ -75,10 +80,10 @@ const TimelineDefault: React.FC = ({ return ( { + const copiableContent = useRef<{ content: string; complete: boolean }>({ + content: '', + complete: false + }) + if ( notification.status && - shouldFilter({ status: notification.status, queryKey }) + shouldFilter({ copiableContent, status: notification.status, queryKey }) ) { return } @@ -60,9 +65,9 @@ const TimelineNotifications = React.memo( return ( ) : ( @@ -66,7 +64,6 @@ const TimelineContent = React.memo( tags={status.tags} numberOfLines={highlighted ? 999 : numberOfLines} disableDetails={disableDetails} - selectable={highlighted} /> )} diff --git a/src/components/Timeline/Shared/ContextMenu.tsx b/src/components/Timeline/Shared/ContextMenu.tsx index c38272f1..911ad328 100644 --- a/src/components/Timeline/Shared/ContextMenu.tsx +++ b/src/components/Timeline/Shared/ContextMenu.tsx @@ -12,23 +12,26 @@ import ContextMenu, { } from 'react-native-context-menu-view' export interface Props { + copiableContent: React.MutableRefObject<{ + content: string + complete: boolean + }> status?: Mastodon.Status queryKey?: QueryKeyTimeline rootQueryKey?: QueryKeyTimeline - disabled?: boolean // Allowing toot to be copied when highlighted } export const ContextMenuContext = createContext([]) const TimelineContextMenu: React.FC = ({ children, + copiableContent, status, queryKey, rootQueryKey, - disabled, ...props }) => { - if (!status || !queryKey || disabled || Platform.OS === 'android') { + if (!status || !queryKey || Platform.OS === 'android') { return <>{children} } @@ -37,6 +40,7 @@ const TimelineContextMenu: React.FC = ({ const shareOnPress = status.visibility !== 'direct' ? contextMenuShare({ + copiableContent, actions, type: 'status', url: status.url || status.uri diff --git a/src/components/Timeline/Shared/Filtered.tsx b/src/components/Timeline/Shared/Filtered.tsx index f6e10994..1dd5f4ae 100644 --- a/src/components/Timeline/Shared/Filtered.tsx +++ b/src/components/Timeline/Shared/Filtered.tsx @@ -34,9 +34,14 @@ const TimelineFiltered = React.memo( ) export const shouldFilter = ({ + copiableContent, status, queryKey }: { + copiableContent: React.MutableRefObject<{ + content: string + complete: boolean + }> status: Mastodon.Status queryKey: QueryKeyTimeline }) => { @@ -48,6 +53,11 @@ export const shouldFilter = ({ if (!ownAccount) { const parser = new htmlparser2.Parser({ ontext: (text: string) => { + if (!copiableContent.current.complete) { + copiableContent.current.content = + copiableContent.current.content + text + } + const checkFilter = (filter: Mastodon.Filter) => { const escapedPhrase = filter.phrase.replace( /[.*+?^${}()|[\]\\]/g, @@ -103,6 +113,7 @@ export const shouldFilter = ({ status.spoiler_text && parser.write(status.spoiler_text) parser.write(status.content) parser.end() + copiableContent.current.complete = true } return shouldFilter diff --git a/src/components/Timeline/Shared/HeaderDefault.ios.tsx b/src/components/Timeline/Shared/HeaderDefault.ios.tsx index d18668d2..80a1c1bb 100644 --- a/src/components/Timeline/Shared/HeaderDefault.ios.tsx +++ b/src/components/Timeline/Shared/HeaderDefault.ios.tsx @@ -4,7 +4,7 @@ import { StyleConstants } from '@utils/styles/constants' import { useTheme } from '@utils/styles/ThemeManager' import React, { useContext } from 'react' import { useTranslation } from 'react-i18next' -import { Platform, Pressable, View } from 'react-native' +import { Pressable, View } from 'react-native' import ContextMenu from 'react-native-context-menu-view' import { ContextMenuContext } from './ContextMenu' import HeaderSharedAccount from './HeaderShared/Account' @@ -48,7 +48,7 @@ const TimelineHeaderDefault = ({ queryKey, status, highlighted }: Props) => { - {queryKey && !highlighted ? ( + {queryKey ? ( {data && data.error === undefined ? data.text.map((d, i) => ( - + )) : null} diff --git a/src/i18n/en/components/contextMenu.json b/src/i18n/en/components/contextMenu.json index cd410020..d7ba0c11 100644 --- a/src/i18n/en/components/contextMenu.json +++ b/src/i18n/en/components/contextMenu.json @@ -14,6 +14,10 @@ "action": "Report user" } }, + "copy": { + "action": "Copy toot", + "succeed": "Copied" + }, "instance": { "title": "Instance action", "block": { diff --git a/yarn.lock b/yarn.lock index 98064f50..d2d58568 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1710,6 +1710,11 @@ dependencies: merge-options "^3.0.4" +"@react-native-clipboard/clipboard@^1.10.0": + version "1.10.0" + resolved "https://registry.yarnpkg.com/@react-native-clipboard/clipboard/-/clipboard-1.10.0.tgz#605e784ed5435059c9b5db52b2d112f9fd09c409" + integrity sha512-1L+I0vmeUJgMi8MnNsqI00391/RFLkmmxj9qAuOS2madpvce/oNqJb8Pwk2Fc/uxIJSxOckTpq+dQwyPU6s+7w== + "@react-native-community/blur@^4.2.0": version "4.2.0" resolved "https://registry.yarnpkg.com/@react-native-community/blur/-/blur-4.2.0.tgz#f100d0ba220ecfed26be3c0ad2ceffa5eee17533"