@oxyhq/services 6.9.46 → 6.10.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (812) hide show
  1. package/lib/commonjs/index.js +36 -13
  2. package/lib/commonjs/index.js.map +1 -1
  3. package/lib/commonjs/ui/client.js +0 -20
  4. package/lib/commonjs/ui/client.js.map +1 -1
  5. package/lib/commonjs/ui/components/ActingAsBanner.js +0 -4
  6. package/lib/commonjs/ui/components/ActingAsBanner.js.map +1 -1
  7. package/lib/commonjs/ui/components/ActivityIndicator.js +1 -1
  8. package/lib/commonjs/ui/components/ActivityIndicator.js.map +1 -1
  9. package/lib/commonjs/ui/components/Avatar.js +0 -2
  10. package/lib/commonjs/ui/components/Avatar.js.map +1 -1
  11. package/lib/commonjs/ui/components/BottomSheet.js +33 -398
  12. package/lib/commonjs/ui/components/BottomSheet.js.map +1 -1
  13. package/lib/commonjs/ui/components/BottomSheetRouter.js +8 -0
  14. package/lib/commonjs/ui/components/BottomSheetRouter.js.map +1 -1
  15. package/lib/commonjs/ui/components/FollowButton.js +3 -5
  16. package/lib/commonjs/ui/components/FollowButton.js.map +1 -1
  17. package/lib/commonjs/ui/components/Header.js +0 -5
  18. package/lib/commonjs/ui/components/Header.js.map +1 -1
  19. package/lib/commonjs/ui/components/Icon.js +6 -7
  20. package/lib/commonjs/ui/components/Icon.js.map +1 -1
  21. package/lib/commonjs/ui/components/IconButton/IconButton.js +1 -5
  22. package/lib/commonjs/ui/components/IconButton/IconButton.js.map +1 -1
  23. package/lib/commonjs/ui/components/OxyPayButton.js +0 -2
  24. package/lib/commonjs/ui/components/OxyPayButton.js.map +1 -1
  25. package/lib/commonjs/ui/components/OxyProvider.js +100 -37
  26. package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
  27. package/lib/commonjs/ui/components/OxySignInButton.js +23 -9
  28. package/lib/commonjs/ui/components/OxySignInButton.js.map +1 -1
  29. package/lib/commonjs/ui/components/ProfileCard.js +11 -8
  30. package/lib/commonjs/ui/components/ProfileCard.js.map +1 -1
  31. package/lib/commonjs/ui/components/QuickActions.js +2 -2
  32. package/lib/commonjs/ui/components/QuickActions.js.map +1 -1
  33. package/lib/commonjs/ui/components/SignInModal.js +139 -284
  34. package/lib/commonjs/ui/components/SignInModal.js.map +1 -1
  35. package/lib/commonjs/ui/components/StepBasedScreen.js +0 -2
  36. package/lib/commonjs/ui/components/StepBasedScreen.js.map +1 -1
  37. package/lib/commonjs/ui/components/TextField.js +0 -1
  38. package/lib/commonjs/ui/components/TextField.js.map +1 -1
  39. package/lib/commonjs/ui/components/TouchableRipple/TouchableRipple.native.js +1 -1
  40. package/lib/commonjs/ui/components/TouchableRipple/TouchableRipple.native.js.map +1 -1
  41. package/lib/commonjs/ui/components/feedback/feedbackStyles.js +0 -2
  42. package/lib/commonjs/ui/components/feedback/feedbackStyles.js.map +1 -1
  43. package/lib/commonjs/ui/components/fileManagement/AnimatedButton.js +0 -2
  44. package/lib/commonjs/ui/components/fileManagement/AnimatedButton.js.map +1 -1
  45. package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js +80 -76
  46. package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
  47. package/lib/commonjs/ui/components/fileManagement/FileViewer.js +6 -8
  48. package/lib/commonjs/ui/components/fileManagement/FileViewer.js.map +1 -1
  49. package/lib/commonjs/ui/components/fileManagement/UploadPreview.js +18 -23
  50. package/lib/commonjs/ui/components/fileManagement/UploadPreview.js.map +1 -1
  51. package/lib/commonjs/ui/components/fileManagement/styles.js +213 -25
  52. package/lib/commonjs/ui/components/fileManagement/styles.js.map +1 -1
  53. package/lib/commonjs/ui/components/logo/LogoIcon.js +63 -0
  54. package/lib/commonjs/ui/components/logo/LogoIcon.js.map +1 -0
  55. package/lib/commonjs/ui/components/logo/LogoText.js +50 -0
  56. package/lib/commonjs/ui/components/logo/LogoText.js.map +1 -0
  57. package/lib/commonjs/ui/components/modals/DeleteAccountModal.js +54 -88
  58. package/lib/commonjs/ui/components/modals/DeleteAccountModal.js.map +1 -1
  59. package/lib/commonjs/ui/components/payment/PaymentDetailsStep.js +2 -2
  60. package/lib/commonjs/ui/components/payment/PaymentDetailsStep.js.map +1 -1
  61. package/lib/commonjs/ui/components/payment/PaymentReviewStep.js +1 -1
  62. package/lib/commonjs/ui/components/payment/PaymentReviewStep.js.map +1 -1
  63. package/lib/commonjs/ui/components/payment/PaymentSuccessStep.js +1 -1
  64. package/lib/commonjs/ui/components/payment/PaymentSuccessStep.js.map +1 -1
  65. package/lib/commonjs/ui/components/payment/paymentStyles.js +2 -10
  66. package/lib/commonjs/ui/components/payment/paymentStyles.js.map +1 -1
  67. package/lib/commonjs/ui/components/styles/overlay.js +7 -9
  68. package/lib/commonjs/ui/components/styles/overlay.js.map +1 -1
  69. package/lib/commonjs/ui/components/theming.js +0 -1
  70. package/lib/commonjs/ui/components/theming.js.map +1 -1
  71. package/lib/commonjs/ui/context/OxyContext.js +34 -21
  72. package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
  73. package/lib/commonjs/ui/context/hooks/useAuthOperations.js +1 -3
  74. package/lib/commonjs/ui/context/hooks/useAuthOperations.js.map +1 -1
  75. package/lib/commonjs/ui/hooks/index.js +32 -12
  76. package/lib/commonjs/ui/hooks/index.js.map +1 -1
  77. package/lib/commonjs/ui/hooks/mutations/mutationFactory.js +10 -5
  78. package/lib/commonjs/ui/hooks/mutations/mutationFactory.js.map +1 -1
  79. package/lib/commonjs/ui/hooks/mutations/mutationKeys.js +34 -0
  80. package/lib/commonjs/ui/hooks/mutations/mutationKeys.js.map +1 -0
  81. package/lib/commonjs/ui/hooks/mutations/useAccountMutations.js +235 -57
  82. package/lib/commonjs/ui/hooks/mutations/useAccountMutations.js.map +1 -1
  83. package/lib/commonjs/ui/hooks/mutations/useServicesMutations.js +17 -13
  84. package/lib/commonjs/ui/hooks/mutations/useServicesMutations.js.map +1 -1
  85. package/lib/commonjs/ui/hooks/queries/index.js +6 -0
  86. package/lib/commonjs/ui/hooks/queries/index.js.map +1 -1
  87. package/lib/commonjs/ui/hooks/queries/queryKeys.js +2 -1
  88. package/lib/commonjs/ui/hooks/queries/queryKeys.js.map +1 -1
  89. package/lib/commonjs/ui/hooks/queries/useAccountQueries.js +80 -3
  90. package/lib/commonjs/ui/hooks/queries/useAccountQueries.js.map +1 -1
  91. package/lib/commonjs/ui/hooks/queries/useSecurityQueries.js +36 -1
  92. package/lib/commonjs/ui/hooks/queries/useSecurityQueries.js.map +1 -1
  93. package/lib/commonjs/ui/hooks/queryClient.js +168 -70
  94. package/lib/commonjs/ui/hooks/queryClient.js.map +1 -1
  95. package/lib/commonjs/ui/hooks/useAsyncAction.js +7 -7
  96. package/lib/commonjs/ui/hooks/useAsyncAction.js.map +1 -1
  97. package/lib/commonjs/ui/hooks/useAuth.js +0 -8
  98. package/lib/commonjs/ui/hooks/useAuth.js.map +1 -1
  99. package/lib/commonjs/ui/hooks/useAvatarPicker.js +71 -20
  100. package/lib/commonjs/ui/hooks/useAvatarPicker.js.map +1 -1
  101. package/lib/commonjs/ui/hooks/useFileDownloadUrl.js +12 -41
  102. package/lib/commonjs/ui/hooks/useFileDownloadUrl.js.map +1 -1
  103. package/lib/commonjs/ui/hooks/useMutationStatus.js +86 -0
  104. package/lib/commonjs/ui/hooks/useMutationStatus.js.map +1 -0
  105. package/lib/commonjs/ui/hooks/useOnlineStatus.js +33 -0
  106. package/lib/commonjs/ui/hooks/useOnlineStatus.js.map +1 -0
  107. package/lib/commonjs/ui/hooks/useSessionSocket.js +101 -130
  108. package/lib/commonjs/ui/hooks/useSessionSocket.js.map +1 -1
  109. package/lib/commonjs/ui/hooks/useSettingToggle.js +4 -4
  110. package/lib/commonjs/ui/hooks/useSettingToggle.js.map +1 -1
  111. package/lib/commonjs/ui/index.js +1 -11
  112. package/lib/commonjs/ui/index.js.map +1 -1
  113. package/lib/commonjs/ui/navigation/routes.js +55 -3
  114. package/lib/commonjs/ui/navigation/routes.js.map +1 -1
  115. package/lib/commonjs/ui/screens/AccountCenterScreen.js +16 -16
  116. package/lib/commonjs/ui/screens/AccountCenterScreen.js.map +1 -1
  117. package/lib/commonjs/ui/screens/AccountOverviewScreen.js +108 -123
  118. package/lib/commonjs/ui/screens/AccountOverviewScreen.js.map +1 -1
  119. package/lib/commonjs/ui/screens/AccountSettingsScreen.js +20 -19
  120. package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
  121. package/lib/commonjs/ui/screens/AccountSwitcherScreen.js +204 -161
  122. package/lib/commonjs/ui/screens/AccountSwitcherScreen.js.map +1 -1
  123. package/lib/commonjs/ui/screens/AccountVerificationScreen.js +18 -18
  124. package/lib/commonjs/ui/screens/AccountVerificationScreen.js.map +1 -1
  125. package/lib/commonjs/ui/screens/AppInfoScreen.js +22 -23
  126. package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
  127. package/lib/commonjs/ui/screens/AvatarCropScreen.js +939 -0
  128. package/lib/commonjs/ui/screens/AvatarCropScreen.js.map +1 -0
  129. package/lib/commonjs/ui/screens/CreateManagedAccountScreen.js +13 -20
  130. package/lib/commonjs/ui/screens/CreateManagedAccountScreen.js.map +1 -1
  131. package/lib/commonjs/ui/screens/EditProfileFieldScreen.js +10 -13
  132. package/lib/commonjs/ui/screens/EditProfileFieldScreen.js.map +1 -1
  133. package/lib/commonjs/ui/screens/FAQScreen.js +4 -4
  134. package/lib/commonjs/ui/screens/FAQScreen.js.map +1 -1
  135. package/lib/commonjs/ui/screens/FeedbackScreen.js +17 -15
  136. package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
  137. package/lib/commonjs/ui/screens/FileManagementScreen.js +797 -159
  138. package/lib/commonjs/ui/screens/FileManagementScreen.js.map +1 -1
  139. package/lib/commonjs/ui/screens/HelpSupportScreen.js +8 -9
  140. package/lib/commonjs/ui/screens/HelpSupportScreen.js.map +1 -1
  141. package/lib/commonjs/ui/screens/HistoryViewScreen.js +29 -21
  142. package/lib/commonjs/ui/screens/HistoryViewScreen.js.map +1 -1
  143. package/lib/commonjs/ui/screens/LanguageSelectorScreen.js +3 -5
  144. package/lib/commonjs/ui/screens/LanguageSelectorScreen.js.map +1 -1
  145. package/lib/commonjs/ui/screens/LegalDocumentsScreen.js +5 -5
  146. package/lib/commonjs/ui/screens/LegalDocumentsScreen.js.map +1 -1
  147. package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +2 -2
  148. package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js +75 -73
  149. package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
  150. package/lib/commonjs/ui/screens/PrivacySettingsScreen.js +32 -21
  151. package/lib/commonjs/ui/screens/PrivacySettingsScreen.js.map +1 -1
  152. package/lib/commonjs/ui/screens/ProfileScreen.js +4 -3
  153. package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
  154. package/lib/commonjs/ui/screens/SavesCollectionsScreen.js +3 -3
  155. package/lib/commonjs/ui/screens/SavesCollectionsScreen.js.map +1 -1
  156. package/lib/commonjs/ui/screens/SessionManagementScreen.js +57 -56
  157. package/lib/commonjs/ui/screens/SessionManagementScreen.js.map +1 -1
  158. package/lib/commonjs/ui/screens/UserLinksScreen.js +2 -3
  159. package/lib/commonjs/ui/screens/UserLinksScreen.js.map +1 -1
  160. package/lib/commonjs/ui/screens/UserListScreen.js +39 -22
  161. package/lib/commonjs/ui/screens/UserListScreen.js.map +1 -1
  162. package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js +18 -21
  163. package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js.map +1 -1
  164. package/lib/commonjs/ui/screens/karma/KarmaAboutScreen.js +0 -3
  165. package/lib/commonjs/ui/screens/karma/KarmaAboutScreen.js.map +1 -1
  166. package/lib/commonjs/ui/screens/karma/KarmaCenterScreen.js +6 -10
  167. package/lib/commonjs/ui/screens/karma/KarmaCenterScreen.js.map +1 -1
  168. package/lib/commonjs/ui/screens/karma/KarmaFAQScreen.js +1 -1
  169. package/lib/commonjs/ui/screens/karma/KarmaFAQScreen.js.map +1 -1
  170. package/lib/commonjs/ui/screens/karma/KarmaLeaderboardScreen.js +6 -6
  171. package/lib/commonjs/ui/screens/karma/KarmaLeaderboardScreen.js.map +1 -1
  172. package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js +13 -19
  173. package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
  174. package/lib/commonjs/ui/screens/karma/KarmaRulesScreen.js +5 -5
  175. package/lib/commonjs/ui/screens/karma/KarmaRulesScreen.js.map +1 -1
  176. package/lib/commonjs/ui/server.js +0 -5
  177. package/lib/commonjs/ui/server.js.map +1 -1
  178. package/lib/commonjs/ui/styles/authStyles.js +0 -5
  179. package/lib/commonjs/ui/styles/authStyles.js.map +1 -1
  180. package/lib/commonjs/ui/styles/index.js +0 -11
  181. package/lib/commonjs/ui/styles/index.js.map +1 -1
  182. package/lib/commonjs/ui/styles/spacing.js +1 -42
  183. package/lib/commonjs/ui/styles/spacing.js.map +1 -1
  184. package/lib/commonjs/ui/styles/theme.js +0 -4
  185. package/lib/commonjs/ui/styles/theme.js.map +1 -1
  186. package/lib/commonjs/ui/utils/fileManagement.js +58 -39
  187. package/lib/commonjs/ui/utils/fileManagement.js.map +1 -1
  188. package/lib/commonjs/ui/utils/sessionHelpers.js +3 -1
  189. package/lib/commonjs/ui/utils/sessionHelpers.js.map +1 -1
  190. package/lib/commonjs/ui/utils/userUtils.js +33 -16
  191. package/lib/commonjs/ui/utils/userUtils.js.map +1 -1
  192. package/lib/module/index.js +9 -5
  193. package/lib/module/index.js.map +1 -1
  194. package/lib/module/ui/client.js +0 -6
  195. package/lib/module/ui/client.js.map +1 -1
  196. package/lib/module/ui/components/ActingAsBanner.js +0 -4
  197. package/lib/module/ui/components/ActingAsBanner.js.map +1 -1
  198. package/lib/module/ui/components/ActivityIndicator.js +1 -1
  199. package/lib/module/ui/components/ActivityIndicator.js.map +1 -1
  200. package/lib/module/ui/components/Avatar.js +0 -2
  201. package/lib/module/ui/components/Avatar.js.map +1 -1
  202. package/lib/module/ui/components/BottomSheet.js +35 -400
  203. package/lib/module/ui/components/BottomSheet.js.map +1 -1
  204. package/lib/module/ui/components/BottomSheetRouter.js +9 -1
  205. package/lib/module/ui/components/BottomSheetRouter.js.map +1 -1
  206. package/lib/module/ui/components/FollowButton.js +2 -4
  207. package/lib/module/ui/components/FollowButton.js.map +1 -1
  208. package/lib/module/ui/components/Header.js +0 -5
  209. package/lib/module/ui/components/Header.js.map +1 -1
  210. package/lib/module/ui/components/Icon.js +6 -7
  211. package/lib/module/ui/components/Icon.js.map +1 -1
  212. package/lib/module/ui/components/IconButton/IconButton.js +1 -5
  213. package/lib/module/ui/components/IconButton/IconButton.js.map +1 -1
  214. package/lib/module/ui/components/OxyPayButton.js +0 -2
  215. package/lib/module/ui/components/OxyPayButton.js.map +1 -1
  216. package/lib/module/ui/components/OxyProvider.js +103 -40
  217. package/lib/module/ui/components/OxyProvider.js.map +1 -1
  218. package/lib/module/ui/components/OxySignInButton.js +23 -9
  219. package/lib/module/ui/components/OxySignInButton.js.map +1 -1
  220. package/lib/module/ui/components/ProfileCard.js +11 -8
  221. package/lib/module/ui/components/ProfileCard.js.map +1 -1
  222. package/lib/module/ui/components/QuickActions.js +2 -2
  223. package/lib/module/ui/components/QuickActions.js.map +1 -1
  224. package/lib/module/ui/components/SignInModal.js +137 -284
  225. package/lib/module/ui/components/SignInModal.js.map +1 -1
  226. package/lib/module/ui/components/StepBasedScreen.js +0 -2
  227. package/lib/module/ui/components/StepBasedScreen.js.map +1 -1
  228. package/lib/module/ui/components/TextField.js +0 -1
  229. package/lib/module/ui/components/TextField.js.map +1 -1
  230. package/lib/module/ui/components/TouchableRipple/TouchableRipple.native.js +1 -1
  231. package/lib/module/ui/components/TouchableRipple/TouchableRipple.native.js.map +1 -1
  232. package/lib/module/ui/components/feedback/feedbackStyles.js +0 -2
  233. package/lib/module/ui/components/feedback/feedbackStyles.js.map +1 -1
  234. package/lib/module/ui/components/fileManagement/AnimatedButton.js +0 -1
  235. package/lib/module/ui/components/fileManagement/AnimatedButton.js.map +1 -1
  236. package/lib/module/ui/components/fileManagement/FileDetailsModal.js +80 -75
  237. package/lib/module/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
  238. package/lib/module/ui/components/fileManagement/FileViewer.js +6 -7
  239. package/lib/module/ui/components/fileManagement/FileViewer.js.map +1 -1
  240. package/lib/module/ui/components/fileManagement/UploadPreview.js +18 -22
  241. package/lib/module/ui/components/fileManagement/UploadPreview.js.map +1 -1
  242. package/lib/module/ui/components/fileManagement/styles.js +212 -24
  243. package/lib/module/ui/components/fileManagement/styles.js.map +1 -1
  244. package/lib/module/ui/components/logo/LogoIcon.js +56 -0
  245. package/lib/module/ui/components/logo/LogoIcon.js.map +1 -0
  246. package/lib/module/ui/components/logo/LogoText.js +43 -0
  247. package/lib/module/ui/components/logo/LogoText.js.map +1 -0
  248. package/lib/module/ui/components/modals/DeleteAccountModal.js +55 -88
  249. package/lib/module/ui/components/modals/DeleteAccountModal.js.map +1 -1
  250. package/lib/module/ui/components/payment/PaymentDetailsStep.js +1 -1
  251. package/lib/module/ui/components/payment/PaymentDetailsStep.js.map +1 -1
  252. package/lib/module/ui/components/payment/PaymentReviewStep.js +1 -1
  253. package/lib/module/ui/components/payment/PaymentReviewStep.js.map +1 -1
  254. package/lib/module/ui/components/payment/PaymentSuccessStep.js +1 -1
  255. package/lib/module/ui/components/payment/PaymentSuccessStep.js.map +1 -1
  256. package/lib/module/ui/components/payment/paymentStyles.js +2 -10
  257. package/lib/module/ui/components/payment/paymentStyles.js.map +1 -1
  258. package/lib/module/ui/components/styles/overlay.js +8 -8
  259. package/lib/module/ui/components/styles/overlay.js.map +1 -1
  260. package/lib/module/ui/components/theming.js +0 -1
  261. package/lib/module/ui/components/theming.js.map +1 -1
  262. package/lib/module/ui/context/OxyContext.js +32 -19
  263. package/lib/module/ui/context/OxyContext.js.map +1 -1
  264. package/lib/module/ui/context/hooks/useAuthOperations.js +1 -3
  265. package/lib/module/ui/context/hooks/useAuthOperations.js.map +1 -1
  266. package/lib/module/ui/hooks/index.js +5 -3
  267. package/lib/module/ui/hooks/index.js.map +1 -1
  268. package/lib/module/ui/hooks/mutations/mutationFactory.js +6 -1
  269. package/lib/module/ui/hooks/mutations/mutationFactory.js.map +1 -1
  270. package/lib/module/ui/hooks/mutations/mutationKeys.js +30 -0
  271. package/lib/module/ui/hooks/mutations/mutationKeys.js.map +1 -0
  272. package/lib/module/ui/hooks/mutations/useAccountMutations.js +231 -52
  273. package/lib/module/ui/hooks/mutations/useAccountMutations.js.map +1 -1
  274. package/lib/module/ui/hooks/mutations/useServicesMutations.js +9 -5
  275. package/lib/module/ui/hooks/mutations/useServicesMutations.js.map +1 -1
  276. package/lib/module/ui/hooks/queries/index.js +1 -1
  277. package/lib/module/ui/hooks/queries/index.js.map +1 -1
  278. package/lib/module/ui/hooks/queries/queryKeys.js +2 -1
  279. package/lib/module/ui/hooks/queries/queryKeys.js.map +1 -1
  280. package/lib/module/ui/hooks/queries/useAccountQueries.js +80 -3
  281. package/lib/module/ui/hooks/queries/useAccountQueries.js.map +1 -1
  282. package/lib/module/ui/hooks/queries/useSecurityQueries.js +35 -1
  283. package/lib/module/ui/hooks/queries/useSecurityQueries.js.map +1 -1
  284. package/lib/module/ui/hooks/queryClient.js +166 -68
  285. package/lib/module/ui/hooks/queryClient.js.map +1 -1
  286. package/lib/module/ui/hooks/useAsyncAction.js +3 -3
  287. package/lib/module/ui/hooks/useAsyncAction.js.map +1 -1
  288. package/lib/module/ui/hooks/useAuth.js +0 -3
  289. package/lib/module/ui/hooks/useAuth.js.map +1 -1
  290. package/lib/module/ui/hooks/useAvatarPicker.js +73 -22
  291. package/lib/module/ui/hooks/useAvatarPicker.js.map +1 -1
  292. package/lib/module/ui/hooks/useFileDownloadUrl.js +11 -39
  293. package/lib/module/ui/hooks/useFileDownloadUrl.js.map +1 -1
  294. package/lib/module/ui/hooks/useMutationStatus.js +82 -0
  295. package/lib/module/ui/hooks/useMutationStatus.js.map +1 -0
  296. package/lib/module/ui/hooks/useOnlineStatus.js +29 -0
  297. package/lib/module/ui/hooks/useOnlineStatus.js.map +1 -0
  298. package/lib/module/ui/hooks/useSessionSocket.js +101 -130
  299. package/lib/module/ui/hooks/useSessionSocket.js.map +1 -1
  300. package/lib/module/ui/hooks/useSettingToggle.js +1 -1
  301. package/lib/module/ui/hooks/useSettingToggle.js.map +1 -1
  302. package/lib/module/ui/index.js +1 -10
  303. package/lib/module/ui/index.js.map +1 -1
  304. package/lib/module/ui/navigation/routes.js +54 -2
  305. package/lib/module/ui/navigation/routes.js.map +1 -1
  306. package/lib/module/ui/screens/AccountCenterScreen.js +15 -14
  307. package/lib/module/ui/screens/AccountCenterScreen.js.map +1 -1
  308. package/lib/module/ui/screens/AccountOverviewScreen.js +96 -111
  309. package/lib/module/ui/screens/AccountOverviewScreen.js.map +1 -1
  310. package/lib/module/ui/screens/AccountSettingsScreen.js +19 -18
  311. package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
  312. package/lib/module/ui/screens/AccountSwitcherScreen.js +189 -145
  313. package/lib/module/ui/screens/AccountSwitcherScreen.js.map +1 -1
  314. package/lib/module/ui/screens/AccountVerificationScreen.js +15 -15
  315. package/lib/module/ui/screens/AccountVerificationScreen.js.map +1 -1
  316. package/lib/module/ui/screens/AppInfoScreen.js +14 -15
  317. package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
  318. package/lib/module/ui/screens/AvatarCropScreen.js +936 -0
  319. package/lib/module/ui/screens/AvatarCropScreen.js.map +1 -0
  320. package/lib/module/ui/screens/CreateManagedAccountScreen.js +11 -18
  321. package/lib/module/ui/screens/CreateManagedAccountScreen.js.map +1 -1
  322. package/lib/module/ui/screens/EditProfileFieldScreen.js +8 -11
  323. package/lib/module/ui/screens/EditProfileFieldScreen.js.map +1 -1
  324. package/lib/module/ui/screens/FAQScreen.js +3 -3
  325. package/lib/module/ui/screens/FAQScreen.js.map +1 -1
  326. package/lib/module/ui/screens/FeedbackScreen.js +14 -12
  327. package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
  328. package/lib/module/ui/screens/FileManagementScreen.js +764 -125
  329. package/lib/module/ui/screens/FileManagementScreen.js.map +1 -1
  330. package/lib/module/ui/screens/HelpSupportScreen.js +2 -3
  331. package/lib/module/ui/screens/HelpSupportScreen.js.map +1 -1
  332. package/lib/module/ui/screens/HistoryViewScreen.js +26 -17
  333. package/lib/module/ui/screens/HistoryViewScreen.js.map +1 -1
  334. package/lib/module/ui/screens/LanguageSelectorScreen.js +1 -3
  335. package/lib/module/ui/screens/LanguageSelectorScreen.js.map +1 -1
  336. package/lib/module/ui/screens/LegalDocumentsScreen.js +3 -3
  337. package/lib/module/ui/screens/LegalDocumentsScreen.js.map +1 -1
  338. package/lib/module/ui/screens/PaymentGatewayScreen.js +2 -2
  339. package/lib/module/ui/screens/PremiumSubscriptionScreen.js +60 -57
  340. package/lib/module/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
  341. package/lib/module/ui/screens/PrivacySettingsScreen.js +27 -16
  342. package/lib/module/ui/screens/PrivacySettingsScreen.js.map +1 -1
  343. package/lib/module/ui/screens/ProfileScreen.js +4 -3
  344. package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
  345. package/lib/module/ui/screens/SavesCollectionsScreen.js +2 -2
  346. package/lib/module/ui/screens/SavesCollectionsScreen.js.map +1 -1
  347. package/lib/module/ui/screens/SessionManagementScreen.js +48 -47
  348. package/lib/module/ui/screens/SessionManagementScreen.js.map +1 -1
  349. package/lib/module/ui/screens/UserLinksScreen.js +2 -3
  350. package/lib/module/ui/screens/UserLinksScreen.js.map +1 -1
  351. package/lib/module/ui/screens/UserListScreen.js +40 -23
  352. package/lib/module/ui/screens/UserListScreen.js.map +1 -1
  353. package/lib/module/ui/screens/WelcomeNewUserScreen.js +16 -19
  354. package/lib/module/ui/screens/WelcomeNewUserScreen.js.map +1 -1
  355. package/lib/module/ui/screens/karma/KarmaAboutScreen.js +0 -3
  356. package/lib/module/ui/screens/karma/KarmaAboutScreen.js.map +1 -1
  357. package/lib/module/ui/screens/karma/KarmaCenterScreen.js +6 -10
  358. package/lib/module/ui/screens/karma/KarmaCenterScreen.js.map +1 -1
  359. package/lib/module/ui/screens/karma/KarmaFAQScreen.js +1 -1
  360. package/lib/module/ui/screens/karma/KarmaFAQScreen.js.map +1 -1
  361. package/lib/module/ui/screens/karma/KarmaLeaderboardScreen.js +6 -6
  362. package/lib/module/ui/screens/karma/KarmaLeaderboardScreen.js.map +1 -1
  363. package/lib/module/ui/screens/karma/KarmaRewardsScreen.js +13 -19
  364. package/lib/module/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
  365. package/lib/module/ui/screens/karma/KarmaRulesScreen.js +5 -5
  366. package/lib/module/ui/screens/karma/KarmaRulesScreen.js.map +1 -1
  367. package/lib/module/ui/server.js +0 -4
  368. package/lib/module/ui/server.js.map +1 -1
  369. package/lib/module/ui/styles/authStyles.js +0 -5
  370. package/lib/module/ui/styles/authStyles.js.map +1 -1
  371. package/lib/module/ui/styles/index.js +0 -1
  372. package/lib/module/ui/styles/index.js.map +1 -1
  373. package/lib/module/ui/styles/spacing.js +0 -42
  374. package/lib/module/ui/styles/spacing.js.map +1 -1
  375. package/lib/module/ui/styles/theme.js +0 -4
  376. package/lib/module/ui/styles/theme.js.map +1 -1
  377. package/lib/module/ui/utils/fileManagement.js +54 -36
  378. package/lib/module/ui/utils/fileManagement.js.map +1 -1
  379. package/lib/module/ui/utils/sessionHelpers.js +3 -1
  380. package/lib/module/ui/utils/sessionHelpers.js.map +1 -1
  381. package/lib/module/ui/utils/userUtils.js +34 -16
  382. package/lib/module/ui/utils/userUtils.js.map +1 -1
  383. package/lib/typescript/commonjs/index.d.ts +7 -3
  384. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  385. package/lib/typescript/commonjs/ui/client.d.ts +0 -2
  386. package/lib/typescript/commonjs/ui/client.d.ts.map +1 -1
  387. package/lib/typescript/commonjs/ui/components/ActingAsBanner.d.ts.map +1 -1
  388. package/lib/typescript/commonjs/ui/components/Avatar.d.ts.map +1 -1
  389. package/lib/typescript/commonjs/ui/components/BottomSheet.d.ts +27 -27
  390. package/lib/typescript/commonjs/ui/components/BottomSheet.d.ts.map +1 -1
  391. package/lib/typescript/commonjs/ui/components/BottomSheetRouter.d.ts.map +1 -1
  392. package/lib/typescript/commonjs/ui/components/FollowButton.d.ts.map +1 -1
  393. package/lib/typescript/commonjs/ui/components/Header.d.ts.map +1 -1
  394. package/lib/typescript/commonjs/ui/components/Icon.d.ts +3 -2
  395. package/lib/typescript/commonjs/ui/components/Icon.d.ts.map +1 -1
  396. package/lib/typescript/commonjs/ui/components/IconButton/IconButton.d.ts.map +1 -1
  397. package/lib/typescript/commonjs/ui/components/OxyPayButton.d.ts.map +1 -1
  398. package/lib/typescript/commonjs/ui/components/OxyProvider.d.ts.map +1 -1
  399. package/lib/typescript/commonjs/ui/components/OxySignInButton.d.ts.map +1 -1
  400. package/lib/typescript/commonjs/ui/components/ProfileCard.d.ts +4 -1
  401. package/lib/typescript/commonjs/ui/components/ProfileCard.d.ts.map +1 -1
  402. package/lib/typescript/commonjs/ui/components/SignInModal.d.ts.map +1 -1
  403. package/lib/typescript/commonjs/ui/components/StepBasedScreen.d.ts.map +1 -1
  404. package/lib/typescript/commonjs/ui/components/TextField/Addons/Outline.d.ts +2 -2
  405. package/lib/typescript/commonjs/ui/components/TextField/helpers.d.ts +2 -2
  406. package/lib/typescript/commonjs/ui/components/TextField/types.d.ts +0 -1
  407. package/lib/typescript/commonjs/ui/components/TextField/types.d.ts.map +1 -1
  408. package/lib/typescript/commonjs/ui/components/TextField.d.ts +1 -1
  409. package/lib/typescript/commonjs/ui/components/TextField.d.ts.map +1 -1
  410. package/lib/typescript/commonjs/ui/components/feedback/feedbackStyles.d.ts +0 -1
  411. package/lib/typescript/commonjs/ui/components/feedback/feedbackStyles.d.ts.map +1 -1
  412. package/lib/typescript/commonjs/ui/components/fileManagement/AnimatedButton.d.ts.map +1 -1
  413. package/lib/typescript/commonjs/ui/components/fileManagement/FileDetailsModal.d.ts +1 -1
  414. package/lib/typescript/commonjs/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -1
  415. package/lib/typescript/commonjs/ui/components/fileManagement/FileViewer.d.ts +0 -2
  416. package/lib/typescript/commonjs/ui/components/fileManagement/FileViewer.d.ts.map +1 -1
  417. package/lib/typescript/commonjs/ui/components/fileManagement/UploadPreview.d.ts +3 -2
  418. package/lib/typescript/commonjs/ui/components/fileManagement/UploadPreview.d.ts.map +1 -1
  419. package/lib/typescript/commonjs/ui/components/fileManagement/styles.d.ts +200 -17
  420. package/lib/typescript/commonjs/ui/components/fileManagement/styles.d.ts.map +1 -1
  421. package/lib/typescript/commonjs/ui/components/logo/LogoIcon.d.ts +22 -0
  422. package/lib/typescript/commonjs/ui/components/logo/LogoIcon.d.ts.map +1 -0
  423. package/lib/typescript/commonjs/ui/components/logo/LogoText.d.ts +22 -0
  424. package/lib/typescript/commonjs/ui/components/logo/LogoText.d.ts.map +1 -0
  425. package/lib/typescript/commonjs/ui/components/modals/DeleteAccountModal.d.ts +2 -2
  426. package/lib/typescript/commonjs/ui/components/modals/DeleteAccountModal.d.ts.map +1 -1
  427. package/lib/typescript/commonjs/ui/components/payment/paymentStyles.d.ts +0 -7
  428. package/lib/typescript/commonjs/ui/components/payment/paymentStyles.d.ts.map +1 -1
  429. package/lib/typescript/commonjs/ui/components/styles/overlay.d.ts +3 -1
  430. package/lib/typescript/commonjs/ui/components/styles/overlay.d.ts.map +1 -1
  431. package/lib/typescript/commonjs/ui/components/theming.d.ts.map +1 -1
  432. package/lib/typescript/commonjs/ui/components/types.d.ts.map +1 -1
  433. package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
  434. package/lib/typescript/commonjs/ui/context/hooks/useAuthOperations.d.ts.map +1 -1
  435. package/lib/typescript/commonjs/ui/hooks/index.d.ts +5 -3
  436. package/lib/typescript/commonjs/ui/hooks/index.d.ts.map +1 -1
  437. package/lib/typescript/commonjs/ui/hooks/mutations/mutationFactory.d.ts +11 -0
  438. package/lib/typescript/commonjs/ui/hooks/mutations/mutationFactory.d.ts.map +1 -1
  439. package/lib/typescript/commonjs/ui/hooks/mutations/mutationKeys.d.ts +25 -0
  440. package/lib/typescript/commonjs/ui/hooks/mutations/mutationKeys.d.ts.map +1 -0
  441. package/lib/typescript/commonjs/ui/hooks/mutations/useAccountMutations.d.ts +161 -9
  442. package/lib/typescript/commonjs/ui/hooks/mutations/useAccountMutations.d.ts.map +1 -1
  443. package/lib/typescript/commonjs/ui/hooks/mutations/useServicesMutations.d.ts.map +1 -1
  444. package/lib/typescript/commonjs/ui/hooks/queries/index.d.ts +1 -1
  445. package/lib/typescript/commonjs/ui/hooks/queries/index.d.ts.map +1 -1
  446. package/lib/typescript/commonjs/ui/hooks/queries/queryKeys.d.ts +1 -0
  447. package/lib/typescript/commonjs/ui/hooks/queries/queryKeys.d.ts.map +1 -1
  448. package/lib/typescript/commonjs/ui/hooks/queries/useAccountQueries.d.ts +22 -8
  449. package/lib/typescript/commonjs/ui/hooks/queries/useAccountQueries.d.ts.map +1 -1
  450. package/lib/typescript/commonjs/ui/hooks/queries/useSecurityQueries.d.ts +13 -3
  451. package/lib/typescript/commonjs/ui/hooks/queries/useSecurityQueries.d.ts.map +1 -1
  452. package/lib/typescript/commonjs/ui/hooks/queries/useServicesQueries.d.ts +7 -5
  453. package/lib/typescript/commonjs/ui/hooks/queries/useServicesQueries.d.ts.map +1 -1
  454. package/lib/typescript/commonjs/ui/hooks/queryClient.d.ts +57 -9
  455. package/lib/typescript/commonjs/ui/hooks/queryClient.d.ts.map +1 -1
  456. package/lib/typescript/commonjs/ui/hooks/useAssets.d.ts +1 -1
  457. package/lib/typescript/commonjs/ui/hooks/useAuth.d.ts +0 -1
  458. package/lib/typescript/commonjs/ui/hooks/useAuth.d.ts.map +1 -1
  459. package/lib/typescript/commonjs/ui/hooks/useAvatarPicker.d.ts +10 -2
  460. package/lib/typescript/commonjs/ui/hooks/useAvatarPicker.d.ts.map +1 -1
  461. package/lib/typescript/commonjs/ui/hooks/useFileDownloadUrl.d.ts +2 -6
  462. package/lib/typescript/commonjs/ui/hooks/useFileDownloadUrl.d.ts.map +1 -1
  463. package/lib/typescript/commonjs/ui/hooks/useMutationStatus.d.ts +23 -0
  464. package/lib/typescript/commonjs/ui/hooks/useMutationStatus.d.ts.map +1 -0
  465. package/lib/typescript/commonjs/ui/hooks/useOnlineStatus.d.ts +13 -0
  466. package/lib/typescript/commonjs/ui/hooks/useOnlineStatus.d.ts.map +1 -0
  467. package/lib/typescript/commonjs/ui/hooks/useSessionSocket.d.ts +1 -2
  468. package/lib/typescript/commonjs/ui/hooks/useSessionSocket.d.ts.map +1 -1
  469. package/lib/typescript/commonjs/ui/index.d.ts +1 -4
  470. package/lib/typescript/commonjs/ui/index.d.ts.map +1 -1
  471. package/lib/typescript/commonjs/ui/navigation/routes.d.ts +48 -2
  472. package/lib/typescript/commonjs/ui/navigation/routes.d.ts.map +1 -1
  473. package/lib/typescript/commonjs/ui/screens/AccountCenterScreen.d.ts.map +1 -1
  474. package/lib/typescript/commonjs/ui/screens/AccountOverviewScreen.d.ts.map +1 -1
  475. package/lib/typescript/commonjs/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
  476. package/lib/typescript/commonjs/ui/screens/AccountSwitcherScreen.d.ts.map +1 -1
  477. package/lib/typescript/commonjs/ui/screens/AppInfoScreen.d.ts.map +1 -1
  478. package/lib/typescript/commonjs/ui/screens/AvatarCropScreen.d.ts +49 -0
  479. package/lib/typescript/commonjs/ui/screens/AvatarCropScreen.d.ts.map +1 -0
  480. package/lib/typescript/commonjs/ui/screens/CreateManagedAccountScreen.d.ts.map +1 -1
  481. package/lib/typescript/commonjs/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
  482. package/lib/typescript/commonjs/ui/screens/FeedbackScreen.d.ts.map +1 -1
  483. package/lib/typescript/commonjs/ui/screens/FileManagementScreen.d.ts.map +1 -1
  484. package/lib/typescript/commonjs/ui/screens/HelpSupportScreen.d.ts.map +1 -1
  485. package/lib/typescript/commonjs/ui/screens/HistoryViewScreen.d.ts.map +1 -1
  486. package/lib/typescript/commonjs/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
  487. package/lib/typescript/commonjs/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
  488. package/lib/typescript/commonjs/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
  489. package/lib/typescript/commonjs/ui/screens/ProfileScreen.d.ts.map +1 -1
  490. package/lib/typescript/commonjs/ui/screens/SessionManagementScreen.d.ts.map +1 -1
  491. package/lib/typescript/commonjs/ui/screens/UserLinksScreen.d.ts.map +1 -1
  492. package/lib/typescript/commonjs/ui/screens/UserListScreen.d.ts.map +1 -1
  493. package/lib/typescript/commonjs/ui/screens/WelcomeNewUserScreen.d.ts.map +1 -1
  494. package/lib/typescript/commonjs/ui/screens/karma/KarmaAboutScreen.d.ts.map +1 -1
  495. package/lib/typescript/commonjs/ui/screens/karma/KarmaCenterScreen.d.ts.map +1 -1
  496. package/lib/typescript/commonjs/ui/screens/karma/KarmaLeaderboardScreen.d.ts.map +1 -1
  497. package/lib/typescript/commonjs/ui/screens/karma/KarmaRewardsScreen.d.ts.map +1 -1
  498. package/lib/typescript/commonjs/ui/screens/karma/KarmaRulesScreen.d.ts.map +1 -1
  499. package/lib/typescript/commonjs/ui/server.d.ts +0 -2
  500. package/lib/typescript/commonjs/ui/server.d.ts.map +1 -1
  501. package/lib/typescript/commonjs/ui/styles/authStyles.d.ts +0 -4
  502. package/lib/typescript/commonjs/ui/styles/authStyles.d.ts.map +1 -1
  503. package/lib/typescript/commonjs/ui/styles/index.d.ts +0 -1
  504. package/lib/typescript/commonjs/ui/styles/index.d.ts.map +1 -1
  505. package/lib/typescript/commonjs/ui/styles/spacing.d.ts +0 -36
  506. package/lib/typescript/commonjs/ui/styles/spacing.d.ts.map +1 -1
  507. package/lib/typescript/commonjs/ui/styles/theme.d.ts +0 -1
  508. package/lib/typescript/commonjs/ui/styles/theme.d.ts.map +1 -1
  509. package/lib/typescript/commonjs/ui/utils/fileManagement.d.ts +39 -12
  510. package/lib/typescript/commonjs/ui/utils/fileManagement.d.ts.map +1 -1
  511. package/lib/typescript/commonjs/ui/utils/sessionHelpers.d.ts +3 -1
  512. package/lib/typescript/commonjs/ui/utils/sessionHelpers.d.ts.map +1 -1
  513. package/lib/typescript/commonjs/ui/utils/userUtils.d.ts +19 -18
  514. package/lib/typescript/commonjs/ui/utils/userUtils.d.ts.map +1 -1
  515. package/lib/typescript/module/index.d.ts +7 -3
  516. package/lib/typescript/module/index.d.ts.map +1 -1
  517. package/lib/typescript/module/ui/client.d.ts +0 -2
  518. package/lib/typescript/module/ui/client.d.ts.map +1 -1
  519. package/lib/typescript/module/ui/components/ActingAsBanner.d.ts.map +1 -1
  520. package/lib/typescript/module/ui/components/Avatar.d.ts.map +1 -1
  521. package/lib/typescript/module/ui/components/BottomSheet.d.ts +27 -27
  522. package/lib/typescript/module/ui/components/BottomSheet.d.ts.map +1 -1
  523. package/lib/typescript/module/ui/components/BottomSheetRouter.d.ts.map +1 -1
  524. package/lib/typescript/module/ui/components/FollowButton.d.ts.map +1 -1
  525. package/lib/typescript/module/ui/components/Header.d.ts.map +1 -1
  526. package/lib/typescript/module/ui/components/Icon.d.ts +3 -2
  527. package/lib/typescript/module/ui/components/Icon.d.ts.map +1 -1
  528. package/lib/typescript/module/ui/components/IconButton/IconButton.d.ts.map +1 -1
  529. package/lib/typescript/module/ui/components/OxyPayButton.d.ts.map +1 -1
  530. package/lib/typescript/module/ui/components/OxyProvider.d.ts.map +1 -1
  531. package/lib/typescript/module/ui/components/OxySignInButton.d.ts.map +1 -1
  532. package/lib/typescript/module/ui/components/ProfileCard.d.ts +4 -1
  533. package/lib/typescript/module/ui/components/ProfileCard.d.ts.map +1 -1
  534. package/lib/typescript/module/ui/components/SignInModal.d.ts.map +1 -1
  535. package/lib/typescript/module/ui/components/StepBasedScreen.d.ts.map +1 -1
  536. package/lib/typescript/module/ui/components/TextField/Addons/Outline.d.ts +2 -2
  537. package/lib/typescript/module/ui/components/TextField/helpers.d.ts +2 -2
  538. package/lib/typescript/module/ui/components/TextField/types.d.ts +0 -1
  539. package/lib/typescript/module/ui/components/TextField/types.d.ts.map +1 -1
  540. package/lib/typescript/module/ui/components/TextField.d.ts +1 -1
  541. package/lib/typescript/module/ui/components/TextField.d.ts.map +1 -1
  542. package/lib/typescript/module/ui/components/feedback/feedbackStyles.d.ts +0 -1
  543. package/lib/typescript/module/ui/components/feedback/feedbackStyles.d.ts.map +1 -1
  544. package/lib/typescript/module/ui/components/fileManagement/AnimatedButton.d.ts.map +1 -1
  545. package/lib/typescript/module/ui/components/fileManagement/FileDetailsModal.d.ts +1 -1
  546. package/lib/typescript/module/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -1
  547. package/lib/typescript/module/ui/components/fileManagement/FileViewer.d.ts +0 -2
  548. package/lib/typescript/module/ui/components/fileManagement/FileViewer.d.ts.map +1 -1
  549. package/lib/typescript/module/ui/components/fileManagement/UploadPreview.d.ts +3 -2
  550. package/lib/typescript/module/ui/components/fileManagement/UploadPreview.d.ts.map +1 -1
  551. package/lib/typescript/module/ui/components/fileManagement/styles.d.ts +200 -17
  552. package/lib/typescript/module/ui/components/fileManagement/styles.d.ts.map +1 -1
  553. package/lib/typescript/module/ui/components/logo/LogoIcon.d.ts +22 -0
  554. package/lib/typescript/module/ui/components/logo/LogoIcon.d.ts.map +1 -0
  555. package/lib/typescript/module/ui/components/logo/LogoText.d.ts +22 -0
  556. package/lib/typescript/module/ui/components/logo/LogoText.d.ts.map +1 -0
  557. package/lib/typescript/module/ui/components/modals/DeleteAccountModal.d.ts +2 -2
  558. package/lib/typescript/module/ui/components/modals/DeleteAccountModal.d.ts.map +1 -1
  559. package/lib/typescript/module/ui/components/payment/paymentStyles.d.ts +0 -7
  560. package/lib/typescript/module/ui/components/payment/paymentStyles.d.ts.map +1 -1
  561. package/lib/typescript/module/ui/components/styles/overlay.d.ts +3 -1
  562. package/lib/typescript/module/ui/components/styles/overlay.d.ts.map +1 -1
  563. package/lib/typescript/module/ui/components/theming.d.ts.map +1 -1
  564. package/lib/typescript/module/ui/components/types.d.ts.map +1 -1
  565. package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
  566. package/lib/typescript/module/ui/context/hooks/useAuthOperations.d.ts.map +1 -1
  567. package/lib/typescript/module/ui/hooks/index.d.ts +5 -3
  568. package/lib/typescript/module/ui/hooks/index.d.ts.map +1 -1
  569. package/lib/typescript/module/ui/hooks/mutations/mutationFactory.d.ts +11 -0
  570. package/lib/typescript/module/ui/hooks/mutations/mutationFactory.d.ts.map +1 -1
  571. package/lib/typescript/module/ui/hooks/mutations/mutationKeys.d.ts +25 -0
  572. package/lib/typescript/module/ui/hooks/mutations/mutationKeys.d.ts.map +1 -0
  573. package/lib/typescript/module/ui/hooks/mutations/useAccountMutations.d.ts +161 -9
  574. package/lib/typescript/module/ui/hooks/mutations/useAccountMutations.d.ts.map +1 -1
  575. package/lib/typescript/module/ui/hooks/mutations/useServicesMutations.d.ts.map +1 -1
  576. package/lib/typescript/module/ui/hooks/queries/index.d.ts +1 -1
  577. package/lib/typescript/module/ui/hooks/queries/index.d.ts.map +1 -1
  578. package/lib/typescript/module/ui/hooks/queries/queryKeys.d.ts +1 -0
  579. package/lib/typescript/module/ui/hooks/queries/queryKeys.d.ts.map +1 -1
  580. package/lib/typescript/module/ui/hooks/queries/useAccountQueries.d.ts +22 -8
  581. package/lib/typescript/module/ui/hooks/queries/useAccountQueries.d.ts.map +1 -1
  582. package/lib/typescript/module/ui/hooks/queries/useSecurityQueries.d.ts +13 -3
  583. package/lib/typescript/module/ui/hooks/queries/useSecurityQueries.d.ts.map +1 -1
  584. package/lib/typescript/module/ui/hooks/queries/useServicesQueries.d.ts +7 -5
  585. package/lib/typescript/module/ui/hooks/queries/useServicesQueries.d.ts.map +1 -1
  586. package/lib/typescript/module/ui/hooks/queryClient.d.ts +57 -9
  587. package/lib/typescript/module/ui/hooks/queryClient.d.ts.map +1 -1
  588. package/lib/typescript/module/ui/hooks/useAssets.d.ts +1 -1
  589. package/lib/typescript/module/ui/hooks/useAuth.d.ts +0 -1
  590. package/lib/typescript/module/ui/hooks/useAuth.d.ts.map +1 -1
  591. package/lib/typescript/module/ui/hooks/useAvatarPicker.d.ts +10 -2
  592. package/lib/typescript/module/ui/hooks/useAvatarPicker.d.ts.map +1 -1
  593. package/lib/typescript/module/ui/hooks/useFileDownloadUrl.d.ts +2 -6
  594. package/lib/typescript/module/ui/hooks/useFileDownloadUrl.d.ts.map +1 -1
  595. package/lib/typescript/module/ui/hooks/useMutationStatus.d.ts +23 -0
  596. package/lib/typescript/module/ui/hooks/useMutationStatus.d.ts.map +1 -0
  597. package/lib/typescript/module/ui/hooks/useOnlineStatus.d.ts +13 -0
  598. package/lib/typescript/module/ui/hooks/useOnlineStatus.d.ts.map +1 -0
  599. package/lib/typescript/module/ui/hooks/useSessionSocket.d.ts +1 -2
  600. package/lib/typescript/module/ui/hooks/useSessionSocket.d.ts.map +1 -1
  601. package/lib/typescript/module/ui/index.d.ts +1 -4
  602. package/lib/typescript/module/ui/index.d.ts.map +1 -1
  603. package/lib/typescript/module/ui/navigation/routes.d.ts +48 -2
  604. package/lib/typescript/module/ui/navigation/routes.d.ts.map +1 -1
  605. package/lib/typescript/module/ui/screens/AccountCenterScreen.d.ts.map +1 -1
  606. package/lib/typescript/module/ui/screens/AccountOverviewScreen.d.ts.map +1 -1
  607. package/lib/typescript/module/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
  608. package/lib/typescript/module/ui/screens/AccountSwitcherScreen.d.ts.map +1 -1
  609. package/lib/typescript/module/ui/screens/AppInfoScreen.d.ts.map +1 -1
  610. package/lib/typescript/module/ui/screens/AvatarCropScreen.d.ts +49 -0
  611. package/lib/typescript/module/ui/screens/AvatarCropScreen.d.ts.map +1 -0
  612. package/lib/typescript/module/ui/screens/CreateManagedAccountScreen.d.ts.map +1 -1
  613. package/lib/typescript/module/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
  614. package/lib/typescript/module/ui/screens/FeedbackScreen.d.ts.map +1 -1
  615. package/lib/typescript/module/ui/screens/FileManagementScreen.d.ts.map +1 -1
  616. package/lib/typescript/module/ui/screens/HelpSupportScreen.d.ts.map +1 -1
  617. package/lib/typescript/module/ui/screens/HistoryViewScreen.d.ts.map +1 -1
  618. package/lib/typescript/module/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
  619. package/lib/typescript/module/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
  620. package/lib/typescript/module/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
  621. package/lib/typescript/module/ui/screens/ProfileScreen.d.ts.map +1 -1
  622. package/lib/typescript/module/ui/screens/SessionManagementScreen.d.ts.map +1 -1
  623. package/lib/typescript/module/ui/screens/UserLinksScreen.d.ts.map +1 -1
  624. package/lib/typescript/module/ui/screens/UserListScreen.d.ts.map +1 -1
  625. package/lib/typescript/module/ui/screens/WelcomeNewUserScreen.d.ts.map +1 -1
  626. package/lib/typescript/module/ui/screens/karma/KarmaAboutScreen.d.ts.map +1 -1
  627. package/lib/typescript/module/ui/screens/karma/KarmaCenterScreen.d.ts.map +1 -1
  628. package/lib/typescript/module/ui/screens/karma/KarmaLeaderboardScreen.d.ts.map +1 -1
  629. package/lib/typescript/module/ui/screens/karma/KarmaRewardsScreen.d.ts.map +1 -1
  630. package/lib/typescript/module/ui/screens/karma/KarmaRulesScreen.d.ts.map +1 -1
  631. package/lib/typescript/module/ui/server.d.ts +0 -2
  632. package/lib/typescript/module/ui/server.d.ts.map +1 -1
  633. package/lib/typescript/module/ui/styles/authStyles.d.ts +0 -4
  634. package/lib/typescript/module/ui/styles/authStyles.d.ts.map +1 -1
  635. package/lib/typescript/module/ui/styles/index.d.ts +0 -1
  636. package/lib/typescript/module/ui/styles/index.d.ts.map +1 -1
  637. package/lib/typescript/module/ui/styles/spacing.d.ts +0 -36
  638. package/lib/typescript/module/ui/styles/spacing.d.ts.map +1 -1
  639. package/lib/typescript/module/ui/styles/theme.d.ts +0 -1
  640. package/lib/typescript/module/ui/styles/theme.d.ts.map +1 -1
  641. package/lib/typescript/module/ui/utils/fileManagement.d.ts +39 -12
  642. package/lib/typescript/module/ui/utils/fileManagement.d.ts.map +1 -1
  643. package/lib/typescript/module/ui/utils/sessionHelpers.d.ts +3 -1
  644. package/lib/typescript/module/ui/utils/sessionHelpers.d.ts.map +1 -1
  645. package/lib/typescript/module/ui/utils/userUtils.d.ts +19 -18
  646. package/lib/typescript/module/ui/utils/userUtils.d.ts.map +1 -1
  647. package/lib/typescript/types/expo-vector-icons.d.ts +7 -4
  648. package/package.json +64 -31
  649. package/src/index.ts +11 -4
  650. package/src/types/expo-vector-icons.d.ts +7 -4
  651. package/src/ui/client.ts +0 -6
  652. package/src/ui/components/ActingAsBanner.tsx +0 -4
  653. package/src/ui/components/ActivityIndicator.tsx +1 -1
  654. package/src/ui/components/Avatar.tsx +0 -2
  655. package/src/ui/components/BottomSheet.tsx +41 -440
  656. package/src/ui/components/BottomSheetRouter.tsx +12 -1
  657. package/src/ui/components/FollowButton.tsx +2 -4
  658. package/src/ui/components/Header.tsx +0 -5
  659. package/src/ui/components/Icon.tsx +12 -6
  660. package/src/ui/components/IconButton/IconButton.tsx +0 -3
  661. package/src/ui/components/OxyPayButton.tsx +0 -2
  662. package/src/ui/components/OxyProvider.tsx +127 -48
  663. package/src/ui/components/OxySignInButton.tsx +21 -9
  664. package/src/ui/components/ProfileCard.tsx +13 -10
  665. package/src/ui/components/QuickActions.tsx +2 -2
  666. package/src/ui/components/SignInModal.tsx +80 -199
  667. package/src/ui/components/StepBasedScreen.tsx +0 -2
  668. package/src/ui/components/TextField/Addons/Outline.tsx +2 -2
  669. package/src/ui/components/TextField/helpers.tsx +2 -2
  670. package/src/ui/components/TextField/types.tsx +0 -1
  671. package/src/ui/components/TextField.tsx +1 -2
  672. package/src/ui/components/TouchableRipple/TouchableRipple.native.tsx +1 -1
  673. package/src/ui/components/feedback/feedbackStyles.ts +0 -2
  674. package/src/ui/components/fileManagement/AnimatedButton.tsx +0 -1
  675. package/src/ui/components/fileManagement/FileDetailsModal.tsx +71 -65
  676. package/src/ui/components/fileManagement/FileViewer.tsx +6 -9
  677. package/src/ui/components/fileManagement/UploadPreview.tsx +21 -25
  678. package/src/ui/components/fileManagement/styles.ts +206 -18
  679. package/src/ui/components/logo/LogoIcon.tsx +70 -0
  680. package/src/ui/components/logo/LogoText.tsx +70 -0
  681. package/src/ui/components/modals/DeleteAccountModal.tsx +56 -91
  682. package/src/ui/components/payment/PaymentDetailsStep.tsx +1 -1
  683. package/src/ui/components/payment/PaymentReviewStep.tsx +1 -1
  684. package/src/ui/components/payment/PaymentSuccessStep.tsx +1 -1
  685. package/src/ui/components/payment/paymentStyles.ts +0 -8
  686. package/src/ui/components/styles/overlay.tsx +17 -8
  687. package/src/ui/components/theming.tsx +0 -1
  688. package/src/ui/components/types.tsx +3 -2
  689. package/src/ui/context/OxyContext.tsx +34 -19
  690. package/src/ui/context/hooks/useAuthOperations.ts +1 -3
  691. package/src/ui/hooks/index.ts +11 -4
  692. package/src/ui/hooks/mutations/mutationFactory.ts +16 -1
  693. package/src/ui/hooks/mutations/mutationKeys.ts +28 -0
  694. package/src/ui/hooks/mutations/useAccountMutations.ts +251 -59
  695. package/src/ui/hooks/mutations/useServicesMutations.ts +10 -4
  696. package/src/ui/hooks/queries/index.ts +1 -0
  697. package/src/ui/hooks/queries/queryKeys.ts +2 -0
  698. package/src/ui/hooks/queries/useAccountQueries.ts +83 -3
  699. package/src/ui/hooks/queries/useSecurityQueries.ts +42 -2
  700. package/src/ui/hooks/queryClient.ts +194 -69
  701. package/src/ui/hooks/useAsyncAction.ts +3 -3
  702. package/src/ui/hooks/useAuth.ts +0 -2
  703. package/src/ui/hooks/useAvatarPicker.ts +108 -27
  704. package/src/ui/hooks/useFileDownloadUrl.ts +15 -39
  705. package/src/ui/hooks/useMutationStatus.ts +111 -0
  706. package/src/ui/hooks/useOnlineStatus.ts +29 -0
  707. package/src/ui/hooks/useSessionSocket.ts +136 -126
  708. package/src/ui/hooks/useSettingToggle.ts +1 -1
  709. package/src/ui/index.ts +0 -12
  710. package/src/ui/navigation/routes.ts +93 -2
  711. package/src/ui/screens/AccountCenterScreen.tsx +15 -13
  712. package/src/ui/screens/AccountOverviewScreen.tsx +94 -104
  713. package/src/ui/screens/AccountSettingsScreen.tsx +18 -17
  714. package/src/ui/screens/AccountSwitcherScreen.tsx +331 -298
  715. package/src/ui/screens/AccountVerificationScreen.tsx +15 -15
  716. package/src/ui/screens/AppInfoScreen.tsx +8 -13
  717. package/src/ui/screens/AvatarCropScreen.tsx +1073 -0
  718. package/src/ui/screens/CreateManagedAccountScreen.tsx +5 -16
  719. package/src/ui/screens/EditProfileFieldScreen.tsx +5 -10
  720. package/src/ui/screens/FAQScreen.tsx +3 -3
  721. package/src/ui/screens/FeedbackScreen.tsx +14 -12
  722. package/src/ui/screens/FileManagementScreen.tsx +885 -124
  723. package/src/ui/screens/HelpSupportScreen.tsx +2 -3
  724. package/src/ui/screens/HistoryViewScreen.tsx +24 -9
  725. package/src/ui/screens/LanguageSelectorScreen.tsx +1 -3
  726. package/src/ui/screens/LegalDocumentsScreen.tsx +3 -3
  727. package/src/ui/screens/PaymentGatewayScreen.tsx +2 -2
  728. package/src/ui/screens/PremiumSubscriptionScreen.tsx +51 -56
  729. package/src/ui/screens/PrivacySettingsScreen.tsx +22 -20
  730. package/src/ui/screens/ProfileScreen.tsx +1 -2
  731. package/src/ui/screens/SavesCollectionsScreen.tsx +2 -2
  732. package/src/ui/screens/SessionManagementScreen.tsx +35 -47
  733. package/src/ui/screens/UserLinksScreen.tsx +1 -2
  734. package/src/ui/screens/UserListScreen.tsx +30 -19
  735. package/src/ui/screens/WelcomeNewUserScreen.tsx +14 -18
  736. package/src/ui/screens/karma/KarmaAboutScreen.tsx +0 -3
  737. package/src/ui/screens/karma/KarmaCenterScreen.tsx +4 -8
  738. package/src/ui/screens/karma/KarmaFAQScreen.tsx +1 -1
  739. package/src/ui/screens/karma/KarmaLeaderboardScreen.tsx +3 -4
  740. package/src/ui/screens/karma/KarmaRewardsScreen.tsx +13 -18
  741. package/src/ui/screens/karma/KarmaRulesScreen.tsx +3 -4
  742. package/src/ui/server.ts +0 -4
  743. package/src/ui/styles/authStyles.ts +0 -5
  744. package/src/ui/styles/index.ts +0 -1
  745. package/src/ui/styles/spacing.ts +0 -43
  746. package/src/ui/styles/theme.ts +0 -4
  747. package/src/ui/utils/fileManagement.ts +66 -38
  748. package/src/ui/utils/sessionHelpers.ts +3 -1
  749. package/src/ui/utils/userUtils.ts +45 -29
  750. package/lib/commonjs/lib/sonner-safe.js +0 -32
  751. package/lib/commonjs/lib/sonner-safe.js.map +0 -1
  752. package/lib/commonjs/lib/sonner.js +0 -19
  753. package/lib/commonjs/lib/sonner.js.map +0 -1
  754. package/lib/commonjs/lib/sonner.native.js +0 -24
  755. package/lib/commonjs/lib/sonner.native.js.map +0 -1
  756. package/lib/commonjs/lib/sonner.web.js +0 -24
  757. package/lib/commonjs/lib/sonner.web.js.map +0 -1
  758. package/lib/commonjs/ui/hooks/useThemeColors.js +0 -33
  759. package/lib/commonjs/ui/hooks/useThemeColors.js.map +0 -1
  760. package/lib/commonjs/ui/hooks/useThemeStyles.js +0 -38
  761. package/lib/commonjs/ui/hooks/useThemeStyles.js.map +0 -1
  762. package/lib/commonjs/ui/styles/fonts.js +0 -84
  763. package/lib/commonjs/ui/styles/fonts.js.map +0 -1
  764. package/lib/module/lib/sonner-safe.js +0 -29
  765. package/lib/module/lib/sonner-safe.js.map +0 -1
  766. package/lib/module/lib/sonner.js +0 -14
  767. package/lib/module/lib/sonner.js.map +0 -1
  768. package/lib/module/lib/sonner.native.js +0 -19
  769. package/lib/module/lib/sonner.native.js.map +0 -1
  770. package/lib/module/lib/sonner.web.js +0 -19
  771. package/lib/module/lib/sonner.web.js.map +0 -1
  772. package/lib/module/ui/hooks/useThemeColors.js +0 -29
  773. package/lib/module/ui/hooks/useThemeColors.js.map +0 -1
  774. package/lib/module/ui/hooks/useThemeStyles.js +0 -33
  775. package/lib/module/ui/hooks/useThemeStyles.js.map +0 -1
  776. package/lib/module/ui/styles/fonts.js +0 -81
  777. package/lib/module/ui/styles/fonts.js.map +0 -1
  778. package/lib/typescript/commonjs/lib/sonner-safe.d.ts +0 -9
  779. package/lib/typescript/commonjs/lib/sonner-safe.d.ts.map +0 -1
  780. package/lib/typescript/commonjs/lib/sonner.d.ts +0 -12
  781. package/lib/typescript/commonjs/lib/sonner.d.ts.map +0 -1
  782. package/lib/typescript/commonjs/lib/sonner.native.d.ts +0 -15
  783. package/lib/typescript/commonjs/lib/sonner.native.d.ts.map +0 -1
  784. package/lib/typescript/commonjs/lib/sonner.web.d.ts +0 -15
  785. package/lib/typescript/commonjs/lib/sonner.web.d.ts.map +0 -1
  786. package/lib/typescript/commonjs/ui/hooks/useThemeColors.d.ts +0 -87
  787. package/lib/typescript/commonjs/ui/hooks/useThemeColors.d.ts.map +0 -1
  788. package/lib/typescript/commonjs/ui/hooks/useThemeStyles.d.ts +0 -22
  789. package/lib/typescript/commonjs/ui/hooks/useThemeStyles.d.ts.map +0 -1
  790. package/lib/typescript/commonjs/ui/styles/fonts.d.ts +0 -21
  791. package/lib/typescript/commonjs/ui/styles/fonts.d.ts.map +0 -1
  792. package/lib/typescript/module/lib/sonner-safe.d.ts +0 -9
  793. package/lib/typescript/module/lib/sonner-safe.d.ts.map +0 -1
  794. package/lib/typescript/module/lib/sonner.d.ts +0 -12
  795. package/lib/typescript/module/lib/sonner.d.ts.map +0 -1
  796. package/lib/typescript/module/lib/sonner.native.d.ts +0 -15
  797. package/lib/typescript/module/lib/sonner.native.d.ts.map +0 -1
  798. package/lib/typescript/module/lib/sonner.web.d.ts +0 -15
  799. package/lib/typescript/module/lib/sonner.web.d.ts.map +0 -1
  800. package/lib/typescript/module/ui/hooks/useThemeColors.d.ts +0 -87
  801. package/lib/typescript/module/ui/hooks/useThemeColors.d.ts.map +0 -1
  802. package/lib/typescript/module/ui/hooks/useThemeStyles.d.ts +0 -22
  803. package/lib/typescript/module/ui/hooks/useThemeStyles.d.ts.map +0 -1
  804. package/lib/typescript/module/ui/styles/fonts.d.ts +0 -21
  805. package/lib/typescript/module/ui/styles/fonts.d.ts.map +0 -1
  806. package/src/lib/sonner-safe.ts +0 -31
  807. package/src/lib/sonner.native.ts +0 -28
  808. package/src/lib/sonner.ts +0 -11
  809. package/src/lib/sonner.web.ts +0 -28
  810. package/src/ui/hooks/useThemeColors.ts +0 -27
  811. package/src/ui/hooks/useThemeStyles.ts +0 -50
  812. package/src/ui/styles/fonts.ts +0 -77
