@oxyhq/services 22.8.7 → 22.10.0

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 (502) hide show
  1. package/lib/commonjs/index.js +24 -5
  2. package/lib/commonjs/index.js.map +1 -1
  3. package/lib/commonjs/ui/components/OxyAccountDialogScreen.js +150 -0
  4. package/lib/commonjs/ui/components/OxyAccountDialogScreen.js.map +1 -0
  5. package/lib/commonjs/ui/components/OxyAuthChooser.js +137 -40
  6. package/lib/commonjs/ui/components/OxyAuthChooser.js.map +1 -1
  7. package/lib/commonjs/ui/components/OxyConsentScreen.js +1 -1
  8. package/lib/commonjs/ui/components/OxyProvider.js +9 -29
  9. package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
  10. package/lib/commonjs/ui/components/ProfileButton.js +1 -1
  11. package/lib/commonjs/ui/components/RequireOxyAuth.js +1 -1
  12. package/lib/commonjs/ui/components/SurfaceHeaderAction.js +63 -0
  13. package/lib/commonjs/ui/components/SurfaceHeaderAction.js.map +1 -0
  14. package/lib/commonjs/ui/components/SurfaceScreen.js +193 -0
  15. package/lib/commonjs/ui/components/SurfaceScreen.js.map +1 -0
  16. package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js +46 -29
  17. package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
  18. package/lib/commonjs/ui/components/modals/DeleteAccountModal.js +47 -23
  19. package/lib/commonjs/ui/components/modals/DeleteAccountModal.js.map +1 -1
  20. package/lib/commonjs/ui/components/oxyAuthChooserStyles.js +22 -12
  21. package/lib/commonjs/ui/components/oxyAuthChooserStyles.js.map +1 -1
  22. package/lib/commonjs/ui/components/surfaces/ActionSheetSurface.js +83 -0
  23. package/lib/commonjs/ui/components/surfaces/ActionSheetSurface.js.map +1 -0
  24. package/lib/commonjs/ui/context/OxyContext.js +49 -4
  25. package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
  26. package/lib/commonjs/ui/hooks/useAvatarPicker.js +34 -39
  27. package/lib/commonjs/ui/hooks/useAvatarPicker.js.map +1 -1
  28. package/lib/commonjs/ui/hooks/useSurfaceHeader.js +46 -0
  29. package/lib/commonjs/ui/hooks/useSurfaceHeader.js.map +1 -0
  30. package/lib/commonjs/ui/hooks/useSwitchableAccounts.js +1 -1
  31. package/lib/commonjs/ui/navigation/accountDialogManager.js +14 -2
  32. package/lib/commonjs/ui/navigation/accountDialogManager.js.map +1 -1
  33. package/lib/commonjs/ui/navigation/bottomSheetManager.js +38 -56
  34. package/lib/commonjs/ui/navigation/bottomSheetManager.js.map +1 -1
  35. package/lib/commonjs/ui/navigation/routes.js +7 -57
  36. package/lib/commonjs/ui/navigation/routes.js.map +1 -1
  37. package/lib/commonjs/ui/navigation/surfaceBackBridge.js +68 -0
  38. package/lib/commonjs/ui/navigation/surfaceBackBridge.js.map +1 -0
  39. package/lib/commonjs/ui/navigation/surfaceNavStack.js +98 -0
  40. package/lib/commonjs/ui/navigation/surfaceNavStack.js.map +1 -0
  41. package/lib/commonjs/ui/navigation/surfaceRegistry.js +152 -0
  42. package/lib/commonjs/ui/navigation/surfaceRegistry.js.map +1 -0
  43. package/lib/commonjs/ui/navigation/surfaces.js +256 -0
  44. package/lib/commonjs/ui/navigation/surfaces.js.map +1 -0
  45. package/lib/commonjs/ui/screens/AccountMembersScreen.js +214 -283
  46. package/lib/commonjs/ui/screens/AccountMembersScreen.js.map +1 -1
  47. package/lib/commonjs/ui/screens/AccountSettingsScreen.js +88 -118
  48. package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
  49. package/lib/commonjs/ui/screens/AccountVerificationScreen.js +22 -36
  50. package/lib/commonjs/ui/screens/AccountVerificationScreen.js.map +1 -1
  51. package/lib/commonjs/ui/screens/AppInfoScreen.js +219 -226
  52. package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
  53. package/lib/commonjs/ui/screens/AvatarCropScreen.js +10 -14
  54. package/lib/commonjs/ui/screens/AvatarCropScreen.js.map +1 -1
  55. package/lib/commonjs/ui/screens/ConnectedAppsScreen.js +24 -39
  56. package/lib/commonjs/ui/screens/ConnectedAppsScreen.js.map +1 -1
  57. package/lib/commonjs/ui/screens/CreateAccountScreen.js +136 -158
  58. package/lib/commonjs/ui/screens/CreateAccountScreen.js.map +1 -1
  59. package/lib/commonjs/ui/screens/EditProfileFieldScreen.js +29 -36
  60. package/lib/commonjs/ui/screens/EditProfileFieldScreen.js.map +1 -1
  61. package/lib/commonjs/ui/screens/EditProfileScreen.js +101 -109
  62. package/lib/commonjs/ui/screens/EditProfileScreen.js.map +1 -1
  63. package/lib/commonjs/ui/screens/FAQScreen.js +10 -15
  64. package/lib/commonjs/ui/screens/FAQScreen.js.map +1 -1
  65. package/lib/commonjs/ui/screens/FeedbackScreen.js +8 -16
  66. package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
  67. package/lib/commonjs/ui/screens/FileManagementScreen.js +219 -206
  68. package/lib/commonjs/ui/screens/FileManagementScreen.js.map +1 -1
  69. package/lib/commonjs/ui/screens/HelpSupportScreen.js +62 -69
  70. package/lib/commonjs/ui/screens/HelpSupportScreen.js.map +1 -1
  71. package/lib/commonjs/ui/screens/HistoryViewScreen.js +63 -79
  72. package/lib/commonjs/ui/screens/HistoryViewScreen.js.map +1 -1
  73. package/lib/commonjs/ui/screens/LanguageSelectorScreen.js +69 -98
  74. package/lib/commonjs/ui/screens/LanguageSelectorScreen.js.map +1 -1
  75. package/lib/commonjs/ui/screens/LearnMoreUsernamesScreen.js +8 -14
  76. package/lib/commonjs/ui/screens/LearnMoreUsernamesScreen.js.map +1 -1
  77. package/lib/commonjs/ui/screens/LegalDocumentsScreen.js +77 -94
  78. package/lib/commonjs/ui/screens/LegalDocumentsScreen.js.map +1 -1
  79. package/lib/commonjs/ui/screens/ManageAccountScreen.js +99 -134
  80. package/lib/commonjs/ui/screens/ManageAccountScreen.js.map +1 -1
  81. package/lib/commonjs/ui/screens/NotificationsScreen.js +69 -76
  82. package/lib/commonjs/ui/screens/NotificationsScreen.js.map +1 -1
  83. package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +3 -8
  84. package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -1
  85. package/lib/commonjs/ui/screens/PreferencesScreen.js +67 -74
  86. package/lib/commonjs/ui/screens/PreferencesScreen.js.map +1 -1
  87. package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js +55 -91
  88. package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
  89. package/lib/commonjs/ui/screens/PrivacySettingsScreen.js +291 -304
  90. package/lib/commonjs/ui/screens/PrivacySettingsScreen.js.map +1 -1
  91. package/lib/commonjs/ui/screens/ProfileScreen.js +100 -114
  92. package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
  93. package/lib/commonjs/ui/screens/SavesCollectionsScreen.js +38 -45
  94. package/lib/commonjs/ui/screens/SavesCollectionsScreen.js.map +1 -1
  95. package/lib/commonjs/ui/screens/SearchSettingsScreen.js +44 -57
  96. package/lib/commonjs/ui/screens/SearchSettingsScreen.js.map +1 -1
  97. package/lib/commonjs/ui/screens/UserLinksScreen.js +24 -31
  98. package/lib/commonjs/ui/screens/UserLinksScreen.js.map +1 -1
  99. package/lib/commonjs/ui/screens/UserListScreen.js +14 -24
  100. package/lib/commonjs/ui/screens/UserListScreen.js.map +1 -1
  101. package/lib/commonjs/ui/screens/fileManagement/PhotoPickerSection.js +1 -1
  102. package/lib/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.js +9 -7
  103. package/lib/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.js.map +1 -1
  104. package/lib/commonjs/ui/screens/trust/TrustAboutScreen.js +66 -75
  105. package/lib/commonjs/ui/screens/trust/TrustAboutScreen.js.map +1 -1
  106. package/lib/commonjs/ui/screens/trust/TrustCenterScreen.js +111 -139
  107. package/lib/commonjs/ui/screens/trust/TrustCenterScreen.js.map +1 -1
  108. package/lib/commonjs/ui/screens/trust/TrustFAQScreen.js +13 -20
  109. package/lib/commonjs/ui/screens/trust/TrustFAQScreen.js.map +1 -1
  110. package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js +14 -27
  111. package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
  112. package/lib/commonjs/ui/screens/trust/TrustRewardsScreen.js +68 -85
  113. package/lib/commonjs/ui/screens/trust/TrustRewardsScreen.js.map +1 -1
  114. package/lib/commonjs/ui/screens/trust/TrustRulesScreen.js +28 -36
  115. package/lib/commonjs/ui/screens/trust/TrustRulesScreen.js.map +1 -1
  116. package/lib/commonjs/ui/types/surfaceScreen.js +6 -0
  117. package/lib/commonjs/ui/types/surfaceScreen.js.map +1 -0
  118. package/lib/module/index.js +12 -5
  119. package/lib/module/index.js.map +1 -1
  120. package/lib/module/ui/components/OxyAccountDialogScreen.js +145 -0
  121. package/lib/module/ui/components/OxyAccountDialogScreen.js.map +1 -0
  122. package/lib/module/ui/components/OxyAuthChooser.js +137 -40
  123. package/lib/module/ui/components/OxyAuthChooser.js.map +1 -1
  124. package/lib/module/ui/components/OxyConsentScreen.js +1 -1
  125. package/lib/module/ui/components/OxyProvider.js +10 -30
  126. package/lib/module/ui/components/OxyProvider.js.map +1 -1
  127. package/lib/module/ui/components/ProfileButton.js +1 -1
  128. package/lib/module/ui/components/RequireOxyAuth.js +1 -1
  129. package/lib/module/ui/components/SurfaceHeaderAction.js +58 -0
  130. package/lib/module/ui/components/SurfaceHeaderAction.js.map +1 -0
  131. package/lib/module/ui/components/SurfaceScreen.js +188 -0
  132. package/lib/module/ui/components/SurfaceScreen.js.map +1 -0
  133. package/lib/module/ui/components/fileManagement/FileDetailsModal.js +46 -29
  134. package/lib/module/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
  135. package/lib/module/ui/components/modals/DeleteAccountModal.js +46 -23
  136. package/lib/module/ui/components/modals/DeleteAccountModal.js.map +1 -1
  137. package/lib/module/ui/components/oxyAuthChooserStyles.js +22 -12
  138. package/lib/module/ui/components/oxyAuthChooserStyles.js.map +1 -1
  139. package/lib/module/ui/components/surfaces/ActionSheetSurface.js +78 -0
  140. package/lib/module/ui/components/surfaces/ActionSheetSurface.js.map +1 -0
  141. package/lib/module/ui/context/OxyContext.js +49 -4
  142. package/lib/module/ui/context/OxyContext.js.map +1 -1
  143. package/lib/module/ui/hooks/useAvatarPicker.js +34 -39
  144. package/lib/module/ui/hooks/useAvatarPicker.js.map +1 -1
  145. package/lib/module/ui/hooks/useSurfaceHeader.js +42 -0
  146. package/lib/module/ui/hooks/useSurfaceHeader.js.map +1 -0
  147. package/lib/module/ui/hooks/useSwitchableAccounts.js +1 -1
  148. package/lib/module/ui/navigation/accountDialogManager.js +14 -2
  149. package/lib/module/ui/navigation/accountDialogManager.js.map +1 -1
  150. package/lib/module/ui/navigation/bottomSheetManager.js +37 -53
  151. package/lib/module/ui/navigation/bottomSheetManager.js.map +1 -1
  152. package/lib/module/ui/navigation/routes.js +6 -56
  153. package/lib/module/ui/navigation/routes.js.map +1 -1
  154. package/lib/module/ui/navigation/surfaceBackBridge.js +63 -0
  155. package/lib/module/ui/navigation/surfaceBackBridge.js.map +1 -0
  156. package/lib/module/ui/navigation/surfaceNavStack.js +95 -0
  157. package/lib/module/ui/navigation/surfaceNavStack.js.map +1 -0
  158. package/lib/module/ui/navigation/surfaceRegistry.js +146 -0
  159. package/lib/module/ui/navigation/surfaceRegistry.js.map +1 -0
  160. package/lib/module/ui/navigation/surfaces.js +244 -0
  161. package/lib/module/ui/navigation/surfaces.js.map +1 -0
  162. package/lib/module/ui/screens/AccountMembersScreen.js +218 -286
  163. package/lib/module/ui/screens/AccountMembersScreen.js.map +1 -1
  164. package/lib/module/ui/screens/AccountSettingsScreen.js +92 -121
  165. package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
  166. package/lib/module/ui/screens/AccountVerificationScreen.js +25 -38
  167. package/lib/module/ui/screens/AccountVerificationScreen.js.map +1 -1
  168. package/lib/module/ui/screens/AppInfoScreen.js +220 -227
  169. package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
  170. package/lib/module/ui/screens/AvatarCropScreen.js +10 -14
  171. package/lib/module/ui/screens/AvatarCropScreen.js.map +1 -1
  172. package/lib/module/ui/screens/ConnectedAppsScreen.js +26 -40
  173. package/lib/module/ui/screens/ConnectedAppsScreen.js.map +1 -1
  174. package/lib/module/ui/screens/CreateAccountScreen.js +139 -160
  175. package/lib/module/ui/screens/CreateAccountScreen.js.map +1 -1
  176. package/lib/module/ui/screens/EditProfileFieldScreen.js +32 -38
  177. package/lib/module/ui/screens/EditProfileFieldScreen.js.map +1 -1
  178. package/lib/module/ui/screens/EditProfileScreen.js +102 -110
  179. package/lib/module/ui/screens/EditProfileScreen.js.map +1 -1
  180. package/lib/module/ui/screens/FAQScreen.js +11 -15
  181. package/lib/module/ui/screens/FAQScreen.js.map +1 -1
  182. package/lib/module/ui/screens/FeedbackScreen.js +10 -17
  183. package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
  184. package/lib/module/ui/screens/FileManagementScreen.js +222 -208
  185. package/lib/module/ui/screens/FileManagementScreen.js.map +1 -1
  186. package/lib/module/ui/screens/HelpSupportScreen.js +64 -70
  187. package/lib/module/ui/screens/HelpSupportScreen.js.map +1 -1
  188. package/lib/module/ui/screens/HistoryViewScreen.js +65 -81
  189. package/lib/module/ui/screens/HistoryViewScreen.js.map +1 -1
  190. package/lib/module/ui/screens/LanguageSelectorScreen.js +71 -99
  191. package/lib/module/ui/screens/LanguageSelectorScreen.js.map +1 -1
  192. package/lib/module/ui/screens/LearnMoreUsernamesScreen.js +10 -15
  193. package/lib/module/ui/screens/LearnMoreUsernamesScreen.js.map +1 -1
  194. package/lib/module/ui/screens/LegalDocumentsScreen.js +78 -94
  195. package/lib/module/ui/screens/LegalDocumentsScreen.js.map +1 -1
  196. package/lib/module/ui/screens/ManageAccountScreen.js +102 -137
  197. package/lib/module/ui/screens/ManageAccountScreen.js.map +1 -1
  198. package/lib/module/ui/screens/NotificationsScreen.js +71 -77
  199. package/lib/module/ui/screens/NotificationsScreen.js.map +1 -1
  200. package/lib/module/ui/screens/PaymentGatewayScreen.js +4 -9
  201. package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -1
  202. package/lib/module/ui/screens/PreferencesScreen.js +69 -75
  203. package/lib/module/ui/screens/PreferencesScreen.js.map +1 -1
  204. package/lib/module/ui/screens/PremiumSubscriptionScreen.js +58 -93
  205. package/lib/module/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
  206. package/lib/module/ui/screens/PrivacySettingsScreen.js +293 -305
  207. package/lib/module/ui/screens/PrivacySettingsScreen.js.map +1 -1
  208. package/lib/module/ui/screens/ProfileScreen.js +102 -116
  209. package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
  210. package/lib/module/ui/screens/SavesCollectionsScreen.js +40 -46
  211. package/lib/module/ui/screens/SavesCollectionsScreen.js.map +1 -1
  212. package/lib/module/ui/screens/SearchSettingsScreen.js +46 -58
  213. package/lib/module/ui/screens/SearchSettingsScreen.js.map +1 -1
  214. package/lib/module/ui/screens/UserLinksScreen.js +26 -32
  215. package/lib/module/ui/screens/UserLinksScreen.js.map +1 -1
  216. package/lib/module/ui/screens/UserListScreen.js +14 -24
  217. package/lib/module/ui/screens/UserListScreen.js.map +1 -1
  218. package/lib/module/ui/screens/fileManagement/PhotoPickerSection.js +1 -1
  219. package/lib/module/ui/screens/fileManagement/hooks/useFileUploadState.js +8 -7
  220. package/lib/module/ui/screens/fileManagement/hooks/useFileUploadState.js.map +1 -1
  221. package/lib/module/ui/screens/trust/TrustAboutScreen.js +67 -75
  222. package/lib/module/ui/screens/trust/TrustAboutScreen.js.map +1 -1
  223. package/lib/module/ui/screens/trust/TrustCenterScreen.js +112 -139
  224. package/lib/module/ui/screens/trust/TrustCenterScreen.js.map +1 -1
  225. package/lib/module/ui/screens/trust/TrustFAQScreen.js +15 -21
  226. package/lib/module/ui/screens/trust/TrustFAQScreen.js.map +1 -1
  227. package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js +14 -26
  228. package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
  229. package/lib/module/ui/screens/trust/TrustRewardsScreen.js +69 -85
  230. package/lib/module/ui/screens/trust/TrustRewardsScreen.js.map +1 -1
  231. package/lib/module/ui/screens/trust/TrustRulesScreen.js +30 -37
  232. package/lib/module/ui/screens/trust/TrustRulesScreen.js.map +1 -1
  233. package/lib/module/ui/types/surfaceScreen.js +4 -0
  234. package/lib/module/ui/types/surfaceScreen.js.map +1 -0
  235. package/lib/typescript/commonjs/index.d.ts +2 -0
  236. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  237. package/lib/typescript/commonjs/ui/components/OxyAccountDialogScreen.d.ts +39 -0
  238. package/lib/typescript/commonjs/ui/components/OxyAccountDialogScreen.d.ts.map +1 -0
  239. package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts +3 -3
  240. package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts.map +1 -1
  241. package/lib/typescript/commonjs/ui/components/OxyProvider.d.ts +3 -2
  242. package/lib/typescript/commonjs/ui/components/OxyProvider.d.ts.map +1 -1
  243. package/lib/typescript/commonjs/ui/components/ProfileButton.d.ts +2 -2
  244. package/lib/typescript/commonjs/ui/components/RequireOxyAuth.d.ts +1 -1
  245. package/lib/typescript/commonjs/ui/components/SurfaceHeaderAction.d.ts +16 -0
  246. package/lib/typescript/commonjs/ui/components/SurfaceHeaderAction.d.ts.map +1 -0
  247. package/lib/typescript/commonjs/ui/components/SurfaceScreen.d.ts +26 -0
  248. package/lib/typescript/commonjs/ui/components/SurfaceScreen.d.ts.map +1 -0
  249. package/lib/typescript/commonjs/ui/components/fileManagement/FileDetailsModal.d.ts +14 -4
  250. package/lib/typescript/commonjs/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -1
  251. package/lib/typescript/commonjs/ui/components/modals/DeleteAccountModal.d.ts +17 -2
  252. package/lib/typescript/commonjs/ui/components/modals/DeleteAccountModal.d.ts.map +1 -1
  253. package/lib/typescript/commonjs/ui/components/oxyAuthChooserStyles.d.ts +19 -9
  254. package/lib/typescript/commonjs/ui/components/oxyAuthChooserStyles.d.ts.map +1 -1
  255. package/lib/typescript/commonjs/ui/components/surfaces/ActionSheetSurface.d.ts +38 -0
  256. package/lib/typescript/commonjs/ui/components/surfaces/ActionSheetSurface.d.ts.map +1 -0
  257. package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
  258. package/lib/typescript/commonjs/ui/hooks/useAvatarPicker.d.ts +7 -11
  259. package/lib/typescript/commonjs/ui/hooks/useAvatarPicker.d.ts.map +1 -1
  260. package/lib/typescript/commonjs/ui/hooks/useSurfaceHeader.d.ts +31 -0
  261. package/lib/typescript/commonjs/ui/hooks/useSurfaceHeader.d.ts.map +1 -0
  262. package/lib/typescript/commonjs/ui/hooks/useSwitchableAccounts.d.ts +1 -1
  263. package/lib/typescript/commonjs/ui/navigation/accountDialogManager.d.ts +14 -2
  264. package/lib/typescript/commonjs/ui/navigation/accountDialogManager.d.ts.map +1 -1
  265. package/lib/typescript/commonjs/ui/navigation/bottomSheetManager.d.ts +24 -16
  266. package/lib/typescript/commonjs/ui/navigation/bottomSheetManager.d.ts.map +1 -1
  267. package/lib/typescript/commonjs/ui/navigation/routes.d.ts +2 -60
  268. package/lib/typescript/commonjs/ui/navigation/routes.d.ts.map +1 -1
  269. package/lib/typescript/commonjs/ui/navigation/surfaceBackBridge.d.ts +16 -0
  270. package/lib/typescript/commonjs/ui/navigation/surfaceBackBridge.d.ts.map +1 -0
  271. package/lib/typescript/commonjs/ui/navigation/surfaceNavStack.d.ts +51 -0
  272. package/lib/typescript/commonjs/ui/navigation/surfaceNavStack.d.ts.map +1 -0
  273. package/lib/typescript/commonjs/ui/navigation/surfaceRegistry.d.ts +135 -0
  274. package/lib/typescript/commonjs/ui/navigation/surfaceRegistry.d.ts.map +1 -0
  275. package/lib/typescript/commonjs/ui/navigation/surfaces.d.ts +79 -0
  276. package/lib/typescript/commonjs/ui/navigation/surfaces.d.ts.map +1 -0
  277. package/lib/typescript/commonjs/ui/screens/AccountMembersScreen.d.ts.map +1 -1
  278. package/lib/typescript/commonjs/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
  279. package/lib/typescript/commonjs/ui/screens/AccountVerificationScreen.d.ts.map +1 -1
  280. package/lib/typescript/commonjs/ui/screens/AppInfoScreen.d.ts.map +1 -1
  281. package/lib/typescript/commonjs/ui/screens/AvatarCropScreen.d.ts +0 -4
  282. package/lib/typescript/commonjs/ui/screens/AvatarCropScreen.d.ts.map +1 -1
  283. package/lib/typescript/commonjs/ui/screens/ConnectedAppsScreen.d.ts.map +1 -1
  284. package/lib/typescript/commonjs/ui/screens/CreateAccountScreen.d.ts.map +1 -1
  285. package/lib/typescript/commonjs/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
  286. package/lib/typescript/commonjs/ui/screens/EditProfileScreen.d.ts.map +1 -1
  287. package/lib/typescript/commonjs/ui/screens/FAQScreen.d.ts.map +1 -1
  288. package/lib/typescript/commonjs/ui/screens/FeedbackScreen.d.ts.map +1 -1
  289. package/lib/typescript/commonjs/ui/screens/FileManagementScreen.d.ts.map +1 -1
  290. package/lib/typescript/commonjs/ui/screens/HelpSupportScreen.d.ts.map +1 -1
  291. package/lib/typescript/commonjs/ui/screens/HistoryViewScreen.d.ts.map +1 -1
  292. package/lib/typescript/commonjs/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
  293. package/lib/typescript/commonjs/ui/screens/LearnMoreUsernamesScreen.d.ts.map +1 -1
  294. package/lib/typescript/commonjs/ui/screens/LegalDocumentsScreen.d.ts.map +1 -1
  295. package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts +1 -1
  296. package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts.map +1 -1
  297. package/lib/typescript/commonjs/ui/screens/NotificationsScreen.d.ts.map +1 -1
  298. package/lib/typescript/commonjs/ui/screens/PaymentGatewayScreen.d.ts.map +1 -1
  299. package/lib/typescript/commonjs/ui/screens/PreferencesScreen.d.ts.map +1 -1
  300. package/lib/typescript/commonjs/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
  301. package/lib/typescript/commonjs/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
  302. package/lib/typescript/commonjs/ui/screens/ProfileScreen.d.ts.map +1 -1
  303. package/lib/typescript/commonjs/ui/screens/SavesCollectionsScreen.d.ts.map +1 -1
  304. package/lib/typescript/commonjs/ui/screens/SearchSettingsScreen.d.ts.map +1 -1
  305. package/lib/typescript/commonjs/ui/screens/UserLinksScreen.d.ts.map +1 -1
  306. package/lib/typescript/commonjs/ui/screens/UserListScreen.d.ts.map +1 -1
  307. package/lib/typescript/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.d.ts.map +1 -1
  308. package/lib/typescript/commonjs/ui/screens/trust/TrustAboutScreen.d.ts.map +1 -1
  309. package/lib/typescript/commonjs/ui/screens/trust/TrustCenterScreen.d.ts.map +1 -1
  310. package/lib/typescript/commonjs/ui/screens/trust/TrustFAQScreen.d.ts.map +1 -1
  311. package/lib/typescript/commonjs/ui/screens/trust/TrustLeaderboardScreen.d.ts.map +1 -1
  312. package/lib/typescript/commonjs/ui/screens/trust/TrustRewardsScreen.d.ts.map +1 -1
  313. package/lib/typescript/commonjs/ui/screens/trust/TrustRulesScreen.d.ts.map +1 -1
  314. package/lib/typescript/commonjs/ui/types/navigation.d.ts +8 -0
  315. package/lib/typescript/commonjs/ui/types/navigation.d.ts.map +1 -1
  316. package/lib/typescript/commonjs/ui/types/surfaceScreen.d.ts +38 -0
  317. package/lib/typescript/commonjs/ui/types/surfaceScreen.d.ts.map +1 -0
  318. package/lib/typescript/module/index.d.ts +2 -0
  319. package/lib/typescript/module/index.d.ts.map +1 -1
  320. package/lib/typescript/module/ui/components/OxyAccountDialogScreen.d.ts +39 -0
  321. package/lib/typescript/module/ui/components/OxyAccountDialogScreen.d.ts.map +1 -0
  322. package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts +3 -3
  323. package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts.map +1 -1
  324. package/lib/typescript/module/ui/components/OxyProvider.d.ts +3 -2
  325. package/lib/typescript/module/ui/components/OxyProvider.d.ts.map +1 -1
  326. package/lib/typescript/module/ui/components/ProfileButton.d.ts +2 -2
  327. package/lib/typescript/module/ui/components/RequireOxyAuth.d.ts +1 -1
  328. package/lib/typescript/module/ui/components/SurfaceHeaderAction.d.ts +16 -0
  329. package/lib/typescript/module/ui/components/SurfaceHeaderAction.d.ts.map +1 -0
  330. package/lib/typescript/module/ui/components/SurfaceScreen.d.ts +26 -0
  331. package/lib/typescript/module/ui/components/SurfaceScreen.d.ts.map +1 -0
  332. package/lib/typescript/module/ui/components/fileManagement/FileDetailsModal.d.ts +14 -4
  333. package/lib/typescript/module/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -1
  334. package/lib/typescript/module/ui/components/modals/DeleteAccountModal.d.ts +17 -2
  335. package/lib/typescript/module/ui/components/modals/DeleteAccountModal.d.ts.map +1 -1
  336. package/lib/typescript/module/ui/components/oxyAuthChooserStyles.d.ts +19 -9
  337. package/lib/typescript/module/ui/components/oxyAuthChooserStyles.d.ts.map +1 -1
  338. package/lib/typescript/module/ui/components/surfaces/ActionSheetSurface.d.ts +38 -0
  339. package/lib/typescript/module/ui/components/surfaces/ActionSheetSurface.d.ts.map +1 -0
  340. package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
  341. package/lib/typescript/module/ui/hooks/useAvatarPicker.d.ts +7 -11
  342. package/lib/typescript/module/ui/hooks/useAvatarPicker.d.ts.map +1 -1
  343. package/lib/typescript/module/ui/hooks/useSurfaceHeader.d.ts +31 -0
  344. package/lib/typescript/module/ui/hooks/useSurfaceHeader.d.ts.map +1 -0
  345. package/lib/typescript/module/ui/hooks/useSwitchableAccounts.d.ts +1 -1
  346. package/lib/typescript/module/ui/navigation/accountDialogManager.d.ts +14 -2
  347. package/lib/typescript/module/ui/navigation/accountDialogManager.d.ts.map +1 -1
  348. package/lib/typescript/module/ui/navigation/bottomSheetManager.d.ts +24 -16
  349. package/lib/typescript/module/ui/navigation/bottomSheetManager.d.ts.map +1 -1
  350. package/lib/typescript/module/ui/navigation/routes.d.ts +2 -60
  351. package/lib/typescript/module/ui/navigation/routes.d.ts.map +1 -1
  352. package/lib/typescript/module/ui/navigation/surfaceBackBridge.d.ts +16 -0
  353. package/lib/typescript/module/ui/navigation/surfaceBackBridge.d.ts.map +1 -0
  354. package/lib/typescript/module/ui/navigation/surfaceNavStack.d.ts +51 -0
  355. package/lib/typescript/module/ui/navigation/surfaceNavStack.d.ts.map +1 -0
  356. package/lib/typescript/module/ui/navigation/surfaceRegistry.d.ts +135 -0
  357. package/lib/typescript/module/ui/navigation/surfaceRegistry.d.ts.map +1 -0
  358. package/lib/typescript/module/ui/navigation/surfaces.d.ts +79 -0
  359. package/lib/typescript/module/ui/navigation/surfaces.d.ts.map +1 -0
  360. package/lib/typescript/module/ui/screens/AccountMembersScreen.d.ts.map +1 -1
  361. package/lib/typescript/module/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
  362. package/lib/typescript/module/ui/screens/AccountVerificationScreen.d.ts.map +1 -1
  363. package/lib/typescript/module/ui/screens/AppInfoScreen.d.ts.map +1 -1
  364. package/lib/typescript/module/ui/screens/AvatarCropScreen.d.ts +0 -4
  365. package/lib/typescript/module/ui/screens/AvatarCropScreen.d.ts.map +1 -1
  366. package/lib/typescript/module/ui/screens/ConnectedAppsScreen.d.ts.map +1 -1
  367. package/lib/typescript/module/ui/screens/CreateAccountScreen.d.ts.map +1 -1
  368. package/lib/typescript/module/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
  369. package/lib/typescript/module/ui/screens/EditProfileScreen.d.ts.map +1 -1
  370. package/lib/typescript/module/ui/screens/FAQScreen.d.ts.map +1 -1
  371. package/lib/typescript/module/ui/screens/FeedbackScreen.d.ts.map +1 -1
  372. package/lib/typescript/module/ui/screens/FileManagementScreen.d.ts.map +1 -1
  373. package/lib/typescript/module/ui/screens/HelpSupportScreen.d.ts.map +1 -1
  374. package/lib/typescript/module/ui/screens/HistoryViewScreen.d.ts.map +1 -1
  375. package/lib/typescript/module/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
  376. package/lib/typescript/module/ui/screens/LearnMoreUsernamesScreen.d.ts.map +1 -1
  377. package/lib/typescript/module/ui/screens/LegalDocumentsScreen.d.ts.map +1 -1
  378. package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts +1 -1
  379. package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts.map +1 -1
  380. package/lib/typescript/module/ui/screens/NotificationsScreen.d.ts.map +1 -1
  381. package/lib/typescript/module/ui/screens/PaymentGatewayScreen.d.ts.map +1 -1
  382. package/lib/typescript/module/ui/screens/PreferencesScreen.d.ts.map +1 -1
  383. package/lib/typescript/module/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
  384. package/lib/typescript/module/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
  385. package/lib/typescript/module/ui/screens/ProfileScreen.d.ts.map +1 -1
  386. package/lib/typescript/module/ui/screens/SavesCollectionsScreen.d.ts.map +1 -1
  387. package/lib/typescript/module/ui/screens/SearchSettingsScreen.d.ts.map +1 -1
  388. package/lib/typescript/module/ui/screens/UserLinksScreen.d.ts.map +1 -1
  389. package/lib/typescript/module/ui/screens/UserListScreen.d.ts.map +1 -1
  390. package/lib/typescript/module/ui/screens/fileManagement/hooks/useFileUploadState.d.ts.map +1 -1
  391. package/lib/typescript/module/ui/screens/trust/TrustAboutScreen.d.ts.map +1 -1
  392. package/lib/typescript/module/ui/screens/trust/TrustCenterScreen.d.ts.map +1 -1
  393. package/lib/typescript/module/ui/screens/trust/TrustFAQScreen.d.ts.map +1 -1
  394. package/lib/typescript/module/ui/screens/trust/TrustLeaderboardScreen.d.ts.map +1 -1
  395. package/lib/typescript/module/ui/screens/trust/TrustRewardsScreen.d.ts.map +1 -1
  396. package/lib/typescript/module/ui/screens/trust/TrustRulesScreen.d.ts.map +1 -1
  397. package/lib/typescript/module/ui/types/navigation.d.ts +8 -0
  398. package/lib/typescript/module/ui/types/navigation.d.ts.map +1 -1
  399. package/lib/typescript/module/ui/types/surfaceScreen.d.ts +38 -0
  400. package/lib/typescript/module/ui/types/surfaceScreen.d.ts.map +1 -0
  401. package/package.json +2 -2
  402. package/src/index.ts +12 -5
  403. package/src/ui/components/OxyAccountDialogScreen.tsx +148 -0
  404. package/src/ui/components/OxyAuthChooser.tsx +153 -33
  405. package/src/ui/components/OxyConsentScreen.tsx +1 -1
  406. package/src/ui/components/OxyProvider.tsx +12 -34
  407. package/src/ui/components/ProfileButton.tsx +2 -2
  408. package/src/ui/components/RequireOxyAuth.tsx +1 -1
  409. package/src/ui/components/SurfaceHeaderAction.tsx +60 -0
  410. package/src/ui/components/SurfaceScreen.tsx +226 -0
  411. package/src/ui/components/fileManagement/FileDetailsModal.tsx +50 -36
  412. package/src/ui/components/modals/DeleteAccountModal.tsx +47 -26
  413. package/src/ui/components/oxyAuthChooserStyles.ts +22 -12
  414. package/src/ui/components/surfaces/ActionSheetSurface.tsx +98 -0
  415. package/src/ui/context/OxyContext.tsx +43 -3
  416. package/src/ui/hooks/useAvatarPicker.ts +53 -66
  417. package/src/ui/hooks/useSurfaceHeader.ts +56 -0
  418. package/src/ui/hooks/useSwitchableAccounts.ts +1 -1
  419. package/src/ui/navigation/__tests__/getSurfaceConfig.test.ts +39 -0
  420. package/src/ui/navigation/__tests__/surfaceNavStack.test.ts +68 -0
  421. package/src/ui/navigation/accountDialogManager.ts +14 -2
  422. package/src/ui/navigation/bottomSheetManager.ts +46 -73
  423. package/src/ui/navigation/routes.ts +7 -106
  424. package/src/ui/navigation/surfaceBackBridge.ts +69 -0
  425. package/src/ui/navigation/surfaceNavStack.ts +110 -0
  426. package/src/ui/navigation/surfaceRegistry.ts +240 -0
  427. package/src/ui/navigation/surfaces.ts +272 -0
  428. package/src/ui/screens/AccountMembersScreen.tsx +39 -100
  429. package/src/ui/screens/AccountSettingsScreen.tsx +32 -54
  430. package/src/ui/screens/AccountVerificationScreen.tsx +23 -51
  431. package/src/ui/screens/AppInfoScreen.tsx +6 -13
  432. package/src/ui/screens/AvatarCropScreen.tsx +8 -17
  433. package/src/ui/screens/ConnectedAppsScreen.tsx +39 -60
  434. package/src/ui/screens/CreateAccountScreen.tsx +13 -39
  435. package/src/ui/screens/EditProfileFieldScreen.tsx +30 -48
  436. package/src/ui/screens/EditProfileScreen.tsx +7 -16
  437. package/src/ui/screens/FAQScreen.tsx +9 -13
  438. package/src/ui/screens/FeedbackScreen.tsx +8 -22
  439. package/src/ui/screens/FileManagementScreen.tsx +191 -188
  440. package/src/ui/screens/HelpSupportScreen.tsx +7 -13
  441. package/src/ui/screens/HistoryViewScreen.tsx +26 -31
  442. package/src/ui/screens/LanguageSelectorScreen.tsx +12 -46
  443. package/src/ui/screens/LearnMoreUsernamesScreen.tsx +8 -16
  444. package/src/ui/screens/LegalDocumentsScreen.tsx +7 -22
  445. package/src/ui/screens/ManageAccountScreen.tsx +96 -165
  446. package/src/ui/screens/NotificationsScreen.tsx +7 -13
  447. package/src/ui/screens/PaymentGatewayScreen.tsx +3 -10
  448. package/src/ui/screens/PreferencesScreen.tsx +7 -13
  449. package/src/ui/screens/PremiumSubscriptionScreen.tsx +52 -90
  450. package/src/ui/screens/PrivacySettingsScreen.tsx +9 -21
  451. package/src/ui/screens/ProfileScreen.tsx +9 -11
  452. package/src/ui/screens/SavesCollectionsScreen.tsx +7 -13
  453. package/src/ui/screens/SearchSettingsScreen.tsx +9 -21
  454. package/src/ui/screens/UserLinksScreen.tsx +7 -14
  455. package/src/ui/screens/UserListScreen.tsx +2 -5
  456. package/src/ui/screens/fileManagement/PhotoPickerSection.tsx +1 -1
  457. package/src/ui/screens/fileManagement/hooks/useFileUploadState.ts +9 -7
  458. package/src/ui/screens/trust/TrustAboutScreen.tsx +10 -17
  459. package/src/ui/screens/trust/TrustCenterScreen.tsx +9 -28
  460. package/src/ui/screens/trust/TrustFAQScreen.tsx +15 -18
  461. package/src/ui/screens/trust/TrustLeaderboardScreen.tsx +3 -5
  462. package/src/ui/screens/trust/TrustRewardsScreen.tsx +11 -26
  463. package/src/ui/screens/trust/TrustRulesScreen.tsx +10 -13
  464. package/src/ui/types/navigation.ts +8 -0
  465. package/src/ui/types/surfaceScreen.ts +38 -0
  466. package/lib/commonjs/ui/components/BottomSheet.js +0 -49
  467. package/lib/commonjs/ui/components/BottomSheet.js.map +0 -1
  468. package/lib/commonjs/ui/components/BottomSheetRouter.js +0 -298
  469. package/lib/commonjs/ui/components/BottomSheetRouter.js.map +0 -1
  470. package/lib/commonjs/ui/components/Header.js +0 -305
  471. package/lib/commonjs/ui/components/Header.js.map +0 -1
  472. package/lib/commonjs/ui/components/OxyAccountDialog.js +0 -259
  473. package/lib/commonjs/ui/components/OxyAccountDialog.js.map +0 -1
  474. package/lib/module/ui/components/BottomSheet.js +0 -45
  475. package/lib/module/ui/components/BottomSheet.js.map +0 -1
  476. package/lib/module/ui/components/BottomSheetRouter.js +0 -292
  477. package/lib/module/ui/components/BottomSheetRouter.js.map +0 -1
  478. package/lib/module/ui/components/Header.js +0 -299
  479. package/lib/module/ui/components/Header.js.map +0 -1
  480. package/lib/module/ui/components/OxyAccountDialog.js +0 -254
  481. package/lib/module/ui/components/OxyAccountDialog.js.map +0 -1
  482. package/lib/typescript/commonjs/ui/components/BottomSheet.d.ts +0 -29
  483. package/lib/typescript/commonjs/ui/components/BottomSheet.d.ts.map +0 -1
  484. package/lib/typescript/commonjs/ui/components/BottomSheetRouter.d.ts +0 -9
  485. package/lib/typescript/commonjs/ui/components/BottomSheetRouter.d.ts.map +0 -1
  486. package/lib/typescript/commonjs/ui/components/Header.d.ts +0 -33
  487. package/lib/typescript/commonjs/ui/components/Header.d.ts.map +0 -1
  488. package/lib/typescript/commonjs/ui/components/OxyAccountDialog.d.ts +0 -37
  489. package/lib/typescript/commonjs/ui/components/OxyAccountDialog.d.ts.map +0 -1
  490. package/lib/typescript/module/ui/components/BottomSheet.d.ts +0 -29
  491. package/lib/typescript/module/ui/components/BottomSheet.d.ts.map +0 -1
  492. package/lib/typescript/module/ui/components/BottomSheetRouter.d.ts +0 -9
  493. package/lib/typescript/module/ui/components/BottomSheetRouter.d.ts.map +0 -1
  494. package/lib/typescript/module/ui/components/Header.d.ts +0 -33
  495. package/lib/typescript/module/ui/components/Header.d.ts.map +0 -1
  496. package/lib/typescript/module/ui/components/OxyAccountDialog.d.ts +0 -37
  497. package/lib/typescript/module/ui/components/OxyAccountDialog.d.ts.map +0 -1
  498. package/src/ui/components/BottomSheet.tsx +0 -48
  499. package/src/ui/components/BottomSheetRouter.tsx +0 -310
  500. package/src/ui/components/Header.tsx +0 -224
  501. package/src/ui/components/OxyAccountDialog.tsx +0 -243
  502. package/src/ui/navigation/__tests__/getSheetConfig.test.ts +0 -36
