@oxyhq/services 5.7.5 → 5.8.2
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 +76 -76
- package/lib/commonjs/core/index.js +177 -102
- package/lib/commonjs/core/index.js.map +1 -1
- package/lib/commonjs/index.js +69 -28
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/ui/components/Avatar.js +15 -6
- package/lib/commonjs/ui/components/Avatar.js.map +1 -1
- package/lib/commonjs/ui/components/FollowButton.js +100 -12
- package/lib/commonjs/ui/components/FollowButton.js.map +1 -1
- package/lib/commonjs/ui/components/GroupedItem.js +58 -13
- package/lib/commonjs/ui/components/GroupedItem.js.map +1 -1
- package/lib/commonjs/ui/components/GroupedSection.js +7 -1
- package/lib/commonjs/ui/components/GroupedSection.js.map +1 -1
- package/lib/commonjs/ui/components/Header.js +356 -0
- package/lib/commonjs/ui/components/Header.js.map +1 -0
- package/lib/commonjs/ui/components/OxyProvider.js +28 -7
- package/lib/commonjs/ui/components/OxyProvider.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 +1 -1
- package/lib/commonjs/ui/components/internal/GroupedPillButtons.js.map +1 -1
- package/lib/commonjs/ui/components/internal/TextField.js +606 -546
- package/lib/commonjs/ui/components/internal/TextField.js.map +1 -1
- package/lib/commonjs/ui/components/internal/TextField.md +436 -0
- package/lib/commonjs/ui/context/OxyContext.js +181 -199
- package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
- package/lib/commonjs/ui/hooks/index.js +6 -0
- package/lib/commonjs/ui/hooks/index.js.map +1 -1
- package/lib/commonjs/ui/hooks/useFollow.js +59 -2
- package/lib/commonjs/ui/hooks/useFollow.js.map +1 -1
- package/lib/commonjs/ui/hooks/useSessionSocket.js +5 -2
- package/lib/commonjs/ui/hooks/useSessionSocket.js.map +1 -1
- package/lib/commonjs/ui/navigation/OxyRouter.js +11 -1
- package/lib/commonjs/ui/navigation/OxyRouter.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountCenterScreen.js +6 -6
- package/lib/commonjs/ui/screens/AccountCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountManagementDemo.js +3 -3
- package/lib/commonjs/ui/screens/AccountManagementDemo.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountOverviewScreen.js +241 -598
- package/lib/commonjs/ui/screens/AccountOverviewScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js +1160 -406
- package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AccountSwitcherScreen.js +135 -237
- package/lib/commonjs/ui/screens/AccountSwitcherScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/AppInfoScreen.js +246 -463
- package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FeedbackScreen.js +3 -3
- package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +808 -650
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ProfileScreen.js +214 -37
- package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/RecoverAccountScreen.js +51 -72
- package/lib/commonjs/ui/screens/RecoverAccountScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SessionManagementScreen.js +11 -29
- package/lib/commonjs/ui/screens/SessionManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SignInScreen.js +30 -303
- package/lib/commonjs/ui/screens/SignInScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/SignUpScreen.js +4 -4
- package/lib/commonjs/ui/screens/SignUpScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/UserLinksScreen.js +90 -0
- package/lib/commonjs/ui/screens/UserLinksScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/internal/SignInPasswordStep.js +19 -31
- package/lib/commonjs/ui/screens/internal/SignInPasswordStep.js.map +1 -1
- package/lib/commonjs/ui/screens/internal/SignInUsernameStep.js +7 -10
- package/lib/commonjs/ui/screens/internal/SignInUsernameStep.js.map +1 -1
- package/lib/commonjs/ui/screens/internal/SignUpIdentityStep.js +11 -5
- package/lib/commonjs/ui/screens/internal/SignUpIdentityStep.js.map +1 -1
- package/lib/commonjs/ui/screens/internal/SignUpSecurityStep.js +11 -4
- package/lib/commonjs/ui/screens/internal/SignUpSecurityStep.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaAboutScreen.js +9 -6
- package/lib/commonjs/ui/screens/karma/KarmaAboutScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaCenterScreen.js +3 -30
- package/lib/commonjs/ui/screens/karma/KarmaCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaFAQScreen.js +37 -46
- package/lib/commonjs/ui/screens/karma/KarmaFAQScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaLeaderboardScreen.js +9 -12
- package/lib/commonjs/ui/screens/karma/KarmaLeaderboardScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js +9 -12
- package/lib/commonjs/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/karma/KarmaRulesScreen.js +9 -12
- package/lib/commonjs/ui/screens/karma/KarmaRulesScreen.js.map +1 -1
- package/lib/commonjs/ui/stores/authStore.js +36 -6
- package/lib/commonjs/ui/stores/authStore.js.map +1 -1
- package/lib/commonjs/ui/stores/followStore.js +106 -1
- package/lib/commonjs/ui/stores/followStore.js.map +1 -1
- package/lib/commonjs/ui/styles/authStyles.js +337 -0
- package/lib/commonjs/ui/styles/authStyles.js.map +1 -0
- package/lib/commonjs/ui/styles/index.js +11 -0
- package/lib/commonjs/ui/styles/index.js.map +1 -1
- package/lib/module/core/index.js +177 -41
- package/lib/module/core/index.js.map +1 -1
- package/lib/module/index.js +24 -4
- package/lib/module/index.js.map +1 -1
- package/lib/module/ui/components/Avatar.js +15 -6
- package/lib/module/ui/components/Avatar.js.map +1 -1
- package/lib/module/ui/components/FollowButton.js +101 -13
- package/lib/module/ui/components/FollowButton.js.map +1 -1
- package/lib/module/ui/components/GroupedItem.js +59 -14
- package/lib/module/ui/components/GroupedItem.js.map +1 -1
- package/lib/module/ui/components/GroupedSection.js +7 -1
- package/lib/module/ui/components/GroupedSection.js.map +1 -1
- package/lib/module/ui/components/Header.js +351 -0
- package/lib/module/ui/components/Header.js.map +1 -0
- package/lib/module/ui/components/OxyProvider.js +30 -9
- package/lib/module/ui/components/OxyProvider.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 +1 -1
- package/lib/module/ui/components/internal/GroupedPillButtons.js.map +1 -1
- package/lib/module/ui/components/internal/TextField.js +607 -547
- package/lib/module/ui/components/internal/TextField.js.map +1 -1
- package/lib/module/ui/components/internal/TextField.md +436 -0
- package/lib/module/ui/context/OxyContext.js +180 -198
- package/lib/module/ui/context/OxyContext.js.map +1 -1
- package/lib/module/ui/hooks/index.js +1 -1
- package/lib/module/ui/hooks/index.js.map +1 -1
- package/lib/module/ui/hooks/useFollow.js +57 -1
- package/lib/module/ui/hooks/useFollow.js.map +1 -1
- package/lib/module/ui/hooks/useSessionSocket.js +5 -2
- package/lib/module/ui/hooks/useSessionSocket.js.map +1 -1
- package/lib/module/ui/navigation/OxyRouter.js +11 -1
- package/lib/module/ui/navigation/OxyRouter.js.map +1 -1
- package/lib/module/ui/screens/AccountCenterScreen.js +6 -6
- package/lib/module/ui/screens/AccountCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountManagementDemo.js +3 -3
- package/lib/module/ui/screens/AccountManagementDemo.js.map +1 -1
- package/lib/module/ui/screens/AccountOverviewScreen.js +242 -597
- package/lib/module/ui/screens/AccountOverviewScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSettingsScreen.js +1161 -407
- package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
- package/lib/module/ui/screens/AccountSwitcherScreen.js +135 -237
- package/lib/module/ui/screens/AccountSwitcherScreen.js.map +1 -1
- package/lib/module/ui/screens/AppInfoScreen.js +248 -465
- package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
- package/lib/module/ui/screens/FeedbackScreen.js +3 -3
- package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentGatewayScreen.js +809 -651
- package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/module/ui/screens/ProfileScreen.js +214 -37
- package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/module/ui/screens/RecoverAccountScreen.js +53 -74
- package/lib/module/ui/screens/RecoverAccountScreen.js.map +1 -1
- package/lib/module/ui/screens/SessionManagementScreen.js +11 -29
- package/lib/module/ui/screens/SessionManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/SignInScreen.js +32 -305
- package/lib/module/ui/screens/SignInScreen.js.map +1 -1
- package/lib/module/ui/screens/SignUpScreen.js +5 -5
- package/lib/module/ui/screens/SignUpScreen.js.map +1 -1
- package/lib/module/ui/screens/UserLinksScreen.js +85 -0
- package/lib/module/ui/screens/UserLinksScreen.js.map +1 -0
- package/lib/module/ui/screens/internal/SignInPasswordStep.js +19 -31
- package/lib/module/ui/screens/internal/SignInPasswordStep.js.map +1 -1
- package/lib/module/ui/screens/internal/SignInUsernameStep.js +7 -10
- package/lib/module/ui/screens/internal/SignInUsernameStep.js.map +1 -1
- package/lib/module/ui/screens/internal/SignUpIdentityStep.js +11 -5
- package/lib/module/ui/screens/internal/SignUpIdentityStep.js.map +1 -1
- package/lib/module/ui/screens/internal/SignUpSecurityStep.js +11 -4
- package/lib/module/ui/screens/internal/SignUpSecurityStep.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaAboutScreen.js +9 -6
- package/lib/module/ui/screens/karma/KarmaAboutScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaCenterScreen.js +3 -30
- package/lib/module/ui/screens/karma/KarmaCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaFAQScreen.js +37 -46
- package/lib/module/ui/screens/karma/KarmaFAQScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaLeaderboardScreen.js +9 -12
- package/lib/module/ui/screens/karma/KarmaLeaderboardScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaRewardsScreen.js +9 -12
- package/lib/module/ui/screens/karma/KarmaRewardsScreen.js.map +1 -1
- package/lib/module/ui/screens/karma/KarmaRulesScreen.js +9 -12
- package/lib/module/ui/screens/karma/KarmaRulesScreen.js.map +1 -1
- package/lib/module/ui/stores/authStore.js +36 -6
- package/lib/module/ui/stores/authStore.js.map +1 -1
- package/lib/module/ui/stores/followStore.js +106 -1
- package/lib/module/ui/stores/followStore.js.map +1 -1
- package/lib/module/ui/styles/authStyles.js +332 -0
- package/lib/module/ui/styles/authStyles.js.map +1 -0
- package/lib/module/ui/styles/index.js +1 -0
- package/lib/module/ui/styles/index.js.map +1 -1
- package/lib/typescript/core/index.d.ts +68 -24
- package/lib/typescript/core/index.d.ts.map +1 -1
- package/lib/typescript/index.d.ts +13 -3
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/ui/components/Avatar.d.ts.map +1 -1
- package/lib/typescript/ui/components/FollowButton.d.ts +1 -0
- package/lib/typescript/ui/components/FollowButton.d.ts.map +1 -1
- package/lib/typescript/ui/components/GroupedItem.d.ts +6 -0
- package/lib/typescript/ui/components/GroupedItem.d.ts.map +1 -1
- package/lib/typescript/ui/components/GroupedSection.d.ts +6 -0
- package/lib/typescript/ui/components/GroupedSection.d.ts.map +1 -1
- package/lib/typescript/ui/components/Header.d.ts +24 -0
- package/lib/typescript/ui/components/Header.d.ts.map +1 -0
- package/lib/typescript/ui/components/OxyProvider.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/TextField.d.ts +31 -16
- package/lib/typescript/ui/components/internal/TextField.d.ts.map +1 -1
- package/lib/typescript/ui/context/OxyContext.d.ts +5 -2
- package/lib/typescript/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/index.d.ts +1 -1
- package/lib/typescript/ui/hooks/index.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/useFollow.d.ts +20 -0
- package/lib/typescript/ui/hooks/useFollow.d.ts.map +1 -1
- package/lib/typescript/ui/hooks/useSessionSocket.d.ts.map +1 -1
- package/lib/typescript/ui/navigation/OxyRouter.d.ts.map +1 -1
- package/lib/typescript/ui/navigation/types.d.ts +9 -2
- package/lib/typescript/ui/navigation/types.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/PaymentGatewayScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/ProfileScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts +5 -1
- package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts.map +1 -1
- 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/UserLinksScreen.d.ts +15 -0
- package/lib/typescript/ui/screens/UserLinksScreen.d.ts.map +1 -0
- package/lib/typescript/ui/screens/internal/SignInPasswordStep.d.ts +1 -1
- package/lib/typescript/ui/screens/internal/SignInPasswordStep.d.ts.map +1 -1
- package/lib/typescript/ui/screens/internal/SignInUsernameStep.d.ts +0 -1
- package/lib/typescript/ui/screens/internal/SignInUsernameStep.d.ts.map +1 -1
- package/lib/typescript/ui/screens/internal/SignUpIdentityStep.d.ts.map +1 -1
- package/lib/typescript/ui/screens/internal/SignUpSecurityStep.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaAboutScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaCenterScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaFAQScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaLeaderboardScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaRewardsScreen.d.ts.map +1 -1
- package/lib/typescript/ui/screens/karma/KarmaRulesScreen.d.ts.map +1 -1
- package/lib/typescript/ui/stores/authStore.d.ts +3 -1
- package/lib/typescript/ui/stores/authStore.d.ts.map +1 -1
- package/lib/typescript/ui/stores/followStore.d.ts +10 -0
- package/lib/typescript/ui/stores/followStore.d.ts.map +1 -1
- package/lib/typescript/ui/styles/authStyles.d.ts +326 -0
- package/lib/typescript/ui/styles/authStyles.d.ts.map +1 -0
- package/lib/typescript/ui/styles/index.d.ts +1 -0
- package/lib/typescript/ui/styles/index.d.ts.map +1 -1
- package/package.json +1 -4
- package/src/core/index.ts +195 -41
- package/src/index.ts +64 -4
- package/src/ui/components/Avatar.tsx +11 -5
- package/src/ui/components/FollowButton.tsx +95 -11
- package/src/ui/components/GroupedItem.tsx +57 -9
- package/src/ui/components/GroupedSection.tsx +12 -0
- package/src/ui/components/Header.tsx +405 -0
- package/src/ui/components/OxyProvider.tsx +37 -15
- package/src/ui/components/index.ts +1 -0
- package/src/ui/components/internal/GroupedPillButtons.tsx +1 -1
- package/src/ui/components/internal/TextField.md +436 -0
- package/src/ui/components/internal/TextField.tsx +720 -620
- package/src/ui/context/OxyContext.tsx +211 -195
- package/src/ui/hooks/index.ts +1 -1
- package/src/ui/hooks/useFollow.ts +63 -0
- package/src/ui/hooks/useSessionSocket.ts +5 -2
- package/src/ui/navigation/OxyRouter.tsx +11 -1
- package/src/ui/navigation/types.ts +10 -2
- package/src/ui/screens/AccountCenterScreen.tsx +5 -5
- package/src/ui/screens/AccountManagementDemo.tsx +9 -9
- package/src/ui/screens/AccountOverviewScreen.tsx +265 -414
- package/src/ui/screens/AccountSettingsScreen.tsx +1173 -403
- package/src/ui/screens/AccountSwitcherScreen.tsx +158 -202
- package/src/ui/screens/AppInfoScreen.tsx +270 -497
- package/src/ui/screens/FeedbackScreen.tsx +3 -3
- package/src/ui/screens/PaymentGatewayScreen.tsx +668 -365
- package/src/ui/screens/ProfileScreen.tsx +196 -33
- package/src/ui/screens/RecoverAccountScreen.tsx +46 -74
- package/src/ui/screens/SessionManagementScreen.tsx +14 -22
- package/src/ui/screens/SignInScreen.tsx +27 -294
- package/src/ui/screens/SignUpScreen.tsx +5 -5
- package/src/ui/screens/UserLinksScreen.tsx +96 -0
- package/src/ui/screens/internal/SignInPasswordStep.tsx +11 -22
- package/src/ui/screens/internal/SignInUsernameStep.tsx +3 -10
- package/src/ui/screens/internal/SignUpIdentityStep.tsx +2 -5
- package/src/ui/screens/internal/SignUpSecurityStep.tsx +3 -4
- package/src/ui/screens/karma/KarmaAboutScreen.tsx +9 -2
- package/src/ui/screens/karma/KarmaCenterScreen.tsx +1 -20
- package/src/ui/screens/karma/KarmaFAQScreen.tsx +40 -24
- package/src/ui/screens/karma/KarmaLeaderboardScreen.tsx +9 -3
- package/src/ui/screens/karma/KarmaRewardsScreen.tsx +9 -3
- package/src/ui/screens/karma/KarmaRulesScreen.tsx +9 -3
- package/src/ui/stores/authStore.ts +34 -7
- package/src/ui/stores/followStore.ts +102 -1
- package/src/ui/styles/authStyles.ts +352 -0
- package/src/ui/styles/index.ts +1 -0
- package/lib/commonjs/core/auth-manager.js +0 -440
- package/lib/commonjs/core/auth-manager.js.map +0 -1
- package/lib/commonjs/core/use-auth.js +0 -244
- package/lib/commonjs/core/use-auth.js.map +0 -1
- package/lib/module/core/auth-manager.js +0 -432
- package/lib/module/core/auth-manager.js.map +0 -1
- package/lib/module/core/use-auth.js +0 -235
- package/lib/module/core/use-auth.js.map +0 -1
- package/lib/typescript/core/auth-manager.d.ts +0 -136
- package/lib/typescript/core/auth-manager.d.ts.map +0 -1
- package/lib/typescript/core/use-auth.d.ts +0 -79
- package/lib/typescript/core/use-auth.d.ts.map +0 -1
- package/src/__tests__/middleware.test.ts +0 -105
- package/src/__tests__/setup.ts +0 -10
- package/src/__tests__/zero-config-auth.test.ts +0 -607
- package/src/core/auth-manager.ts +0 -500
- package/src/core/use-auth.tsx +0 -245
|
@@ -7,7 +7,8 @@ import Avatar from '../components/Avatar';
|
|
|
7
7
|
import OxyIcon from '../components/icon/OxyIcon';
|
|
8
8
|
import { toast } from '../../lib/sonner';
|
|
9
9
|
import { confirmAction } from '../utils/confirmAction';
|
|
10
|
-
import {
|
|
10
|
+
import { Header, Section, GroupedSection, GroupedItem } from '../components';
|
|
11
|
+
|
|
11
12
|
/**
|
|
12
13
|
* AccountOverviewScreen - Optimized for performance
|
|
13
14
|
*
|
|
@@ -16,7 +17,9 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
16
17
|
* - useMemo for additional accounts filtering (only recalculates when dependencies change)
|
|
17
18
|
* - useCallback for event handlers to prevent unnecessary re-renders
|
|
18
19
|
* - React.memo wrapper to prevent re-renders when props haven't changed
|
|
20
|
+
* - GroupedSection components for better organization and cleaner code
|
|
19
21
|
*/
|
|
22
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
20
23
|
const AccountOverviewScreen = ({
|
|
21
24
|
onClose,
|
|
22
25
|
theme,
|
|
@@ -153,545 +156,259 @@ const AccountOverviewScreen = ({
|
|
|
153
156
|
style: [styles.container, {
|
|
154
157
|
backgroundColor: '#f2f2f2'
|
|
155
158
|
}],
|
|
156
|
-
children: [/*#__PURE__*/
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
style: styles.closeButton,
|
|
163
|
-
onPress: onClose,
|
|
164
|
-
children: /*#__PURE__*/_jsx(Text, {
|
|
165
|
-
style: styles.closeButtonText,
|
|
166
|
-
children: "\xD7"
|
|
167
|
-
})
|
|
168
|
-
})]
|
|
159
|
+
children: [/*#__PURE__*/_jsx(Header, {
|
|
160
|
+
title: "Account",
|
|
161
|
+
theme: theme,
|
|
162
|
+
onBack: onClose,
|
|
163
|
+
variant: "minimal",
|
|
164
|
+
elevation: "subtle"
|
|
169
165
|
}), /*#__PURE__*/_jsxs(ScrollView, {
|
|
170
166
|
style: styles.content,
|
|
171
|
-
children: [/*#__PURE__*/
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
}), /*#__PURE__*/_jsx(
|
|
193
|
-
style: styles.
|
|
194
|
-
|
|
167
|
+
children: [/*#__PURE__*/_jsx(Section, {
|
|
168
|
+
title: "Profile",
|
|
169
|
+
theme: theme,
|
|
170
|
+
isFirst: true,
|
|
171
|
+
children: /*#__PURE__*/_jsx(GroupedSection, {
|
|
172
|
+
items: [{
|
|
173
|
+
id: 'profile-info',
|
|
174
|
+
icon: 'person',
|
|
175
|
+
iconColor: '#007AFF',
|
|
176
|
+
title: user ? typeof user.name === 'string' ? user.name : user.name?.full || user.name?.first || user.username : 'Loading...',
|
|
177
|
+
subtitle: user ? user.email || user.username : 'Loading...',
|
|
178
|
+
onPress: () => toast.info('Manage your Oxy Account feature coming soon!'),
|
|
179
|
+
customContent: /*#__PURE__*/_jsxs(_Fragment, {
|
|
180
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
181
|
+
style: styles.userIcon,
|
|
182
|
+
children: /*#__PURE__*/_jsx(Avatar, {
|
|
183
|
+
uri: user?.avatar?.url,
|
|
184
|
+
name: user?.name?.full,
|
|
185
|
+
size: 40,
|
|
186
|
+
theme: theme
|
|
187
|
+
})
|
|
188
|
+
}), /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
189
|
+
style: styles.manageButton,
|
|
190
|
+
onPress: () => toast.info('Manage your Oxy Account feature coming soon!'),
|
|
191
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
192
|
+
style: styles.manageButtonText,
|
|
193
|
+
children: "Manage"
|
|
194
|
+
})
|
|
195
195
|
})]
|
|
196
196
|
})
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
197
|
+
}],
|
|
198
|
+
theme: theme
|
|
199
|
+
})
|
|
200
|
+
}), /*#__PURE__*/_jsx(Section, {
|
|
201
|
+
title: "Account Settings",
|
|
202
|
+
theme: theme,
|
|
203
|
+
children: /*#__PURE__*/_jsx(GroupedSection, {
|
|
204
|
+
items: [{
|
|
205
|
+
id: 'edit-profile',
|
|
206
|
+
icon: 'person-circle',
|
|
207
|
+
iconColor: '#007AFF',
|
|
208
|
+
title: 'Edit Profile',
|
|
209
|
+
subtitle: 'Update your personal information',
|
|
210
|
+
onPress: () => navigate?.('EditProfile', {
|
|
211
|
+
activeTab: 'profile'
|
|
203
212
|
})
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
})]
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
style: styles.settingDescription,
|
|
255
|
-
children: "Password, 2FA, and privacy settings"
|
|
256
|
-
})]
|
|
257
|
-
})]
|
|
258
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
259
|
-
name: "chevron-forward",
|
|
260
|
-
size: 16,
|
|
261
|
-
color: "#ccc"
|
|
262
|
-
})]
|
|
263
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
264
|
-
style: styles.settingItem,
|
|
265
|
-
onPress: () => navigate?.('AccountSettings', {
|
|
266
|
-
activeTab: 'notifications'
|
|
267
|
-
}),
|
|
268
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
269
|
-
style: styles.settingInfo,
|
|
270
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
271
|
-
name: "notifications",
|
|
272
|
-
size: 20,
|
|
273
|
-
color: "#FF9500",
|
|
274
|
-
style: styles.settingIcon
|
|
275
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
276
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
277
|
-
style: styles.settingLabel,
|
|
278
|
-
children: "Notifications"
|
|
279
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
280
|
-
style: styles.settingDescription,
|
|
281
|
-
children: "Manage your notification preferences"
|
|
282
|
-
})]
|
|
283
|
-
})]
|
|
284
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
285
|
-
name: "chevron-forward",
|
|
286
|
-
size: 16,
|
|
287
|
-
color: "#ccc"
|
|
288
|
-
})]
|
|
289
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
290
|
-
style: [styles.settingItem],
|
|
291
|
-
onPress: () => navigate?.('PremiumSubscription'),
|
|
292
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
293
|
-
style: styles.settingInfo,
|
|
294
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
295
|
-
name: "star",
|
|
296
|
-
size: 20,
|
|
297
|
-
color: "#FFD700",
|
|
298
|
-
style: styles.settingIcon
|
|
299
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
300
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
301
|
-
style: styles.settingLabel,
|
|
302
|
-
children: "Oxy+ Subscriptions"
|
|
303
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
304
|
-
style: styles.settingDescription,
|
|
305
|
-
children: user?.isPremium ? 'Manage your premium plan' : 'Upgrade to premium features'
|
|
306
|
-
})]
|
|
307
|
-
})]
|
|
308
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
309
|
-
name: "chevron-forward",
|
|
310
|
-
size: 16,
|
|
311
|
-
color: "#ccc"
|
|
312
|
-
})]
|
|
313
|
-
}), user?.isPremium && /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
314
|
-
style: [styles.settingItem, styles.lastSettingItem],
|
|
315
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
316
|
-
style: styles.settingInfo,
|
|
317
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
318
|
-
name: "card",
|
|
319
|
-
size: 20,
|
|
320
|
-
color: "#34C759",
|
|
321
|
-
style: styles.settingIcon
|
|
322
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
323
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
324
|
-
style: styles.settingLabel,
|
|
325
|
-
children: "Billing Management"
|
|
213
|
+
}, {
|
|
214
|
+
id: 'security-privacy',
|
|
215
|
+
icon: 'shield-checkmark',
|
|
216
|
+
iconColor: '#30D158',
|
|
217
|
+
title: 'Security & Privacy',
|
|
218
|
+
subtitle: 'Password, 2FA, and privacy settings',
|
|
219
|
+
onPress: () => navigate?.('EditProfile', {
|
|
220
|
+
activeTab: 'password'
|
|
221
|
+
})
|
|
222
|
+
}, {
|
|
223
|
+
id: 'notifications',
|
|
224
|
+
icon: 'notifications',
|
|
225
|
+
iconColor: '#FF9500',
|
|
226
|
+
title: 'Notifications',
|
|
227
|
+
subtitle: 'Manage your notification preferences',
|
|
228
|
+
onPress: () => navigate?.('EditProfile', {
|
|
229
|
+
activeTab: 'notifications'
|
|
230
|
+
})
|
|
231
|
+
}, {
|
|
232
|
+
id: 'premium-subscription',
|
|
233
|
+
icon: 'star',
|
|
234
|
+
iconColor: '#FFD700',
|
|
235
|
+
title: 'Oxy+ Subscriptions',
|
|
236
|
+
subtitle: user?.isPremium ? 'Manage your premium plan' : 'Upgrade to premium features',
|
|
237
|
+
onPress: () => navigate?.('PremiumSubscription')
|
|
238
|
+
}, ...(user?.isPremium ? [{
|
|
239
|
+
id: 'billing-management',
|
|
240
|
+
icon: 'card',
|
|
241
|
+
iconColor: '#34C759',
|
|
242
|
+
title: 'Billing Management',
|
|
243
|
+
subtitle: 'Payment methods and invoices',
|
|
244
|
+
onPress: () => toast.info('Billing management feature coming soon!')
|
|
245
|
+
}] : [])],
|
|
246
|
+
theme: theme
|
|
247
|
+
})
|
|
248
|
+
}), showMoreAccounts && /*#__PURE__*/_jsx(Section, {
|
|
249
|
+
title: `Additional Accounts${additionalAccountsData.length > 0 ? ` (${additionalAccountsData.length})` : ''}`,
|
|
250
|
+
theme: theme,
|
|
251
|
+
children: loadingAdditionalAccounts ? /*#__PURE__*/_jsx(GroupedSection, {
|
|
252
|
+
items: [{
|
|
253
|
+
id: 'loading-accounts',
|
|
254
|
+
icon: 'sync',
|
|
255
|
+
iconColor: '#007AFF',
|
|
256
|
+
title: 'Loading accounts...',
|
|
257
|
+
subtitle: 'Please wait while we load your additional accounts',
|
|
258
|
+
customContent: /*#__PURE__*/_jsxs(View, {
|
|
259
|
+
style: styles.loadingContainer,
|
|
260
|
+
children: [/*#__PURE__*/_jsx(ActivityIndicator, {
|
|
261
|
+
size: "small",
|
|
262
|
+
color: "#007AFF"
|
|
326
263
|
}), /*#__PURE__*/_jsx(Text, {
|
|
327
|
-
style: styles.
|
|
328
|
-
children: "
|
|
264
|
+
style: styles.loadingText,
|
|
265
|
+
children: "Loading accounts..."
|
|
329
266
|
})]
|
|
330
|
-
})
|
|
331
|
-
}
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
style: styles.sectionTitle,
|
|
341
|
-
children: ["Additional Accounts", additionalAccountsData.length > 0 ? ` (${additionalAccountsData.length})` : '']
|
|
342
|
-
}), loadingAdditionalAccounts ? /*#__PURE__*/_jsx(View, {
|
|
343
|
-
style: [styles.settingItem, styles.firstSettingItem, styles.lastSettingItem],
|
|
344
|
-
children: /*#__PURE__*/_jsxs(View, {
|
|
345
|
-
style: styles.loadingContainer,
|
|
346
|
-
children: [/*#__PURE__*/_jsx(ActivityIndicator, {
|
|
347
|
-
size: "small",
|
|
348
|
-
color: "#007AFF"
|
|
349
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
350
|
-
style: styles.loadingText,
|
|
351
|
-
children: "Loading accounts..."
|
|
352
|
-
})]
|
|
353
|
-
})
|
|
354
|
-
}) : additionalAccountsData.length > 0 ? /*#__PURE__*/_jsx(_Fragment, {
|
|
355
|
-
children: additionalAccountsData.map((account, index) => /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
356
|
-
style: [styles.settingItem, index === 0 && styles.firstSettingItem, index === additionalAccountsData.length - 1 && styles.lastSettingItem],
|
|
267
|
+
})
|
|
268
|
+
}],
|
|
269
|
+
theme: theme
|
|
270
|
+
}) : additionalAccountsData.length > 0 ? /*#__PURE__*/_jsx(GroupedSection, {
|
|
271
|
+
items: additionalAccountsData.map((account, index) => ({
|
|
272
|
+
id: `account-${account.id}`,
|
|
273
|
+
icon: 'person',
|
|
274
|
+
iconColor: '#5856D6',
|
|
275
|
+
title: typeof account.name === 'object' ? account.name?.full || account.name?.first || account.username : account.name || account.username,
|
|
276
|
+
subtitle: account.email || account.username,
|
|
357
277
|
onPress: () => {
|
|
358
278
|
toast.info(`Switch to ${account.username}?`);
|
|
359
279
|
// TODO: Implement account switching logic
|
|
360
280
|
// switchSession(account.sessionId);
|
|
361
281
|
},
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
282
|
+
customContent: /*#__PURE__*/_jsxs(_Fragment, {
|
|
283
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
284
|
+
style: styles.userIcon,
|
|
285
|
+
children: account.avatar?.url ? /*#__PURE__*/_jsx(Image, {
|
|
286
|
+
source: {
|
|
287
|
+
uri: account.avatar.url
|
|
288
|
+
},
|
|
289
|
+
style: styles.accountAvatarImage
|
|
290
|
+
}) : /*#__PURE__*/_jsx(View, {
|
|
291
|
+
style: styles.accountAvatarFallback,
|
|
292
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
293
|
+
style: styles.accountAvatarText,
|
|
294
|
+
children: account.username?.charAt(0).toUpperCase() || '?'
|
|
295
|
+
})
|
|
374
296
|
})
|
|
375
|
-
})
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
380
|
-
style: styles.settingLabel,
|
|
381
|
-
children: typeof account.name === 'object' ? account.name?.full || account.name?.first || account.username : account.name || account.username
|
|
382
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
383
|
-
style: styles.settingDescription,
|
|
384
|
-
children: account.email || account.username
|
|
385
|
-
})]
|
|
386
|
-
})
|
|
387
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
388
|
-
name: "chevron-forward",
|
|
389
|
-
size: 16,
|
|
390
|
-
color: "#ccc"
|
|
391
|
-
})]
|
|
392
|
-
}, account.id))
|
|
393
|
-
}) : /*#__PURE__*/_jsx(View, {
|
|
394
|
-
style: [styles.settingItem, styles.firstSettingItem, styles.lastSettingItem],
|
|
395
|
-
children: /*#__PURE__*/_jsxs(View, {
|
|
396
|
-
style: styles.settingInfo,
|
|
397
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
398
|
-
name: "person-outline",
|
|
399
|
-
size: 20,
|
|
400
|
-
color: "#ccc",
|
|
401
|
-
style: styles.settingIcon
|
|
402
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
403
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
404
|
-
style: styles.settingLabel,
|
|
405
|
-
children: "No other accounts"
|
|
406
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
407
|
-
style: styles.settingDescription,
|
|
408
|
-
children: "Add another account to switch between them"
|
|
409
|
-
})]
|
|
410
|
-
})]
|
|
411
|
-
})
|
|
412
|
-
})]
|
|
413
|
-
}), showMoreAccounts && /*#__PURE__*/_jsxs(View, {
|
|
414
|
-
style: styles.section,
|
|
415
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
416
|
-
style: styles.sectionTitle,
|
|
417
|
-
children: "Account Management"
|
|
418
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
419
|
-
style: [styles.settingItem, styles.firstSettingItem],
|
|
420
|
-
onPress: handleAddAccount,
|
|
421
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
422
|
-
style: styles.settingInfo,
|
|
423
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
424
|
-
name: "add",
|
|
425
|
-
size: 20,
|
|
426
|
-
color: "#007AFF",
|
|
427
|
-
style: styles.settingIcon
|
|
428
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
429
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
430
|
-
style: styles.settingLabel,
|
|
431
|
-
children: "Add another account"
|
|
432
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
433
|
-
style: styles.settingDescription,
|
|
434
|
-
children: "Sign in with a different account"
|
|
435
|
-
})]
|
|
436
|
-
})]
|
|
437
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
438
|
-
name: "chevron-forward",
|
|
439
|
-
size: 16,
|
|
440
|
-
color: "#ccc"
|
|
441
|
-
})]
|
|
442
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
443
|
-
style: [styles.settingItem, styles.lastSettingItem],
|
|
444
|
-
onPress: handleSignOutAll,
|
|
445
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
446
|
-
style: styles.settingInfo,
|
|
447
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
448
|
-
name: "log-out",
|
|
449
|
-
size: 20,
|
|
450
|
-
color: "#FF3B30",
|
|
451
|
-
style: styles.settingIcon
|
|
452
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
453
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
454
|
-
style: styles.settingLabel,
|
|
455
|
-
children: "Sign out of all accounts"
|
|
456
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
457
|
-
style: styles.settingDescription,
|
|
458
|
-
children: "Remove all accounts from this device"
|
|
459
|
-
})]
|
|
460
|
-
})]
|
|
461
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
462
|
-
name: "chevron-forward",
|
|
463
|
-
size: 16,
|
|
464
|
-
color: "#ccc"
|
|
465
|
-
})]
|
|
466
|
-
})]
|
|
467
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
468
|
-
style: styles.section,
|
|
469
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
470
|
-
style: styles.sectionTitle,
|
|
471
|
-
children: "Quick Actions"
|
|
472
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
473
|
-
style: [styles.settingItem, styles.firstSettingItem],
|
|
474
|
-
onPress: () => setShowMoreAccounts(!showMoreAccounts),
|
|
475
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
476
|
-
style: styles.settingInfo,
|
|
477
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
478
|
-
name: "people",
|
|
479
|
-
size: 20,
|
|
480
|
-
color: "#5856D6",
|
|
481
|
-
style: styles.settingIcon
|
|
482
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
483
|
-
children: [/*#__PURE__*/_jsxs(Text, {
|
|
484
|
-
style: styles.settingLabel,
|
|
485
|
-
children: [showMoreAccounts ? 'Hide' : 'Show', " Account Switcher"]
|
|
486
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
487
|
-
style: styles.settingDescription,
|
|
488
|
-
children: showMoreAccounts ? 'Hide account switcher' : additionalAccountsData.length > 0 ? `Switch between ${additionalAccountsData.length + 1} accounts` : loadingAdditionalAccounts ? 'Loading additional accounts...' : 'Manage multiple accounts'
|
|
489
|
-
})]
|
|
490
|
-
})]
|
|
491
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
492
|
-
name: "chevron-forward",
|
|
493
|
-
size: 16,
|
|
494
|
-
color: "#ccc"
|
|
495
|
-
})]
|
|
496
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
497
|
-
style: styles.settingItem,
|
|
498
|
-
onPress: () => toast.info('Download account data feature coming soon!'),
|
|
499
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
500
|
-
style: styles.settingInfo,
|
|
501
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
502
|
-
name: "download",
|
|
503
|
-
size: 20,
|
|
504
|
-
color: "#34C759",
|
|
505
|
-
style: styles.settingIcon
|
|
506
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
507
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
508
|
-
style: styles.settingLabel,
|
|
509
|
-
children: "Download My Data"
|
|
510
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
511
|
-
style: styles.settingDescription,
|
|
512
|
-
children: "Export your account information"
|
|
513
|
-
})]
|
|
514
|
-
})]
|
|
515
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
516
|
-
name: "chevron-forward",
|
|
517
|
-
size: 16,
|
|
518
|
-
color: "#ccc"
|
|
519
|
-
})]
|
|
520
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
521
|
-
style: [styles.settingItem, styles.lastSettingItem],
|
|
522
|
-
onPress: () => toast.info('Delete account feature coming soon!'),
|
|
523
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
524
|
-
style: styles.settingInfo,
|
|
525
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
526
|
-
name: "trash",
|
|
527
|
-
size: 20,
|
|
528
|
-
color: "#FF3B30",
|
|
529
|
-
style: styles.settingIcon
|
|
530
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
531
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
532
|
-
style: styles.settingLabel,
|
|
533
|
-
children: "Delete Account"
|
|
534
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
535
|
-
style: styles.settingDescription,
|
|
536
|
-
children: "Permanently delete your account"
|
|
537
|
-
})]
|
|
538
|
-
})]
|
|
539
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
540
|
-
name: "chevron-forward",
|
|
541
|
-
size: 16,
|
|
542
|
-
color: "#ccc"
|
|
543
|
-
})]
|
|
544
|
-
})]
|
|
545
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
546
|
-
style: styles.section,
|
|
547
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
548
|
-
style: styles.sectionTitle,
|
|
549
|
-
children: "Support & Settings"
|
|
550
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
551
|
-
style: [styles.settingItem, styles.firstSettingItem],
|
|
552
|
-
onPress: () => toast.info('Account preferences coming soon!'),
|
|
553
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
554
|
-
style: styles.settingInfo,
|
|
555
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
556
|
-
name: "settings",
|
|
557
|
-
size: 20,
|
|
558
|
-
color: "#8E8E93",
|
|
559
|
-
style: styles.settingIcon
|
|
560
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
561
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
562
|
-
style: styles.settingLabel,
|
|
563
|
-
children: "Account Preferences"
|
|
564
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
565
|
-
style: styles.settingDescription,
|
|
566
|
-
children: "Customize your account experience"
|
|
567
|
-
})]
|
|
568
|
-
})]
|
|
569
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
570
|
-
name: "chevron-forward",
|
|
571
|
-
size: 16,
|
|
572
|
-
color: "#ccc"
|
|
573
|
-
})]
|
|
574
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
575
|
-
style: styles.settingItem,
|
|
576
|
-
onPress: () => toast.info('Help & support feature coming soon!'),
|
|
577
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
578
|
-
style: styles.settingInfo,
|
|
579
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
580
|
-
name: "help-circle",
|
|
581
|
-
size: 20,
|
|
582
|
-
color: "#007AFF",
|
|
583
|
-
style: styles.settingIcon
|
|
584
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
585
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
586
|
-
style: styles.settingLabel,
|
|
587
|
-
children: "Help & Support"
|
|
588
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
589
|
-
style: styles.settingDescription,
|
|
590
|
-
children: "Get help with your account"
|
|
591
|
-
})]
|
|
592
|
-
})]
|
|
593
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
594
|
-
name: "chevron-forward",
|
|
595
|
-
size: 16,
|
|
596
|
-
color: "#ccc"
|
|
597
|
-
})]
|
|
598
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
599
|
-
style: styles.settingItem,
|
|
600
|
-
onPress: () => toast.info('Connected apps feature coming soon!'),
|
|
601
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
602
|
-
style: styles.settingInfo,
|
|
603
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
604
|
-
name: "link",
|
|
605
|
-
size: 20,
|
|
606
|
-
color: "#32D74B",
|
|
607
|
-
style: styles.settingIcon
|
|
608
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
609
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
610
|
-
style: styles.settingLabel,
|
|
611
|
-
children: "Connected Apps"
|
|
612
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
613
|
-
style: styles.settingDescription,
|
|
614
|
-
children: "Manage third-party app access"
|
|
615
|
-
})]
|
|
616
|
-
})]
|
|
617
|
-
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
618
|
-
name: "chevron-forward",
|
|
619
|
-
size: 16,
|
|
620
|
-
color: "#ccc"
|
|
621
|
-
})]
|
|
622
|
-
}), /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
623
|
-
style: styles.settingItem,
|
|
624
|
-
onPress: () => toast.info('Privacy Policy feature coming soon!'),
|
|
625
|
-
children: [/*#__PURE__*/_jsxs(View, {
|
|
626
|
-
style: styles.settingInfo,
|
|
627
|
-
children: [/*#__PURE__*/_jsx(OxyIcon, {
|
|
628
|
-
name: "document-lock",
|
|
629
|
-
size: 20,
|
|
630
|
-
color: "#FF9F0A",
|
|
631
|
-
style: styles.settingIcon
|
|
632
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
633
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
634
|
-
style: styles.settingLabel,
|
|
635
|
-
children: "Privacy Policy"
|
|
636
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
637
|
-
style: styles.settingDescription,
|
|
638
|
-
children: "Learn about data protection"
|
|
297
|
+
}), /*#__PURE__*/_jsx(OxyIcon, {
|
|
298
|
+
name: "chevron-forward",
|
|
299
|
+
size: 16,
|
|
300
|
+
color: "#ccc"
|
|
639
301
|
})]
|
|
640
|
-
})
|
|
641
|
-
}),
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
302
|
+
})
|
|
303
|
+
})),
|
|
304
|
+
theme: theme
|
|
305
|
+
}) : /*#__PURE__*/_jsx(GroupedSection, {
|
|
306
|
+
items: [{
|
|
307
|
+
id: 'no-accounts',
|
|
308
|
+
icon: 'person-outline',
|
|
309
|
+
iconColor: '#ccc',
|
|
310
|
+
title: 'No other accounts',
|
|
311
|
+
subtitle: 'Add another account to switch between them'
|
|
312
|
+
}],
|
|
313
|
+
theme: theme
|
|
314
|
+
})
|
|
315
|
+
}), showMoreAccounts && /*#__PURE__*/_jsx(Section, {
|
|
316
|
+
title: "Account Management",
|
|
317
|
+
theme: theme,
|
|
318
|
+
children: /*#__PURE__*/_jsx(GroupedSection, {
|
|
319
|
+
items: [{
|
|
320
|
+
id: 'add-account',
|
|
321
|
+
icon: 'add',
|
|
322
|
+
iconColor: '#007AFF',
|
|
323
|
+
title: 'Add another account',
|
|
324
|
+
subtitle: 'Sign in with a different account',
|
|
325
|
+
onPress: handleAddAccount
|
|
326
|
+
}, {
|
|
327
|
+
id: 'sign-out-all',
|
|
328
|
+
icon: 'log-out',
|
|
329
|
+
iconColor: '#FF3B30',
|
|
330
|
+
title: 'Sign out of all accounts',
|
|
331
|
+
subtitle: 'Remove all accounts from this device',
|
|
332
|
+
onPress: handleSignOutAll
|
|
333
|
+
}],
|
|
334
|
+
theme: theme
|
|
335
|
+
})
|
|
336
|
+
}), /*#__PURE__*/_jsx(Section, {
|
|
337
|
+
title: "Quick Actions",
|
|
338
|
+
theme: theme,
|
|
339
|
+
children: /*#__PURE__*/_jsx(GroupedSection, {
|
|
340
|
+
items: [{
|
|
341
|
+
id: 'account-switcher',
|
|
342
|
+
icon: 'people',
|
|
343
|
+
iconColor: '#5856D6',
|
|
344
|
+
title: `${showMoreAccounts ? 'Hide' : 'Show'} Account Switcher`,
|
|
345
|
+
subtitle: showMoreAccounts ? 'Hide account switcher' : additionalAccountsData.length > 0 ? `Switch between ${additionalAccountsData.length + 1} accounts` : loadingAdditionalAccounts ? 'Loading additional accounts...' : 'Manage multiple accounts',
|
|
346
|
+
onPress: () => setShowMoreAccounts(!showMoreAccounts)
|
|
347
|
+
}, {
|
|
348
|
+
id: 'download-data',
|
|
349
|
+
icon: 'download',
|
|
350
|
+
iconColor: '#34C759',
|
|
351
|
+
title: 'Download My Data',
|
|
352
|
+
subtitle: 'Export your account information',
|
|
353
|
+
onPress: () => toast.info('Download account data feature coming soon!')
|
|
354
|
+
}, {
|
|
355
|
+
id: 'delete-account',
|
|
356
|
+
icon: 'trash',
|
|
357
|
+
iconColor: '#FF3B30',
|
|
358
|
+
title: 'Delete Account',
|
|
359
|
+
subtitle: 'Permanently delete your account',
|
|
360
|
+
onPress: () => toast.info('Delete account feature coming soon!')
|
|
361
|
+
}],
|
|
362
|
+
theme: theme
|
|
363
|
+
})
|
|
364
|
+
}), /*#__PURE__*/_jsx(Section, {
|
|
365
|
+
title: "Support & Settings",
|
|
366
|
+
theme: theme,
|
|
367
|
+
children: /*#__PURE__*/_jsx(GroupedSection, {
|
|
368
|
+
items: [{
|
|
369
|
+
id: 'account-preferences',
|
|
370
|
+
icon: 'settings',
|
|
371
|
+
iconColor: '#8E8E93',
|
|
372
|
+
title: 'Account Preferences',
|
|
373
|
+
subtitle: 'Customize your account experience',
|
|
374
|
+
onPress: () => toast.info('Account preferences coming soon!')
|
|
375
|
+
}, {
|
|
376
|
+
id: 'help-support',
|
|
377
|
+
icon: 'help-circle',
|
|
378
|
+
iconColor: '#007AFF',
|
|
379
|
+
title: 'Help & Support',
|
|
380
|
+
subtitle: 'Get help with your account',
|
|
381
|
+
onPress: () => toast.info('Help & support feature coming soon!')
|
|
382
|
+
}, {
|
|
383
|
+
id: 'connected-apps',
|
|
384
|
+
icon: 'link',
|
|
385
|
+
iconColor: '#32D74B',
|
|
386
|
+
title: 'Connected Apps',
|
|
387
|
+
subtitle: 'Manage third-party app access',
|
|
388
|
+
onPress: () => toast.info('Connected apps feature coming soon!')
|
|
389
|
+
}, {
|
|
390
|
+
id: 'about',
|
|
391
|
+
icon: 'information-circle',
|
|
392
|
+
iconColor: '#8E8E93',
|
|
393
|
+
title: 'About',
|
|
394
|
+
subtitle: 'App version and information',
|
|
395
|
+
onPress: () => navigate?.('AppInfo')
|
|
396
|
+
}],
|
|
397
|
+
theme: theme
|
|
398
|
+
})
|
|
399
|
+
}), /*#__PURE__*/_jsx(Section, {
|
|
400
|
+
title: "Account Actions",
|
|
401
|
+
theme: theme,
|
|
402
|
+
children: /*#__PURE__*/_jsx(GroupedItem, {
|
|
403
|
+
icon: "log-out",
|
|
404
|
+
iconColor: "#FF3B30",
|
|
405
|
+
title: "Sign Out",
|
|
406
|
+
subtitle: "Sign out of your current account",
|
|
407
|
+
theme: theme,
|
|
675
408
|
onPress: confirmLogout,
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
name: "log-out",
|
|
680
|
-
size: 20,
|
|
681
|
-
color: "#ff4757",
|
|
682
|
-
style: styles.settingIcon
|
|
683
|
-
}), /*#__PURE__*/_jsxs(View, {
|
|
684
|
-
children: [/*#__PURE__*/_jsx(Text, {
|
|
685
|
-
style: [styles.settingLabel, {
|
|
686
|
-
color: '#ff4757'
|
|
687
|
-
}],
|
|
688
|
-
children: "Sign Out"
|
|
689
|
-
}), /*#__PURE__*/_jsx(Text, {
|
|
690
|
-
style: styles.settingDescription,
|
|
691
|
-
children: "Sign out of your account"
|
|
692
|
-
})]
|
|
693
|
-
})]
|
|
694
|
-
})
|
|
409
|
+
isFirst: true,
|
|
410
|
+
isLast: true,
|
|
411
|
+
showChevron: false
|
|
695
412
|
})
|
|
696
413
|
})]
|
|
697
414
|
})]
|
|
@@ -702,78 +419,10 @@ const styles = StyleSheet.create({
|
|
|
702
419
|
flex: 1,
|
|
703
420
|
backgroundColor: '#f2f2f2'
|
|
704
421
|
},
|
|
705
|
-
header: {
|
|
706
|
-
paddingHorizontal: 20,
|
|
707
|
-
paddingTop: 60,
|
|
708
|
-
paddingBottom: 16,
|
|
709
|
-
backgroundColor: '#fff',
|
|
710
|
-
borderBottomWidth: 1,
|
|
711
|
-
borderBottomColor: '#e0e0e0',
|
|
712
|
-
flexDirection: 'row',
|
|
713
|
-
justifyContent: 'space-between',
|
|
714
|
-
alignItems: 'center'
|
|
715
|
-
},
|
|
716
|
-
headerTitle: {
|
|
717
|
-
fontSize: 24,
|
|
718
|
-
fontWeight: 'bold',
|
|
719
|
-
color: '#000'
|
|
720
|
-
},
|
|
721
|
-
closeButton: {
|
|
722
|
-
padding: 8
|
|
723
|
-
},
|
|
724
|
-
closeButtonText: {
|
|
725
|
-
fontSize: 24,
|
|
726
|
-
color: '#000',
|
|
727
|
-
fontWeight: '300'
|
|
728
|
-
},
|
|
729
422
|
content: {
|
|
730
423
|
flex: 1,
|
|
731
424
|
padding: 16
|
|
732
425
|
},
|
|
733
|
-
section: {
|
|
734
|
-
marginBottom: 24
|
|
735
|
-
},
|
|
736
|
-
sectionTitle: {
|
|
737
|
-
fontSize: 16,
|
|
738
|
-
fontWeight: '600',
|
|
739
|
-
color: '#333',
|
|
740
|
-
marginBottom: 12
|
|
741
|
-
},
|
|
742
|
-
settingItem: {
|
|
743
|
-
backgroundColor: '#fff',
|
|
744
|
-
padding: 16,
|
|
745
|
-
flexDirection: 'row',
|
|
746
|
-
alignItems: 'center',
|
|
747
|
-
justifyContent: 'space-between',
|
|
748
|
-
marginBottom: 2
|
|
749
|
-
},
|
|
750
|
-
firstSettingItem: {
|
|
751
|
-
borderTopLeftRadius: 24,
|
|
752
|
-
borderTopRightRadius: 24
|
|
753
|
-
},
|
|
754
|
-
lastSettingItem: {
|
|
755
|
-
borderBottomLeftRadius: 24,
|
|
756
|
-
borderBottomRightRadius: 24,
|
|
757
|
-
marginBottom: 8
|
|
758
|
-
},
|
|
759
|
-
settingInfo: {
|
|
760
|
-
flexDirection: 'row',
|
|
761
|
-
alignItems: 'center',
|
|
762
|
-
flex: 1
|
|
763
|
-
},
|
|
764
|
-
settingIcon: {
|
|
765
|
-
marginRight: 12
|
|
766
|
-
},
|
|
767
|
-
settingLabel: {
|
|
768
|
-
fontSize: 16,
|
|
769
|
-
fontWeight: '500',
|
|
770
|
-
color: '#333',
|
|
771
|
-
marginBottom: 2
|
|
772
|
-
},
|
|
773
|
-
settingDescription: {
|
|
774
|
-
fontSize: 14,
|
|
775
|
-
color: '#666'
|
|
776
|
-
},
|
|
777
426
|
userIcon: {
|
|
778
427
|
marginRight: 12
|
|
779
428
|
},
|
|
@@ -806,10 +455,6 @@ const styles = StyleSheet.create({
|
|
|
806
455
|
fontSize: 18,
|
|
807
456
|
fontWeight: 'bold'
|
|
808
457
|
},
|
|
809
|
-
signOutButton: {
|
|
810
|
-
borderWidth: 1,
|
|
811
|
-
borderColor: '#ff4757'
|
|
812
|
-
},
|
|
813
458
|
message: {
|
|
814
459
|
fontSize: 16,
|
|
815
460
|
textAlign: 'center',
|