@@ -7,10 +7,10 @@ exports.default = void 0;
7
7
  var _react = _interopRequireWildcard(require("react"));
8
8
  var _reactNative = require("react-native");
9
9
  var _expoImage = require("expo-image");
10
- var _sonner = require("../../lib/sonner");
11
- var _prompt = _interopRequireWildcard(require("@oxyhq/bloom/prompt"));
12
- var Prompt = _prompt;
10
+ var _reactNativeReanimated = _interopRequireWildcard(require("react-native-reanimated"));
11
+ var _bloom = require("@oxyhq/bloom");
13
12
  var _vectorIcons = require("@expo/vector-icons");
13
+ var _core = require("@oxyhq/core");
14
14
  var _fileStore = require("../stores/fileStore.js");
15
15
  var _Header = _interopRequireDefault(require("../components/Header.js"));
16
16
  var _JustifiedPhotoGrid = _interopRequireDefault(require("../components/photogrid/JustifiedPhotoGrid.js"));
@@ -23,7 +23,6 @@ var _fileManagement = require("../utils/fileManagement.js");
23
23
  var _FileViewer = require("../components/fileManagement/FileViewer.js");
24
24
  var _FileDetailsModal = require("../components/fileManagement/FileDetailsModal.js");
25
25
  var _UploadPreview = require("../components/fileManagement/UploadPreview.js");