@@ -2,18 +2,24 @@
2
2
 
3
3
  import { View, Text } from 'react-native';
4
4
  import { Ionicons } from '@expo/vector-icons';
5
- import { Dialog } from '@oxyhq/bloom';
5
+ import { Button } from '@oxyhq/bloom/button';
6
6
  import { useTheme } from '@oxyhq/bloom/theme';
7
+ import { surfaces } from '@oxyhq/bloom/surfaces';
7
8
  import { useI18n } from "../../hooks/useI18n.js";
8
9
  import { formatFileSize, getFileIcon } from "../../utils/fileManagement.js";
9
10
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
11
+ /**
12
+ * File-detail panel — a rich presented surface (NOT a yes/no confirm): a file's
13
+ * icon + metadata plus download / delete / cancel actions. Each action first
14
+ * dismisses this surface, then runs its handler, so a follow-up delete confirm
15
+ * stacks cleanly above whatever remains. Presented via {@link presentFileDetails}.
16
+ */
10
17
  export const FileDetailsModal = ({
11
- control,
18
+ surface,
12
19
  file,
13
20
  onDownload,
14
21
  onDelete,
15
- isOwner,
16
- onClose
22
+ isOwner
17
23
  }) => {
18
24
  const {
19
25
  t
@@ -21,30 +27,8 @@ export const FileDetailsModal = ({
21
27
  const {
22
28
  colors
23
29
  } = useTheme();
24
- if (!file) return null;
25
- const actions = isOwner ? [{
26
- label: t('fileManagement.details.download'),
27
- onPress: () => onDownload(file.id, file.filename)
28
- }, {
29
- label: t('common.actions.delete'),
30
- color: 'destructive',
31
- onPress: () => onDelete(file.id, file.filename)
32
- }, {
33
- label: t('common.cancel'),
34
- color: 'cancel'
35
- }] : [{
36
- label: t('fileManagement.details.download'),
37
- onPress: () => onDownload(file.id, file.filename)
38
- }, {
39
- label: t('common.cancel'),
40
- color: 'cancel'
41
- }];
42
- return /*#__PURE__*/_jsx(Dialog, {
43
- control: control,
44
- onClose: onClose,
45
- label: t('fileManagement.details.title'),
46
- actions: actions,
47
- children: /*#__PURE__*/_jsxs(View, {
30
+ return /*#__PURE__*/_jsxs(View, {
31
+ children: [/*#__PURE__*/_jsxs(View, {
48
32
  className: "bg-secondary border-border p-[18px] rounded-[14px] border items-center",
49
33
  children: [/*#__PURE__*/_jsx(View, {
50
34
  className: "mb-space-16",
@@ -96,7 +80,40 @@ export const FileDetailsModal = ({
96
80
  })]
97
81
  })]
98
82
  })]
99
- })
83
+ }), /*#__PURE__*/_jsxs(View, {
84
+ style: {
85
+ gap: 8
86
+ },
87
+ children: [/*#__PURE__*/_jsx(Button, {
88
+ variant: "primary",
89
+ onPress: () => {
90
+ surface.dismiss();
91
+ onDownload(file.id, file.filename);
92
+ },
93
+ children: t('fileManagement.details.download')
94
+ }), isOwner ? /*#__PURE__*/_jsx(Button, {
95
+ variant: "destructive",
96
+ onPress: () => {
97
+ surface.dismiss();
98
+ onDelete(file.id, file.filename);
99
+ },
100
+ children: t('common.actions.delete')
101
+ }) : null, /*#__PURE__*/_jsx(Button, {
102
+ variant: "secondary",
103
+ onPress: () => surface.dismiss(),
104
+ children: t('common.cancel')
105
+ })]
106
+ })]
100
107
  });
101
108
  };
109
+
110
+ /** Options accepted by {@link presentFileDetails} (everything but `surface`). */
111
+
112
+ /** Present the file-detail panel on the shared surface stack. */
113
+ export function presentFileDetails(options) {
114
+ void surfaces.present(surface => /*#__PURE__*/_jsx(FileDetailsModal, {
115
+ surface: surface,
116
+ ...options
117
+ }));
118
+ }
102
119
  //# sourceMappingURL=FileDetailsModal.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["View","Text","Ionicons","Dialog","useTheme","useI18n","formatFileSize","getFileIcon","jsx","_jsx","jsxs","_jsxs","FileDetailsModal","control","file","onDownload","onDelete","isOwner","onClose","t","colors","actions","label","onPress","id","filename","color","children","className","name","contentType","size","primary","length","Date","uploadDate","toLocaleString","metadata","description"],"sourceRoot":"../../../../../src","sources":["ui/components/fileManagement/FileDetailsModal.tsx"],"mappings":";;AACA,SAASA,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzC,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,MAAM,QAAiC,cAAc;AAC9D,SAASC,QAAQ,QAAQ,oBAAoB;AAE7C,SAASC,OAAO,QAAQ,wBAAqB;AAC7C,SAASC,cAAc,EAAEC,WAAW,QAAQ,+BAA4B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAWzE,OAAO,MAAMC,gBAAiD,GAAGA,CAAC;EAC9DC,OAAO;EACPC,IAAI;EACJC,UAAU;EACVC,QAAQ;EACRC,OAAO;EACPC;AACJ,CAAC,KAAK;EACF,MAAM;IAAEC;EAAE,CAAC,GAAGd,OAAO,CAAC,CAAC;EACvB,MAAM;IAAEe;EAAO,CAAC,GAAGhB,QAAQ,CAAC,CAAC;EAE7B,IAAI,CAACU,IAAI,EAAE,OAAO,IAAI;EAEtB,MAAMO,OAAO,GAAGJ,OAAO,GACjB,CACI;IACIK,KAAK,EAAEH,CAAC,CAAC,iCAAiC,CAAC;IAC3CI,OAAO,EAAEA,CAAA,KAAMR,UAAU,CAACD,IAAI,CAACU,EAAE,EAAEV,IAAI,CAACW,QAAQ;EACpD,CAAC,EACD;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AC,eACPV,IAAA,CAACR,IAAI;YAAC2B,SAAS,EAAC,2CAA2C;YAAAD,QAAA,EACtDb,IAAI,CAACuB,QAAQ,CAACC;UAAW,CACxB,CAAC;QAAA,CACL,CACT;MAAA,CACC,CAAC;IAAA,CACL;EAAC,CACH,CAAC;AAEjB,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["View","Text","Ionicons","Button","useTheme","surfaces","useI18n","formatFileSize","getFileIcon","jsx","_jsx","jsxs","_jsxs","FileDetailsModal","surface","file","onDownload","onDelete","isOwner","t","colors","children","className","name","contentType","size","color","primary","filename","length","Date","uploadDate","toLocaleString","metadata","description","style","gap","variant","onPress","dismiss","id","presentFileDetails","options","present"],"sourceRoot":"../../../../../src","sources":["ui/components/fileManagement/FileDetailsModal.tsx"],"mappings":";;AACA,SAASA,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzC,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,MAAM,QAAQ,qBAAqB;AAC5C,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,QAAQ,QAA8B,uBAAuB;AAEtE,SAASC,OAAO,QAAQ,wBAAqB;AAC7C,SAASC,cAAc,EAAEC,WAAW,QAAQ,+BAA4B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAWzE;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,gBAAiD,GAAGA,CAAC;EAC9DC,OAAO;EACPC,IAAI;EACJC,UAAU;EACVC,QAAQ;EACRC;AACJ,CAAC,KAAK;EACF,MAAM;IAAEC;EAAE,CAAC,GAAGb,OAAO,CAAC,CAAC;EACvB,MAAM;IAAEc;EAAO,CAAC,GAAGhB,QAAQ,CAAC,CAAC;EAE7B,oBACIQ,KAAA,CAACZ,IAAI;IAAAqB,QAAA,gBACDT,KAAA,CAACZ,IAAI;MAACsB,SAAS,EAAC,wEAAwE;MAAAD,QAAA,gBACpFX,IAAA,CAACV,IAAI;QAACsB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RT,IAAA,CAACP,MAAM;QAACkC,OAAO,EAAC,WAAW;QAACC,OAAO,EAAEA,CAAA,KAAMxB,OAAO,CAACyB,OAAO,CAAC,CAAE;QAAAlB,QAAA,EACxDF,CAAC,CAAC,eAAe;MAAC,CACf,CAAC;IAAA,CACP,CAAC;EAAA,CACL,CAAC;AAEf,CAAC;;AAED;;AAGA;AACA,OAAO,SAASsB,kBAAkBA,CAACC,OAAkC,EAAQ;EACzE,KAAKrC,QAAQ,CAACsC,OAAO,CAAE7B,OAAO,iBAC1BJ,IAAA,CAACG,gBAAgB;IAACC,OAAO,EAAEA,OAAQ;IAAA,GAAK4B;EAAO,CAAG,CACrD,CAAC;AACN","ignoreList":[]}
@@ -3,11 +3,19 @@
3
3
  import { useState, useCallback } from 'react';
4
4
  import { View, Text, TextInput } from 'react-native';
5
5
  import { Ionicons } from '@expo/vector-icons';
6
- import { Dialog } from '@oxyhq/bloom';
6
+ import { Button } from '@oxyhq/bloom/button';
7
7
  import { useTheme } from '@oxyhq/bloom/theme';
8
+ import { surfaces } from '@oxyhq/bloom/surfaces';
8
9
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
10
+ /**
11
+ * Delete-account confirmation — a rich presented surface (NOT a yes/no confirm):
12
+ * the user must retype their username, then the destructive action runs
13
+ * `onDelete`. On success the surface is dismissed with `true` (the presenter
14
+ * then signs out + closes); cancel dismisses with `false`. Presented via
15
+ * {@link presentDeleteAccount}.
16
+ */
9
17
  const DeleteAccountModal = ({
10
- control,
18
+ surface,
11
19
  username,
12
20
  onDelete,
13
21
  t
@@ -23,32 +31,18 @@ const DeleteAccountModal = ({
23
31
  setIsDeleting(true);
24
32
  try {
25
33
  await onDelete(confirmUsername);
26
- // Dialog will be closed by parent on success
34
+ surface.dismiss(true);
27
35
  } catch (err) {
28
36
  setError((err instanceof Error ? err.message : null) || t('deleteAccount.error') || 'Failed to delete account');
29
37
  } finally {
30
38
  setIsDeleting(false);
31
39
  }
32
- }, [isValid, confirmUsername, onDelete, t]);
33
- const handleCleanup = useCallback(() => {
40
+ }, [isValid, confirmUsername, onDelete, surface, t]);
41
+ const handleCancel = useCallback(() => {
34
42
  if (isDeleting) return;
35
- setConfirmUsername('');
36
- setError(null);
37
- }, [isDeleting]);
38
- return /*#__PURE__*/_jsxs(Dialog, {
39
- control: control,
40
- onClose: handleCleanup,
41
- label: "Delete Account",
42
- actions: [{
43
- label: t('deleteAccount.confirm') || 'Delete Forever',
44
- color: 'destructive',
45
- onPress: handleDelete,
46
- disabled: !isValid || isDeleting,
47
- shouldCloseOnPress: false
48
- }, {
49
- label: t('common.cancel') || 'Cancel',
50
- color: 'cancel'
51
- }],
43
+ surface.dismiss(false);
44
+ }, [isDeleting, surface]);
45
+ return /*#__PURE__*/_jsxs(View, {
52
46
  children: [/*#__PURE__*/_jsxs(View, {
53
47
  className: "flex-row items-center mb-4 gap-3",
54
48
  children: [/*#__PURE__*/_jsx(Ionicons, {
@@ -87,7 +81,7 @@ const DeleteAccountModal = ({
87
81
  }), /*#__PURE__*/_jsx(TextInput, {
88
82
  className: "text-text bg-bg text-base py-3 px-4 border rounded-lg",
89
83
  style: {
90
- borderColor: confirmUsername === username ? theme.colors.success : theme.colors.border
84
+ borderColor: isValid ? theme.colors.success : theme.colors.border
91
85
  },
92
86
  value: confirmUsername,
93
87
  onChangeText: setConfirmUsername,
@@ -97,8 +91,37 @@ const DeleteAccountModal = ({
97
91
  autoCorrect: false,
98
92
  editable: !isDeleting
99
93
  })]
94
+ }), /*#__PURE__*/_jsxs(View, {
95
+ style: {
96
+ gap: 8
97
+ },
98
+ children: [/*#__PURE__*/_jsx(Button, {
99
+ variant: "destructive",
100
+ onPress: handleDelete,
101
+ disabled: !isValid || isDeleting,
102
+ loading: isDeleting,
103
+ children: t('deleteAccount.confirm') || 'Delete Forever'
104
+ }), /*#__PURE__*/_jsx(Button, {
105
+ variant: "secondary",
106
+ onPress: handleCancel,
107
+ disabled: isDeleting,
108
+ children: t('common.cancel') || 'Cancel'
109
+ })]
100
110
  })]
101
111
  });
102
112
  };
113
+
114
+ /** Options accepted by {@link presentDeleteAccount} (everything but `surface`). */
115
+
116
+ /**
117
+ * Present the delete-account confirmation on the shared surface stack. Resolves
118
+ * `true` once the account is deleted, `false` if cancelled/dismissed.
119
+ */
120
+ export function presentDeleteAccount(options) {
121
+ return surfaces.present(surface => /*#__PURE__*/_jsx(DeleteAccountModal, {
122
+ surface: surface,
123
+ ...options
124
+ })).then(result => result === true);
125
+ }
103
126
  export default DeleteAccountModal;
104
127
  //# sourceMappingURL=DeleteAccountModal.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["useState","useCallback","View","Text","TextInput","Ionicons","Dialog","useTheme","jsx","_jsx","jsxs","_jsxs","DeleteAccountModal","control","username","onDelete","t","theme","confirmUsername","setConfirmUsername","isDeleting","setIsDeleting","error","setError","isValid","handleDelete","err","Error","message","handleCleanup","onClose","label","actions","color","onPress","disabled","shouldCloseOnPress","children","className","name","size","colors","style","backgroundColor","borderColor","success","border","value","onChangeText","placeholder","placeholderTextColor","textSecondary","autoCapitalize","autoCorrect","editable"],"sourceRoot":"../../../../../src","sources":["ui/components/modals/DeleteAccountModal.tsx"],"mappings":";;AACA,SAASA,QAAQ,EAAEC,WAAW,QAAQ,OAAO;AAC7C,SAASC,IAAI,EAAEC,IAAI,EAAEC,SAAS,QAAQ,cAAc;AACpD,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,MAAM,QAAiC,cAAc;AAC9D,SAASC,QAAQ,QAAQ,oBAAoB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAS9C,MAAMC,kBAAqD,GAAGA,CAAC;EAC3DC,OAAO;EACPC,QAAQ;EACRC,QAAQ;EACRC;AACJ,CAAC,KAAK;EACF,MAAMC,KAAK,GAAGV,QAAQ,CAAC,CAAC;EACxB,MAAM,CAACW,eAAe,EAAEC,kBAAkB,CAAC,GAAGnB,QAAQ,CAAC,EAAE,CA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AI,SAASA,QAAQ;MAAc,CAC/E,CAAC,eACPL,IAAA,CAACL,SAAS;QACNkC,SAAS,EAAC,uDAAuD;QACjEI,KAAK,EAAE;UACHE,WAAW,EAAE1B,eAAe,KAAKJ,QAAQ,GAAGG,KAAK,CAACwB,MAAM,CAACI,OAAO,GAAG5B,KAAK,CAACwB,MAAM,CAACK;QACpF,CAAE;QACFC,KAAK,EAAE7B,eAAgB;QACvB8B,YAAY,EAAE7B,kBAAmB;QACjC8B,WAAW,EAAEnC,QAAS;QACtBoC,oBAAoB,EAAEjC,KAAK,CAACwB,MAAM,CAACU,aAAc;QACjDC,cAAc,EAAC,MAAM;QACrBC,WAAW,EAAE,KAAM;QACnBC,QAAQ,EAAE,CAAClC;MAAW,CACzB,CAAC;IAAA,CACA,CAAC;EAAA,CACH,CAAC;AAEjB,CAAC;AAED,eAAeR,kBAAkB","ignoreList":[]}
1
+ {"version":3,"names":["useState","useCallback","View","Text","TextInput","Ionicons","Button","useTheme","surfaces","jsx","_jsx","jsxs","_jsxs","DeleteAccountModal","surface","username","onDelete","t","theme","confirmUsername","setConfirmUsername","isDeleting","setIsDeleting","error","setError","isValid","handleDelete","dismiss","err","Error","message","handleCancel","children","className","name","size","color","colors","style","backgroundColor","borderColor","success","border","value","onChangeText","placeholder","placeholderTextColor","textSecondary","autoCapitalize","autoCorrect","editable","gap","variant","onPress","disabled","loading","presentDeleteAccount","options","present","then","result"],"sourceRoot":"../../../../../src","sources":["ui/components/modals/DeleteAccountModal.tsx"],"mappings":";;AACA,SAASA,QAAQ,EAAEC,WAAW,QAAQ,OAAO;AAC7C,SAASC,IAAI,EAAEC,IAAI,EAAEC,SAAS,QAAQ,cAAc;AACpD,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,MAAM,QAAQ,qBAAqB;AAC5C,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,QAAQ,QAA8B,uBAAuB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,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kBAAkB","ignoreList":[]}
@@ -6,7 +6,7 @@ import { StyleSheet } from 'react-native';
6
6
  const QR_PLATE_BG = '#FFFFFF';
7
7
 
8
8
  /**
9
- * Shared styles for `OxyAuthChooser`'s views. Extracted from `OxyAccountDialog`
9
+ * Shared styles for `OxyAuthChooser`'s views. Extracted from `OxyAccountDialogScreen`
10
10
  * so both the Dialog-wrapped host and any bare host (e.g. a future
11
11
  * auth.oxy.so hub page) render identically without duplicating a StyleSheet.
12
12
  */
@@ -44,16 +44,30 @@ export const authChooserStyles = StyleSheet.create({
44
44
  fontSize: 12.5,
45
45
  marginTop: 1
46
46
  },
47
- addRow: {
47
+ /** Prominent current-account header (Google-style collapsed row). */
48
+ currentAccountRow: {
48
49
  flexDirection: 'row',
49
50
  alignItems: 'center',
50
51
  gap: 12,
51
- borderWidth: StyleSheet.hairlineWidth,
52
- borderStyle: 'dashed',
53
- borderRadius: 16,
54
- paddingVertical: 10,
55
- paddingHorizontal: 12,
56
- marginTop: 8
52
+ paddingVertical: 8,
53
+ paddingHorizontal: 4
54
+ },
55
+ currentAccountMeta: {
56
+ flex: 1,
57
+ minWidth: 0
58
+ },
59
+ currentAccountName: {
60
+ fontSize: 16,
61
+ fontWeight: '700'
62
+ },
63
+ currentAccountEmail: {
64
+ fontSize: 13,
65
+ marginTop: 2
66
+ },
67
+ manageButton: {
68
+ width: '100%',
69
+ borderRadius: 14,
70
+ marginTop: 4
57
71
  },
58
72
  addBadge: {
59
73
  width: 40,
@@ -63,10 +77,6 @@ export const authChooserStyles = StyleSheet.create({
63
77
  alignItems: 'center',
64
78
  justifyContent: 'center'
65
79
  },
66
- footerLinks: {
67
- alignItems: 'center',
68
- marginTop: 16
69
- },
70
80
  footerLink: {
71
81
  alignSelf: 'center',
72
82
  paddingVertical: 10,
@@ -1 +1 @@
1
- {"version":3,"names":["StyleSheet","QR_PLATE_BG","authChooserStyles","create","rows","width","gap","accountRow","flexDirection","alignItems","borderWidth","hairlineWidth","borderRadius","paddingVertical","paddingHorizontal","rowDisabled","opacity","avatarRing","padding","rowMeta","flex","minWidth","rowName","fontSize","fontWeight","rowHandle","marginTop","addRow","borderStyle","addBadge","height","justifyContent","footerLinks","footerLink","alignSelf","linkText","signInBlock","primaryButton","secondaryButton","usernameInput","dividerRow","marginVertical","dividerLine","dividerText","marginHorizontal","centeredBlock","mutedText","textAlign","qrHeadline","qrPlate","backgroundColor"],"sourceRoot":"../../../../src","sources":["ui/components/oxyAuthChooserStyles.ts"],"mappings":";;AAAA,SAASA,UAAU,QAAQ,cAAc;;AAEzC;AACA,MAAMC,WAAW,GAAG,SAAS;;AAE7B;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGF,UAAU,CAACG,MAAM,CAAC;EACjDC,IAAI,EAAE;IACJC,KAAK,EAAE,MAAM;IACbC,GAAG,EAAE;EACP,CAAC;EACDC,UAAU,EAAE;IACVC,aAAa,EAAE,KAAK;IACpBC,UAAU,EAAE,QAAQ;IACpBH,GAAG,EAAE,EAAE;IACPI,WAAW,EAAEV,UAAU,CAACW,aAAa;IACrCC,YAAY,EAAE,EAAE;IAChBC,eAAe,EAAE,EAAE;IACnBC,iBAAiB,EAAE;EACrB,CAAC;EACDC,WAAW,EAAE;IACXC,OAAO,EAAE;EACX,CAAC;EACDC,UAAU,EAAE;IACVL,YAAY,EAAE,IAAI;IAClBF,WAAW,EAAE,CAAC;IACdQ,OAAO,EAAE;EACX,CAAC;EACDC,OAAO,EAAE;IACPC,IAAI,EAAE,CAAC;IACPC,QAAQ,EAAE;EACZ,CAAC;EACDC,OAAO,EAAE;IACPC,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE;EACd,CAAC;EACDC,SAAS,EAAE;IACTF,QAAQ,EAAE,IAAI;IACdG,SAAS,EAAE;EACb,CAAC;EACDC,MAAM,EAAE;IACNnB,aAAa,EAAE,KAAK;IACpBC,UAAU,EAAE,QAAQ;IACpBH,GAAG,EAAE,EAAE;IACPI,WAAW,EAAEV,UAA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,EAAE9B,UAAU,CAACW;EACrB,CAAC;EACDgC,WAAW,EAAE;IACXC,gBAAgB,EAAE,EAAE;IACpBrB,QAAQ,EAAE;EACZ,CAAC;EACDsB,aAAa,EAAE;IACbpC,UAAU,EAAE,QAAQ;IACpBsB,cAAc,EAAE,QAAQ;IACxBzB,GAAG,EAAE,EAAE;IACPO,eAAe,EAAE;EACnB,CAAC;EACDiC,SAAS,EAAE;IACTvB,QAAQ,EAAE,EAAE;IACZwB,SAAS,EAAE;EACb,CAAC;EACDC,UAAU,EAAE;IACVzB,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE,KAAK;IACjBuB,SAAS,EAAE;EACb,CAAC;EACDE,OAAO,EAAE;IACP/B,OAAO,EAAE,EAAE;IACXN,YAAY,EAAE,EAAE;IAChBsC,eAAe,EAAEjD;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["StyleSheet","QR_PLATE_BG","authChooserStyles","create","rows","width","gap","accountRow","flexDirection","alignItems","borderWidth","hairlineWidth","borderRadius","paddingVertical","paddingHorizontal","rowDisabled","opacity","avatarRing","padding","rowMeta","flex","minWidth","rowName","fontSize","fontWeight","rowHandle","marginTop","currentAccountRow","currentAccountMeta","currentAccountName","currentAccountEmail","manageButton","addBadge","height","justifyContent","footerLink","alignSelf","linkText","signInBlock","primaryButton","secondaryButton","usernameInput","dividerRow","marginVertical","dividerLine","dividerText","marginHorizontal","centeredBlock","mutedText","textAlign","qrHeadline","qrPlate","backgroundColor"],"sourceRoot":"../../../../src","sources":["ui/components/oxyAuthChooserStyles.ts"],"mappings":";;AAAA,SAASA,UAAU,QAAQ,cAAc;;AAEzC;AACA,MAAMC,WAAW,GAAG,SAAS;;AAE7B;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGF,UAAU,CAACG,MAAM,CAAC;EACjDC,IAAI,EAAE;IACJC,KAAK,EAAE,MAAM;IACbC,GAAG,EAAE;EACP,CAAC;EACDC,UAAU,EAA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ACb,CAAC;EACDE,OAAO,EAAE;IACPjC,OAAO,EAAE,EAAE;IACXN,YAAY,EAAE,EAAE;IAChBwC,eAAe,EAAEnD;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,78 @@
1
+ "use strict";
2
+
3
+ import { Text, View } from 'react-native';
4
+ import { Button } from '@oxyhq/bloom/button';
5
+ import { useTheme } from '@oxyhq/bloom/theme';
6
+ import { surfaces } from '@oxyhq/bloom/surfaces';
7
+
8
+ /**
9
+ * A single choice in an {@link ActionSheetSurface} — a labelled button that
10
+ * resolves the surface with `value` when pressed.
11
+ */
12
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
13
+ const TITLE_STYLE = {
14
+ fontSize: 22,
15
+ fontWeight: '600',
16
+ lineHeight: 30
17
+ };
18
+ const MESSAGE_STYLE = {
19
+ fontSize: 16,
20
+ lineHeight: 22
21
+ };
22
+
23
+ /**
24
+ * A multi-choice action sheet rendered as a shared-stack surface — the
25
+ * many-option counterpart to Bloom's two-way `surfaces.confirm`. Each option
26
+ * button resolves the surface's `present()` promise with that option's `value`;
27
+ * cancel / backdrop / Escape resolve `undefined`. Presented via
28
+ * {@link presentActionSheet}.
29
+ */
30
+ export function ActionSheetSurface({
31
+ surface,
32
+ title,
33
+ message,
34
+ options,
35
+ cancelLabel
36
+ }) {
37
+ const theme = useTheme();
38
+ return /*#__PURE__*/_jsxs(View, {
39
+ children: [/*#__PURE__*/_jsx(Text, {
40
+ style: [TITLE_STYLE, {
41
+ color: theme.colors.text,
42
+ paddingBottom: message ? 4 : 16
43
+ }],
44
+ children: title
45
+ }), message ? /*#__PURE__*/_jsx(Text, {
46
+ style: [MESSAGE_STYLE, {
47
+ color: theme.colors.textSecondary,
48
+ paddingBottom: 16
49
+ }],
50
+ children: message
51
+ }) : null, /*#__PURE__*/_jsxs(View, {
52
+ style: {
53
+ gap: 8
54
+ },
55
+ children: [options.map(option => /*#__PURE__*/_jsx(Button, {
56
+ variant: option.destructive ? 'destructive' : 'primary',
57
+ onPress: () => surface.dismiss(option.value),
58
+ children: option.label
59
+ }, option.value)), /*#__PURE__*/_jsx(Button, {
60
+ variant: "secondary",
61
+ onPress: () => surface.dismiss(undefined),
62
+ children: cancelLabel
63
+ })]
64
+ })]
65
+ });
66
+ }
67
+
68
+ /**
69
+ * Present an {@link ActionSheetSurface} on the shared stack and resolve with the
70
+ * chosen option `value`, or `undefined` if cancelled/dismissed.
71
+ */
72
+ export function presentActionSheet(options) {
73
+ return surfaces.present(surface => /*#__PURE__*/_jsx(ActionSheetSurface, {
74
+ surface: surface,
75
+ ...options
76
+ }));
77
+ }
78
+ //# sourceMappingURL=ActionSheetSurface.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Text","View","Button","useTheme","surfaces","jsx","_jsx","jsxs","_jsxs","TITLE_STYLE","fontSize","fontWeight","lineHeight","MESSAGE_STYLE","ActionSheetSurface","surface","title","message","options","cancelLabel","theme","children","style","color","colors","text","paddingBottom","textSecondary","gap","map","option","variant","destructive","onPress","dismiss","value","label","undefined","presentActionSheet","present"],"sourceRoot":"../../../../../src","sources":["ui/components/surfaces/ActionSheetSurface.tsx"],"mappings":";;AACA,SAASA,IAAI,EAAEC,IAAI,QAAQ,cAAc;AACzC,SAASC,MAAM,QAAQ,qBAAqB;AAC5C,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,QAAQ,QAA8B,uBAAuB;;AAEtE;AACA;AACA;AACA;AAHA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAwBA,MAAMC,WAAW,GAAG;EAAEC,QAAQ,EAAE,EAAE;EAAEC,UAAU,EAAE,KAAc;EAAEC,UAAU,EAAE;AAAG,CAAC;AAChF,MAAMC,aAAa,GAAG;EAAEH,QAAQ,EAAE,EAAE;EAAEE,UAAU,EAAE;AAAG,CAAC;;AAEtD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASE,kBAAkBA,CAAmB;EACjD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D,EAC9B;EACtB,OAAOd,QAAQ,CAACmC,OAAO,CAAiBxB,OAAO,iBAC3CT,IAAA,CAACQ,kBAAkB;IAACC,OAAO,EAAEA,OAAQ;IAAA,GAAKG;EAAO,CAAG,CACvD,CAAC;AACN","ignoreList":[]}
@@ -19,6 +19,7 @@ import { useAuthOperations, clearPersistedAuthSafe } from "./hooks/useAuthOperat
19
19
  import { useDeviceManagement } from "../hooks/useDeviceManagement.js";
20
20
  import { getStorageKeys, createPlatformStorage } from "../utils/storageHelpers.js";
21
21
  import { showBottomSheet as globalShowBottomSheet } from "../navigation/bottomSheetManager.js";
22
+ import { presentDetached } from "../navigation/surfaces.js";
22
23
  import { useQueryClient, onlineManager } from '@tanstack/react-query';
23
24
  import { clearQueryCache } from "../hooks/queryClient.js";
24
25
  import { useAvatarPicker } from "../hooks/useAvatarPicker.js";
@@ -582,6 +583,14 @@ export const OxyProvider = ({
582
583
  handleWebSessionRef.current = handleWebSession;
583
584
  const commitSwitchedSessionRef = useRef(commitSwitchedSession);
584
585
  commitSwitchedSessionRef.current = commitSwitchedSession;
586
+
587
+ // The live AccountDialog surface (a stacked Bloom surface), while open — the
588
+ // SINGLE source of truth for "is the account dialog open". Held so
589
+ // `openAccountDialog` can no-op when already open and `closeAccountDialog` /
590
+ // `onSignedIn` can dismiss it. Its present→settle lifecycle is what drives the
591
+ // reactive `accountDialogOpen` mirror below: presenting flips it true, the
592
+ // surface settling (`result.finally`) flips it false — no other write site.
593
+ const accountDialogSurfaceRef = useRef(null);
585
594
  const accountDialogControllerRef = useRef(null);
586
595
  if (!accountDialogControllerRef.current) {
587
596
  accountDialogControllerRef.current = createAccountDialogController({
@@ -594,7 +603,13 @@ export const OxyProvider = ({
594
603
  socketFactory: io,
595
604
  commitSession: session => handleWebSessionRef.current(session),
596
605
  commitSwitchedSession: session => commitSwitchedSessionRef.current(session),
597
- onSignedIn: () => setAccountDialogOpen(false),
606
+ onSignedIn: () => {
607
+ // Dismiss the surface; its settle (`result.finally` below) is what flips
608
+ // `accountDialogOpen` false. The surface's present→settle lifecycle is the
609
+ // SINGLE source of truth for "is the account dialog open" — never a manual
610
+ // flip here.
611
+ accountDialogSurfaceRef.current?.dismiss();
612
+ },
598
613
  openUrl: url => {
599
614
  if (isWebBrowser()) {
600
615
  redirectToAuthorize(url);
@@ -618,11 +633,42 @@ export const OxyProvider = ({
618
633
  const accountDialogController = accountDialogControllerRef.current;
619
634
  const openAccountDialog = useCallback(view => {
620
635
  accountDialogControllerRef.current?.setView(view ?? 'accounts');
636
+ // Present the AccountDialog surface on the shared Bloom stack the FIRST time
637
+ // (subsequent opens just re-point the controller's view above). `presentDetached`
638
+ // keeps it OUT of the `showBottomSheet` route-surface lineage, so closing the
639
+ // bottom-sheet session never touches the account dialog and vice-versa. When a
640
+ // route surface (e.g. ManageAccount) is already open, this stacks the dialog
641
+ // ABOVE it; dismissing the dialog unwinds back to that surface.
642
+ if (!accountDialogSurfaceRef.current) {
643
+ const instance = presentDetached('AccountDialog', {
644
+ initialView: view ?? 'accounts'
645
+ }, {
646
+ placement: {
647
+ base: 'bottom',
648
+ md: 'center'
649
+ },
650
+ dismissOnBackdrop: false,
651
+ maxWidth: 420
652
+ });
653
+ accountDialogSurfaceRef.current = instance;
654
+ // The surface settling is the ONE place `accountDialogOpen` flips false —
655
+ // covering every dismiss path (close button, `onSignedIn`, programmatic
656
+ // `closeAccountDialog`, host unmount). So the stack owns the open state.
657
+ instance.result.finally(() => {
658
+ if (accountDialogSurfaceRef.current === instance) {
659
+ accountDialogSurfaceRef.current = null;
660
+ setAccountDialogOpen(false);
661
+ }
662
+ });
663
+ }
621
664
  setAccountDialogOpen(true);
622
665
  }, []);
623
666
  const closeAccountDialog = useCallback(() => {
624
667
  accountDialogControllerRef.current?.cancelSignIn();
625
- setAccountDialogOpen(false);
668
+ // Dismiss the surface; its settle (`result.finally` above) flips
669
+ // `accountDialogOpen` false. Do NOT flip it here — the surface lifecycle is
670
+ // the single source of truth, so a manual write would be a second authority.
671
+ accountDialogSurfaceRef.current?.dismiss();
626
672
  }, []);
627
673
 
628
674
  // Start driving the dialog on mount; tear it down on unmount.
@@ -851,8 +897,7 @@ export const OxyProvider = ({
851
897
  oxyServices,
852
898
  currentLanguage,
853
899
  activeSessionId,
854
- queryClient,
855
- showBottomSheet: showBottomSheetForContext
900
+ queryClient
856
901
  });
857
902
  const {
858
903
  accounts,