react-native-inapp-inspector 1.1.34 → 1.1.35
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/dist/commonjs/components/ConsoleLogCard.js +57 -56
- package/dist/commonjs/components/CopyButton.js +7 -1
- package/dist/commonjs/components/Inspector/BundleTab.js +19 -19
- package/dist/commonjs/components/Inspector/CrashDetail.js +16 -12
- package/dist/commonjs/components/Inspector/InspectorHeader.js +16 -16
- package/dist/commonjs/components/Inspector/MainScreen.js +6 -2
- package/dist/commonjs/components/Inspector/NetworkTab.js +97 -1
- package/dist/commonjs/components/Inspector/ReduxDetail.js +24 -19
- package/dist/commonjs/components/Inspector/ReduxTab.js +12 -8
- package/dist/commonjs/components/Inspector/SettingsPanel.js +1243 -673
- package/dist/commonjs/components/LogCard.js +27 -9
- package/dist/commonjs/components/MetaAccordion.js +42 -0
- package/dist/commonjs/components/NetworkIcons.d.ts +9 -0
- package/dist/commonjs/components/NetworkIcons.js +48 -1
- package/dist/commonjs/components/Toast.js +3 -3
- package/dist/commonjs/components/TouchableScale.d.ts +4 -2
- package/dist/commonjs/components/TouchableScale.js +4 -4
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -1
- package/dist/commonjs/customHooks/analyticsLogger.d.ts +2 -0
- package/dist/commonjs/customHooks/analyticsLogger.js +10 -1
- package/dist/commonjs/customHooks/bundleAnalyzer.d.ts +2 -0
- package/dist/commonjs/customHooks/bundleAnalyzer.js +26 -17
- package/dist/commonjs/customHooks/consoleLogger.d.ts +2 -0
- package/dist/commonjs/customHooks/consoleLogger.js +10 -1
- package/dist/commonjs/customHooks/crashHandler.d.ts +2 -0
- package/dist/commonjs/customHooks/crashHandler.js +10 -1
- package/dist/commonjs/customHooks/networkLogger.d.ts +2 -0
- package/dist/commonjs/customHooks/networkLogger.js +12 -1
- package/dist/commonjs/customHooks/performanceTracker.d.ts +3 -1
- package/dist/commonjs/customHooks/performanceTracker.js +18 -4
- package/dist/commonjs/customHooks/reduxLogger.d.ts +2 -0
- package/dist/commonjs/customHooks/reduxLogger.js +10 -1
- package/dist/commonjs/i18n/locales/en.json +96 -28
- package/dist/commonjs/index.js +78 -34
- package/dist/commonjs/styles/AppColors.d.ts +28 -0
- package/dist/commonjs/styles/AppColors.js +30 -0
- package/dist/esm/components/ConsoleLogCard.js +58 -57
- package/dist/esm/components/CopyButton.js +7 -1
- package/dist/esm/components/Inspector/BundleTab.js +19 -19
- package/dist/esm/components/Inspector/CrashDetail.js +16 -12
- package/dist/esm/components/Inspector/InspectorHeader.js +16 -16
- package/dist/esm/components/Inspector/MainScreen.js +6 -2
- package/dist/esm/components/Inspector/NetworkTab.js +99 -3
- package/dist/esm/components/Inspector/ReduxDetail.js +24 -19
- package/dist/esm/components/Inspector/ReduxTab.js +12 -8
- package/dist/esm/components/Inspector/SettingsPanel.js +1246 -676
- package/dist/esm/components/LogCard.js +27 -9
- package/dist/esm/components/MetaAccordion.js +42 -0
- package/dist/esm/components/NetworkIcons.d.ts +9 -0
- package/dist/esm/components/NetworkIcons.js +38 -0
- package/dist/esm/components/Toast.js +3 -3
- package/dist/esm/components/TouchableScale.d.ts +4 -2
- package/dist/esm/components/TouchableScale.js +4 -4
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/customHooks/analyticsLogger.d.ts +2 -0
- package/dist/esm/customHooks/analyticsLogger.js +7 -0
- package/dist/esm/customHooks/bundleAnalyzer.d.ts +2 -0
- package/dist/esm/customHooks/bundleAnalyzer.js +23 -16
- package/dist/esm/customHooks/consoleLogger.d.ts +2 -0
- package/dist/esm/customHooks/consoleLogger.js +7 -0
- package/dist/esm/customHooks/crashHandler.d.ts +2 -0
- package/dist/esm/customHooks/crashHandler.js +7 -0
- package/dist/esm/customHooks/networkLogger.d.ts +2 -0
- package/dist/esm/customHooks/networkLogger.js +9 -0
- package/dist/esm/customHooks/performanceTracker.d.ts +3 -1
- package/dist/esm/customHooks/performanceTracker.js +15 -3
- package/dist/esm/customHooks/reduxLogger.d.ts +2 -0
- package/dist/esm/customHooks/reduxLogger.js +7 -0
- package/dist/esm/i18n/locales/en.json +96 -28
- package/dist/esm/index.js +64 -20
- package/dist/esm/styles/AppColors.d.ts +28 -0
- package/dist/esm/styles/AppColors.js +30 -0
- package/package.json +3 -2
|
@@ -36,7 +36,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
const react_1 =
|
|
39
|
+
const react_1 = __importStar(require("react"));
|
|
40
40
|
const react_native_1 = require("react-native");
|
|
41
41
|
const react_native_svg_1 = __importStar(require("react-native-svg"));
|
|
42
42
|
const react_native_linear_gradient_1 = __importDefault(require("react-native-linear-gradient"));
|
|
@@ -51,6 +51,8 @@ const networkLogger_1 = require("../../customHooks/networkLogger");
|
|
|
51
51
|
const consoleLogger_1 = require("../../customHooks/consoleLogger");
|
|
52
52
|
const analyticsLogger_1 = require("../../customHooks/analyticsLogger");
|
|
53
53
|
const crashHandler_1 = require("../../customHooks/crashHandler");
|
|
54
|
+
const bundleAnalyzer_1 = require("../../customHooks/bundleAnalyzer");
|
|
55
|
+
const performanceTracker_1 = require("../../customHooks/performanceTracker");
|
|
54
56
|
const reduxLogger_1 = require("../../customHooks/reduxLogger");
|
|
55
57
|
const analyticsLogger_2 = require("../../customHooks/analyticsLogger");
|
|
56
58
|
const i18n_1 = require("../../i18n");
|
|
@@ -59,23 +61,113 @@ const SettingsPanel = () => {
|
|
|
59
61
|
const { t } = (0, i18n_1.useTranslation)();
|
|
60
62
|
const { settingsPage, setSettingsPage, settingsActiveSubTab, setSettingsActiveSubTab, tabVisibility, toggleTabVisibility, defaultTab, setDefaultTab, isDark, setIsDark, modalHeightPercent, setModalHeightPercent, modalAnimationType, setModalAnimationType, showDuplicateLogs, setShowDuplicateLogs, showConsoleLevels, setShowConsoleLevels, resetToDefaults, storage, logs, consoleLogs, analyticsEvents, reduxState, maxNetworkLogs, setMaxNetworkLogs, maxConsoleLogs, setMaxConsoleLogs, reduxAutoRefresh, setReduxAutoRefreshState, reduxExpandDepth, setReduxExpandDepth, switchActiveTab, setSelected, setSelectedEvent, setReduxState, crashRecords, maxCrashLogs, setMaxCrashLogs, } = (0, InspectorContext_1.useInspector)();
|
|
61
63
|
const isPersistent = (0, settingsStore_1.isPersistentStorageAvailable)();
|
|
62
|
-
|
|
64
|
+
// Safe Area & Status Bar Padding for All Device Form Factors
|
|
65
|
+
const statusBarHeight = react_native_1.Platform.OS === 'android' ? react_native_1.StatusBar.currentHeight || 24 : 44;
|
|
66
|
+
const headerTopPadding = modalHeightPercent >= 95 ? statusBarHeight : 0;
|
|
67
|
+
const allModules = [
|
|
68
|
+
{
|
|
69
|
+
key: 'apis',
|
|
70
|
+
label: 'APIs (Network)',
|
|
71
|
+
category: 'core',
|
|
72
|
+
icon: 'apis',
|
|
73
|
+
desc: 'HTTP/HTTPS requests, GraphQL, Axios & WebSocket inspector',
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
key: 'logs',
|
|
77
|
+
label: 'Console Logs',
|
|
78
|
+
category: 'core',
|
|
79
|
+
icon: 'logs',
|
|
80
|
+
desc: 'Terminal console logs, warnings, errors & stack traces',
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
key: 'performance',
|
|
84
|
+
label: 'Performance Tracker',
|
|
85
|
+
category: 'diagnostic',
|
|
86
|
+
icon: 'performance',
|
|
87
|
+
desc: '60 FPS monitor, Hermes memory telemetry & re-render profiler',
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
key: 'bundle',
|
|
91
|
+
label: 'Bundle Analyzer',
|
|
92
|
+
category: 'diagnostic',
|
|
93
|
+
icon: 'bundle',
|
|
94
|
+
desc: 'Metro packager dependencies, source maps & asset breakdown',
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
key: 'crash',
|
|
98
|
+
label: 'Crash Protection',
|
|
99
|
+
category: 'diagnostic',
|
|
100
|
+
icon: 'crash',
|
|
101
|
+
desc: 'Runtime exception guard, breadcrumbs & memory snapshot',
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
key: 'analytics',
|
|
105
|
+
label: 'Analytics Logger',
|
|
106
|
+
category: 'telemetry',
|
|
107
|
+
icon: 'analytics',
|
|
108
|
+
desc: 'Firebase & custom analytics events, user properties & params',
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
key: 'redux',
|
|
112
|
+
label: 'Redux Inspector',
|
|
113
|
+
category: 'telemetry',
|
|
114
|
+
icon: 'redux',
|
|
115
|
+
desc: 'Store state diffing, action history & reducer timeline',
|
|
116
|
+
},
|
|
117
|
+
];
|
|
118
|
+
// Staged selection state for checkboxes before clicking "Save Changes"
|
|
119
|
+
const [stagedTabVisibility, setStagedTabVisibility] = (0, react_1.useState)(() => ({
|
|
120
|
+
apis: true,
|
|
121
|
+
logs: Boolean(tabVisibility?.logs),
|
|
122
|
+
analytics: Boolean(tabVisibility?.analytics),
|
|
123
|
+
redux: Boolean(tabVisibility?.redux),
|
|
124
|
+
bundle: Boolean(tabVisibility?.bundle),
|
|
125
|
+
performance: Boolean(tabVisibility?.performance),
|
|
126
|
+
crash: Boolean(tabVisibility?.crash),
|
|
127
|
+
}));
|
|
128
|
+
// Synchronize staged state with tabVisibility when tabVisibility updates
|
|
129
|
+
(0, react_1.useEffect)(() => {
|
|
130
|
+
setStagedTabVisibility({
|
|
131
|
+
apis: true,
|
|
132
|
+
logs: Boolean(tabVisibility?.logs),
|
|
133
|
+
analytics: Boolean(tabVisibility?.analytics),
|
|
134
|
+
redux: Boolean(tabVisibility?.redux),
|
|
135
|
+
bundle: Boolean(tabVisibility?.bundle),
|
|
136
|
+
performance: Boolean(tabVisibility?.performance),
|
|
137
|
+
crash: Boolean(tabVisibility?.crash),
|
|
138
|
+
});
|
|
139
|
+
}, [tabVisibility]);
|
|
140
|
+
const hasUnsavedChanges = (0, react_1.useMemo)(() => {
|
|
141
|
+
return allModules.some(m => Boolean(stagedTabVisibility[m.key]) !==
|
|
142
|
+
Boolean(tabVisibility?.[m.key]));
|
|
143
|
+
}, [stagedTabVisibility, tabVisibility, allModules]);
|
|
144
|
+
const stagedActiveCount = allModules.filter(m => m.key === 'apis' || Boolean(stagedTabVisibility[m.key])).length;
|
|
145
|
+
const handleSaveChanges = () => {
|
|
146
|
+
(0, InspectorContext_1.animateNextLayout)();
|
|
147
|
+
allModules.forEach(m => {
|
|
148
|
+
if (m.key !== 'apis') {
|
|
149
|
+
const isStagedOn = Boolean(stagedTabVisibility[m.key]);
|
|
150
|
+
const isCurrentOn = Boolean(tabVisibility?.[m.key]);
|
|
151
|
+
if (isStagedOn !== isCurrentOn) {
|
|
152
|
+
toggleTabVisibility(m.key);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
react_native_1.Alert.alert(t('settings.settingsSaved'), t('settings.settingsSavedDesc'));
|
|
157
|
+
};
|
|
63
158
|
if (settingsPage === 'main') {
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
{ key: 'bundle', label: 'Bundle', icon: 'bundle' },
|
|
70
|
-
{ key: 'performance', label: 'Performance', icon: 'performance' },
|
|
71
|
-
{ key: 'crash', label: 'Crash', icon: 'crash' },
|
|
72
|
-
];
|
|
73
|
-
return (<react_native_1.View style={{ flex: 1, backgroundColor: AppColors_1.AppColors.grayBackground }}>
|
|
74
|
-
{/* Settings Header with back button */}
|
|
159
|
+
return (<react_native_1.View style={{
|
|
160
|
+
flex: 1,
|
|
161
|
+
backgroundColor: AppColors_1.AppColors.grayBackground,
|
|
162
|
+
}}>
|
|
163
|
+
{/* Modern Floating Gradient Header */}
|
|
75
164
|
<react_native_linear_gradient_1.default colors={[AppColors_1.AppColors.purple, AppColors_1.AppColors.brandPurple]} start={{ x: 0, y: 0 }} end={{ x: 1, y: 0 }} style={styles_1.default.headerGradient}>
|
|
76
165
|
<react_native_1.View style={{ paddingTop: headerTopPadding, width: '100%' }}>
|
|
77
|
-
<react_native_1.View style={[
|
|
78
|
-
|
|
166
|
+
<react_native_1.View style={[
|
|
167
|
+
styles_1.default.header,
|
|
168
|
+
{ paddingHorizontal: 16, paddingVertical: 12, gap: 12 },
|
|
169
|
+
]}>
|
|
170
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="button" accessibilityLabel={t('settings.back')} onPress={() => {
|
|
79
171
|
(0, InspectorContext_1.animateNextLayout)();
|
|
80
172
|
setSettingsPage(null);
|
|
81
173
|
switchActiveTab('apis');
|
|
@@ -84,223 +176,360 @@ const SettingsPanel = () => {
|
|
|
84
176
|
borderRadius: 10,
|
|
85
177
|
backgroundColor: `${AppColors_1.AppColors.white}26`,
|
|
86
178
|
borderWidth: 1,
|
|
87
|
-
borderColor: `${AppColors_1.AppColors.white}
|
|
179
|
+
borderColor: `${AppColors_1.AppColors.white}18`,
|
|
88
180
|
}}>
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
<react_native_1.
|
|
181
|
+
<NetworkIcons_1.WhiteBackNavigation color={AppColors_1.AppColors.white} size={16}/>
|
|
182
|
+
</TouchableScale_1.default>
|
|
183
|
+
|
|
184
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
185
|
+
<react_native_1.View style={{
|
|
186
|
+
flexDirection: 'row',
|
|
187
|
+
alignItems: 'center',
|
|
188
|
+
gap: 8,
|
|
189
|
+
}}>
|
|
190
|
+
<react_native_1.Text style={{
|
|
93
191
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
94
192
|
fontSize: 17,
|
|
95
193
|
color: AppColors_1.AppColors.white,
|
|
194
|
+
letterSpacing: -0.3,
|
|
195
|
+
lineHeight: 22,
|
|
96
196
|
}}>
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
197
|
+
{t('settings.mainTitle')}
|
|
198
|
+
</react_native_1.Text>
|
|
199
|
+
<react_native_1.View style={{
|
|
200
|
+
backgroundColor: `${AppColors_1.AppColors.white}26`,
|
|
201
|
+
paddingHorizontal: 7,
|
|
202
|
+
paddingVertical: 2,
|
|
203
|
+
borderRadius: 12,
|
|
204
|
+
}}>
|
|
205
|
+
<react_native_1.Text style={{
|
|
206
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
207
|
+
fontSize: 10,
|
|
208
|
+
color: AppColors_1.AppColors.white,
|
|
209
|
+
lineHeight: 13,
|
|
210
|
+
}}>
|
|
211
|
+
{stagedActiveCount}/{allModules.length} Active
|
|
212
|
+
</react_native_1.Text>
|
|
213
|
+
</react_native_1.View>
|
|
214
|
+
</react_native_1.View>
|
|
215
|
+
<react_native_1.Text style={{
|
|
100
216
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
101
217
|
fontSize: 11,
|
|
102
|
-
color: `${AppColors_1.AppColors.white}
|
|
103
|
-
marginTop:
|
|
218
|
+
color: `${AppColors_1.AppColors.white}CC`,
|
|
219
|
+
marginTop: 2,
|
|
220
|
+
lineHeight: 15,
|
|
104
221
|
}}>
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
222
|
+
{t('settings.mainSubtitle')}
|
|
223
|
+
</react_native_1.Text>
|
|
224
|
+
</react_native_1.View>
|
|
225
|
+
|
|
226
|
+
<react_native_1.View style={{
|
|
227
|
+
backgroundColor: `${AppColors_1.AppColors.white}22`,
|
|
110
228
|
paddingHorizontal: 8,
|
|
111
229
|
paddingVertical: 4,
|
|
112
230
|
borderRadius: 8,
|
|
113
231
|
borderWidth: 1,
|
|
114
232
|
borderColor: `${AppColors_1.AppColors.white}1A`,
|
|
115
233
|
}}>
|
|
116
|
-
|
|
234
|
+
<react_native_1.Text style={{
|
|
117
235
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
118
236
|
fontSize: 10.5,
|
|
119
237
|
color: AppColors_1.AppColors.white,
|
|
238
|
+
lineHeight: 14,
|
|
120
239
|
}}>
|
|
121
|
-
|
|
122
|
-
|
|
240
|
+
v{constants_1.LIB_VERSION}
|
|
241
|
+
</react_native_1.Text>
|
|
242
|
+
</react_native_1.View>
|
|
123
243
|
</react_native_1.View>
|
|
124
244
|
</react_native_1.View>
|
|
125
|
-
</
|
|
126
|
-
</react_native_linear_gradient_1.default>
|
|
245
|
+
</react_native_linear_gradient_1.default>
|
|
127
246
|
|
|
128
|
-
<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap:
|
|
129
|
-
{/* Sub
|
|
247
|
+
<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 14 }} showsVerticalScrollIndicator={false}>
|
|
248
|
+
{/* Segmented Top Navigation Sub-Tabs */}
|
|
130
249
|
<react_native_1.View style={{
|
|
131
250
|
flexDirection: 'row',
|
|
132
251
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
133
|
-
borderRadius:
|
|
134
|
-
padding:
|
|
252
|
+
borderRadius: 12,
|
|
253
|
+
padding: 4,
|
|
135
254
|
borderWidth: 1,
|
|
136
255
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
137
|
-
|
|
256
|
+
shadowColor: AppColors_1.AppColors.black,
|
|
257
|
+
shadowOpacity: 0.04,
|
|
258
|
+
shadowRadius: 4,
|
|
259
|
+
shadowOffset: { width: 0, height: 2 },
|
|
138
260
|
}}>
|
|
139
|
-
<
|
|
261
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="tab" accessibilityLabel={t('settings.modulesAndTools')} accessibilityState={{ selected: settingsActiveSubTab === 'module' }} onPress={() => {
|
|
140
262
|
(0, InspectorContext_1.animateNextLayout)();
|
|
141
263
|
setSettingsActiveSubTab('module');
|
|
142
264
|
}} style={{
|
|
143
265
|
flex: 1,
|
|
144
|
-
paddingVertical:
|
|
266
|
+
paddingVertical: 9,
|
|
267
|
+
flexDirection: 'row',
|
|
145
268
|
alignItems: 'center',
|
|
146
269
|
justifyContent: 'center',
|
|
147
|
-
|
|
270
|
+
gap: 6,
|
|
271
|
+
borderRadius: 9,
|
|
148
272
|
backgroundColor: settingsActiveSubTab === 'module'
|
|
149
273
|
? AppColors_1.AppColors.purple
|
|
150
274
|
: 'transparent',
|
|
151
275
|
}}>
|
|
276
|
+
<NetworkIcons_1.LayersIcon color={settingsActiveSubTab === 'module'
|
|
277
|
+
? AppColors_1.AppColors.white
|
|
278
|
+
: AppColors_1.AppColors.grayText} size={13}/>
|
|
152
279
|
<react_native_1.Text style={{
|
|
153
280
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
154
|
-
fontSize: 12,
|
|
281
|
+
fontSize: 12.5,
|
|
282
|
+
lineHeight: 16,
|
|
155
283
|
color: settingsActiveSubTab === 'module'
|
|
156
284
|
? AppColors_1.AppColors.white
|
|
157
285
|
: AppColors_1.AppColors.grayText,
|
|
158
286
|
}}>
|
|
159
|
-
|
|
287
|
+
{t('settings.modulesAndTools')}
|
|
160
288
|
</react_native_1.Text>
|
|
161
|
-
</
|
|
162
|
-
|
|
289
|
+
</TouchableScale_1.default>
|
|
290
|
+
|
|
291
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="tab" accessibilityLabel={t('settings.uiPreferences')} accessibilityState={{ selected: settingsActiveSubTab === 'ui' }} onPress={() => {
|
|
163
292
|
(0, InspectorContext_1.animateNextLayout)();
|
|
164
293
|
setSettingsActiveSubTab('ui');
|
|
165
294
|
}} style={{
|
|
166
295
|
flex: 1,
|
|
167
|
-
paddingVertical:
|
|
296
|
+
paddingVertical: 9,
|
|
297
|
+
flexDirection: 'row',
|
|
168
298
|
alignItems: 'center',
|
|
169
299
|
justifyContent: 'center',
|
|
170
|
-
|
|
300
|
+
gap: 6,
|
|
301
|
+
borderRadius: 9,
|
|
171
302
|
backgroundColor: settingsActiveSubTab === 'ui'
|
|
172
303
|
? AppColors_1.AppColors.purple
|
|
173
304
|
: 'transparent',
|
|
174
305
|
}}>
|
|
306
|
+
<NetworkIcons_1.ScreenIcon color={settingsActiveSubTab === 'ui'
|
|
307
|
+
? AppColors_1.AppColors.white
|
|
308
|
+
: AppColors_1.AppColors.grayText} size={13}/>
|
|
175
309
|
<react_native_1.Text style={{
|
|
176
310
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
177
|
-
fontSize: 12,
|
|
311
|
+
fontSize: 12.5,
|
|
312
|
+
lineHeight: 16,
|
|
178
313
|
color: settingsActiveSubTab === 'ui'
|
|
179
314
|
? AppColors_1.AppColors.white
|
|
180
315
|
: AppColors_1.AppColors.grayText,
|
|
181
316
|
}}>
|
|
182
|
-
|
|
317
|
+
{t('settings.uiPreferences')}
|
|
183
318
|
</react_native_1.Text>
|
|
184
|
-
</
|
|
319
|
+
</TouchableScale_1.default>
|
|
185
320
|
</react_native_1.View>
|
|
186
321
|
|
|
187
|
-
{settingsActiveSubTab === 'module' ? (
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
backgroundColor: AppColors_1.AppColors.
|
|
322
|
+
{settingsActiveSubTab === 'module' ? (<react_native_1.View style={{ gap: 12 }}>
|
|
323
|
+
{/* Performance Advisory Banner */}
|
|
324
|
+
<react_native_1.View style={{
|
|
325
|
+
backgroundColor: `${AppColors_1.AppColors.purple}0A`,
|
|
191
326
|
borderRadius: 12,
|
|
327
|
+
padding: 12,
|
|
192
328
|
borderWidth: 1,
|
|
193
|
-
borderColor: AppColors_1.AppColors.
|
|
194
|
-
overflow: 'hidden',
|
|
195
|
-
}}>
|
|
196
|
-
{/* Table Header */}
|
|
197
|
-
<react_native_1.View style={{
|
|
329
|
+
borderColor: `${AppColors_1.AppColors.purple}20`,
|
|
198
330
|
flexDirection: 'row',
|
|
199
331
|
alignItems: 'center',
|
|
200
|
-
|
|
201
|
-
paddingHorizontal: 14,
|
|
202
|
-
backgroundColor: AppColors_1.AppColors.grayBackground,
|
|
203
|
-
borderBottomWidth: 1,
|
|
204
|
-
borderBottomColor: AppColors_1.AppColors.dividerColor,
|
|
205
|
-
gap: 12,
|
|
332
|
+
gap: 10,
|
|
206
333
|
}}>
|
|
207
|
-
<react_native_1.
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
334
|
+
<react_native_1.View style={{
|
|
335
|
+
width: 32,
|
|
336
|
+
height: 32,
|
|
337
|
+
borderRadius: 8,
|
|
338
|
+
backgroundColor: `${AppColors_1.AppColors.purple}14`,
|
|
339
|
+
alignItems: 'center',
|
|
340
|
+
justifyContent: 'center',
|
|
213
341
|
}}>
|
|
214
|
-
|
|
215
|
-
</react_native_1.
|
|
216
|
-
<react_native_1.
|
|
342
|
+
<NetworkIcons_1.SignalIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
343
|
+
</react_native_1.View>
|
|
344
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
345
|
+
<react_native_1.Text style={{
|
|
217
346
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
218
|
-
fontSize:
|
|
219
|
-
color: AppColors_1.AppColors.
|
|
220
|
-
|
|
221
|
-
width: 90,
|
|
222
|
-
textAlign: 'right',
|
|
223
|
-
paddingRight: 4,
|
|
347
|
+
fontSize: 12,
|
|
348
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
349
|
+
lineHeight: 16,
|
|
224
350
|
}}>
|
|
225
|
-
|
|
226
|
-
|
|
351
|
+
{t('settings.zeroOverheadTitle')}
|
|
352
|
+
</react_native_1.Text>
|
|
353
|
+
<react_native_1.Text style={{
|
|
354
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
355
|
+
fontSize: 10.5,
|
|
356
|
+
color: AppColors_1.AppColors.grayText,
|
|
357
|
+
marginTop: 2,
|
|
358
|
+
lineHeight: 14,
|
|
359
|
+
}}>
|
|
360
|
+
{t('settings.zeroOverheadDesc')}
|
|
361
|
+
</react_native_1.Text>
|
|
362
|
+
</react_native_1.View>
|
|
227
363
|
</react_native_1.View>
|
|
228
364
|
|
|
229
|
-
{
|
|
365
|
+
{/* Enhanced Individual Module Cards with Decorative Checkboxes */}
|
|
366
|
+
<react_native_1.View style={{ gap: 10 }}>
|
|
367
|
+
{allModules.map(moduleItem => {
|
|
230
368
|
const isReduxAvail = (0, reduxLogger_1.isReduxConnected)();
|
|
231
369
|
const isAnalyticsAvail = (0, analyticsLogger_2.isAnalyticsConnected)();
|
|
232
|
-
const isUnavailable = (
|
|
233
|
-
(
|
|
234
|
-
const isLocked =
|
|
235
|
-
const
|
|
236
|
-
(Boolean(
|
|
237
|
-
|
|
238
|
-
|
|
370
|
+
const isUnavailable = (moduleItem.key === 'redux' && !isReduxAvail) ||
|
|
371
|
+
(moduleItem.key === 'analytics' && !isAnalyticsAvail);
|
|
372
|
+
const isLocked = moduleItem.key === 'apis' || isUnavailable;
|
|
373
|
+
const isChecked = moduleItem.key === 'apis' ||
|
|
374
|
+
(Boolean(stagedTabVisibility?.[moduleItem.key]) &&
|
|
375
|
+
!isUnavailable);
|
|
376
|
+
const liveStats = moduleItem.key === 'apis'
|
|
377
|
+
? `${logs.length} requests • Limit: ${maxNetworkLogs}`
|
|
378
|
+
: moduleItem.key === 'logs'
|
|
379
|
+
? `${consoleLogs.length} logs • Limit: ${maxConsoleLogs}`
|
|
380
|
+
: moduleItem.key === 'performance'
|
|
381
|
+
? '60 FPS Target • Memory Telemetry'
|
|
382
|
+
: moduleItem.key === 'bundle'
|
|
383
|
+
? 'Metro Packager • Dependency Map'
|
|
384
|
+
: moduleItem.key === 'crash'
|
|
385
|
+
? `${crashRecords?.length || 0} crashes recorded • Crash Guard`
|
|
386
|
+
: moduleItem.key === 'analytics'
|
|
387
|
+
? `${analyticsEvents.length} events logged`
|
|
388
|
+
: moduleItem.key === 'redux'
|
|
389
|
+
? `${Object.keys(reduxState || {}).length} slices • Depth: ${reduxExpandDepth}`
|
|
390
|
+
: '';
|
|
391
|
+
return (<react_native_1.View key={moduleItem.key} style={{
|
|
392
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
393
|
+
borderRadius: 14,
|
|
394
|
+
borderWidth: 1.5,
|
|
395
|
+
borderColor: isChecked
|
|
396
|
+
? `${AppColors_1.AppColors.purple}38`
|
|
397
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
398
|
+
padding: 14,
|
|
399
|
+
gap: 10,
|
|
400
|
+
shadowColor: AppColors_1.AppColors.black,
|
|
401
|
+
shadowOpacity: isChecked ? 0.04 : 0.02,
|
|
402
|
+
shadowRadius: 5,
|
|
403
|
+
shadowOffset: { width: 0, height: 2 },
|
|
404
|
+
}}>
|
|
405
|
+
{/* Top Row: Icon + Title & Badges + Checkbox */}
|
|
406
|
+
<react_native_1.View style={{
|
|
239
407
|
flexDirection: 'row',
|
|
240
|
-
alignItems: '
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
borderBottomWidth: isLast ? 0 : 1,
|
|
244
|
-
borderBottomColor: AppColors_1.AppColors.dividerColor,
|
|
245
|
-
gap: 12,
|
|
408
|
+
alignItems: 'flex-start',
|
|
409
|
+
justifyContent: 'space-between',
|
|
410
|
+
gap: 10,
|
|
246
411
|
}}>
|
|
247
|
-
|
|
248
|
-
|
|
412
|
+
{/* Tap Zone for Details/Settings */}
|
|
413
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="button" accessibilityLabel={`${moduleItem.label} settings`} disabled={isUnavailable} onPress={() => {
|
|
414
|
+
(0, InspectorContext_1.animateNextLayout)();
|
|
415
|
+
setSettingsPage(moduleItem.key);
|
|
416
|
+
}} style={{
|
|
249
417
|
flex: 1,
|
|
250
418
|
flexDirection: 'row',
|
|
251
|
-
alignItems: '
|
|
252
|
-
gap:
|
|
253
|
-
flexWrap: 'wrap',
|
|
419
|
+
alignItems: 'flex-start',
|
|
420
|
+
gap: 10,
|
|
254
421
|
}}>
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
width:
|
|
258
|
-
height:
|
|
259
|
-
borderRadius:
|
|
422
|
+
{/* Icon Tile */}
|
|
423
|
+
<react_native_1.View style={{
|
|
424
|
+
width: 36,
|
|
425
|
+
height: 36,
|
|
426
|
+
borderRadius: 10,
|
|
260
427
|
backgroundColor: isLocked
|
|
261
|
-
? AppColors_1.AppColors.grayBorderSecondary
|
|
262
|
-
:
|
|
428
|
+
? `${AppColors_1.AppColors.grayBorderSecondary}4D`
|
|
429
|
+
: isChecked
|
|
430
|
+
? `${AppColors_1.AppColors.purple}14`
|
|
431
|
+
: AppColors_1.AppColors.grayBackground,
|
|
263
432
|
borderWidth: 1,
|
|
264
433
|
borderColor: isLocked
|
|
265
434
|
? AppColors_1.AppColors.dividerColor
|
|
266
|
-
:
|
|
435
|
+
: isChecked
|
|
436
|
+
? `${AppColors_1.AppColors.purple}33`
|
|
437
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
267
438
|
alignItems: 'center',
|
|
268
439
|
justifyContent: 'center',
|
|
440
|
+
marginTop: 1,
|
|
269
441
|
}}>
|
|
270
|
-
|
|
271
|
-
? AppColors_1.AppColors.
|
|
272
|
-
: AppColors_1.AppColors.
|
|
273
|
-
|
|
274
|
-
? AppColors_1.AppColors.
|
|
275
|
-
: AppColors_1.AppColors.
|
|
276
|
-
|
|
277
|
-
? AppColors_1.AppColors.
|
|
278
|
-
: AppColors_1.AppColors.
|
|
279
|
-
|
|
280
|
-
? AppColors_1.AppColors.
|
|
281
|
-
: AppColors_1.AppColors.
|
|
282
|
-
|
|
283
|
-
? AppColors_1.AppColors.
|
|
284
|
-
: AppColors_1.AppColors.
|
|
285
|
-
|
|
286
|
-
? AppColors_1.AppColors.
|
|
287
|
-
: AppColors_1.AppColors.
|
|
288
|
-
|
|
289
|
-
? AppColors_1.AppColors.
|
|
290
|
-
: AppColors_1.AppColors.
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
442
|
+
{moduleItem.icon === 'apis' && (<NetworkIcons_1.SignalIcon color={isChecked
|
|
443
|
+
? AppColors_1.AppColors.purple
|
|
444
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
445
|
+
{moduleItem.icon === 'logs' && (<NetworkIcons_1.TerminalIcon color={isChecked
|
|
446
|
+
? AppColors_1.AppColors.purple
|
|
447
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
448
|
+
{moduleItem.icon === 'performance' && (<NetworkIcons_1.PerformanceIcon color={isChecked
|
|
449
|
+
? AppColors_1.AppColors.purple
|
|
450
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
451
|
+
{moduleItem.icon === 'bundle' && (<NetworkIcons_1.PackageIcon color={isChecked
|
|
452
|
+
? AppColors_1.AppColors.purple
|
|
453
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
454
|
+
{moduleItem.icon === 'crash' && (<NetworkIcons_1.CrashIcon color={isChecked
|
|
455
|
+
? AppColors_1.AppColors.purple
|
|
456
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
457
|
+
{moduleItem.icon === 'analytics' && (<NetworkIcons_1.AnalyticsIcon color={isChecked
|
|
458
|
+
? AppColors_1.AppColors.purple
|
|
459
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
460
|
+
{moduleItem.icon === 'redux' && (<NetworkIcons_1.ReduxIcon color={isChecked
|
|
461
|
+
? AppColors_1.AppColors.purple
|
|
462
|
+
: AppColors_1.AppColors.grayTextWeak} size={16}/>)}
|
|
463
|
+
</react_native_1.View>
|
|
464
|
+
|
|
465
|
+
{/* Titles & Status Pill */}
|
|
466
|
+
<react_native_1.View style={{ flex: 1, gap: 2 }}>
|
|
467
|
+
<react_native_1.View style={{
|
|
468
|
+
flexDirection: 'row',
|
|
469
|
+
alignItems: 'center',
|
|
470
|
+
gap: 6,
|
|
471
|
+
flexWrap: 'wrap',
|
|
472
|
+
}}>
|
|
473
|
+
<react_native_1.Text style={{
|
|
294
474
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
295
|
-
fontSize:
|
|
475
|
+
fontSize: 14,
|
|
476
|
+
lineHeight: 18,
|
|
296
477
|
color: isLocked
|
|
297
478
|
? AppColors_1.AppColors.grayText
|
|
298
479
|
: AppColors_1.AppColors.primaryBlack,
|
|
299
480
|
}}>
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
481
|
+
{moduleItem.label}
|
|
482
|
+
</react_native_1.Text>
|
|
483
|
+
|
|
484
|
+
{/* Default Startup Tab Badge */}
|
|
485
|
+
{moduleItem.key === defaultTab &&
|
|
486
|
+
!isUnavailable && (<react_native_1.View style={{
|
|
487
|
+
flexDirection: 'row',
|
|
488
|
+
alignItems: 'center',
|
|
489
|
+
backgroundColor: `${AppColors_1.AppColors.purple}14`,
|
|
490
|
+
borderRadius: 12,
|
|
491
|
+
paddingHorizontal: 5,
|
|
492
|
+
paddingVertical: 1.5,
|
|
493
|
+
borderWidth: 1,
|
|
494
|
+
borderColor: `${AppColors_1.AppColors.purple}2E`,
|
|
495
|
+
gap: 3,
|
|
496
|
+
}}>
|
|
497
|
+
<react_native_1.View style={{
|
|
498
|
+
width: 4,
|
|
499
|
+
height: 4,
|
|
500
|
+
borderRadius: 2,
|
|
501
|
+
backgroundColor: AppColors_1.AppColors.purple,
|
|
502
|
+
}}/>
|
|
503
|
+
<react_native_1.Text style={{
|
|
504
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
505
|
+
fontSize: 8,
|
|
506
|
+
lineHeight: 11,
|
|
507
|
+
color: AppColors_1.AppColors.purple,
|
|
508
|
+
letterSpacing: 0.4,
|
|
509
|
+
}}>
|
|
510
|
+
{t('settings.defaultBadge')}
|
|
511
|
+
</react_native_1.Text>
|
|
512
|
+
</react_native_1.View>)}
|
|
513
|
+
|
|
514
|
+
{/* Status Pill */}
|
|
515
|
+
{moduleItem.key === 'apis' ? (<react_native_1.View style={{
|
|
516
|
+
backgroundColor: `${AppColors_1.AppColors.blue500}14`,
|
|
517
|
+
borderRadius: 4,
|
|
518
|
+
paddingHorizontal: 5,
|
|
519
|
+
paddingVertical: 1.5,
|
|
520
|
+
borderWidth: 1,
|
|
521
|
+
borderColor: `${AppColors_1.AppColors.blue500}33`,
|
|
522
|
+
}}>
|
|
523
|
+
<react_native_1.Text style={{
|
|
524
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
525
|
+
fontSize: 8,
|
|
526
|
+
lineHeight: 11,
|
|
527
|
+
color: AppColors_1.AppColors.blue500,
|
|
528
|
+
letterSpacing: 0.3,
|
|
529
|
+
}}>
|
|
530
|
+
{t('settings.coreBadge')}
|
|
531
|
+
</react_native_1.Text>
|
|
532
|
+
</react_native_1.View>) : isUnavailable ? (<react_native_1.View style={{
|
|
304
533
|
backgroundColor: `${AppColors_1.AppColors.amber500}18`,
|
|
305
534
|
borderRadius: 4,
|
|
306
535
|
paddingHorizontal: 5,
|
|
@@ -308,181 +537,244 @@ const SettingsPanel = () => {
|
|
|
308
537
|
borderWidth: 1,
|
|
309
538
|
borderColor: `${AppColors_1.AppColors.amber500}35`,
|
|
310
539
|
}}>
|
|
311
|
-
|
|
540
|
+
<react_native_1.Text style={{
|
|
312
541
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
313
542
|
fontSize: 8,
|
|
543
|
+
lineHeight: 11,
|
|
314
544
|
color: AppColors_1.AppColors.amber700,
|
|
315
545
|
letterSpacing: 0.3,
|
|
316
546
|
}}>
|
|
317
|
-
|
|
547
|
+
{moduleItem.key === 'redux'
|
|
318
548
|
? t('settings.notConnectedBadge')
|
|
319
549
|
: t('settings.notDetectedBadge')}
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
backgroundColor: `${AppColors_1.AppColors.purple}14`,
|
|
327
|
-
borderRadius: 20,
|
|
328
|
-
paddingHorizontal: 6,
|
|
329
|
-
paddingVertical: 2,
|
|
550
|
+
</react_native_1.Text>
|
|
551
|
+
</react_native_1.View>) : isChecked ? (<react_native_1.View style={{
|
|
552
|
+
backgroundColor: `${AppColors_1.AppColors.liveGreen}18`,
|
|
553
|
+
borderRadius: 4,
|
|
554
|
+
paddingHorizontal: 5,
|
|
555
|
+
paddingVertical: 1.5,
|
|
330
556
|
borderWidth: 1,
|
|
331
|
-
borderColor: `${AppColors_1.AppColors.
|
|
332
|
-
gap: 3,
|
|
557
|
+
borderColor: `${AppColors_1.AppColors.liveGreen}38`,
|
|
333
558
|
}}>
|
|
334
|
-
|
|
335
|
-
width: 4,
|
|
336
|
-
height: 4,
|
|
337
|
-
borderRadius: 2,
|
|
338
|
-
backgroundColor: AppColors_1.AppColors.purple,
|
|
339
|
-
opacity: 0.7,
|
|
340
|
-
}}/>
|
|
341
|
-
<react_native_1.Text style={{
|
|
559
|
+
<react_native_1.Text style={{
|
|
342
560
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
343
|
-
fontSize: 8
|
|
344
|
-
|
|
345
|
-
|
|
561
|
+
fontSize: 8,
|
|
562
|
+
lineHeight: 11,
|
|
563
|
+
color: AppColors_1.AppColors.green700,
|
|
564
|
+
letterSpacing: 0.3,
|
|
346
565
|
}}>
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
setSettingsPage(tab.key);
|
|
355
|
-
}} hitSlop={8} style={{
|
|
356
|
-
marginLeft: 4,
|
|
357
|
-
padding: 4,
|
|
358
|
-
borderRadius: 6,
|
|
359
|
-
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
566
|
+
{t('settings.activeBadge')}
|
|
567
|
+
</react_native_1.Text>
|
|
568
|
+
</react_native_1.View>) : (<react_native_1.View style={{
|
|
569
|
+
backgroundColor: `${AppColors_1.AppColors.grayTextWeak}18`,
|
|
570
|
+
borderRadius: 4,
|
|
571
|
+
paddingHorizontal: 5,
|
|
572
|
+
paddingVertical: 1.5,
|
|
360
573
|
borderWidth: 1,
|
|
361
|
-
borderColor: `${AppColors_1.AppColors.
|
|
362
|
-
alignItems: 'center',
|
|
363
|
-
justifyContent: 'center',
|
|
574
|
+
borderColor: `${AppColors_1.AppColors.grayTextWeak}2E`,
|
|
364
575
|
}}>
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
576
|
+
<react_native_1.Text style={{
|
|
577
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
578
|
+
fontSize: 8,
|
|
579
|
+
lineHeight: 11,
|
|
580
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
581
|
+
letterSpacing: 0.3,
|
|
582
|
+
}}>
|
|
583
|
+
{t('settings.dormantBadge')}
|
|
584
|
+
</react_native_1.Text>
|
|
585
|
+
</react_native_1.View>)}
|
|
586
|
+
</react_native_1.View>
|
|
368
587
|
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
588
|
+
<react_native_1.Text style={{
|
|
589
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
590
|
+
fontSize: 11,
|
|
591
|
+
color: AppColors_1.AppColors.grayText,
|
|
592
|
+
lineHeight: 15,
|
|
593
|
+
marginTop: 1,
|
|
374
594
|
}}>
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
595
|
+
{moduleItem.desc}
|
|
596
|
+
</react_native_1.Text>
|
|
597
|
+
</react_native_1.View>
|
|
598
|
+
</TouchableScale_1.default>
|
|
599
|
+
|
|
600
|
+
{/* Decorative Custom Checkbox */}
|
|
601
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="checkbox" accessibilityLabel={`Select ${moduleItem.label}`} accessibilityState={{
|
|
602
|
+
checked: isChecked,
|
|
603
|
+
disabled: isLocked,
|
|
604
|
+
}} disabled={isLocked} onPress={() => {
|
|
605
|
+
if (isLocked)
|
|
606
|
+
return;
|
|
607
|
+
setStagedTabVisibility(prev => ({
|
|
608
|
+
...prev,
|
|
609
|
+
[moduleItem.key]: !prev[moduleItem.key],
|
|
610
|
+
}));
|
|
611
|
+
}} style={{
|
|
612
|
+
width: 26,
|
|
613
|
+
height: 26,
|
|
614
|
+
borderRadius: 8,
|
|
615
|
+
borderWidth: isChecked ? 0 : 2,
|
|
385
616
|
borderColor: isLocked
|
|
386
|
-
? AppColors_1.AppColors.
|
|
387
|
-
:
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
}}>
|
|
394
|
-
<react_native_1.View style={{
|
|
395
|
-
width: 18,
|
|
396
|
-
height: 18,
|
|
397
|
-
borderRadius: 9,
|
|
398
|
-
backgroundColor: isLocked
|
|
399
|
-
? AppColors_1.AppColors.grayBorderSecondary
|
|
400
|
-
: AppColors_1.AppColors.white,
|
|
617
|
+
? AppColors_1.AppColors.dividerColor
|
|
618
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
619
|
+
backgroundColor: moduleItem.key === 'apis'
|
|
620
|
+
? `${AppColors_1.AppColors.blue500}22`
|
|
621
|
+
: isChecked
|
|
622
|
+
? AppColors_1.AppColors.purple
|
|
623
|
+
: AppColors_1.AppColors.grayBackground,
|
|
401
624
|
alignItems: 'center',
|
|
402
625
|
justifyContent: 'center',
|
|
403
|
-
shadowColor:
|
|
404
|
-
|
|
405
|
-
|
|
626
|
+
shadowColor: isChecked
|
|
627
|
+
? AppColors_1.AppColors.purple
|
|
628
|
+
: 'transparent',
|
|
629
|
+
shadowOpacity: isChecked ? 0.3 : 0,
|
|
630
|
+
shadowRadius: 3,
|
|
406
631
|
shadowOffset: { width: 0, height: 1 },
|
|
632
|
+
elevation: isChecked ? 2 : 0,
|
|
407
633
|
}}>
|
|
408
|
-
{isLocked
|
|
634
|
+
{moduleItem.key === 'apis' ? (<NetworkIcons_1.CheckIcon size={14} color={AppColors_1.AppColors.blue500}/>) : isChecked ? (<NetworkIcons_1.CheckIcon size={14} color={AppColors_1.AppColors.white}/>) : isLocked ? (<react_native_svg_1.default width={10} height={10} viewBox="0 0 24 24" fill="none">
|
|
409
635
|
<react_native_svg_1.Path d="M7 10V7a5 5 0 0 1 10 0v3" stroke={AppColors_1.AppColors.grayText} strokeWidth="2.2" strokeLinecap="round"/>
|
|
410
636
|
<react_native_svg_1.Path d="M5 10h14v9a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1z" fill={AppColors_1.AppColors.grayText}/>
|
|
411
|
-
</react_native_svg_1.default>)}
|
|
412
|
-
</
|
|
413
|
-
</
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
637
|
+
</react_native_svg_1.default>) : null}
|
|
638
|
+
</TouchableScale_1.default>
|
|
639
|
+
</react_native_1.View>
|
|
640
|
+
|
|
641
|
+
{/* Card Footer: Live Stats + Configure Button */}
|
|
642
|
+
{!isUnavailable && (<react_native_1.View style={{
|
|
643
|
+
flexDirection: 'row',
|
|
644
|
+
alignItems: 'center',
|
|
645
|
+
justifyContent: 'space-between',
|
|
646
|
+
paddingTop: 8,
|
|
647
|
+
borderTopWidth: 1,
|
|
648
|
+
borderTopColor: AppColors_1.AppColors.dividerColor,
|
|
649
|
+
}}>
|
|
650
|
+
{/* Live Info Pill */}
|
|
651
|
+
<react_native_1.View style={{
|
|
652
|
+
flexDirection: 'row',
|
|
653
|
+
alignItems: 'center',
|
|
654
|
+
gap: 6,
|
|
655
|
+
flex: 1,
|
|
656
|
+
}}>
|
|
657
|
+
<react_native_1.View style={{
|
|
658
|
+
width: 6,
|
|
659
|
+
height: 6,
|
|
660
|
+
borderRadius: 3,
|
|
661
|
+
backgroundColor: isChecked
|
|
662
|
+
? AppColors_1.AppColors.liveGreen
|
|
419
663
|
: AppColors_1.AppColors.grayTextWeak,
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
664
|
+
}}/>
|
|
665
|
+
<react_native_1.Text style={{
|
|
666
|
+
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
667
|
+
fontSize: 11,
|
|
668
|
+
color: AppColors_1.AppColors.grayText,
|
|
669
|
+
lineHeight: 14,
|
|
423
670
|
}}>
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
671
|
+
{liveStats}
|
|
672
|
+
</react_native_1.Text>
|
|
673
|
+
</react_native_1.View>
|
|
674
|
+
|
|
675
|
+
{/* Sleek Configure Button */}
|
|
676
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="button" accessibilityLabel={`Configure ${moduleItem.label} settings`} onPress={() => {
|
|
677
|
+
(0, InspectorContext_1.animateNextLayout)();
|
|
678
|
+
setSettingsPage(moduleItem.key);
|
|
679
|
+
}} style={{
|
|
680
|
+
flexDirection: 'row',
|
|
681
|
+
alignItems: 'center',
|
|
682
|
+
gap: 5,
|
|
683
|
+
backgroundColor: `${AppColors_1.AppColors.purple}12`,
|
|
684
|
+
paddingHorizontal: 10,
|
|
685
|
+
paddingVertical: 5,
|
|
686
|
+
borderRadius: 8,
|
|
687
|
+
borderWidth: 1,
|
|
688
|
+
borderColor: `${AppColors_1.AppColors.purple}26`,
|
|
689
|
+
}}>
|
|
690
|
+
<NetworkIcons_1.SettingsIcon color={AppColors_1.AppColors.purple} size={11}/>
|
|
691
|
+
<react_native_1.Text style={{
|
|
692
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
693
|
+
fontSize: 11,
|
|
694
|
+
lineHeight: 14,
|
|
695
|
+
color: AppColors_1.AppColors.purple,
|
|
696
|
+
}}>
|
|
697
|
+
{t('settings.configure')}
|
|
698
|
+
</react_native_1.Text>
|
|
699
|
+
<NetworkIcons_1.ForwardChevronIcon color={AppColors_1.AppColors.purple} size={9}/>
|
|
700
|
+
</TouchableScale_1.default>
|
|
701
|
+
</react_native_1.View>)}
|
|
702
|
+
</react_native_1.View>);
|
|
430
703
|
})}
|
|
704
|
+
</react_native_1.View>
|
|
431
705
|
</react_native_1.View>) : (
|
|
432
|
-
/* UI Preferences
|
|
433
|
-
<react_native_1.View style={{
|
|
706
|
+
/* UI Preferences Subtab */
|
|
707
|
+
<react_native_1.View style={{ gap: 14 }}>
|
|
708
|
+
{/* Section 1: Appearance */}
|
|
709
|
+
<react_native_1.View style={{
|
|
434
710
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
435
|
-
borderRadius:
|
|
711
|
+
borderRadius: 14,
|
|
436
712
|
borderWidth: 1,
|
|
437
713
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
438
714
|
overflow: 'hidden',
|
|
439
|
-
|
|
440
|
-
<react_native_1.View style={{
|
|
441
|
-
flexDirection: 'row',
|
|
442
|
-
alignItems: 'center',
|
|
443
|
-
paddingVertical: 12,
|
|
444
|
-
paddingHorizontal: 14,
|
|
715
|
+
padding: 14,
|
|
445
716
|
gap: 12,
|
|
446
717
|
}}>
|
|
447
|
-
{
|
|
718
|
+
<react_native_1.Text style={{
|
|
719
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
720
|
+
fontSize: 11,
|
|
721
|
+
lineHeight: 14,
|
|
722
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
723
|
+
letterSpacing: 0.8,
|
|
724
|
+
}}>
|
|
725
|
+
{t('settings.appearanceTheme')}
|
|
726
|
+
</react_native_1.Text>
|
|
727
|
+
|
|
448
728
|
<react_native_1.View style={{
|
|
449
|
-
flex: 1,
|
|
450
729
|
flexDirection: 'row',
|
|
451
730
|
alignItems: 'center',
|
|
452
|
-
|
|
731
|
+
justifyContent: 'space-between',
|
|
453
732
|
}}>
|
|
454
733
|
<react_native_1.View style={{
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
734
|
+
flexDirection: 'row',
|
|
735
|
+
alignItems: 'center',
|
|
736
|
+
gap: 10,
|
|
737
|
+
flex: 1,
|
|
738
|
+
}}>
|
|
739
|
+
<react_native_1.View style={{
|
|
740
|
+
width: 32,
|
|
741
|
+
height: 32,
|
|
742
|
+
borderRadius: 8,
|
|
458
743
|
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
459
|
-
borderWidth: 1,
|
|
460
|
-
borderColor: `${AppColors_1.AppColors.purple}33`,
|
|
461
744
|
alignItems: 'center',
|
|
462
745
|
justifyContent: 'center',
|
|
463
746
|
}}>
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
747
|
+
{isDark ? (<NetworkIcons_1.SunIcon color={AppColors_1.AppColors.purple} size={15}/>) : (<NetworkIcons_1.MoonIcon color={AppColors_1.AppColors.purple} size={15}/>)}
|
|
748
|
+
</react_native_1.View>
|
|
749
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
750
|
+
<react_native_1.Text style={{
|
|
468
751
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
469
|
-
fontSize: 13,
|
|
752
|
+
fontSize: 13.5,
|
|
753
|
+
lineHeight: 18,
|
|
470
754
|
color: AppColors_1.AppColors.primaryBlack,
|
|
471
755
|
}}>
|
|
472
|
-
|
|
473
|
-
|
|
756
|
+
{t('settings.general.darkMode')}
|
|
757
|
+
</react_native_1.Text>
|
|
758
|
+
<react_native_1.Text style={{
|
|
759
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
760
|
+
fontSize: 11,
|
|
761
|
+
lineHeight: 15,
|
|
762
|
+
color: AppColors_1.AppColors.grayText,
|
|
763
|
+
marginTop: 1,
|
|
764
|
+
}}>
|
|
765
|
+
{t('settings.general.darkModeDescription')}
|
|
766
|
+
</react_native_1.Text>
|
|
767
|
+
</react_native_1.View>
|
|
474
768
|
</react_native_1.View>
|
|
475
|
-
</react_native_1.View>
|
|
476
769
|
|
|
477
|
-
|
|
478
|
-
<TouchableScale_1.default onPress={() => {
|
|
770
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="switch" accessibilityLabel="Toggle Dark Theme" accessibilityState={{ checked: isDark }} onPress={() => {
|
|
479
771
|
const newTheme = !isDark;
|
|
480
772
|
setIsDark(newTheme);
|
|
481
773
|
(0, styles_1.toggleGlobalTheme)(newTheme);
|
|
482
774
|
}} style={{
|
|
483
|
-
width:
|
|
484
|
-
height:
|
|
485
|
-
borderRadius:
|
|
775
|
+
width: 42,
|
|
776
|
+
height: 24,
|
|
777
|
+
borderRadius: 12,
|
|
486
778
|
backgroundColor: isDark
|
|
487
779
|
? AppColors_1.AppColors.purple
|
|
488
780
|
: AppColors_1.AppColors.grayBorderSecondary,
|
|
@@ -490,226 +782,243 @@ const SettingsPanel = () => {
|
|
|
490
782
|
justifyContent: 'center',
|
|
491
783
|
alignItems: isDark ? 'flex-end' : 'flex-start',
|
|
492
784
|
}}>
|
|
493
|
-
|
|
494
|
-
width:
|
|
495
|
-
height:
|
|
496
|
-
borderRadius:
|
|
785
|
+
<react_native_1.View style={{
|
|
786
|
+
width: 20,
|
|
787
|
+
height: 20,
|
|
788
|
+
borderRadius: 10,
|
|
497
789
|
backgroundColor: AppColors_1.AppColors.white,
|
|
498
790
|
shadowColor: AppColors_1.AppColors.black,
|
|
499
|
-
shadowOpacity: 0.
|
|
500
|
-
shadowRadius:
|
|
791
|
+
shadowOpacity: 0.18,
|
|
792
|
+
shadowRadius: 2,
|
|
501
793
|
shadowOffset: { width: 0, height: 1 },
|
|
502
794
|
}}/>
|
|
503
|
-
|
|
795
|
+
</TouchableScale_1.default>
|
|
796
|
+
</react_native_1.View>
|
|
504
797
|
</react_native_1.View>
|
|
505
798
|
|
|
506
|
-
{/*
|
|
507
|
-
<react_native_1.View style={{
|
|
508
|
-
height: 1,
|
|
509
|
-
backgroundColor: AppColors_1.AppColors.dividerColor,
|
|
510
|
-
}}/>
|
|
511
|
-
|
|
512
|
-
{/* Modal Height */}
|
|
799
|
+
{/* Section 2: Window & Layout */}
|
|
513
800
|
<react_native_1.View style={{
|
|
514
|
-
|
|
515
|
-
|
|
801
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
802
|
+
borderRadius: 14,
|
|
803
|
+
borderWidth: 1,
|
|
804
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
805
|
+
overflow: 'hidden',
|
|
806
|
+
padding: 14,
|
|
807
|
+
gap: 14,
|
|
516
808
|
}}>
|
|
517
|
-
<react_native_1.
|
|
809
|
+
<react_native_1.Text style={{
|
|
810
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
811
|
+
fontSize: 11,
|
|
812
|
+
lineHeight: 14,
|
|
813
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
814
|
+
letterSpacing: 0.8,
|
|
815
|
+
}}>
|
|
816
|
+
{t('settings.windowLayout')}
|
|
817
|
+
</react_native_1.Text>
|
|
818
|
+
|
|
819
|
+
{/* Modal Height */}
|
|
820
|
+
<react_native_1.View style={{ gap: 8 }}>
|
|
821
|
+
<react_native_1.View style={{
|
|
518
822
|
flexDirection: 'row',
|
|
519
823
|
alignItems: 'center',
|
|
520
|
-
gap:
|
|
824
|
+
gap: 10,
|
|
521
825
|
}}>
|
|
522
|
-
|
|
523
|
-
width:
|
|
524
|
-
height:
|
|
525
|
-
borderRadius:
|
|
826
|
+
<react_native_1.View style={{
|
|
827
|
+
width: 32,
|
|
828
|
+
height: 32,
|
|
829
|
+
borderRadius: 8,
|
|
526
830
|
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
527
|
-
borderWidth: 1,
|
|
528
|
-
borderColor: `${AppColors_1.AppColors.purple}33`,
|
|
529
831
|
alignItems: 'center',
|
|
530
832
|
justifyContent: 'center',
|
|
531
833
|
}}>
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
834
|
+
<NetworkIcons_1.ScreenIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
835
|
+
</react_native_1.View>
|
|
836
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
837
|
+
<react_native_1.Text style={{
|
|
536
838
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
537
|
-
fontSize: 13,
|
|
839
|
+
fontSize: 13.5,
|
|
840
|
+
lineHeight: 18,
|
|
538
841
|
color: AppColors_1.AppColors.primaryBlack,
|
|
539
842
|
}}>
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
843
|
+
{t('settings.general.modalHeight')}
|
|
844
|
+
</react_native_1.Text>
|
|
845
|
+
<react_native_1.Text style={{
|
|
543
846
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
544
847
|
fontSize: 11,
|
|
848
|
+
lineHeight: 15,
|
|
545
849
|
color: AppColors_1.AppColors.grayText,
|
|
546
850
|
marginTop: 1,
|
|
547
851
|
}}>
|
|
548
|
-
|
|
549
|
-
|
|
852
|
+
{t('settings.general.modalHeightDescription')}
|
|
853
|
+
</react_native_1.Text>
|
|
854
|
+
</react_native_1.View>
|
|
550
855
|
</react_native_1.View>
|
|
551
|
-
</react_native_1.View>
|
|
552
856
|
|
|
553
|
-
|
|
554
|
-
<react_native_1.View style={{
|
|
857
|
+
<react_native_1.View style={{
|
|
555
858
|
flexDirection: 'row',
|
|
556
859
|
backgroundColor: AppColors_1.AppColors.grayBackground,
|
|
557
|
-
borderRadius:
|
|
558
|
-
padding:
|
|
559
|
-
marginTop: 10,
|
|
860
|
+
borderRadius: 10,
|
|
861
|
+
padding: 3,
|
|
560
862
|
borderWidth: 1,
|
|
561
863
|
borderColor: AppColors_1.AppColors.dividerColor,
|
|
562
864
|
}}>
|
|
563
|
-
|
|
865
|
+
{[50, 70, 90, 100].map(opt => {
|
|
564
866
|
const isActive = modalHeightPercent === opt;
|
|
565
|
-
return (<TouchableScale_1.default key={opt} onPress={() => setModalHeightPercent(opt)} style={{
|
|
867
|
+
return (<TouchableScale_1.default key={opt} accessible={true} accessibilityRole="button" accessibilityLabel={`Set window height to ${opt} percent`} accessibilityState={{ selected: isActive }} onPress={() => setModalHeightPercent(opt)} style={{
|
|
566
868
|
flex: 1,
|
|
567
|
-
paddingVertical:
|
|
869
|
+
paddingVertical: 7,
|
|
568
870
|
alignItems: 'center',
|
|
569
|
-
borderRadius:
|
|
871
|
+
borderRadius: 8,
|
|
570
872
|
backgroundColor: isActive
|
|
571
873
|
? AppColors_1.AppColors.purple
|
|
572
874
|
: 'transparent',
|
|
573
875
|
}}>
|
|
574
|
-
|
|
876
|
+
<react_native_1.Text style={{
|
|
575
877
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
576
|
-
fontSize: 11,
|
|
577
|
-
|
|
878
|
+
fontSize: 11.5,
|
|
879
|
+
lineHeight: 15,
|
|
880
|
+
color: isActive
|
|
881
|
+
? AppColors_1.AppColors.white
|
|
882
|
+
: AppColors_1.AppColors.grayText,
|
|
578
883
|
}}>
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
884
|
+
{opt}%
|
|
885
|
+
</react_native_1.Text>
|
|
886
|
+
</TouchableScale_1.default>);
|
|
582
887
|
})}
|
|
888
|
+
</react_native_1.View>
|
|
583
889
|
</react_native_1.View>
|
|
584
|
-
</react_native_1.View>
|
|
585
890
|
|
|
586
|
-
|
|
587
|
-
<react_native_1.View style={{
|
|
588
|
-
height: 1,
|
|
589
|
-
backgroundColor: AppColors_1.AppColors.dividerColor,
|
|
590
|
-
}}/>
|
|
891
|
+
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
591
892
|
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
paddingHorizontal: 14,
|
|
596
|
-
}}>
|
|
597
|
-
<react_native_1.View style={{
|
|
893
|
+
{/* Modal Animation */}
|
|
894
|
+
<react_native_1.View style={{ gap: 8 }}>
|
|
895
|
+
<react_native_1.View style={{
|
|
598
896
|
flexDirection: 'row',
|
|
599
897
|
alignItems: 'center',
|
|
600
|
-
gap:
|
|
898
|
+
gap: 10,
|
|
601
899
|
}}>
|
|
602
|
-
|
|
603
|
-
width:
|
|
604
|
-
height:
|
|
605
|
-
borderRadius:
|
|
900
|
+
<react_native_1.View style={{
|
|
901
|
+
width: 32,
|
|
902
|
+
height: 32,
|
|
903
|
+
borderRadius: 8,
|
|
606
904
|
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
607
|
-
borderWidth: 1,
|
|
608
|
-
borderColor: `${AppColors_1.AppColors.purple}33`,
|
|
609
905
|
alignItems: 'center',
|
|
610
906
|
justifyContent: 'center',
|
|
611
907
|
}}>
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
908
|
+
<NetworkIcons_1.MotionIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
909
|
+
</react_native_1.View>
|
|
910
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
911
|
+
<react_native_1.Text style={{
|
|
616
912
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
617
|
-
fontSize: 13,
|
|
913
|
+
fontSize: 13.5,
|
|
914
|
+
lineHeight: 18,
|
|
618
915
|
color: AppColors_1.AppColors.primaryBlack,
|
|
619
916
|
}}>
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
917
|
+
{t('settings.general.modalAnimation')}
|
|
918
|
+
</react_native_1.Text>
|
|
919
|
+
<react_native_1.Text style={{
|
|
623
920
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
624
921
|
fontSize: 11,
|
|
922
|
+
lineHeight: 15,
|
|
625
923
|
color: AppColors_1.AppColors.grayText,
|
|
626
924
|
marginTop: 1,
|
|
627
925
|
}}>
|
|
628
|
-
|
|
629
|
-
|
|
926
|
+
{t('settings.general.modalAnimationDescription')}
|
|
927
|
+
</react_native_1.Text>
|
|
928
|
+
</react_native_1.View>
|
|
630
929
|
</react_native_1.View>
|
|
631
|
-
</react_native_1.View>
|
|
632
930
|
|
|
633
|
-
|
|
634
|
-
<react_native_1.View style={{
|
|
931
|
+
<react_native_1.View style={{
|
|
635
932
|
flexDirection: 'row',
|
|
636
933
|
backgroundColor: AppColors_1.AppColors.grayBackground,
|
|
637
|
-
borderRadius:
|
|
638
|
-
padding:
|
|
639
|
-
marginTop: 10,
|
|
934
|
+
borderRadius: 10,
|
|
935
|
+
padding: 3,
|
|
640
936
|
borderWidth: 1,
|
|
641
937
|
borderColor: AppColors_1.AppColors.dividerColor,
|
|
642
938
|
}}>
|
|
643
|
-
|
|
939
|
+
{[
|
|
644
940
|
{ key: 'slide', label: 'Slide Up' },
|
|
645
941
|
{ key: 'fade', label: 'Fade' },
|
|
646
942
|
{ key: 'none', label: 'None' },
|
|
647
|
-
]
|
|
943
|
+
].map(opt => {
|
|
648
944
|
const isActive = modalAnimationType === opt.key;
|
|
649
|
-
return (<TouchableScale_1.default key={opt.key} onPress={() => setModalAnimationType(opt.key)} style={{
|
|
945
|
+
return (<TouchableScale_1.default key={opt.key} accessible={true} accessibilityRole="button" accessibilityLabel={`Set transition animation to ${opt.label}`} accessibilityState={{ selected: isActive }} onPress={() => setModalAnimationType(opt.key)} style={{
|
|
650
946
|
flex: 1,
|
|
651
|
-
paddingVertical:
|
|
947
|
+
paddingVertical: 7,
|
|
652
948
|
alignItems: 'center',
|
|
653
|
-
borderRadius:
|
|
949
|
+
borderRadius: 8,
|
|
654
950
|
backgroundColor: isActive
|
|
655
951
|
? AppColors_1.AppColors.purple
|
|
656
952
|
: 'transparent',
|
|
657
953
|
}}>
|
|
658
|
-
|
|
954
|
+
<react_native_1.Text style={{
|
|
659
955
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
660
|
-
fontSize: 11,
|
|
661
|
-
|
|
956
|
+
fontSize: 11.5,
|
|
957
|
+
lineHeight: 15,
|
|
958
|
+
color: isActive
|
|
959
|
+
? AppColors_1.AppColors.white
|
|
960
|
+
: AppColors_1.AppColors.grayText,
|
|
662
961
|
}}>
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
962
|
+
{opt.label}
|
|
963
|
+
</react_native_1.Text>
|
|
964
|
+
</TouchableScale_1.default>);
|
|
666
965
|
})}
|
|
966
|
+
</react_native_1.View>
|
|
667
967
|
</react_native_1.View>
|
|
668
968
|
</react_native_1.View>
|
|
669
969
|
|
|
670
|
-
{/*
|
|
970
|
+
{/* Section 3: Default Startup Tab */}
|
|
671
971
|
<react_native_1.View style={{
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
972
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
973
|
+
borderRadius: 14,
|
|
974
|
+
borderWidth: 1,
|
|
975
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
976
|
+
overflow: 'hidden',
|
|
977
|
+
padding: 14,
|
|
978
|
+
gap: 12,
|
|
979
|
+
}}>
|
|
980
|
+
<react_native_1.Text style={{
|
|
981
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
982
|
+
fontSize: 11,
|
|
983
|
+
lineHeight: 14,
|
|
984
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
985
|
+
letterSpacing: 0.8,
|
|
680
986
|
}}>
|
|
987
|
+
{t('settings.startupDefault')}
|
|
988
|
+
</react_native_1.Text>
|
|
989
|
+
|
|
681
990
|
<react_native_1.View style={{
|
|
682
991
|
flexDirection: 'row',
|
|
683
992
|
alignItems: 'center',
|
|
684
|
-
gap:
|
|
993
|
+
gap: 10,
|
|
685
994
|
}}>
|
|
686
995
|
<react_native_1.View style={{
|
|
687
|
-
width:
|
|
688
|
-
height:
|
|
689
|
-
borderRadius:
|
|
996
|
+
width: 32,
|
|
997
|
+
height: 32,
|
|
998
|
+
borderRadius: 8,
|
|
690
999
|
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
691
|
-
borderWidth: 1,
|
|
692
|
-
borderColor: `${AppColors_1.AppColors.purple}33`,
|
|
693
1000
|
alignItems: 'center',
|
|
694
1001
|
justifyContent: 'center',
|
|
695
1002
|
}}>
|
|
696
|
-
<NetworkIcons_1.LayersIcon color={AppColors_1.AppColors.purple} size={
|
|
1003
|
+
<NetworkIcons_1.LayersIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
697
1004
|
</react_native_1.View>
|
|
698
1005
|
<react_native_1.View style={{ flex: 1 }}>
|
|
699
1006
|
<react_native_1.Text style={{
|
|
700
1007
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
701
|
-
fontSize: 13,
|
|
1008
|
+
fontSize: 13.5,
|
|
1009
|
+
lineHeight: 18,
|
|
702
1010
|
color: AppColors_1.AppColors.primaryBlack,
|
|
703
1011
|
}}>
|
|
704
|
-
|
|
1012
|
+
{t('settings.general.defaultOpeningTab')}
|
|
705
1013
|
</react_native_1.Text>
|
|
706
1014
|
<react_native_1.Text style={{
|
|
707
1015
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
708
1016
|
fontSize: 11,
|
|
1017
|
+
lineHeight: 15,
|
|
709
1018
|
color: AppColors_1.AppColors.grayText,
|
|
710
1019
|
marginTop: 1,
|
|
711
1020
|
}}>
|
|
712
|
-
|
|
1021
|
+
{t('settings.general.defaultOpeningTabDesc')}
|
|
713
1022
|
</react_native_1.Text>
|
|
714
1023
|
</react_native_1.View>
|
|
715
1024
|
</react_native_1.View>
|
|
@@ -719,13 +1028,15 @@ const SettingsPanel = () => {
|
|
|
719
1028
|
flexDirection: 'row',
|
|
720
1029
|
flexWrap: 'wrap',
|
|
721
1030
|
gap: 8,
|
|
722
|
-
marginTop:
|
|
1031
|
+
marginTop: 4,
|
|
723
1032
|
}}>
|
|
724
|
-
{
|
|
725
|
-
.filter(tab => tab.key === 'apis' ||
|
|
1033
|
+
{allModules
|
|
1034
|
+
.filter(tab => tab.key === 'apis' ||
|
|
1035
|
+
stagedTabVisibility?.[tab.key] ||
|
|
1036
|
+
tabVisibility?.[tab.key])
|
|
726
1037
|
.map(tab => {
|
|
727
1038
|
const isActive = defaultTab === tab.key;
|
|
728
|
-
return (<TouchableScale_1.default key={tab.key} onPress={() => setDefaultTab(tab.key)} style={{
|
|
1039
|
+
return (<TouchableScale_1.default key={tab.key} accessible={true} accessibilityRole="button" accessibilityLabel={`Set ${tab.label} as default tab`} accessibilityState={{ selected: isActive }} onPress={() => setDefaultTab(tab.key)} style={{
|
|
729
1040
|
flexDirection: 'row',
|
|
730
1041
|
alignItems: 'center',
|
|
731
1042
|
gap: 8,
|
|
@@ -733,186 +1044,190 @@ const SettingsPanel = () => {
|
|
|
733
1044
|
paddingHorizontal: 12,
|
|
734
1045
|
borderRadius: 10,
|
|
735
1046
|
borderWidth: 1.5,
|
|
736
|
-
borderColor: isActive
|
|
737
|
-
|
|
1047
|
+
borderColor: isActive
|
|
1048
|
+
? AppColors_1.AppColors.purple
|
|
1049
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
1050
|
+
backgroundColor: isActive
|
|
1051
|
+
? `${AppColors_1.AppColors.purple}0F`
|
|
1052
|
+
: AppColors_1.AppColors.primaryLight,
|
|
738
1053
|
minWidth: '47%',
|
|
739
1054
|
flex: 1,
|
|
740
1055
|
}}>
|
|
741
|
-
<react_native_1.View style={{
|
|
742
|
-
width: 22,
|
|
743
|
-
height: 22,
|
|
744
|
-
borderRadius: 6,
|
|
745
|
-
backgroundColor: isActive ? AppColors_1.AppColors.purple : AppColors_1.AppColors.purpleShade50,
|
|
746
|
-
alignItems: 'center',
|
|
747
|
-
justifyContent: 'center',
|
|
748
|
-
}}>
|
|
749
|
-
{tab.icon === 'apis' && (<NetworkIcons_1.SignalIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
750
|
-
{tab.icon === 'logs' && (<NetworkIcons_1.TerminalIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
751
|
-
{tab.icon === 'analytics' && (<NetworkIcons_1.AnalyticsIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
752
|
-
{tab.icon === 'redux' && (<NetworkIcons_1.ReduxIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
753
|
-
{tab.icon === 'bundle' && (<NetworkIcons_1.PackageIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
754
|
-
{tab.icon === 'performance' && (<NetworkIcons_1.PerformanceIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
755
|
-
{tab.icon === 'crash' && (<NetworkIcons_1.CrashIcon color={isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>)}
|
|
756
|
-
</react_native_1.View>
|
|
757
1056
|
<react_native_1.Text style={{
|
|
758
1057
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
759
|
-
fontSize:
|
|
760
|
-
|
|
1058
|
+
fontSize: 12.5,
|
|
1059
|
+
lineHeight: 16,
|
|
1060
|
+
color: isActive
|
|
1061
|
+
? AppColors_1.AppColors.purple
|
|
1062
|
+
: AppColors_1.AppColors.primaryBlack,
|
|
761
1063
|
flex: 1,
|
|
762
1064
|
}}>
|
|
763
|
-
|
|
1065
|
+
{tab.label}
|
|
764
1066
|
</react_native_1.Text>
|
|
765
1067
|
{isActive && (<react_native_1.View style={{
|
|
766
|
-
width:
|
|
767
|
-
height:
|
|
768
|
-
borderRadius:
|
|
1068
|
+
width: 16,
|
|
1069
|
+
height: 16,
|
|
1070
|
+
borderRadius: 8,
|
|
769
1071
|
backgroundColor: AppColors_1.AppColors.purple,
|
|
770
1072
|
alignItems: 'center',
|
|
771
1073
|
justifyContent: 'center',
|
|
772
1074
|
}}>
|
|
773
|
-
<NetworkIcons_1.CheckIcon size={
|
|
1075
|
+
<NetworkIcons_1.CheckIcon size={9} color={AppColors_1.AppColors.white}/>
|
|
774
1076
|
</react_native_1.View>)}
|
|
775
1077
|
</TouchableScale_1.default>);
|
|
776
1078
|
})}
|
|
777
1079
|
</react_native_1.View>
|
|
778
1080
|
</react_native_1.View>
|
|
779
1081
|
|
|
780
|
-
{/*
|
|
1082
|
+
{/* Section 4: Log Deduplication & Levels */}
|
|
781
1083
|
<react_native_1.View style={{
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
1084
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1085
|
+
borderRadius: 14,
|
|
1086
|
+
borderWidth: 1,
|
|
1087
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1088
|
+
overflow: 'hidden',
|
|
1089
|
+
padding: 14,
|
|
1090
|
+
gap: 14,
|
|
1091
|
+
}}>
|
|
1092
|
+
<react_native_1.Text style={{
|
|
1093
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1094
|
+
fontSize: 11,
|
|
1095
|
+
lineHeight: 14,
|
|
1096
|
+
color: AppColors_1.AppColors.grayTextWeak,
|
|
1097
|
+
letterSpacing: 0.8,
|
|
1098
|
+
}}>
|
|
1099
|
+
{t('settings.logFiltersDeduplication')}
|
|
1100
|
+
</react_native_1.Text>
|
|
785
1101
|
|
|
786
|
-
|
|
787
|
-
|
|
1102
|
+
{/* Show Duplicate Logs */}
|
|
1103
|
+
<react_native_1.View style={{
|
|
788
1104
|
flexDirection: 'row',
|
|
789
1105
|
alignItems: 'center',
|
|
790
|
-
|
|
791
|
-
paddingHorizontal: 14,
|
|
792
|
-
gap: 12,
|
|
1106
|
+
justifyContent: 'space-between',
|
|
793
1107
|
}}>
|
|
794
|
-
|
|
795
|
-
flex: 1,
|
|
1108
|
+
<react_native_1.View style={{
|
|
796
1109
|
flexDirection: 'row',
|
|
797
1110
|
alignItems: 'center',
|
|
798
|
-
gap:
|
|
1111
|
+
gap: 10,
|
|
1112
|
+
flex: 1,
|
|
799
1113
|
}}>
|
|
800
|
-
|
|
801
|
-
width:
|
|
802
|
-
height:
|
|
803
|
-
borderRadius:
|
|
1114
|
+
<react_native_1.View style={{
|
|
1115
|
+
width: 32,
|
|
1116
|
+
height: 32,
|
|
1117
|
+
borderRadius: 8,
|
|
804
1118
|
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
805
|
-
borderWidth: 1,
|
|
806
|
-
borderColor: `${AppColors_1.AppColors.purple}33`,
|
|
807
1119
|
alignItems: 'center',
|
|
808
1120
|
justifyContent: 'center',
|
|
809
1121
|
}}>
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
1122
|
+
<NetworkIcons_1.EyeIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
1123
|
+
</react_native_1.View>
|
|
1124
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1125
|
+
<react_native_1.Text style={{
|
|
814
1126
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
815
|
-
fontSize: 13,
|
|
1127
|
+
fontSize: 13.5,
|
|
1128
|
+
lineHeight: 18,
|
|
816
1129
|
color: AppColors_1.AppColors.primaryBlack,
|
|
817
1130
|
}}>
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
1131
|
+
{t('settings.general.duplicateLogs')}
|
|
1132
|
+
</react_native_1.Text>
|
|
1133
|
+
<react_native_1.Text style={{
|
|
821
1134
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
822
1135
|
fontSize: 11,
|
|
1136
|
+
lineHeight: 15,
|
|
823
1137
|
color: AppColors_1.AppColors.grayText,
|
|
824
1138
|
marginTop: 1,
|
|
825
1139
|
}}>
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
</react_native_1.
|
|
1140
|
+
{t('settings.general.duplicateLogsDescription')}
|
|
1141
|
+
</react_native_1.Text>
|
|
1142
|
+
</react_native_1.View>
|
|
829
1143
|
</react_native_1.View>
|
|
830
|
-
</react_native_1.View>
|
|
831
1144
|
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
borderRadius: 11,
|
|
1145
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="switch" accessibilityLabel="Toggle show duplicate logs" accessibilityState={{ checked: showDuplicateLogs }} onPress={() => setShowDuplicateLogs(prev => !prev)} style={{
|
|
1146
|
+
width: 42,
|
|
1147
|
+
height: 24,
|
|
1148
|
+
borderRadius: 12,
|
|
837
1149
|
backgroundColor: showDuplicateLogs
|
|
838
1150
|
? AppColors_1.AppColors.purple
|
|
839
1151
|
: AppColors_1.AppColors.grayBorderSecondary,
|
|
840
1152
|
padding: 2,
|
|
841
1153
|
justifyContent: 'center',
|
|
842
|
-
alignItems: showDuplicateLogs
|
|
1154
|
+
alignItems: showDuplicateLogs
|
|
1155
|
+
? 'flex-end'
|
|
1156
|
+
: 'flex-start',
|
|
843
1157
|
}}>
|
|
844
|
-
|
|
845
|
-
width:
|
|
846
|
-
height:
|
|
847
|
-
borderRadius:
|
|
1158
|
+
<react_native_1.View style={{
|
|
1159
|
+
width: 20,
|
|
1160
|
+
height: 20,
|
|
1161
|
+
borderRadius: 10,
|
|
848
1162
|
backgroundColor: AppColors_1.AppColors.white,
|
|
849
1163
|
shadowColor: AppColors_1.AppColors.black,
|
|
850
|
-
shadowOpacity: 0.
|
|
851
|
-
shadowRadius:
|
|
1164
|
+
shadowOpacity: 0.18,
|
|
1165
|
+
shadowRadius: 2,
|
|
852
1166
|
shadowOffset: { width: 0, height: 1 },
|
|
853
1167
|
}}/>
|
|
854
|
-
|
|
855
|
-
|
|
1168
|
+
</TouchableScale_1.default>
|
|
1169
|
+
</react_native_1.View>
|
|
856
1170
|
|
|
857
|
-
|
|
858
|
-
<react_native_1.View style={{
|
|
859
|
-
height: 1,
|
|
860
|
-
backgroundColor: AppColors_1.AppColors.dividerColor,
|
|
861
|
-
}}/>
|
|
1171
|
+
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
862
1172
|
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
paddingHorizontal: 14,
|
|
867
|
-
}}>
|
|
868
|
-
<react_native_1.View style={{
|
|
1173
|
+
{/* Console Log Levels */}
|
|
1174
|
+
<react_native_1.View style={{ gap: 8 }}>
|
|
1175
|
+
<react_native_1.View style={{
|
|
869
1176
|
flexDirection: 'row',
|
|
870
1177
|
alignItems: 'center',
|
|
871
|
-
gap:
|
|
1178
|
+
gap: 10,
|
|
872
1179
|
}}>
|
|
873
|
-
|
|
874
|
-
width:
|
|
875
|
-
height:
|
|
876
|
-
borderRadius:
|
|
1180
|
+
<react_native_1.View style={{
|
|
1181
|
+
width: 32,
|
|
1182
|
+
height: 32,
|
|
1183
|
+
borderRadius: 8,
|
|
877
1184
|
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
878
|
-
borderWidth: 1,
|
|
879
|
-
borderColor: `${AppColors_1.AppColors.purple}33`,
|
|
880
1185
|
alignItems: 'center',
|
|
881
1186
|
justifyContent: 'center',
|
|
882
1187
|
}}>
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
1188
|
+
<NetworkIcons_1.TerminalIcon color={AppColors_1.AppColors.purple} size={15}/>
|
|
1189
|
+
</react_native_1.View>
|
|
1190
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1191
|
+
<react_native_1.Text style={{
|
|
887
1192
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
888
|
-
fontSize: 13,
|
|
1193
|
+
fontSize: 13.5,
|
|
1194
|
+
lineHeight: 18,
|
|
889
1195
|
color: AppColors_1.AppColors.primaryBlack,
|
|
890
1196
|
}}>
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
1197
|
+
{t('settings.general.activeConsoleLogLevels')}
|
|
1198
|
+
</react_native_1.Text>
|
|
1199
|
+
<react_native_1.Text style={{
|
|
894
1200
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
895
1201
|
fontSize: 11,
|
|
1202
|
+
lineHeight: 15,
|
|
896
1203
|
color: AppColors_1.AppColors.grayText,
|
|
897
1204
|
marginTop: 1,
|
|
898
1205
|
}}>
|
|
899
|
-
|
|
900
|
-
|
|
1206
|
+
{t('settings.general.activeConsoleLogLevelsDesc')}
|
|
1207
|
+
</react_native_1.Text>
|
|
1208
|
+
</react_native_1.View>
|
|
901
1209
|
</react_native_1.View>
|
|
902
|
-
</react_native_1.View>
|
|
903
1210
|
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
{
|
|
912
|
-
|
|
913
|
-
|
|
1211
|
+
<react_native_1.View style={{ flexDirection: 'row', gap: 8, marginTop: 4 }}>
|
|
1212
|
+
{[
|
|
1213
|
+
{
|
|
1214
|
+
key: 'info',
|
|
1215
|
+
label: 'Info',
|
|
1216
|
+
color: AppColors_1.AppColors.blue500,
|
|
1217
|
+
},
|
|
1218
|
+
{
|
|
1219
|
+
key: 'warn',
|
|
1220
|
+
label: 'Warning',
|
|
1221
|
+
color: AppColors_1.AppColors.amber500,
|
|
1222
|
+
},
|
|
1223
|
+
{
|
|
1224
|
+
key: 'error',
|
|
1225
|
+
label: 'Error',
|
|
1226
|
+
color: AppColors_1.AppColors.errorColor,
|
|
1227
|
+
},
|
|
1228
|
+
].map(level => {
|
|
914
1229
|
const isActive = showConsoleLevels[level.key];
|
|
915
|
-
return (<TouchableScale_1.default key={level.key} onPress={() => setShowConsoleLevels(prev => ({
|
|
1230
|
+
return (<TouchableScale_1.default key={level.key} accessible={true} accessibilityRole="checkbox" accessibilityLabel={`Toggle ${level.label} logs`} accessibilityState={{ checked: isActive }} onPress={() => setShowConsoleLevels(prev => ({
|
|
916
1231
|
...prev,
|
|
917
1232
|
[level.key]: !prev[level.key],
|
|
918
1233
|
}))} style={{
|
|
@@ -922,112 +1237,113 @@ const SettingsPanel = () => {
|
|
|
922
1237
|
justifyContent: 'center',
|
|
923
1238
|
gap: 6,
|
|
924
1239
|
paddingVertical: 8,
|
|
925
|
-
borderRadius:
|
|
1240
|
+
borderRadius: 9,
|
|
926
1241
|
borderWidth: 1.5,
|
|
927
|
-
borderColor: isActive
|
|
928
|
-
|
|
1242
|
+
borderColor: isActive
|
|
1243
|
+
? level.color
|
|
1244
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
1245
|
+
backgroundColor: isActive
|
|
1246
|
+
? `${level.color}0D`
|
|
1247
|
+
: AppColors_1.AppColors.primaryLight,
|
|
929
1248
|
}}>
|
|
930
|
-
|
|
1249
|
+
<react_native_1.View style={{
|
|
931
1250
|
width: 8,
|
|
932
1251
|
height: 8,
|
|
933
1252
|
borderRadius: 4,
|
|
934
|
-
backgroundColor: isActive
|
|
1253
|
+
backgroundColor: isActive
|
|
1254
|
+
? level.color
|
|
1255
|
+
: AppColors_1.AppColors.grayBorderSecondary,
|
|
935
1256
|
}}/>
|
|
936
|
-
|
|
1257
|
+
<react_native_1.Text style={{
|
|
937
1258
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
938
|
-
fontSize: 11,
|
|
939
|
-
|
|
1259
|
+
fontSize: 11.5,
|
|
1260
|
+
lineHeight: 15,
|
|
1261
|
+
color: isActive
|
|
1262
|
+
? level.color
|
|
1263
|
+
: AppColors_1.AppColors.grayText,
|
|
940
1264
|
}}>
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
1265
|
+
{level.label}
|
|
1266
|
+
</react_native_1.Text>
|
|
1267
|
+
</TouchableScale_1.default>);
|
|
944
1268
|
})}
|
|
1269
|
+
</react_native_1.View>
|
|
945
1270
|
</react_native_1.View>
|
|
946
1271
|
</react_native_1.View>
|
|
947
1272
|
|
|
948
|
-
{/*
|
|
949
|
-
<react_native_1.View style={{
|
|
950
|
-
height: 1,
|
|
951
|
-
backgroundColor: AppColors_1.AppColors.dividerColor,
|
|
952
|
-
}}/>
|
|
953
|
-
|
|
954
|
-
{/* Reset Settings */}
|
|
1273
|
+
{/* Section 5: Reset Settings */}
|
|
955
1274
|
<react_native_1.View style={{
|
|
1275
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1276
|
+
borderRadius: 14,
|
|
1277
|
+
borderWidth: 1,
|
|
1278
|
+
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
1279
|
+
overflow: 'hidden',
|
|
1280
|
+
padding: 14,
|
|
956
1281
|
flexDirection: 'row',
|
|
957
1282
|
alignItems: 'center',
|
|
958
|
-
paddingVertical: 12,
|
|
959
|
-
paddingHorizontal: 14,
|
|
960
1283
|
gap: 12,
|
|
961
1284
|
}}>
|
|
962
1285
|
<react_native_1.View style={{
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
gap: 8,
|
|
967
|
-
}}>
|
|
968
|
-
<react_native_1.View style={{
|
|
969
|
-
width: 20,
|
|
970
|
-
height: 20,
|
|
971
|
-
borderRadius: 6,
|
|
1286
|
+
width: 34,
|
|
1287
|
+
height: 34,
|
|
1288
|
+
borderRadius: 9,
|
|
972
1289
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
973
|
-
borderWidth: 1,
|
|
974
|
-
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
975
1290
|
alignItems: 'center',
|
|
976
1291
|
justifyContent: 'center',
|
|
977
1292
|
}}>
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
1293
|
+
<NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={15}/>
|
|
1294
|
+
</react_native_1.View>
|
|
1295
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1296
|
+
<react_native_1.Text style={{
|
|
982
1297
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
983
|
-
fontSize: 13,
|
|
1298
|
+
fontSize: 13.5,
|
|
1299
|
+
lineHeight: 18,
|
|
984
1300
|
color: AppColors_1.AppColors.primaryBlack,
|
|
985
1301
|
}}>
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
1302
|
+
{t('settings.resetSettings')}
|
|
1303
|
+
</react_native_1.Text>
|
|
1304
|
+
<react_native_1.Text style={{
|
|
989
1305
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
990
1306
|
fontSize: 11,
|
|
1307
|
+
lineHeight: 15,
|
|
991
1308
|
color: AppColors_1.AppColors.grayText,
|
|
992
1309
|
marginTop: 1,
|
|
993
1310
|
}}>
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
</react_native_1.View>
|
|
1311
|
+
{t('settings.resetSettingsDesc')}
|
|
1312
|
+
</react_native_1.Text>
|
|
997
1313
|
</react_native_1.View>
|
|
998
1314
|
|
|
999
|
-
<TouchableScale_1.default onPress={resetToDefaults} style={{
|
|
1000
|
-
paddingHorizontal:
|
|
1001
|
-
paddingVertical:
|
|
1002
|
-
borderRadius:
|
|
1315
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="button" accessibilityLabel="Reset all settings to default" onPress={resetToDefaults} style={{
|
|
1316
|
+
paddingHorizontal: 12,
|
|
1317
|
+
paddingVertical: 7,
|
|
1318
|
+
borderRadius: 8,
|
|
1003
1319
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1004
1320
|
borderWidth: 1,
|
|
1005
|
-
borderColor: `${AppColors_1.AppColors.errorColor}
|
|
1321
|
+
borderColor: `${AppColors_1.AppColors.errorColor}38`,
|
|
1006
1322
|
}}>
|
|
1007
1323
|
<react_native_1.Text style={{
|
|
1008
1324
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1009
|
-
fontSize: 11,
|
|
1325
|
+
fontSize: 11.5,
|
|
1326
|
+
lineHeight: 15,
|
|
1010
1327
|
color: AppColors_1.AppColors.errorColor,
|
|
1011
1328
|
}}>
|
|
1012
|
-
|
|
1329
|
+
{t('settings.reset')}
|
|
1013
1330
|
</react_native_1.Text>
|
|
1014
1331
|
</TouchableScale_1.default>
|
|
1015
1332
|
</react_native_1.View>
|
|
1016
1333
|
</react_native_1.View>)}
|
|
1017
1334
|
|
|
1018
|
-
|
|
1019
|
-
{/* Storage Status */}
|
|
1335
|
+
{/* Storage & Engine Status Card */}
|
|
1020
1336
|
<react_native_1.View style={{
|
|
1021
|
-
backgroundColor:
|
|
1022
|
-
? `${AppColors_1.AppColors.liveGreen}
|
|
1023
|
-
: `${AppColors_1.AppColors.amber600}
|
|
1337
|
+
backgroundColor: isPersistent
|
|
1338
|
+
? `${AppColors_1.AppColors.liveGreen}12`
|
|
1339
|
+
: `${AppColors_1.AppColors.amber600}12`,
|
|
1024
1340
|
borderRadius: 12,
|
|
1025
1341
|
borderWidth: 1,
|
|
1026
|
-
borderColor:
|
|
1342
|
+
borderColor: isPersistent
|
|
1027
1343
|
? `${AppColors_1.AppColors.liveGreen}33`
|
|
1028
1344
|
: `${AppColors_1.AppColors.amber600}33`,
|
|
1029
1345
|
padding: 12,
|
|
1030
|
-
|
|
1346
|
+
marginBottom: 10,
|
|
1031
1347
|
flexDirection: 'row',
|
|
1032
1348
|
alignItems: 'center',
|
|
1033
1349
|
gap: 10,
|
|
@@ -1036,32 +1352,106 @@ const SettingsPanel = () => {
|
|
|
1036
1352
|
width: 8,
|
|
1037
1353
|
height: 8,
|
|
1038
1354
|
borderRadius: 4,
|
|
1039
|
-
backgroundColor:
|
|
1355
|
+
backgroundColor: isPersistent
|
|
1356
|
+
? AppColors_1.AppColors.green500
|
|
1357
|
+
: AppColors_1.AppColors.amber600,
|
|
1040
1358
|
}}/>
|
|
1041
1359
|
<react_native_1.View style={{ flex: 1 }}>
|
|
1042
1360
|
<react_native_1.Text style={{
|
|
1043
1361
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1044
1362
|
fontSize: 12,
|
|
1045
|
-
|
|
1363
|
+
lineHeight: 16,
|
|
1364
|
+
color: isPersistent
|
|
1365
|
+
? AppColors_1.AppColors.green700
|
|
1366
|
+
: AppColors_1.AppColors.amber800,
|
|
1046
1367
|
}}>
|
|
1047
|
-
{
|
|
1048
|
-
?
|
|
1049
|
-
|
|
1368
|
+
{isPersistent
|
|
1369
|
+
? t('settings.general.storageStatusEnabled', {
|
|
1370
|
+
type: storage ? 'Custom Storage' : 'iOS NSUserDefaults',
|
|
1371
|
+
})
|
|
1372
|
+
: t('settings.general.storageStatusDisabled')}
|
|
1050
1373
|
</react_native_1.Text>
|
|
1051
1374
|
<react_native_1.Text style={{
|
|
1052
1375
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1053
1376
|
fontSize: 10.5,
|
|
1054
|
-
|
|
1377
|
+
lineHeight: 14,
|
|
1378
|
+
color: isPersistent
|
|
1379
|
+
? AppColors_1.AppColors.green800
|
|
1380
|
+
: AppColors_1.AppColors.amber800,
|
|
1055
1381
|
marginTop: 2,
|
|
1056
|
-
opacity: 0.
|
|
1382
|
+
opacity: 0.85,
|
|
1057
1383
|
}}>
|
|
1058
|
-
{
|
|
1059
|
-
? '
|
|
1060
|
-
: '
|
|
1384
|
+
{isPersistent
|
|
1385
|
+
? t('settings.general.storageStatusEnabledDesc')
|
|
1386
|
+
: t('settings.general.storageStatusDisabledDesc')}
|
|
1061
1387
|
</react_native_1.Text>
|
|
1062
1388
|
</react_native_1.View>
|
|
1063
1389
|
</react_native_1.View>
|
|
1064
1390
|
</react_native_1.ScrollView>
|
|
1391
|
+
|
|
1392
|
+
{/* Bottom Sticky Action Bar for Save Changes */}
|
|
1393
|
+
{settingsActiveSubTab === 'module' && (<react_native_1.View style={{
|
|
1394
|
+
paddingHorizontal: 16,
|
|
1395
|
+
paddingTop: 12,
|
|
1396
|
+
paddingBottom: react_native_1.Platform.OS === 'ios' ? 26 : 14,
|
|
1397
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1398
|
+
borderTopWidth: 1,
|
|
1399
|
+
borderTopColor: AppColors_1.AppColors.dividerColor,
|
|
1400
|
+
flexDirection: 'row',
|
|
1401
|
+
alignItems: 'center',
|
|
1402
|
+
gap: 12,
|
|
1403
|
+
shadowColor: AppColors_1.AppColors.black,
|
|
1404
|
+
shadowOpacity: 0.08,
|
|
1405
|
+
shadowRadius: 8,
|
|
1406
|
+
shadowOffset: { width: 0, height: -3 },
|
|
1407
|
+
elevation: 8,
|
|
1408
|
+
}}>
|
|
1409
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1410
|
+
<react_native_1.Text style={{
|
|
1411
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1412
|
+
fontSize: 13,
|
|
1413
|
+
lineHeight: 17,
|
|
1414
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
1415
|
+
}}>
|
|
1416
|
+
{stagedActiveCount} of {allModules.length} Modules Active
|
|
1417
|
+
</react_native_1.Text>
|
|
1418
|
+
<react_native_1.Text style={{
|
|
1419
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1420
|
+
fontSize: 11,
|
|
1421
|
+
lineHeight: 15,
|
|
1422
|
+
color: hasUnsavedChanges
|
|
1423
|
+
? AppColors_1.AppColors.purple
|
|
1424
|
+
: AppColors_1.AppColors.grayText,
|
|
1425
|
+
marginTop: 1,
|
|
1426
|
+
}}>
|
|
1427
|
+
{hasUnsavedChanges
|
|
1428
|
+
? t('settings.unsavedPending')
|
|
1429
|
+
: t('settings.allSynchronized')}
|
|
1430
|
+
</react_native_1.Text>
|
|
1431
|
+
</react_native_1.View>
|
|
1432
|
+
|
|
1433
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="button" accessibilityLabel="Save Changes" onPress={handleSaveChanges} style={{
|
|
1434
|
+
flexDirection: 'row',
|
|
1435
|
+
alignItems: 'center',
|
|
1436
|
+
gap: 6,
|
|
1437
|
+
backgroundColor: hasUnsavedChanges
|
|
1438
|
+
? AppColors_1.AppColors.purple
|
|
1439
|
+
: `${AppColors_1.AppColors.purple}22`,
|
|
1440
|
+
paddingHorizontal: 18,
|
|
1441
|
+
paddingVertical: 10,
|
|
1442
|
+
borderRadius: 10,
|
|
1443
|
+
}}>
|
|
1444
|
+
<NetworkIcons_1.CheckIcon size={14} color={hasUnsavedChanges ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple}/>
|
|
1445
|
+
<react_native_1.Text style={{
|
|
1446
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1447
|
+
fontSize: 13,
|
|
1448
|
+
lineHeight: 17,
|
|
1449
|
+
color: hasUnsavedChanges ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple,
|
|
1450
|
+
}}>
|
|
1451
|
+
{t('settings.saveChanges')}
|
|
1452
|
+
</react_native_1.Text>
|
|
1453
|
+
</TouchableScale_1.default>
|
|
1454
|
+
</react_native_1.View>)}
|
|
1065
1455
|
</react_native_1.View>);
|
|
1066
1456
|
}
|
|
1067
1457
|
const goBackToMain = () => {
|
|
@@ -1095,6 +1485,7 @@ const SettingsPanel = () => {
|
|
|
1095
1485
|
<react_native_1.Text style={{
|
|
1096
1486
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1097
1487
|
fontSize: 14,
|
|
1488
|
+
lineHeight: 18,
|
|
1098
1489
|
color: AppColors_1.AppColors.primaryBlack,
|
|
1099
1490
|
}}>
|
|
1100
1491
|
{opts.label}
|
|
@@ -1102,6 +1493,7 @@ const SettingsPanel = () => {
|
|
|
1102
1493
|
{opts.description ? (<react_native_1.Text style={{
|
|
1103
1494
|
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1104
1495
|
fontSize: 11,
|
|
1496
|
+
lineHeight: 15,
|
|
1105
1497
|
color: AppColors_1.AppColors.grayText,
|
|
1106
1498
|
marginTop: 1,
|
|
1107
1499
|
}}>
|
|
@@ -1133,6 +1525,7 @@ const SettingsPanel = () => {
|
|
|
1133
1525
|
<react_native_1.Text style={{
|
|
1134
1526
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1135
1527
|
fontSize: 11,
|
|
1528
|
+
lineHeight: 14,
|
|
1136
1529
|
color: isActive ? AppColors_1.AppColors.white : AppColors_1.AppColors.grayText,
|
|
1137
1530
|
}}>
|
|
1138
1531
|
{opts.picker.formatLabel
|
|
@@ -1148,22 +1541,21 @@ const SettingsPanel = () => {
|
|
|
1148
1541
|
let icon = null;
|
|
1149
1542
|
let rightInfo = '';
|
|
1150
1543
|
if (settingsPage === 'apis') {
|
|
1151
|
-
title = '
|
|
1544
|
+
title = t('settings.apis.title');
|
|
1152
1545
|
icon = <NetworkIcons_1.SignalIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
1153
|
-
rightInfo =
|
|
1154
|
-
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16 }}>
|
|
1546
|
+
rightInfo = t('settings.apis.total', { count: logs.length });
|
|
1547
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
1155
1548
|
<react_native_1.View style={{
|
|
1156
1549
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1157
1550
|
padding: 16,
|
|
1158
|
-
borderRadius:
|
|
1551
|
+
borderRadius: 14,
|
|
1159
1552
|
borderWidth: 1,
|
|
1160
1553
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1161
|
-
gap: 4,
|
|
1162
1554
|
}}>
|
|
1163
1555
|
{renderSettingRow({
|
|
1164
1556
|
icon: <NetworkIcons_1.SignalIcon color={AppColors_1.AppColors.purple} size={16}/>,
|
|
1165
|
-
label: '
|
|
1166
|
-
description: '
|
|
1557
|
+
label: t('settings.apis.maxRequestLogs'),
|
|
1558
|
+
description: t('settings.apis.maxRequestLogsDescription'),
|
|
1167
1559
|
picker: {
|
|
1168
1560
|
options: [50, 100, 200, 500],
|
|
1169
1561
|
selectedValue: maxNetworkLogs,
|
|
@@ -1175,26 +1567,25 @@ const SettingsPanel = () => {
|
|
|
1175
1567
|
|
|
1176
1568
|
<react_native_1.View style={{
|
|
1177
1569
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1178
|
-
borderRadius:
|
|
1570
|
+
borderRadius: 14,
|
|
1179
1571
|
borderWidth: 1,
|
|
1180
1572
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1181
1573
|
padding: 16,
|
|
1182
|
-
marginTop: 12,
|
|
1183
1574
|
}}>
|
|
1184
1575
|
{renderSettingRow({
|
|
1185
1576
|
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
1186
|
-
label: '
|
|
1187
|
-
description:
|
|
1577
|
+
label: t('settings.apis.clearNetworkLogs'),
|
|
1578
|
+
description: t('settings.apis.clearNetworkLogsDescription', { count: logs.length }),
|
|
1188
1579
|
isLast: true,
|
|
1189
1580
|
onPress: () => {
|
|
1190
1581
|
(0, networkLogger_1.clearNetworkLogs)();
|
|
1191
1582
|
setSelected(null);
|
|
1192
|
-
react_native_1.Alert.alert('
|
|
1583
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.apis.networkLogsCleared'));
|
|
1193
1584
|
},
|
|
1194
1585
|
right: (<react_native_1.View style={{
|
|
1195
|
-
paddingHorizontal:
|
|
1196
|
-
paddingVertical:
|
|
1197
|
-
borderRadius:
|
|
1586
|
+
paddingHorizontal: 12,
|
|
1587
|
+
paddingVertical: 6,
|
|
1588
|
+
borderRadius: 8,
|
|
1198
1589
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1199
1590
|
borderWidth: 1,
|
|
1200
1591
|
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
@@ -1202,9 +1593,10 @@ const SettingsPanel = () => {
|
|
|
1202
1593
|
<react_native_1.Text style={{
|
|
1203
1594
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1204
1595
|
fontSize: 11,
|
|
1596
|
+
lineHeight: 14,
|
|
1205
1597
|
color: AppColors_1.AppColors.errorColor,
|
|
1206
1598
|
}}>
|
|
1207
|
-
|
|
1599
|
+
{t('common.clear')}
|
|
1208
1600
|
</react_native_1.Text>
|
|
1209
1601
|
</react_native_1.View>),
|
|
1210
1602
|
})}
|
|
@@ -1212,22 +1604,22 @@ const SettingsPanel = () => {
|
|
|
1212
1604
|
</react_native_1.ScrollView>);
|
|
1213
1605
|
}
|
|
1214
1606
|
else if (settingsPage === 'logs') {
|
|
1215
|
-
title = '
|
|
1607
|
+
title = t('settings.logs.title');
|
|
1216
1608
|
icon = <NetworkIcons_1.TerminalIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
1217
|
-
rightInfo =
|
|
1218
|
-
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16 }}>
|
|
1609
|
+
rightInfo = t('settings.logs.total', { count: consoleLogs.length });
|
|
1610
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
1219
1611
|
<react_native_1.View style={{
|
|
1220
1612
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1221
1613
|
padding: 16,
|
|
1222
|
-
borderRadius:
|
|
1614
|
+
borderRadius: 14,
|
|
1223
1615
|
borderWidth: 1,
|
|
1224
1616
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1225
1617
|
gap: 4,
|
|
1226
1618
|
}}>
|
|
1227
1619
|
{renderSettingRow({
|
|
1228
1620
|
icon: <NetworkIcons_1.TerminalIcon color={AppColors_1.AppColors.purple} size={16}/>,
|
|
1229
|
-
label: '
|
|
1230
|
-
description: '
|
|
1621
|
+
label: t('settings.logs.maxConsoleLogs'),
|
|
1622
|
+
description: t('settings.logs.maxConsoleLogsDescription'),
|
|
1231
1623
|
picker: {
|
|
1232
1624
|
options: [100, 200, 500, 1000],
|
|
1233
1625
|
selectedValue: maxConsoleLogs,
|
|
@@ -1238,10 +1630,11 @@ const SettingsPanel = () => {
|
|
|
1238
1630
|
<react_native_1.Text style={{
|
|
1239
1631
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1240
1632
|
fontSize: 13,
|
|
1633
|
+
lineHeight: 17,
|
|
1241
1634
|
color: AppColors_1.AppColors.primaryBlack,
|
|
1242
|
-
paddingTop:
|
|
1635
|
+
paddingTop: 6,
|
|
1243
1636
|
}}>
|
|
1244
|
-
|
|
1637
|
+
{t('settings.logs.logLevels')}
|
|
1245
1638
|
</react_native_1.Text>
|
|
1246
1639
|
{['info', 'warn', 'error'].map(level => {
|
|
1247
1640
|
const isLvlActive = showConsoleLevels?.[level];
|
|
@@ -1250,19 +1643,25 @@ const SettingsPanel = () => {
|
|
|
1250
1643
|
: level === 'warn'
|
|
1251
1644
|
? AppColors_1.AppColors.warningIconGold
|
|
1252
1645
|
: AppColors_1.AppColors.skyBlue;
|
|
1646
|
+
const label = level === 'info'
|
|
1647
|
+
? t('settings.logs.showInfo')
|
|
1648
|
+
: level === 'warn'
|
|
1649
|
+
? t('settings.logs.showWarn')
|
|
1650
|
+
: t('settings.logs.showError');
|
|
1651
|
+
const desc = level === 'info'
|
|
1652
|
+
? t('settings.logs.showInfoDesc')
|
|
1653
|
+
: level === 'warn'
|
|
1654
|
+
? t('settings.logs.showWarnDesc')
|
|
1655
|
+
: t('settings.logs.showErrorDesc');
|
|
1253
1656
|
return renderSettingRow({
|
|
1254
1657
|
icon: (<react_native_1.View style={{
|
|
1255
|
-
width:
|
|
1256
|
-
height:
|
|
1257
|
-
borderRadius:
|
|
1658
|
+
width: 12,
|
|
1659
|
+
height: 12,
|
|
1660
|
+
borderRadius: 6,
|
|
1258
1661
|
backgroundColor: levelColor,
|
|
1259
1662
|
}}/>),
|
|
1260
|
-
label
|
|
1261
|
-
description:
|
|
1262
|
-
? 'Informational messages'
|
|
1263
|
-
: level === 'warn'
|
|
1264
|
-
? 'Warning messages'
|
|
1265
|
-
: 'Error messages',
|
|
1663
|
+
label,
|
|
1664
|
+
description: desc,
|
|
1266
1665
|
isLast: level === 'error',
|
|
1267
1666
|
onPress: () => setShowConsoleLevels(prev => ({
|
|
1268
1667
|
...prev,
|
|
@@ -1290,25 +1689,24 @@ const SettingsPanel = () => {
|
|
|
1290
1689
|
|
|
1291
1690
|
<react_native_1.View style={{
|
|
1292
1691
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1293
|
-
borderRadius:
|
|
1692
|
+
borderRadius: 14,
|
|
1294
1693
|
borderWidth: 1,
|
|
1295
1694
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1296
1695
|
padding: 16,
|
|
1297
|
-
marginTop: 12,
|
|
1298
1696
|
}}>
|
|
1299
1697
|
{renderSettingRow({
|
|
1300
1698
|
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
1301
|
-
label: '
|
|
1302
|
-
description:
|
|
1699
|
+
label: t('settings.logs.clearConsoleLogs'),
|
|
1700
|
+
description: t('settings.logs.clearConsoleLogsDescription', { count: consoleLogs.length }),
|
|
1303
1701
|
isLast: true,
|
|
1304
1702
|
onPress: () => {
|
|
1305
1703
|
(0, consoleLogger_1.clearConsoleLogs)();
|
|
1306
|
-
react_native_1.Alert.alert('
|
|
1704
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.logs.consoleLogsCleared'));
|
|
1307
1705
|
},
|
|
1308
1706
|
right: (<react_native_1.View style={{
|
|
1309
|
-
paddingHorizontal:
|
|
1310
|
-
paddingVertical:
|
|
1311
|
-
borderRadius:
|
|
1707
|
+
paddingHorizontal: 12,
|
|
1708
|
+
paddingVertical: 6,
|
|
1709
|
+
borderRadius: 8,
|
|
1312
1710
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1313
1711
|
borderWidth: 1,
|
|
1314
1712
|
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
@@ -1316,9 +1714,10 @@ const SettingsPanel = () => {
|
|
|
1316
1714
|
<react_native_1.Text style={{
|
|
1317
1715
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1318
1716
|
fontSize: 11,
|
|
1717
|
+
lineHeight: 14,
|
|
1319
1718
|
color: AppColors_1.AppColors.errorColor,
|
|
1320
1719
|
}}>
|
|
1321
|
-
|
|
1720
|
+
{t('common.clear')}
|
|
1322
1721
|
</react_native_1.Text>
|
|
1323
1722
|
</react_native_1.View>),
|
|
1324
1723
|
})}
|
|
@@ -1326,47 +1725,45 @@ const SettingsPanel = () => {
|
|
|
1326
1725
|
</react_native_1.ScrollView>);
|
|
1327
1726
|
}
|
|
1328
1727
|
else if (settingsPage === 'analytics') {
|
|
1329
|
-
title = '
|
|
1728
|
+
title = t('settings.analytics.title');
|
|
1330
1729
|
icon = <NetworkIcons_1.AnalyticsIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
1331
|
-
rightInfo =
|
|
1332
|
-
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16 }}>
|
|
1730
|
+
rightInfo = t('settings.analytics.total', { count: analyticsEvents.length });
|
|
1731
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
1333
1732
|
<react_native_1.View style={{
|
|
1334
1733
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1335
1734
|
padding: 16,
|
|
1336
|
-
borderRadius:
|
|
1735
|
+
borderRadius: 14,
|
|
1337
1736
|
borderWidth: 1,
|
|
1338
1737
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1339
|
-
gap: 4,
|
|
1340
1738
|
}}>
|
|
1341
1739
|
{renderSettingRow({
|
|
1342
1740
|
icon: <NetworkIcons_1.AnalyticsIcon color={AppColors_1.AppColors.purple} size={16}/>,
|
|
1343
|
-
label: '
|
|
1344
|
-
description:
|
|
1741
|
+
label: t('settings.analytics.maxAnalyticsEvents'),
|
|
1742
|
+
description: t('settings.analytics.maxAnalyticsEventsDescription', { count: analyticsEvents.length }),
|
|
1345
1743
|
isLast: true,
|
|
1346
1744
|
})}
|
|
1347
1745
|
</react_native_1.View>
|
|
1348
1746
|
<react_native_1.View style={{
|
|
1349
1747
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1350
|
-
borderRadius:
|
|
1748
|
+
borderRadius: 14,
|
|
1351
1749
|
borderWidth: 1,
|
|
1352
1750
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1353
1751
|
padding: 16,
|
|
1354
|
-
marginTop: 12,
|
|
1355
1752
|
}}>
|
|
1356
1753
|
{renderSettingRow({
|
|
1357
1754
|
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
1358
|
-
label: '
|
|
1359
|
-
description: '
|
|
1755
|
+
label: t('settings.analytics.clearAnalyticsEvents'),
|
|
1756
|
+
description: t('settings.analytics.clearAnalyticsEventsDescription'),
|
|
1360
1757
|
isLast: true,
|
|
1361
1758
|
onPress: () => {
|
|
1362
1759
|
(0, analyticsLogger_1.clearAnalyticsEvents)();
|
|
1363
1760
|
setSelectedEvent(null);
|
|
1364
|
-
react_native_1.Alert.alert('
|
|
1761
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.analytics.analyticsEventsCleared'));
|
|
1365
1762
|
},
|
|
1366
1763
|
right: (<react_native_1.View style={{
|
|
1367
|
-
paddingHorizontal:
|
|
1368
|
-
paddingVertical:
|
|
1369
|
-
borderRadius:
|
|
1764
|
+
paddingHorizontal: 12,
|
|
1765
|
+
paddingVertical: 6,
|
|
1766
|
+
borderRadius: 8,
|
|
1370
1767
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1371
1768
|
borderWidth: 1,
|
|
1372
1769
|
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
@@ -1374,9 +1771,10 @@ const SettingsPanel = () => {
|
|
|
1374
1771
|
<react_native_1.Text style={{
|
|
1375
1772
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1376
1773
|
fontSize: 11,
|
|
1774
|
+
lineHeight: 14,
|
|
1377
1775
|
color: AppColors_1.AppColors.errorColor,
|
|
1378
1776
|
}}>
|
|
1379
|
-
|
|
1777
|
+
{t('common.clear')}
|
|
1380
1778
|
</react_native_1.Text>
|
|
1381
1779
|
</react_native_1.View>),
|
|
1382
1780
|
})}
|
|
@@ -1384,22 +1782,22 @@ const SettingsPanel = () => {
|
|
|
1384
1782
|
</react_native_1.ScrollView>);
|
|
1385
1783
|
}
|
|
1386
1784
|
else if (settingsPage === 'redux') {
|
|
1387
|
-
title = '
|
|
1388
|
-
icon = <NetworkIcons_1.
|
|
1389
|
-
rightInfo =
|
|
1390
|
-
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16 }}>
|
|
1785
|
+
title = t('settings.redux.title');
|
|
1786
|
+
icon = <NetworkIcons_1.ReduxIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
1787
|
+
rightInfo = t('settings.redux.reducers', { count: Object.keys(reduxState || {}).length });
|
|
1788
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
1391
1789
|
<react_native_1.View style={{
|
|
1392
1790
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1393
1791
|
padding: 16,
|
|
1394
|
-
borderRadius:
|
|
1792
|
+
borderRadius: 14,
|
|
1395
1793
|
borderWidth: 1,
|
|
1396
1794
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1397
1795
|
gap: 4,
|
|
1398
1796
|
}}>
|
|
1399
1797
|
{renderSettingRow({
|
|
1400
|
-
icon: <NetworkIcons_1.
|
|
1401
|
-
label: '
|
|
1402
|
-
description: '
|
|
1798
|
+
icon: <NetworkIcons_1.ReduxIcon color={AppColors_1.AppColors.purple} size={16}/>,
|
|
1799
|
+
label: t('settings.redux.autoRefresh'),
|
|
1800
|
+
description: t('settings.redux.autoRefreshDescription'),
|
|
1403
1801
|
onPress: () => setReduxAutoRefreshState(prev => !prev),
|
|
1404
1802
|
right: (<react_native_1.View style={{
|
|
1405
1803
|
width: 22,
|
|
@@ -1421,8 +1819,8 @@ const SettingsPanel = () => {
|
|
|
1421
1819
|
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
1422
1820
|
{renderSettingRow({
|
|
1423
1821
|
icon: <NetworkIcons_1.LayersIcon color={AppColors_1.AppColors.purple} size={16}/>,
|
|
1424
|
-
label: '
|
|
1425
|
-
description: '
|
|
1822
|
+
label: t('settings.redux.defaultJsonExpandDepth'),
|
|
1823
|
+
description: t('settings.redux.defaultJsonExpandDepthDescription'),
|
|
1426
1824
|
picker: {
|
|
1427
1825
|
options: [1, 2, 3, 5],
|
|
1428
1826
|
selectedValue: reduxExpandDepth,
|
|
@@ -1434,27 +1832,26 @@ const SettingsPanel = () => {
|
|
|
1434
1832
|
|
|
1435
1833
|
<react_native_1.View style={{
|
|
1436
1834
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1437
|
-
borderRadius:
|
|
1835
|
+
borderRadius: 14,
|
|
1438
1836
|
borderWidth: 1,
|
|
1439
1837
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1440
1838
|
padding: 16,
|
|
1441
|
-
marginTop: 12,
|
|
1442
1839
|
}}>
|
|
1443
1840
|
{renderSettingRow({
|
|
1444
1841
|
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
1445
|
-
label: '
|
|
1842
|
+
label: t('settings.redux.clearReduxState'),
|
|
1446
1843
|
description: reduxState
|
|
1447
|
-
? '
|
|
1448
|
-
: '
|
|
1844
|
+
? t('settings.redux.clearReduxStateDescription')
|
|
1845
|
+
: t('settings.redux.clearReduxStateEmpty'),
|
|
1449
1846
|
isLast: true,
|
|
1450
1847
|
onPress: () => {
|
|
1451
1848
|
setReduxState(null);
|
|
1452
|
-
react_native_1.Alert.alert('
|
|
1849
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.redux.reduxStateCleared'));
|
|
1453
1850
|
},
|
|
1454
1851
|
right: (<react_native_1.View style={{
|
|
1455
|
-
paddingHorizontal:
|
|
1456
|
-
paddingVertical:
|
|
1457
|
-
borderRadius:
|
|
1852
|
+
paddingHorizontal: 12,
|
|
1853
|
+
paddingVertical: 6,
|
|
1854
|
+
borderRadius: 8,
|
|
1458
1855
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1459
1856
|
borderWidth: 1,
|
|
1460
1857
|
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
@@ -1462,9 +1859,10 @@ const SettingsPanel = () => {
|
|
|
1462
1859
|
<react_native_1.Text style={{
|
|
1463
1860
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1464
1861
|
fontSize: 11,
|
|
1862
|
+
lineHeight: 14,
|
|
1465
1863
|
color: AppColors_1.AppColors.errorColor,
|
|
1466
1864
|
}}>
|
|
1467
|
-
|
|
1865
|
+
{t('common.clear')}
|
|
1468
1866
|
</react_native_1.Text>
|
|
1469
1867
|
</react_native_1.View>),
|
|
1470
1868
|
})}
|
|
@@ -1472,22 +1870,22 @@ const SettingsPanel = () => {
|
|
|
1472
1870
|
</react_native_1.ScrollView>);
|
|
1473
1871
|
}
|
|
1474
1872
|
else if (settingsPage === 'crash') {
|
|
1475
|
-
title = '
|
|
1873
|
+
title = t('settings.crash.title');
|
|
1476
1874
|
icon = <NetworkIcons_1.CrashIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
1477
1875
|
rightInfo = `Total: ${crashRecords?.length || 0}`;
|
|
1478
|
-
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16 }}>
|
|
1876
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
1479
1877
|
<react_native_1.View style={{
|
|
1480
1878
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1481
1879
|
padding: 16,
|
|
1482
|
-
borderRadius:
|
|
1880
|
+
borderRadius: 14,
|
|
1483
1881
|
borderWidth: 1,
|
|
1484
1882
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1485
1883
|
gap: 4,
|
|
1486
1884
|
}}>
|
|
1487
1885
|
{renderSettingRow({
|
|
1488
1886
|
icon: <NetworkIcons_1.LayersIcon color={AppColors_1.AppColors.purple} size={16}/>,
|
|
1489
|
-
label: '
|
|
1490
|
-
description: '
|
|
1887
|
+
label: t('settings.crash.maxCrashLogs'),
|
|
1888
|
+
description: t('settings.crash.maxCrashLogsDesc'),
|
|
1491
1889
|
picker: {
|
|
1492
1890
|
options: [25, 50, 100, 200],
|
|
1493
1891
|
selectedValue: maxCrashLogs || 100,
|
|
@@ -1497,8 +1895,8 @@ const SettingsPanel = () => {
|
|
|
1497
1895
|
<react_native_1.View style={{ height: 1, backgroundColor: AppColors_1.AppColors.dividerColor }}/>
|
|
1498
1896
|
{renderSettingRow({
|
|
1499
1897
|
icon: <NetworkIcons_1.ShieldAlertIcon color={AppColors_1.AppColors.greenColor} size={16}/>,
|
|
1500
|
-
label: '
|
|
1501
|
-
description: '
|
|
1898
|
+
label: t('settings.crash.globalGuard'),
|
|
1899
|
+
description: t('settings.crash.globalGuardDesc'),
|
|
1502
1900
|
isLast: true,
|
|
1503
1901
|
right: (<react_native_1.View style={{
|
|
1504
1902
|
paddingHorizontal: 8,
|
|
@@ -1509,9 +1907,10 @@ const SettingsPanel = () => {
|
|
|
1509
1907
|
<react_native_1.Text style={{
|
|
1510
1908
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1511
1909
|
fontSize: 10,
|
|
1910
|
+
lineHeight: 13,
|
|
1512
1911
|
color: AppColors_1.AppColors.greenColor,
|
|
1513
1912
|
}}>
|
|
1514
|
-
|
|
1913
|
+
{t('settings.protectedBadge')}
|
|
1515
1914
|
</react_native_1.Text>
|
|
1516
1915
|
</react_native_1.View>),
|
|
1517
1916
|
})}
|
|
@@ -1519,25 +1918,190 @@ const SettingsPanel = () => {
|
|
|
1519
1918
|
|
|
1520
1919
|
<react_native_1.View style={{
|
|
1521
1920
|
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1522
|
-
borderRadius:
|
|
1921
|
+
borderRadius: 14,
|
|
1523
1922
|
borderWidth: 1,
|
|
1524
1923
|
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1525
1924
|
padding: 16,
|
|
1526
|
-
marginTop: 12,
|
|
1527
1925
|
}}>
|
|
1528
1926
|
{renderSettingRow({
|
|
1529
1927
|
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
1530
|
-
label: '
|
|
1531
|
-
description:
|
|
1928
|
+
label: t('settings.crash.clearHistory'),
|
|
1929
|
+
description: t('settings.crash.clearHistoryDesc', { count: crashRecords?.length || 0 }),
|
|
1532
1930
|
isLast: true,
|
|
1533
1931
|
onPress: () => {
|
|
1534
1932
|
(0, crashHandler_1.clearCrashRecords)();
|
|
1535
|
-
react_native_1.Alert.alert('
|
|
1933
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.crash.historyCleared'));
|
|
1934
|
+
},
|
|
1935
|
+
right: (<react_native_1.View style={{
|
|
1936
|
+
paddingHorizontal: 12,
|
|
1937
|
+
paddingVertical: 6,
|
|
1938
|
+
borderRadius: 8,
|
|
1939
|
+
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1940
|
+
borderWidth: 1,
|
|
1941
|
+
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
1942
|
+
}}>
|
|
1943
|
+
<react_native_1.Text style={{
|
|
1944
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1945
|
+
fontSize: 11,
|
|
1946
|
+
lineHeight: 14,
|
|
1947
|
+
color: AppColors_1.AppColors.errorColor,
|
|
1948
|
+
}}>
|
|
1949
|
+
{t('common.clear')}
|
|
1950
|
+
</react_native_1.Text>
|
|
1951
|
+
</react_native_1.View>),
|
|
1952
|
+
})}
|
|
1953
|
+
</react_native_1.View>
|
|
1954
|
+
</react_native_1.ScrollView>);
|
|
1955
|
+
}
|
|
1956
|
+
else if (settingsPage === 'bundle') {
|
|
1957
|
+
title = t('settings.bundle.title');
|
|
1958
|
+
icon = <NetworkIcons_1.PackageIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
1959
|
+
rightInfo = 'Metro';
|
|
1960
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
1961
|
+
<react_native_1.View style={{
|
|
1962
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
1963
|
+
padding: 16,
|
|
1964
|
+
borderRadius: 14,
|
|
1965
|
+
borderWidth: 1,
|
|
1966
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
1967
|
+
gap: 8,
|
|
1968
|
+
}}>
|
|
1969
|
+
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 10 }}>
|
|
1970
|
+
<react_native_1.View style={{
|
|
1971
|
+
width: 36,
|
|
1972
|
+
height: 36,
|
|
1973
|
+
borderRadius: 10,
|
|
1974
|
+
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
1975
|
+
alignItems: 'center',
|
|
1976
|
+
justifyContent: 'center',
|
|
1977
|
+
}}>
|
|
1978
|
+
<NetworkIcons_1.PackageIcon color={AppColors_1.AppColors.purple} size={16}/>
|
|
1979
|
+
</react_native_1.View>
|
|
1980
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
1981
|
+
<react_native_1.Text style={{
|
|
1982
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1983
|
+
fontSize: 14,
|
|
1984
|
+
lineHeight: 18,
|
|
1985
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
1986
|
+
}}>
|
|
1987
|
+
{t('settings.bundle.sourceBundler')}
|
|
1988
|
+
</react_native_1.Text>
|
|
1989
|
+
<react_native_1.Text style={{
|
|
1990
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
1991
|
+
fontSize: 11,
|
|
1992
|
+
lineHeight: 15,
|
|
1993
|
+
color: AppColors_1.AppColors.grayText,
|
|
1994
|
+
marginTop: 1,
|
|
1995
|
+
}}>
|
|
1996
|
+
{t('settings.bundle.sourceBundlerDesc')}
|
|
1997
|
+
</react_native_1.Text>
|
|
1998
|
+
</react_native_1.View>
|
|
1999
|
+
</react_native_1.View>
|
|
2000
|
+
</react_native_1.View>
|
|
2001
|
+
|
|
2002
|
+
<react_native_1.View style={{
|
|
2003
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
2004
|
+
borderRadius: 14,
|
|
2005
|
+
borderWidth: 1,
|
|
2006
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
2007
|
+
padding: 16,
|
|
2008
|
+
}}>
|
|
2009
|
+
{renderSettingRow({
|
|
2010
|
+
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
2011
|
+
label: t('settings.bundle.clearCache'),
|
|
2012
|
+
description: t('settings.bundle.clearCacheDesc'),
|
|
2013
|
+
isLast: true,
|
|
2014
|
+
onPress: () => {
|
|
2015
|
+
(0, bundleAnalyzer_1.clearCachedBundleAnalysis)();
|
|
2016
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.bundle.cacheCleared'));
|
|
2017
|
+
},
|
|
2018
|
+
right: (<react_native_1.View style={{
|
|
2019
|
+
paddingHorizontal: 12,
|
|
2020
|
+
paddingVertical: 6,
|
|
2021
|
+
borderRadius: 8,
|
|
2022
|
+
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
2023
|
+
borderWidth: 1,
|
|
2024
|
+
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
2025
|
+
}}>
|
|
2026
|
+
<react_native_1.Text style={{
|
|
2027
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
2028
|
+
fontSize: 11,
|
|
2029
|
+
lineHeight: 14,
|
|
2030
|
+
color: AppColors_1.AppColors.errorColor,
|
|
2031
|
+
}}>
|
|
2032
|
+
{t('common.clear')}
|
|
2033
|
+
</react_native_1.Text>
|
|
2034
|
+
</react_native_1.View>),
|
|
2035
|
+
})}
|
|
2036
|
+
</react_native_1.View>
|
|
2037
|
+
</react_native_1.ScrollView>);
|
|
2038
|
+
}
|
|
2039
|
+
else if (settingsPage === 'performance') {
|
|
2040
|
+
title = t('settings.performance.title');
|
|
2041
|
+
icon = <NetworkIcons_1.PerformanceIcon color={AppColors_1.AppColors.white} size={16}/>;
|
|
2042
|
+
rightInfo = '60 FPS Target';
|
|
2043
|
+
content = (<react_native_1.ScrollView style={{ flex: 1 }} contentContainerStyle={{ padding: 16, gap: 12 }}>
|
|
2044
|
+
<react_native_1.View style={{
|
|
2045
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
2046
|
+
padding: 16,
|
|
2047
|
+
borderRadius: 14,
|
|
2048
|
+
borderWidth: 1,
|
|
2049
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
2050
|
+
gap: 8,
|
|
2051
|
+
}}>
|
|
2052
|
+
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 10 }}>
|
|
2053
|
+
<react_native_1.View style={{
|
|
2054
|
+
width: 36,
|
|
2055
|
+
height: 36,
|
|
2056
|
+
borderRadius: 10,
|
|
2057
|
+
backgroundColor: AppColors_1.AppColors.purpleShade50,
|
|
2058
|
+
alignItems: 'center',
|
|
2059
|
+
justifyContent: 'center',
|
|
2060
|
+
}}>
|
|
2061
|
+
<NetworkIcons_1.PerformanceIcon color={AppColors_1.AppColors.purple} size={16}/>
|
|
2062
|
+
</react_native_1.View>
|
|
2063
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
2064
|
+
<react_native_1.Text style={{
|
|
2065
|
+
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
2066
|
+
fontSize: 14,
|
|
2067
|
+
lineHeight: 18,
|
|
2068
|
+
color: AppColors_1.AppColors.primaryBlack,
|
|
2069
|
+
}}>
|
|
2070
|
+
{t('settings.performance.frameMeasurement')}
|
|
2071
|
+
</react_native_1.Text>
|
|
2072
|
+
<react_native_1.Text style={{
|
|
2073
|
+
fontFamily: AppFonts_1.AppFonts.interRegular,
|
|
2074
|
+
fontSize: 11,
|
|
2075
|
+
lineHeight: 15,
|
|
2076
|
+
color: AppColors_1.AppColors.grayText,
|
|
2077
|
+
marginTop: 1,
|
|
2078
|
+
}}>
|
|
2079
|
+
{t('settings.performance.frameMeasurementDesc')}
|
|
2080
|
+
</react_native_1.Text>
|
|
2081
|
+
</react_native_1.View>
|
|
2082
|
+
</react_native_1.View>
|
|
2083
|
+
</react_native_1.View>
|
|
2084
|
+
|
|
2085
|
+
<react_native_1.View style={{
|
|
2086
|
+
backgroundColor: AppColors_1.AppColors.primaryLight,
|
|
2087
|
+
borderRadius: 14,
|
|
2088
|
+
borderWidth: 1,
|
|
2089
|
+
borderColor: AppColors_1.AppColors.grayBorderSecondary,
|
|
2090
|
+
padding: 16,
|
|
2091
|
+
}}>
|
|
2092
|
+
{renderSettingRow({
|
|
2093
|
+
icon: <NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor} size={16}/>,
|
|
2094
|
+
label: t('settings.performance.clearEvents'),
|
|
2095
|
+
description: t('settings.performance.clearEventsDesc'),
|
|
2096
|
+
isLast: true,
|
|
2097
|
+
onPress: () => {
|
|
2098
|
+
(0, performanceTracker_1.clearPerformanceEvents)();
|
|
2099
|
+
react_native_1.Alert.alert(t('common.success'), t('settings.performance.eventsCleared'));
|
|
1536
2100
|
},
|
|
1537
2101
|
right: (<react_native_1.View style={{
|
|
1538
|
-
paddingHorizontal:
|
|
1539
|
-
paddingVertical:
|
|
1540
|
-
borderRadius:
|
|
2102
|
+
paddingHorizontal: 12,
|
|
2103
|
+
paddingVertical: 6,
|
|
2104
|
+
borderRadius: 8,
|
|
1541
2105
|
backgroundColor: `${AppColors_1.AppColors.errorColor}14`,
|
|
1542
2106
|
borderWidth: 1,
|
|
1543
2107
|
borderColor: `${AppColors_1.AppColors.errorColor}33`,
|
|
@@ -1545,29 +2109,33 @@ const SettingsPanel = () => {
|
|
|
1545
2109
|
<react_native_1.Text style={{
|
|
1546
2110
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1547
2111
|
fontSize: 11,
|
|
2112
|
+
lineHeight: 14,
|
|
1548
2113
|
color: AppColors_1.AppColors.errorColor,
|
|
1549
2114
|
}}>
|
|
1550
|
-
|
|
2115
|
+
{t('common.clear')}
|
|
1551
2116
|
</react_native_1.Text>
|
|
1552
2117
|
</react_native_1.View>),
|
|
1553
2118
|
})}
|
|
1554
2119
|
</react_native_1.View>
|
|
1555
2120
|
</react_native_1.ScrollView>);
|
|
1556
2121
|
}
|
|
1557
|
-
return (<react_native_1.View style={{
|
|
2122
|
+
return (<react_native_1.View style={{
|
|
2123
|
+
flex: 1,
|
|
2124
|
+
backgroundColor: AppColors_1.AppColors.grayBackground,
|
|
2125
|
+
}}>
|
|
1558
2126
|
<react_native_linear_gradient_1.default colors={[AppColors_1.AppColors.purple, AppColors_1.AppColors.brandPurple]} start={{ x: 0, y: 0 }} end={{ x: 1, y: 0 }} style={styles_1.default.headerGradient}>
|
|
1559
2127
|
<react_native_1.View style={{ paddingTop: headerTopPadding, width: '100%' }}>
|
|
1560
2128
|
<react_native_1.View style={[styles_1.default.header, { paddingHorizontal: 16, gap: 12 }]}>
|
|
1561
|
-
|
|
2129
|
+
<TouchableScale_1.default accessible={true} accessibilityRole="button" accessibilityLabel={t('settings.back')} onPress={goBackToMain} hitSlop={12} style={{
|
|
1562
2130
|
padding: 8,
|
|
1563
2131
|
borderRadius: 10,
|
|
1564
2132
|
backgroundColor: `${AppColors_1.AppColors.white}26`,
|
|
1565
2133
|
borderWidth: 1,
|
|
1566
2134
|
borderColor: `${AppColors_1.AppColors.white}14`,
|
|
1567
2135
|
}}>
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
2136
|
+
<NetworkIcons_1.WhiteBackNavigation color={AppColors_1.AppColors.white} size={16}/>
|
|
2137
|
+
</TouchableScale_1.default>
|
|
2138
|
+
{icon && (<react_native_1.View style={{
|
|
1571
2139
|
width: 30,
|
|
1572
2140
|
height: 30,
|
|
1573
2141
|
borderRadius: 8,
|
|
@@ -1575,18 +2143,19 @@ const SettingsPanel = () => {
|
|
|
1575
2143
|
alignItems: 'center',
|
|
1576
2144
|
justifyContent: 'center',
|
|
1577
2145
|
}}>
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
2146
|
+
{icon}
|
|
2147
|
+
</react_native_1.View>)}
|
|
2148
|
+
<react_native_1.View style={{ flex: 1 }}>
|
|
2149
|
+
<react_native_1.Text style={{
|
|
1582
2150
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1583
2151
|
fontSize: 17,
|
|
2152
|
+
lineHeight: 22,
|
|
1584
2153
|
color: AppColors_1.AppColors.white,
|
|
1585
2154
|
}}>
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
2155
|
+
{title}
|
|
2156
|
+
</react_native_1.Text>
|
|
2157
|
+
</react_native_1.View>
|
|
2158
|
+
{rightInfo ? (<react_native_1.View style={{
|
|
1590
2159
|
backgroundColor: `${AppColors_1.AppColors.white}26`,
|
|
1591
2160
|
paddingHorizontal: 8,
|
|
1592
2161
|
paddingVertical: 4,
|
|
@@ -1594,17 +2163,18 @@ const SettingsPanel = () => {
|
|
|
1594
2163
|
borderWidth: 1,
|
|
1595
2164
|
borderColor: `${AppColors_1.AppColors.white}1A`,
|
|
1596
2165
|
}}>
|
|
1597
|
-
|
|
2166
|
+
<react_native_1.Text style={{
|
|
1598
2167
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
1599
2168
|
fontSize: 11,
|
|
2169
|
+
lineHeight: 14,
|
|
1600
2170
|
color: AppColors_1.AppColors.white,
|
|
1601
2171
|
}}>
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
2172
|
+
{rightInfo}
|
|
2173
|
+
</react_native_1.Text>
|
|
2174
|
+
</react_native_1.View>) : null}
|
|
2175
|
+
</react_native_1.View>
|
|
1605
2176
|
</react_native_1.View>
|
|
1606
|
-
</
|
|
1607
|
-
</react_native_linear_gradient_1.default>
|
|
2177
|
+
</react_native_linear_gradient_1.default>
|
|
1608
2178
|
{content}
|
|
1609
2179
|
</react_native_1.View>);
|
|
1610
2180
|
};
|