@oxyhq/services 5.5.8 → 5.6.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 +16 -2
- package/lib/commonjs/core/index.js +69 -82
- package/lib/commonjs/core/index.js.map +1 -1
- package/lib/commonjs/index.js +24 -183
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/node/index.js +0 -2
- package/lib/commonjs/node/index.js.map +1 -1
- package/lib/commonjs/ui/components/FollowButton.js +100 -229
- package/lib/commonjs/ui/components/FollowButton.js.map +1 -1
- package/lib/commonjs/ui/components/OxyPayButton.js +131 -0
- package/lib/commonjs/ui/components/OxyPayButton.js.map +1 -0
- package/lib/commonjs/ui/components/OxyProvider.js +41 -198
- package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
- package/lib/commonjs/ui/components/OxySignInButton.js +15 -2
- package/lib/commonjs/ui/components/OxySignInButton.js.map +1 -1
- package/lib/commonjs/ui/components/icon/FAIRWalletIcon.js +66 -0
- package/lib/commonjs/ui/components/icon/FAIRWalletIcon.js.map +1 -0
- package/lib/commonjs/ui/components/icon/index.js +7 -0
- package/lib/commonjs/ui/components/icon/index.js.map +1 -1
- package/lib/commonjs/ui/components/index.js +7 -0
- package/lib/commonjs/ui/components/index.js.map +1 -1
- package/lib/commonjs/ui/components/internal/GroupedPillButtons.js +14 -7
- package/lib/commonjs/ui/components/internal/GroupedPillButtons.js.map +1 -1
- package/lib/commonjs/ui/components/internal/PinInput.js +108 -0
- package/lib/commonjs/ui/components/internal/PinInput.js.map +1 -0
- package/lib/commonjs/ui/components/internal/TextField.js +20 -0
- package/lib/commonjs/ui/components/internal/TextField.js.map +1 -1
- package/lib/commonjs/ui/context/OxyContext.js +26 -23
- package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
- package/lib/commonjs/ui/hooks/index.js +2 -15
- package/lib/commonjs/ui/hooks/index.js.map +1 -1
- package/lib/commonjs/ui/hooks/useFollow.js +52 -136
- package/lib/commonjs/ui/hooks/useFollow.js.map +1 -1
- package/lib/commonjs/ui/hooks/useSessionSocket.js +52 -0
- package/lib/commonjs/ui/hooks/useSessionSocket.js.map +1 -0
- package/lib/commonjs/ui/index.js +8 -191
- package/lib/commonjs/ui/index.js.map +1 -1
- package/lib/commonjs/ui/navigation/OxyRouter.js +52 -60
- package/lib/commonjs/ui/navigation/OxyRouter.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountCenterScreen.js +18 -30
- package/lib/commonjs/ui/screens/AccountCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountOverviewScreen.js +4 -22
- package/lib/commonjs/ui/screens/AccountOverviewScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js +6 -14
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSwitcherScreen.js +37 -66
- package/lib/commonjs/ui/screens/AccountSwitcherScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AppInfoScreen.js +21 -44
- package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FeedbackScreen.js +44 -23
- package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FileManagementScreen.js +59 -78
- package/lib/commonjs/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +1588 -0
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js +22 -36
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/RecoverAccountScreen.js +269 -0
- package/lib/commonjs/ui/screens/RecoverAccountScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/SessionManagementScreen.js +47 -69
- package/lib/commonjs/ui/screens/SessionManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SignInScreen.js +99 -333
- package/lib/commonjs/ui/screens/SignInScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SignUpScreen.js +136 -340
- package/lib/commonjs/ui/screens/SignUpScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/internal/SignInPasswordStep.js +192 -0
- package/lib/commonjs/ui/screens/internal/SignInPasswordStep.js.map +1 -0
- package/lib/commonjs/ui/screens/internal/SignInUsernameStep.js +135 -0
- package/lib/commonjs/ui/screens/internal/SignInUsernameStep.js.map +1 -0
- package/lib/commonjs/ui/screens/internal/SignUpIdentityStep.js +108 -0
- package/lib/commonjs/ui/screens/internal/SignUpIdentityStep.js.map +1 -0
- package/lib/commonjs/ui/screens/internal/SignUpSecurityStep.js +126 -0
- package/lib/commonjs/ui/screens/internal/SignUpSecurityStep.js.map +1 -0
- package/lib/commonjs/ui/screens/internal/SignUpSummaryStep.js +84 -0
- package/lib/commonjs/ui/screens/internal/SignUpSummaryStep.js.map +1 -0
- package/lib/commonjs/ui/screens/internal/SignUpWelcomeStep.js +59 -0
- package/lib/commonjs/ui/screens/internal/SignUpWelcomeStep.js.map +1 -0
- package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js +15 -2
- package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
- package/lib/commonjs/ui/stores/authStore.js +31 -0
- package/lib/commonjs/ui/stores/authStore.js.map +1 -0
- package/lib/commonjs/ui/stores/followStore.js +124 -0
- package/lib/commonjs/ui/stores/followStore.js.map +1 -0
- package/lib/commonjs/ui/styles/index.js +0 -11
- package/lib/commonjs/ui/styles/index.js.map +1 -1
- package/lib/commonjs/ui/utils/confirmAction.js +28 -0
- package/lib/commonjs/ui/utils/confirmAction.js.map +1 -0
- package/lib/module/core/index.js +69 -81
- package/lib/module/core/index.js.map +1 -1
- package/lib/module/index.js +14 -17
- package/lib/module/index.js.map +1 -1
- package/lib/module/node/index.js +0 -3
- package/lib/module/node/index.js.map +1 -1
- package/lib/module/ui/components/FollowButton.js +100 -229
- package/lib/module/ui/components/FollowButton.js.map +1 -1
- package/lib/module/ui/components/OxyPayButton.js +125 -0
- package/lib/module/ui/components/OxyPayButton.js.map +1 -0
- package/lib/module/ui/components/OxyProvider.js +42 -199
- package/lib/module/ui/components/OxyProvider.js.map +1 -1
- package/lib/module/ui/components/OxySignInButton.js +15 -2
- package/lib/module/ui/components/OxySignInButton.js.map +1 -1
- package/lib/module/ui/components/icon/FAIRWalletIcon.js +60 -0
- package/lib/module/ui/components/icon/FAIRWalletIcon.js.map +1 -0
- package/lib/module/ui/components/icon/index.js +1 -0
- package/lib/module/ui/components/icon/index.js.map +1 -1
- package/lib/module/ui/components/index.js +1 -0
- package/lib/module/ui/components/index.js.map +1 -1
- package/lib/module/ui/components/internal/GroupedPillButtons.js +15 -8
- package/lib/module/ui/components/internal/GroupedPillButtons.js.map +1 -1
- package/lib/module/ui/components/internal/PinInput.js +103 -0
- package/lib/module/ui/components/internal/PinInput.js.map +1 -0
- package/lib/module/ui/components/internal/TextField.js +20 -0
- package/lib/module/ui/components/internal/TextField.js.map +1 -1
- package/lib/module/ui/context/OxyContext.js +26 -23
- package/lib/module/ui/context/OxyContext.js.map +1 -1
- package/lib/module/ui/hooks/index.js +1 -2
- package/lib/module/ui/hooks/index.js.map +1 -1
- package/lib/module/ui/hooks/useFollow.js +52 -137
- package/lib/module/ui/hooks/useFollow.js.map +1 -1
- package/lib/module/ui/hooks/useSessionSocket.js +47 -0
- package/lib/module/ui/hooks/useSessionSocket.js.map +1 -0
- package/lib/module/ui/index.js +2 -13
- package/lib/module/ui/index.js.map +1 -1
- package/lib/module/ui/navigation/OxyRouter.js +53 -61
- package/lib/module/ui/navigation/OxyRouter.js.map +1 -1
- package/lib/module/ui/screens/AccountCenterScreen.js +6 -18
- package/lib/module/ui/screens/AccountCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountOverviewScreen.js +5 -23
- package/lib/module/ui/screens/AccountOverviewScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSettingsScreen.js +7 -15
- package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSwitcherScreen.js +38 -67
- package/lib/module/ui/screens/AccountSwitcherScreen.js.map +1 -1
- package/lib/module/ui/screens/AppInfoScreen.js +22 -45
- package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/module/ui/screens/FeedbackScreen.js +44 -23
- package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/module/ui/screens/FileManagementScreen.js +59 -78
- package/lib/module/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentGatewayScreen.js +1583 -0
- package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -0
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js +23 -37
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/module/ui/screens/RecoverAccountScreen.js +263 -0
- package/lib/module/ui/screens/RecoverAccountScreen.js.map +1 -0
- package/lib/module/ui/screens/SessionManagementScreen.js +47 -69
- package/lib/module/ui/screens/SessionManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/SignInScreen.js +100 -334
- package/lib/module/ui/screens/SignInScreen.js.map +1 -1
- package/lib/module/ui/screens/SignUpScreen.js +137 -341
- package/lib/module/ui/screens/SignUpScreen.js.map +1 -1
- package/lib/module/ui/screens/internal/SignInPasswordStep.js +186 -0
- package/lib/module/ui/screens/internal/SignInPasswordStep.js.map +1 -0
- package/lib/module/ui/screens/internal/SignInUsernameStep.js +129 -0
- package/lib/module/ui/screens/internal/SignInUsernameStep.js.map +1 -0
- package/lib/module/ui/screens/internal/SignUpIdentityStep.js +102 -0
- package/lib/module/ui/screens/internal/SignUpIdentityStep.js.map +1 -0
- package/lib/module/ui/screens/internal/SignUpSecurityStep.js +120 -0
- package/lib/module/ui/screens/internal/SignUpSecurityStep.js.map +1 -0
- package/lib/module/ui/screens/internal/SignUpSummaryStep.js +79 -0
- package/lib/module/ui/screens/internal/SignUpSummaryStep.js.map +1 -0
- package/lib/module/ui/screens/internal/SignUpWelcomeStep.js +54 -0
- package/lib/module/ui/screens/internal/SignUpWelcomeStep.js.map +1 -0
- package/lib/module/ui/screens/karma/KarmaRewardsScreen.js +16 -3
- package/lib/module/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
- package/lib/module/ui/stores/authStore.js +27 -0
- package/lib/module/ui/stores/authStore.js.map +1 -0
- package/lib/module/ui/stores/followStore.js +120 -0
- package/lib/module/ui/stores/followStore.js.map +1 -0
- package/lib/module/ui/styles/index.js +0 -1
- package/lib/module/ui/styles/index.js.map +1 -1
- package/lib/module/ui/utils/confirmAction.js +25 -0
- package/lib/module/ui/utils/confirmAction.js.map +1 -0
- package/lib/typescript/core/index.d.ts +28 -10
- package/lib/typescript/core/index.d.ts.map +1 -1
- package/lib/typescript/index.d.ts +5 -4
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/models/secureSession.d.ts +0 -1
- package/lib/typescript/models/secureSession.d.ts.map +1 -1
- package/lib/typescript/node/index.d.ts +0 -1
- package/lib/typescript/node/index.d.ts.map +1 -1
- package/lib/typescript/ui/components/FollowButton.d.ts +1 -77
- package/lib/typescript/ui/components/FollowButton.d.ts.map +1 -1
- package/lib/typescript/ui/components/OxyPayButton.d.ts +29 -0
- package/lib/typescript/ui/components/OxyPayButton.d.ts.map +1 -0
- package/lib/typescript/ui/components/OxyProvider.d.ts.map +1 -1
- package/lib/typescript/ui/components/OxySignInButton.d.ts.map +1 -1
- package/lib/typescript/ui/components/icon/FAIRWalletIcon.d.ts +8 -0
- package/lib/typescript/ui/components/icon/FAIRWalletIcon.d.ts.map +1 -0
- package/lib/typescript/ui/components/icon/index.d.ts +1 -0
- package/lib/typescript/ui/components/icon/index.d.ts.map +1 -1
- package/lib/typescript/ui/components/index.d.ts +1 -0
- package/lib/typescript/ui/components/index.d.ts.map +1 -1
- package/lib/typescript/ui/components/internal/GroupedPillButtons.d.ts.map +1 -1
- package/lib/typescript/ui/components/internal/PinInput.d.ts +12 -0
- package/lib/typescript/ui/components/internal/PinInput.d.ts.map +1 -0
- package/lib/typescript/ui/components/internal/TextField.d.ts +1 -0
- package/lib/typescript/ui/components/internal/TextField.d.ts.map +1 -1
- package/lib/typescript/ui/context/OxyContext.d.ts +0 -1
- package/lib/typescript/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/index.d.ts +1 -2
- package/lib/typescript/ui/hooks/index.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/useFollow.d.ts +14 -15
- package/lib/typescript/ui/hooks/useFollow.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/useSessionSocket.d.ts +11 -0
- package/lib/typescript/ui/hooks/useSessionSocket.d.ts.map +1 -0
- package/lib/typescript/ui/index.d.ts +2 -5
- package/lib/typescript/ui/index.d.ts.map +1 -1
- package/lib/typescript/ui/navigation/OxyRouter.d.ts.map +1 -1
- package/lib/typescript/ui/navigation/types.d.ts +5 -23
- package/lib/typescript/ui/navigation/types.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountCenterScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountOverviewScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AccountSwitcherScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/AppInfoScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/FeedbackScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/FileManagementScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/PaymentGatewayScreen.d.ts +27 -0
- package/lib/typescript/ui/screens/PaymentGatewayScreen.d.ts.map +1 -0
- package/lib/typescript/ui/screens/PremiumSubscriptionScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts +8 -0
- package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts.map +1 -0
- package/lib/typescript/ui/screens/SessionManagementScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/SignInScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/SignUpScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/internal/SignInPasswordStep.d.ts +27 -0
- package/lib/typescript/ui/screens/internal/SignInPasswordStep.d.ts.map +1 -0
- package/lib/typescript/ui/screens/internal/SignInUsernameStep.d.ts +26 -0
- package/lib/typescript/ui/screens/internal/SignInUsernameStep.d.ts.map +1 -0
- package/lib/typescript/ui/screens/internal/SignUpIdentityStep.d.ts +20 -0
- package/lib/typescript/ui/screens/internal/SignUpIdentityStep.d.ts.map +1 -0
- package/lib/typescript/ui/screens/internal/SignUpSecurityStep.d.ts +24 -0
- package/lib/typescript/ui/screens/internal/SignUpSecurityStep.d.ts.map +1 -0
- package/lib/typescript/ui/screens/internal/SignUpSummaryStep.d.ts +15 -0
- package/lib/typescript/ui/screens/internal/SignUpSummaryStep.d.ts.map +1 -0
- package/lib/typescript/ui/screens/internal/SignUpWelcomeStep.d.ts +13 -0
- package/lib/typescript/ui/screens/internal/SignUpWelcomeStep.d.ts.map +1 -0
- package/lib/typescript/ui/screens/karma/KarmaRewardsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/stores/authStore.d.ts +14 -0
- package/lib/typescript/ui/stores/authStore.d.ts.map +1 -0
- package/lib/typescript/ui/stores/followStore.d.ts +15 -0
- package/lib/typescript/ui/stores/followStore.d.ts.map +1 -0
- package/lib/typescript/ui/styles/index.d.ts +0 -1
- package/lib/typescript/ui/styles/index.d.ts.map +1 -1
- package/lib/typescript/ui/utils/confirmAction.d.ts +7 -0
- package/lib/typescript/ui/utils/confirmAction.d.ts.map +1 -0
- package/package.json +12 -7
- package/src/core/index.ts +78 -88
- package/src/index.ts +8 -45
- package/src/models/secureSession.ts +1 -2
- package/src/node/index.ts +0 -3
- package/src/ui/components/FollowButton.tsx +100 -322
- package/src/ui/components/OxyPayButton.tsx +133 -0
- package/src/ui/components/OxyProvider.tsx +39 -201
- package/src/ui/components/OxySignInButton.tsx +13 -2
- package/src/ui/components/icon/FAIRWalletIcon.tsx +49 -0
- package/src/ui/components/icon/index.ts +1 -0
- package/src/ui/components/index.ts +1 -0
- package/src/ui/components/internal/GroupedPillButtons.tsx +12 -8
- package/src/ui/components/internal/PinInput.tsx +102 -0
- package/src/ui/components/internal/TextField.tsx +9 -0
- package/src/ui/context/OxyContext.tsx +26 -26
- package/src/ui/hooks/index.ts +1 -2
- package/src/ui/hooks/useFollow.ts +58 -129
- package/src/ui/hooks/useSessionSocket.ts +50 -0
- package/src/ui/index.ts +2 -37
- package/src/ui/navigation/OxyRouter.tsx +47 -63
- package/src/ui/navigation/types.ts +5 -26
- package/src/ui/screens/AccountCenterScreen.tsx +12 -21
- package/src/ui/screens/AccountOverviewScreen.tsx +6 -30
- package/src/ui/screens/AccountSettingsScreen.tsx +7 -22
- package/src/ui/screens/AccountSwitcherScreen.tsx +46 -88
- package/src/ui/screens/AppInfoScreen.tsx +27 -47
- package/src/ui/screens/FeedbackScreen.tsx +34 -19
- package/src/ui/screens/FileManagementScreen.tsx +293 -321
- package/src/ui/screens/PaymentGatewayScreen.tsx +1315 -0
- package/src/ui/screens/PremiumSubscriptionScreen.tsx +109 -124
- package/src/ui/screens/RecoverAccountScreen.tsx +260 -0
- package/src/ui/screens/SessionManagementScreen.tsx +65 -137
- package/src/ui/screens/SignInScreen.tsx +89 -283
- package/src/ui/screens/SignUpScreen.tsx +138 -291
- package/src/ui/screens/internal/SignInPasswordStep.tsx +179 -0
- package/src/ui/screens/internal/SignInUsernameStep.tsx +139 -0
- package/src/ui/screens/internal/SignUpIdentityStep.tsx +114 -0
- package/src/ui/screens/internal/SignUpSecurityStep.tsx +132 -0
- package/src/ui/screens/internal/SignUpSummaryStep.tsx +66 -0
- package/src/ui/screens/internal/SignUpWelcomeStep.tsx +52 -0
- package/src/ui/screens/karma/KarmaRewardsScreen.tsx +13 -3
- package/src/ui/stores/authStore.ts +24 -0
- package/src/ui/stores/followStore.ts +80 -0
- package/src/ui/styles/index.ts +0 -1
- package/src/ui/utils/confirmAction.ts +23 -0
- package/lib/commonjs/ui/components/bottomSheet/index.js +0 -37
- package/lib/commonjs/ui/components/bottomSheet/index.js.map +0 -1
- package/lib/commonjs/ui/hooks/useAuthFetch.js +0 -216
- package/lib/commonjs/ui/hooks/useAuthFetch.js.map +0 -1
- package/lib/commonjs/ui/hooks/useOxyFollow.js +0 -190
- package/lib/commonjs/ui/hooks/useOxyFollow.js.map +0 -1
- package/lib/commonjs/ui/screens/BillingManagementScreen.js +0 -636
- package/lib/commonjs/ui/screens/BillingManagementScreen.js.map +0 -1
- package/lib/commonjs/ui/store/index.js +0 -67
- package/lib/commonjs/ui/store/index.js.map +0 -1
- package/lib/commonjs/ui/store/setupOxyStore.js +0 -63
- package/lib/commonjs/ui/store/setupOxyStore.js.map +0 -1
- package/lib/commonjs/ui/store/slices/authSlice.js +0 -56
- package/lib/commonjs/ui/store/slices/authSlice.js.map +0 -1
- package/lib/commonjs/ui/store/slices/followSlice.js +0 -238
- package/lib/commonjs/ui/store/slices/followSlice.js.map +0 -1
- package/lib/commonjs/ui/store/slices/index.js +0 -129
- package/lib/commonjs/ui/store/slices/index.js.map +0 -1
- package/lib/commonjs/ui/store/slices/types.js +0 -19
- package/lib/commonjs/ui/store/slices/types.js.map +0 -1
- package/lib/commonjs/ui/styles/shadows.js +0 -123
- package/lib/commonjs/ui/styles/shadows.js.map +0 -1
- package/lib/commonjs/utils/polyfills.js +0 -42
- package/lib/commonjs/utils/polyfills.js.map +0 -1
- package/lib/module/ui/components/bottomSheet/index.js +0 -5
- package/lib/module/ui/components/bottomSheet/index.js.map +0 -1
- package/lib/module/ui/hooks/useAuthFetch.js +0 -211
- package/lib/module/ui/hooks/useAuthFetch.js.map +0 -1
- package/lib/module/ui/hooks/useOxyFollow.js +0 -186
- package/lib/module/ui/hooks/useOxyFollow.js.map +0 -1
- package/lib/module/ui/screens/BillingManagementScreen.js +0 -631
- package/lib/module/ui/screens/BillingManagementScreen.js.map +0 -1
- package/lib/module/ui/store/index.js +0 -33
- package/lib/module/ui/store/index.js.map +0 -1
- package/lib/module/ui/store/setupOxyStore.js +0 -59
- package/lib/module/ui/store/setupOxyStore.js.map +0 -1
- package/lib/module/ui/store/slices/authSlice.js +0 -48
- package/lib/module/ui/store/slices/authSlice.js.map +0 -1
- package/lib/module/ui/store/slices/followSlice.js +0 -232
- package/lib/module/ui/store/slices/followSlice.js.map +0 -1
- package/lib/module/ui/store/slices/index.js +0 -11
- package/lib/module/ui/store/slices/index.js.map +0 -1
- package/lib/module/ui/store/slices/types.js +0 -15
- package/lib/module/ui/store/slices/types.js.map +0 -1
- package/lib/module/ui/styles/shadows.js +0 -119
- package/lib/module/ui/styles/shadows.js.map +0 -1
- package/lib/module/utils/polyfills.js +0 -36
- package/lib/module/utils/polyfills.js.map +0 -1
- package/lib/typescript/types/react-redux.d.ts +0 -5
- package/lib/typescript/ui/components/bottomSheet/index.d.ts +0 -4
- package/lib/typescript/ui/components/bottomSheet/index.d.ts.map +0 -1
- package/lib/typescript/ui/hooks/useAuthFetch.d.ts +0 -34
- package/lib/typescript/ui/hooks/useAuthFetch.d.ts.map +0 -1
- package/lib/typescript/ui/hooks/useOxyFollow.d.ts +0 -81
- package/lib/typescript/ui/hooks/useOxyFollow.d.ts.map +0 -1
- package/lib/typescript/ui/screens/BillingManagementScreen.d.ts +0 -5
- package/lib/typescript/ui/screens/BillingManagementScreen.d.ts.map +0 -1
- package/lib/typescript/ui/store/index.d.ts +0 -27
- package/lib/typescript/ui/store/index.d.ts.map +0 -1
- package/lib/typescript/ui/store/setupOxyStore.d.ts +0 -29
- package/lib/typescript/ui/store/setupOxyStore.d.ts.map +0 -1
- package/lib/typescript/ui/store/slices/authSlice.d.ts +0 -32
- package/lib/typescript/ui/store/slices/authSlice.d.ts.map +0 -1
- package/lib/typescript/ui/store/slices/followSlice.d.ts +0 -120
- package/lib/typescript/ui/store/slices/followSlice.d.ts.map +0 -1
- package/lib/typescript/ui/store/slices/index.d.ts +0 -9
- package/lib/typescript/ui/store/slices/index.d.ts.map +0 -1
- package/lib/typescript/ui/store/slices/types.d.ts +0 -16
- package/lib/typescript/ui/store/slices/types.d.ts.map +0 -1
- package/lib/typescript/ui/styles/shadows.d.ts +0 -233
- package/lib/typescript/ui/styles/shadows.d.ts.map +0 -1
- package/lib/typescript/utils/polyfills.d.ts +0 -6
- package/lib/typescript/utils/polyfills.d.ts.map +0 -1
- package/src/__tests__/backend-middleware.test.ts +0 -209
- package/src/__tests__/polyfills.test.ts +0 -30
- package/src/__tests__/setup.ts +0 -43
- package/src/__tests__/ui/hooks/useAuthFetch.test.ts +0 -70
- package/src/__tests__/ui/hooks/useOxyFollow.test.tsx +0 -92
- package/src/__tests__/ui/screens/AccountSettingsScreen.test.tsx +0 -112
- package/src/__tests__/ui/store/setupOxyStore.test.ts +0 -50
- package/src/__tests__/validate-structure.js +0 -91
- package/src/__tests__/validation.js +0 -42
- package/src/types/react-redux.d.ts +0 -5
- package/src/ui/components/bottomSheet/index.tsx +0 -14
- package/src/ui/hooks/useAuthFetch.ts +0 -238
- package/src/ui/hooks/useOxyFollow.ts +0 -188
- package/src/ui/screens/BillingManagementScreen.tsx +0 -589
- package/src/ui/store/index.ts +0 -36
- package/src/ui/store/setupOxyStore.ts +0 -58
- package/src/ui/store/slices/authSlice.ts +0 -43
- package/src/ui/store/slices/followSlice.ts +0 -207
- package/src/ui/store/slices/index.ts +0 -31
- package/src/ui/store/slices/types.ts +0 -33
- package/src/ui/styles/shadows.ts +0 -112
- package/src/utils/polyfills.ts +0 -34
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
var _exportNames = {
|
|
7
|
-
store: true,
|
|
8
|
-
selectIsUserBeingFetched: true,
|
|
9
|
-
setupOxyStore: true,
|
|
10
|
-
oxyReducers: true
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "oxyReducers", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function () {
|
|
15
|
-
return _setupOxyStore.oxyReducers;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
|
-
exports.selectIsUserBeingFetched = void 0;
|
|
19
|
-
Object.defineProperty(exports, "setupOxyStore", {
|
|
20
|
-
enumerable: true,
|
|
21
|
-
get: function () {
|
|
22
|
-
return _setupOxyStore.setupOxyStore;
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
|
-
exports.store = void 0;
|
|
26
|
-
var _slices = require("./slices");
|
|
27
|
-
Object.keys(_slices).forEach(function (key) {
|
|
28
|
-
if (key === "default" || key === "__esModule") return;
|
|
29
|
-
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
30
|
-
if (key in exports && exports[key] === _slices[key]) return;
|
|
31
|
-
Object.defineProperty(exports, key, {
|
|
32
|
-
enumerable: true,
|
|
33
|
-
get: function () {
|
|
34
|
-
return _slices[key];
|
|
35
|
-
}
|
|
36
|
-
});
|
|
37
|
-
});
|
|
38
|
-
var _setupOxyStore = require("./setupOxyStore");
|
|
39
|
-
var _toolkit = require("@reduxjs/toolkit");
|
|
40
|
-
/**
|
|
41
|
-
* OxyHQ Services Redux Store
|
|
42
|
-
* Framework-agnostic, tree-shakable Redux integration
|
|
43
|
-
*
|
|
44
|
-
* This module exports individual slices, reducers, actions, selectors, and helpers
|
|
45
|
-
* for easy integration into any Redux store without internal dependencies.
|
|
46
|
-
*/
|
|
47
|
-
|
|
48
|
-
// Export individual slices and their components
|
|
49
|
-
|
|
50
|
-
// Export setup helper for easy integration
|
|
51
|
-
|
|
52
|
-
// Export types for external store integration
|
|
53
|
-
|
|
54
|
-
// For backward compatibility: create a legacy store instance
|
|
55
|
-
// This will be deprecated in favor of setupOxyStore()
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* @deprecated Use setupOxyStore() instead to integrate with your app's store
|
|
59
|
-
* This internal store will be removed in a future version
|
|
60
|
-
*/
|
|
61
|
-
const store = exports.store = (0, _toolkit.configureStore)({
|
|
62
|
-
reducer: (0, _setupOxyStore.setupOxyStore)()
|
|
63
|
-
});
|
|
64
|
-
// Legacy selector (deprecated)
|
|
65
|
-
const selectIsUserBeingFetched = (state, userId) => state.follow.fetchingUsers[userId] ?? false;
|
|
66
|
-
exports.selectIsUserBeingFetched = selectIsUserBeingFetched;
|
|
67
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_slices","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_setupOxyStore","_toolkit","store","configureStore","reducer","setupOxyStore","selectIsUserBeingFetched","state","userId","follow","fetchingUsers"],"sourceRoot":"../../../../src","sources":["ui/store/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AASA,IAAAA,OAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,OAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAL,OAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAb,OAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AAGA,IAAAS,cAAA,GAAAb,OAAA;AAOA,IAAAc,QAAA,GAAAd,OAAA;AAnBA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAGA;;AAGA;;AAGA;AACA;;AAIA;AACA;AACA;AACA;AACO,MAAMe,KAAK,GAAAN,OAAA,CAAAM,KAAA,GAAG,IAAAC,uBAAc,EAAC;EAClCC,OAAO,EAAE,IAAAC,4BAAa,EAAC;AACzB,CAAC,CAAC;AAKF;AACO,MAAMC,wBAAwB,GAAGA,CAACC,KAAgB,EAAEC,MAAc,KACvED,KAAK,CAACE,MAAM,CAACC,aAAa,CAACF,MAAM,CAAC,IAAI,KAAK;AAACZ,OAAA,CAAAU,wBAAA,GAAAA,wBAAA","ignoreList":[]}
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.oxyReducers = void 0;
|
|
7
|
-
exports.setupOxyStore = setupOxyStore;
|
|
8
|
-
var _authSlice = require("./slices/authSlice");
|
|
9
|
-
var _followSlice = require("./slices/followSlice");
|
|
10
|
-
/**
|
|
11
|
-
* Setup helper for Oxy Store
|
|
12
|
-
* Returns all Oxy reducers ready to be spread into a host app's Redux store
|
|
13
|
-
*
|
|
14
|
-
* Usage:
|
|
15
|
-
* ```ts
|
|
16
|
-
* const store = configureStore({
|
|
17
|
-
* reducer: {
|
|
18
|
-
* ...setupOxyStore(),
|
|
19
|
-
* appSpecificReducer,
|
|
20
|
-
* },
|
|
21
|
-
* });
|
|
22
|
-
* ```
|
|
23
|
-
*/
|
|
24
|
-
function setupOxyStore() {
|
|
25
|
-
return {
|
|
26
|
-
auth: _authSlice.authReducer,
|
|
27
|
-
follow: _followSlice.followReducer
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* Tree-shakable version where you can pick specific reducers
|
|
33
|
-
*
|
|
34
|
-
* Usage:
|
|
35
|
-
* ```ts
|
|
36
|
-
* const store = configureStore({
|
|
37
|
-
* reducer: {
|
|
38
|
-
* ...setupOxyStore.pick('auth'), // Only include auth
|
|
39
|
-
* // or
|
|
40
|
-
* ...setupOxyStore.pick('auth', 'follow'), // Include both
|
|
41
|
-
* appSpecificReducer,
|
|
42
|
-
* },
|
|
43
|
-
* });
|
|
44
|
-
* ```
|
|
45
|
-
*/
|
|
46
|
-
setupOxyStore.pick = function (...keys) {
|
|
47
|
-
const allReducers = setupOxyStore();
|
|
48
|
-
const pickedReducers = {};
|
|
49
|
-
for (const key of keys) {
|
|
50
|
-
if (key in allReducers) {
|
|
51
|
-
// Use bracket notation with explicit typing
|
|
52
|
-
pickedReducers[key] = allReducers[key];
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
return pickedReducers;
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
// Export individual reducers for maximum flexibility
|
|
59
|
-
const oxyReducers = exports.oxyReducers = {
|
|
60
|
-
auth: _authSlice.authReducer,
|
|
61
|
-
follow: _followSlice.followReducer
|
|
62
|
-
};
|
|
63
|
-
//# sourceMappingURL=setupOxyStore.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_authSlice","require","_followSlice","setupOxyStore","auth","authReducer","follow","followReducer","pick","keys","allReducers","pickedReducers","key","oxyReducers","exports"],"sourceRoot":"../../../../src","sources":["ui/store/setupOxyStore.ts"],"mappings":";;;;;;;AAAA,IAAAA,UAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAASE,aAAaA,CAAA,EAAG;EAC9B,OAAO;IACLC,IAAI,EAAEC,sBAAW;IACjBC,MAAM,EAAEC;EACV,CAAC;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACAJ,aAAa,CAACK,IAAI,GAAG,UAAS,GAAGC,IAA8B,EAAE;EAC/D,MAAMC,WAAW,GAAGP,aAAa,CAAC,CAAC;EACnC,MAAMQ,cAAc,GAAG,CAAC,CAA8C;EAEtE,KAAK,MAAMC,GAAG,IAAIH,IAAI,EAAE;IACtB,IAAIG,GAAG,IAAIF,WAAW,EAAE;MACtB;MACCC,cAAc,CAAyBC,GAAG,CAAC,GAAGF,WAAW,CAACE,GAAG,CAAC;IACjE;EACF;EAEA,OAAOD,cAAc;AACvB,CAAC;;AAED;AACO,MAAME,WAAW,GAAAC,OAAA,CAAAD,WAAA,GAAG;EACzBT,IAAI,EAAEC,sBAAW;EACjBC,MAAM,EAAEC;AACV,CAAC","ignoreList":[]}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.logout = exports.loginSuccess = exports.loginStart = exports.loginFailure = exports.authSlice = exports.authSelectors = exports.authReducer = exports.authActions = void 0;
|
|
7
|
-
var _toolkit = require("@reduxjs/toolkit");
|
|
8
|
-
var _types = require("./types");
|
|
9
|
-
const authSlice = exports.authSlice = (0, _toolkit.createSlice)({
|
|
10
|
-
name: 'auth',
|
|
11
|
-
initialState: _types.initialAuthState,
|
|
12
|
-
reducers: {
|
|
13
|
-
loginStart(state) {
|
|
14
|
-
state.isLoading = true;
|
|
15
|
-
state.error = null;
|
|
16
|
-
},
|
|
17
|
-
loginSuccess(state, action) {
|
|
18
|
-
state.isLoading = false;
|
|
19
|
-
state.isAuthenticated = true;
|
|
20
|
-
state.user = action.payload;
|
|
21
|
-
},
|
|
22
|
-
loginFailure(state, action) {
|
|
23
|
-
state.isLoading = false;
|
|
24
|
-
state.error = action.payload;
|
|
25
|
-
},
|
|
26
|
-
logout(state) {
|
|
27
|
-
state.user = null;
|
|
28
|
-
state.isAuthenticated = false;
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
// Export actions
|
|
34
|
-
const authActions = exports.authActions = authSlice.actions;
|
|
35
|
-
const {
|
|
36
|
-
loginStart,
|
|
37
|
-
loginSuccess,
|
|
38
|
-
loginFailure,
|
|
39
|
-
logout
|
|
40
|
-
} = authSlice.actions;
|
|
41
|
-
|
|
42
|
-
// Export selectors
|
|
43
|
-
exports.logout = logout;
|
|
44
|
-
exports.loginFailure = loginFailure;
|
|
45
|
-
exports.loginSuccess = loginSuccess;
|
|
46
|
-
exports.loginStart = loginStart;
|
|
47
|
-
const authSelectors = exports.authSelectors = {
|
|
48
|
-
selectUser: state => state.auth.user,
|
|
49
|
-
selectIsAuthenticated: state => state.auth.isAuthenticated,
|
|
50
|
-
selectIsLoading: state => state.auth.isLoading,
|
|
51
|
-
selectError: state => state.auth.error
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
// Export reducer
|
|
55
|
-
const authReducer = exports.authReducer = authSlice.reducer;
|
|
56
|
-
//# sourceMappingURL=authSlice.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_toolkit","require","_types","authSlice","exports","createSlice","name","initialState","initialAuthState","reducers","loginStart","state","isLoading","error","loginSuccess","action","isAuthenticated","user","payload","loginFailure","logout","authActions","actions","authSelectors","selectUser","auth","selectIsAuthenticated","selectIsLoading","selectError","authReducer","reducer"],"sourceRoot":"../../../../../src","sources":["ui/store/slices/authSlice.ts"],"mappings":";;;;;;AAAA,IAAAA,QAAA,GAAAC,OAAA;AAGA,IAAAC,MAAA,GAAAD,OAAA;AAEO,MAAME,SAAS,GAAAC,OAAA,CAAAD,SAAA,GAAG,IAAAE,oBAAW,EAAC;EACnCC,IAAI,EAAE,MAAM;EACZC,YAAY,EAAEC,uBAAgB;EAC9BC,QAAQ,EAAE;IACRC,UAAUA,CAACC,KAAgB,EAAE;MAC3BA,KAAK,CAACC,SAAS,GAAG,IAAI;MACtBD,KAAK,CAACE,KAAK,GAAG,IAAI;IACpB,CAAC;IACDC,YAAYA,CAACH,KAAgB,EAAEI,MAA2B,EAAE;MAC1DJ,KAAK,CAACC,SAAS,GAAG,KAAK;MACvBD,KAAK,CAACK,eAAe,GAAG,IAAI;MAC5BL,KAAK,CAACM,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
|
|
6
|
-
exports.toggleFollowUser = exports.setFollowingStatus = exports.resetFollowState = exports.followThunks = exports.followSlice = exports.followSelectors = exports.followReducer = exports.followActions = exports.fetchFollowStatus = exports.clearFollowError = void 0;
|
|
7
|
-
var _toolkit = require("@reduxjs/toolkit");
|
|
8
|
-
var _types = require("./types");
|
|
9
|
-
// Define thunk state interface for dependency injection
|
|
10
|
-
|
|
11
|
-
// Async thunk for fetching follow status from backend with deduplication
|
|
12
|
-
const fetchFollowStatus = exports.fetchFollowStatus = (0, _toolkit.createAsyncThunk)('follow/fetchFollowStatus', async ({
|
|
13
|
-
userId,
|
|
14
|
-
oxyServices
|
|
15
|
-
}, {
|
|
16
|
-
rejectWithValue
|
|
17
|
-
}) => {
|
|
18
|
-
try {
|
|
19
|
-
// Use the proper core service method
|
|
20
|
-
const response = await oxyServices.getFollowStatus(userId);
|
|
21
|
-
return {
|
|
22
|
-
userId,
|
|
23
|
-
isFollowing: response.isFollowing
|
|
24
|
-
};
|
|
25
|
-
} catch (error) {
|
|
26
|
-
// Ignore authentication errors when user isn't signed in - don't update state
|
|
27
|
-
if (error?.status === 401 || error?.message?.includes('Authentication')) {
|
|
28
|
-
return rejectWithValue('Not authenticated');
|
|
29
|
-
}
|
|
30
|
-
// Log other failures and reject to not update state
|
|
31
|
-
console.warn(`Failed to fetch follow status for user ${userId}:`, error);
|
|
32
|
-
return rejectWithValue(error?.message || 'Failed to fetch follow status');
|
|
33
|
-
}
|
|
34
|
-
}, {
|
|
35
|
-
// Prevent duplicate requests for the same user ID
|
|
36
|
-
condition: ({
|
|
37
|
-
userId
|
|
38
|
-
}, {
|
|
39
|
-
getState
|
|
40
|
-
}) => {
|
|
41
|
-
const state = getState();
|
|
42
|
-
const isAlreadyFetching = state.follow.fetchingUsers[userId];
|
|
43
|
-
if (isAlreadyFetching) {
|
|
44
|
-
console.log(`⚡ Deduplicating fetch request for user ${userId} - already in progress`);
|
|
45
|
-
return false; // Cancel this request
|
|
46
|
-
}
|
|
47
|
-
return true; // Allow this request
|
|
48
|
-
}
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
// Async thunk for following/unfollowing users using core services
|
|
52
|
-
const toggleFollowUser = exports.toggleFollowUser = (0, _toolkit.createAsyncThunk)('follow/toggleFollowUser', async ({
|
|
53
|
-
userId,
|
|
54
|
-
oxyServices,
|
|
55
|
-
isCurrentlyFollowing
|
|
56
|
-
}, {
|
|
57
|
-
rejectWithValue,
|
|
58
|
-
dispatch
|
|
59
|
-
}) => {
|
|
60
|
-
try {
|
|
61
|
-
let response;
|
|
62
|
-
let newFollowState;
|
|
63
|
-
if (isCurrentlyFollowing) {
|
|
64
|
-
// Use the core service to unfollow user
|
|
65
|
-
response = await oxyServices.unfollowUser(userId);
|
|
66
|
-
newFollowState = false;
|
|
67
|
-
} else {
|
|
68
|
-
// Use the core service to follow user
|
|
69
|
-
response = await oxyServices.followUser(userId);
|
|
70
|
-
newFollowState = true;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
// Check if the response indicates success (different APIs might return different formats)
|
|
74
|
-
const isSuccess = response.success !== false && response.action !== 'error';
|
|
75
|
-
if (isSuccess) {
|
|
76
|
-
return {
|
|
77
|
-
userId,
|
|
78
|
-
isFollowing: newFollowState,
|
|
79
|
-
message: response.message || `Successfully ${newFollowState ? 'followed' : 'unfollowed'} user`
|
|
80
|
-
};
|
|
81
|
-
} else {
|
|
82
|
-
return rejectWithValue(response.message || `Failed to ${newFollowState ? 'follow' : 'unfollow'} user`);
|
|
83
|
-
}
|
|
84
|
-
} catch (error) {
|
|
85
|
-
// Enhanced error handling with state mismatch detection
|
|
86
|
-
let errorMessage = 'Network error occurred';
|
|
87
|
-
if (error?.message) {
|
|
88
|
-
errorMessage = error.message;
|
|
89
|
-
} else if (error?.response?.data?.message) {
|
|
90
|
-
errorMessage = error.response.data.message;
|
|
91
|
-
} else if (error?.data?.message) {
|
|
92
|
-
errorMessage = error.data.message;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
// Handle state mismatch errors by syncing with backend
|
|
96
|
-
if (errorMessage.includes('Not following this user') && isCurrentlyFollowing) {
|
|
97
|
-
console.warn(`State mismatch detected for user ${userId}: Frontend thinks following, backend says not following. Syncing state...`);
|
|
98
|
-
// Auto-sync with backend state
|
|
99
|
-
try {
|
|
100
|
-
const actualStatus = await oxyServices.getFollowStatus(userId);
|
|
101
|
-
dispatch({
|
|
102
|
-
type: 'follow/setFollowingStatus',
|
|
103
|
-
payload: {
|
|
104
|
-
userId,
|
|
105
|
-
isFollowing: actualStatus.isFollowing
|
|
106
|
-
}
|
|
107
|
-
});
|
|
108
|
-
return rejectWithValue('State synced with backend. Please try again.');
|
|
109
|
-
} catch (syncError) {
|
|
110
|
-
console.error('Failed to sync state with backend:', syncError);
|
|
111
|
-
}
|
|
112
|
-
} else if (errorMessage.includes('Already following this user') && !isCurrentlyFollowing) {
|
|
113
|
-
console.warn(`State mismatch detected for user ${userId}: Frontend thinks not following, backend says following. Syncing state...`);
|
|
114
|
-
// Auto-sync with backend state
|
|
115
|
-
try {
|
|
116
|
-
const actualStatus = await oxyServices.getFollowStatus(userId);
|
|
117
|
-
dispatch({
|
|
118
|
-
type: 'follow/setFollowingStatus',
|
|
119
|
-
payload: {
|
|
120
|
-
userId,
|
|
121
|
-
isFollowing: actualStatus.isFollowing
|
|
122
|
-
}
|
|
123
|
-
});
|
|
124
|
-
return rejectWithValue('State synced with backend. Please try again.');
|
|
125
|
-
} catch (syncError) {
|
|
126
|
-
console.error('Failed to sync state with backend:', syncError);
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
return rejectWithValue(errorMessage);
|
|
130
|
-
}
|
|
131
|
-
});
|
|
132
|
-
const followSlice = exports.followSlice = (0, _toolkit.createSlice)({
|
|
133
|
-
name: 'follow',
|
|
134
|
-
initialState: _types.initialFollowState,
|
|
135
|
-
reducers: {
|
|
136
|
-
setFollowingStatus(state, action) {
|
|
137
|
-
const {
|
|
138
|
-
userId,
|
|
139
|
-
isFollowing
|
|
140
|
-
} = action.payload;
|
|
141
|
-
state.followingUsers[userId] = isFollowing;
|
|
142
|
-
state.errors[userId] = null;
|
|
143
|
-
},
|
|
144
|
-
clearFollowError(state, action) {
|
|
145
|
-
const userId = action.payload;
|
|
146
|
-
state.errors[userId] = null;
|
|
147
|
-
},
|
|
148
|
-
resetFollowState(state) {
|
|
149
|
-
state.followingUsers = {};
|
|
150
|
-
state.loadingUsers = {};
|
|
151
|
-
state.fetchingUsers = {};
|
|
152
|
-
state.errors = {};
|
|
153
|
-
}
|
|
154
|
-
},
|
|
155
|
-
extraReducers: builder => {
|
|
156
|
-
builder
|
|
157
|
-
// Handle fetchFollowStatus
|
|
158
|
-
.addCase(fetchFollowStatus.pending, (state, action) => {
|
|
159
|
-
const {
|
|
160
|
-
userId
|
|
161
|
-
} = action.meta.arg;
|
|
162
|
-
state.fetchingUsers[userId] = true;
|
|
163
|
-
state.errors[userId] = null;
|
|
164
|
-
}).addCase(fetchFollowStatus.fulfilled, (state, action) => {
|
|
165
|
-
const {
|
|
166
|
-
userId,
|
|
167
|
-
isFollowing
|
|
168
|
-
} = action.payload;
|
|
169
|
-
state.followingUsers[userId] = isFollowing;
|
|
170
|
-
state.fetchingUsers[userId] = false;
|
|
171
|
-
state.errors[userId] = null;
|
|
172
|
-
}).addCase(fetchFollowStatus.rejected, (state, action) => {
|
|
173
|
-
const {
|
|
174
|
-
userId
|
|
175
|
-
} = action.meta.arg;
|
|
176
|
-
state.fetchingUsers[userId] = false;
|
|
177
|
-
// Don't update follow state on fetch errors - preserve existing/initial state
|
|
178
|
-
if (action.payload !== 'Not authenticated') {
|
|
179
|
-
console.warn(`Failed to fetch follow status for user ${userId}:`, action.payload);
|
|
180
|
-
}
|
|
181
|
-
})
|
|
182
|
-
// Handle toggleFollowUser
|
|
183
|
-
.addCase(toggleFollowUser.pending, (state, action) => {
|
|
184
|
-
const {
|
|
185
|
-
userId
|
|
186
|
-
} = action.meta.arg;
|
|
187
|
-
state.loadingUsers[userId] = true;
|
|
188
|
-
state.errors[userId] = null;
|
|
189
|
-
}).addCase(toggleFollowUser.fulfilled, (state, action) => {
|
|
190
|
-
const {
|
|
191
|
-
userId,
|
|
192
|
-
isFollowing
|
|
193
|
-
} = action.payload;
|
|
194
|
-
state.followingUsers[userId] = isFollowing;
|
|
195
|
-
state.loadingUsers[userId] = false;
|
|
196
|
-
state.errors[userId] = null;
|
|
197
|
-
}).addCase(toggleFollowUser.rejected, (state, action) => {
|
|
198
|
-
const {
|
|
199
|
-
userId
|
|
200
|
-
} = action.meta.arg;
|
|
201
|
-
state.loadingUsers[userId] = false;
|
|
202
|
-
state.errors[userId] = action.error.message || 'Failed to update follow status';
|
|
203
|
-
});
|
|
204
|
-
}
|
|
205
|
-
});
|
|
206
|
-
|
|
207
|
-
// Export actions
|
|
208
|
-
const followActions = exports.followActions = followSlice.actions;
|
|
209
|
-
const {
|
|
210
|
-
setFollowingStatus,
|
|
211
|
-
clearFollowError,
|
|
212
|
-
resetFollowState
|
|
213
|
-
} = followSlice.actions;
|
|
214
|
-
|
|
215
|
-
// Export thunks
|
|
216
|
-
exports.resetFollowState = resetFollowState;
|
|
217
|
-
exports.clearFollowError = clearFollowError;
|
|
218
|
-
exports.setFollowingStatus = setFollowingStatus;
|
|
219
|
-
const followThunks = exports.followThunks = {
|
|
220
|
-
fetchFollowStatus,
|
|
221
|
-
toggleFollowUser
|
|
222
|
-
};
|
|
223
|
-
|
|
224
|
-
// Export selectors
|
|
225
|
-
const followSelectors = exports.followSelectors = {
|
|
226
|
-
selectFollowingUsers: state => state.follow.followingUsers,
|
|
227
|
-
selectLoadingUsers: state => state.follow.loadingUsers,
|
|
228
|
-
selectFetchingUsers: state => state.follow.fetchingUsers,
|
|
229
|
-
selectFollowErrors: state => state.follow.errors,
|
|
230
|
-
selectIsUserFollowed: (state, userId) => state.follow.followingUsers[userId] ?? false,
|
|
231
|
-
selectIsUserLoading: (state, userId) => state.follow.loadingUsers[userId] ?? false,
|
|
232
|
-
selectIsUserBeingFetched: (state, userId) => state.follow.fetchingUsers[userId] ?? false,
|
|
233
|
-
selectUserError: (state, userId) => state.follow.errors[userId] ?? null
|
|
234
|
-
};
|
|
235
|
-
|
|
236
|
-
// Export reducer
|
|
237
|
-
const followReducer = exports.followReducer = followSlice.reducer;
|
|
238
|
-
//# sourceMappingURL=followSlice.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_toolkit","require","_types","fetchFollowStatus","exports","createAsyncThunk","userId","oxyServices","rejectWithValue","response","getFollowStatus","isFollowing","error","status","message","includes","console","warn","condition","getState","state","isAlreadyFetching","follow","fetchingUsers","log","toggleFollowUser","isCurrentlyFollowing","dispatch","newFollowState","unfollowUser","followUser","isSuccess","success","action","errorMessage","data","actualStatus","type","payload","syncError","followSlice","createSlice","name","initialState","initialFollowState","reducers","setFollowingStatus","followingUsers","errors","clearFollowError","resetFollowState","loadingUsers","extraReducers","builder","addCase","pending","meta","arg","fulfilled","rejected","followActions","actions","followThunks","followSelectors","selectFollowingUsers","selectLoadingUsers","selectFetchingUsers","selectFollowErrors","selectIsUserFollowed","selectIsUserLoading","selectIsUserBeingFetched","selectUserError","followReducer","reducer"],"sourceRoot":"../../../../../src","sources":["ui/store/slices/followSlice.ts"],"mappings":";;;;;;AAAA,IAAAA,QAAA,GAAAC,OAAA;AAEA,IAAAC,MAAA,GAAAD,OAAA;AAEA;;AAKA;AACO,MAAME,iBAAiB,GAAAC,OAAA,CAAAD,iBAAA,GAAG,IAAAE,yBAAgB,EAC/C,0BAA0B,EAC1B,OAAO;EAAEC,MAAM;EAAEC;AAAkD,CAAC,EAAE;EAAEC;AAAgB,CAAC,KAAK;EAC5F,IAAI;IACF;IACA,MAAMC,QAAQ,GAAG,MAAMF,WAAW,CAACG,eAAe,CAACJ,MAAM,CAAC;IAC1D,OAAO;MAAEA,MAAM;MAAEK,WAAW,EAAEF,QAAQ,CAACE;IAAY,CAAC;EACtD,CAAC,CAAC,OAAOC,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AA,CAAAoE,aAAA,GAAGhC,WAAW,CAACiC,OAAO","ignoreList":[]}
|
|
@@ -1,129 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
Object.defineProperty(exports, "authActions", {
|
|
7
|
-
enumerable: true,
|
|
8
|
-
get: function () {
|
|
9
|
-
return _authSlice.authActions;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
Object.defineProperty(exports, "authReducer", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function () {
|
|
15
|
-
return _authSlice.authReducer;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
|
-
Object.defineProperty(exports, "authSelectors", {
|
|
19
|
-
enumerable: true,
|
|
20
|
-
get: function () {
|
|
21
|
-
return _authSlice.authSelectors;
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
|
-
Object.defineProperty(exports, "authSlice", {
|
|
25
|
-
enumerable: true,
|
|
26
|
-
get: function () {
|
|
27
|
-
return _authSlice.authSlice;
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
Object.defineProperty(exports, "clearFollowError", {
|
|
31
|
-
enumerable: true,
|
|
32
|
-
get: function () {
|
|
33
|
-
return _followSlice.clearFollowError;
|
|
34
|
-
}
|
|
35
|
-
});
|
|
36
|
-
Object.defineProperty(exports, "fetchFollowStatus", {
|
|
37
|
-
enumerable: true,
|
|
38
|
-
get: function () {
|
|
39
|
-
return _followSlice.fetchFollowStatus;
|
|
40
|
-
}
|
|
41
|
-
});
|
|
42
|
-
Object.defineProperty(exports, "followActions", {
|
|
43
|
-
enumerable: true,
|
|
44
|
-
get: function () {
|
|
45
|
-
return _followSlice.followActions;
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
Object.defineProperty(exports, "followReducer", {
|
|
49
|
-
enumerable: true,
|
|
50
|
-
get: function () {
|
|
51
|
-
return _followSlice.followReducer;
|
|
52
|
-
}
|
|
53
|
-
});
|
|
54
|
-
Object.defineProperty(exports, "followSelectors", {
|
|
55
|
-
enumerable: true,
|
|
56
|
-
get: function () {
|
|
57
|
-
return _followSlice.followSelectors;
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
|
-
Object.defineProperty(exports, "followSlice", {
|
|
61
|
-
enumerable: true,
|
|
62
|
-
get: function () {
|
|
63
|
-
return _followSlice.followSlice;
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
Object.defineProperty(exports, "followThunks", {
|
|
67
|
-
enumerable: true,
|
|
68
|
-
get: function () {
|
|
69
|
-
return _followSlice.followThunks;
|
|
70
|
-
}
|
|
71
|
-
});
|
|
72
|
-
Object.defineProperty(exports, "initialAuthState", {
|
|
73
|
-
enumerable: true,
|
|
74
|
-
get: function () {
|
|
75
|
-
return _types.initialAuthState;
|
|
76
|
-
}
|
|
77
|
-
});
|
|
78
|
-
Object.defineProperty(exports, "initialFollowState", {
|
|
79
|
-
enumerable: true,
|
|
80
|
-
get: function () {
|
|
81
|
-
return _types.initialFollowState;
|
|
82
|
-
}
|
|
83
|
-
});
|
|
84
|
-
Object.defineProperty(exports, "loginFailure", {
|
|
85
|
-
enumerable: true,
|
|
86
|
-
get: function () {
|
|
87
|
-
return _authSlice.loginFailure;
|
|
88
|
-
}
|
|
89
|
-
});
|
|
90
|
-
Object.defineProperty(exports, "loginStart", {
|
|
91
|
-
enumerable: true,
|
|
92
|
-
get: function () {
|
|
93
|
-
return _authSlice.loginStart;
|
|
94
|
-
}
|
|
95
|
-
});
|
|
96
|
-
Object.defineProperty(exports, "loginSuccess", {
|
|
97
|
-
enumerable: true,
|
|
98
|
-
get: function () {
|
|
99
|
-
return _authSlice.loginSuccess;
|
|
100
|
-
}
|
|
101
|
-
});
|
|
102
|
-
Object.defineProperty(exports, "logout", {
|
|
103
|
-
enumerable: true,
|
|
104
|
-
get: function () {
|
|
105
|
-
return _authSlice.logout;
|
|
106
|
-
}
|
|
107
|
-
});
|
|
108
|
-
Object.defineProperty(exports, "resetFollowState", {
|
|
109
|
-
enumerable: true,
|
|
110
|
-
get: function () {
|
|
111
|
-
return _followSlice.resetFollowState;
|
|
112
|
-
}
|
|
113
|
-
});
|
|
114
|
-
Object.defineProperty(exports, "setFollowingStatus", {
|
|
115
|
-
enumerable: true,
|
|
116
|
-
get: function () {
|
|
117
|
-
return _followSlice.setFollowingStatus;
|
|
118
|
-
}
|
|
119
|
-
});
|
|
120
|
-
Object.defineProperty(exports, "toggleFollowUser", {
|
|
121
|
-
enumerable: true,
|
|
122
|
-
get: function () {
|
|
123
|
-
return _followSlice.toggleFollowUser;
|
|
124
|
-
}
|
|
125
|
-
});
|
|
126
|
-
var _authSlice = require("./authSlice");
|
|
127
|
-
var _followSlice = require("./followSlice");
|
|
128
|
-
var _types = require("./types");
|
|
129
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_authSlice","require","_followSlice","_types"],"sourceRoot":"../../../../../src","sources":["ui/store/slices/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,IAAAA,UAAA,GAAAC,OAAA;AAWA,IAAAC,YAAA,GAAAD,OAAA;AAcA,IAAAE,MAAA,GAAAF,OAAA","ignoreList":[]}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.initialFollowState = exports.initialAuthState = void 0;
|
|
7
|
-
const initialAuthState = exports.initialAuthState = {
|
|
8
|
-
user: null,
|
|
9
|
-
isAuthenticated: false,
|
|
10
|
-
isLoading: false,
|
|
11
|
-
error: null
|
|
12
|
-
};
|
|
13
|
-
const initialFollowState = exports.initialFollowState = {
|
|
14
|
-
followingUsers: {},
|
|
15
|
-
loadingUsers: {},
|
|
16
|
-
fetchingUsers: {},
|
|
17
|
-
errors: {}
|
|
18
|
-
};
|
|
19
|
-
//# sourceMappingURL=types.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["initialAuthState","exports","user","isAuthenticated","isLoading","error","initialFollowState","followingUsers","loadingUsers","fetchingUsers","errors"],"sourceRoot":"../../../../../src","sources":["ui/store/slices/types.ts"],"mappings":";;;;;;AAoBO,MAAMA,gBAA2B,GAAAC,OAAA,CAAAD,gBAAA,GAAG;EACzCE,IAAI,EAAE,IAAI;EACVC,eAAe,EAAE,KAAK;EACtBC,SAAS,EAAE,KAAK;EAChBC,KAAK,EAAE;AACT,CAAC;AAEM,MAAMC,kBAA+B,GAAAL,OAAA,CAAAK,kBAAA,GAAG;EAC7CC,cAAc,EAAE,CAAC,CAAC;EAClBC,YAAY,EAAE,CAAC,CAAC;EAChBC,aAAa,EAAE,CAAC,CAAC;EACjBC,MAAM,EAAE,CAAC;AACX,CAAC","ignoreList":[]}
|