26
- var _dialog = require("@oxyhq/bloom/dialog");
27
26
  var _styles = require("../components/fileManagement/styles.js");
28
27
  var _jsxRuntime = require("react/jsx-runtime");
29
28
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
@@ -40,11 +39,96 @@ const loadDocumentPicker = async () => {
40
39
  throw new Error('expo-document-picker is not installed. Please install it: npx expo install expo-document-picker');
41
40
  }
42
41
  };
42
+ /**
43
+ * Extract error message from unknown error type.
44
+ * Delegates to the canonical `getErrorMessage` in `@oxyhq/core` and returns
45
+ * `undefined` for empty results (so callers can fall back to a translated
46
+ * message via `||`).
47
+ */
48
+ const getErrorMessage = error => {
49
+ if (error == null) return undefined;
50
+ const message = (0, _core.getErrorMessage)(error, '');
51
+ return message ? message : undefined;
52
+ };
53
+
54
+ /**
55
+ * A picker-produced file ready to upload. On web this is a real `File`
56
+ * (carrying an optional `uri` for preview). On native, it's an
57
+ * {@link RNFileDescriptor} — passed straight to FormData by `assetUpload`.
58
+ */
59
+
60
+ /** Returns the display name for either a web File or an RN descriptor. */
61
+ const candidateName = (candidate, fallback) => candidate.name && typeof candidate.name === 'string' ? candidate.name : fallback;
43
62
 
