@oxyhq/services 22.9.0 → 22.11.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.
- package/lib/commonjs/index.js +24 -5
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/ui/components/AvatarCameraBadge.js +42 -0
- package/lib/commonjs/ui/components/AvatarCameraBadge.js.map +1 -0
- package/lib/commonjs/ui/components/{OxyAccountDialog.js → OxyAccountDialogScreen.js} +55 -133
- package/lib/commonjs/ui/components/OxyAccountDialogScreen.js.map +1 -0
- package/lib/commonjs/ui/components/OxyAuthChooser.js +657 -88
- package/lib/commonjs/ui/components/OxyAuthChooser.js.map +1 -1
- package/lib/commonjs/ui/components/OxyConsentScreen.js +1 -1
- package/lib/commonjs/ui/components/ProfileButton.js +15 -1
- package/lib/commonjs/ui/components/ProfileButton.js.map +1 -1
- package/lib/commonjs/ui/components/ProfileSummaryCard.js +3 -23
- package/lib/commonjs/ui/components/ProfileSummaryCard.js.map +1 -1
- package/lib/commonjs/ui/components/RequireOxyAuth.js +1 -1
- package/lib/commonjs/ui/components/SurfaceHeaderAction.js +63 -0
- package/lib/commonjs/ui/components/SurfaceHeaderAction.js.map +1 -0
- package/lib/commonjs/ui/components/SurfaceScreen.js +91 -8
- package/lib/commonjs/ui/components/SurfaceScreen.js.map +1 -1
- package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js +46 -29
- package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
- package/lib/commonjs/ui/components/modals/DeleteAccountModal.js +47 -23
- package/lib/commonjs/ui/components/modals/DeleteAccountModal.js.map +1 -1
- package/lib/commonjs/ui/components/oxyAuthChooserStyles.js +81 -19
- package/lib/commonjs/ui/components/oxyAuthChooserStyles.js.map +1 -1
- package/lib/commonjs/ui/components/photogrid/JustifiedPhotoGrid.js +83 -23
- package/lib/commonjs/ui/components/photogrid/JustifiedPhotoGrid.js.map +1 -1
- package/lib/commonjs/ui/components/surfaces/ActionSheetSurface.js +83 -0
- package/lib/commonjs/ui/components/surfaces/ActionSheetSurface.js.map +1 -0
- package/lib/commonjs/ui/context/OxyContext.js +79 -29
- package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
- package/lib/commonjs/ui/hooks/queries/queryKeys.js +18 -1
- package/lib/commonjs/ui/hooks/queries/queryKeys.js.map +1 -1
- package/lib/commonjs/ui/hooks/queries/useFileQueries.js +129 -0
- package/lib/commonjs/ui/hooks/queries/useFileQueries.js.map +1 -0
- package/lib/commonjs/ui/hooks/useAvatarPicker.js +38 -55
- package/lib/commonjs/ui/hooks/useAvatarPicker.js.map +1 -1
- package/lib/commonjs/ui/hooks/useReduceMotion.js +57 -0
- package/lib/commonjs/ui/hooks/useReduceMotion.js.map +1 -0
- package/lib/commonjs/ui/hooks/useSurfaceHeader.js +46 -0
- package/lib/commonjs/ui/hooks/useSurfaceHeader.js.map +1 -0
- package/lib/commonjs/ui/hooks/useSwitchableAccounts.js +1 -1
- package/lib/commonjs/ui/navigation/accountDialogManager.js +36 -2
- package/lib/commonjs/ui/navigation/accountDialogManager.js.map +1 -1
- package/lib/commonjs/ui/navigation/bottomSheetManager.js +5 -6
- package/lib/commonjs/ui/navigation/bottomSheetManager.js.map +1 -1
- package/lib/commonjs/ui/navigation/routes.js +4 -3
- package/lib/commonjs/ui/navigation/routes.js.map +1 -1
- package/lib/commonjs/ui/navigation/surfaceBackBridge.js +68 -0
- package/lib/commonjs/ui/navigation/surfaceBackBridge.js.map +1 -0
- package/lib/commonjs/ui/navigation/surfaceNavStack.js +62 -15
- package/lib/commonjs/ui/navigation/surfaceNavStack.js.map +1 -1
- package/lib/commonjs/ui/navigation/surfaceRegistry.js +84 -19
- package/lib/commonjs/ui/navigation/surfaceRegistry.js.map +1 -1
- package/lib/commonjs/ui/navigation/surfaces.js +139 -25
- package/lib/commonjs/ui/navigation/surfaces.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountMembersScreen.js +214 -283
- package/lib/commonjs/ui/screens/AccountMembersScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js +88 -118
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountVerificationScreen.js +22 -36
- package/lib/commonjs/ui/screens/AccountVerificationScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AppInfoScreen.js +219 -226
- package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AvatarCropScreen.js +287 -289
- package/lib/commonjs/ui/screens/AvatarCropScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ChangeAvatarScreen.js +301 -0
- package/lib/commonjs/ui/screens/ChangeAvatarScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/ConnectedAppsScreen.js +24 -39
- package/lib/commonjs/ui/screens/ConnectedAppsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CreateAccountScreen.js +136 -158
- package/lib/commonjs/ui/screens/CreateAccountScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/EditProfileFieldScreen.js +29 -36
- package/lib/commonjs/ui/screens/EditProfileFieldScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/EditProfileScreen.js +101 -109
- package/lib/commonjs/ui/screens/EditProfileScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FAQScreen.js +10 -15
- package/lib/commonjs/ui/screens/FAQScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FeedbackScreen.js +8 -16
- package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FileManagementScreen.js +403 -627
- package/lib/commonjs/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HelpSupportScreen.js +62 -69
- package/lib/commonjs/ui/screens/HelpSupportScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HistoryViewScreen.js +63 -79
- package/lib/commonjs/ui/screens/HistoryViewScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/LanguageSelectorScreen.js +69 -98
- package/lib/commonjs/ui/screens/LanguageSelectorScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/LearnMoreUsernamesScreen.js +8 -14
- package/lib/commonjs/ui/screens/LearnMoreUsernamesScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/LegalDocumentsScreen.js +77 -94
- package/lib/commonjs/ui/screens/LegalDocumentsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ManageAccountScreen.js +99 -134
- package/lib/commonjs/ui/screens/ManageAccountScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/NotificationsScreen.js +69 -76
- package/lib/commonjs/ui/screens/NotificationsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +3 -8
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PreferencesScreen.js +67 -74
- package/lib/commonjs/ui/screens/PreferencesScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js +55 -91
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PrivacySettingsScreen.js +291 -304
- package/lib/commonjs/ui/screens/PrivacySettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ProfileScreen.js +100 -114
- package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SavesCollectionsScreen.js +38 -45
- package/lib/commonjs/ui/screens/SavesCollectionsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SearchSettingsScreen.js +44 -57
- package/lib/commonjs/ui/screens/SearchSettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/UserLinksScreen.js +24 -31
- package/lib/commonjs/ui/screens/UserLinksScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/UserListScreen.js +14 -24
- package/lib/commonjs/ui/screens/UserListScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js +16 -48
- package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/fileManagement/FileLibraryError.js +63 -0
- package/lib/commonjs/ui/screens/fileManagement/FileLibraryError.js.map +1 -0
- package/lib/commonjs/ui/screens/fileManagement/PhotoPickerSection.js +54 -41
- package/lib/commonjs/ui/screens/fileManagement/PhotoPickerSection.js.map +1 -1
- package/lib/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.js +44 -81
- package/lib/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustAboutScreen.js +66 -75
- package/lib/commonjs/ui/screens/trust/TrustAboutScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustCenterScreen.js +111 -139
- package/lib/commonjs/ui/screens/trust/TrustCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustFAQScreen.js +13 -20
- package/lib/commonjs/ui/screens/trust/TrustFAQScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js +14 -27
- package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustRewardsScreen.js +68 -85
- package/lib/commonjs/ui/screens/trust/TrustRewardsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustRulesScreen.js +28 -36
- package/lib/commonjs/ui/screens/trust/TrustRulesScreen.js.map +1 -1
- package/lib/commonjs/ui/stores/resetSessionScopedStores.js +8 -3
- package/lib/commonjs/ui/stores/resetSessionScopedStores.js.map +1 -1
- package/lib/commonjs/ui/utils/avatarUtils.js +11 -2
- package/lib/commonjs/ui/utils/avatarUtils.js.map +1 -1
- package/lib/commonjs/ui/utils/fileManagement.js +0 -79
- package/lib/commonjs/ui/utils/fileManagement.js.map +1 -1
- package/lib/module/index.js +12 -5
- package/lib/module/index.js.map +1 -1
- package/lib/module/ui/components/AvatarCameraBadge.js +40 -0
- package/lib/module/ui/components/AvatarCameraBadge.js.map +1 -0
- package/lib/module/ui/components/{OxyAccountDialog.js → OxyAccountDialogScreen.js} +57 -135
- package/lib/module/ui/components/OxyAccountDialogScreen.js.map +1 -0
- package/lib/module/ui/components/OxyAuthChooser.js +659 -91
- package/lib/module/ui/components/OxyAuthChooser.js.map +1 -1
- package/lib/module/ui/components/OxyConsentScreen.js +1 -1
- package/lib/module/ui/components/ProfileButton.js +16 -2
- package/lib/module/ui/components/ProfileButton.js.map +1 -1
- package/lib/module/ui/components/ProfileSummaryCard.js +2 -23
- package/lib/module/ui/components/ProfileSummaryCard.js.map +1 -1
- package/lib/module/ui/components/RequireOxyAuth.js +1 -1
- package/lib/module/ui/components/SurfaceHeaderAction.js +58 -0
- package/lib/module/ui/components/SurfaceHeaderAction.js.map +1 -0
- package/lib/module/ui/components/SurfaceScreen.js +93 -10
- package/lib/module/ui/components/SurfaceScreen.js.map +1 -1
- package/lib/module/ui/components/fileManagement/FileDetailsModal.js +46 -29
- package/lib/module/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
- package/lib/module/ui/components/modals/DeleteAccountModal.js +46 -23
- package/lib/module/ui/components/modals/DeleteAccountModal.js.map +1 -1
- package/lib/module/ui/components/oxyAuthChooserStyles.js +81 -19
- package/lib/module/ui/components/oxyAuthChooserStyles.js.map +1 -1
- package/lib/module/ui/components/photogrid/JustifiedPhotoGrid.js +83 -25
- package/lib/module/ui/components/photogrid/JustifiedPhotoGrid.js.map +1 -1
- package/lib/module/ui/components/surfaces/ActionSheetSurface.js +78 -0
- package/lib/module/ui/components/surfaces/ActionSheetSurface.js.map +1 -0
- package/lib/module/ui/context/OxyContext.js +80 -30
- package/lib/module/ui/context/OxyContext.js.map +1 -1
- package/lib/module/ui/hooks/queries/queryKeys.js +16 -0
- package/lib/module/ui/hooks/queries/queryKeys.js.map +1 -1
- package/lib/module/ui/hooks/queries/useFileQueries.js +120 -0
- package/lib/module/ui/hooks/queries/useFileQueries.js.map +1 -0
- package/lib/module/ui/hooks/useAvatarPicker.js +38 -55
- package/lib/module/ui/hooks/useAvatarPicker.js.map +1 -1
- package/lib/module/ui/hooks/useReduceMotion.js +53 -0
- package/lib/module/ui/hooks/useReduceMotion.js.map +1 -0
- package/lib/module/ui/hooks/useSurfaceHeader.js +42 -0
- package/lib/module/ui/hooks/useSurfaceHeader.js.map +1 -0
- package/lib/module/ui/hooks/useSwitchableAccounts.js +1 -1
- package/lib/module/ui/navigation/accountDialogManager.js +34 -2
- package/lib/module/ui/navigation/accountDialogManager.js.map +1 -1
- package/lib/module/ui/navigation/bottomSheetManager.js +6 -7
- package/lib/module/ui/navigation/bottomSheetManager.js.map +1 -1
- package/lib/module/ui/navigation/routes.js +4 -3
- package/lib/module/ui/navigation/routes.js.map +1 -1
- package/lib/module/ui/navigation/surfaceBackBridge.js +63 -0
- package/lib/module/ui/navigation/surfaceBackBridge.js.map +1 -0
- package/lib/module/ui/navigation/surfaceNavStack.js +62 -15
- package/lib/module/ui/navigation/surfaceNavStack.js.map +1 -1
- package/lib/module/ui/navigation/surfaceRegistry.js +84 -19
- package/lib/module/ui/navigation/surfaceRegistry.js.map +1 -1
- package/lib/module/ui/navigation/surfaces.js +138 -26
- package/lib/module/ui/navigation/surfaces.js.map +1 -1
- package/lib/module/ui/screens/AccountMembersScreen.js +218 -286
- package/lib/module/ui/screens/AccountMembersScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSettingsScreen.js +92 -121
- package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountVerificationScreen.js +25 -38
- package/lib/module/ui/screens/AccountVerificationScreen.js.map +1 -1
- package/lib/module/ui/screens/AppInfoScreen.js +220 -227
- package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/module/ui/screens/AvatarCropScreen.js +289 -291
- package/lib/module/ui/screens/AvatarCropScreen.js.map +1 -1
- package/lib/module/ui/screens/ChangeAvatarScreen.js +298 -0
- package/lib/module/ui/screens/ChangeAvatarScreen.js.map +1 -0
- package/lib/module/ui/screens/ConnectedAppsScreen.js +26 -40
- package/lib/module/ui/screens/ConnectedAppsScreen.js.map +1 -1
- package/lib/module/ui/screens/CreateAccountScreen.js +139 -160
- package/lib/module/ui/screens/CreateAccountScreen.js.map +1 -1
- package/lib/module/ui/screens/EditProfileFieldScreen.js +32 -38
- package/lib/module/ui/screens/EditProfileFieldScreen.js.map +1 -1
- package/lib/module/ui/screens/EditProfileScreen.js +102 -110
- package/lib/module/ui/screens/EditProfileScreen.js.map +1 -1
- package/lib/module/ui/screens/FAQScreen.js +11 -15
- package/lib/module/ui/screens/FAQScreen.js.map +1 -1
- package/lib/module/ui/screens/FeedbackScreen.js +10 -17
- package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/module/ui/screens/FileManagementScreen.js +408 -631
- package/lib/module/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/HelpSupportScreen.js +64 -70
- package/lib/module/ui/screens/HelpSupportScreen.js.map +1 -1
- package/lib/module/ui/screens/HistoryViewScreen.js +65 -81
- package/lib/module/ui/screens/HistoryViewScreen.js.map +1 -1
- package/lib/module/ui/screens/LanguageSelectorScreen.js +71 -99
- package/lib/module/ui/screens/LanguageSelectorScreen.js.map +1 -1
- package/lib/module/ui/screens/LearnMoreUsernamesScreen.js +10 -15
- package/lib/module/ui/screens/LearnMoreUsernamesScreen.js.map +1 -1
- package/lib/module/ui/screens/LegalDocumentsScreen.js +78 -94
- package/lib/module/ui/screens/LegalDocumentsScreen.js.map +1 -1
- package/lib/module/ui/screens/ManageAccountScreen.js +102 -137
- package/lib/module/ui/screens/ManageAccountScreen.js.map +1 -1
- package/lib/module/ui/screens/NotificationsScreen.js +71 -77
- package/lib/module/ui/screens/NotificationsScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentGatewayScreen.js +4 -9
- package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/module/ui/screens/PreferencesScreen.js +69 -75
- package/lib/module/ui/screens/PreferencesScreen.js.map +1 -1
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js +58 -93
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/module/ui/screens/PrivacySettingsScreen.js +293 -305
- package/lib/module/ui/screens/PrivacySettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/ProfileScreen.js +102 -116
- package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/module/ui/screens/SavesCollectionsScreen.js +40 -46
- package/lib/module/ui/screens/SavesCollectionsScreen.js.map +1 -1
- package/lib/module/ui/screens/SearchSettingsScreen.js +46 -58
- package/lib/module/ui/screens/SearchSettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/UserLinksScreen.js +26 -32
- package/lib/module/ui/screens/UserLinksScreen.js.map +1 -1
- package/lib/module/ui/screens/UserListScreen.js +14 -24
- package/lib/module/ui/screens/UserListScreen.js.map +1 -1
- package/lib/module/ui/screens/WelcomeNewUserScreen.js +17 -49
- package/lib/module/ui/screens/WelcomeNewUserScreen.js.map +1 -1
- package/lib/module/ui/screens/fileManagement/FileLibraryError.js +59 -0
- package/lib/module/ui/screens/fileManagement/FileLibraryError.js.map +1 -0
- package/lib/module/ui/screens/fileManagement/PhotoPickerSection.js +54 -42
- package/lib/module/ui/screens/fileManagement/PhotoPickerSection.js.map +1 -1
- package/lib/module/ui/screens/fileManagement/hooks/useFileUploadState.js +45 -81
- package/lib/module/ui/screens/fileManagement/hooks/useFileUploadState.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustAboutScreen.js +67 -75
- package/lib/module/ui/screens/trust/TrustAboutScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustCenterScreen.js +112 -139
- package/lib/module/ui/screens/trust/TrustCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustFAQScreen.js +15 -21
- package/lib/module/ui/screens/trust/TrustFAQScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js +14 -26
- package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustRewardsScreen.js +69 -85
- package/lib/module/ui/screens/trust/TrustRewardsScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustRulesScreen.js +30 -37
- package/lib/module/ui/screens/trust/TrustRulesScreen.js.map +1 -1
- package/lib/module/ui/stores/resetSessionScopedStores.js +8 -3
- package/lib/module/ui/stores/resetSessionScopedStores.js.map +1 -1
- package/lib/module/ui/utils/avatarUtils.js +11 -2
- package/lib/module/ui/utils/avatarUtils.js.map +1 -1
- package/lib/module/ui/utils/fileManagement.js +0 -78
- package/lib/module/ui/utils/fileManagement.js.map +1 -1
- package/lib/typescript/commonjs/index.d.ts +2 -0
- package/lib/typescript/commonjs/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/AvatarCameraBadge.d.ts +4 -0
- package/lib/typescript/commonjs/ui/components/AvatarCameraBadge.d.ts.map +1 -0
- package/lib/typescript/{module/ui/components/OxyAccountDialog.d.ts → commonjs/ui/components/OxyAccountDialogScreen.d.ts} +5 -4
- package/lib/typescript/commonjs/ui/components/OxyAccountDialogScreen.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts +3 -3
- package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/ProfileButton.d.ts +2 -2
- package/lib/typescript/commonjs/ui/components/ProfileButton.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/ProfileSummaryCard.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/RequireOxyAuth.d.ts +1 -1
- package/lib/typescript/commonjs/ui/components/SurfaceHeaderAction.d.ts +16 -0
- package/lib/typescript/commonjs/ui/components/SurfaceHeaderAction.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/SurfaceScreen.d.ts +3 -4
- package/lib/typescript/commonjs/ui/components/SurfaceScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/fileManagement/FileDetailsModal.d.ts +14 -4
- package/lib/typescript/commonjs/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/modals/DeleteAccountModal.d.ts +17 -2
- package/lib/typescript/commonjs/ui/components/modals/DeleteAccountModal.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/oxyAuthChooserStyles.d.ts +75 -13
- package/lib/typescript/commonjs/ui/components/oxyAuthChooserStyles.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/photogrid/JustifiedPhotoGrid.d.ts +10 -8
- package/lib/typescript/commonjs/ui/components/photogrid/JustifiedPhotoGrid.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/surfaces/ActionSheetSurface.d.ts +38 -0
- package/lib/typescript/commonjs/ui/components/surfaces/ActionSheetSurface.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/hooks/queries/queryKeys.d.ts +9 -0
- package/lib/typescript/commonjs/ui/hooks/queries/queryKeys.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/hooks/queries/useFileQueries.d.ts +50 -0
- package/lib/typescript/commonjs/ui/hooks/queries/useFileQueries.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/hooks/useAvatarPicker.d.ts +17 -16
- package/lib/typescript/commonjs/ui/hooks/useAvatarPicker.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/hooks/useReduceMotion.d.ts +14 -0
- package/lib/typescript/commonjs/ui/hooks/useReduceMotion.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/hooks/useSurfaceHeader.d.ts +31 -0
- package/lib/typescript/commonjs/ui/hooks/useSurfaceHeader.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/hooks/useSwitchableAccounts.d.ts +1 -1
- package/lib/typescript/commonjs/ui/navigation/accountDialogManager.d.ts +27 -2
- package/lib/typescript/commonjs/ui/navigation/accountDialogManager.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/navigation/bottomSheetManager.d.ts +4 -5
- package/lib/typescript/commonjs/ui/navigation/bottomSheetManager.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/navigation/routes.d.ts +1 -1
- package/lib/typescript/commonjs/ui/navigation/routes.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/navigation/surfaceBackBridge.d.ts +16 -0
- package/lib/typescript/commonjs/ui/navigation/surfaceBackBridge.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/navigation/surfaceNavStack.d.ts +21 -0
- package/lib/typescript/commonjs/ui/navigation/surfaceNavStack.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/navigation/surfaceRegistry.d.ts +101 -23
- package/lib/typescript/commonjs/ui/navigation/surfaceRegistry.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/navigation/surfaces.d.ts +42 -11
- package/lib/typescript/commonjs/ui/navigation/surfaces.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/AccountMembersScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/AccountVerificationScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/AppInfoScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/AvatarCropScreen.d.ts +18 -9
- package/lib/typescript/commonjs/ui/screens/AvatarCropScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/ChangeAvatarScreen.d.ts +34 -0
- package/lib/typescript/commonjs/ui/screens/ChangeAvatarScreen.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/screens/ConnectedAppsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/CreateAccountScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/EditProfileScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/FAQScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/FeedbackScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/FileManagementScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/HelpSupportScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/HistoryViewScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/LearnMoreUsernamesScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/LegalDocumentsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts +1 -1
- package/lib/typescript/commonjs/ui/screens/ManageAccountScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/NotificationsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/PaymentGatewayScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/PreferencesScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/ProfileScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/SavesCollectionsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/SearchSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/UserLinksScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/UserListScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/WelcomeNewUserScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/fileManagement/FileLibraryError.d.ts +23 -0
- package/lib/typescript/commonjs/ui/screens/fileManagement/FileLibraryError.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/screens/fileManagement/PhotoPickerSection.d.ts +4 -0
- package/lib/typescript/commonjs/ui/screens/fileManagement/PhotoPickerSection.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.d.ts +10 -2
- package/lib/typescript/commonjs/ui/screens/fileManagement/hooks/useFileUploadState.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/trust/TrustAboutScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/trust/TrustCenterScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/trust/TrustFAQScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/trust/TrustLeaderboardScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/trust/TrustRewardsScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/trust/TrustRulesScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/stores/resetSessionScopedStores.d.ts +8 -1
- package/lib/typescript/commonjs/ui/stores/resetSessionScopedStores.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/types/navigation.d.ts +10 -0
- package/lib/typescript/commonjs/ui/types/navigation.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/utils/avatarUtils.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/utils/fileManagement.d.ts +0 -48
- package/lib/typescript/commonjs/ui/utils/fileManagement.d.ts.map +1 -1
- package/lib/typescript/module/index.d.ts +2 -0
- package/lib/typescript/module/index.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/AvatarCameraBadge.d.ts +4 -0
- package/lib/typescript/module/ui/components/AvatarCameraBadge.d.ts.map +1 -0
- package/lib/typescript/{commonjs/ui/components/OxyAccountDialog.d.ts → module/ui/components/OxyAccountDialogScreen.d.ts} +5 -4
- package/lib/typescript/module/ui/components/OxyAccountDialogScreen.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts +3 -3
- package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/ProfileButton.d.ts +2 -2
- package/lib/typescript/module/ui/components/ProfileButton.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/ProfileSummaryCard.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/RequireOxyAuth.d.ts +1 -1
- package/lib/typescript/module/ui/components/SurfaceHeaderAction.d.ts +16 -0
- package/lib/typescript/module/ui/components/SurfaceHeaderAction.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/SurfaceScreen.d.ts +3 -4
- package/lib/typescript/module/ui/components/SurfaceScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/fileManagement/FileDetailsModal.d.ts +14 -4
- package/lib/typescript/module/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/modals/DeleteAccountModal.d.ts +17 -2
- package/lib/typescript/module/ui/components/modals/DeleteAccountModal.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/oxyAuthChooserStyles.d.ts +75 -13
- package/lib/typescript/module/ui/components/oxyAuthChooserStyles.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/photogrid/JustifiedPhotoGrid.d.ts +10 -8
- package/lib/typescript/module/ui/components/photogrid/JustifiedPhotoGrid.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/surfaces/ActionSheetSurface.d.ts +38 -0
- package/lib/typescript/module/ui/components/surfaces/ActionSheetSurface.d.ts.map +1 -0
- package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/module/ui/hooks/queries/queryKeys.d.ts +9 -0
- package/lib/typescript/module/ui/hooks/queries/queryKeys.d.ts.map +1 -1
- package/lib/typescript/module/ui/hooks/queries/useFileQueries.d.ts +50 -0
- package/lib/typescript/module/ui/hooks/queries/useFileQueries.d.ts.map +1 -0
- package/lib/typescript/module/ui/hooks/useAvatarPicker.d.ts +17 -16
- package/lib/typescript/module/ui/hooks/useAvatarPicker.d.ts.map +1 -1
- package/lib/typescript/module/ui/hooks/useReduceMotion.d.ts +14 -0
- package/lib/typescript/module/ui/hooks/useReduceMotion.d.ts.map +1 -0
- package/lib/typescript/module/ui/hooks/useSurfaceHeader.d.ts +31 -0
- package/lib/typescript/module/ui/hooks/useSurfaceHeader.d.ts.map +1 -0
- package/lib/typescript/module/ui/hooks/useSwitchableAccounts.d.ts +1 -1
- package/lib/typescript/module/ui/navigation/accountDialogManager.d.ts +27 -2
- package/lib/typescript/module/ui/navigation/accountDialogManager.d.ts.map +1 -1
- package/lib/typescript/module/ui/navigation/bottomSheetManager.d.ts +4 -5
- package/lib/typescript/module/ui/navigation/bottomSheetManager.d.ts.map +1 -1
- package/lib/typescript/module/ui/navigation/routes.d.ts +1 -1
- package/lib/typescript/module/ui/navigation/routes.d.ts.map +1 -1
- package/lib/typescript/module/ui/navigation/surfaceBackBridge.d.ts +16 -0
- package/lib/typescript/module/ui/navigation/surfaceBackBridge.d.ts.map +1 -0
- package/lib/typescript/module/ui/navigation/surfaceNavStack.d.ts +21 -0
- package/lib/typescript/module/ui/navigation/surfaceNavStack.d.ts.map +1 -1
- package/lib/typescript/module/ui/navigation/surfaceRegistry.d.ts +101 -23
- package/lib/typescript/module/ui/navigation/surfaceRegistry.d.ts.map +1 -1
- package/lib/typescript/module/ui/navigation/surfaces.d.ts +42 -11
- package/lib/typescript/module/ui/navigation/surfaces.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/AccountMembersScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/AccountVerificationScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/AppInfoScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/AvatarCropScreen.d.ts +18 -9
- package/lib/typescript/module/ui/screens/AvatarCropScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/ChangeAvatarScreen.d.ts +34 -0
- package/lib/typescript/module/ui/screens/ChangeAvatarScreen.d.ts.map +1 -0
- package/lib/typescript/module/ui/screens/ConnectedAppsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/CreateAccountScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/EditProfileFieldScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/EditProfileScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/FAQScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/FeedbackScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/FileManagementScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/HelpSupportScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/HistoryViewScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/LearnMoreUsernamesScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/LegalDocumentsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts +1 -1
- package/lib/typescript/module/ui/screens/ManageAccountScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/NotificationsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/PaymentGatewayScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/PreferencesScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/ProfileScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/SavesCollectionsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/SearchSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/UserLinksScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/UserListScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/WelcomeNewUserScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/fileManagement/FileLibraryError.d.ts +23 -0
- package/lib/typescript/module/ui/screens/fileManagement/FileLibraryError.d.ts.map +1 -0
- package/lib/typescript/module/ui/screens/fileManagement/PhotoPickerSection.d.ts +4 -0
- package/lib/typescript/module/ui/screens/fileManagement/PhotoPickerSection.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/fileManagement/hooks/useFileUploadState.d.ts +10 -2
- package/lib/typescript/module/ui/screens/fileManagement/hooks/useFileUploadState.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/trust/TrustAboutScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/trust/TrustCenterScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/trust/TrustFAQScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/trust/TrustLeaderboardScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/trust/TrustRewardsScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/trust/TrustRulesScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/stores/resetSessionScopedStores.d.ts +8 -1
- package/lib/typescript/module/ui/stores/resetSessionScopedStores.d.ts.map +1 -1
- package/lib/typescript/module/ui/types/navigation.d.ts +10 -0
- package/lib/typescript/module/ui/types/navigation.d.ts.map +1 -1
- package/lib/typescript/module/ui/utils/avatarUtils.d.ts.map +1 -1
- package/lib/typescript/module/ui/utils/fileManagement.d.ts +0 -48
- package/lib/typescript/module/ui/utils/fileManagement.d.ts.map +1 -1
- package/package.json +9 -5
- package/src/index.ts +12 -5
- package/src/ui/components/AvatarCameraBadge.tsx +35 -0
- package/src/ui/components/{OxyAccountDialog.tsx → OxyAccountDialogScreen.tsx} +50 -116
- package/src/ui/components/OxyAuthChooser.tsx +743 -86
- package/src/ui/components/OxyConsentScreen.tsx +1 -1
- package/src/ui/components/ProfileButton.tsx +18 -3
- package/src/ui/components/ProfileSummaryCard.tsx +2 -25
- package/src/ui/components/RequireOxyAuth.tsx +1 -1
- package/src/ui/components/SurfaceHeaderAction.tsx +60 -0
- package/src/ui/components/SurfaceScreen.tsx +108 -14
- package/src/ui/components/fileManagement/FileDetailsModal.tsx +50 -36
- package/src/ui/components/modals/DeleteAccountModal.tsx +47 -26
- package/src/ui/components/oxyAuthChooserStyles.ts +78 -16
- package/src/ui/components/photogrid/JustifiedPhotoGrid.tsx +158 -84
- package/src/ui/components/photogrid/__tests__/chunkPhotos.test.ts +51 -0
- package/src/ui/components/surfaces/ActionSheetSurface.tsx +98 -0
- package/src/ui/context/OxyContext.tsx +79 -25
- package/src/ui/hooks/queries/queryKeys.ts +15 -0
- package/src/ui/hooks/queries/useFileQueries.ts +162 -0
- package/src/ui/hooks/useAvatarPicker.ts +46 -74
- package/src/ui/hooks/useReduceMotion.ts +58 -0
- package/src/ui/hooks/useSurfaceHeader.ts +57 -0
- package/src/ui/hooks/useSwitchableAccounts.ts +1 -1
- package/src/ui/navigation/__tests__/getSurfaceConfig.test.ts +55 -7
- package/src/ui/navigation/__tests__/surfaceNavStack.test.ts +149 -0
- package/src/ui/navigation/accountDialogManager.ts +42 -2
- package/src/ui/navigation/bottomSheetManager.ts +6 -7
- package/src/ui/navigation/routes.ts +6 -4
- package/src/ui/navigation/surfaceBackBridge.ts +69 -0
- package/src/ui/navigation/surfaceNavStack.ts +72 -9
- package/src/ui/navigation/surfaceRegistry.ts +164 -24
- package/src/ui/navigation/surfaces.ts +137 -30
- package/src/ui/screens/AccountMembersScreen.tsx +39 -100
- package/src/ui/screens/AccountSettingsScreen.tsx +32 -54
- package/src/ui/screens/AccountVerificationScreen.tsx +23 -51
- package/src/ui/screens/AppInfoScreen.tsx +6 -13
- package/src/ui/screens/AvatarCropScreen.tsx +340 -311
- package/src/ui/screens/ChangeAvatarScreen.tsx +359 -0
- package/src/ui/screens/ConnectedAppsScreen.tsx +39 -60
- package/src/ui/screens/CreateAccountScreen.tsx +13 -39
- package/src/ui/screens/EditProfileFieldScreen.tsx +30 -48
- package/src/ui/screens/EditProfileScreen.tsx +7 -16
- package/src/ui/screens/FAQScreen.tsx +9 -13
- package/src/ui/screens/FeedbackScreen.tsx +8 -22
- package/src/ui/screens/FileManagementScreen.tsx +370 -610
- package/src/ui/screens/HelpSupportScreen.tsx +7 -13
- package/src/ui/screens/HistoryViewScreen.tsx +26 -31
- package/src/ui/screens/LanguageSelectorScreen.tsx +12 -46
- package/src/ui/screens/LearnMoreUsernamesScreen.tsx +8 -16
- package/src/ui/screens/LegalDocumentsScreen.tsx +7 -22
- package/src/ui/screens/ManageAccountScreen.tsx +96 -165
- package/src/ui/screens/NotificationsScreen.tsx +7 -13
- package/src/ui/screens/PaymentGatewayScreen.tsx +3 -10
- package/src/ui/screens/PreferencesScreen.tsx +7 -13
- package/src/ui/screens/PremiumSubscriptionScreen.tsx +52 -90
- package/src/ui/screens/PrivacySettingsScreen.tsx +9 -21
- package/src/ui/screens/ProfileScreen.tsx +9 -11
- package/src/ui/screens/SavesCollectionsScreen.tsx +7 -13
- package/src/ui/screens/SearchSettingsScreen.tsx +9 -21
- package/src/ui/screens/UserLinksScreen.tsx +7 -14
- package/src/ui/screens/UserListScreen.tsx +2 -5
- package/src/ui/screens/WelcomeNewUserScreen.tsx +18 -48
- package/src/ui/screens/fileManagement/FileLibraryError.tsx +56 -0
- package/src/ui/screens/fileManagement/PhotoPickerSection.tsx +56 -46
- package/src/ui/screens/fileManagement/hooks/useFileUploadState.ts +55 -71
- package/src/ui/screens/trust/TrustAboutScreen.tsx +10 -17
- package/src/ui/screens/trust/TrustCenterScreen.tsx +9 -28
- package/src/ui/screens/trust/TrustFAQScreen.tsx +15 -18
- package/src/ui/screens/trust/TrustLeaderboardScreen.tsx +3 -5
- package/src/ui/screens/trust/TrustRewardsScreen.tsx +11 -26
- package/src/ui/screens/trust/TrustRulesScreen.tsx +10 -13
- package/src/ui/stores/resetSessionScopedStores.ts +8 -3
- package/src/ui/types/navigation.ts +10 -0
- package/src/ui/utils/avatarUtils.ts +11 -2
- package/src/ui/utils/fileManagement.ts +1 -101
- package/lib/commonjs/ui/components/Header.js +0 -305
- package/lib/commonjs/ui/components/Header.js.map +0 -1
- package/lib/commonjs/ui/components/OxyAccountDialog.js.map +0 -1
- package/lib/commonjs/ui/stores/fileStore.js +0 -153
- package/lib/commonjs/ui/stores/fileStore.js.map +0 -1
- package/lib/module/ui/components/Header.js +0 -299
- package/lib/module/ui/components/Header.js.map +0 -1
- package/lib/module/ui/components/OxyAccountDialog.js.map +0 -1
- package/lib/module/ui/stores/fileStore.js +0 -145
- package/lib/module/ui/stores/fileStore.js.map +0 -1
- package/lib/typescript/commonjs/ui/components/Header.d.ts +0 -33
- package/lib/typescript/commonjs/ui/components/Header.d.ts.map +0 -1
- package/lib/typescript/commonjs/ui/components/OxyAccountDialog.d.ts.map +0 -1
- package/lib/typescript/commonjs/ui/stores/fileStore.d.ts +0 -31
- package/lib/typescript/commonjs/ui/stores/fileStore.d.ts.map +0 -1
- package/lib/typescript/module/ui/components/Header.d.ts +0 -33
- package/lib/typescript/module/ui/components/Header.d.ts.map +0 -1
- package/lib/typescript/module/ui/components/OxyAccountDialog.d.ts.map +0 -1
- package/lib/typescript/module/ui/stores/fileStore.d.ts +0 -31
- package/lib/typescript/module/ui/stores/fileStore.d.ts.map +0 -1
- package/src/ui/components/Header.tsx +0 -224
- package/src/ui/stores/fileStore.ts +0 -118
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
2
|
import { useCallback, useRef, useState } from 'react';
|
|
3
|
+
import { useQueryClient } from '@tanstack/react-query';
|
|
3
4
|
import { toast } from '@oxyhq/bloom';
|
|
4
5
|
import type { AssetUploadInput, FileMetadata } from '@oxyhq/core';
|
|
5
|
-
import { useFileStore } from '../../../stores/fileStore';
|
|
6
6
|
import type { useUploadFile } from '../../../hooks/mutations/useAccountMutations';
|
|
7
|
+
import { queryKeys } from '../../../hooks/queries/queryKeys';
|
|
8
|
+
import {
|
|
9
|
+
prependFileToCache,
|
|
10
|
+
removeFileFromCache,
|
|
11
|
+
replaceFileInCache,
|
|
12
|
+
} from '../../../hooks/queries/useFileQueries';
|
|
7
13
|
import { convertDocumentPickerAssetToFile, formatFileSize } from '../../../utils/fileManagement';
|
|
8
14
|
import {
|
|
9
15
|
createPendingUploadFile,
|
|
@@ -17,6 +23,15 @@ import {
|
|
|
17
23
|
loadDocumentPicker,
|
|
18
24
|
} from '../shared';
|
|
19
25
|
|
|
26
|
+
/** Aggregate progress across a multi-file upload. */
|
|
27
|
+
export interface FileUploadAggregateProgress {
|
|
28
|
+
current: number;
|
|
29
|
+
total: number;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/** Minimum time the "Uploading…" indicator stays visible (anti-flash). */
|
|
33
|
+
const MIN_BANNER_MS = 600;
|
|
34
|
+
|
|
20
35
|
function revokePreviewUrl(preview: string | undefined): void {
|
|
21
36
|
if (preview?.startsWith('blob:')) {
|
|
22
37
|
URL.revokeObjectURL(preview);
|
|
@@ -47,7 +62,6 @@ export interface UseFileUploadStateParams {
|
|
|
47
62
|
onClose?: () => void;
|
|
48
63
|
selectedIds: Set<string>;
|
|
49
64
|
setSelectedIds: React.Dispatch<React.SetStateAction<Set<string>>>;
|
|
50
|
-
loadFiles: (mode?: 'initial' | 'refresh' | 'silent' | 'more') => Promise<void> | void;
|
|
51
65
|
t: (key: string, vars?: Record<string, string | number>) => string;
|
|
52
66
|
}
|
|
53
67
|
|
|
@@ -56,6 +70,10 @@ export interface UseFileUploadStateResult {
|
|
|
56
70
|
isPickingDocument: boolean;
|
|
57
71
|
pendingFiles: PendingUploadFile[];
|
|
58
72
|
showUploadPreview: boolean;
|
|
73
|
+
/** Whether an upload is in flight (drives the "Uploading…" banner). */
|
|
74
|
+
uploading: boolean;
|
|
75
|
+
/** Aggregate progress across the current upload, or null. */
|
|
76
|
+
uploadProgress: FileUploadAggregateProgress | null;
|
|
59
77
|
handleFileUpload: () => Promise<void>;
|
|
60
78
|
handleConfirmUpload: () => Promise<void>;
|
|
61
79
|
handleCancelUpload: () => void;
|
|
@@ -80,25 +98,23 @@ export const useFileUploadState = ({
|
|
|
80
98
|
onClose,
|
|
81
99
|
selectedIds,
|
|
82
100
|
setSelectedIds,
|
|
83
|
-
loadFiles,
|
|
84
101
|
t,
|
|
85
102
|
}: UseFileUploadStateParams): UseFileUploadStateResult => {
|
|
86
103
|
const [isPickingDocument, setIsPickingDocument] = useState(false);
|
|
87
104
|
const [pendingFiles, setPendingFiles] = useState<PendingUploadFile[]>([]);
|
|
88
105
|
const [showUploadPreview, setShowUploadPreview] = useState(false);
|
|
106
|
+
const [uploading, setUploading] = useState(false);
|
|
107
|
+
const [uploadProgress, setUploadProgress] = useState<FileUploadAggregateProgress | null>(null);
|
|
89
108
|
|
|
109
|
+
const queryClient = useQueryClient();
|
|
90
110
|
const uploadStartRef = useRef<number | null>(null);
|
|
91
|
-
const MIN_BANNER_MS = 600;
|
|
92
|
-
|
|
93
|
-
const storeSetUploading = useFileStore(s => s.setUploading);
|
|
94
|
-
const storeSetUploadProgress = useFileStore(s => s.setUploadProgress);
|
|
95
111
|
|
|
96
112
|
const endUpload = useCallback(() => {
|
|
97
113
|
const started = uploadStartRef.current;
|
|
98
114
|
const elapsed = started ? Date.now() - started : MIN_BANNER_MS;
|
|
99
115
|
const remaining = elapsed < MIN_BANNER_MS ? MIN_BANNER_MS - elapsed : 0;
|
|
100
116
|
setTimeout(() => {
|
|
101
|
-
|
|
117
|
+
setUploading(false);
|
|
102
118
|
uploadStartRef.current = null;
|
|
103
119
|
}, remaining);
|
|
104
120
|
}, []);
|
|
@@ -108,7 +124,7 @@ export const useFileUploadState = ({
|
|
|
108
124
|
if (!targetUserId) return []; // Guard clause to ensure userId is defined
|
|
109
125
|
const uploadedFiles: FileMetadata[] = [];
|
|
110
126
|
try {
|
|
111
|
-
|
|
127
|
+
setUploadProgress({ current: 0, total: selectedFiles.length });
|
|
112
128
|
const maxSize = 50 * 1024 * 1024; // 50MB
|
|
113
129
|
const oversizedFiles = selectedFiles.filter(file => candidateSize(file) > maxSize);
|
|
114
130
|
if (oversizedFiles.length > 0) {
|
|
@@ -120,20 +136,16 @@ export const useFileUploadState = ({
|
|
|
120
136
|
let failureCount = 0;
|
|
121
137
|
const errors: string[] = [];
|
|
122
138
|
for (let i = 0; i < selectedFiles.length; i++) {
|
|
123
|
-
|
|
139
|
+
setUploadProgress({ current: i + 1, total: selectedFiles.length });
|
|
124
140
|
const raw = selectedFiles[i];
|
|
125
141
|
const fileName = candidateName(raw, `file-${i + 1}`);
|
|
126
142
|
const fileSize = candidateSize(raw);
|
|
127
143
|
const fileType = candidateType(raw);
|
|
128
|
-
const optimisticId = `temp-${Date.now()}-${i}-${Math.random().toString(36).
|
|
144
|
+
const optimisticId = `temp-${Date.now()}-${i}-${Math.random().toString(36).slice(2, 11)}`; // Unique ID per file
|
|
129
145
|
|
|
130
146
|
try {
|
|
131
147
|
// Validate file before upload
|
|
132
148
|
if (!raw || !fileName || fileSize <= 0) {
|
|
133
|
-
const errorMsg = `Invalid file: ${fileName}`;
|
|
134
|
-
if (__DEV__) {
|
|
135
|
-
console.error('Upload validation failed:', { file: raw, error: errorMsg });
|
|
136
|
-
}
|
|
137
149
|
failureCount++;
|
|
138
150
|
errors.push(`${fileName}: Invalid file (missing name or size)`);
|
|
139
151
|
continue;
|
|
@@ -158,7 +170,7 @@ export const useFileUploadState = ({
|
|
|
158
170
|
metadata: optimisticMetadata,
|
|
159
171
|
variants: [],
|
|
160
172
|
};
|
|
161
|
-
|
|
173
|
+
prependFileToCache(queryClient, targetUserId, optimisticFile);
|
|
162
174
|
|
|
163
175
|
// Use the mutation hook with authentication handling
|
|
164
176
|
const result = await uploadFileMutation.mutateAsync({
|
|
@@ -179,41 +191,26 @@ export const useFileUploadState = ({
|
|
|
179
191
|
metadata: f.metadata || {},
|
|
180
192
|
variants: f.variants || [],
|
|
181
193
|
};
|
|
182
|
-
//
|
|
183
|
-
|
|
184
|
-
useFileStore.getState().addFile(merged, { prepend: true });
|
|
194
|
+
// Swap the optimistic temp entry for the persisted record.
|
|
195
|
+
replaceFileInCache(queryClient, targetUserId, optimisticId, merged);
|
|
185
196
|
uploadedFiles.push(merged);
|
|
186
197
|
successCount++;
|
|
187
198
|
} else {
|
|
188
199
|
// Upload succeeded but the API returned no file payload,
|
|
189
200
|
// so we cannot build a real entry. Drop the optimistic
|
|
190
201
|
// placeholder instead of stranding a `temp-…` id (which
|
|
191
|
-
// would leak into asset URLs); the
|
|
192
|
-
//
|
|
193
|
-
|
|
194
|
-
if (__DEV__) {
|
|
195
|
-
console.warn('Upload completed but no file data returned:', { fileName, result });
|
|
196
|
-
}
|
|
202
|
+
// would leak into asset URLs); the reconcile invalidation
|
|
203
|
+
// below re-fetches the persisted record.
|
|
204
|
+
removeFileFromCache(queryClient, targetUserId, optimisticId);
|
|
197
205
|
// Still count as success if upload didn't throw
|
|
198
206
|
successCount++;
|
|
199
207
|
}
|
|
200
208
|
} catch (error: unknown) {
|
|
201
209
|
failureCount++;
|
|
202
210
|
const errorMessage = getErrorMessage(error) || 'Upload failed';
|
|
203
|
-
|
|
204
|
-
errors.push(fullError);
|
|
205
|
-
if (__DEV__) {
|
|
206
|
-
console.error('File upload failed:', {
|
|
207
|
-
fileName,
|
|
208
|
-
fileSize,
|
|
209
|
-
fileType,
|
|
210
|
-
error: errorMessage,
|
|
211
|
-
stack: (error instanceof Error) ? error.stack : undefined
|
|
212
|
-
});
|
|
213
|
-
}
|
|
214
|
-
|
|
211
|
+
errors.push(`${fileName}: ${errorMessage}`);
|
|
215
212
|
// Remove optimistic file on error (use the same optimisticId from above)
|
|
216
|
-
|
|
213
|
+
removeFileFromCache(queryClient, targetUserId, optimisticId);
|
|
217
214
|
}
|
|
218
215
|
}
|
|
219
216
|
|
|
@@ -228,12 +225,15 @@ export const useFileUploadState = ({
|
|
|
228
225
|
: '';
|
|
229
226
|
toast.error(`${t('fileManagement.toasts.uploadFailed', { count: failureCount })}${errorDetails}`);
|
|
230
227
|
}
|
|
231
|
-
//
|
|
232
|
-
|
|
228
|
+
// Reconcile against the server (picks up generated variants / metadata)
|
|
229
|
+
// — replaces the old silent-reload timer.
|
|
230
|
+
if (successCount > 0) {
|
|
231
|
+
queryClient.invalidateQueries({ queryKey: queryKeys.files.list(targetUserId) });
|
|
232
|
+
}
|
|
233
233
|
} catch (error: unknown) {
|
|
234
234
|
toast.error(getErrorMessage(error) || t('fileManagement.toasts.uploadError'));
|
|
235
235
|
} finally {
|
|
236
|
-
|
|
236
|
+
setUploadProgress(null);
|
|
237
237
|
}
|
|
238
238
|
return uploadedFiles;
|
|
239
239
|
};
|
|
@@ -245,35 +245,23 @@ export const useFileUploadState = ({
|
|
|
245
245
|
for (const file of selectedFiles) {
|
|
246
246
|
// Validate file has required properties
|
|
247
247
|
if (!file) {
|
|
248
|
-
if (__DEV__) {
|
|
249
|
-
console.error('Invalid file: file is null or undefined');
|
|
250
|
-
}
|
|
251
248
|
toast.error(t('fileManagement.toasts.invalidFileMissing'));
|
|
252
249
|
continue;
|
|
253
250
|
}
|
|
254
251
|
|
|
255
252
|
const name = candidateName(file, '');
|
|
256
253
|
if (!name) {
|
|
257
|
-
if (__DEV__) {
|
|
258
|
-
console.error('Invalid file: missing or invalid name property', file);
|
|
259
|
-
}
|
|
260
254
|
toast.error(t('fileManagement.toasts.invalidFileName'));
|
|
261
255
|
continue;
|
|
262
256
|
}
|
|
263
257
|
|
|
264
258
|
const size = (file as { size?: number }).size;
|
|
265
259
|
if (size === undefined || size === null || Number.isNaN(size)) {
|
|
266
|
-
if (__DEV__) {
|
|
267
|
-
console.error('Invalid file: missing or invalid size property', file);
|
|
268
|
-
}
|
|
269
260
|
toast.error(t('fileManagement.toasts.invalidFileSize', { name }));
|
|
270
261
|
continue;
|
|
271
262
|
}
|
|
272
263
|
|
|
273
264
|
if (size <= 0) {
|
|
274
|
-
if (__DEV__) {
|
|
275
|
-
console.error('Invalid file: file size is zero or negative', file);
|
|
276
|
-
}
|
|
277
265
|
toast.error(t('fileManagement.toasts.fileEmpty', { name }));
|
|
278
266
|
continue;
|
|
279
267
|
}
|
|
@@ -303,11 +291,8 @@ export const useFileUploadState = ({
|
|
|
303
291
|
(typeof Blob !== 'undefined' && file instanceof Blob)) {
|
|
304
292
|
preview = URL.createObjectURL(file as Blob);
|
|
305
293
|
}
|
|
306
|
-
} catch
|
|
307
|
-
|
|
308
|
-
console.warn('Failed to create preview URL:', error);
|
|
309
|
-
}
|
|
310
|
-
// Preview is optional, continue without it
|
|
294
|
+
} catch {
|
|
295
|
+
// Preview is optional — continue without it.
|
|
311
296
|
}
|
|
312
297
|
}
|
|
313
298
|
}
|
|
@@ -330,23 +315,23 @@ export const useFileUploadState = ({
|
|
|
330
315
|
|
|
331
316
|
setShowUploadPreview(false);
|
|
332
317
|
uploadStartRef.current = Date.now();
|
|
333
|
-
|
|
334
|
-
|
|
318
|
+
setUploading(true);
|
|
319
|
+
setUploadProgress(null);
|
|
335
320
|
|
|
336
321
|
try {
|
|
337
322
|
const filesToUpload = pendingFiles.map(pf => pf.file);
|
|
338
|
-
|
|
323
|
+
setUploadProgress({ current: 0, total: filesToUpload.length });
|
|
339
324
|
const uploadedFiles = await processFileUploads(filesToUpload);
|
|
340
325
|
|
|
341
326
|
// Cleanup preview URLs
|
|
342
|
-
|
|
327
|
+
for (const pf of pendingFiles) {
|
|
343
328
|
revokePreviewUrl(pf.preview);
|
|
344
|
-
}
|
|
329
|
+
}
|
|
345
330
|
setPendingFiles([]);
|
|
346
331
|
|
|
347
332
|
// If in selectMode, automatically select the uploaded file(s)
|
|
348
333
|
if (selectMode && uploadedFiles.length > 0) {
|
|
349
|
-
//
|
|
334
|
+
// Defer one tick so the query cache has settled before selecting.
|
|
350
335
|
setTimeout(() => {
|
|
351
336
|
const fileToSelect = uploadedFiles[0];
|
|
352
337
|
if (!multiSelect && fileToSelect) {
|
|
@@ -359,11 +344,11 @@ export const useFileUploadState = ({
|
|
|
359
344
|
}
|
|
360
345
|
} else if (multiSelect) {
|
|
361
346
|
// Multi-select mode - add all uploaded files to selection
|
|
362
|
-
|
|
347
|
+
for (const file of uploadedFiles) {
|
|
363
348
|
if (!selectedIds.has(file.id)) {
|
|
364
349
|
setSelectedIds(prev => new Set(prev).add(file.id));
|
|
365
350
|
}
|
|
366
|
-
}
|
|
351
|
+
}
|
|
367
352
|
}
|
|
368
353
|
}, 500);
|
|
369
354
|
}
|
|
@@ -377,9 +362,9 @@ export const useFileUploadState = ({
|
|
|
377
362
|
|
|
378
363
|
const handleCancelUpload = () => {
|
|
379
364
|
// Cleanup preview URLs
|
|
380
|
-
|
|
365
|
+
for (const pf of pendingFiles) {
|
|
381
366
|
revokePreviewUrl(pf.preview);
|
|
382
|
-
}
|
|
367
|
+
}
|
|
383
368
|
setPendingFiles([]);
|
|
384
369
|
setShowUploadPreview(false);
|
|
385
370
|
};
|
|
@@ -487,9 +472,6 @@ export const useFileUploadState = ({
|
|
|
487
472
|
toast.error(t('fileManagement.toasts.noFilesProcessed'));
|
|
488
473
|
}
|
|
489
474
|
} catch (error: unknown) {
|
|
490
|
-
if (__DEV__) {
|
|
491
|
-
console.error('File upload error:', error);
|
|
492
|
-
}
|
|
493
475
|
if (getErrorMessage(error)?.includes('expo-document-picker') || getErrorMessage(error)?.includes('Different document picking in progress')) {
|
|
494
476
|
if (getErrorMessage(error)?.includes('Different document picking in progress')) {
|
|
495
477
|
toast.error(t('fileManagement.toasts.waitForSelection'));
|
|
@@ -509,6 +491,8 @@ export const useFileUploadState = ({
|
|
|
509
491
|
isPickingDocument,
|
|
510
492
|
pendingFiles,
|
|
511
493
|
showUploadPreview,
|
|
494
|
+
uploading,
|
|
495
|
+
uploadProgress,
|
|
512
496
|
handleFileUpload,
|
|
513
497
|
handleConfirmUpload,
|
|
514
498
|
handleCancelUpload,
|
|
@@ -1,32 +1,26 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import { View
|
|
2
|
+
import { View } from 'react-native';
|
|
3
3
|
import { useTheme } from '@oxyhq/bloom/theme';
|
|
4
4
|
import { H4, Text } from '@oxyhq/bloom/typography';
|
|
5
5
|
import { IconCircle } from '@oxyhq/bloom/icon-circle';
|
|
6
6
|
import { BenefitList, BenefitRow } from '@oxyhq/bloom/benefit-list';
|
|
7
7
|
import * as Icons from '@oxyhq/bloom/icons';
|
|
8
8
|
import type { BaseScreenProps } from '../../types/navigation';
|
|
9
|
-
import Header from '../../components/Header';
|
|
10
9
|
import { useI18n } from '../../hooks/useI18n';
|
|
10
|
+
import { useSurfaceHeader } from '../../hooks/useSurfaceHeader';
|
|
11
11
|
|
|
12
|
-
const TrustAboutScreen: React.FC<BaseScreenProps> = (
|
|
12
|
+
const TrustAboutScreen: React.FC<BaseScreenProps> = () => {
|
|
13
13
|
const { t } = useI18n();
|
|
14
14
|
const bloomTheme = useTheme();
|
|
15
15
|
const iconColor = bloomTheme.colors.primary;
|
|
16
16
|
|
|
17
|
+
useSurfaceHeader({
|
|
18
|
+
title: t('trust.about.title') || 'About Oxy Trust',
|
|
19
|
+
subtitle: t('trust.about.subtitle') || 'Learn about the reputation system',
|
|
20
|
+
});
|
|
21
|
+
|
|
17
22
|
return (
|
|
18
|
-
|
|
19
|
-
<Header
|
|
20
|
-
title={t('trust.about.title') || 'About Oxy Trust'}
|
|
21
|
-
subtitle={t('trust.about.subtitle') || 'Learn about the reputation system'}
|
|
22
|
-
onBack={goBack}
|
|
23
|
-
elevation="subtle"
|
|
24
|
-
/>
|
|
25
|
-
<ScrollView
|
|
26
|
-
className="flex-1 px-screen-margin"
|
|
27
|
-
showsVerticalScrollIndicator={false}
|
|
28
|
-
contentContainerClassName="pb-space-32"
|
|
29
|
-
>
|
|
23
|
+
<View className="px-screen-margin pt-space-16 pb-space-32">
|
|
30
24
|
<View className="items-center py-space-24 gap-space-12">
|
|
31
25
|
<IconCircle icon={Icons.ShieldCheck_Stroke2_Corner0_Rounded} />
|
|
32
26
|
<Text className="font-sans text-body text-text-secondary text-center">
|
|
@@ -69,8 +63,7 @@ const TrustAboutScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
69
63
|
<Text className="font-sans text-body text-text-secondary">
|
|
70
64
|
{t('trust.about.why.text') || 'Your reputation and trust tier unlock special features and recognition in the Oxy Ecosystem. The more you contribute, the more you earn!'}
|
|
71
65
|
</Text>
|
|
72
|
-
</
|
|
73
|
-
</View>
|
|
66
|
+
</View>
|
|
74
67
|
);
|
|
75
68
|
};
|
|
76
69
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
2
|
import { useEffect, useMemo, useState } from 'react';
|
|
3
|
-
import { View,
|
|
3
|
+
import { View, StyleSheet } from 'react-native';
|
|
4
4
|
import type { ReputationTransaction, TrustTier } from '@oxyhq/core';
|
|
5
5
|
import { Ionicons } from '@expo/vector-icons';
|
|
6
6
|
import { Chip } from '@oxyhq/bloom/chip';
|
|
@@ -8,16 +8,14 @@ import { useTheme } from '@oxyhq/bloom/theme';
|
|
|
8
8
|
import { H1, Text } from '@oxyhq/bloom/typography';
|
|
9
9
|
import { SettingsListGroup, SettingsListItem } from '@oxyhq/bloom/settings-list';
|
|
10
10
|
import type { BaseScreenProps } from '../../types/navigation';
|
|
11
|
-
import Header from '../../components/Header';
|
|
12
11
|
import { SettingsIcon } from '../../components/SettingsIcon';
|
|
13
12
|
import { Loading } from '@oxyhq/bloom/loading';
|
|
14
13
|
import { useI18n } from '../../hooks/useI18n';
|
|
14
|
+
import { useSurfaceHeader } from '../../hooks/useSurfaceHeader';
|
|
15
15
|
import { useOxy } from '../../context/OxyContext';
|
|
16
16
|
import { getTrustTierLabel } from './trustTier';
|
|
17
17
|
|
|
18
18
|
const TrustCenterScreen: React.FC<BaseScreenProps> = ({
|
|
19
|
-
onClose,
|
|
20
|
-
goBack,
|
|
21
19
|
navigate,
|
|
22
20
|
}) => {
|
|
23
21
|
// Reputation/trust is the ACTIVE account's standing (the org/project/bot
|
|
@@ -61,38 +59,28 @@ const TrustCenterScreen: React.FC<BaseScreenProps> = ({
|
|
|
61
59
|
);
|
|
62
60
|
|
|
63
61
|
const title = t('trust.center.title') || 'Trust Center';
|
|
62
|
+
useSurfaceHeader({ title });
|
|
64
63
|
|
|
65
64
|
if (!isAuthenticated) {
|
|
66
65
|
return (
|
|
67
|
-
|
|
68
|
-
<Header title={title} onBack={goBack || onClose} elevation="subtle" />
|
|
69
|
-
<View style={styles.center}>
|
|
66
|
+
<View className="items-center py-space-40">
|
|
70
67
|
<Text className="text-text font-medium text-base">
|
|
71
68
|
{t('common.status.notSignedIn') || 'Not signed in'}
|
|
72
69
|
</Text>
|
|
73
70
|
</View>
|
|
74
|
-
</View>
|
|
75
71
|
);
|
|
76
72
|
}
|
|
77
73
|
|
|
78
74
|
if (isLoading) {
|
|
79
75
|
return (
|
|
80
|
-
|
|
81
|
-
<Header title={title} onBack={goBack || onClose} elevation="subtle" />
|
|
82
|
-
<View style={styles.center}>
|
|
76
|
+
<View className="items-center py-space-40">
|
|
83
77
|
<Loading size="large" color={primaryColor} />
|
|
84
78
|
</View>
|
|
85
|
-
</View>
|
|
86
79
|
);
|
|
87
80
|
}
|
|
88
81
|
|
|
89
82
|
return (
|
|
90
|
-
|
|
91
|
-
<Header title={title} onBack={goBack || onClose} elevation="subtle" />
|
|
92
|
-
<ScrollView
|
|
93
|
-
className="flex-1"
|
|
94
|
-
contentContainerClassName="px-screen-margin pb-space-24"
|
|
95
|
-
>
|
|
83
|
+
<View className="px-screen-margin pt-space-16 pb-space-24">
|
|
96
84
|
{/* Balance hero card */}
|
|
97
85
|
<View className="items-center bg-fill-secondary rounded-radius-20 px-space-20 py-space-24 mb-space-16">
|
|
98
86
|
<H1 style={{ color: primaryColor }}>{reputationTotal ?? 0}</H1>
|
|
@@ -250,20 +238,13 @@ const TrustCenterScreen: React.FC<BaseScreenProps> = ({
|
|
|
250
238
|
{error}
|
|
251
239
|
</Text>
|
|
252
240
|
) : null}
|
|
253
|
-
</
|
|
254
|
-
</View>
|
|
241
|
+
</View>
|
|
255
242
|
);
|
|
256
243
|
};
|
|
257
244
|
|
|
258
|
-
// Layout-only styles:
|
|
259
|
-
//
|
|
260
|
-
// roles live here — those use Bloom token classes.
|
|
245
|
+
// Layout-only styles: the info caption's measured max width. No color, spacing,
|
|
246
|
+
// radius, or typography roles live here — those use Bloom token classes.
|
|
261
247
|
const styles = StyleSheet.create({
|
|
262
|
-
center: {
|
|
263
|
-
flex: 1,
|
|
264
|
-
alignItems: 'center',
|
|
265
|
-
justifyContent: 'center',
|
|
266
|
-
},
|
|
267
248
|
infoText: {
|
|
268
249
|
maxWidth: 320,
|
|
269
250
|
},
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { useState, useMemo, useCallback } from 'react';
|
|
2
|
-
import { View
|
|
2
|
+
import { View } from 'react-native';
|
|
3
3
|
import type { BaseScreenProps } from '../../types/navigation';
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
4
|
+
import { useSurfaceHeader } from '../../hooks/useSurfaceHeader';
|
|
5
|
+
import { Search } from '@oxyhq/bloom/search';
|
|
6
6
|
import {
|
|
7
7
|
Accordion,
|
|
8
8
|
AccordionItem,
|
|
@@ -18,13 +18,18 @@ const FAQ_KEYS = ['what', 'earn', 'lose', 'use', 'transfer', 'support'] as const
|
|
|
18
18
|
* TrustFAQScreen
|
|
19
19
|
*
|
|
20
20
|
* Frequently asked questions about Oxy Trust, rendered with the shared Bloom
|
|
21
|
-
* Accordion (single-expand) +
|
|
21
|
+
* Accordion (single-expand) + Search. Styling is centralized Bloom token
|
|
22
22
|
* classes; the Bloom Accordion owns its own expand/collapse animation, so no
|
|
23
23
|
* `LayoutAnimation` is used here.
|
|
24
24
|
*/
|
|
25
|
-
const TrustFAQScreen: React.FC<BaseScreenProps> = (
|
|
25
|
+
const TrustFAQScreen: React.FC<BaseScreenProps> = () => {
|
|
26
26
|
const { t } = useI18n();
|
|
27
27
|
|
|
28
|
+
useSurfaceHeader({
|
|
29
|
+
title: t('trust.faq.title') || 'Trust FAQ',
|
|
30
|
+
subtitle: t('trust.faq.subtitle') || 'Frequently asked questions about Oxy Trust',
|
|
31
|
+
});
|
|
32
|
+
|
|
28
33
|
const [search, setSearch] = useState('');
|
|
29
34
|
const [expanded, setExpanded] = useState<string | undefined>(undefined);
|
|
30
35
|
|
|
@@ -51,17 +56,9 @@ const TrustFAQScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
51
56
|
);
|
|
52
57
|
|
|
53
58
|
return (
|
|
54
|
-
|
|
55
|
-
<Header
|
|
56
|
-
title={t('trust.faq.title') || 'Trust FAQ'}
|
|
57
|
-
subtitle={t('trust.faq.subtitle') || 'Frequently asked questions about Oxy Trust'}
|
|
58
|
-
subtitleVariant="muted"
|
|
59
|
-
onBack={goBack}
|
|
60
|
-
elevation="subtle"
|
|
61
|
-
/>
|
|
62
|
-
|
|
59
|
+
<>
|
|
63
60
|
<View className="px-screen-margin pt-space-20 pb-space-12">
|
|
64
|
-
<
|
|
61
|
+
<Search
|
|
65
62
|
label={t('trust.faq.search') || 'Search FAQ...'}
|
|
66
63
|
value={search}
|
|
67
64
|
onChangeText={setSearch}
|
|
@@ -70,7 +67,7 @@ const TrustFAQScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
70
67
|
/>
|
|
71
68
|
</View>
|
|
72
69
|
|
|
73
|
-
<
|
|
70
|
+
<View className="px-screen-margin">
|
|
74
71
|
{filteredFaqs.length === 0 ? (
|
|
75
72
|
<Text className="text-text-secondary text-center p-space-40">
|
|
76
73
|
{t('trust.faq.noResults', { query: search }) ||
|
|
@@ -96,8 +93,8 @@ const TrustFAQScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
96
93
|
))}
|
|
97
94
|
</Accordion>
|
|
98
95
|
)}
|
|
99
|
-
</
|
|
100
|
-
|
|
96
|
+
</View>
|
|
97
|
+
</>
|
|
101
98
|
);
|
|
102
99
|
};
|
|
103
100
|
|
|
@@ -16,8 +16,8 @@ import { Button } from '@oxyhq/bloom/button';
|
|
|
16
16
|
import { Ionicons } from '@expo/vector-icons';
|
|
17
17
|
import type { BaseScreenProps } from '../../types/navigation';
|
|
18
18
|
import { Avatar } from '@oxyhq/bloom/avatar';
|
|
19
|
-
import Header from '../../components/Header';
|
|
20
19
|
import { useI18n } from '../../hooks/useI18n';
|
|
20
|
+
import { useSurfaceHeader } from '../../hooks/useSurfaceHeader';
|
|
21
21
|
import { useOxy } from '../../context/OxyContext';
|
|
22
22
|
import { getTrustTierLabel } from './trustTier';
|
|
23
23
|
|
|
@@ -27,7 +27,7 @@ const ERROR_ICON_SIZE = 48;
|
|
|
27
27
|
/** Ranks within the podium (1–3) get a highlighted row surface. */
|
|
28
28
|
const PODIUM_RANK = 3;
|
|
29
29
|
|
|
30
|
-
const TrustLeaderboardScreen: React.FC<BaseScreenProps> = ({
|
|
30
|
+
const TrustLeaderboardScreen: React.FC<BaseScreenProps> = ({ navigate }) => {
|
|
31
31
|
const { oxyServices, user: currentUser } = useOxy();
|
|
32
32
|
const { t, locale } = useI18n();
|
|
33
33
|
const bloomTheme = useTheme();
|
|
@@ -61,6 +61,7 @@ const TrustLeaderboardScreen: React.FC<BaseScreenProps> = ({ goBack, navigate })
|
|
|
61
61
|
|
|
62
62
|
const title = t('trust.leaderboard.title') || 'Trust Leaderboard';
|
|
63
63
|
const subtitle = t('trust.leaderboard.subtitle') || 'Top contributors in the community';
|
|
64
|
+
useSurfaceHeader({ title, subtitle });
|
|
64
65
|
|
|
65
66
|
const handleEntryPress = useCallback(
|
|
66
67
|
(entry: ReputationLeaderboardEntry) => {
|
|
@@ -130,7 +131,6 @@ const TrustLeaderboardScreen: React.FC<BaseScreenProps> = ({ goBack, navigate })
|
|
|
130
131
|
if (isLoading) {
|
|
131
132
|
return (
|
|
132
133
|
<View className="flex-1 bg-bg">
|
|
133
|
-
<Header title={title} subtitle={subtitle} onBack={goBack} elevation="subtle" />
|
|
134
134
|
<View style={styles.center}>
|
|
135
135
|
<ActivityIndicator size="large" color={bloomTheme.colors.primary} />
|
|
136
136
|
</View>
|
|
@@ -141,7 +141,6 @@ const TrustLeaderboardScreen: React.FC<BaseScreenProps> = ({ goBack, navigate })
|
|
|
141
141
|
if (error) {
|
|
142
142
|
return (
|
|
143
143
|
<View className="flex-1 bg-bg">
|
|
144
|
-
<Header title={title} subtitle={subtitle} onBack={goBack} elevation="subtle" />
|
|
145
144
|
<View style={styles.center} className="px-space-32 gap-space-16">
|
|
146
145
|
<Ionicons name="alert-circle" size={ERROR_ICON_SIZE} color={bloomTheme.colors.error} />
|
|
147
146
|
<Text className="text-text-secondary text-base text-center">
|
|
@@ -157,7 +156,6 @@ const TrustLeaderboardScreen: React.FC<BaseScreenProps> = ({ goBack, navigate })
|
|
|
157
156
|
|
|
158
157
|
return (
|
|
159
158
|
<View className="flex-1 bg-bg">
|
|
160
|
-
<Header title={title} subtitle={subtitle} onBack={goBack} elevation="subtle" />
|
|
161
159
|
<FlatList
|
|
162
160
|
data={leaderboard}
|
|
163
161
|
renderItem={renderEntry}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
2
|
import { useMemo, useState, useEffect } from 'react';
|
|
3
|
-
import { View, StyleSheet
|
|
3
|
+
import { View, StyleSheet } from 'react-native';
|
|
4
4
|
import type { BaseScreenProps } from '../../types/navigation';
|
|
5
|
-
import
|
|
5
|
+
import { useSurfaceHeader } from '../../hooks/useSurfaceHeader';
|
|
6
6
|
import { Ionicons } from '@expo/vector-icons';
|
|
7
7
|
import { useTheme } from '@oxyhq/bloom/theme';
|
|
8
8
|
import { H1, H4, H5, Text } from '@oxyhq/bloom/typography';
|
|
@@ -75,11 +75,16 @@ const RARITY_DARKEN = 0.4;
|
|
|
75
75
|
const ACCENT_LIGHTEN = 0.1;
|
|
76
76
|
const LOCKED_OPACITY = 0.5;
|
|
77
77
|
|
|
78
|
-
const TrustRewardsScreen: React.FC<BaseScreenProps> = (
|
|
78
|
+
const TrustRewardsScreen: React.FC<BaseScreenProps> = () => {
|
|
79
79
|
const { t } = useI18n();
|
|
80
80
|
// Reputation/trust is the ACTIVE account's standing (the org/project/bot
|
|
81
81
|
// when switched, else the personal user).
|
|
82
82
|
const { user, oxyServices, isAuthenticated } = useOxy();
|
|
83
|
+
|
|
84
|
+
useSurfaceHeader({
|
|
85
|
+
title: t('trust.rewards.title') || 'Trust Rewards',
|
|
86
|
+
subtitle: t('trust.rewards.subtitle') || 'Unlock special features and recognition',
|
|
87
|
+
});
|
|
83
88
|
const [reputationTotal, setReputationTotal] = useState<number>(0);
|
|
84
89
|
const [, setIsLoading] = useState(true);
|
|
85
90
|
|
|
@@ -360,19 +365,11 @@ const TrustRewardsScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
360
365
|
|
|
361
366
|
if (!isAuthenticated) {
|
|
362
367
|
return (
|
|
363
|
-
|
|
364
|
-
<Header
|
|
365
|
-
title={t('trust.rewards.title') || 'Trust Rewards'}
|
|
366
|
-
subtitle={t('trust.rewards.subtitle') || 'Unlock special features and recognition'}
|
|
367
|
-
onBack={goBack}
|
|
368
|
-
elevation="subtle"
|
|
369
|
-
/>
|
|
370
|
-
<View className="flex-1 items-center justify-center px-screen-margin">
|
|
368
|
+
<View className="items-center justify-center px-screen-margin py-space-40">
|
|
371
369
|
<Text className="text-text text-base text-center">
|
|
372
370
|
{t('common.status.notSignedIn') || 'Not signed in'}
|
|
373
371
|
</Text>
|
|
374
372
|
</View>
|
|
375
|
-
</View>
|
|
376
373
|
);
|
|
377
374
|
}
|
|
378
375
|
|
|
@@ -381,18 +378,7 @@ const TrustRewardsScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
381
378
|
: 0;
|
|
382
379
|
|
|
383
380
|
return (
|
|
384
|
-
|
|
385
|
-
<Header
|
|
386
|
-
title={t('trust.rewards.title') || 'Trust Rewards'}
|
|
387
|
-
subtitle={t('trust.rewards.subtitle') || 'Unlock special features and recognition'}
|
|
388
|
-
onBack={goBack}
|
|
389
|
-
elevation="subtle"
|
|
390
|
-
/>
|
|
391
|
-
<ScrollView
|
|
392
|
-
className="flex-1"
|
|
393
|
-
contentContainerClassName="px-screen-margin pt-space-20 pb-space-40"
|
|
394
|
-
showsVerticalScrollIndicator={false}
|
|
395
|
-
>
|
|
381
|
+
<View className="px-screen-margin pt-space-20 pb-space-40">
|
|
396
382
|
{/* Stats Header */}
|
|
397
383
|
<View className="bg-fill rounded-radius-20 p-space-20 mb-space-24">
|
|
398
384
|
<View className="flex-row justify-between items-center mb-space-16">
|
|
@@ -458,8 +444,7 @@ const TrustRewardsScreen: React.FC<BaseScreenProps> = ({ goBack }) => {
|
|
|
458
444
|
</View>
|
|
459
445
|
</>
|
|
460
446
|
)}
|
|
461
|
-
</
|
|
462
|
-
</View>
|
|
447
|
+
</View>
|
|
463
448
|
);
|
|
464
449
|
};
|
|
465
450
|
|