@oxyhq/services 5.13.40 → 5.15.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/README.md +130 -54
- package/lib/commonjs/assets/assets/lottie/welcomeheader_background_op1.json +1 -0
- package/lib/commonjs/assets/lottie/welcomeheader_background_op1.json +1 -0
- package/lib/commonjs/core/HttpService.js +94 -4
- package/lib/commonjs/core/HttpService.js.map +1 -1
- package/lib/commonjs/core/OxyServices.base.js +3 -1
- package/lib/commonjs/core/OxyServices.base.js.map +1 -1
- package/lib/commonjs/core/mixins/OxyServices.assets.js +213 -22
- package/lib/commonjs/core/mixins/OxyServices.assets.js.map +1 -1
- package/lib/commonjs/core/mixins/OxyServices.auth.js +70 -99
- package/lib/commonjs/core/mixins/OxyServices.auth.js.map +1 -1
- package/lib/commonjs/crypto/index.js +33 -0
- package/lib/commonjs/crypto/index.js.map +1 -0
- package/lib/commonjs/crypto/keyManager.js +208 -0
- package/lib/commonjs/crypto/keyManager.js.map +1 -0
- package/lib/commonjs/crypto/recoveryPhrase.js +137 -0
- package/lib/commonjs/crypto/recoveryPhrase.js.map +1 -0
- package/lib/commonjs/crypto/signatureService.js +230 -0
- package/lib/commonjs/crypto/signatureService.js.map +1 -0
- package/lib/commonjs/i18n/locales/en-US.json +4 -0
- package/lib/commonjs/index.js +22 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/ui/components/ActivityIndicator.js +203 -0
- package/lib/commonjs/ui/components/ActivityIndicator.js.map +1 -0
- package/lib/commonjs/ui/components/AutoHeightScrollView.js +46 -0
- package/lib/commonjs/ui/components/AutoHeightScrollView.js.map +1 -0
- package/lib/commonjs/ui/components/BottomSheet.js +407 -0
- package/lib/commonjs/ui/components/BottomSheet.js.map +1 -0
- package/lib/commonjs/ui/components/BottomSheetRouter.js +366 -0
- package/lib/commonjs/ui/components/BottomSheetRouter.js.map +1 -0
- package/lib/commonjs/ui/components/CrossFadeIcon.js +106 -0
- package/lib/commonjs/ui/components/CrossFadeIcon.js.map +1 -0
- package/lib/commonjs/ui/components/EmptyState.js +41 -0
- package/lib/commonjs/ui/components/EmptyState.js.map +1 -0
- package/lib/commonjs/ui/components/GroupedItem.js +87 -82
- package/lib/commonjs/ui/components/GroupedItem.js.map +1 -1
- package/lib/commonjs/ui/components/GroupedSection.js +25 -25
- package/lib/commonjs/ui/components/GroupedSection.js.map +1 -1
- package/lib/commonjs/ui/components/Header.js +111 -47
- package/lib/commonjs/ui/components/Header.js.map +1 -1
- package/lib/commonjs/ui/components/HelperText.js +103 -0
- package/lib/commonjs/ui/components/HelperText.js.map +1 -0
- package/lib/commonjs/ui/components/Icon.js +109 -0
- package/lib/commonjs/ui/components/Icon.js.map +1 -0
- package/lib/commonjs/ui/components/IconButton/IconButton.js +159 -0
- package/lib/commonjs/ui/components/IconButton/IconButton.js.map +1 -0
- package/lib/commonjs/ui/components/IconButton/utils.js +155 -0
- package/lib/commonjs/ui/components/IconButton/utils.js.map +1 -0
- package/lib/commonjs/ui/components/LoadingState.js +47 -0
- package/lib/commonjs/ui/components/LoadingState.js.map +1 -0
- package/lib/commonjs/ui/components/OxyPayButton.js +1 -14
- package/lib/commonjs/ui/components/OxyPayButton.js.map +1 -1
- package/lib/commonjs/ui/components/OxyProvider.js +41 -372
- package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
- package/lib/commonjs/ui/components/OxySignInButton.js +9 -13
- package/lib/commonjs/ui/components/OxySignInButton.js.map +1 -1
- package/lib/commonjs/ui/components/ProfileCard.js +7 -4
- package/lib/commonjs/ui/components/ProfileCard.js.map +1 -1
- package/lib/commonjs/ui/components/QuickActions.js +7 -4
- package/lib/commonjs/ui/components/QuickActions.js.map +1 -1
- package/lib/commonjs/ui/components/Section.js +4 -1
- package/lib/commonjs/ui/components/Section.js.map +1 -1
- package/lib/commonjs/ui/components/SectionTitle.js +6 -3
- package/lib/commonjs/ui/components/SectionTitle.js.map +1 -1
- package/lib/commonjs/ui/components/SettingRow.js +77 -0
- package/lib/commonjs/ui/components/SettingRow.js.map +1 -0
- package/lib/commonjs/ui/components/StepBasedScreen.js +188 -172
- package/lib/commonjs/ui/components/StepBasedScreen.js.map +1 -1
- package/lib/commonjs/ui/components/Surface.js +258 -0
- package/lib/commonjs/ui/components/Surface.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Addons/Outline.js +46 -0
- package/lib/commonjs/ui/components/TextField/Addons/Outline.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Addons/Underline.js +53 -0
- package/lib/commonjs/ui/components/TextField/Addons/Underline.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Adornment/TextFieldAdornment.js +155 -0
- package/lib/commonjs/ui/components/TextField/Adornment/TextFieldAdornment.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Adornment/TextFieldAffix.js +144 -0
- package/lib/commonjs/ui/components/TextField/Adornment/TextFieldAffix.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Adornment/TextFieldIcon.js +137 -0
- package/lib/commonjs/ui/components/TextField/Adornment/TextFieldIcon.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Adornment/enums.js +22 -0
- package/lib/commonjs/ui/components/TextField/Adornment/enums.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Adornment/types.js +6 -0
- package/lib/commonjs/ui/components/TextField/Adornment/types.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Adornment/utils.js +62 -0
- package/lib/commonjs/ui/components/TextField/Adornment/utils.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Label/InputLabel.js +176 -0
- package/lib/commonjs/ui/components/TextField/Label/InputLabel.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/Label/LabelBackground.js +84 -0
- package/lib/commonjs/ui/components/TextField/Label/LabelBackground.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/TextFieldFlat.js +377 -0
- package/lib/commonjs/ui/components/TextField/TextFieldFlat.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/TextFieldOutlined.js +361 -0
- package/lib/commonjs/ui/components/TextField/TextFieldOutlined.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/constants.js +50 -0
- package/lib/commonjs/ui/components/TextField/constants.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/helpers.js +490 -0
- package/lib/commonjs/ui/components/TextField/helpers.js.map +1 -0
- package/lib/commonjs/ui/components/TextField/types.js +6 -0
- package/lib/commonjs/ui/components/TextField/types.js.map +1 -0
- package/lib/commonjs/ui/components/TextField.js +339 -0
- package/lib/commonjs/ui/components/TextField.js.map +1 -0
- package/lib/commonjs/ui/components/TouchableRipple/Pressable.js +12 -0
- package/lib/commonjs/ui/components/TouchableRipple/Pressable.js.map +1 -0
- package/lib/commonjs/ui/components/TouchableRipple/TouchableRipple.js +258 -0
- package/lib/commonjs/ui/components/TouchableRipple/TouchableRipple.js.map +1 -0
- package/lib/commonjs/ui/components/TouchableRipple/TouchableRipple.native.js +107 -0
- package/lib/commonjs/ui/components/TouchableRipple/TouchableRipple.native.js.map +1 -0
- package/lib/commonjs/ui/components/TouchableRipple/utils.js +56 -0
- package/lib/commonjs/ui/components/TouchableRipple/utils.js.map +1 -0
- package/lib/commonjs/ui/components/Typography/AnimatedText.js +62 -0
- package/lib/commonjs/ui/components/Typography/AnimatedText.js.map +1 -0
- package/lib/commonjs/ui/components/Typography/types.js +26 -0
- package/lib/commonjs/ui/components/Typography/types.js.map +1 -0
- package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js +171 -0
- package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js.map +1 -0
- package/lib/commonjs/ui/components/fileManagement/FileViewer.js +409 -0
- package/lib/commonjs/ui/components/fileManagement/FileViewer.js.map +1 -0
- package/lib/commonjs/ui/components/fileManagement/UploadPreview.js +181 -0
- package/lib/commonjs/ui/components/fileManagement/UploadPreview.js.map +1 -0
- package/lib/commonjs/ui/components/fileManagement/styles.js +868 -0
- package/lib/commonjs/ui/components/fileManagement/styles.js.map +1 -0
- package/lib/commonjs/ui/components/index.js +29 -1
- package/lib/commonjs/ui/components/index.js.map +1 -1
- package/lib/commonjs/ui/components/profile/EditBioModal.js +181 -0
- package/lib/commonjs/ui/components/profile/EditBioModal.js.map +1 -0
- package/lib/commonjs/ui/components/profile/EditDisplayNameModal.js +207 -0
- package/lib/commonjs/ui/components/profile/EditDisplayNameModal.js.map +1 -0
- package/lib/commonjs/ui/components/profile/EditEmailModal.js +184 -0
- package/lib/commonjs/ui/components/profile/EditEmailModal.js.map +1 -0
- package/lib/commonjs/ui/components/profile/EditLinksModal.js +315 -0
- package/lib/commonjs/ui/components/profile/EditLinksModal.js.map +1 -0
- package/lib/commonjs/ui/components/profile/EditLocationModal.js +273 -0
- package/lib/commonjs/ui/components/profile/EditLocationModal.js.map +1 -0
- package/lib/commonjs/ui/components/profile/EditUsernameModal.js +180 -0
- package/lib/commonjs/ui/components/profile/EditUsernameModal.js.map +1 -0
- package/lib/commonjs/ui/components/profile/TwoFactorSetupModal.js +467 -0
- package/lib/commonjs/ui/components/profile/TwoFactorSetupModal.js.map +1 -0
- package/lib/commonjs/ui/components/styles/overlay.js +85 -0
- package/lib/commonjs/ui/components/styles/overlay.js.map +1 -0
- package/lib/commonjs/ui/components/styles/shadow.js +132 -0
- package/lib/commonjs/ui/components/styles/shadow.js.map +1 -0
- package/lib/commonjs/ui/components/theming.js +116 -0
- package/lib/commonjs/ui/components/theming.js.map +1 -0
- package/lib/commonjs/ui/components/types.js +2 -0
- package/lib/commonjs/ui/components/types.js.map +1 -0
- package/lib/commonjs/ui/components/utils/forwardRef.js +18 -0
- package/lib/commonjs/ui/components/utils/forwardRef.js.map +1 -0
- package/lib/commonjs/ui/components/utils/hasTouchHandler.js +13 -0
- package/lib/commonjs/ui/components/utils/hasTouchHandler.js.map +1 -0
- package/lib/commonjs/ui/components/utils/roundLayoutSize.js +9 -0
- package/lib/commonjs/ui/components/utils/roundLayoutSize.js.map +1 -0
- package/lib/commonjs/ui/components/utils/splitStyles.js +50 -0
- package/lib/commonjs/ui/components/utils/splitStyles.js.map +1 -0
- package/lib/commonjs/ui/constants/iconColors.js +84 -0
- package/lib/commonjs/ui/constants/iconColors.js.map +1 -0
- package/lib/commonjs/ui/constants/spacing.js +50 -0
- package/lib/commonjs/ui/constants/spacing.js.map +1 -0
- package/lib/commonjs/ui/constants/theme.js +123 -0
- package/lib/commonjs/ui/constants/theme.js.map +1 -0
- package/lib/commonjs/ui/context/OxyContext.js +198 -853
- package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
- package/lib/commonjs/ui/context/ThemeContext.js +36 -0
- package/lib/commonjs/ui/context/ThemeContext.js.map +1 -0
- package/lib/commonjs/ui/context/hooks/useAuthOperations.js +349 -0
- package/lib/commonjs/ui/context/hooks/useAuthOperations.js.map +1 -0
- package/lib/commonjs/ui/context/hooks/useDeviceManagement.js +73 -0
- package/lib/commonjs/ui/context/hooks/useDeviceManagement.js.map +1 -0
- package/lib/commonjs/ui/context/hooks/useLanguageManagement.js +112 -0
- package/lib/commonjs/ui/context/hooks/useLanguageManagement.js.map +1 -0
- package/lib/commonjs/ui/context/hooks/useSessionManagement.js +261 -0
- package/lib/commonjs/ui/context/hooks/useSessionManagement.js.map +1 -0
- package/lib/commonjs/ui/context/hooks/useStorage.js +79 -0
- package/lib/commonjs/ui/context/hooks/useStorage.js.map +1 -0
- package/lib/commonjs/ui/context/utils/errorHandlers.js +90 -0
- package/lib/commonjs/ui/context/utils/errorHandlers.js.map +1 -0
- package/lib/commonjs/ui/context/utils/sessionHelpers.js +103 -0
- package/lib/commonjs/ui/context/utils/sessionHelpers.js.map +1 -0
- package/lib/commonjs/ui/context/utils/storageHelpers.js +119 -0
- package/lib/commonjs/ui/context/utils/storageHelpers.js.map +1 -0
- package/lib/commonjs/ui/hooks/index.js +14 -0
- package/lib/commonjs/ui/hooks/index.js.map +1 -1
- package/lib/commonjs/ui/hooks/use-color-scheme.js +29 -0
- package/lib/commonjs/ui/hooks/use-color-scheme.js.map +1 -0
- package/lib/commonjs/ui/hooks/use-haptic-press.js +21 -0
- package/lib/commonjs/ui/hooks/use-haptic-press.js.map +1 -0
- package/lib/commonjs/ui/hooks/useAssets.js.map +1 -1
- package/lib/commonjs/ui/hooks/useDeviceManagement.js +73 -0
- package/lib/commonjs/ui/hooks/useDeviceManagement.js.map +1 -0
- package/lib/commonjs/ui/hooks/useLanguageManagement.js +112 -0
- package/lib/commonjs/ui/hooks/useLanguageManagement.js.map +1 -0
- package/lib/commonjs/ui/hooks/useProfileEditing.js +123 -0
- package/lib/commonjs/ui/hooks/useProfileEditing.js.map +1 -0
- package/lib/commonjs/ui/hooks/useSessionManagement.js +261 -0
- package/lib/commonjs/ui/hooks/useSessionManagement.js.map +1 -0
- package/lib/commonjs/ui/hooks/useStorage.js +79 -0
- package/lib/commonjs/ui/hooks/useStorage.js.map +1 -0
- package/lib/commonjs/ui/hooks/useThemeColors.js +31 -0
- package/lib/commonjs/ui/hooks/useThemeColors.js.map +1 -0
- package/lib/commonjs/ui/hooks/useThemeStyles.js +69 -0
- package/lib/commonjs/ui/hooks/useThemeStyles.js.map +1 -0
- package/lib/commonjs/ui/index.js +1 -4
- package/lib/commonjs/ui/index.js.map +1 -1
- package/lib/commonjs/ui/navigation/bottomSheetManager.js +180 -0
- package/lib/commonjs/ui/navigation/bottomSheetManager.js.map +1 -0
- package/lib/commonjs/ui/navigation/routes.js +80 -154
- package/lib/commonjs/ui/navigation/routes.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountCenterScreen.js +67 -67
- package/lib/commonjs/ui/screens/AccountCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountOverviewScreen.js +217 -98
- package/lib/commonjs/ui/screens/AccountOverviewScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js +514 -429
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSwitcherScreen.js +44 -59
- package/lib/commonjs/ui/screens/AccountSwitcherScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountVerificationScreen.js +12 -19
- package/lib/commonjs/ui/screens/AccountVerificationScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AppInfoScreen.js +36 -43
- package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FeedbackScreen.js +14 -14
- package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FileManagementScreen.js +674 -1968
- package/lib/commonjs/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HelpSupportScreen.js +26 -23
- package/lib/commonjs/ui/screens/HelpSupportScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HistoryViewScreen.js +19 -59
- package/lib/commonjs/ui/screens/HistoryViewScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/LanguageSelectorScreen.js +79 -170
- package/lib/commonjs/ui/screens/LanguageSelectorScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/LegalDocumentsScreen.js +13 -40
- package/lib/commonjs/ui/screens/LegalDocumentsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/OxyAuthScreen.js +436 -0
- package/lib/commonjs/ui/screens/OxyAuthScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +18 -24
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js +21 -9
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PrivacySettingsScreen.js +180 -252
- package/lib/commonjs/ui/screens/PrivacySettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ProfileScreen.js +7 -5
- package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SavesCollectionsScreen.js +32 -70
- package/lib/commonjs/ui/screens/SavesCollectionsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SearchSettingsScreen.js +26 -99
- package/lib/commonjs/ui/screens/SearchSettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SessionManagementScreen.js +24 -16
- package/lib/commonjs/ui/screens/SessionManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/UserLinksScreen.js +8 -10
- package/lib/commonjs/ui/screens/UserLinksScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js +64 -67
- package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaAboutScreen.js +11 -8
- package/lib/commonjs/ui/screens/karma/KarmaAboutScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaCenterScreen.js +124 -122
- package/lib/commonjs/ui/screens/karma/KarmaCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaFAQScreen.js +99 -112
- package/lib/commonjs/ui/screens/karma/KarmaFAQScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaLeaderboardScreen.js +12 -9
- package/lib/commonjs/ui/screens/karma/KarmaLeaderboardScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js +552 -79
- package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaRulesScreen.js +12 -8
- package/lib/commonjs/ui/screens/karma/KarmaRulesScreen.js.map +1 -1
- package/lib/commonjs/ui/styles/authStyles.js +5 -11
- package/lib/commonjs/ui/styles/authStyles.js.map +1 -1
- package/lib/commonjs/ui/styles/spacing.js +60 -2
- package/lib/commonjs/ui/styles/spacing.js.map +1 -1
- package/lib/commonjs/ui/styles/theme.js +1 -1
- package/lib/commonjs/ui/types/fileManagement.js +6 -0
- package/lib/commonjs/ui/types/fileManagement.js.map +1 -0
- package/lib/commonjs/ui/types/navigation.js +6 -0
- package/lib/commonjs/ui/types/navigation.js.map +1 -0
- package/lib/commonjs/ui/utils/colorUtils.js +52 -0
- package/lib/commonjs/ui/utils/colorUtils.js.map +1 -0
- package/lib/commonjs/ui/utils/errorHandlers.js +90 -0
- package/lib/commonjs/ui/utils/errorHandlers.js.map +1 -0
- package/lib/commonjs/ui/utils/fileManagement.js +181 -0
- package/lib/commonjs/ui/utils/fileManagement.js.map +1 -0
- package/lib/commonjs/ui/utils/sessionHelpers.js +103 -0
- package/lib/commonjs/ui/utils/sessionHelpers.js.map +1 -0
- package/lib/commonjs/ui/utils/storageHelpers.js +119 -0
- package/lib/commonjs/ui/utils/storageHelpers.js.map +1 -0
- package/lib/commonjs/ui/utils/themeUtils.js +47 -0
- package/lib/commonjs/ui/utils/themeUtils.js.map +1 -0
- package/lib/commonjs/ui/utils/user-utils.js +53 -0
- package/lib/commonjs/ui/utils/user-utils.js.map +1 -0
- package/lib/commonjs/utils/errorUtils.js +14 -4
- package/lib/commonjs/utils/errorUtils.js.map +1 -1
- package/lib/module/assets/assets/lottie/welcomeheader_background_op1.json +1 -0
- package/lib/module/assets/lottie/welcomeheader_background_op1.json +1 -0
- package/lib/module/core/HttpService.js +94 -4
- package/lib/module/core/HttpService.js.map +1 -1
- package/lib/module/core/OxyServices.base.js +3 -1
- package/lib/module/core/OxyServices.base.js.map +1 -1
- package/lib/module/core/mixins/OxyServices.assets.js +212 -20
- package/lib/module/core/mixins/OxyServices.assets.js.map +1 -1
- package/lib/module/core/mixins/OxyServices.auth.js +70 -99
- package/lib/module/core/mixins/OxyServices.auth.js.map +1 -1
- package/lib/module/crypto/index.js +16 -0
- package/lib/module/crypto/index.js.map +1 -0
- package/lib/module/crypto/keyManager.js +204 -0
- package/lib/module/crypto/keyManager.js.map +1 -0
- package/lib/module/crypto/recoveryPhrase.js +131 -0
- package/lib/module/crypto/recoveryPhrase.js.map +1 -0
- package/lib/module/crypto/signatureService.js +227 -0
- package/lib/module/crypto/signatureService.js.map +1 -0
- package/lib/module/i18n/locales/en-US.json +4 -0
- package/lib/module/index.js +2 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/ui/components/ActivityIndicator.js +198 -0
- package/lib/module/ui/components/ActivityIndicator.js.map +1 -0
- package/lib/module/ui/components/AutoHeightScrollView.js +41 -0
- package/lib/module/ui/components/AutoHeightScrollView.js.map +1 -0
- package/lib/module/ui/components/BottomSheet.js +402 -0
- package/lib/module/ui/components/BottomSheet.js.map +1 -0
- package/lib/module/ui/components/BottomSheetRouter.js +356 -0
- package/lib/module/ui/components/BottomSheetRouter.js.map +1 -0
- package/lib/module/ui/components/CrossFadeIcon.js +101 -0
- package/lib/module/ui/components/CrossFadeIcon.js.map +1 -0
- package/lib/module/ui/components/EmptyState.js +36 -0
- package/lib/module/ui/components/EmptyState.js.map +1 -0
- package/lib/module/ui/components/GroupedItem.js +88 -82
- package/lib/module/ui/components/GroupedItem.js.map +1 -1
- package/lib/module/ui/components/GroupedSection.js +23 -23
- package/lib/module/ui/components/GroupedSection.js.map +1 -1
- package/lib/module/ui/components/Header.js +109 -46
- package/lib/module/ui/components/Header.js.map +1 -1
- package/lib/module/ui/components/HelperText.js +99 -0
- package/lib/module/ui/components/HelperText.js.map +1 -0
- package/lib/module/ui/components/Icon.js +102 -0
- package/lib/module/ui/components/Icon.js.map +1 -0
- package/lib/module/ui/components/IconButton/IconButton.js +153 -0
- package/lib/module/ui/components/IconButton/IconButton.js.map +1 -0
- package/lib/module/ui/components/IconButton/utils.js +149 -0
- package/lib/module/ui/components/IconButton/utils.js.map +1 -0
- package/lib/module/ui/components/LoadingState.js +42 -0
- package/lib/module/ui/components/LoadingState.js.map +1 -0
- package/lib/module/ui/components/OxyPayButton.js +1 -14
- package/lib/module/ui/components/OxyPayButton.js.map +1 -1
- package/lib/module/ui/components/OxyProvider.js +45 -377
- package/lib/module/ui/components/OxyProvider.js.map +1 -1
- package/lib/module/ui/components/OxySignInButton.js +9 -13
- package/lib/module/ui/components/OxySignInButton.js.map +1 -1
- package/lib/module/ui/components/ProfileCard.js +7 -4
- package/lib/module/ui/components/ProfileCard.js.map +1 -1
- package/lib/module/ui/components/QuickActions.js +7 -4
- package/lib/module/ui/components/QuickActions.js.map +1 -1
- package/lib/module/ui/components/Section.js +4 -1
- package/lib/module/ui/components/Section.js.map +1 -1
- package/lib/module/ui/components/SectionTitle.js +6 -3
- package/lib/module/ui/components/SectionTitle.js.map +1 -1
- package/lib/module/ui/components/SettingRow.js +72 -0
- package/lib/module/ui/components/SettingRow.js.map +1 -0
- package/lib/module/ui/components/StepBasedScreen.js +190 -174
- package/lib/module/ui/components/StepBasedScreen.js.map +1 -1
- package/lib/module/ui/components/Surface.js +252 -0
- package/lib/module/ui/components/Surface.js.map +1 -0
- package/lib/module/ui/components/TextField/Addons/Outline.js +40 -0
- package/lib/module/ui/components/TextField/Addons/Outline.js.map +1 -0
- package/lib/module/ui/components/TextField/Addons/Underline.js +47 -0
- package/lib/module/ui/components/TextField/Addons/Underline.js.map +1 -0
- package/lib/module/ui/components/TextField/Adornment/TextFieldAdornment.js +148 -0
- package/lib/module/ui/components/TextField/Adornment/TextFieldAdornment.js.map +1 -0
- package/lib/module/ui/components/TextField/Adornment/TextFieldAffix.js +141 -0
- package/lib/module/ui/components/TextField/Adornment/TextFieldAffix.js.map +1 -0
- package/lib/module/ui/components/TextField/Adornment/TextFieldIcon.js +135 -0
- package/lib/module/ui/components/TextField/Adornment/TextFieldIcon.js.map +1 -0
- package/lib/module/ui/components/TextField/Adornment/enums.js +18 -0
- package/lib/module/ui/components/TextField/Adornment/enums.js.map +1 -0
- package/lib/module/ui/components/TextField/Adornment/types.js +4 -0
- package/lib/module/ui/components/TextField/Adornment/types.js.map +1 -0
- package/lib/module/ui/components/TextField/Adornment/utils.js +57 -0
- package/lib/module/ui/components/TextField/Adornment/utils.js.map +1 -0
- package/lib/module/ui/components/TextField/Label/InputLabel.js +171 -0
- package/lib/module/ui/components/TextField/Label/InputLabel.js.map +1 -0
- package/lib/module/ui/components/TextField/Label/LabelBackground.js +78 -0
- package/lib/module/ui/components/TextField/Label/LabelBackground.js.map +1 -0
- package/lib/module/ui/components/TextField/TextFieldFlat.js +372 -0
- package/lib/module/ui/components/TextField/TextFieldFlat.js.map +1 -0
- package/lib/module/ui/components/TextField/TextFieldOutlined.js +355 -0
- package/lib/module/ui/components/TextField/TextFieldOutlined.js.map +1 -0
- package/lib/module/ui/components/TextField/constants.js +46 -0
- package/lib/module/ui/components/TextField/constants.js.map +1 -0
- package/lib/module/ui/components/TextField/helpers.js +472 -0
- package/lib/module/ui/components/TextField/helpers.js.map +1 -0
- package/lib/module/ui/components/TextField/types.js +4 -0
- package/lib/module/ui/components/TextField/types.js.map +1 -0
- package/lib/module/ui/components/TextField.js +333 -0
- package/lib/module/ui/components/TextField.js.map +1 -0
- package/lib/module/ui/components/TouchableRipple/Pressable.js +9 -0
- package/lib/module/ui/components/TouchableRipple/Pressable.js.map +1 -0
- package/lib/module/ui/components/TouchableRipple/TouchableRipple.js +253 -0
- package/lib/module/ui/components/TouchableRipple/TouchableRipple.js.map +1 -0
- package/lib/module/ui/components/TouchableRipple/TouchableRipple.native.js +101 -0
- package/lib/module/ui/components/TouchableRipple/TouchableRipple.native.js.map +1 -0
- package/lib/module/ui/components/TouchableRipple/utils.js +50 -0
- package/lib/module/ui/components/TouchableRipple/utils.js.map +1 -0
- package/lib/module/ui/components/Typography/AnimatedText.js +56 -0
- package/lib/module/ui/components/Typography/AnimatedText.js.map +1 -0
- package/lib/module/ui/components/Typography/types.js +22 -0
- package/lib/module/ui/components/Typography/types.js.map +1 -0
- package/lib/module/ui/components/fileManagement/FileDetailsModal.js +165 -0
- package/lib/module/ui/components/fileManagement/FileDetailsModal.js.map +1 -0
- package/lib/module/ui/components/fileManagement/FileViewer.js +402 -0
- package/lib/module/ui/components/fileManagement/FileViewer.js.map +1 -0
- package/lib/module/ui/components/fileManagement/UploadPreview.js +175 -0
- package/lib/module/ui/components/fileManagement/UploadPreview.js.map +1 -0
- package/lib/module/ui/components/fileManagement/styles.js +864 -0
- package/lib/module/ui/components/fileManagement/styles.js.map +1 -0
- package/lib/module/ui/components/index.js +4 -1
- package/lib/module/ui/components/index.js.map +1 -1
- package/lib/module/ui/components/profile/EditBioModal.js +175 -0
- package/lib/module/ui/components/profile/EditBioModal.js.map +1 -0
- package/lib/module/ui/components/profile/EditDisplayNameModal.js +201 -0
- package/lib/module/ui/components/profile/EditDisplayNameModal.js.map +1 -0
- package/lib/module/ui/components/profile/EditEmailModal.js +178 -0
- package/lib/module/ui/components/profile/EditEmailModal.js.map +1 -0
- package/lib/module/ui/components/profile/EditLinksModal.js +309 -0
- package/lib/module/ui/components/profile/EditLinksModal.js.map +1 -0
- package/lib/module/ui/components/profile/EditLocationModal.js +267 -0
- package/lib/module/ui/components/profile/EditLocationModal.js.map +1 -0
- package/lib/module/ui/components/profile/EditUsernameModal.js +174 -0
- package/lib/module/ui/components/profile/EditUsernameModal.js.map +1 -0
- package/lib/module/ui/components/profile/TwoFactorSetupModal.js +460 -0
- package/lib/module/ui/components/profile/TwoFactorSetupModal.js.map +1 -0
- package/lib/module/ui/components/styles/overlay.js +80 -0
- package/lib/module/ui/components/styles/overlay.js.map +1 -0
- package/lib/module/ui/components/styles/shadow.js +128 -0
- package/lib/module/ui/components/styles/shadow.js.map +1 -0
- package/lib/module/ui/components/theming.js +111 -0
- package/lib/module/ui/components/theming.js.map +1 -0
- package/lib/module/ui/components/types.js +2 -0
- package/lib/module/ui/components/types.js.map +1 -0
- package/lib/module/ui/components/utils/forwardRef.js +13 -0
- package/lib/module/ui/components/utils/forwardRef.js.map +1 -0
- package/lib/module/ui/components/utils/hasTouchHandler.js +9 -0
- package/lib/module/ui/components/utils/hasTouchHandler.js.map +1 -0
- package/lib/module/ui/components/utils/roundLayoutSize.js +4 -0
- package/lib/module/ui/components/utils/roundLayoutSize.js.map +1 -0
- package/lib/module/ui/components/utils/splitStyles.js +46 -0
- package/lib/module/ui/components/utils/splitStyles.js.map +1 -0
- package/lib/module/ui/constants/iconColors.js +78 -0
- package/lib/module/ui/constants/iconColors.js.map +1 -0
- package/lib/module/ui/constants/spacing.js +45 -0
- package/lib/module/ui/constants/spacing.js.map +1 -0
- package/lib/module/ui/constants/theme.js +119 -0
- package/lib/module/ui/constants/theme.js.map +1 -0
- package/lib/module/ui/context/OxyContext.js +199 -855
- package/lib/module/ui/context/OxyContext.js.map +1 -1
- package/lib/module/ui/context/ThemeContext.js +29 -0
- package/lib/module/ui/context/ThemeContext.js.map +1 -0
- package/lib/module/ui/context/hooks/useAuthOperations.js +344 -0
- package/lib/module/ui/context/hooks/useAuthOperations.js.map +1 -0
- package/lib/module/ui/context/hooks/useDeviceManagement.js +68 -0
- package/lib/module/ui/context/hooks/useDeviceManagement.js.map +1 -0
- package/lib/module/ui/context/hooks/useLanguageManagement.js +107 -0
- package/lib/module/ui/context/hooks/useLanguageManagement.js.map +1 -0
- package/lib/module/ui/context/hooks/useSessionManagement.js +256 -0
- package/lib/module/ui/context/hooks/useSessionManagement.js.map +1 -0
- package/lib/module/ui/context/hooks/useStorage.js +74 -0
- package/lib/module/ui/context/hooks/useStorage.js.map +1 -0
- package/lib/module/ui/context/utils/errorHandlers.js +83 -0
- package/lib/module/ui/context/utils/errorHandlers.js.map +1 -0
- package/lib/module/ui/context/utils/sessionHelpers.js +96 -0
- package/lib/module/ui/context/utils/sessionHelpers.js.map +1 -0
- package/lib/module/ui/context/utils/storageHelpers.js +111 -0
- package/lib/module/ui/context/utils/storageHelpers.js.map +1 -0
- package/lib/module/ui/hooks/index.js +2 -0
- package/lib/module/ui/hooks/index.js.map +1 -1
- package/lib/module/ui/hooks/use-color-scheme.js +26 -0
- package/lib/module/ui/hooks/use-color-scheme.js.map +1 -0
- package/lib/module/ui/hooks/use-haptic-press.js +17 -0
- package/lib/module/ui/hooks/use-haptic-press.js.map +1 -0
- package/lib/module/ui/hooks/useAssets.js.map +1 -1
- package/lib/module/ui/hooks/useDeviceManagement.js +68 -0
- package/lib/module/ui/hooks/useDeviceManagement.js.map +1 -0
- package/lib/module/ui/hooks/useLanguageManagement.js +107 -0
- package/lib/module/ui/hooks/useLanguageManagement.js.map +1 -0
- package/lib/module/ui/hooks/useProfileEditing.js +118 -0
- package/lib/module/ui/hooks/useProfileEditing.js.map +1 -0
- package/lib/module/ui/hooks/useSessionManagement.js +256 -0
- package/lib/module/ui/hooks/useSessionManagement.js.map +1 -0
- package/lib/module/ui/hooks/useStorage.js +74 -0
- package/lib/module/ui/hooks/useStorage.js.map +1 -0
- package/lib/module/ui/hooks/useThemeColors.js +27 -0
- package/lib/module/ui/hooks/useThemeColors.js.map +1 -0
- package/lib/module/ui/hooks/useThemeStyles.js +64 -0
- package/lib/module/ui/hooks/useThemeStyles.js.map +1 -0
- package/lib/module/ui/index.js +2 -4
- package/lib/module/ui/index.js.map +1 -1
- package/lib/module/ui/navigation/bottomSheetManager.js +168 -0
- package/lib/module/ui/navigation/bottomSheetManager.js.map +1 -0
- package/lib/module/ui/navigation/routes.js +77 -152
- package/lib/module/ui/navigation/routes.js.map +1 -1
- package/lib/module/ui/screens/AccountCenterScreen.js +67 -67
- package/lib/module/ui/screens/AccountCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountOverviewScreen.js +218 -100
- package/lib/module/ui/screens/AccountOverviewScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSettingsScreen.js +515 -430
- package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSwitcherScreen.js +45 -60
- package/lib/module/ui/screens/AccountSwitcherScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountVerificationScreen.js +12 -19
- package/lib/module/ui/screens/AccountVerificationScreen.js.map +1 -1
- package/lib/module/ui/screens/AppInfoScreen.js +36 -43
- package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/module/ui/screens/FeedbackScreen.js +14 -14
- package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/module/ui/screens/FileManagementScreen.js +670 -1965
- package/lib/module/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/HelpSupportScreen.js +26 -23
- package/lib/module/ui/screens/HelpSupportScreen.js.map +1 -1
- package/lib/module/ui/screens/HistoryViewScreen.js +22 -62
- package/lib/module/ui/screens/HistoryViewScreen.js.map +1 -1
- package/lib/module/ui/screens/LanguageSelectorScreen.js +80 -171
- package/lib/module/ui/screens/LanguageSelectorScreen.js.map +1 -1
- package/lib/module/ui/screens/LegalDocumentsScreen.js +16 -43
- package/lib/module/ui/screens/LegalDocumentsScreen.js.map +1 -1
- package/lib/module/ui/screens/OxyAuthScreen.js +432 -0
- package/lib/module/ui/screens/OxyAuthScreen.js.map +1 -0
- package/lib/module/ui/screens/PaymentGatewayScreen.js +18 -24
- package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js +21 -9
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/module/ui/screens/PrivacySettingsScreen.js +167 -239
- package/lib/module/ui/screens/PrivacySettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/ProfileScreen.js +7 -5
- package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/module/ui/screens/SavesCollectionsScreen.js +35 -73
- package/lib/module/ui/screens/SavesCollectionsScreen.js.map +1 -1
- package/lib/module/ui/screens/SearchSettingsScreen.js +29 -102
- package/lib/module/ui/screens/SearchSettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/SessionManagementScreen.js +24 -16
- package/lib/module/ui/screens/SessionManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/UserLinksScreen.js +8 -10
- package/lib/module/ui/screens/UserLinksScreen.js.map +1 -1
- package/lib/module/ui/screens/WelcomeNewUserScreen.js +65 -68
- package/lib/module/ui/screens/WelcomeNewUserScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaAboutScreen.js +11 -8
- package/lib/module/ui/screens/karma/KarmaAboutScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaCenterScreen.js +124 -121
- package/lib/module/ui/screens/karma/KarmaCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaFAQScreen.js +101 -114
- package/lib/module/ui/screens/karma/KarmaFAQScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaLeaderboardScreen.js +12 -9
- package/lib/module/ui/screens/karma/KarmaLeaderboardScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaRewardsScreen.js +554 -81
- package/lib/module/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaRulesScreen.js +12 -8
- package/lib/module/ui/screens/karma/KarmaRulesScreen.js.map +1 -1
- package/lib/module/ui/styles/authStyles.js +5 -11
- package/lib/module/ui/styles/authStyles.js.map +1 -1
- package/lib/module/ui/styles/spacing.js +12 -2
- package/lib/module/ui/styles/spacing.js.map +1 -1
- package/lib/module/ui/styles/theme.js +1 -1
- package/lib/module/ui/types/fileManagement.js +4 -0
- package/lib/module/ui/types/fileManagement.js.map +1 -0
- package/lib/module/ui/types/navigation.js +4 -0
- package/lib/module/ui/types/navigation.js.map +1 -0
- package/lib/module/ui/utils/colorUtils.js +46 -0
- package/lib/module/ui/utils/colorUtils.js.map +1 -0
- package/lib/module/ui/utils/errorHandlers.js +83 -0
- package/lib/module/ui/utils/errorHandlers.js.map +1 -0
- package/lib/module/ui/utils/fileManagement.js +172 -0
- package/lib/module/ui/utils/fileManagement.js.map +1 -0
- package/lib/module/ui/utils/sessionHelpers.js +96 -0
- package/lib/module/ui/utils/sessionHelpers.js.map +1 -0
- package/lib/module/ui/utils/storageHelpers.js +111 -0
- package/lib/module/ui/utils/storageHelpers.js.map +1 -0
- package/lib/module/ui/utils/themeUtils.js +41 -0
- package/lib/module/ui/utils/themeUtils.js.map +1 -0
- package/lib/module/ui/utils/user-utils.js +46 -0
- package/lib/module/ui/utils/user-utils.js.map +1 -0
- package/lib/module/utils/errorUtils.js +14 -4
- package/lib/module/utils/errorUtils.js.map +1 -1
- package/lib/typescript/core/HttpService.d.ts +48 -0
- package/lib/typescript/core/HttpService.d.ts.map +1 -1
- package/lib/typescript/core/OxyServices.base.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.analytics.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.assets.d.ts +23 -1
- package/lib/typescript/core/mixins/OxyServices.assets.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.auth.d.ts +70 -42
- package/lib/typescript/core/mixins/OxyServices.auth.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.developer.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.devices.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.karma.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.language.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.location.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.payment.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.privacy.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.totp.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.user.d.ts.map +1 -1
- package/lib/typescript/core/mixins/OxyServices.utility.d.ts.map +1 -1
- package/lib/typescript/core/mixins/index.d.ts +26 -34
- package/lib/typescript/core/mixins/index.d.ts.map +1 -1
- package/lib/typescript/crypto/index.d.ts +11 -0
- package/lib/typescript/crypto/index.d.ts.map +1 -0
- package/lib/typescript/crypto/keyManager.d.ts +73 -0
- package/lib/typescript/crypto/keyManager.d.ts.map +1 -0
- package/lib/typescript/crypto/recoveryPhrase.d.ts +57 -0
- package/lib/typescript/crypto/recoveryPhrase.d.ts.map +1 -0
- package/lib/typescript/crypto/signatureService.d.ts +80 -0
- package/lib/typescript/crypto/signatureService.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +2 -0
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/models/interfaces.d.ts +1 -0
- package/lib/typescript/models/interfaces.d.ts.map +1 -1
- package/lib/typescript/types/bip39.d.ts +28 -0
- package/lib/typescript/types/color.d.ts +18 -0
- package/lib/typescript/types/elliptic.d.ts +60 -0
- package/lib/typescript/types/expo-crypto.d.ts +28 -0
- package/lib/typescript/types/expo-random.d.ts +8 -0
- package/lib/typescript/types/expo-secure-store.d.ts +20 -0
- package/lib/typescript/types/expo-vector-icons.d.ts +9 -0
- package/lib/typescript/ui/components/ActivityIndicator.d.ts +45 -0
- package/lib/typescript/ui/components/ActivityIndicator.d.ts.map +1 -0
- package/lib/typescript/ui/components/AutoHeightScrollView.d.ts +23 -0
- package/lib/typescript/ui/components/AutoHeightScrollView.d.ts.map +1 -0
- package/lib/typescript/ui/components/BottomSheet.d.ts +29 -0
- package/lib/typescript/ui/components/BottomSheet.d.ts.map +1 -0
- package/lib/typescript/ui/components/BottomSheetRouter.d.ts +14 -0
- package/lib/typescript/ui/components/BottomSheetRouter.d.ts.map +1 -0
- package/lib/typescript/ui/components/CrossFadeIcon.d.ts +27 -0
- package/lib/typescript/ui/components/CrossFadeIcon.d.ts.map +1 -0
- package/lib/typescript/ui/components/EmptyState.d.ts +8 -0
- package/lib/typescript/ui/components/EmptyState.d.ts.map +1 -0
- package/lib/typescript/ui/components/GroupedItem.d.ts +5 -9
- package/lib/typescript/ui/components/GroupedItem.d.ts.map +1 -1
- package/lib/typescript/ui/components/GroupedSection.d.ts +6 -7
- package/lib/typescript/ui/components/GroupedSection.d.ts.map +1 -1
- package/lib/typescript/ui/components/Header.d.ts +6 -1
- package/lib/typescript/ui/components/Header.d.ts.map +1 -1
- package/lib/typescript/ui/components/HelperText.d.ts +47 -0
- package/lib/typescript/ui/components/HelperText.d.ts.map +1 -0
- package/lib/typescript/ui/components/Icon.d.ts +60 -0
- package/lib/typescript/ui/components/Icon.d.ts.map +1 -0
- package/lib/typescript/ui/components/IconButton/IconButton.d.ts +99 -0
- package/lib/typescript/ui/components/IconButton/IconButton.d.ts.map +1 -0
- package/lib/typescript/ui/components/IconButton/utils.d.ts +19 -0
- package/lib/typescript/ui/components/IconButton/utils.d.ts.map +1 -0
- package/lib/typescript/ui/components/LoadingState.d.ts +9 -0
- package/lib/typescript/ui/components/LoadingState.d.ts.map +1 -0
- package/lib/typescript/ui/components/OxyPayButton.d.ts.map +1 -1
- package/lib/typescript/ui/components/OxyProvider.d.ts +4 -5
- package/lib/typescript/ui/components/OxyProvider.d.ts.map +1 -1
- package/lib/typescript/ui/components/OxySignInButton.d.ts +3 -8
- package/lib/typescript/ui/components/OxySignInButton.d.ts.map +1 -1
- package/lib/typescript/ui/components/ProfileCard.d.ts.map +1 -1
- package/lib/typescript/ui/components/QuickActions.d.ts.map +1 -1
- package/lib/typescript/ui/components/Section.d.ts +1 -1
- package/lib/typescript/ui/components/Section.d.ts.map +1 -1
- package/lib/typescript/ui/components/SectionTitle.d.ts +1 -1
- package/lib/typescript/ui/components/SectionTitle.d.ts.map +1 -1
- package/lib/typescript/ui/components/SettingRow.d.ts +14 -0
- package/lib/typescript/ui/components/SettingRow.d.ts.map +1 -0
- package/lib/typescript/ui/components/StepBasedScreen.d.ts +3 -2
- package/lib/typescript/ui/components/StepBasedScreen.d.ts.map +1 -1
- package/lib/typescript/ui/components/Surface.d.ts +76 -0
- package/lib/typescript/ui/components/Surface.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Addons/Outline.d.ts +16 -0
- package/lib/typescript/ui/components/TextField/Addons/Outline.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Addons/Underline.d.ts +19 -0
- package/lib/typescript/ui/components/TextField/Addons/Underline.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Adornment/TextFieldAdornment.d.ts +45 -0
- package/lib/typescript/ui/components/TextField/Adornment/TextFieldAdornment.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Adornment/TextFieldAffix.d.ts +73 -0
- package/lib/typescript/ui/components/TextField/Adornment/TextFieldAffix.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Adornment/TextFieldIcon.d.ts +78 -0
- package/lib/typescript/ui/components/TextField/Adornment/TextFieldIcon.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Adornment/enums.d.ts +13 -0
- package/lib/typescript/ui/components/TextField/Adornment/enums.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Adornment/types.d.ts +12 -0
- package/lib/typescript/ui/components/TextField/Adornment/types.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Adornment/utils.d.ts +12 -0
- package/lib/typescript/ui/components/TextField/Adornment/utils.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Label/InputLabel.d.ts +5 -0
- package/lib/typescript/ui/components/TextField/Label/InputLabel.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/Label/LabelBackground.d.ts +4 -0
- package/lib/typescript/ui/components/TextField/Label/LabelBackground.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/TextFieldFlat.d.ts +4 -0
- package/lib/typescript/ui/components/TextField/TextFieldFlat.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/TextFieldOutlined.d.ts +4 -0
- package/lib/typescript/ui/components/TextField/TextFieldOutlined.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/constants.d.ts +32 -0
- package/lib/typescript/ui/components/TextField/constants.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/helpers.d.ts +97 -0
- package/lib/typescript/ui/components/TextField/helpers.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField/types.d.ts +156 -0
- package/lib/typescript/ui/components/TextField/types.d.ts.map +1 -0
- package/lib/typescript/ui/components/TextField.d.ts +192 -0
- package/lib/typescript/ui/components/TextField.d.ts.map +1 -0
- package/lib/typescript/ui/components/TouchableRipple/Pressable.d.ts +13 -0
- package/lib/typescript/ui/components/TouchableRipple/Pressable.d.ts.map +1 -0
- package/lib/typescript/ui/components/TouchableRipple/TouchableRipple.d.ts +62 -0
- package/lib/typescript/ui/components/TouchableRipple/TouchableRipple.d.ts.map +1 -0
- package/lib/typescript/ui/components/TouchableRipple/TouchableRipple.native.d.ts +25 -0
- package/lib/typescript/ui/components/TouchableRipple/TouchableRipple.native.d.ts.map +1 -0
- package/lib/typescript/ui/components/TouchableRipple/utils.d.ts +11 -0
- package/lib/typescript/ui/components/TouchableRipple/utils.d.ts.map +1 -0
- package/lib/typescript/ui/components/Typography/AnimatedText.d.ts +35 -0
- package/lib/typescript/ui/components/Typography/AnimatedText.d.ts.map +1 -0
- package/lib/typescript/ui/components/Typography/types.d.ts +19 -0
- package/lib/typescript/ui/components/Typography/types.d.ts.map +1 -0
- package/lib/typescript/ui/components/fileManagement/FileDetailsModal.d.ts +15 -0
- package/lib/typescript/ui/components/fileManagement/FileDetailsModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/fileManagement/FileViewer.d.ts +18 -0
- package/lib/typescript/ui/components/fileManagement/FileViewer.d.ts.map +1 -0
- package/lib/typescript/ui/components/fileManagement/UploadPreview.d.ts +21 -0
- package/lib/typescript/ui/components/fileManagement/UploadPreview.d.ts.map +1 -0
- package/lib/typescript/ui/components/fileManagement/styles.d.ts +860 -0
- package/lib/typescript/ui/components/fileManagement/styles.d.ts.map +1 -0
- package/lib/typescript/ui/components/index.d.ts +4 -1
- package/lib/typescript/ui/components/index.d.ts.map +1 -1
- package/lib/typescript/ui/components/profile/EditBioModal.d.ts +11 -0
- package/lib/typescript/ui/components/profile/EditBioModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/profile/EditDisplayNameModal.d.ts +12 -0
- package/lib/typescript/ui/components/profile/EditDisplayNameModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/profile/EditEmailModal.d.ts +11 -0
- package/lib/typescript/ui/components/profile/EditEmailModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/profile/EditLinksModal.d.ts +18 -0
- package/lib/typescript/ui/components/profile/EditLinksModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/profile/EditLocationModal.d.ts +20 -0
- package/lib/typescript/ui/components/profile/EditLocationModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/profile/EditUsernameModal.d.ts +11 -0
- package/lib/typescript/ui/components/profile/EditUsernameModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/profile/TwoFactorSetupModal.d.ts +11 -0
- package/lib/typescript/ui/components/profile/TwoFactorSetupModal.d.ts.map +1 -0
- package/lib/typescript/ui/components/styles/overlay.d.ts +4 -0
- package/lib/typescript/ui/components/styles/overlay.d.ts.map +1 -0
- package/lib/typescript/ui/components/styles/shadow.d.ts +3 -0
- package/lib/typescript/ui/components/styles/shadow.d.ts.map +1 -0
- package/lib/typescript/ui/components/theming.d.ts +8 -0
- package/lib/typescript/ui/components/theming.d.ts.map +1 -0
- package/lib/typescript/ui/components/types.d.ts +80 -0
- package/lib/typescript/ui/components/types.d.ts.map +1 -0
- package/lib/typescript/ui/components/utils/forwardRef.d.ts +12 -0
- package/lib/typescript/ui/components/utils/forwardRef.d.ts.map +1 -0
- package/lib/typescript/ui/components/utils/hasTouchHandler.d.ts +6 -0
- package/lib/typescript/ui/components/utils/hasTouchHandler.d.ts.map +1 -0
- package/lib/typescript/ui/components/utils/roundLayoutSize.d.ts +2 -0
- package/lib/typescript/ui/components/utils/roundLayoutSize.d.ts.map +1 -0
- package/lib/typescript/ui/components/utils/splitStyles.d.ts +20 -0
- package/lib/typescript/ui/components/utils/splitStyles.d.ts.map +1 -0
- package/lib/typescript/ui/constants/iconColors.d.ts +130 -0
- package/lib/typescript/ui/constants/iconColors.d.ts.map +1 -0
- package/lib/typescript/ui/constants/spacing.d.ts +33 -0
- package/lib/typescript/ui/constants/spacing.d.ts.map +1 -0
- package/lib/typescript/ui/constants/theme.d.ts +97 -0
- package/lib/typescript/ui/constants/theme.d.ts.map +1 -0
- package/lib/typescript/ui/context/OxyContext.d.ts +23 -17
- package/lib/typescript/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/ui/context/ThemeContext.d.ts +19 -0
- package/lib/typescript/ui/context/ThemeContext.d.ts.map +1 -0
- package/lib/typescript/ui/context/hooks/useAuthOperations.d.ts +51 -0
- package/lib/typescript/ui/context/hooks/useAuthOperations.d.ts.map +1 -0
- package/lib/typescript/ui/context/hooks/useDeviceManagement.d.ts +27 -0
- package/lib/typescript/ui/context/hooks/useDeviceManagement.d.ts.map +1 -0
- package/lib/typescript/ui/context/hooks/useLanguageManagement.d.ts +25 -0
- package/lib/typescript/ui/context/hooks/useLanguageManagement.d.ts.map +1 -0
- package/lib/typescript/ui/context/hooks/useSessionManagement.d.ts +39 -0
- package/lib/typescript/ui/context/hooks/useSessionManagement.d.ts.map +1 -0
- package/lib/typescript/ui/context/hooks/useStorage.d.ts +22 -0
- package/lib/typescript/ui/context/hooks/useStorage.d.ts.map +1 -0
- package/lib/typescript/ui/context/utils/errorHandlers.d.ts +30 -0
- package/lib/typescript/ui/context/utils/errorHandlers.d.ts.map +1 -0
- package/lib/typescript/ui/context/utils/sessionHelpers.d.ts +59 -0
- package/lib/typescript/ui/context/utils/sessionHelpers.d.ts.map +1 -0
- package/lib/typescript/ui/context/utils/storageHelpers.d.ts +31 -0
- package/lib/typescript/ui/context/utils/storageHelpers.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/index.d.ts +2 -0
- package/lib/typescript/ui/hooks/index.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/use-color-scheme.d.ts +8 -0
- package/lib/typescript/ui/hooks/use-color-scheme.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/use-haptic-press.d.ts +8 -0
- package/lib/typescript/ui/hooks/use-haptic-press.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useDeviceManagement.d.ts +27 -0
- package/lib/typescript/ui/hooks/useDeviceManagement.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useLanguageManagement.d.ts +25 -0
- package/lib/typescript/ui/hooks/useLanguageManagement.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useProfileEditing.d.ts +36 -0
- package/lib/typescript/ui/hooks/useProfileEditing.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useSessionManagement.d.ts +39 -0
- package/lib/typescript/ui/hooks/useSessionManagement.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useStorage.d.ts +22 -0
- package/lib/typescript/ui/hooks/useStorage.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useThemeColors.d.ts +94 -0
- package/lib/typescript/ui/hooks/useThemeColors.d.ts.map +1 -0
- package/lib/typescript/ui/hooks/useThemeStyles.d.ts +45 -0
- package/lib/typescript/ui/hooks/useThemeStyles.d.ts.map +1 -0
- package/lib/typescript/ui/index.d.ts +2 -2
- package/lib/typescript/ui/index.d.ts.map +1 -1
- package/lib/typescript/ui/navigation/bottomSheetManager.d.ts +74 -0
- package/lib/typescript/ui/navigation/bottomSheetManager.d.ts.map +1 -0
- package/lib/typescript/ui/navigation/routes.d.ts +4 -7
- package/lib/typescript/ui/navigation/routes.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountCenterScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/AccountCenterScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountOverviewScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/AccountOverviewScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountSettingsScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountSwitcherScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/AccountSwitcherScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountVerificationScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/AccountVerificationScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AppInfoScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/AppInfoScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/FeedbackScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/FeedbackScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/FileManagementScreen.d.ts +1 -36
- package/lib/typescript/ui/screens/FileManagementScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/HelpSupportScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/HelpSupportScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/HistoryViewScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/HistoryViewScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/LanguageSelectorScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/LanguageSelectorScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/LegalDocumentsScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/LegalDocumentsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/OxyAuthScreen.d.ts +16 -0
- package/lib/typescript/ui/screens/OxyAuthScreen.d.ts.map +1 -0
- package/lib/typescript/ui/screens/PaymentGatewayScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/PaymentGatewayScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/PremiumSubscriptionScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/PrivacySettingsScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/PrivacySettingsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/ProfileScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/ProfileScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/SavesCollectionsScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/SavesCollectionsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/SearchSettingsScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/SearchSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/SessionManagementScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/SessionManagementScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/UserLinksScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/UserLinksScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/WelcomeNewUserScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/WelcomeNewUserScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaAboutScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/karma/KarmaAboutScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaCenterScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/karma/KarmaCenterScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaFAQScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/karma/KarmaLeaderboardScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/karma/KarmaLeaderboardScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaRewardsScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/karma/KarmaRewardsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaRulesScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/karma/KarmaRulesScreen.d.ts.map +1 -1
- package/lib/typescript/ui/stores/authStore.d.ts +1 -2
- package/lib/typescript/ui/stores/authStore.d.ts.map +1 -1
- package/lib/typescript/ui/styles/authStyles.d.ts +0 -10
- package/lib/typescript/ui/styles/authStyles.d.ts.map +1 -1
- package/lib/typescript/ui/styles/spacing.d.ts +7 -1
- package/lib/typescript/ui/styles/spacing.d.ts.map +1 -1
- package/lib/typescript/ui/types/fileManagement.d.ts +41 -0
- package/lib/typescript/ui/types/fileManagement.d.ts.map +1 -0
- package/lib/typescript/ui/types/navigation.d.ts +36 -0
- package/lib/typescript/ui/types/navigation.d.ts.map +1 -0
- package/lib/typescript/ui/utils/colorUtils.d.ts +14 -0
- package/lib/typescript/ui/utils/colorUtils.d.ts.map +1 -0
- package/lib/typescript/ui/utils/errorHandlers.d.ts +30 -0
- package/lib/typescript/ui/utils/errorHandlers.d.ts.map +1 -0
- package/lib/typescript/ui/utils/fileManagement.d.ts +39 -0
- package/lib/typescript/ui/utils/fileManagement.d.ts.map +1 -0
- package/lib/typescript/ui/utils/sessionHelpers.d.ts +59 -0
- package/lib/typescript/ui/utils/sessionHelpers.d.ts.map +1 -0
- package/lib/typescript/ui/utils/storageHelpers.d.ts +31 -0
- package/lib/typescript/ui/utils/storageHelpers.d.ts.map +1 -0
- package/lib/typescript/ui/utils/themeUtils.d.ts +24 -0
- package/lib/typescript/ui/utils/themeUtils.d.ts.map +1 -0
- package/lib/typescript/ui/utils/user-utils.d.ts +29 -0
- package/lib/typescript/ui/utils/user-utils.d.ts.map +1 -0
- package/lib/typescript/utils/errorUtils.d.ts.map +1 -1
- package/package.json +26 -15
- package/src/assets/lottie/welcomeheader_background_op1.json +1 -0
- package/src/core/HttpService.ts +97 -4
- package/src/core/OxyServices.base.ts +3 -1
- package/src/core/mixins/OxyServices.assets.ts +225 -27
- package/src/core/mixins/OxyServices.auth.ts +144 -80
- package/src/crypto/index.ts +20 -0
- package/src/crypto/keyManager.ts +213 -0
- package/src/crypto/recoveryPhrase.ts +146 -0
- package/src/crypto/signatureService.ts +258 -0
- package/src/i18n/locales/en-US.json +4 -0
- package/src/index.ts +13 -0
- package/src/models/interfaces.ts +1 -0
- package/src/types/bip39.d.ts +28 -0
- package/src/types/color.d.ts +18 -0
- package/src/types/elliptic.d.ts +60 -0
- package/src/types/expo-crypto.d.ts +28 -0
- package/src/types/expo-random.d.ts +8 -0
- package/src/types/expo-secure-store.d.ts +20 -0
- package/src/types/expo-vector-icons.d.ts +9 -0
- package/src/ui/components/ActivityIndicator.tsx +254 -0
- package/src/ui/components/AutoHeightScrollView.tsx +50 -0
- package/src/ui/components/BottomSheet.tsx +443 -0
- package/src/ui/components/BottomSheetRouter.tsx +407 -0
- package/src/ui/components/CrossFadeIcon.tsx +140 -0
- package/src/ui/components/EmptyState.tsx +39 -0
- package/src/ui/components/GroupedItem.tsx +98 -96
- package/src/ui/components/GroupedSection.tsx +24 -29
- package/src/ui/components/Header.tsx +129 -49
- package/src/ui/components/HelperText.tsx +160 -0
- package/src/ui/components/Icon.tsx +181 -0
- package/src/ui/components/IconButton/IconButton.tsx +235 -0
- package/src/ui/components/IconButton/utils.ts +190 -0
- package/src/ui/components/LoadingState.tsx +46 -0
- package/src/ui/components/OxyPayButton.tsx +1 -12
- package/src/ui/components/OxyProvider.tsx +49 -381
- package/src/ui/components/OxySignInButton.tsx +11 -18
- package/src/ui/components/ProfileCard.tsx +7 -4
- package/src/ui/components/QuickActions.tsx +7 -4
- package/src/ui/components/Section.tsx +6 -2
- package/src/ui/components/SectionTitle.tsx +7 -4
- package/src/ui/components/SettingRow.tsx +76 -0
- package/src/ui/components/StepBasedScreen.tsx +205 -187
- package/src/ui/components/Surface.tsx +384 -0
- package/src/ui/components/TextField/Addons/Outline.tsx +64 -0
- package/src/ui/components/TextField/Addons/Underline.tsx +78 -0
- package/src/ui/components/TextField/Adornment/TextFieldAdornment.tsx +208 -0
- package/src/ui/components/TextField/Adornment/TextFieldAffix.tsx +212 -0
- package/src/ui/components/TextField/Adornment/TextFieldIcon.tsx +195 -0
- package/src/ui/components/TextField/Adornment/enums.tsx +12 -0
- package/src/ui/components/TextField/Adornment/types.tsx +11 -0
- package/src/ui/components/TextField/Adornment/utils.ts +66 -0
- package/src/ui/components/TextField/Label/InputLabel.tsx +219 -0
- package/src/ui/components/TextField/Label/LabelBackground.tsx +100 -0
- package/src/ui/components/TextField/TextFieldFlat.tsx +488 -0
- package/src/ui/components/TextField/TextFieldOutlined.tsx +464 -0
- package/src/ui/components/TextField/constants.tsx +48 -0
- package/src/ui/components/TextField/helpers.tsx +612 -0
- package/src/ui/components/TextField/types.tsx +156 -0
- package/src/ui/components/TextField.tsx +578 -0
- package/src/ui/components/TouchableRipple/Pressable.tsx +41 -0
- package/src/ui/components/TouchableRipple/TouchableRipple.native.tsx +146 -0
- package/src/ui/components/TouchableRipple/TouchableRipple.tsx +347 -0
- package/src/ui/components/TouchableRipple/utils.ts +66 -0
- package/src/ui/components/Typography/AnimatedText.tsx +107 -0
- package/src/ui/components/Typography/types.tsx +22 -0
- package/src/ui/components/fileManagement/FileDetailsModal.tsx +137 -0
- package/src/ui/components/fileManagement/FileViewer.tsx +380 -0
- package/src/ui/components/fileManagement/UploadPreview.tsx +175 -0
- package/src/ui/components/fileManagement/styles.ts +860 -0
- package/src/ui/components/index.ts +4 -1
- package/src/ui/components/profile/EditBioModal.tsx +184 -0
- package/src/ui/components/profile/EditDisplayNameModal.tsx +205 -0
- package/src/ui/components/profile/EditEmailModal.tsx +188 -0
- package/src/ui/components/profile/EditLinksModal.tsx +316 -0
- package/src/ui/components/profile/EditLocationModal.tsx +278 -0
- package/src/ui/components/profile/EditUsernameModal.tsx +183 -0
- package/src/ui/components/profile/TwoFactorSetupModal.tsx +442 -0
- package/src/ui/components/styles/overlay.tsx +88 -0
- package/src/ui/components/styles/shadow.tsx +136 -0
- package/src/ui/components/theming.tsx +114 -0
- package/src/ui/components/types.tsx +90 -0
- package/src/ui/components/utils/forwardRef.tsx +23 -0
- package/src/ui/components/utils/hasTouchHandler.tsx +23 -0
- package/src/ui/components/utils/roundLayoutSize.ts +2 -0
- package/src/ui/components/utils/splitStyles.ts +60 -0
- package/src/ui/constants/iconColors.ts +88 -0
- package/src/ui/constants/spacing.ts +45 -0
- package/src/ui/constants/theme.ts +120 -0
- package/src/ui/context/OxyContext.tsx +276 -894
- package/src/ui/context/ThemeContext.tsx +41 -0
- package/src/ui/context/hooks/useAuthOperations.ts +400 -0
- package/src/ui/context/hooks/useDeviceManagement.ts +108 -0
- package/src/ui/context/hooks/useLanguageManagement.ts +152 -0
- package/src/ui/context/hooks/useSessionManagement.ts +378 -0
- package/src/ui/context/hooks/useStorage.ts +104 -0
- package/src/ui/context/utils/errorHandlers.ts +136 -0
- package/src/ui/context/utils/sessionHelpers.ts +146 -0
- package/src/ui/context/utils/storageHelpers.ts +134 -0
- package/src/ui/hooks/index.ts +3 -1
- package/src/ui/hooks/use-color-scheme.ts +24 -0
- package/src/ui/hooks/use-haptic-press.ts +15 -0
- package/src/ui/hooks/useAssets.ts +1 -1
- package/src/ui/hooks/useDeviceManagement.ts +108 -0
- package/src/ui/hooks/useLanguageManagement.ts +152 -0
- package/src/ui/hooks/useProfileEditing.ts +151 -0
- package/src/ui/hooks/useSessionManagement.ts +378 -0
- package/src/ui/hooks/useStorage.ts +104 -0
- package/src/ui/hooks/useThemeColors.ts +26 -0
- package/src/ui/hooks/useThemeStyles.ts +85 -0
- package/src/ui/index.ts +1 -4
- package/src/ui/navigation/bottomSheetManager.ts +191 -0
- package/src/ui/navigation/routes.ts +107 -189
- package/src/ui/screens/AccountCenterScreen.tsx +67 -63
- package/src/ui/screens/AccountOverviewScreen.tsx +237 -95
- package/src/ui/screens/AccountSettingsScreen.tsx +546 -474
- package/src/ui/screens/AccountSwitcherScreen.tsx +113 -116
- package/src/ui/screens/AccountVerificationScreen.tsx +18 -20
- package/src/ui/screens/AppInfoScreen.tsx +37 -38
- package/src/ui/screens/FeedbackScreen.tsx +15 -12
- package/src/ui/screens/FileManagementScreen.tsx +764 -2026
- package/src/ui/screens/HelpSupportScreen.tsx +30 -23
- package/src/ui/screens/HistoryViewScreen.tsx +25 -56
- package/src/ui/screens/LanguageSelectorScreen.tsx +84 -170
- package/src/ui/screens/LegalDocumentsScreen.tsx +18 -41
- package/src/ui/screens/OxyAuthScreen.tsx +402 -0
- package/src/ui/screens/PaymentGatewayScreen.tsx +20 -22
- package/src/ui/screens/PremiumSubscriptionScreen.tsx +13 -10
- package/src/ui/screens/PrivacySettingsScreen.tsx +150 -198
- package/src/ui/screens/ProfileScreen.tsx +7 -6
- package/src/ui/screens/SavesCollectionsScreen.tsx +39 -62
- package/src/ui/screens/SearchSettingsScreen.tsx +36 -86
- package/src/ui/screens/SessionManagementScreen.tsx +25 -17
- package/src/ui/screens/UserLinksScreen.tsx +10 -11
- package/src/ui/screens/WelcomeNewUserScreen.tsx +41 -41
- package/src/ui/screens/karma/KarmaAboutScreen.tsx +13 -9
- package/src/ui/screens/karma/KarmaCenterScreen.tsx +70 -70
- package/src/ui/screens/karma/KarmaFAQScreen.tsx +96 -96
- package/src/ui/screens/karma/KarmaLeaderboardScreen.tsx +15 -10
- package/src/ui/screens/karma/KarmaRewardsScreen.tsx +605 -60
- package/src/ui/screens/karma/KarmaRulesScreen.tsx +14 -9
- package/src/ui/stores/authStore.ts +1 -1
- package/src/ui/styles/authStyles.ts +5 -11
- package/src/ui/styles/spacing.ts +21 -2
- package/src/ui/styles/theme.ts +1 -1
- package/src/ui/types/fileManagement.ts +51 -0
- package/src/ui/types/navigation.ts +61 -0
- package/src/ui/utils/colorUtils.ts +46 -0
- package/src/ui/utils/errorHandlers.ts +136 -0
- package/src/ui/utils/fileManagement.ts +190 -0
- package/src/ui/utils/sessionHelpers.ts +146 -0
- package/src/ui/utils/storageHelpers.ts +134 -0
- package/src/ui/utils/themeUtils.ts +43 -0
- package/src/ui/utils/user-utils.ts +58 -0
- package/src/utils/errorUtils.ts +14 -4
- package/lib/commonjs/ui/components/internal/TextField.js +0 -733
- package/lib/commonjs/ui/components/internal/TextField.js.map +0 -1
- package/lib/commonjs/ui/navigation/OxyRouter.js +0 -213
- package/lib/commonjs/ui/navigation/OxyRouter.js.map +0 -1
- package/lib/commonjs/ui/navigation/types.js +0 -13
- package/lib/commonjs/ui/navigation/types.js.map +0 -1
- package/lib/commonjs/ui/screens/AccountManagementDemo.js +0 -298
- package/lib/commonjs/ui/screens/AccountManagementDemo.js.map +0 -1
- package/lib/commonjs/ui/screens/RecoverAccountScreen.js +0 -137
- package/lib/commonjs/ui/screens/RecoverAccountScreen.js.map +0 -1
- package/lib/commonjs/ui/screens/SignInScreen.js +0 -270
- package/lib/commonjs/ui/screens/SignInScreen.js.map +0 -1
- package/lib/commonjs/ui/screens/SignUpScreen.js +0 -229
- package/lib/commonjs/ui/screens/SignUpScreen.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/RecoverRequestStep.js +0 -135
- package/lib/commonjs/ui/screens/steps/RecoverRequestStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/RecoverResetPasswordStep.js +0 -165
- package/lib/commonjs/ui/screens/steps/RecoverResetPasswordStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/RecoverSuccessStep.js +0 -159
- package/lib/commonjs/ui/screens/steps/RecoverSuccessStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/RecoverVerifyStep.js +0 -144
- package/lib/commonjs/ui/screens/steps/RecoverVerifyStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignInPasswordStep.js +0 -358
- package/lib/commonjs/ui/screens/steps/SignInPasswordStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignInTotpStep.js +0 -188
- package/lib/commonjs/ui/screens/steps/SignInTotpStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignInUsernameStep.js +0 -509
- package/lib/commonjs/ui/screens/steps/SignInUsernameStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignUpIdentityStep.js +0 -200
- package/lib/commonjs/ui/screens/steps/SignUpIdentityStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignUpSecurityStep.js +0 -185
- package/lib/commonjs/ui/screens/steps/SignUpSecurityStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignUpSummaryStep.js +0 -138
- package/lib/commonjs/ui/screens/steps/SignUpSummaryStep.js.map +0 -1
- package/lib/commonjs/ui/screens/steps/SignUpWelcomeStep.js +0 -150
- package/lib/commonjs/ui/screens/steps/SignUpWelcomeStep.js.map +0 -1
- package/lib/module/package.json +0 -1
- package/lib/module/ui/components/internal/TextField.js +0 -729
- package/lib/module/ui/components/internal/TextField.js.map +0 -1
- package/lib/module/ui/navigation/OxyRouter.js +0 -209
- package/lib/module/ui/navigation/OxyRouter.js.map +0 -1
- package/lib/module/ui/navigation/types.js +0 -22
- package/lib/module/ui/navigation/types.js.map +0 -1
- package/lib/module/ui/screens/AccountManagementDemo.js +0 -295
- package/lib/module/ui/screens/AccountManagementDemo.js.map +0 -1
- package/lib/module/ui/screens/RecoverAccountScreen.js +0 -133
- package/lib/module/ui/screens/RecoverAccountScreen.js.map +0 -1
- package/lib/module/ui/screens/SignInScreen.js +0 -265
- package/lib/module/ui/screens/SignInScreen.js.map +0 -1
- package/lib/module/ui/screens/SignUpScreen.js +0 -224
- package/lib/module/ui/screens/SignUpScreen.js.map +0 -1
- package/lib/module/ui/screens/steps/RecoverRequestStep.js +0 -130
- package/lib/module/ui/screens/steps/RecoverRequestStep.js.map +0 -1
- package/lib/module/ui/screens/steps/RecoverResetPasswordStep.js +0 -160
- package/lib/module/ui/screens/steps/RecoverResetPasswordStep.js.map +0 -1
- package/lib/module/ui/screens/steps/RecoverSuccessStep.js +0 -154
- package/lib/module/ui/screens/steps/RecoverSuccessStep.js.map +0 -1
- package/lib/module/ui/screens/steps/RecoverVerifyStep.js +0 -139
- package/lib/module/ui/screens/steps/RecoverVerifyStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignInPasswordStep.js +0 -353
- package/lib/module/ui/screens/steps/SignInPasswordStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignInTotpStep.js +0 -183
- package/lib/module/ui/screens/steps/SignInTotpStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignInUsernameStep.js +0 -504
- package/lib/module/ui/screens/steps/SignInUsernameStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignUpIdentityStep.js +0 -195
- package/lib/module/ui/screens/steps/SignUpIdentityStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignUpSecurityStep.js +0 -180
- package/lib/module/ui/screens/steps/SignUpSecurityStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignUpSummaryStep.js +0 -133
- package/lib/module/ui/screens/steps/SignUpSummaryStep.js.map +0 -1
- package/lib/module/ui/screens/steps/SignUpWelcomeStep.js +0 -145
- package/lib/module/ui/screens/steps/SignUpWelcomeStep.js.map +0 -1
- package/lib/typescript/ui/components/internal/TextField.d.ts +0 -41
- package/lib/typescript/ui/components/internal/TextField.d.ts.map +0 -1
- package/lib/typescript/ui/navigation/OxyRouter.d.ts +0 -7
- package/lib/typescript/ui/navigation/OxyRouter.d.ts.map +0 -1
- package/lib/typescript/ui/navigation/types.d.ts +0 -141
- package/lib/typescript/ui/navigation/types.d.ts.map +0 -1
- package/lib/typescript/ui/screens/AccountManagementDemo.d.ts +0 -8
- package/lib/typescript/ui/screens/AccountManagementDemo.d.ts.map +0 -1
- package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts +0 -5
- package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts.map +0 -1
- package/lib/typescript/ui/screens/SignInScreen.d.ts +0 -5
- package/lib/typescript/ui/screens/SignInScreen.d.ts.map +0 -1
- package/lib/typescript/ui/screens/SignUpScreen.d.ts +0 -5
- package/lib/typescript/ui/screens/SignUpScreen.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/RecoverRequestStep.d.ts +0 -24
- package/lib/typescript/ui/screens/steps/RecoverRequestStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/RecoverResetPasswordStep.d.ts +0 -24
- package/lib/typescript/ui/screens/steps/RecoverResetPasswordStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/RecoverSuccessStep.d.ts +0 -19
- package/lib/typescript/ui/screens/steps/RecoverSuccessStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/RecoverVerifyStep.d.ts +0 -26
- package/lib/typescript/ui/screens/steps/RecoverVerifyStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignInPasswordStep.d.ts +0 -30
- package/lib/typescript/ui/screens/steps/SignInPasswordStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignInTotpStep.d.ts +0 -19
- package/lib/typescript/ui/screens/steps/SignInTotpStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignInUsernameStep.d.ts +0 -28
- package/lib/typescript/ui/screens/steps/SignInUsernameStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignUpIdentityStep.d.ts +0 -26
- package/lib/typescript/ui/screens/steps/SignUpIdentityStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignUpSecurityStep.d.ts +0 -27
- package/lib/typescript/ui/screens/steps/SignUpSecurityStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignUpSummaryStep.d.ts +0 -17
- package/lib/typescript/ui/screens/steps/SignUpSummaryStep.d.ts.map +0 -1
- package/lib/typescript/ui/screens/steps/SignUpWelcomeStep.d.ts +0 -14
- package/lib/typescript/ui/screens/steps/SignUpWelcomeStep.d.ts.map +0 -1
- package/src/ui/components/internal/TextField.tsx +0 -876
- package/src/ui/navigation/OxyRouter.tsx +0 -216
- package/src/ui/navigation/types.ts +0 -164
- package/src/ui/screens/AccountManagementDemo.tsx +0 -297
- package/src/ui/screens/RecoverAccountScreen.tsx +0 -141
- package/src/ui/screens/SignInScreen.tsx +0 -297
- package/src/ui/screens/SignUpScreen.tsx +0 -239
- package/src/ui/screens/steps/RecoverRequestStep.tsx +0 -143
- package/src/ui/screens/steps/RecoverResetPasswordStep.tsx +0 -162
- package/src/ui/screens/steps/RecoverSuccessStep.tsx +0 -148
- package/src/ui/screens/steps/RecoverVerifyStep.tsx +0 -154
- package/src/ui/screens/steps/SignInPasswordStep.tsx +0 -343
- package/src/ui/screens/steps/SignInTotpStep.tsx +0 -163
- package/src/ui/screens/steps/SignInUsernameStep.tsx +0 -560
- package/src/ui/screens/steps/SignUpIdentityStep.tsx +0 -217
- package/src/ui/screens/steps/SignUpSecurityStep.tsx +0 -207
- package/src/ui/screens/steps/SignUpSummaryStep.tsx +0 -155
- package/src/ui/screens/steps/SignUpWelcomeStep.tsx +0 -127
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* Asset & File Methods Mixin
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
import { File } from 'expo-file-system';
|
|
7
8
|
export function OxyServicesAssetsMixin(Base) {
|
|
8
9
|
return class extends Base {
|
|
9
10
|
constructor(...args) {
|
|
@@ -152,13 +153,139 @@ export function OxyServicesAssetsMixin(Base) {
|
|
|
152
153
|
// ============================================================================
|
|
153
154
|
|
|
154
155
|
/**
|
|
155
|
-
*
|
|
156
|
+
* Get base64 string from file - uses expo-file-system when URI is available
|
|
157
|
+
* Returns base64 string directly for use with expo-crypto
|
|
158
|
+
*/
|
|
159
|
+
async getFileBase64(file) {
|
|
160
|
+
// Check for URI from DocumentPicker (Expo 54)
|
|
161
|
+
const uri = file.uri;
|
|
162
|
+
if (uri && typeof uri === 'string') {
|
|
163
|
+
// Use Expo 54 FileSystem API
|
|
164
|
+
try {
|
|
165
|
+
const fileInstance = new File(uri);
|
|
166
|
+
return await fileInstance.base64();
|
|
167
|
+
} catch (error) {
|
|
168
|
+
throw new Error(`Failed to read file from URI: ${error.message || 'Unknown error'}`);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
// For files without URI (web Blobs), convert to base64 using fetch
|
|
173
|
+
const blobUrl = URL.createObjectURL(file);
|
|
174
|
+
try {
|
|
175
|
+
const response = await fetch(blobUrl);
|
|
176
|
+
if (!response.ok) {
|
|
177
|
+
throw new Error(`Failed to fetch file: ${response.statusText || 'HTTP ' + response.status}`);
|
|
178
|
+
}
|
|
179
|
+
const buffer = await response.arrayBuffer();
|
|
180
|
+
// Convert ArrayBuffer to base64 using chunked approach to avoid stack overflow
|
|
181
|
+
return this.arrayBufferToBase64Safe(buffer);
|
|
182
|
+
} finally {
|
|
183
|
+
URL.revokeObjectURL(blobUrl);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/**
|
|
188
|
+
* Convert File or Blob to ArrayBuffer - uses expo-file-system when URI available
|
|
189
|
+
*/
|
|
190
|
+
async fileToArrayBuffer(file) {
|
|
191
|
+
// Check for URI from DocumentPicker (Expo 54)
|
|
192
|
+
const uri = file.uri;
|
|
193
|
+
if (uri && typeof uri === 'string') {
|
|
194
|
+
// Use Expo 54 FileSystem API
|
|
195
|
+
try {
|
|
196
|
+
const fileInstance = new File(uri);
|
|
197
|
+
const bytes = await fileInstance.bytes();
|
|
198
|
+
return bytes.buffer;
|
|
199
|
+
} catch (error) {
|
|
200
|
+
throw new Error(`Failed to read file from URI: ${error.message || 'Unknown error'}`);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
// For files without URI, use native arrayBuffer if available, else fetch
|
|
205
|
+
if (typeof file.arrayBuffer === 'function') {
|
|
206
|
+
return await file.arrayBuffer();
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
// Fallback: fetch via blob URL
|
|
210
|
+
const blobUrl = URL.createObjectURL(file);
|
|
211
|
+
try {
|
|
212
|
+
const response = await fetch(blobUrl);
|
|
213
|
+
if (!response.ok) {
|
|
214
|
+
throw new Error(`Failed to fetch file: ${response.statusText || 'HTTP ' + response.status}`);
|
|
215
|
+
}
|
|
216
|
+
return await response.arrayBuffer();
|
|
217
|
+
} finally {
|
|
218
|
+
URL.revokeObjectURL(blobUrl);
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* Convert ArrayBuffer to hex string
|
|
224
|
+
*/
|
|
225
|
+
arrayBufferToHex(buffer) {
|
|
226
|
+
const bytes = new Uint8Array(buffer);
|
|
227
|
+
return Array.from(bytes, b => b.toString(16).padStart(2, '0')).join('');
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
/**
|
|
231
|
+
* Convert base64 string to ArrayBuffer (safe for large files)
|
|
232
|
+
*/
|
|
233
|
+
base64ToArrayBuffer(base64) {
|
|
234
|
+
const binaryString = atob(base64);
|
|
235
|
+
const bytes = new Uint8Array(binaryString.length);
|
|
236
|
+
for (let i = 0; i < binaryString.length; i++) {
|
|
237
|
+
bytes[i] = binaryString.charCodeAt(i);
|
|
238
|
+
}
|
|
239
|
+
return bytes.buffer;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
/**
|
|
243
|
+
* Convert ArrayBuffer to base64 string (safe chunked approach to avoid stack overflow)
|
|
244
|
+
*/
|
|
245
|
+
arrayBufferToBase64Safe(buffer) {
|
|
246
|
+
const bytes = new Uint8Array(buffer);
|
|
247
|
+
const chunkSize = 8192; // Process in chunks to avoid stack overflow
|
|
248
|
+
|
|
249
|
+
// Use chunked approach for large buffers
|
|
250
|
+
if (bytes.length > chunkSize) {
|
|
251
|
+
let binary = '';
|
|
252
|
+
for (let i = 0; i < bytes.length; i += chunkSize) {
|
|
253
|
+
const chunk = bytes.slice(i, i + chunkSize);
|
|
254
|
+
binary += String.fromCharCode.apply(null, Array.from(chunk));
|
|
255
|
+
}
|
|
256
|
+
return typeof btoa !== 'undefined' ? btoa(binary) : Buffer.from(binary, 'binary').toString('base64');
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// Small buffers can use direct conversion
|
|
260
|
+
const binary = String.fromCharCode.apply(null, Array.from(bytes));
|
|
261
|
+
return typeof btoa !== 'undefined' ? btoa(binary) : Buffer.from(binary, 'binary').toString('base64');
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
/**
|
|
265
|
+
* Calculate SHA256 hash of file content - uses expo-crypto (Expo 54 unified API)
|
|
156
266
|
*/
|
|
157
267
|
async calculateSHA256(file) {
|
|
158
|
-
|
|
159
|
-
const
|
|
160
|
-
|
|
161
|
-
|
|
268
|
+
// Use expo-crypto (works on all platforms with Expo 54)
|
|
269
|
+
const CryptoModule = await import('expo-crypto').catch(() => null);
|
|
270
|
+
if (!CryptoModule) {
|
|
271
|
+
throw new Error('expo-crypto is not available. Install it with: npx expo install expo-crypto');
|
|
272
|
+
}
|
|
273
|
+
const Crypto = CryptoModule.default || CryptoModule;
|
|
274
|
+
if (!Crypto?.digestStringAsync) {
|
|
275
|
+
throw new Error('expo-crypto.digestStringAsync is not available');
|
|
276
|
+
}
|
|
277
|
+
try {
|
|
278
|
+
// Read file as base64 (uses expo-file-system if URI available, else converts)
|
|
279
|
+
const base64 = await this.getFileBase64(file);
|
|
280
|
+
const algorithm = Crypto.CryptoDigestAlgorithm?.SHA256 || 'SHA256';
|
|
281
|
+
const encoding = Crypto.CryptoEncoding?.BASE64 || 'base64';
|
|
282
|
+
return await Crypto.digestStringAsync(algorithm, base64, {
|
|
283
|
+
encoding
|
|
284
|
+
});
|
|
285
|
+
} catch (error) {
|
|
286
|
+
const errorMessage = error?.message || String(error) || 'Unknown error';
|
|
287
|
+
throw new Error(`Failed to calculate SHA256 hash: ${errorMessage}`);
|
|
288
|
+
}
|
|
162
289
|
}
|
|
163
290
|
|
|
164
291
|
/**
|
|
@@ -202,33 +329,98 @@ export function OxyServicesAssetsMixin(Base) {
|
|
|
202
329
|
* Upload file using Central Asset Service
|
|
203
330
|
*/
|
|
204
331
|
async assetUpload(file, visibility, metadata, onProgress) {
|
|
332
|
+
const fileName = file.name || 'unknown';
|
|
333
|
+
const fileSize = file.size;
|
|
334
|
+
const fileType = file.type || 'application/octet-stream';
|
|
205
335
|
try {
|
|
206
336
|
// Calculate SHA256
|
|
207
|
-
|
|
337
|
+
let sha256;
|
|
338
|
+
try {
|
|
339
|
+
sha256 = await this.calculateSHA256(file);
|
|
340
|
+
} catch (error) {
|
|
341
|
+
throw new Error(`Failed to calculate file hash for "${fileName}": ${error.message || 'Unknown error'}`);
|
|
342
|
+
}
|
|
208
343
|
|
|
209
344
|
// Initialize upload
|
|
210
|
-
|
|
345
|
+
let initResponse;
|
|
346
|
+
try {
|
|
347
|
+
initResponse = await this.assetInit(sha256, fileSize, fileType);
|
|
348
|
+
} catch (error) {
|
|
349
|
+
throw new Error(`Failed to initialize upload for "${fileName}": ${error.message || 'Unknown error'}`);
|
|
350
|
+
}
|
|
211
351
|
|
|
212
|
-
// Try presigned URL first
|
|
352
|
+
// Try presigned URL first, fallback to direct upload
|
|
213
353
|
try {
|
|
214
354
|
await this.uploadToPresignedUrl(initResponse.uploadUrl, file, onProgress);
|
|
215
|
-
} catch (
|
|
355
|
+
} catch (uploadError) {
|
|
216
356
|
// Fallback: direct upload via API to avoid CORS issues
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
357
|
+
try {
|
|
358
|
+
const fd = new FormData();
|
|
359
|
+
fd.append('file', file);
|
|
360
|
+
await this.getClient().request({
|
|
361
|
+
method: 'POST',
|
|
362
|
+
url: `/api/assets/${encodeURIComponent(initResponse.fileId)}/upload-direct`,
|
|
363
|
+
data: fd,
|
|
364
|
+
cache: false
|
|
365
|
+
});
|
|
366
|
+
} catch (directUploadError) {
|
|
367
|
+
throw new Error(`Failed to upload file "${fileName}" (${(fileSize / 1024 / 1024).toFixed(2)}MB): ` + `Presigned URL failed: ${uploadError.message || 'Unknown error'}. ` + `Direct upload failed: ${directUploadError.message || 'Unknown error'}`);
|
|
368
|
+
}
|
|
226
369
|
}
|
|
227
370
|
|
|
228
371
|
// Complete upload
|
|
229
|
-
|
|
372
|
+
try {
|
|
373
|
+
return await this.assetComplete(initResponse.fileId, fileName, fileSize, fileType, visibility, metadata);
|
|
374
|
+
} catch (error) {
|
|
375
|
+
throw new Error(`Failed to complete upload for "${fileName}": ${error.message || 'Unknown error'}`);
|
|
376
|
+
}
|
|
230
377
|
} catch (error) {
|
|
231
|
-
|
|
378
|
+
// Log the original error for debugging
|
|
379
|
+
console.error('File upload error:', error);
|
|
380
|
+
|
|
381
|
+
// Preserve original error message before passing to handleError
|
|
382
|
+
// This ensures we don't lose the error details
|
|
383
|
+
let errorMessage = 'File upload failed';
|
|
384
|
+
if (error instanceof Error) {
|
|
385
|
+
errorMessage = error.message || errorMessage;
|
|
386
|
+
} else if (error && typeof error === 'object') {
|
|
387
|
+
// Try to extract message from various error formats
|
|
388
|
+
if ('message' in error) {
|
|
389
|
+
errorMessage = String(error.message) || errorMessage;
|
|
390
|
+
} else if ('error' in error && typeof error.error === 'string') {
|
|
391
|
+
errorMessage = error.error;
|
|
392
|
+
} else if ('data' in error && error.data?.message) {
|
|
393
|
+
errorMessage = String(error.data.message);
|
|
394
|
+
}
|
|
395
|
+
} else if (error) {
|
|
396
|
+
errorMessage = String(error) || errorMessage;
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
// Add file context to error for better debugging
|
|
400
|
+
const contextError = error;
|
|
401
|
+
if (!contextError.fileContext) {
|
|
402
|
+
contextError.fileContext = {
|
|
403
|
+
fileName,
|
|
404
|
+
fileSize,
|
|
405
|
+
fileType
|
|
406
|
+
};
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
// If the error already has a message, preserve it
|
|
410
|
+
if (error instanceof Error && error.message) {
|
|
411
|
+
// Pass through handleError but ensure message is preserved
|
|
412
|
+
const handledError = this.handleError(contextError);
|
|
413
|
+
// If handleError stripped the message, restore it
|
|
414
|
+
if (!handledError.message || handledError.message.trim() === 'An unexpected error occurred') {
|
|
415
|
+
handledError.message = errorMessage;
|
|
416
|
+
}
|
|
417
|
+
throw handledError;
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
// For non-Error objects, create a new Error with the message
|
|
421
|
+
const newError = new Error(errorMessage);
|
|
422
|
+
newError.fileContext = contextError.fileContext;
|
|
423
|
+
throw this.handleError(newError);
|
|
232
424
|
}
|
|
233
425
|
}
|
|
234
426
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["OxyServicesAssetsMixin","Base","constructor","args","deleteFile","fileId","makeRequest","encodeURIComponent","undefined","cache","error","handleError","getFileDownloadUrl","variant","expiresIn","base","getBaseURL","params","URLSearchParams","set","String","token","getClient","getAccessToken","qs","toString","getFileDownloadUrlAsync","url","fetchAssetDownloadUrl","getAssetUrlCacheTTL","listUserFiles","limit","offset","paramsObj","getFileContentAsText","downloadUrl","Error","fetchAssetContent","getFileContentAsBlob","getBatchFileAccess","fileIds","context","getFileDownloadUrls","response","urls","results","id","result","Object","entries","allowed","uploadRawFile","file","visibility","metadata","assetUpload","calculateSHA256","buffer","arrayBuffer","hashBuffer","crypto","subtle","digest","hashArray","Array","from","Uint8Array","map","b","padStart","join","assetInit","sha256","size","mime","assetComplete","originalName","onProgress","initResponse","type","uploadToPresignedUrl","uploadUrl","e","fd","FormData","append","request","method","data","name","Promise","resolve","reject","xhr","XMLHttpRequest","upload","addEventListener","event","lengthComputable","progress","loaded","total","status","open","setRequestHeader","send","assetLink","app","entityType","entityId","webhookUrl","body","assetUnlink","assetGet","cacheTTL","assetGetUrl","assetRestore","assetDelete","force","assetGetVariants","assetData","variants","assetUpdateVisibility","uploadAvatar","userId","asset","uploadProfileBanner","desiredTtlMs","Math","min","urlRes","keys","length","fetch","ok","text","blob"],"sourceRoot":"../../../../src","sources":["core/mixins/OxyServices.assets.ts"],"mappings":";;AAAA;AACA;AACA;;AAIA,OAAO,SAASA,sBAAsBA,CAAmCC,IAAO,EAAE;EAChF,OAAO,cAAcA,IAAI,CAAC;IACxBC,WAAWA,CAAC,GAAGC,IAAW,EAAE;MAC1B,KAAK,CAAC,GAAIA,IAAc,CAAC;IAC3B;IACA;IACA;IACA;;IAEA;AACJ;AACA;IACI,MAAMC,UAAUA,CAACC,MAAc,EAAgB;MAC7C,IAAI;QACF;QACA,OAAO,MAAM,IAAI,CAACC,WAAW,CAAC,QAAQ,EAAE,eAAeC,kBAAkB,CAACF,MAAM,CAAC,EAAE,EAAEG,SAAS,EAAE;UAAEC,KAAK,EAAE;QAAM,CAAC,CAAC;MACnH,CAAC,CAAC,OAAOC,KAAK,EAAE;QACd,MAAM,IAAI,CAACC,WAAW,CAACD,KAAK,CAAC;MAC/B;IACF;;IAEA;AACJ;AACA;AACA;AACA;IACIE,kBAAkBA,CAACP,MAAc,EAAEQ,OAAgB,EAAEC,SAAkB,EAAU;MAC/E,MAAMC,IAAI,GAAG,IAAI,CAACC,UAAU,CAAC,CAAC;MAC9B,MAAMC,MAAM,GAAG,IAAIC,eAAe,CAAC,CAAC;MACpC,IAAIL,OAAO,EAAEI,MAAM,CAACE,GAA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","deleteFile","fileId","makeRequest","encodeURIComponent","undefined","cache","error","handleError","getFileDownloadUrl","variant","expiresIn","base","getBaseURL","params","URLSearchParams","set","String","token","getClient","getAccessToken","qs","toString","getFileDownloadUrlAsync","url","fetchAssetDownloadUrl","getAssetUrlCacheTTL","listUserFiles","limit","offset","paramsObj","getFileContentAsText","downloadUrl","Error","fetchAssetContent","getFileContentAsBlob","getBatchFileAccess","fileIds","context","getFileDownloadUrls","response","urls","results","id","result","Object","entries","allowed","uploadRawFile","file","visibility","metadata","assetUpload","getFileBase64","uri","fileInstance","base64","message","blobUrl","URL","createObjectURL","fetch","ok","statusText","status","buffer","arrayBuffer","arrayBufferToBase64Safe","revokeObjectURL","fileToArrayBuffer","bytes","arrayBufferToHex","Uint8Array","Array","from","b","padStart","join","base64ToArrayBuffer","binaryString","atob","length","i","charCodeAt","chunkSize","binary","chunk","slice","fromCharCode","apply","btoa","Buffer","calculateSHA256","CryptoModule","catch","Crypto","default","digestStringAsync","algorithm","CryptoDigestAlgorithm","SHA256","encoding","CryptoEncoding","BASE64","errorMessage","assetInit","sha256","size","mime","assetComplete","originalName","onProgress","fileName","name","fileSize","fileType","type","initResponse","uploadToPresignedUrl","uploadUrl","uploadError","fd","FormData","append","request","method","data","directUploadError","toFixed","console","contextError","fileContext","handledError","trim","newError","Promise","resolve","reject","xhr","XMLHttpRequest","upload","addEventListener","event","lengthComputable","progress","loaded","total","open","setRequestHeader","send","assetLink","app","entityType","entityId","webhookUrl","body","assetUnlink","assetGet","cacheTTL","assetGetUrl","assetRestore","assetDelete","force","assetGetVariants","assetData","variants","assetUpdateVisibility","uploadAvatar","userId","asset","uploadProfileBanner","desiredTtlMs","Math","min","urlRes","keys","text","blob"],"sourceRoot":"../../../../src","sources":["core/mixins/OxyServices.assets.ts"],"mappings":";;AAAA;AACA;AACA;;AAGA,SAASA,IAAI,QAAQ,kBAAkB;AAEvC,OAAO,SAASC,sBAAsBA,CAAmCC,IAAO,EAAE;EAChF,OAAO,cAAc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CAAC;IAC/C;IAEA,MAAalJ,qBAAqBA,CAChCvB,MAAc,EACdQ,OAAgB,EAChBoJ,QAAiB,EACjBnJ,SAAkB,EACM;MACxB,MAAMG,MAAW,GAAG,CAAC,CAAC;MACtB,IAAIJ,OAAO,EAAEI,MAAM,CAACJ,OAAO,GAAGA,OAAO;MACrC,IAAIC,SAAS,EAAEG,MAAM,CAACH,SAAS,GAAGA,SAAS;MAE3C,MAAMmK,MAAM,GAAG,MAAM,IAAI,CAAC3K,WAAW,CACnC,KAAK,EACL,eAAeC,kBAAkB,CAACF,MAAM,CAAC,MAAM,EAC/C2C,MAAM,CAACkI,IAAI,CAACjK,MAAM,CAAC,CAACmE,MAAM,GAAGnE,MAAM,GAAGT,SAAS,EAC/C;QACEC,KAAK,EAAE,IAAI;QACXwJ,QAAQ,EAAEA,QAAQ,IAAI,EAAE,GAAG,EAAE,GAAG,IAAI,CAAE;MACxC,CACF,CAAC;MAED,OAAOgB,MAAM,EAAEtJ,GAAG,IAAI,IAAI;IAC5B;IAIA,MAAaU,iBAAiBA,CAACV,GAAW,EAAE4F,IAAqB,EAAE;MACjE,MAAM5E,QAAQ,GAAG,MAAMqB,KAAK,CAACrC,GAAG,CAAC;MACjC,IAAI,CAACgB,QAAQ,EAAEsB,EAAE,EAAE;QACjB,MAAM,IAAI7B,KAAK,CAAC,yCAAyCO,QAAQ,EAAEwB,MAAM,GAAG,CAAC;MAC/E;MACA,OAAOoD,IAAI,KAAK,MAAM,GAAG5E,QAAQ,CAACwI,IAAI,CAAC,CAAC,GAAGxI,QAAQ,CAACyI,IAAI,CAAC,CAAC;IAC5D;EACF,CAAC;AACH","ignoreList":[]}
|
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Authentication Methods Mixin
|
|
5
|
+
*
|
|
6
|
+
* Public key authentication using ECDSA signatures.
|
|
7
|
+
* No passwords required - authentication is done via challenge-response.
|
|
5
8
|
*/
|
|
6
9
|
|
|
7
10
|
import { OxyAuthenticationError } from '../OxyServices.errors';
|
|
@@ -10,20 +13,29 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
10
13
|
constructor(...args) {
|
|
11
14
|
super(...args);
|
|
12
15
|
}
|
|
16
|
+
|
|
13
17
|
/**
|
|
14
|
-
*
|
|
18
|
+
* Register a new user with public key authentication
|
|
19
|
+
*
|
|
20
|
+
* @param publicKey - The user's ECDSA public key (hex)
|
|
21
|
+
* @param username - Desired username
|
|
22
|
+
* @param email - Optional email address
|
|
23
|
+
* @param signature - Signature of the registration request
|
|
24
|
+
* @param timestamp - Timestamp when the signature was created
|
|
15
25
|
*/
|
|
16
|
-
async
|
|
26
|
+
async register(publicKey, username, signature, timestamp, email) {
|
|
17
27
|
try {
|
|
18
|
-
const res = await this.makeRequest('POST', '/api/auth/
|
|
28
|
+
const res = await this.makeRequest('POST', '/api/auth/register', {
|
|
29
|
+
publicKey,
|
|
19
30
|
username,
|
|
20
31
|
email,
|
|
21
|
-
|
|
32
|
+
signature,
|
|
33
|
+
timestamp
|
|
22
34
|
}, {
|
|
23
35
|
cache: false
|
|
24
36
|
});
|
|
25
37
|
if (!res || typeof res === 'object' && Object.keys(res).length === 0) {
|
|
26
|
-
throw new OxyAuthenticationError('
|
|
38
|
+
throw new OxyAuthenticationError('Registration failed', 'REGISTER_FAILED', 400);
|
|
27
39
|
}
|
|
28
40
|
return res;
|
|
29
41
|
} catch (error) {
|
|
@@ -32,45 +44,15 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
32
44
|
}
|
|
33
45
|
|
|
34
46
|
/**
|
|
35
|
-
* Request
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
return await this.makeRequest('POST', '/api/auth/recover/request', {
|
|
40
|
-
identifier
|
|
41
|
-
}, {
|
|
42
|
-
cache: false
|
|
43
|
-
});
|
|
44
|
-
} catch (error) {
|
|
45
|
-
throw this.handleError(error);
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* Verify recovery code
|
|
51
|
-
*/
|
|
52
|
-
async verifyRecoveryCode(identifier, code) {
|
|
53
|
-
try {
|
|
54
|
-
return await this.makeRequest('POST', '/api/auth/recover/verify', {
|
|
55
|
-
identifier,
|
|
56
|
-
code
|
|
57
|
-
}, {
|
|
58
|
-
cache: false
|
|
59
|
-
});
|
|
60
|
-
} catch (error) {
|
|
61
|
-
throw this.handleError(error);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* Reset password using verified code
|
|
47
|
+
* Request an authentication challenge
|
|
48
|
+
* The client must sign this challenge with their private key
|
|
49
|
+
*
|
|
50
|
+
* @param publicKey - The user's public key
|
|
67
51
|
*/
|
|
68
|
-
async
|
|
52
|
+
async requestChallenge(publicKey) {
|
|
69
53
|
try {
|
|
70
|
-
return await this.makeRequest('POST', '/api/auth/
|
|
71
|
-
|
|
72
|
-
code,
|
|
73
|
-
newPassword
|
|
54
|
+
return await this.makeRequest('POST', '/api/auth/challenge', {
|
|
55
|
+
publicKey
|
|
74
56
|
}, {
|
|
75
57
|
cache: false
|
|
76
58
|
});
|
|
@@ -80,40 +62,24 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
80
62
|
}
|
|
81
63
|
|
|
82
64
|
/**
|
|
83
|
-
*
|
|
65
|
+
* Verify a signed challenge and create a session
|
|
66
|
+
*
|
|
67
|
+
* @param publicKey - The user's public key
|
|
68
|
+
* @param challenge - The challenge string from requestChallenge
|
|
69
|
+
* @param signature - Signature of the auth message
|
|
70
|
+
* @param timestamp - Timestamp when the signature was created
|
|
71
|
+
* @param deviceName - Optional device name
|
|
72
|
+
* @param deviceFingerprint - Optional device fingerprint
|
|
84
73
|
*/
|
|
85
|
-
async
|
|
86
|
-
try {
|
|
87
|
-
return await this.makeRequest('POST', '/api/auth/recover/totp/reset', {
|
|
88
|
-
identifier,
|
|
89
|
-
code,
|
|
90
|
-
newPassword
|
|
91
|
-
}, {
|
|
92
|
-
cache: false
|
|
93
|
-
});
|
|
94
|
-
} catch (error) {
|
|
95
|
-
throw this.handleError(error);
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
async resetPasswordWithBackupCode(identifier, backupCode, newPassword) {
|
|
74
|
+
async verifyChallenge(publicKey, challenge, signature, timestamp, deviceName, deviceFingerprint) {
|
|
99
75
|
try {
|
|
100
|
-
return await this.makeRequest('POST', '/api/auth/
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
} catch (error) {
|
|
108
|
-
throw this.handleError(error);
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
async resetPasswordWithRecoveryKey(identifier, recoveryKey, newPassword) {
|
|
112
|
-
try {
|
|
113
|
-
return await this.makeRequest('POST', '/api/auth/recover/recovery-key/reset', {
|
|
114
|
-
identifier,
|
|
115
|
-
recoveryKey,
|
|
116
|
-
newPassword
|
|
76
|
+
return await this.makeRequest('POST', '/api/auth/verify', {
|
|
77
|
+
publicKey,
|
|
78
|
+
challenge,
|
|
79
|
+
signature,
|
|
80
|
+
timestamp,
|
|
81
|
+
deviceName,
|
|
82
|
+
deviceFingerprint
|
|
117
83
|
}, {
|
|
118
84
|
cache: false
|
|
119
85
|
});
|
|
@@ -123,16 +89,11 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
123
89
|
}
|
|
124
90
|
|
|
125
91
|
/**
|
|
126
|
-
*
|
|
92
|
+
* Check if a public key is already registered
|
|
127
93
|
*/
|
|
128
|
-
async
|
|
94
|
+
async checkPublicKeyRegistered(publicKey) {
|
|
129
95
|
try {
|
|
130
|
-
return await this.makeRequest('
|
|
131
|
-
username,
|
|
132
|
-
password,
|
|
133
|
-
deviceName,
|
|
134
|
-
deviceFingerprint
|
|
135
|
-
}, {
|
|
96
|
+
return await this.makeRequest('GET', `/api/auth/check-publickey/${encodeURIComponent(publicKey)}`, undefined, {
|
|
136
97
|
cache: false
|
|
137
98
|
});
|
|
138
99
|
} catch (error) {
|
|
@@ -141,15 +102,13 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
141
102
|
}
|
|
142
103
|
|
|
143
104
|
/**
|
|
144
|
-
*
|
|
105
|
+
* Get user by public key
|
|
145
106
|
*/
|
|
146
|
-
async
|
|
107
|
+
async getUserByPublicKey(publicKey) {
|
|
147
108
|
try {
|
|
148
|
-
return await this.makeRequest('
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
}, {
|
|
152
|
-
cache: false
|
|
109
|
+
return await this.makeRequest('GET', `/api/auth/user/${encodeURIComponent(publicKey)}`, undefined, {
|
|
110
|
+
cache: true,
|
|
111
|
+
cacheTTL: 2 * 60 * 1000
|
|
153
112
|
});
|
|
154
113
|
} catch (error) {
|
|
155
114
|
throw this.handleError(error);
|
|
@@ -163,7 +122,7 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
163
122
|
try {
|
|
164
123
|
return await this.makeRequest('GET', `/api/session/user/${sessionId}`, undefined, {
|
|
165
124
|
cache: true,
|
|
166
|
-
cacheTTL: 2 * 60 * 1000
|
|
125
|
+
cacheTTL: 2 * 60 * 1000
|
|
167
126
|
});
|
|
168
127
|
} catch (error) {
|
|
169
128
|
throw this.handleError(error);
|
|
@@ -171,24 +130,20 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
171
130
|
}
|
|
172
131
|
|
|
173
132
|
/**
|
|
174
|
-
* Batch get multiple user profiles by session IDs
|
|
175
|
-
* Returns array of { sessionId, user } objects
|
|
133
|
+
* Batch get multiple user profiles by session IDs
|
|
176
134
|
*/
|
|
177
135
|
async getUsersBySessions(sessionIds) {
|
|
178
136
|
try {
|
|
179
137
|
if (!Array.isArray(sessionIds) || sessionIds.length === 0) {
|
|
180
138
|
return [];
|
|
181
139
|
}
|
|
182
|
-
|
|
183
|
-
// Deduplicate and sort sessionIds for consistent cache keys
|
|
184
140
|
const uniqueSessionIds = Array.from(new Set(sessionIds)).sort();
|
|
185
141
|
return await this.makeRequest('POST', '/api/session/users/batch', {
|
|
186
142
|
sessionIds: uniqueSessionIds
|
|
187
143
|
}, {
|
|
188
144
|
cache: true,
|
|
189
145
|
cacheTTL: 2 * 60 * 1000,
|
|
190
|
-
|
|
191
|
-
deduplicate: true // Important for batch requests
|
|
146
|
+
deduplicate: true
|
|
192
147
|
});
|
|
193
148
|
} catch (error) {
|
|
194
149
|
throw this.handleError(error);
|
|
@@ -196,7 +151,7 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
196
151
|
}
|
|
197
152
|
|
|
198
153
|
/**
|
|
199
|
-
* Get access token by session ID
|
|
154
|
+
* Get access token by session ID
|
|
200
155
|
*/
|
|
201
156
|
async getTokenBySession(sessionId) {
|
|
202
157
|
try {
|
|
@@ -204,8 +159,6 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
204
159
|
cache: false,
|
|
205
160
|
retry: false
|
|
206
161
|
});
|
|
207
|
-
|
|
208
|
-
// Set the token in the centralized token store
|
|
209
162
|
this.setTokens(res.accessToken);
|
|
210
163
|
return res;
|
|
211
164
|
} catch (error) {
|
|
@@ -294,6 +247,24 @@ export function OxyServicesAuthMixin(Base) {
|
|
|
294
247
|
throw this.handleError(error);
|
|
295
248
|
}
|
|
296
249
|
}
|
|
250
|
+
|
|
251
|
+
// ==========================================
|
|
252
|
+
// Deprecated methods - kept for reference
|
|
253
|
+
// ==========================================
|
|
254
|
+
|
|
255
|
+
/**
|
|
256
|
+
* @deprecated Use register() with public key authentication instead
|
|
257
|
+
*/
|
|
258
|
+
async signUp(username, email, password) {
|
|
259
|
+
throw new OxyAuthenticationError('Password-based signup is no longer supported. Use register() with public key.', 'DEPRECATED', 410);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* @deprecated Use requestChallenge() and verifyChallenge() instead
|
|
264
|
+
*/
|
|
265
|
+
async signIn(username, password, deviceName, deviceFingerprint) {
|
|
266
|
+
throw new OxyAuthenticationError('Password-based login is no longer supported. Use challenge-response authentication.', 'DEPRECATED', 410);
|
|
267
|
+
}
|
|
297
268
|
};
|
|
298
269
|
}
|
|
299
270
|
//# sourceMappingURL=OxyServices.auth.js.map
|