44
- // @ts-ignore - MaterialCommunityIcons is available at runtime
63
+ /** Returns the byte size for either a web File or an RN descriptor (0 if unknown). */
64
+ const candidateSize = candidate => {
65
+ const size = candidate.size;
66
+ return typeof size === 'number' && Number.isFinite(size) ? size : 0;
67
+ };
45
68
 
46
- /** Extract error message from unknown error type */
47
- const getErrorMessage = error => error instanceof Error ? getErrorMessage(error) : typeof error === 'string' ? error : undefined;
69
+ /** Returns the mime type for either a web File or an RN descriptor. */
70
+ const candidateType = candidate => {
71
+ const value = candidate.type;
72
+ return typeof value === 'string' && value.length > 0 ? value : 'application/octet-stream';
73
+ };
74
+
75
+ /** Returns the preview URI for an upload candidate, if available. */
76
+ const candidateUri = candidate => {
77
+ const uri = candidate.uri;
78
+ return typeof uri === 'string' && uri.length > 0 ? uri : undefined;
79
+ };
80
+
81
+ /**
82
+ * Haptic feedback wrapper. `expo-haptics` is an optional dependency — when not
83
+ * installed (or on web), all calls degrade silently. We resolve the module
84
+ * once and cache the promise so subsequent calls don't repeat the dynamic
85
+ * import. Matches the pattern used by AvatarCropScreen.
86
+ */
87
+
88
+ let hapticsModulePromise = null;
89
+ const getHaptics = () => {
90
+ if (_reactNative.Platform.OS === 'web') return Promise.resolve(null);
91
+ if (hapticsModulePromise) return hapticsModulePromise;
92
+ hapticsModulePromise = (async () => {
93
+ try {
94
+ const mod = await Promise.resolve().then(() => _interopRequireWildcard(require('expo-haptics')));
95
+ if (!mod || typeof mod.impactAsync !== 'function') return null;
96
+ return mod;
97
+ } catch {
98
+ return null;
99
+ }
100
+ })();
101
+ return hapticsModulePromise;
102
+ };
103
+ const hapticImpact = async style => {
104
+ const h = await getHaptics();
105
+ if (!h) return;
106
+ const styleEnum = style === 'heavy' ? h.ImpactFeedbackStyle.Heavy : style === 'medium' ? h.ImpactFeedbackStyle.Medium : h.ImpactFeedbackStyle.Light;
107
+ try {
108
+ await h.impactAsync(styleEnum);
109
+ } catch {
110
+ // Silent — haptics are non-critical UX polish.
111
+ }
112
+ };
113
+ const hapticSelection = async () => {
114
+ const h = await getHaptics();
115
+ if (!h) return;
116
+ try {
117
+ await h.selectionAsync();
118
+ } catch {
119
+ // Silent.
120
+ }
121
+ };
122
+ const hapticNotification = async type => {
123
+ const h = await getHaptics();
124
+ if (!h) return;
125
+ const typeEnum = type === 'error' ? h.NotificationFeedbackType.Error : type === 'warning' ? h.NotificationFeedbackType.Warning : h.NotificationFeedbackType.Success;
126
+ try {
127
+ await h.notificationAsync(typeEnum);
128
+ } catch {
129
+ // Silent.
130
+ }
131
+ };
48
132
 
49
133
  // Animated button component for smooth transitions
50
134
  const AnimatedButton = ({
@@ -53,7 +137,8 @@ const AnimatedButton = ({
53
137
  icon,
54
138
  primaryColor,
55
139
  textColor,
56
- style
140
+ style,
141
+ accessibilityLabel
57
142
  }) => {
58
143
  const animatedValue = (0, _react.useRef)(new _reactNative.Animated.Value(isSelected ? 1 : 0)).current;
59
144
  (0, _react.useEffect)(() => {
@@ -68,13 +153,14 @@ const AnimatedButton = ({
68
153
  inputRange: [0, 1],
69
154
  outputRange: ['transparent', primaryColor]
70
155
  });
71
- const iconColor = animatedValue.interpolate({
72
- inputRange: [0, 1],
73
- outputRange: [textColor, '#FFFFFF']
74
- });
75
156
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
76
157
  onPress: onPress,
77
158
  activeOpacity: 0.7,
159
+ accessibilityRole: "button",
160
+ accessibilityLabel: accessibilityLabel,
161
+ accessibilityState: {
162
+ selected: isSelected
163
+ },
78
164
  children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Animated.View, {
79
165
  style: [style, {
80
166
  backgroundColor
@@ -89,6 +175,453 @@ const AnimatedButton = ({
89
175
  })
90
176
  });
91
177
  };
178
+
179
+ /**
180
+ * Props for the dedicated photo picker view. Used by FileManagementScreen
181
+ * only when `selectMode + image-only` is active. All callbacks are wired by
182
+ * the parent — this component is purely presentational.
183
+ */
184
+
185
+ /**
186
+ * A single photo cell. Memoized so re-renders during selection only touch
187
+ * affected cells — selection of one photo must not redraw the whole grid.
188
+ *
189
+ * Apple Photos pattern: when any cell is selected, *non-selected* siblings
190
+ * fade to 0.6 opacity to focus attention on the active selection.
191
+ */
192
+ const PhotoPickerCell = /*#__PURE__*/_react.default.memo(function PhotoPickerCell(props) {
193
+ const {
194
+ photo,
195
+ size,
196
+ marginRight,
197
+ marginBottom,
198
+ isSelected,
199
+ selectionIndex,
200
+ dim,
201
+ primaryColor,
202
+ thumbUrl,
203
+ enterIndex,
204
+ reduceMotion,
205
+ onPress,
206
+ onLongPress,
207
+ a11yLabel
208
+ } = props;
209
+
210
+ // Cap the cumulative stagger at ~800ms total so the very long grid does
211
+ // not keep fading in late tiles. Beyond ~53 tiles the delay maxes out.
212
+ const STAGGER_PER_CELL_MS = 15;
213
+ const MAX_TOTAL_STAGGER_MS = 800;
214
+ const delay = Math.min(enterIndex * STAGGER_PER_CELL_MS, MAX_TOTAL_STAGGER_MS);
215
+
216
+ // Selection ring pulse animation: 1.0 → 1.05 → 1.0 on transition to
217
+ // selected. Plays at most once per selection change; reduce-motion skips.
218
+ const ringScale = (0, _reactNativeReanimated.useSharedValue)(1);
219
+ const prevSelected = (0, _react.useRef)(isSelected);
220
+ (0, _react.useEffect)(() => {
221
+ if (prevSelected.current === isSelected) return;
222
+ prevSelected.current = isSelected;
223
+ if (!isSelected) {
224
+ ringScale.value = 1;
225
+ return;
226
+ }
227
+ if (reduceMotion) {
228
+ ringScale.value = 1;
229
+ return;
230
+ }
231
+ ringScale.value = (0, _reactNativeReanimated.withSequence)((0, _reactNativeReanimated.withTiming)(1.05, {
232
+ duration: 110
233
+ }), (0, _reactNativeReanimated.withSpring)(1, {
234
+ damping: 14,
235
+ stiffness: 200
236
+ }));
237
+ }, [isSelected, reduceMotion, ringScale]);
238
+ const ringAnimatedStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => ({
239
+ transform: [{
240
+ scale: ringScale.value
241
+ }]
242
+ }));
243
+ const inner = /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
244
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
245
+ style: [_styles.photoPickerStyles.cellInner, dim && _styles.photoPickerStyles.cellDim],
246
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_expoImage.Image, {
247
+ source: {
248
+ uri: thumbUrl
249
+ },
250
+ style: _styles.photoPickerStyles.cellImage,
251
+ contentFit: "cover",
252
+ transition: 120,
253
+ cachePolicy: "memory-disk",
254
+ accessibilityLabel: photo.filename
255
+ })
256
+ }), isSelected && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
257
+ pointerEvents: "none",
258
+ style: [_styles.photoPickerStyles.cellRing, {
259
+ borderColor: primaryColor
260
+ }, ringAnimatedStyle]
261
+ }), isSelected && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
262
+ pointerEvents: "none",
263
+ style: [_styles.photoPickerStyles.cellBadge, {
264
+ backgroundColor: primaryColor
265
+ }],
266
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
267
+ style: _styles.photoPickerStyles.cellBadgeText,
268
+ children: selectionIndex > 0 ? String(selectionIndex) : ''
269
+ })
270
+ })]
271
+ });
272
+ const cellWrapperStyle = {
273
+ width: size,
274
+ height: size,
275
+ marginRight,
276
+ marginBottom
277
+ };
278
+ if (reduceMotion) {
279
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
280
+ activeOpacity: 0.85,
281
+ onPress: onPress,
282
+ onLongPress: onLongPress,
283
+ style: [_styles.photoPickerStyles.cellWrapper, cellWrapperStyle],
284
+ accessibilityRole: "button",
285
+ accessibilityLabel: a11yLabel,
286
+ accessibilityState: {
287
+ selected: isSelected
288
+ },
289
+ children: inner
290
+ });
291
+ }
292
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeReanimated.default.View, {
293
+ entering: _reactNativeReanimated.FadeIn.delay(delay).duration(200),
294
+ style: [_styles.photoPickerStyles.cellWrapper, cellWrapperStyle],
295
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
296
+ activeOpacity: 0.85,
297
+ onPress: onPress,
298
+ onLongPress: onLongPress,
299
+ style: {
300
+ flex: 1
301
+ },
302
+ accessibilityRole: "button",
303
+ accessibilityLabel: a11yLabel,
304
+ accessibilityState: {
305
+ selected: isSelected
306
+ },
307
+ children: inner
308
+ })
309
+ });
310
+ });
311
+ const PhotoPickerView = ({
312
+ photos,
313
+ selectedIds,
314
+ multiSelect,
315
+ maxSelection,
316
+ allowUpload,
317
+ refreshing,
318
+ uploading,
319
+ isPickingDocument,
320
+ uploadProgress,
321
+ hasMore,
322
+ loadingMore,
323
+ reduceMotion,
324
+ getThumbUrl,
325
+ primaryColor,
326
+ isOwner,
327
+ onTogglePhoto,
328
+ onPreviewPhoto,
329
+ onUpload,
330
+ onRefresh,
331
+ onLoadMore,
332
+ onCancel,
333
+ onConfirm,
334
+ t
335
+ }) => {
336
+ const {
337
+ width: windowWidth,
338
+ height: windowHeight
339
+ } = (0, _reactNative.useWindowDimensions)();
340
+
341
+ // Layout: 3 columns phone portrait, 2 columns phone landscape,
342
+ // 4 columns tablet (>= 600 width). Apple Photos-ish.
343
+ const columns = (0, _react.useMemo)(() => {
344
+ if (windowWidth >= 600) return 4;
345
+ // Landscape phone: width > height
346
+ if (windowWidth > windowHeight) return 2;
347
+ return 3;
348
+ }, [windowWidth, windowHeight]);
349
+ const GUTTER = 2;
350
+ const cellSize = (0, _react.useMemo)(() => {
351
+ // (windowWidth - (columns - 1) * GUTTER) / columns, but
352
+ // FlatList in 3-col layout means each row has 2 inter-cell gutters.
353
+ return Math.floor((windowWidth - GUTTER * (columns - 1)) / columns);
354
+ }, [windowWidth, columns]);
355
+
356
+ // Map selectedIds → 1-based selection order for the badge. We freeze a
357
+ // stable order at the time of selection: the order is the insertion
358
+ // order of the Set (which JS preserves natively).
359
+ const selectionOrder = (0, _react.useMemo)(() => {
360
+ const map = new Map();
361
+ let i = 1;
362
+ for (const id of selectedIds) {
363
+ map.set(id, i++);
364
+ }
365
+ return map;
366
+ }, [selectedIds]);
367
+ const hasAnySelection = selectedIds.size > 0;
368
+
369
+ // Compact icon-only upload pill on narrow screens; full pill otherwise.
370
+ const showUploadLabel = windowWidth >= 360;
371
+
372
+ // The bottom sheet renders below the status bar already (its `maxHeight`
373
+ // is capped by `SCREEN_HEIGHT - insets.top`), so the picker MUST NOT add
374
+ // an additional safe-area inset to the header. Header layout:
375
+ // • 28dp drag-handle hit area floats at the very top of the sheet
376
+ // • 56dp app bar sits immediately below the handle
377
+ // Total header zone = 28 + 56 = 84dp from sheet top.
378
+ const HANDLE_ZONE = 28;
379
+ const APP_BAR_HEIGHT = 56;
380
+ const headerHeight = HANDLE_ZONE + APP_BAR_HEIGHT;
381
+ const contentPaddingTop = headerHeight + 4;
382
+ const isEmpty = photos.length === 0;
383
+ const a11yColumnsAnnouncement = (0, _react.useRef)(columns);
384
+ (0, _react.useEffect)(() => {
385
+ if (a11yColumnsAnnouncement.current !== columns) {
386
+ a11yColumnsAnnouncement.current = columns;
387
+ }
388
+ }, [columns]);
389
+ const handleCellPress = (0, _react.useCallback)(photo => {
390
+ if (_reactNative.Platform.OS !== 'web') {
391
+ void hapticImpact('light');
392
+ }
393
+ onTogglePhoto(photo);
394
+ }, [onTogglePhoto]);
395
+ const handleCellLongPress = (0, _react.useCallback)(photo => {
396
+ if (_reactNative.Platform.OS !== 'web') {
397
+ void hapticSelection();
398
+ }
399
+ onPreviewPhoto(photo);
400
+ }, [onPreviewPhoto]);
401
+ const handleConfirm = (0, _react.useCallback)(() => {
402
+ if (multiSelect) {
403
+ if (selectedIds.size === 0) return;
404
+ if (_reactNative.Platform.OS !== 'web') {
405
+ void hapticNotification('success');
406
+ }
407
+ }
408
+ onConfirm();
409
+ }, [multiSelect, selectedIds.size, onConfirm]);
410
+
411
+ // FlatList renderItem: each cell knows its enterIndex (for stagger).
412
+ const renderItem = (0, _react.useCallback)(({
413
+ item,
414
+ index
415
+ }) => {
416
+ const isSelected = selectedIds.has(item.id);
417
+ const selIndex = isSelected ? selectionOrder.get(item.id) || 0 : 0;
418
+ // Last column gets no right margin; last row no bottom margin
419
+ // (FlatList handles row breaks via numColumns).
420
+ const isLastInRow = (index + 1) % columns === 0;
421
+ const a11yLabel = t(isSelected ? 'fileManagement.a11y.photoCellSelected' : 'fileManagement.a11y.photoCellUnselected', {
422
+ name: item.filename || 'photo'
423
+ });
424
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(PhotoPickerCell, {
425
+ photo: item,
426
+ size: cellSize,
427
+ marginRight: isLastInRow ? 0 : GUTTER,
428
+ marginBottom: GUTTER,
429
+ isSelected: isSelected,
430
+ selectionIndex: selIndex,
431
+ dim: multiSelect && hasAnySelection && !isSelected,
432
+ primaryColor: primaryColor,
433
+ thumbUrl: getThumbUrl(item, 'thumb'),
434
+ enterIndex: index,
435
+ reduceMotion: reduceMotion,
436
+ onPress: () => handleCellPress(item),
437
+ onLongPress: () => handleCellLongPress(item),
438
+ a11yLabel: a11yLabel
439
+ });
440
+ }, [selectedIds, selectionOrder, columns, cellSize, multiSelect, hasAnySelection, primaryColor, getThumbUrl, reduceMotion, handleCellPress, handleCellLongPress, t]);
441
+ const keyExtractor = (0, _react.useCallback)(item => item.id, []);
442
+ const listFooter = (0, _react.useMemo)(() => {
443
+ if (!loadingMore) return null;
444
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
445
+ style: {
446
+ paddingVertical: 16,
447
+ alignItems: 'center'
448
+ },
449
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {
450
+ size: "small",
451
+ color: "#FFFFFF"
452
+ })
453
+ });
454
+ }, [loadingMore]);
455
+ const handleEndReached = (0, _react.useCallback)(() => {
456
+ if (loadingMore || !hasMore) return;
457
+ onLoadMore();
458
+ }, [loadingMore, hasMore, onLoadMore]);
459
+ const confirmDisabled = multiSelect && selectedIds.size === 0;
460
+ const confirmLabel = multiSelect ? t('fileManagement.doneWithCount', {
461
+ count: selectedIds.size
462
+ }) : t('fileManagement.done');
463
+
464
+ // The progress fill width. Guard against zero division.
465
+ const progressFraction = uploadProgress && uploadProgress.total > 0 ? Math.min(1, Math.max(0, uploadProgress.current / uploadProgress.total)) : 0;
466
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
467
+ style: _styles.photoPickerStyles.root,
468
+ children: [isEmpty ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
469
+ style: [_styles.photoPickerStyles.empty, {
470
+ paddingTop: contentPaddingTop
471
+ }],
472
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
473
+ style: _styles.photoPickerStyles.emptyIconWrap,
474
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_vectorIcons.MaterialCommunityIcons, {
475
+ name: "image-outline",
476
+ size: 64,
477
+ color: "#FFFFFF"
478
+ })
479
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
480
+ style: [_styles.photoPickerStyles.emptyTitle, {
481
+ color: '#FFFFFF'
482
+ }],
483
+ children: t('fileManagement.photoPicker.emptyTitle')
484
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
485
+ style: [_styles.photoPickerStyles.emptySubtitle, {
486
+ color: '#FFFFFF'
487
+ }],
488
+ children: t('fileManagement.photoPicker.emptySubtitle')
489
+ }), isOwner && allowUpload && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
490
+ style: [_styles.photoPickerStyles.emptyCta, {
491
+ backgroundColor: primaryColor
492
+ }],
493
+ onPress: onUpload,
494
+ disabled: uploading || isPickingDocument,
495
+ accessibilityRole: "button",
496
+ accessibilityLabel: t('fileManagement.uploadPhoto'),
497
+ accessibilityState: {
498
+ busy: uploading || isPickingDocument
499
+ },
500
+ children: uploading || isPickingDocument ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {
501
+ size: "small",
502
+ color: "#FFFFFF"
503
+ }) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
504
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_vectorIcons.Ionicons, {
505
+ name: "cloud-upload",
506
+ size: 18,
507
+ color: "#FFFFFF"
508
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
509
+ style: _styles.photoPickerStyles.emptyCtaText,
510
+ children: t('fileManagement.uploadPhoto')
511
+ })]
512
+ })
513
+ })]
514
+ }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.FlatList, {
515
+ data: photos,
516
+ renderItem: renderItem,
517
+ keyExtractor: keyExtractor,
518
+ numColumns: columns,
519
+ contentContainerStyle: [_styles.photoPickerStyles.gridContent, {
520
+ paddingTop: contentPaddingTop
521
+ }],
522
+ style: _styles.photoPickerStyles.grid,
523
+ showsVerticalScrollIndicator: false,
524
+ refreshControl: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.RefreshControl, {
525
+ refreshing: refreshing,
526
+ onRefresh: onRefresh,
527
+ tintColor: "#FFFFFF",
528
+ colors: [primaryColor],
529
+ progressViewOffset: contentPaddingTop
530
+ }),
531
+ onEndReached: handleEndReached,
532
+ onEndReachedThreshold: 0.4,
533
+ ListFooterComponent: listFooter,
534
+ removeClippedSubviews: true,
535
+ initialNumToRender: Math.max(12, columns * 6),
536
+ windowSize: 9
537
+ }, `cols-${columns}`), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
538
+ style: [_styles.photoPickerStyles.header, {
539
+ paddingTop: HANDLE_ZONE,
540
+ minHeight: headerHeight
541
+ }],
542
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
543
+ style: _styles.photoPickerStyles.headerRow,
544
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
545
+ style: [_styles.photoPickerStyles.headerSide, _styles.photoPickerStyles.headerSideLeft],
546
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
547
+ onPress: onCancel,
548
+ style: _styles.photoPickerStyles.headerCancel,
549
+ accessibilityRole: "button",
550
+ accessibilityLabel: t('fileManagement.a11y.cancelPicker'),
551
+ hitSlop: {
552
+ top: 8,
553
+ bottom: 8,
554
+ left: 8,
555
+ right: 8
556
+ },
557
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
558
+ style: _styles.photoPickerStyles.headerCancelText,
559
+ children: t('fileManagement.cancel')
560
+ })
561
+ })
562
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
563
+ pointerEvents: "none",
564
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
565
+ style: _styles.photoPickerStyles.headerTitle,
566
+ numberOfLines: 1,
567
+ children: t('fileManagement.choosePhoto')
568
+ })
569
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
570
+ style: [_styles.photoPickerStyles.headerSide, _styles.photoPickerStyles.headerSideRight],
571
+ children: multiSelect ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
572
+ onPress: handleConfirm,
573
+ disabled: confirmDisabled,
574
+ style: [_styles.photoPickerStyles.headerPrimaryPill, {
575
+ backgroundColor: confirmDisabled ? 'rgba(255,255,255,0.18)' : primaryColor,
576
+ opacity: confirmDisabled ? 0.6 : 1
577
+ }],
578
+ accessibilityRole: "button",
579
+ accessibilityLabel: t('fileManagement.a11y.confirmSelection'),
580
+ accessibilityState: {
581
+ disabled: confirmDisabled
582
+ },
583
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
584
+ style: _styles.photoPickerStyles.headerPrimaryText,
585
+ children: confirmLabel
586
+ })
587
+ }) : isOwner && allowUpload && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
588
+ onPress: onUpload,
589
+ disabled: uploading || isPickingDocument,
590
+ style: [_styles.photoPickerStyles.headerPrimaryPill, !showUploadLabel && _styles.photoPickerStyles.headerPrimaryPillIconOnly, {
591
+ backgroundColor: primaryColor
592
+ }],
593
+ accessibilityRole: "button",
594
+ accessibilityLabel: t('fileManagement.a11y.uploadFromDevice'),
595
+ accessibilityState: {
596
+ busy: uploading || isPickingDocument
597
+ },
598
+ children: uploading || isPickingDocument ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {
599
+ size: "small",
600
+ color: "#FFFFFF"
601
+ }) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
602
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_vectorIcons.Ionicons, {
603
+ name: "cloud-upload",
604
+ size: 16,
605
+ color: "#FFFFFF"
606
+ }), showUploadLabel && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
607
+ style: _styles.photoPickerStyles.headerPrimaryText,
608
+ children: t('fileManagement.upload')
609
+ })]
610
+ })
611
+ })
612
+ })]
613
+ }), uploading && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
614
+ style: _styles.photoPickerStyles.headerProgressBarTrack,
615
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
616
+ style: [_styles.photoPickerStyles.headerProgressBarFill, {
617
+ width: `${Math.round(progressFraction * 100)}%`,
618
+ backgroundColor: primaryColor
619
+ }]
620
+ })
621
+ })]
622
+ })]
623
+ });
624
+ };
92
625
  const FileManagementScreen = ({
93
626
  onClose,
94
627
  theme,
@@ -119,9 +652,9 @@ const FileManagementScreen = ({
119
652
  } = (0, _useI18n.useI18n)();
120
653
  const uploadFileMutation = (0, _useAccountMutations.useUploadFile)();
121
654
  // Prompt controls
122
- const fileDeletePrompt = (0, _prompt.usePromptControl)();
123
- const bulkDeletePrompt = (0, _prompt.usePromptControl)();
124
- const visibilityChangePrompt = (0, _prompt.usePromptControl)();
655
+ const fileDeleteDialog = (0, _bloom.useDialogControl)();
656
+ const bulkDeleteDialog = (0, _bloom.useDialogControl)();
657
+ const visibilityChangeDialog = (0, _bloom.useDialogControl)();
125
658
  const [pendingDeleteFile, setPendingDeleteFile] = (0, _react.useState)(null);
126
659
  const files = (0, _fileStore.useFiles)();
127
660
  // Ensure containerWidth is a number (TypeScript guard)
@@ -139,14 +672,44 @@ const FileManagementScreen = ({
139
672
  loadingMore: false
140
673
  });
141
674
  const [selectedFile, setSelectedFile] = (0, _react.useState)(null);
142
- const fileDetailsControl = (0, _dialog.useDialogControl)();
675
+ const fileDetailsControl = (0, _bloom.useDialogControl)();
143
676
  // In selectMode we never open the detailed viewer
144
677
  const [openedFile, setOpenedFile] = (0, _react.useState)(null);
145
678
  const [fileContent, setFileContent] = (0, _react.useState)(null);
146
679
  const [loadingFileContent, setLoadingFileContent] = (0, _react.useState)(false);
147
680
  const [showFileDetailsInViewer, setShowFileDetailsInViewer] = (0, _react.useState)(false);
148
681
  const [isPickingDocument, setIsPickingDocument] = (0, _react.useState)(false);
149
- const [viewMode, setViewMode] = (0, _react.useState)('all');
682
+ const [reduceMotion, setReduceMotion] = (0, _react.useState)(false);
683
+
684
+ // Detect reduce-motion preference once on mount + subscribe to changes.
685
+ // Used by `PhotoPickerView` to skip cell stagger animations.
686
+ (0, _react.useEffect)(() => {
687
+ let cancelled = false;
688
+ _reactNative.AccessibilityInfo.isReduceMotionEnabled().then(enabled => {
689
+ if (!cancelled) setReduceMotion(enabled);
690
+ }).catch(() => {
691
+ // Defaults to false; no action needed.
692
+ });
693
+ const sub = _reactNative.AccessibilityInfo.addEventListener('reduceMotionChanged', enabled => {
694
+ setReduceMotion(enabled);
695
+ });
696
+ return () => {
697
+ cancelled = true;
698
+ sub.remove();
699
+ };
700
+ }, []);
701
+
702
+ // Image-only picker mode: when the consumer restricts to image MIME types
703
+ // (e.g. avatar picker), photos grid is the more useful default view.
704
+ const isImageOnlyPicker = (0, _react.useMemo)(() => {
705
+ if (!selectMode) return false;
706
+ if (disabledMimeTypes.length === 0) return false;
707
+ const blocksVideos = disabledMimeTypes.some(mt => mt === 'video/' || mt.startsWith('video/'));
708
+ const blocksAudio = disabledMimeTypes.some(mt => mt === 'audio/' || mt.startsWith('audio/'));
709
+ const blocksDocs = disabledMimeTypes.some(mt => mt === 'application/pdf' || mt === 'application/' || mt.startsWith('application/'));
710
+ return blocksVideos && blocksAudio && blocksDocs;
711
+ }, [disabledMimeTypes, selectMode]);
712
+ const [viewMode, setViewMode] = (0, _react.useState)(isImageOnlyPicker ? 'photos' : 'all');
150
713
  const [searchQuery, setSearchQuery] = (0, _react.useState)('');
151
714
  const [sortBy, setSortBy] = (0, _react.useState)('date');
152
715
  const [sortOrder, setSortOrder] = (0, _react.useState)('desc');
@@ -210,7 +773,7 @@ const FileManagementScreen = ({
210
773
  if (disabledMimeTypes.length) {
211
774
  const blocked = disabledMimeTypes.some(mt => file.contentType === mt || file.contentType.startsWith(mt.endsWith('/') ? mt : `${mt}/`));
212
775
  if (blocked) {
213
- _sonner.toast.error(t('fileManagement.toasts.fileTypeBlocked'));
776
+ _bloom.toast.error(t('fileManagement.toasts.fileTypeBlocked'));
214
777
  return;
215
778
  }
216
779
  }
@@ -250,7 +813,7 @@ const FileManagementScreen = ({
250
813
  const already = next.has(file.id);
251
814
  if (!already) {
252
815
  if (maxSelection && next.size >= maxSelection) {
253
- _sonner.toast.error(t('fileManagement.toasts.maxSelection', {
816
+ _bloom.toast.error(t('fileManagement.toasts.maxSelection', {
254
817
  max: maxSelection
255
818
  }));
256
819
  return prev;
@@ -346,13 +909,13 @@ const FileManagementScreen = ({
346
909
  const response = await oxyServices.listUserFiles(currentPaging.limit, effectiveOffset);
347
910
  const assets = (response.files || []).map(f => ({
348
911
  id: f.id,
349
- filename: f.originalName || f.sha256,
350
- contentType: f.mime,
351
- length: f.size,
912
+ filename: f.originalName ?? f.sha256 ?? '',
913
+ contentType: f.mime ?? '',
914
+ length: f.size ?? 0,
352
915
  chunkSize: 0,
353
- uploadDate: f.createdAt,
354
- metadata: f.metadata || {},
355
- variants: f.variants || []
916
+ uploadDate: f.createdAt ?? '',
917
+ metadata: f.metadata ?? {},
918
+ variants: f.variants ?? []
356
919
  }));
357
920
  if (mode === 'more') {
358
921
  // append
@@ -379,7 +942,7 @@ const FileManagementScreen = ({
379
942
  }));
380
943
  }
381
944
  } catch (error) {
382
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.loadFailed'));
945
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.loadFailed'));
383
946
  } finally {
384
947
  setLoading(false);
385
948
  setRefreshing(false);
@@ -478,10 +1041,10 @@ const FileManagementScreen = ({
478
1041
  total: selectedFiles.length
479
1042
  });
480
1043
  const maxSize = 50 * 1024 * 1024; // 50MB
481
- const oversizedFiles = selectedFiles.filter(file => file.size > maxSize);
1044
+ const oversizedFiles = selectedFiles.filter(file => candidateSize(file) > maxSize);
482
1045
  if (oversizedFiles.length > 0) {
483
- const fileList = oversizedFiles.map(f => f.name).join(', ');
484
- _sonner.toast.error(t('fileManagement.toasts.filesTooLarge', {
1046
+ const fileList = oversizedFiles.map(f => candidateName(f, 'file')).join(', ');
1047
+ _bloom.toast.error(t('fileManagement.toasts.filesTooLarge', {
485
1048
  files: fileList
486
1049
  }));
487
1050
  return [];
@@ -495,12 +1058,14 @@ const FileManagementScreen = ({
495
1058
  total: selectedFiles.length
496
1059
  });
497
1060
  const raw = selectedFiles[i];
498
- const fileName = raw.name || `file-${i + 1}`;
1061
+ const fileName = candidateName(raw, `file-${i + 1}`);
1062
+ const fileSize = candidateSize(raw);
1063
+ const fileType = candidateType(raw);
499
1064
  const optimisticId = `temp-${Date.now()}-${i}-${Math.random().toString(36).substr(2, 9)}`; // Unique ID per file
500
1065
 
501
1066
  try {
502
1067
  // Validate file before upload
503
- if (!raw || !raw.name || raw.size === undefined || raw.size <= 0) {
1068
+ if (!raw || !fileName || fileSize <= 0) {
504
1069
  const errorMsg = `Invalid file: ${fileName}`;
505
1070
  if (__DEV__) {
506
1071
  console.error('Upload validation failed:', {
@@ -514,9 +1079,9 @@ const FileManagementScreen = ({
514
1079
  }
515
1080
  const optimisticFile = {
516
1081
  id: optimisticId,
517
- filename: raw.name,
518
- contentType: raw.type || 'application/octet-stream',
519
- length: raw.size,
1082
+ filename: fileName,
1083
+ contentType: fileType,
1084
+ length: fileSize,
520
1085
  chunkSize: 0,
521
1086
  uploadDate: new Date().toISOString(),
522
1087
  metadata: {
@@ -539,9 +1104,9 @@ const FileManagementScreen = ({
539
1104
  if (f) {
540
1105
  const merged = {
541
1106
  id: f.id,
542
- filename: f.originalName || f.sha256 || raw.name,
543
- contentType: f.mime || raw.type || 'application/octet-stream',
544
- length: f.size || raw.size,
1107
+ filename: f.originalName || f.sha256 || fileName,
1108
+ contentType: f.mime || fileType,
1109
+ length: f.size || fileSize,
545
1110
  chunkSize: 0,
546
1111
  uploadDate: f.createdAt || new Date().toISOString(),
547
1112
  metadata: f.metadata || {},
@@ -572,14 +1137,14 @@ const FileManagementScreen = ({
572
1137
  }
573
1138
  } catch (error) {
574
1139
  failureCount++;
575
- const errorMessage = getErrorMessage(error) || String(error) || 'Upload failed';
1140
+ const errorMessage = getErrorMessage(error) || 'Upload failed';
576
1141
  const fullError = `${fileName}: ${errorMessage}`;
577
1142
  errors.push(fullError);
578
1143
  if (__DEV__) {
579
1144
  console.error('File upload failed:', {
580
1145
  fileName,
581
- fileSize: raw.size,
582
- fileType: raw.type,
1146
+ fileSize,
1147
+ fileType,
583
1148
  error: errorMessage,
584
1149
  stack: error instanceof Error ? error.stack : undefined
585
1150
  });
@@ -592,14 +1157,14 @@ const FileManagementScreen = ({
592
1157
 
593
1158
  // Show success/error messages
594
1159
  if (successCount > 0) {
595
- _sonner.toast.success(t('fileManagement.toasts.uploadSuccess', {
1160
+ _bloom.toast.success(t('fileManagement.toasts.uploadSuccess', {
596
1161
  count: successCount
597
1162
  }));
598
1163
  }
599
1164
  if (failureCount > 0) {
600
1165
  // Show detailed error message with first few errors
601
1166
  const errorDetails = errors.length > 0 ? `\n${errors.slice(0, 3).join('\n')}${errors.length > 3 ? `\n...and ${errors.length - 3} more` : ''}` : '';
602
- _sonner.toast.error(`${t('fileManagement.toasts.uploadFailed', {
1167
+ _bloom.toast.error(`${t('fileManagement.toasts.uploadFailed', {
603
1168
  count: failureCount
604
1169
  })}${errorDetails}`);
605
1170
  }
@@ -608,14 +1173,12 @@ const FileManagementScreen = ({
608
1173
  loadFiles('silent');
609
1174
  }, 1200);
610
1175
  } catch (error) {
611
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.uploadError'));
1176
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.uploadError'));
612
1177
  } finally {
613
1178
  storeSetUploadProgress(null);
614
1179
  }
615
1180
  return uploadedFiles;
616
1181
  };
617
-
618
- // biome-ignore lint/suspicious/noExplicitAny: Files from document picker may have extra properties like uri
619
1182
  const handleFileSelection = (0, _react.useCallback)(async selectedFiles => {
620
1183
  const MAX_FILE_SIZE = 100 * 1024 * 1024; // 100MB
621
1184
  const processedFiles = [];
@@ -625,58 +1188,58 @@ const FileManagementScreen = ({
625
1188
  if (__DEV__) {
626
1189
  console.error('Invalid file: file is null or undefined');
627
1190
  }
628
- _sonner.toast.error(t('fileManagement.toasts.invalidFileMissing'));
1191
+ _bloom.toast.error(t('fileManagement.toasts.invalidFileMissing'));
629
1192
  continue;
630
1193
  }
631
- if (!file.name || typeof file.name !== 'string') {
1194
+ const name = candidateName(file, '');
1195
+ if (!name) {
632
1196
  if (__DEV__) {
633
1197
  console.error('Invalid file: missing or invalid name property', file);
634
1198
  }
635
- _sonner.toast.error(t('fileManagement.toasts.invalidFileName'));
1199
+ _bloom.toast.error(t('fileManagement.toasts.invalidFileName'));
636
1200
  continue;
637
1201
  }
638
- if (file.size === undefined || file.size === null || Number.isNaN(file.size)) {
1202
+ const size = file.size;
1203
+ if (size === undefined || size === null || Number.isNaN(size)) {
639
1204
  if (__DEV__) {
640
1205
  console.error('Invalid file: missing or invalid size property', file);
641
1206
  }
642
- _sonner.toast.error(t('fileManagement.toasts.invalidFileSize', {
643
- name: file.name || 'unknown'
1207
+ _bloom.toast.error(t('fileManagement.toasts.invalidFileSize', {
1208
+ name
644
1209
  }));
645
1210
  continue;
646
1211
  }
647
- if (file.size <= 0) {
1212
+ if (size <= 0) {
648
1213
  if (__DEV__) {
649
1214
  console.error('Invalid file: file size is zero or negative', file);
650
1215
  }
651
- _sonner.toast.error(t('fileManagement.toasts.fileEmpty', {
652
- name: file.name
1216
+ _bloom.toast.error(t('fileManagement.toasts.fileEmpty', {
1217
+ name
653
1218
  }));
654
1219
  continue;
655
1220
  }
656
1221
 
657
1222
  // Validate file size
658
- if (file.size > MAX_FILE_SIZE) {
659
- _sonner.toast.error(t('fileManagement.toasts.fileTooLarge', {
660
- name: file.name,
1223
+ if (size > MAX_FILE_SIZE) {
1224
+ _bloom.toast.error(t('fileManagement.toasts.fileTooLarge', {
1225
+ name,
661
1226
  maxSize: (0, _fileManagement.formatFileSize)(MAX_FILE_SIZE)
662
1227
  }));
663
1228
  continue;
664
1229
  }
665
-
666
- // Ensure file has a type property
667
- const fileType = file.type || 'application/octet-stream';
1230
+ const fileType = candidateType(file);
668
1231
 
669
1232
  // Generate preview for images - unified approach
670
1233
  let preview;
671
1234
  if (fileType.startsWith('image/')) {
672
1235
  // Try to use file URI from expo-document-picker if available (works on all platforms)
673
- const fileUri = file.uri;
674
- if (fileUri && typeof fileUri === 'string' && (fileUri.startsWith('file://') || fileUri.startsWith('content://') || fileUri.startsWith('http://') || fileUri.startsWith('https://') || fileUri.startsWith('blob:'))) {
1236
+ const fileUri = candidateUri(file);
1237
+ if (fileUri && (fileUri.startsWith('file://') || fileUri.startsWith('content://') || fileUri.startsWith('http://') || fileUri.startsWith('https://') || fileUri.startsWith('blob:'))) {
675
1238
  preview = fileUri;
676
1239
  } else {
677
- // Fallback: create blob URL if possible (works on web)
1240
+ // Fallback: create blob URL if possible (works on web only)
678
1241
  try {
679
- if (file instanceof File || file instanceof Blob) {
1242
+ if (typeof File !== 'undefined' && file instanceof File || typeof Blob !== 'undefined' && file instanceof Blob) {
680
1243
  preview = URL.createObjectURL(file);
681
1244
  }
682
1245
  } catch (error) {
@@ -690,20 +1253,20 @@ const FileManagementScreen = ({
690
1253
  processedFiles.push({
691
1254
  file,
692
1255
  preview,
693
- size: file.size,
694
- name: file.name,
1256
+ size,
1257
+ name,
695
1258
  type: fileType
696
1259
  });
697
1260
  }
698
1261
  if (processedFiles.length === 0) {
699
- _sonner.toast.error(t('fileManagement.toasts.noValidFiles'));
1262
+ _bloom.toast.error(t('fileManagement.toasts.noValidFiles'));
700
1263
  return;
701
1264
  }
702
1265
 
703
1266
  // Show preview modal for user to review files before upload
704
1267
  setPendingFiles(processedFiles);
705
1268
  setShowUploadPreview(true);
706
- }, []);
1269
+ }, [t]);
707
1270
  const handleConfirmUpload = async () => {
708
1271
  if (pendingFiles.length === 0) return;
709
1272
  setShowUploadPreview(false);
@@ -751,7 +1314,7 @@ const FileManagementScreen = ({
751
1314
  }
752
1315
  endUpload();
753
1316
  } catch (error) {
754
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.uploadError'));
1317
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.uploadError'));
755
1318
  endUpload();
756
1319
  }
757
1320
  };
@@ -784,7 +1347,7 @@ const FileManagementScreen = ({
784
1347
  const handleFileUpload = async () => {
785
1348
  // Prevent concurrent document picker calls
786
1349
  if (isPickingDocument) {
787
- _sonner.toast.error(t('fileManagement.toasts.waitForSelection'));
1350
+ _bloom.toast.error(t('fileManagement.toasts.waitForSelection'));
788
1351
  return;
789
1352
  }
790
1353
  try {
@@ -806,7 +1369,7 @@ const FileManagementScreen = ({
806
1369
  }
807
1370
  if (!result.assets || result.assets.length === 0) {
808
1371
  setIsPickingDocument(false);
809
- _sonner.toast.error(t('fileManagement.toasts.noFilesSelected'));
1372
+ _bloom.toast.error(t('fileManagement.toasts.noFilesSelected'));
810
1373
  return;
811
1374
  }
812
1375
 
@@ -848,7 +1411,7 @@ const FileManagementScreen = ({
848
1411
  // Show errors if any
849
1412
  if (errors.length > 0) {
850
1413
  const errorMessage = errors.slice(0, 3).join('\n') + (errors.length > 3 ? `\n...and ${errors.length - 3} more` : '');
851
- _sonner.toast.error(t('fileManagement.toasts.loadSomeFailed', {
1414
+ _bloom.toast.error(t('fileManagement.toasts.loadSomeFailed', {
852
1415
  errors: errorMessage
853
1416
  }));
854
1417
  }
@@ -858,7 +1421,7 @@ const FileManagementScreen = ({
858
1421
  await handleFileSelection(files);
859
1422
  } else {
860
1423
  // Files were selected but none could be converted
861
- _sonner.toast.error(t('fileManagement.toasts.noFilesProcessed'));
1424
+ _bloom.toast.error(t('fileManagement.toasts.noFilesProcessed'));
862
1425
  }
863
1426
  } catch (error) {
864
1427
  if (__DEV__) {
@@ -866,12 +1429,12 @@ const FileManagementScreen = ({
866
1429
  }
867
1430
  if (getErrorMessage(error)?.includes('expo-document-picker') || getErrorMessage(error)?.includes('Different document picking in progress')) {
868
1431
  if (getErrorMessage(error)?.includes('Different document picking in progress')) {
869
- _sonner.toast.error(t('fileManagement.toasts.waitForSelection'));
1432
+ _bloom.toast.error(t('fileManagement.toasts.waitForSelection'));
870
1433
  } else {
871
- _sonner.toast.error(t('fileManagement.toasts.filePickerNotAvailable'));
1434
+ _bloom.toast.error(t('fileManagement.toasts.filePickerNotAvailable'));
872
1435
  }
873
1436
  } else {
874
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.selectFilesFailed'));
1437
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.selectFilesFailed'));
875
1438
  }
876
1439
  } finally {
877
1440
  // Always reset the picking state, even if there was an error
@@ -883,8 +1446,8 @@ const FileManagementScreen = ({
883
1446
  id: fileId,
884
1447
  name: filename
885
1448
  });
886
- fileDeletePrompt.open();
887
- }, [fileDeletePrompt]);
1449
+ fileDeleteDialog.open();
1450
+ }, [fileDeleteDialog]);
888
1451
  const handleFileDelete = (0, _react.useCallback)(async () => {
889
1452
  if (!pendingDeleteFile) return;
890
1453
  const {
@@ -893,7 +1456,7 @@ const FileManagementScreen = ({
893
1456
  try {
894
1457
  storeSetDeleting(fileId);
895
1458
  await oxyServices.deleteFile(fileId);
896
- _sonner.toast.success(t('fileManagement.toasts.deleteSuccess'));
1459
+ _bloom.toast.success(t('fileManagement.toasts.deleteSuccess'));
897
1460
 
898
1461
  // Reload files after successful deletion
899
1462
  // Optimistic remove
@@ -903,13 +1466,13 @@ const FileManagementScreen = ({
903
1466
  } catch (error) {
904
1467
  // Provide specific error messages
905
1468
  if (getErrorMessage(error)?.includes('File not found') || getErrorMessage(error)?.includes('404')) {
906
- _sonner.toast.error(t('fileManagement.toasts.fileNotFound'));
1469
+ _bloom.toast.error(t('fileManagement.toasts.fileNotFound'));
907
1470
  // Still reload files to refresh the list
908
1471
  setTimeout(() => loadFiles('silent'), 800);
909
1472
  } else if (getErrorMessage(error)?.includes('permission') || getErrorMessage(error)?.includes('403')) {
910
- _sonner.toast.error(t('fileManagement.toasts.noPermission'));
1473
+ _bloom.toast.error(t('fileManagement.toasts.noPermission'));
911
1474
  } else {
912
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.deleteFailed'));
1475
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.deleteFailed'));
913
1476
  }
914
1477
  } finally {
915
1478
  storeSetDeleting(null);
@@ -918,8 +1481,8 @@ const FileManagementScreen = ({
918
1481
  }, [pendingDeleteFile, storeSetDeleting, oxyServices, loadFiles, t]);
919
1482
  const confirmBulkDelete = (0, _react.useCallback)(() => {
920
1483
  if (selectedIds.size === 0) return;
921
- bulkDeletePrompt.open();
922
- }, [selectedIds.size, bulkDeletePrompt]);
1484
+ bulkDeleteDialog.open();
1485
+ }, [selectedIds.size, bulkDeleteDialog]);
923
1486
  const handleBulkDelete = (0, _react.useCallback)(async () => {
924
1487
  if (selectedIds.size === 0) return;
925
1488
  try {
@@ -943,19 +1506,19 @@ const FileManagementScreen = ({
943
1506
  const successful = results.filter(r => r.status === 'fulfilled' && r.value.success).length;
944
1507
  const failed = results.length - successful;
945
1508
  if (successful > 0) {
946
- _sonner.toast.success(t('fileManagement.toasts.bulkDeleteSuccess', {
1509
+ _bloom.toast.success(t('fileManagement.toasts.bulkDeleteSuccess', {
947
1510
  count: successful
948
1511
  }));
949
1512
  }
950
1513
  if (failed > 0) {
951
- _sonner.toast.error(t('fileManagement.toasts.bulkDeleteFailed', {
1514
+ _bloom.toast.error(t('fileManagement.toasts.bulkDeleteFailed', {
952
1515
  count: failed
953
1516
  }));
954
1517
  }
955
1518
  setSelectedIds(new Set());
956
1519
  setTimeout(() => loadFiles('silent'), 800);
957
1520
  } catch (error) {
958
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.bulkDeleteError'));
1521
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.bulkDeleteError'));
959
1522
  }
960
1523
  }, [selectedIds, files, oxyServices, loadFiles]);
961
1524
  const handleBulkVisibilityChange = (0, _react.useCallback)(async visibility => {
@@ -980,7 +1543,7 @@ const FileManagementScreen = ({
980
1543
  const successful = results.filter(r => r.status === 'fulfilled' && r.value.success).length;
981
1544
  const failed = results.length - successful;
982
1545
  if (successful > 0) {
983
- _sonner.toast.success(t('fileManagement.toasts.visibilitySuccess', {
1546
+ _bloom.toast.success(t('fileManagement.toasts.visibilitySuccess', {
984
1547
  count: successful,
985
1548
  visibility
986
1549
  }));
@@ -995,13 +1558,13 @@ const FileManagementScreen = ({
995
1558
  });
996
1559
  }
997
1560
  if (failed > 0) {
998
- _sonner.toast.error(t('fileManagement.toasts.visibilityFailed', {
1561
+ _bloom.toast.error(t('fileManagement.toasts.visibilityFailed', {
999
1562
  count: failed
1000
1563
  }));
1001
1564
  }
1002
1565
  setTimeout(() => loadFiles('silent'), 800);
1003
1566
  } catch (error) {
1004
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.visibilityError'));
1567
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.visibilityError'));
1005
1568
  }
1006
1569
  }, [selectedIds, oxyServices, files, loadFiles]);
1007
1570
 
@@ -1023,7 +1586,7 @@ const FileManagementScreen = ({
1023
1586
  document.body.appendChild(link);
1024
1587
  link.click();
1025
1588
  document.body.removeChild(link);
1026
- _sonner.toast.success(t('fileManagement.toasts.downloadStarted'));
1589
+ _bloom.toast.success(t('fileManagement.toasts.downloadStarted'));
1027
1590
  } catch (linkError) {
1028
1591
  // Fallback to authenticated download
1029
1592
  const blob = await oxyServices.getFileContentAsBlob(fileId);
@@ -1037,16 +1600,16 @@ const FileManagementScreen = ({
1037
1600
 
1038
1601
  // Clean up the blob URL
1039
1602
  URL.revokeObjectURL(url);
1040
- _sonner.toast.success(t('fileManagement.toasts.downloadSuccess'));
1603
+ _bloom.toast.success(t('fileManagement.toasts.downloadSuccess'));
1041
1604
  }
1042
1605
  } else {
1043
1606
  // For mobile, open the URL (user can save from browser)
1044
1607
  // Note: This is a simplified approach - for full mobile support,
1045
1608
  // consider using expo-file-system or react-native-fs
1046
- _sonner.toast.info(t('fileManagement.toasts.downloadMobile'));
1609
+ _bloom.toast.info(t('fileManagement.toasts.downloadMobile'));
1047
1610
  }
1048
1611
  } catch (error) {
1049
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.downloadFailed'));
1612
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.downloadFailed'));
1050
1613
  }
1051
1614
  };
1052
1615
  const handleFileOpen = async file => {
@@ -1072,9 +1635,9 @@ const FileManagementScreen = ({
1072
1635
  }
1073
1636
  } catch (error) {
1074
1637
  if (getErrorMessage(error)?.includes('404') || getErrorMessage(error)?.includes('not found')) {
1075
- _sonner.toast.error(t('fileManagement.toasts.fileNotFoundContent'));
1638
+ _bloom.toast.error(t('fileManagement.toasts.fileNotFoundContent'));
1076
1639
  } else {
1077
- _sonner.toast.error(t('fileManagement.toasts.loadContentFailed'));
1640
+ _bloom.toast.error(t('fileManagement.toasts.loadContentFailed'));
1078
1641
  }
1079
1642
  setFileContent(null);
1080
1643
  }
@@ -1083,7 +1646,7 @@ const FileManagementScreen = ({
1083
1646
  setFileContent(null);
1084
1647
  }
1085
1648
  } catch (error) {
1086
- _sonner.toast.error(getErrorMessage(error) || t('fileManagement.toasts.openFailed'));
1649
+ _bloom.toast.error(getErrorMessage(error) || t('fileManagement.toasts.openFailed'));
1087
1650
  } finally {
1088
1651
  setLoadingFileContent(false);
1089
1652
  }
@@ -1985,6 +2548,51 @@ const FileManagementScreen = ({
1985
2548
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(SkeletonLoader, {});
1986
2549
  }
1987
2550
 
2551
+ // Dedicated flagship-style photo picker view used in the avatar-picker
2552
+ // context (selectMode + image-only filter). The picker is intentionally
2553
+ // minimal: black backdrop, edge-to-edge grid, translucent header. The
2554
+ // standalone file manager (non-picker browse) keeps the existing UI.
2555
+ if (isImageOnlyPicker && !showUploadPreview) {
2556
+ const photosOnly = filteredFiles.filter(file => file.contentType.startsWith('image/'));
2557
+ const isOwner = user?.id === targetUserId;
2558
+ const allowUpload = isOwner && allowUploadInSelectMode;
2559
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
2560
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(PhotoPickerView, {
2561
+ photos: photosOnly,
2562
+ selectedIds: selectedIds,
2563
+ multiSelect: multiSelect,
2564
+ maxSelection: maxSelection,
2565
+ allowUpload: allowUpload,
2566
+ refreshing: refreshing,
2567
+ uploading: uploading,
2568
+ isPickingDocument: isPickingDocument,
2569
+ uploadProgress: uploadProgress,
2570
+ hasMore: paging.hasMore,
2571
+ loadingMore: paging.loadingMore,
2572
+ reduceMotion: reduceMotion,
2573
+ getThumbUrl: getSafeDownloadUrlCallback,
2574
+ primaryColor: colors.primary,
2575
+ isOwner: isOwner,
2576
+ onTogglePhoto: toggleSelect,
2577
+ onPreviewPhoto: file => showFileDetailsModal(file),
2578
+ onUpload: handleFileUpload,
2579
+ onRefresh: () => loadFiles('refresh'),
2580
+ onLoadMore: () => loadFiles('more'),
2581
+ onCancel: () => {
2582
+ if (onClose) onClose();else goBack?.();
2583
+ },
2584
+ onConfirm: confirmMultiSelection,
2585
+ t: t
2586
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_FileDetailsModal.FileDetailsModal, {
2587
+ control: fileDetailsControl,
2588
+ file: selectedFile,
2589
+ onDownload: handleFileDownload,
2590
+ onDelete: confirmFileDelete,
2591
+ isOwner: isOwner
2592
+ })]
2593
+ });
2594
+ }
2595
+
1988
2596
  // If a file is opened, show the file viewer
1989
2597
  if (!selectMode && openedFile) {
1990
2598
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
@@ -2072,7 +2680,7 @@ const FileManagementScreen = ({
2072
2680
  key: 'visibility',
2073
2681
  text: t('fileManagement.visibility'),
2074
2682
  onPress: () => {
2075
- visibilityChangePrompt.open();
2683
+ visibilityChangeDialog.open();
2076
2684
  },
2077
2685
  icon: 'eye'
2078
2686
  }] : undefined,
@@ -2097,41 +2705,53 @@ const FileManagementScreen = ({
2097
2705
  icon: viewMode === 'all' ? 'folder' : 'folder-outline',
2098
2706
  primaryColor: colors.primary,
2099
2707
  textColor: colors.text,
2100
- style: _styles.fileManagementStyles.viewModeButton
2708
+ style: _styles.fileManagementStyles.viewModeButton,
2709
+ accessibilityLabel: t('fileManagement.a11y.viewAll') || 'Show all files'
2101
2710
  }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2102
2711
  isSelected: viewMode === 'photos',
2103
2712
  onPress: () => setViewMode('photos'),
2104
2713
  icon: viewMode === 'photos' ? 'image-multiple' : 'image-multiple-outline',
2105
2714
  primaryColor: colors.primary,
2106
2715
  textColor: colors.text,
2107
- style: _styles.fileManagementStyles.viewModeButton
2108
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2109
- isSelected: viewMode === 'videos',
2110
- onPress: () => setViewMode('videos'),
2111
- icon: viewMode === 'videos' ? 'video' : 'video-outline',
2112
- primaryColor: colors.primary,
2113
- textColor: colors.text,
2114
- style: _styles.fileManagementStyles.viewModeButton
2115
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2116
- isSelected: viewMode === 'documents',
2117
- onPress: () => setViewMode('documents'),
2118
- icon: viewMode === 'documents' ? 'file-document' : 'file-document-outline',
2119
- primaryColor: colors.primary,
2120
- textColor: colors.text,
2121
- style: _styles.fileManagementStyles.viewModeButton
2122
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2123
- isSelected: viewMode === 'audio',
2124
- onPress: () => setViewMode('audio'),
2125
- icon: viewMode === 'audio' ? 'music-note' : 'music-note-outline',
2126
- primaryColor: colors.primary,
2127
- textColor: colors.text,
2128
- style: _styles.fileManagementStyles.viewModeButton
2716
+ style: _styles.fileManagementStyles.viewModeButton,
2717
+ accessibilityLabel: t('fileManagement.a11y.viewPhotos') || 'Show photos only'
2718
+ }), !isImageOnlyPicker && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
2719
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2720
+ isSelected: viewMode === 'videos',
2721
+ onPress: () => setViewMode('videos'),
2722
+ icon: viewMode === 'videos' ? 'video' : 'video-outline',
2723
+ primaryColor: colors.primary,
2724
+ textColor: colors.text,
2725
+ style: _styles.fileManagementStyles.viewModeButton,
2726
+ accessibilityLabel: t('fileManagement.a11y.viewVideos') || 'Show videos only'
2727
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2728
+ isSelected: viewMode === 'documents',
2729
+ onPress: () => setViewMode('documents'),
2730
+ icon: viewMode === 'documents' ? 'file-document' : 'file-document-outline',
2731
+ primaryColor: colors.primary,
2732
+ textColor: colors.text,
2733
+ style: _styles.fileManagementStyles.viewModeButton,
2734
+ accessibilityLabel: t('fileManagement.a11y.viewDocuments') || 'Show documents only'
2735
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(AnimatedButton, {
2736
+ isSelected: viewMode === 'audio',
2737
+ onPress: () => setViewMode('audio'),
2738
+ icon: viewMode === 'audio' ? 'music-note' : 'music-note-outline',
2739
+ primaryColor: colors.primary,
2740
+ textColor: colors.text,
2741
+ style: _styles.fileManagementStyles.viewModeButton,
2742
+ accessibilityLabel: t('fileManagement.a11y.viewAudio') || 'Show audio only'
2743
+ })]
2129
2744
  })]
2130
2745
  })
2131
2746
  }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
2132
2747
  style: [_styles.fileManagementStyles.sortButton, {
2133
2748
  backgroundColor: colors.card
2134
2749
  }],
2750
+ accessibilityRole: "button",
2751
+ accessibilityLabel: t('fileManagement.a11y.sortBy', {
2752
+ field: sortBy,
2753
+ order: sortOrder === 'asc' ? 'ascending' : 'descending'
2754
+ }) || `Sort by ${sortBy}, ${sortOrder === 'asc' ? 'ascending' : 'descending'}`,
2135
2755
  onPress: () => {
2136
2756
  // Cycle through sort options: date -> size -> name -> type -> date
2137
2757
  const sortOrder = ['date', 'size', 'name', 'type'];
@@ -2153,11 +2773,16 @@ const FileManagementScreen = ({
2153
2773
  color: colors.textSecondary
2154
2774
  })]
2155
2775
  }), user?.id === targetUserId && (!selectMode || selectMode && allowUploadInSelectMode) && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
2156
- style: [_styles.fileManagementStyles.uploadButton, {
2776
+ style: [_styles.fileManagementStyles.uploadButton, isImageOnlyPicker && _styles.fileManagementStyles.uploadButtonExtended, {
2157
2777
  backgroundColor: colors.primary
2158
2778
  }],
2159
2779
  onPress: handleFileUpload,
2160
2780
  disabled: uploading || isPickingDocument,
2781
+ accessibilityRole: "button",
2782
+ accessibilityLabel: isImageOnlyPicker ? t('fileManagement.a11y.uploadFromDevice') || 'Upload photo from device' : t('fileManagement.a11y.uploadFile') || 'Upload file',
2783
+ accessibilityState: {
2784
+ busy: uploading || isPickingDocument
2785
+ },
2161
2786
  children: uploading ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
2162
2787
  style: _styles.fileManagementStyles.uploadProgress,
2163
2788
  children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {
@@ -2170,6 +2795,17 @@ const FileManagementScreen = ({
2170
2795
  }) : isPickingDocument ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {
2171
2796
  size: "small",
2172
2797
  color: "#FFFFFF"
2798
+ }) : isImageOnlyPicker ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
2799
+ style: _styles.fileManagementStyles.uploadButtonContent,
2800
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_vectorIcons.Ionicons, {
2801
+ name: "cloud-upload",
2802
+ size: 18,
2803
+ color: "#FFFFFF"
2804
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
2805
+ style: _styles.fileManagementStyles.uploadButtonLabel,
2806
+ numberOfLines: 1,
2807
+ children: t('fileManagement.upload') || 'Upload'
2808
+ })]
2173
2809
  }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_vectorIcons.Ionicons, {
2174
2810
  name: "add",
2175
2811
  size: 22,
@@ -2365,51 +3001,53 @@ const FileManagementScreen = ({
2365
3001
  color: colors.primary
2366
3002
  })]
2367
3003
  })
2368
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.Basic, {
2369
- control: fileDeletePrompt,
3004
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_bloom.Dialog, {
3005
+ control: fileDeleteDialog,
2370
3006
  title: t('fileManagement.deleteFile') || 'Delete File',
2371
3007
  description: pendingDeleteFile ? t('fileManagement.confirms.deleteFile', {
2372
3008
  filename: pendingDeleteFile.name
2373
3009
  }) : '',
2374
- onConfirm: handleFileDelete,
2375
- confirmButtonCta: t('fileManagement.confirm') || 'Delete',
2376
- confirmButtonColor: "negative"
2377
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.Basic, {
2378
- control: bulkDeletePrompt,
3010
+ actions: [{
3011
+ label: t('fileManagement.confirm') || 'Delete',
3012
+ color: 'destructive',
3013
+ onPress: handleFileDelete
3014
+ }, {
3015
+ label: t('common.cancel') || 'Cancel',
3016
+ color: 'cancel'
3017
+ }]
3018
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_bloom.Dialog, {
3019
+ control: bulkDeleteDialog,
2379
3020
  title: t('fileManagement.deleteFiles') || 'Delete Files',
2380
3021
  description: t('fileManagement.confirms.deleteFiles', {
2381
3022
  count: selectedIds.size
2382
3023
  }),
2383
- onConfirm: handleBulkDelete,
2384
- confirmButtonCta: t('fileManagement.confirm') || 'Delete',
2385
- confirmButtonColor: "negative"
2386
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(Prompt.Outer, {
2387
- control: visibilityChangePrompt,
2388
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(Prompt.Content, {
2389
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.TitleText, {
2390
- children: t('fileManagement.changeVisibility') || 'Change Visibility'
2391
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.DescriptionText, {
2392
- children: t('fileManagement.changeVisibilityConfirm', {
2393
- count: selectedIds.size
2394
- })
2395
- })]
2396
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(Prompt.Actions, {
2397
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.Action, {
2398
- cta: t('fileManagement.private') || 'Private',
2399
- onPress: () => handleBulkVisibilityChange('private'),
2400
- color: "primary"
2401
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.Action, {
2402
- cta: t('fileManagement.public') || 'Public',
2403
- onPress: () => handleBulkVisibilityChange('public'),
2404
- color: "primary_subtle"
2405
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.Action, {
2406
- cta: t('fileManagement.unlisted') || 'Unlisted',
2407
- onPress: () => handleBulkVisibilityChange('unlisted'),
2408
- color: "primary_subtle"
2409
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(Prompt.Cancel, {
2410
- cta: t('common.cancel') || 'Cancel'
2411
- })]
2412
- })]
3024
+ actions: [{
3025
+ label: t('fileManagement.confirm') || 'Delete',
3026
+ color: 'destructive',
3027
+ onPress: handleBulkDelete
3028
+ }, {
3029
+ label: t('common.cancel') || 'Cancel',
3030
+ color: 'cancel'
3031
+ }]
3032
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_bloom.Dialog, {
3033
+ control: visibilityChangeDialog,
3034
+ title: t('fileManagement.changeVisibility') || 'Change Visibility',
3035
+ description: t('fileManagement.changeVisibilityConfirm', {
3036
+ count: selectedIds.size
3037
+ }),
3038
+ actions: [{
3039
+ label: t('fileManagement.private') || 'Private',
3040
+ onPress: () => handleBulkVisibilityChange('private')
3041
+ }, {
3042
+ label: t('fileManagement.public') || 'Public',
3043
+ onPress: () => handleBulkVisibilityChange('public')
3044
+ }, {
3045
+ label: t('fileManagement.unlisted') || 'Unlisted',
3046
+ onPress: () => handleBulkVisibilityChange('unlisted')
3047
+ }, {
3048
+ label: t('common.cancel') || 'Cancel',
3049
+ color: 'cancel'
3050
+ }]
2413
3051
  })]
2414
3052
  });
2415
3053
  };