@buoy-gg/network 7.0.41 → 7.0.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -85
- package/lib/commonjs/index.js +1 -332
- package/lib/commonjs/index.web.js +1 -420
- package/lib/commonjs/network/components/DataViewer.web.js +1 -879
- package/lib/commonjs/network/components/NetworkCopyScreen.web.js +1 -48
- package/lib/commonjs/network/components/NetworkCopySettingsView.js +27 -755
- package/lib/commonjs/network/components/NetworkCopySettingsView.web.js +14 -1242
- package/lib/commonjs/network/components/NetworkDetailScreen.web.js +1 -101
- package/lib/commonjs/network/components/NetworkDetailStepper.js +1 -108
- package/lib/commonjs/network/components/NetworkDetailStepper.web.js +1 -298
- package/lib/commonjs/network/components/NetworkEventDetailView.js +15 -1130
- package/lib/commonjs/network/components/NetworkEventDetailView.web.js +15 -1484
- package/lib/commonjs/network/components/NetworkEventItemCompact.js +2 -401
- package/lib/commonjs/network/components/NetworkEventItemCompact.web.js +2 -820
- package/lib/commonjs/network/components/NetworkFilterScreen.web.js +1 -55
- package/lib/commonjs/network/components/NetworkFilterViewV3.js +1 -442
- package/lib/commonjs/network/components/NetworkFilterViewV3.web.js +1 -1310
- package/lib/commonjs/network/components/NetworkHeaderLive.js +1 -375
- package/lib/commonjs/network/components/NetworkHeaderLive.web.js +1 -623
- package/lib/commonjs/network/components/NetworkHeaderMenu.js +1 -190
- package/lib/commonjs/network/components/NetworkListScreen.js +1 -403
- package/lib/commonjs/network/components/NetworkListScreen.web.js +1 -624
- package/lib/commonjs/network/components/NetworkModal.js +1 -786
- package/lib/commonjs/network/components/NetworkNumberPrompt.js +1 -178
- package/lib/commonjs/network/components/NetworkNumberPrompt.web.js +1 -232
- package/lib/commonjs/network/components/NetworkOverrideEditor.js +1 -814
- package/lib/commonjs/network/components/NetworkOverrideEditor.web.js +1 -942
- package/lib/commonjs/network/components/NetworkOverrideHeaderButton.js +1 -107
- package/lib/commonjs/network/components/NetworkOverrideHeaderButton.web.js +1 -133
- package/lib/commonjs/network/components/NetworkOverridesButton.js +1 -90
- package/lib/commonjs/network/components/NetworkOverridesButton.web.js +1 -143
- package/lib/commonjs/network/components/NetworkOverridesScreen.js +1 -543
- package/lib/commonjs/network/components/NetworkOverridesScreen.web.js +1 -830
- package/lib/commonjs/network/components/NetworkSavedScreen.js +1 -226
- package/lib/commonjs/network/components/NetworkSavedScreen.web.js +1 -463
- package/lib/commonjs/network/components/NetworkUpgradeBanner.js +1 -76
- package/lib/commonjs/network/components/response-editor/Explorer.js +1 -973
- package/lib/commonjs/network/components/response-editor/Explorer.web.js +1 -1136
- package/lib/commonjs/network/components/response-editor/deleteNestedDataByPath.js +1 -56
- package/lib/commonjs/network/components/response-editor/editorContext.js +1 -33
- package/lib/commonjs/network/components/response-editor/updateNestedDataByPath.js +1 -61
- package/lib/commonjs/network/conditions/NetworkConditionsControl.js +1 -235
- package/lib/commonjs/network/conditions/NetworkConditionsControl.test.js +1 -136
- package/lib/commonjs/network/conditions/NetworkConditionsIcon.js +1 -33
- package/lib/commonjs/network/conditions/NetworkFloatingTool.js +1 -310
- package/lib/commonjs/network/conditions/NetworkFloatingTool.test.js +1 -219
- package/lib/commonjs/network/conditions/store.js +1 -75
- package/lib/commonjs/network/conditions/wait.js +1 -43
- package/lib/commonjs/network/conditions/xhr.js +1 -135
- package/lib/commonjs/network/hooks/useLiveNetworkEvent.js +1 -62
- package/lib/commonjs/network/hooks/useNetworkBadgeCounts.js +1 -83
- package/lib/commonjs/network/hooks/useNetworkEventList.js +1 -108
- package/lib/commonjs/network/hooks/useNetworkEvents.js +1 -318
- package/lib/commonjs/network/hooks/useNetworkHasMatches.js +1 -56
- package/lib/commonjs/network/hooks/useNetworkSaved.js +1 -38
- package/lib/commonjs/network/hooks/useNetworkSelection.js +1 -53
- package/lib/commonjs/network/hooks/useOverrideRules.js +1 -36
- package/lib/commonjs/network/hooks/useTickEveryMinute.js +1 -21
- package/lib/commonjs/network/overrides/applyToFetch.js +1 -80
- package/lib/commonjs/network/overrides/applyToXhr.js +2 -510
- package/lib/commonjs/network/overrides/engine.js +1 -93
- package/lib/commonjs/network/overrides/matchRule.js +1 -87
- package/lib/commonjs/network/overrides/overriddenRows.js +1 -37
- package/lib/commonjs/network/overrides/overrideRulesStore.js +1 -550
- package/lib/commonjs/network/overrides/presets.js +1 -70
- package/lib/commonjs/network/overrides/resolveOverride.js +1 -158
- package/lib/commonjs/network/overrides/types.js +1 -90
- package/lib/commonjs/network/sync/networkBodyResolver.js +1 -39
- package/lib/commonjs/network/sync/networkSyncAdapter.js +1 -882
- package/lib/commonjs/network/sync/overrideHonesty.release.test.js +1 -36
- package/lib/commonjs/network/types/index.js +1 -5
- package/lib/commonjs/network/utils/extractOperationName.js +1 -80
- package/lib/commonjs/network/utils/filterNetworkEvents.js +1 -96
- package/lib/commonjs/network/utils/formatGraphQLVariables.js +1 -219
- package/lib/commonjs/network/utils/formatting.js +1 -30
- package/lib/commonjs/network/utils/generateCurl.js +2 -71
- package/lib/commonjs/network/utils/generateNetworkCopyText.js +37 -166
- package/lib/commonjs/network/utils/httpCompletion.js +1 -37
- package/lib/commonjs/network/utils/networkEventStore.js +1 -411
- package/lib/commonjs/network/utils/networkListener.js +4 -1352
- package/lib/commonjs/network/utils/networkSavedStore.js +3 -577
- package/lib/commonjs/network/utils/networkSelectionStore.js +1 -193
- package/lib/commonjs/network/utils/realNow.js +1 -0
- package/lib/commonjs/network/utils/requestId.js +1 -16
- package/lib/commonjs/network/utils/resolveRequestUrl.js +1 -15
- package/lib/commonjs/network/utils/selectSavedEvents.js +1 -39
- package/lib/commonjs/network/utils/startNetworkCapture.js +1 -24
- package/lib/commonjs/network/utils/withPinnedFirst.js +1 -32
- package/lib/commonjs/preset.js +1 -93
- package/lib/module/index.js +1 -104
- package/lib/module/index.web.js +1 -82
- package/lib/module/network/components/DataViewer.web.js +1 -875
- package/lib/module/network/components/NetworkCopyScreen.web.js +1 -44
- package/lib/module/network/components/NetworkCopySettingsView.js +27 -750
- package/lib/module/network/components/NetworkCopySettingsView.web.js +14 -1237
- package/lib/module/network/components/NetworkDetailScreen.web.js +1 -97
- package/lib/module/network/components/NetworkDetailStepper.js +1 -104
- package/lib/module/network/components/NetworkDetailStepper.web.js +1 -296
- package/lib/module/network/components/NetworkEventDetailView.js +15 -1129
- package/lib/module/network/components/NetworkEventDetailView.web.js +15 -1482
- package/lib/module/network/components/NetworkEventItemCompact.js +2 -398
- package/lib/module/network/components/NetworkEventItemCompact.web.js +2 -818
- package/lib/module/network/components/NetworkFilterScreen.web.js +1 -51
- package/lib/module/network/components/NetworkFilterViewV3.js +1 -438
- package/lib/module/network/components/NetworkFilterViewV3.web.js +1 -1306
- package/lib/module/network/components/NetworkHeaderLive.js +1 -366
- package/lib/module/network/components/NetworkHeaderLive.web.js +1 -617
- package/lib/module/network/components/NetworkHeaderMenu.js +1 -184
- package/lib/module/network/components/NetworkListScreen.js +1 -399
- package/lib/module/network/components/NetworkListScreen.web.js +1 -622
- package/lib/module/network/components/NetworkModal.js +1 -781
- package/lib/module/network/components/NetworkNumberPrompt.js +1 -174
- package/lib/module/network/components/NetworkNumberPrompt.web.js +1 -230
- package/lib/module/network/components/NetworkOverrideEditor.js +1 -811
- package/lib/module/network/components/NetworkOverrideEditor.web.js +1 -939
- package/lib/module/network/components/NetworkOverrideHeaderButton.js +1 -104
- package/lib/module/network/components/NetworkOverrideHeaderButton.web.js +1 -131
- package/lib/module/network/components/NetworkOverridesButton.js +1 -87
- package/lib/module/network/components/NetworkOverridesButton.web.js +1 -141
- package/lib/module/network/components/NetworkOverridesScreen.js +1 -539
- package/lib/module/network/components/NetworkOverridesScreen.web.js +1 -826
- package/lib/module/network/components/NetworkSavedScreen.js +1 -222
- package/lib/module/network/components/NetworkSavedScreen.web.js +1 -461
- package/lib/module/network/components/NetworkUpgradeBanner.js +1 -72
- package/lib/module/network/components/response-editor/Explorer.js +1 -972
- package/lib/module/network/components/response-editor/Explorer.web.js +1 -1133
- package/lib/module/network/components/response-editor/deleteNestedDataByPath.js +1 -51
- package/lib/module/network/components/response-editor/editorContext.js +1 -29
- package/lib/module/network/components/response-editor/updateNestedDataByPath.js +1 -56
- package/lib/module/network/conditions/NetworkConditionsControl.js +1 -231
- package/lib/module/network/conditions/NetworkConditionsControl.test.js +1 -135
- package/lib/module/network/conditions/NetworkConditionsIcon.js +1 -29
- package/lib/module/network/conditions/NetworkFloatingTool.js +1 -304
- package/lib/module/network/conditions/NetworkFloatingTool.test.js +1 -218
- package/lib/module/network/conditions/store.js +1 -65
- package/lib/module/network/conditions/wait.js +1 -38
- package/lib/module/network/conditions/xhr.js +1 -131
- package/lib/module/network/hooks/useLiveNetworkEvent.js +1 -58
- package/lib/module/network/hooks/useNetworkBadgeCounts.js +1 -79
- package/lib/module/network/hooks/useNetworkEventList.js +1 -104
- package/lib/module/network/hooks/useNetworkEvents.js +1 -314
- package/lib/module/network/hooks/useNetworkHasMatches.js +1 -52
- package/lib/module/network/hooks/useNetworkSaved.js +1 -34
- package/lib/module/network/hooks/useNetworkSelection.js +1 -46
- package/lib/module/network/hooks/useOverrideRules.js +1 -32
- package/lib/module/network/hooks/useTickEveryMinute.js +1 -11
- package/lib/module/network/overrides/applyToFetch.js +1 -72
- package/lib/module/network/overrides/applyToXhr.js +2 -502
- package/lib/module/network/overrides/engine.js +1 -85
- package/lib/module/network/overrides/matchRule.js +1 -81
- package/lib/module/network/overrides/overriddenRows.js +1 -33
- package/lib/module/network/overrides/overrideRulesStore.js +1 -547
- package/lib/module/network/overrides/presets.js +1 -65
- package/lib/module/network/overrides/resolveOverride.js +1 -152
- package/lib/module/network/overrides/types.js +1 -86
- package/lib/module/network/sync/networkBodyResolver.js +1 -34
- package/lib/module/network/sync/networkSyncAdapter.js +1 -880
- package/lib/module/network/sync/overrideHonesty.release.test.js +1 -35
- package/lib/module/network/types/index.js +1 -3
- package/lib/module/network/utils/extractOperationName.js +1 -76
- package/lib/module/network/utils/filterNetworkEvents.js +1 -92
- package/lib/module/network/utils/formatGraphQLVariables.js +1 -213
- package/lib/module/network/utils/formatting.js +1 -9
- package/lib/module/network/utils/generateCurl.js +2 -67
- package/lib/module/network/utils/generateNetworkCopyText.js +37 -162
- package/lib/module/network/utils/httpCompletion.js +1 -32
- package/lib/module/network/utils/networkEventStore.js +1 -409
- package/lib/module/network/utils/networkListener.js +4 -1341
- package/lib/module/network/utils/networkSavedStore.js +3 -572
- package/lib/module/network/utils/networkSelectionStore.js +1 -188
- package/lib/module/network/utils/realNow.js +1 -0
- package/lib/module/network/utils/requestId.js +1 -12
- package/lib/module/network/utils/resolveRequestUrl.js +1 -11
- package/lib/module/network/utils/selectSavedEvents.js +1 -35
- package/lib/module/network/utils/startNetworkCapture.js +1 -21
- package/lib/module/network/utils/withPinnedFirst.js +1 -28
- package/lib/module/preset.js +1 -91
- package/lib/typescript/network/overrides/engine.d.ts +1 -1
- package/lib/typescript/network/overrides/matchRule.d.ts +1 -1
- package/lib/typescript/network/overrides/resolveOverride.d.ts +2 -2
- package/lib/typescript/network/overrides/types.d.ts +9 -0
- package/lib/typescript/network/utils/networkListener.d.ts +11 -0
- package/lib/typescript/network/utils/realNow.d.ts +18 -0
- package/lib/web/index.mjs +73 -74
- package/package.json +2 -2
- package/lib/typescript/index.d.ts.map +0 -1
- package/lib/typescript/index.web.d.ts.map +0 -1
- package/lib/typescript/network/components/DataViewer.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkCopyScreen.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkCopySettingsView.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkCopySettingsView.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkDetailScreen.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkDetailStepper.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkDetailStepper.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkEventDetailView.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkEventDetailView.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkEventItemCompact.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkEventItemCompact.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkFilterScreen.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkFilterViewV3.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkFilterViewV3.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkHeaderLive.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkHeaderLive.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkHeaderMenu.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkListScreen.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkListScreen.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkModal.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkNumberPrompt.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkNumberPrompt.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverrideEditor.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverrideEditor.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverrideHeaderButton.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverrideHeaderButton.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverridesButton.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverridesButton.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverridesScreen.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkOverridesScreen.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkSavedScreen.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkSavedScreen.web.d.ts.map +0 -1
- package/lib/typescript/network/components/NetworkUpgradeBanner.d.ts.map +0 -1
- package/lib/typescript/network/components/response-editor/Explorer.d.ts.map +0 -1
- package/lib/typescript/network/components/response-editor/Explorer.web.d.ts.map +0 -1
- package/lib/typescript/network/components/response-editor/deleteNestedDataByPath.d.ts.map +0 -1
- package/lib/typescript/network/components/response-editor/editorContext.d.ts.map +0 -1
- package/lib/typescript/network/components/response-editor/updateNestedDataByPath.d.ts.map +0 -1
- package/lib/typescript/network/conditions/NetworkConditionsControl.d.ts.map +0 -1
- package/lib/typescript/network/conditions/NetworkConditionsControl.test.d.ts.map +0 -1
- package/lib/typescript/network/conditions/NetworkConditionsIcon.d.ts.map +0 -1
- package/lib/typescript/network/conditions/NetworkFloatingTool.d.ts.map +0 -1
- package/lib/typescript/network/conditions/NetworkFloatingTool.test.d.ts.map +0 -1
- package/lib/typescript/network/conditions/store.d.ts.map +0 -1
- package/lib/typescript/network/conditions/wait.d.ts.map +0 -1
- package/lib/typescript/network/conditions/xhr.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useLiveNetworkEvent.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useNetworkBadgeCounts.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useNetworkEventList.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useNetworkEvents.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useNetworkHasMatches.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useNetworkSaved.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useNetworkSelection.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useOverrideRules.d.ts.map +0 -1
- package/lib/typescript/network/hooks/useTickEveryMinute.d.ts.map +0 -1
- package/lib/typescript/network/overrides/applyToFetch.d.ts.map +0 -1
- package/lib/typescript/network/overrides/applyToXhr.d.ts.map +0 -1
- package/lib/typescript/network/overrides/engine.d.ts.map +0 -1
- package/lib/typescript/network/overrides/matchRule.d.ts.map +0 -1
- package/lib/typescript/network/overrides/overriddenRows.d.ts.map +0 -1
- package/lib/typescript/network/overrides/overrideRulesStore.d.ts.map +0 -1
- package/lib/typescript/network/overrides/presets.d.ts.map +0 -1
- package/lib/typescript/network/overrides/resolveOverride.d.ts.map +0 -1
- package/lib/typescript/network/overrides/types.d.ts.map +0 -1
- package/lib/typescript/network/sync/networkBodyResolver.d.ts.map +0 -1
- package/lib/typescript/network/sync/networkSyncAdapter.d.ts.map +0 -1
- package/lib/typescript/network/sync/overrideHonesty.release.test.d.ts.map +0 -1
- package/lib/typescript/network/types/index.d.ts.map +0 -1
- package/lib/typescript/network/utils/extractOperationName.d.ts.map +0 -1
- package/lib/typescript/network/utils/filterNetworkEvents.d.ts.map +0 -1
- package/lib/typescript/network/utils/formatGraphQLVariables.d.ts.map +0 -1
- package/lib/typescript/network/utils/formatting.d.ts.map +0 -1
- package/lib/typescript/network/utils/generateCurl.d.ts.map +0 -1
- package/lib/typescript/network/utils/generateNetworkCopyText.d.ts.map +0 -1
- package/lib/typescript/network/utils/httpCompletion.d.ts.map +0 -1
- package/lib/typescript/network/utils/networkEventStore.d.ts.map +0 -1
- package/lib/typescript/network/utils/networkListener.d.ts.map +0 -1
- package/lib/typescript/network/utils/networkSavedStore.d.ts.map +0 -1
- package/lib/typescript/network/utils/networkSelectionStore.d.ts.map +0 -1
- package/lib/typescript/network/utils/requestId.d.ts.map +0 -1
- package/lib/typescript/network/utils/resolveRequestUrl.d.ts.map +0 -1
- package/lib/typescript/network/utils/selectSavedEvents.d.ts.map +0 -1
- package/lib/typescript/network/utils/startNetworkCapture.d.ts.map +0 -1
- package/lib/typescript/network/utils/withPinnedFirst.d.ts.map +0 -1
- package/lib/typescript/preset.d.ts.map +0 -1
|
@@ -1,973 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.default = Explorer;
|
|
7
|
-
var _react = require("react");
|
|
8
|
-
var _reactNative = require("react-native");
|
|
9
|
-
var _sharedUi = require("@buoy-gg/shared-ui");
|
|
10
|
-
var _dataViewer = require("@buoy-gg/shared-ui/dataViewer");
|
|
11
|
-
var _updateNestedDataByPath = require("./updateNestedDataByPath");
|
|
12
|
-
var _deleteNestedDataByPath = require("./deleteNestedDataByPath");
|
|
13
|
-
var _editorContext = require("./editorContext");
|
|
14
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
|
-
/**
|
|
16
|
-
* The response-body tree: preview and editor as ONE surface.
|
|
17
|
-
*
|
|
18
|
-
* A 1:1 port of the React Query tool's `Explorer` — deliberately, because that
|
|
19
|
-
* is the interaction that already works: there is no read mode and no edit
|
|
20
|
-
* mode, no button that swaps one for the other. A string renders AS its input,
|
|
21
|
-
* a boolean AS its toggle, and typing into what you are reading is the edit.
|
|
22
|
-
*
|
|
23
|
-
* The only thing changed from the original is where an edit LANDS. There it was
|
|
24
|
-
* `queryClient.setQueryData(activeQuery.queryKey, …)`; here it's the `onChange`
|
|
25
|
-
* from `ResponseEditorContext`, which turns the rebuilt body into an override
|
|
26
|
-
* rule. Everything else — the chunked pages, the focus handling, the
|
|
27
|
-
* local-input-state race note below — is carried over unchanged so the two
|
|
28
|
-
* trees behave identically.
|
|
29
|
-
*/
|
|
30
|
-
|
|
31
|
-
// Stable constants to prevent re-renders [[memory:4875251]]
|
|
32
|
-
const CHUNK_SIZE = 100;
|
|
33
|
-
const HIT_SLOP_OPTIMIZED = {
|
|
34
|
-
top: 8,
|
|
35
|
-
bottom: 8,
|
|
36
|
-
left: 8,
|
|
37
|
-
right: 8
|
|
38
|
-
};
|
|
39
|
-
const EXPANDER_SIZE = 12;
|
|
40
|
-
|
|
41
|
-
// Optimized chunking function moved to module scope [[memory:4875251]]
|
|
42
|
-
const chunkArray = (array, size = CHUNK_SIZE) => {
|
|
43
|
-
if (size < 1 || array.length === 0) return [];
|
|
44
|
-
const result = [];
|
|
45
|
-
for (let i = 0; i < array.length; i += size) {
|
|
46
|
-
result.push(array.slice(i, i + size));
|
|
47
|
-
}
|
|
48
|
-
return result;
|
|
49
|
-
};
|
|
50
|
-
// Memoized Expander component for performance [[memory:4875251]]
|
|
51
|
-
const Expander = /*#__PURE__*/(0, _react.memo)(({
|
|
52
|
-
expanded,
|
|
53
|
-
isFocused = false,
|
|
54
|
-
isMain = false
|
|
55
|
-
}) => {
|
|
56
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
57
|
-
style: [styles.expanderIcon, isMain && styles.expanderIconMain, expanded ? styles.expanded : styles.collapsed],
|
|
58
|
-
children: expanded ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.ChevronDown, {
|
|
59
|
-
size: isMain ? 14 : EXPANDER_SIZE,
|
|
60
|
-
color: isFocused ? _sharedUi.buoyColors.primary : isMain ? _sharedUi.buoyColors.text : _sharedUi.buoyColors.textSecondary,
|
|
61
|
-
strokeWidth: 2.5
|
|
62
|
-
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.ChevronRight, {
|
|
63
|
-
size: isMain ? 14 : EXPANDER_SIZE,
|
|
64
|
-
color: isFocused ? _sharedUi.buoyColors.primary : isMain ? _sharedUi.buoyColors.text : _sharedUi.buoyColors.textSecondary,
|
|
65
|
-
strokeWidth: 2.5
|
|
66
|
-
})
|
|
67
|
-
});
|
|
68
|
-
});
|
|
69
|
-
Expander.displayName = "Expander";
|
|
70
|
-
// Local wrapper for the shared CopyButton to maintain backward compatibility
|
|
71
|
-
const CopyButton = /*#__PURE__*/(0, _react.memo)(({
|
|
72
|
-
value,
|
|
73
|
-
isFocused = false
|
|
74
|
-
}) => {
|
|
75
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.CopyButton, {
|
|
76
|
-
value: value,
|
|
77
|
-
isFocused: isFocused,
|
|
78
|
-
buttonStyle: isFocused ? {
|
|
79
|
-
...styles.buttonStyle,
|
|
80
|
-
...styles.buttonStyleFocused
|
|
81
|
-
} : styles.buttonStyle
|
|
82
|
-
});
|
|
83
|
-
});
|
|
84
|
-
CopyButton.displayName = "CopyButton";
|
|
85
|
-
|
|
86
|
-
// Memoized DeleteItemButton component [[memory:4875251]]
|
|
87
|
-
const DeleteItemButton = /*#__PURE__*/(0, _react.memo)(({
|
|
88
|
-
dataPath,
|
|
89
|
-
isFocused = false
|
|
90
|
-
}) => {
|
|
91
|
-
const editor = (0, _editorContext.useResponseEditor)();
|
|
92
|
-
const handleDelete = (0, _react.useCallback)(() => {
|
|
93
|
-
if (!editor) return;
|
|
94
|
-
editor.onChange((0, _deleteNestedDataByPath.deleteNestedDataByPath)(editor.root, dataPath));
|
|
95
|
-
}, [editor, dataPath]);
|
|
96
|
-
if (!editor) return null;
|
|
97
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
|
98
|
-
"sentry-label": "ignore devtools explorer delete button",
|
|
99
|
-
onPress: handleDelete,
|
|
100
|
-
style: [styles.deleteButton, isFocused && styles.deleteButtonFocused],
|
|
101
|
-
accessibilityLabel: "Delete item",
|
|
102
|
-
hitSlop: HIT_SLOP_OPTIMIZED,
|
|
103
|
-
activeOpacity: 0.7,
|
|
104
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Trash, {
|
|
105
|
-
size: 14,
|
|
106
|
-
strokeWidth: 2,
|
|
107
|
-
color: isFocused ? _sharedUi.buoyColors.error : _sharedUi.buoyColors.error + "CC"
|
|
108
|
-
})
|
|
109
|
-
});
|
|
110
|
-
});
|
|
111
|
-
DeleteItemButton.displayName = "DeleteItemButton";
|
|
112
|
-
// Memoized ClearArrayButton component [[memory:4875251]]
|
|
113
|
-
const ClearArrayButton = /*#__PURE__*/(0, _react.memo)(({
|
|
114
|
-
dataPath,
|
|
115
|
-
isFocused = false
|
|
116
|
-
}) => {
|
|
117
|
-
const editor = (0, _editorContext.useResponseEditor)();
|
|
118
|
-
const handleClear = (0, _react.useCallback)(() => {
|
|
119
|
-
if (!editor) return;
|
|
120
|
-
editor.onChange((0, _updateNestedDataByPath.updateNestedDataByPath)(editor.root, dataPath, []));
|
|
121
|
-
}, [editor, dataPath]);
|
|
122
|
-
if (!editor) return null;
|
|
123
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
|
124
|
-
"sentry-label": "ignore devtools explorer clear button",
|
|
125
|
-
style: [styles.clearButton, isFocused && styles.clearButtonFocused],
|
|
126
|
-
"aria-label": "Remove all items",
|
|
127
|
-
onPress: handleClear,
|
|
128
|
-
hitSlop: HIT_SLOP_OPTIMIZED,
|
|
129
|
-
activeOpacity: 0.7,
|
|
130
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
131
|
-
style: [styles.clearButtonText, {
|
|
132
|
-
color: isFocused ? _sharedUi.buoyColors.warning : _sharedUi.buoyColors.warning + "CC"
|
|
133
|
-
}],
|
|
134
|
-
children: "[]"
|
|
135
|
-
})
|
|
136
|
-
});
|
|
137
|
-
});
|
|
138
|
-
ClearArrayButton.displayName = "ClearArrayButton";
|
|
139
|
-
// ToggleValueButton - not memoized because parent Explorer passes new dataPath array each render
|
|
140
|
-
// which defeats memo anyway, and we need reliable re-renders when value changes
|
|
141
|
-
function ToggleValueButton({
|
|
142
|
-
dataPath,
|
|
143
|
-
value,
|
|
144
|
-
itemsDeletable
|
|
145
|
-
}) {
|
|
146
|
-
const editor = (0, _editorContext.useResponseEditor)();
|
|
147
|
-
const handleClick = (0, _react.useCallback)(() => {
|
|
148
|
-
if (!editor) return;
|
|
149
|
-
const currentValue = typeof value === "boolean" ? value : false;
|
|
150
|
-
editor.onChange((0, _updateNestedDataByPath.updateNestedDataByPath)(editor.root, dataPath, !currentValue));
|
|
151
|
-
}, [editor, dataPath, value]);
|
|
152
|
-
const handleDelete = (0, _react.useCallback)(() => {
|
|
153
|
-
if (!editor) return;
|
|
154
|
-
editor.onChange((0, _deleteNestedDataByPath.deleteNestedDataByPath)(editor.root, dataPath));
|
|
155
|
-
}, [editor, dataPath]);
|
|
156
|
-
if (!editor) return null;
|
|
157
|
-
|
|
158
|
-
// Pre-compute styles based on value state
|
|
159
|
-
const badgeStyle = value ? styles.toggleBadgeTrue : styles.toggleBadgeFalse;
|
|
160
|
-
const textStyle = value ? styles.toggleTextTrue : styles.toggleTextFalse;
|
|
161
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
|
|
162
|
-
"sentry-label": "ignore devtools explorer toggle button",
|
|
163
|
-
style: styles.modernToggleButton,
|
|
164
|
-
onPress: handleClick,
|
|
165
|
-
hitSlop: HIT_SLOP_OPTIMIZED,
|
|
166
|
-
activeOpacity: 0.8,
|
|
167
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
168
|
-
style: [styles.toggleBadge, badgeStyle],
|
|
169
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
170
|
-
style: [styles.toggleBadgeText, textStyle],
|
|
171
|
-
children: value ? "TRUE" : "FALSE"
|
|
172
|
-
})
|
|
173
|
-
}), itemsDeletable && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
|
174
|
-
"sentry-label": "ignore devtools explorer delete button in toggle",
|
|
175
|
-
onPress: handleDelete,
|
|
176
|
-
style: styles.deleteButtonInToggle,
|
|
177
|
-
accessibilityLabel: "Delete item",
|
|
178
|
-
hitSlop: HIT_SLOP_OPTIMIZED,
|
|
179
|
-
activeOpacity: 0.7,
|
|
180
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Trash, {
|
|
181
|
-
size: 14,
|
|
182
|
-
strokeWidth: 2,
|
|
183
|
-
color: _sharedUi.buoyColors.error + "CC"
|
|
184
|
-
})
|
|
185
|
-
})]
|
|
186
|
-
});
|
|
187
|
-
}
|
|
188
|
-
// Optimized Explorer component following rule2 guidelines [[memory:4875251]]
|
|
189
|
-
/**
|
|
190
|
-
* Recursive data explorer component used for both editable and read-only JSON trees inside the
|
|
191
|
-
* React Query dev tools.
|
|
192
|
-
*/
|
|
193
|
-
function Explorer({
|
|
194
|
-
editable,
|
|
195
|
-
label,
|
|
196
|
-
value,
|
|
197
|
-
defaultExpanded,
|
|
198
|
-
dataPath,
|
|
199
|
-
itemsDeletable,
|
|
200
|
-
dataVersion = 0
|
|
201
|
-
}) {
|
|
202
|
-
const editor = (0, _editorContext.useResponseEditor)();
|
|
203
|
-
const [isRowFocused, setIsRowFocused] = (0, _react.useState)(false);
|
|
204
|
-
|
|
205
|
-
// Local state for input value to handle typing properly
|
|
206
|
-
const [localInputValue, setLocalInputValue] = (0, _react.useState)("");
|
|
207
|
-
|
|
208
|
-
// Sync local state with prop value
|
|
209
|
-
// ⚠️ CRITICAL: Do NOT add localInputValue to the dependency array!
|
|
210
|
-
// Adding localInputValue causes a race condition where user edits get reverted:
|
|
211
|
-
// 1. User types "5101" → setLocalInputValue("5101")
|
|
212
|
-
// 2. Cache updates
|
|
213
|
-
// 3. useEffect fires because localInputValue changed
|
|
214
|
-
// 4. At this moment, value prop is still old (5100)
|
|
215
|
-
// 5. Syncs back to 5100, reverting user's change ❌
|
|
216
|
-
// Only sync when EXTERNAL changes happen (value, label, dataVersion)
|
|
217
|
-
(0, _react.useEffect)(() => {
|
|
218
|
-
if (value !== null && value !== undefined && (typeof value === "string" || typeof value === "number")) {
|
|
219
|
-
const newValue = value.toString();
|
|
220
|
-
setLocalInputValue(newValue);
|
|
221
|
-
}
|
|
222
|
-
}, [value, label, dataVersion]); // ⚠️ DO NOT add localInputValue here!
|
|
223
|
-
|
|
224
|
-
// Determine if this is a main section
|
|
225
|
-
const isMainSection = (0, _react.useMemo)(() => {
|
|
226
|
-
const upperLabel = label.toUpperCase();
|
|
227
|
-
return ["DATA", "QUERY", "QUERYKEY", "TYPES", "STATS", "OPTIONS", "OBSERVERS"].includes(upperLabel);
|
|
228
|
-
}, [label]);
|
|
229
|
-
|
|
230
|
-
// Explorer's section is expanded or collapsed
|
|
231
|
-
const [isExpanded, setIsExpanded] = (0, _react.useState)((defaultExpanded || []).includes(label));
|
|
232
|
-
// Remove unnecessary useCallback - simple state setter [[memory:4875251]]
|
|
233
|
-
const toggleExpanded = () => setIsExpanded(old => !old);
|
|
234
|
-
const [expandedPages, setExpandedPages] = (0, _react.useState)([]);
|
|
235
|
-
|
|
236
|
-
// Optimized subEntries computation with early returns and limited processing [[memory:4875251]]
|
|
237
|
-
const subEntries = (0, _react.useMemo)(() => {
|
|
238
|
-
// Early return for primitive values to avoid unnecessary computation
|
|
239
|
-
if (value === null || value === undefined || typeof value !== "object") {
|
|
240
|
-
return [];
|
|
241
|
-
}
|
|
242
|
-
if (Array.isArray(value)) {
|
|
243
|
-
// Limit array processing for performance [[memory:4875251]]
|
|
244
|
-
const limitedValue = value.length > 1000 ? value.slice(0, 1000) : value;
|
|
245
|
-
return limitedValue.map((d, i) => ({
|
|
246
|
-
label: i.toString(),
|
|
247
|
-
value: d
|
|
248
|
-
}));
|
|
249
|
-
}
|
|
250
|
-
if (value instanceof Map) {
|
|
251
|
-
// Limit Map entries for performance
|
|
252
|
-
const entries = Array.from(value.entries()).slice(0, 1000);
|
|
253
|
-
return entries.map(([key, val]) => ({
|
|
254
|
-
label: key.toString(),
|
|
255
|
-
value: val
|
|
256
|
-
}));
|
|
257
|
-
}
|
|
258
|
-
if (value instanceof Set) {
|
|
259
|
-
// Limit Set entries for performance
|
|
260
|
-
const entries = Array.from(value).slice(0, 1000);
|
|
261
|
-
return entries.map((val, i) => ({
|
|
262
|
-
label: i.toString(),
|
|
263
|
-
value: val
|
|
264
|
-
}));
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
// Handle regular objects with key limiting
|
|
268
|
-
const entries = Object.entries(value).slice(0, 1000);
|
|
269
|
-
return entries.map(([key, val]) => ({
|
|
270
|
-
label: key,
|
|
271
|
-
value: val
|
|
272
|
-
}));
|
|
273
|
-
}, [value]);
|
|
274
|
-
|
|
275
|
-
// Optimized valueType computation with early returns [[memory:4875251]]
|
|
276
|
-
const valueType = (0, _react.useMemo)(() => {
|
|
277
|
-
if (Array.isArray(value)) return "array";
|
|
278
|
-
if (value === null || typeof value !== "object") return typeof value;
|
|
279
|
-
if (value instanceof Map || value instanceof Set) return "Iterable";
|
|
280
|
-
return "object";
|
|
281
|
-
}, [value]);
|
|
282
|
-
|
|
283
|
-
// Optimized chunking with stable chunk size [[memory:4875251]]
|
|
284
|
-
const subEntryPages = (0, _react.useMemo)(() => {
|
|
285
|
-
return chunkArray(subEntries, CHUNK_SIZE);
|
|
286
|
-
}, [subEntries]);
|
|
287
|
-
const currentDataPath = dataPath ?? [];
|
|
288
|
-
|
|
289
|
-
// Optimize handleChange using refs to avoid dependency arrays [[memory:4875251]]
|
|
290
|
-
const editorRef = (0, _react.useRef)(editor);
|
|
291
|
-
const dataPathRef = (0, _react.useRef)(currentDataPath);
|
|
292
|
-
const valueTypeRef = (0, _react.useRef)(valueType);
|
|
293
|
-
editorRef.current = editor;
|
|
294
|
-
dataPathRef.current = currentDataPath;
|
|
295
|
-
valueTypeRef.current = valueType;
|
|
296
|
-
const handleChange = (0, _react.useCallback)((isNumber, newValue) => {
|
|
297
|
-
// Update local state immediately for responsive typing
|
|
298
|
-
setLocalInputValue(newValue);
|
|
299
|
-
const current = editorRef.current;
|
|
300
|
-
if (!current) return;
|
|
301
|
-
if (isNumber && isNaN(Number(newValue))) return;
|
|
302
|
-
const updatedValue = valueTypeRef.current === "number" ? Number(newValue) : newValue;
|
|
303
|
-
current.onChange((0, _updateNestedDataByPath.updateNestedDataByPath)(current.root, dataPathRef.current, updatedValue));
|
|
304
|
-
}, [setLocalInputValue]);
|
|
305
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
306
|
-
style: styles.minWidthWrapper,
|
|
307
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
308
|
-
style: styles.fullWidthMarginRight,
|
|
309
|
-
children: [subEntryPages.length > 0 && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
310
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
311
|
-
style: [styles.flexRowItemsCenterGap, isMainSection && styles.flexRowItemsCenterGapMain],
|
|
312
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
|
|
313
|
-
"sentry-label": "ignore devtools explorer expander button",
|
|
314
|
-
style: styles.expanderButton,
|
|
315
|
-
onPress: toggleExpanded,
|
|
316
|
-
hitSlop: HIT_SLOP_OPTIMIZED,
|
|
317
|
-
activeOpacity: 0.6,
|
|
318
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Expander, {
|
|
319
|
-
expanded: isExpanded,
|
|
320
|
-
isFocused: isRowFocused,
|
|
321
|
-
isMain: isMainSection
|
|
322
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
323
|
-
style: [styles.labelText, isRowFocused && styles.labelTextFocused, isMainSection && styles.labelTextMain],
|
|
324
|
-
children: label
|
|
325
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
326
|
-
style: styles.textGray500,
|
|
327
|
-
children: `${String(valueType).toLowerCase() === "iterable" ? "(Iterable) " : ""}${subEntries.length} ${subEntries.length > 1 ? `items` : `item`}`
|
|
328
|
-
})]
|
|
329
|
-
}), editable && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
330
|
-
style: styles.flexRowGapItemsCenter,
|
|
331
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(CopyButton, {
|
|
332
|
-
value: value,
|
|
333
|
-
isFocused: isRowFocused
|
|
334
|
-
}), itemsDeletable && editor !== null && /*#__PURE__*/(0, _jsxRuntime.jsx)(DeleteItemButton, {
|
|
335
|
-
dataPath: currentDataPath,
|
|
336
|
-
isFocused: isRowFocused
|
|
337
|
-
}), valueType === "array" && editor !== null && /*#__PURE__*/(0, _jsxRuntime.jsx)(ClearArrayButton, {
|
|
338
|
-
dataPath: currentDataPath,
|
|
339
|
-
isFocused: isRowFocused
|
|
340
|
-
})]
|
|
341
|
-
})]
|
|
342
|
-
}), isExpanded && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
343
|
-
children: [subEntryPages.length === 1 && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
344
|
-
style: [styles.singleEntryContainer, isMainSection && styles.singleEntryContainerMain],
|
|
345
|
-
children: subEntries.map((entry, index) => /*#__PURE__*/(0, _jsxRuntime.jsx)(Explorer, {
|
|
346
|
-
defaultExpanded: defaultExpanded,
|
|
347
|
-
label: entry.label,
|
|
348
|
-
value: entry.value,
|
|
349
|
-
editable: editable,
|
|
350
|
-
dataPath: [...currentDataPath, entry.label],
|
|
351
|
-
itemsDeletable: valueType === "array" || valueType === "Iterable" || valueType === "object",
|
|
352
|
-
dataVersion: dataVersion
|
|
353
|
-
}, entry.label + index))
|
|
354
|
-
}), subEntryPages.length > 1 && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
355
|
-
style: styles.multiEntryContainer,
|
|
356
|
-
children: subEntryPages.map((entries, index) => /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
357
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
358
|
-
style: styles.relativeOutlineNone,
|
|
359
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
|
|
360
|
-
"sentry-label": "ignore devtools explorer page toggle",
|
|
361
|
-
onPress: () => setExpandedPages(old => old.includes(index) ? old.filter(d => d !== index) : [...old, index]),
|
|
362
|
-
style: styles.pageExpanderButton,
|
|
363
|
-
hitSlop: HIT_SLOP_OPTIMIZED,
|
|
364
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Expander, {
|
|
365
|
-
expanded: expandedPages.includes(index)
|
|
366
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
|
|
367
|
-
style: styles.pageRangeText,
|
|
368
|
-
children: ["[", index * CHUNK_SIZE, "...", index * CHUNK_SIZE + CHUNK_SIZE - 1, "]"]
|
|
369
|
-
})]
|
|
370
|
-
}), expandedPages.includes(index) && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
371
|
-
style: styles.entriesContainer,
|
|
372
|
-
children: entries.map(entry => /*#__PURE__*/(0, _jsxRuntime.jsx)(Explorer, {
|
|
373
|
-
defaultExpanded: defaultExpanded,
|
|
374
|
-
label: entry.label,
|
|
375
|
-
value: entry.value,
|
|
376
|
-
editable: editable,
|
|
377
|
-
dataPath: [...currentDataPath, entry.label],
|
|
378
|
-
dataVersion: dataVersion
|
|
379
|
-
}, entry.label))
|
|
380
|
-
})]
|
|
381
|
-
})
|
|
382
|
-
}, index))
|
|
383
|
-
})]
|
|
384
|
-
})]
|
|
385
|
-
}), subEntryPages.length === 0 && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
386
|
-
style: styles.flexRowGapFullWidth,
|
|
387
|
-
children: [editable && editor !== null && (valueType === "string" || valueType === "number" || valueType === "boolean") ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
388
|
-
children: [editable && editor && (valueType === "string" || valueType === "number") && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
389
|
-
style: styles.nebulaInputWrapper,
|
|
390
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.CyberpunkInput, {
|
|
391
|
-
label: label,
|
|
392
|
-
accessibilityLabel: "Data input field for editing values",
|
|
393
|
-
style: [valueType === "number" ? styles.textNumber : styles.textString],
|
|
394
|
-
keyboardType: valueType === "number" ? "numeric" : "default",
|
|
395
|
-
value: localInputValue,
|
|
396
|
-
onChangeText: newValue => handleChange(valueType === "number", newValue),
|
|
397
|
-
onFocus: () => setIsRowFocused(true),
|
|
398
|
-
onBlur: () => setIsRowFocused(false),
|
|
399
|
-
showNumberControls: valueType === "number",
|
|
400
|
-
onIncrement: () => {
|
|
401
|
-
const currentNum = Number(localInputValue) || 0;
|
|
402
|
-
handleChange(true, String(currentNum + 1));
|
|
403
|
-
},
|
|
404
|
-
onDecrement: () => {
|
|
405
|
-
const currentNum = Number(localInputValue) || 0;
|
|
406
|
-
handleChange(true, String(currentNum - 1));
|
|
407
|
-
},
|
|
408
|
-
showDeleteButton: itemsDeletable,
|
|
409
|
-
onDelete: () => {
|
|
410
|
-
editor.onChange((0, _deleteNestedDataByPath.deleteNestedDataByPath)(editor.root, currentDataPath));
|
|
411
|
-
}
|
|
412
|
-
})
|
|
413
|
-
}), valueType === "boolean" && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
414
|
-
style: styles.booleanRowContainer,
|
|
415
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
416
|
-
style: styles.booleanLabel,
|
|
417
|
-
children: label
|
|
418
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
419
|
-
style: styles.booleanToggleWrapper,
|
|
420
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(ToggleValueButton, {
|
|
421
|
-
dataPath: currentDataPath,
|
|
422
|
-
value: value,
|
|
423
|
-
itemsDeletable: itemsDeletable
|
|
424
|
-
})
|
|
425
|
-
})]
|
|
426
|
-
})]
|
|
427
|
-
}) : /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
428
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
429
|
-
style: styles.text344054,
|
|
430
|
-
children: label
|
|
431
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
432
|
-
style: styles.displayValueText,
|
|
433
|
-
children: (0, _sharedUi.displayValue)(value)
|
|
434
|
-
})]
|
|
435
|
-
}), editable && itemsDeletable && editor !== null && valueType !== "string" && valueType !== "number" && valueType !== "boolean" && /*#__PURE__*/(0, _jsxRuntime.jsx)(DeleteItemButton, {
|
|
436
|
-
dataPath: currentDataPath,
|
|
437
|
-
isFocused: isRowFocused
|
|
438
|
-
})]
|
|
439
|
-
})]
|
|
440
|
-
})
|
|
441
|
-
});
|
|
442
|
-
}
|
|
443
|
-
const styles = _reactNative.StyleSheet.create({
|
|
444
|
-
buttonStyle: {
|
|
445
|
-
backgroundColor: _sharedUi.buoyColors.card + "E6",
|
|
446
|
-
borderWidth: 1,
|
|
447
|
-
borderColor: _sharedUi.buoyColors.textSecondary + "33",
|
|
448
|
-
borderRadius: 6,
|
|
449
|
-
flexDirection: "row",
|
|
450
|
-
alignItems: "center",
|
|
451
|
-
justifyContent: "center",
|
|
452
|
-
width: 28,
|
|
453
|
-
height: 28,
|
|
454
|
-
position: "relative",
|
|
455
|
-
shadowColor: "#000",
|
|
456
|
-
shadowOffset: {
|
|
457
|
-
width: 0,
|
|
458
|
-
height: 1
|
|
459
|
-
},
|
|
460
|
-
shadowOpacity: 0.2,
|
|
461
|
-
shadowRadius: 2
|
|
462
|
-
},
|
|
463
|
-
buttonStyleFocused: {
|
|
464
|
-
borderColor: _sharedUi.buoyColors.primary + "CC",
|
|
465
|
-
backgroundColor: _sharedUi.buoyColors.primary + "26",
|
|
466
|
-
shadowColor: _sharedUi.buoyColors.primary,
|
|
467
|
-
shadowOpacity: 0.3,
|
|
468
|
-
shadowRadius: 4
|
|
469
|
-
},
|
|
470
|
-
deleteButton: {
|
|
471
|
-
backgroundColor: _sharedUi.buoyColors.error + "1A",
|
|
472
|
-
borderColor: _sharedUi.buoyColors.error + "4D",
|
|
473
|
-
borderWidth: 1,
|
|
474
|
-
borderRadius: 6,
|
|
475
|
-
padding: 0,
|
|
476
|
-
alignItems: "center",
|
|
477
|
-
justifyContent: "center",
|
|
478
|
-
width: 28,
|
|
479
|
-
height: 28,
|
|
480
|
-
position: "relative",
|
|
481
|
-
shadowColor: _sharedUi.buoyColors.error,
|
|
482
|
-
shadowOffset: {
|
|
483
|
-
width: 0,
|
|
484
|
-
height: 0
|
|
485
|
-
},
|
|
486
|
-
shadowOpacity: 0.15,
|
|
487
|
-
shadowRadius: 3
|
|
488
|
-
},
|
|
489
|
-
deleteButtonFocused: {
|
|
490
|
-
borderColor: _sharedUi.buoyColors.error + "CC",
|
|
491
|
-
backgroundColor: _sharedUi.buoyColors.error + "33",
|
|
492
|
-
shadowOpacity: 0.3,
|
|
493
|
-
shadowRadius: 5
|
|
494
|
-
},
|
|
495
|
-
deleteButtonInToggle: {
|
|
496
|
-
backgroundColor: _sharedUi.buoyColors.error + "1A",
|
|
497
|
-
borderColor: _sharedUi.buoyColors.error + "4D",
|
|
498
|
-
borderWidth: 1,
|
|
499
|
-
borderRadius: 6,
|
|
500
|
-
padding: 0,
|
|
501
|
-
alignItems: "center",
|
|
502
|
-
justifyContent: "center",
|
|
503
|
-
width: 28,
|
|
504
|
-
height: 28,
|
|
505
|
-
shadowColor: _sharedUi.buoyColors.error,
|
|
506
|
-
shadowOffset: {
|
|
507
|
-
width: 0,
|
|
508
|
-
height: 0
|
|
509
|
-
},
|
|
510
|
-
shadowOpacity: 0.15,
|
|
511
|
-
shadowRadius: 3
|
|
512
|
-
},
|
|
513
|
-
clearButton: {
|
|
514
|
-
backgroundColor: _sharedUi.buoyColors.warning + "1A",
|
|
515
|
-
borderWidth: 1,
|
|
516
|
-
borderColor: _sharedUi.buoyColors.warning + "4D",
|
|
517
|
-
borderRadius: 6,
|
|
518
|
-
flexDirection: "row",
|
|
519
|
-
padding: 0,
|
|
520
|
-
alignItems: "center",
|
|
521
|
-
justifyContent: "center",
|
|
522
|
-
width: 28,
|
|
523
|
-
height: 28,
|
|
524
|
-
position: "relative",
|
|
525
|
-
zIndex: 10,
|
|
526
|
-
shadowColor: _sharedUi.buoyColors.warning,
|
|
527
|
-
shadowOffset: {
|
|
528
|
-
width: 0,
|
|
529
|
-
height: 0
|
|
530
|
-
},
|
|
531
|
-
shadowOpacity: 0.15,
|
|
532
|
-
shadowRadius: 3
|
|
533
|
-
},
|
|
534
|
-
clearButtonFocused: {
|
|
535
|
-
borderColor: _sharedUi.buoyColors.warning + "CC",
|
|
536
|
-
backgroundColor: _sharedUi.buoyColors.warning + "33",
|
|
537
|
-
shadowOpacity: 0.3,
|
|
538
|
-
shadowRadius: 5
|
|
539
|
-
},
|
|
540
|
-
clearButtonText: {
|
|
541
|
-
fontSize: 12,
|
|
542
|
-
fontWeight: "700",
|
|
543
|
-
fontFamily: _sharedUi.monoFont
|
|
544
|
-
},
|
|
545
|
-
expanderIcon: {
|
|
546
|
-
width: 18,
|
|
547
|
-
height: 18,
|
|
548
|
-
alignItems: "center",
|
|
549
|
-
justifyContent: "center",
|
|
550
|
-
marginRight: 1,
|
|
551
|
-
backgroundColor: _sharedUi.buoyColors.textSecondary + "14",
|
|
552
|
-
borderRadius: 3
|
|
553
|
-
},
|
|
554
|
-
expanderIconMain: {
|
|
555
|
-
backgroundColor: _sharedUi.buoyColors.textSecondary + "1A",
|
|
556
|
-
width: 20,
|
|
557
|
-
height: 20,
|
|
558
|
-
borderRadius: 4,
|
|
559
|
-
borderWidth: 0.5,
|
|
560
|
-
borderColor: _sharedUi.buoyColors.textSecondary + "33"
|
|
561
|
-
},
|
|
562
|
-
expanded: {
|
|
563
|
-
transform: [{
|
|
564
|
-
rotate: "0deg"
|
|
565
|
-
}]
|
|
566
|
-
},
|
|
567
|
-
collapsed: {
|
|
568
|
-
transform: [{
|
|
569
|
-
rotate: "0deg"
|
|
570
|
-
}]
|
|
571
|
-
},
|
|
572
|
-
minWidthWrapper: {
|
|
573
|
-
minWidth: 180,
|
|
574
|
-
fontSize: 11,
|
|
575
|
-
flexDirection: "row",
|
|
576
|
-
flexWrap: "wrap",
|
|
577
|
-
width: "100%",
|
|
578
|
-
marginVertical: 0.5
|
|
579
|
-
},
|
|
580
|
-
fullWidthMarginRight: {
|
|
581
|
-
position: "relative",
|
|
582
|
-
width: "100%",
|
|
583
|
-
marginRight: 1
|
|
584
|
-
},
|
|
585
|
-
flexRowItemsCenterGap: {
|
|
586
|
-
flexDirection: "row",
|
|
587
|
-
alignItems: "center",
|
|
588
|
-
justifyContent: "space-between",
|
|
589
|
-
paddingVertical: 3,
|
|
590
|
-
paddingHorizontal: 6,
|
|
591
|
-
marginVertical: 1,
|
|
592
|
-
borderRadius: 4,
|
|
593
|
-
backgroundColor: _sharedUi.buoyColors.card + "66",
|
|
594
|
-
borderWidth: 0.5,
|
|
595
|
-
borderColor: _sharedUi.buoyColors.textSecondary + "1A"
|
|
596
|
-
},
|
|
597
|
-
flexRowItemsCenterGapMain: {
|
|
598
|
-
backgroundColor: _sharedUi.buoyColors.card + "E6",
|
|
599
|
-
borderLeftWidth: 2.5,
|
|
600
|
-
borderLeftColor: _sharedUi.buoyColors.textSecondary + "80",
|
|
601
|
-
borderColor: _sharedUi.buoyColors.textSecondary + "26",
|
|
602
|
-
paddingVertical: 5,
|
|
603
|
-
paddingHorizontal: 8,
|
|
604
|
-
marginBottom: 3,
|
|
605
|
-
borderWidth: 1,
|
|
606
|
-
shadowColor: "#000",
|
|
607
|
-
shadowOffset: {
|
|
608
|
-
width: 0,
|
|
609
|
-
height: 0
|
|
610
|
-
},
|
|
611
|
-
shadowOpacity: 0.08,
|
|
612
|
-
shadowRadius: 3
|
|
613
|
-
},
|
|
614
|
-
expanderButton: {
|
|
615
|
-
flexDirection: "row",
|
|
616
|
-
alignItems: "center",
|
|
617
|
-
backgroundColor: "transparent",
|
|
618
|
-
paddingVertical: 1,
|
|
619
|
-
paddingHorizontal: 2,
|
|
620
|
-
gap: 6,
|
|
621
|
-
borderWidth: 0,
|
|
622
|
-
minHeight: 24,
|
|
623
|
-
flex: 1
|
|
624
|
-
},
|
|
625
|
-
labelText: {
|
|
626
|
-
color: _sharedUi.buoyColors.textSecondary,
|
|
627
|
-
fontSize: 10,
|
|
628
|
-
fontWeight: "600",
|
|
629
|
-
marginRight: 4,
|
|
630
|
-
fontFamily: _sharedUi.monoFont,
|
|
631
|
-
letterSpacing: 0.4
|
|
632
|
-
},
|
|
633
|
-
labelTextFocused: {
|
|
634
|
-
color: _sharedUi.buoyColors.text
|
|
635
|
-
},
|
|
636
|
-
labelTextMain: {
|
|
637
|
-
color: _sharedUi.buoyColors.text,
|
|
638
|
-
fontSize: 11,
|
|
639
|
-
fontWeight: "700",
|
|
640
|
-
letterSpacing: 0.6
|
|
641
|
-
},
|
|
642
|
-
textGray500: {
|
|
643
|
-
color: _sharedUi.buoyColors.textMuted,
|
|
644
|
-
fontSize: 10,
|
|
645
|
-
fontWeight: "400",
|
|
646
|
-
fontFamily: _sharedUi.monoFont,
|
|
647
|
-
opacity: 0.7
|
|
648
|
-
},
|
|
649
|
-
pageRangeText: {
|
|
650
|
-
color: _sharedUi.buoyColors.textSecondary,
|
|
651
|
-
fontSize: 10,
|
|
652
|
-
fontWeight: "600",
|
|
653
|
-
fontFamily: _sharedUi.monoFont
|
|
654
|
-
},
|
|
655
|
-
flexRowGapItemsCenter: {
|
|
656
|
-
flexDirection: "row",
|
|
657
|
-
alignItems: "center",
|
|
658
|
-
gap: 4,
|
|
659
|
-
paddingLeft: 2
|
|
660
|
-
},
|
|
661
|
-
singleEntryContainer: {
|
|
662
|
-
marginLeft: 2,
|
|
663
|
-
marginTop: 2,
|
|
664
|
-
paddingLeft: 8,
|
|
665
|
-
borderLeftWidth: 1.5,
|
|
666
|
-
borderLeftColor: _sharedUi.buoyColors.textSecondary + "40"
|
|
667
|
-
},
|
|
668
|
-
singleEntryContainerMain: {
|
|
669
|
-
borderLeftColor: _sharedUi.buoyColors.textSecondary + "4D",
|
|
670
|
-
marginLeft: 4,
|
|
671
|
-
paddingLeft: 10
|
|
672
|
-
},
|
|
673
|
-
multiEntryContainer: {
|
|
674
|
-
marginLeft: 2,
|
|
675
|
-
marginTop: 2,
|
|
676
|
-
paddingLeft: 8,
|
|
677
|
-
borderLeftWidth: 1.5,
|
|
678
|
-
borderLeftColor: _sharedUi.buoyColors.textSecondary + "40"
|
|
679
|
-
},
|
|
680
|
-
multiEntryContainerMain: {
|
|
681
|
-
borderLeftColor: _sharedUi.buoyColors.textSecondary + "4D",
|
|
682
|
-
marginLeft: 4,
|
|
683
|
-
paddingLeft: 10
|
|
684
|
-
},
|
|
685
|
-
relativeOutlineNone: {
|
|
686
|
-
position: "relative"
|
|
687
|
-
},
|
|
688
|
-
pageExpanderButton: {
|
|
689
|
-
flexDirection: "row",
|
|
690
|
-
alignItems: "center",
|
|
691
|
-
backgroundColor: _sharedUi.buoyColors.card + "66",
|
|
692
|
-
paddingVertical: 3,
|
|
693
|
-
paddingHorizontal: 6,
|
|
694
|
-
gap: 6,
|
|
695
|
-
borderRadius: 4,
|
|
696
|
-
borderWidth: 0.5,
|
|
697
|
-
borderColor: _sharedUi.buoyColors.textSecondary + "1A",
|
|
698
|
-
marginBottom: 2,
|
|
699
|
-
minHeight: 24
|
|
700
|
-
},
|
|
701
|
-
entriesContainer: {
|
|
702
|
-
marginLeft: 2,
|
|
703
|
-
paddingLeft: 8,
|
|
704
|
-
marginTop: 2,
|
|
705
|
-
borderLeftWidth: 1.5,
|
|
706
|
-
borderLeftColor: _sharedUi.buoyColors.textSecondary + "40"
|
|
707
|
-
},
|
|
708
|
-
textNumber: {
|
|
709
|
-
color: _sharedUi.buoyColors.text,
|
|
710
|
-
fontWeight: "600",
|
|
711
|
-
fontFamily: _sharedUi.monoFont
|
|
712
|
-
},
|
|
713
|
-
textString: {
|
|
714
|
-
color: _sharedUi.buoyColors.text,
|
|
715
|
-
fontFamily: _sharedUi.monoFont
|
|
716
|
-
},
|
|
717
|
-
flexRowGapFullWidth: {
|
|
718
|
-
flexDirection: "row",
|
|
719
|
-
width: "100%",
|
|
720
|
-
alignItems: "center",
|
|
721
|
-
marginVertical: 1,
|
|
722
|
-
gap: 6,
|
|
723
|
-
paddingHorizontal: 4,
|
|
724
|
-
paddingVertical: 2,
|
|
725
|
-
borderRadius: 3
|
|
726
|
-
},
|
|
727
|
-
text344054: {
|
|
728
|
-
color: _sharedUi.buoyColors.textSecondary,
|
|
729
|
-
fontWeight: "600",
|
|
730
|
-
fontSize: 9,
|
|
731
|
-
minWidth: 50,
|
|
732
|
-
fontFamily: _sharedUi.monoFont,
|
|
733
|
-
letterSpacing: 0.4,
|
|
734
|
-
opacity: 0.8
|
|
735
|
-
},
|
|
736
|
-
numberInputButtons: {
|
|
737
|
-
position: "absolute",
|
|
738
|
-
right: 8,
|
|
739
|
-
top: "50%",
|
|
740
|
-
transform: [{
|
|
741
|
-
translateY: -18
|
|
742
|
-
}],
|
|
743
|
-
flexDirection: "row",
|
|
744
|
-
gap: 4,
|
|
745
|
-
zIndex: 10
|
|
746
|
-
},
|
|
747
|
-
touchableButton: {
|
|
748
|
-
width: 32,
|
|
749
|
-
height: 32,
|
|
750
|
-
borderRadius: 6,
|
|
751
|
-
backgroundColor: _sharedUi.buoyColors.card + "E6",
|
|
752
|
-
borderWidth: 1,
|
|
753
|
-
borderColor: _sharedUi.buoyColors.textSecondary + "33",
|
|
754
|
-
alignItems: "center",
|
|
755
|
-
justifyContent: "center",
|
|
756
|
-
marginLeft: 2,
|
|
757
|
-
shadowColor: "#000",
|
|
758
|
-
shadowOffset: {
|
|
759
|
-
width: 0,
|
|
760
|
-
height: 1
|
|
761
|
-
},
|
|
762
|
-
shadowOpacity: 0.2,
|
|
763
|
-
shadowRadius: 2
|
|
764
|
-
},
|
|
765
|
-
touchableButtonFocused: {
|
|
766
|
-
borderColor: _sharedUi.buoyColors.primary + "CC",
|
|
767
|
-
backgroundColor: _sharedUi.buoyColors.primary + "26",
|
|
768
|
-
shadowColor: _sharedUi.buoyColors.primary,
|
|
769
|
-
shadowOffset: {
|
|
770
|
-
width: 0,
|
|
771
|
-
height: 0
|
|
772
|
-
},
|
|
773
|
-
shadowOpacity: 0.3,
|
|
774
|
-
shadowRadius: 4,
|
|
775
|
-
elevation: 3
|
|
776
|
-
},
|
|
777
|
-
nebulaInputWrapper: {
|
|
778
|
-
flex: 1,
|
|
779
|
-
width: "100%",
|
|
780
|
-
position: "relative"
|
|
781
|
-
},
|
|
782
|
-
displayValueText: {
|
|
783
|
-
flex: 1,
|
|
784
|
-
color: _sharedUi.buoyColors.text,
|
|
785
|
-
fontWeight: "400",
|
|
786
|
-
fontFamily: _sharedUi.monoFont,
|
|
787
|
-
fontSize: 12,
|
|
788
|
-
paddingVertical: 6,
|
|
789
|
-
paddingHorizontal: 10,
|
|
790
|
-
borderRadius: 6,
|
|
791
|
-
borderWidth: 1,
|
|
792
|
-
borderColor: _sharedUi.buoyColors.textMuted + "66",
|
|
793
|
-
minHeight: 34
|
|
794
|
-
},
|
|
795
|
-
// New redesigned styles (kept for future use)
|
|
796
|
-
dataRow: {
|
|
797
|
-
flexDirection: "row",
|
|
798
|
-
alignItems: "center",
|
|
799
|
-
paddingVertical: 4,
|
|
800
|
-
paddingHorizontal: 8,
|
|
801
|
-
minHeight: 44,
|
|
802
|
-
gap: 12
|
|
803
|
-
},
|
|
804
|
-
dataLabel: {
|
|
805
|
-
color: _sharedUi.buoyColors.textSecondary,
|
|
806
|
-
fontSize: 13,
|
|
807
|
-
fontWeight: "500",
|
|
808
|
-
minWidth: 80,
|
|
809
|
-
flexShrink: 0
|
|
810
|
-
},
|
|
811
|
-
dataValueContainer: {
|
|
812
|
-
flex: 1,
|
|
813
|
-
flexDirection: "row",
|
|
814
|
-
alignItems: "center"
|
|
815
|
-
},
|
|
816
|
-
inputWithActions: {
|
|
817
|
-
flex: 1,
|
|
818
|
-
position: "relative"
|
|
819
|
-
},
|
|
820
|
-
numberControls: {
|
|
821
|
-
position: "absolute",
|
|
822
|
-
right: 8,
|
|
823
|
-
top: "50%",
|
|
824
|
-
transform: [{
|
|
825
|
-
translateY: -16
|
|
826
|
-
}],
|
|
827
|
-
flexDirection: "column",
|
|
828
|
-
gap: 2
|
|
829
|
-
},
|
|
830
|
-
numberButton: {
|
|
831
|
-
width: 32,
|
|
832
|
-
height: 16,
|
|
833
|
-
borderRadius: 4,
|
|
834
|
-
alignItems: "center",
|
|
835
|
-
justifyContent: "center",
|
|
836
|
-
borderWidth: 1,
|
|
837
|
-
borderColor: _sharedUi.buoyColors.primary + "0F"
|
|
838
|
-
},
|
|
839
|
-
readOnlyValue: {
|
|
840
|
-
color: _sharedUi.buoyColors.text,
|
|
841
|
-
fontSize: 13,
|
|
842
|
-
fontFamily: _sharedUi.monoFont,
|
|
843
|
-
paddingVertical: 8,
|
|
844
|
-
paddingHorizontal: 12,
|
|
845
|
-
borderRadius: 6,
|
|
846
|
-
borderWidth: 1,
|
|
847
|
-
borderColor: _sharedUi.buoyColors.textMuted + "33",
|
|
848
|
-
flex: 1
|
|
849
|
-
},
|
|
850
|
-
actionButtons: {
|
|
851
|
-
flexDirection: "row",
|
|
852
|
-
gap: 6,
|
|
853
|
-
paddingLeft: 8
|
|
854
|
-
},
|
|
855
|
-
booleanContainer: {
|
|
856
|
-
flexDirection: "row",
|
|
857
|
-
alignItems: "center",
|
|
858
|
-
padding: 8,
|
|
859
|
-
borderRadius: 6,
|
|
860
|
-
borderWidth: 1,
|
|
861
|
-
borderColor: _sharedUi.buoyColors.textMuted + "4D",
|
|
862
|
-
flex: 1
|
|
863
|
-
},
|
|
864
|
-
booleanText: {
|
|
865
|
-
marginLeft: 8,
|
|
866
|
-
color: _sharedUi.buoyColors.warning,
|
|
867
|
-
fontWeight: "500",
|
|
868
|
-
fontFamily: _sharedUi.monoFont
|
|
869
|
-
},
|
|
870
|
-
modernToggleButton: {
|
|
871
|
-
flexDirection: "row",
|
|
872
|
-
alignItems: "center",
|
|
873
|
-
justifyContent: "space-between",
|
|
874
|
-
borderRadius: 6,
|
|
875
|
-
borderWidth: 1,
|
|
876
|
-
borderColor: _sharedUi.buoyColors.textMuted + "99",
|
|
877
|
-
paddingHorizontal: 8,
|
|
878
|
-
paddingVertical: 6,
|
|
879
|
-
marginVertical: 2,
|
|
880
|
-
minHeight: 34,
|
|
881
|
-
gap: 8
|
|
882
|
-
},
|
|
883
|
-
toggleIconContainer: {
|
|
884
|
-
marginRight: 6
|
|
885
|
-
},
|
|
886
|
-
toggleIcon: {
|
|
887
|
-
padding: 8,
|
|
888
|
-
borderRadius: 8,
|
|
889
|
-
alignItems: "center",
|
|
890
|
-
justifyContent: "center",
|
|
891
|
-
width: 32,
|
|
892
|
-
height: 32
|
|
893
|
-
},
|
|
894
|
-
toggleIconSmall: {
|
|
895
|
-
width: 8,
|
|
896
|
-
height: 8,
|
|
897
|
-
borderRadius: 4
|
|
898
|
-
},
|
|
899
|
-
toggleContent: {
|
|
900
|
-
flex: 1,
|
|
901
|
-
minWidth: 0
|
|
902
|
-
},
|
|
903
|
-
toggleLabel: {
|
|
904
|
-
color: "#E5E7EB",
|
|
905
|
-
fontSize: 11,
|
|
906
|
-
fontWeight: "600",
|
|
907
|
-
fontFamily: _sharedUi.monoFont,
|
|
908
|
-
letterSpacing: 0.3
|
|
909
|
-
},
|
|
910
|
-
toggleStatus: {
|
|
911
|
-
color: "#9CA3AF",
|
|
912
|
-
fontSize: 11
|
|
913
|
-
},
|
|
914
|
-
toggleBadge: {
|
|
915
|
-
marginLeft: 6,
|
|
916
|
-
paddingHorizontal: 6,
|
|
917
|
-
paddingVertical: 3,
|
|
918
|
-
borderRadius: 4,
|
|
919
|
-
borderWidth: 1
|
|
920
|
-
},
|
|
921
|
-
toggleBadgeText: {
|
|
922
|
-
fontSize: 9,
|
|
923
|
-
fontWeight: "700",
|
|
924
|
-
textTransform: "uppercase",
|
|
925
|
-
letterSpacing: 0.8,
|
|
926
|
-
fontFamily: _sharedUi.monoFont
|
|
927
|
-
},
|
|
928
|
-
// Pre-computed toggle icon styles to avoid inline objects [[memory:4875251]]
|
|
929
|
-
toggleIconTrue: {
|
|
930
|
-
backgroundColor: _sharedUi.buoyColors.primary
|
|
931
|
-
},
|
|
932
|
-
toggleIconFalse: {
|
|
933
|
-
backgroundColor: _sharedUi.buoyColors.textMuted
|
|
934
|
-
},
|
|
935
|
-
// Pre-computed toggle badge styles [[memory:4875251]]
|
|
936
|
-
toggleBadgeTrue: {
|
|
937
|
-
backgroundColor: _sharedUi.buoyColors.primary + "1A",
|
|
938
|
-
borderColor: _sharedUi.buoyColors.primary + "4D"
|
|
939
|
-
},
|
|
940
|
-
toggleBadgeFalse: {
|
|
941
|
-
backgroundColor: _sharedUi.buoyColors.textMuted + "1A",
|
|
942
|
-
borderColor: _sharedUi.buoyColors.textMuted + "4D"
|
|
943
|
-
},
|
|
944
|
-
// Pre-computed toggle text styles [[memory:4875251]]
|
|
945
|
-
toggleTextTrue: {
|
|
946
|
-
color: _sharedUi.buoyColors.primary,
|
|
947
|
-
fontWeight: "600"
|
|
948
|
-
},
|
|
949
|
-
toggleTextFalse: {
|
|
950
|
-
color: _sharedUi.buoyColors.textSecondary,
|
|
951
|
-
fontWeight: "500"
|
|
952
|
-
},
|
|
953
|
-
// Boolean row container styles
|
|
954
|
-
booleanRowContainer: {
|
|
955
|
-
flexDirection: "row",
|
|
956
|
-
alignItems: "center",
|
|
957
|
-
width: "100%",
|
|
958
|
-
gap: 8,
|
|
959
|
-
paddingVertical: 2
|
|
960
|
-
},
|
|
961
|
-
booleanLabel: {
|
|
962
|
-
color: _sharedUi.buoyColors.textSecondary,
|
|
963
|
-
fontSize: 10,
|
|
964
|
-
fontWeight: "600",
|
|
965
|
-
fontFamily: _sharedUi.monoFont,
|
|
966
|
-
letterSpacing: 0.4,
|
|
967
|
-
minWidth: 60,
|
|
968
|
-
flexShrink: 0
|
|
969
|
-
},
|
|
970
|
-
booleanToggleWrapper: {
|
|
971
|
-
flex: 1
|
|
972
|
-
}
|
|
973
|
-
});
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=Explorer;var _react=require("react");var _reactNative=require("react-native");var _sharedUi=require("@buoy-gg/shared-ui");var _dataViewer=require("@buoy-gg/shared-ui/dataViewer");var _updateNestedDataByPath=require("./updateNestedDataByPath");var _deleteNestedDataByPath=require("./deleteNestedDataByPath");var _editorContext=require("./editorContext");var _jsxRuntime=require("react/jsx-runtime");const CHUNK_SIZE=100;const HIT_SLOP_OPTIMIZED={top:8,bottom:8,left:8,right:8};const EXPANDER_SIZE=12;const chunkArray=(t,o=CHUNK_SIZE)=>{if(o<1||t.length===0)return[];const e=[];for(let n=0;n<t.length;n+=o){e.push(t.slice(n,n+o))}return e};const Expander=(0,_react.memo)(({expanded:t,isFocused:o=false,isMain:e=false})=>{return(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.expanderIcon,e&&styles.expanderIconMain,t?styles.expanded:styles.collapsed],children:t?(0,_jsxRuntime.jsx)(_sharedUi.ChevronDown,{size:e?14:EXPANDER_SIZE,color:o?_sharedUi.buoyColors.primary:e?_sharedUi.buoyColors.text:_sharedUi.buoyColors.textSecondary,strokeWidth:2.5}):(0,_jsxRuntime.jsx)(_sharedUi.ChevronRight,{size:e?14:EXPANDER_SIZE,color:o?_sharedUi.buoyColors.primary:e?_sharedUi.buoyColors.text:_sharedUi.buoyColors.textSecondary,strokeWidth:2.5})})});Expander.displayName="Expander";const CopyButton=(0,_react.memo)(({value:t,isFocused:o=false})=>{return(0,_jsxRuntime.jsx)(_sharedUi.CopyButton,{value:t,isFocused:o,buttonStyle:o?{...styles.buttonStyle,...styles.buttonStyleFocused}:styles.buttonStyle})});CopyButton.displayName="CopyButton";const DeleteItemButton=(0,_react.memo)(({dataPath:t,isFocused:o=false})=>{const e=(0,_editorContext.useResponseEditor)();const n=(0,_react.useCallback)(()=>{if(!e)return;e.onChange((0,_deleteNestedDataByPath.deleteNestedDataByPath)(e.root,t))},[e,t]);if(!e)return null;return(0,_jsxRuntime.jsx)(_reactNative.TouchableOpacity,{"sentry-label":"ignore devtools explorer delete button",onPress:n,style:[styles.deleteButton,o&&styles.deleteButtonFocused],accessibilityLabel:"Delete item",hitSlop:HIT_SLOP_OPTIMIZED,activeOpacity:.7,children:(0,_jsxRuntime.jsx)(_sharedUi.Trash,{size:14,strokeWidth:2,color:o?_sharedUi.buoyColors.error:_sharedUi.buoyColors.error+"CC"})})});DeleteItemButton.displayName="DeleteItemButton";const ClearArrayButton=(0,_react.memo)(({dataPath:t,isFocused:o=false})=>{const e=(0,_editorContext.useResponseEditor)();const n=(0,_react.useCallback)(()=>{if(!e)return;e.onChange((0,_updateNestedDataByPath.updateNestedDataByPath)(e.root,t,[]))},[e,t]);if(!e)return null;return(0,_jsxRuntime.jsx)(_reactNative.TouchableOpacity,{"sentry-label":"ignore devtools explorer clear button",style:[styles.clearButton,o&&styles.clearButtonFocused],"aria-label":"Remove all items",onPress:n,hitSlop:HIT_SLOP_OPTIMIZED,activeOpacity:.7,children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:[styles.clearButtonText,{color:o?_sharedUi.buoyColors.warning:_sharedUi.buoyColors.warning+"CC"}],children:"[]"})})});ClearArrayButton.displayName="ClearArrayButton";function ToggleValueButton({dataPath:t,value:o,itemsDeletable:e}){const n=(0,_editorContext.useResponseEditor)();const C=(0,_react.useCallback)(()=>{if(!n)return;const c=typeof o==="boolean"?o:false;n.onChange((0,_updateNestedDataByPath.updateNestedDataByPath)(n.root,t,!c))},[n,t,o]);const g=(0,_react.useCallback)(()=>{if(!n)return;n.onChange((0,_deleteNestedDataByPath.deleteNestedDataByPath)(n.root,t))},[n,t]);if(!n)return null;const b=o?styles.toggleBadgeTrue:styles.toggleBadgeFalse;const s=o?styles.toggleTextTrue:styles.toggleTextFalse;return(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{"sentry-label":"ignore devtools explorer toggle button",style:styles.modernToggleButton,onPress:C,hitSlop:HIT_SLOP_OPTIMIZED,activeOpacity:.8,children:[(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.toggleBadge,b],children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:[styles.toggleBadgeText,s],children:o?"TRUE":"FALSE"})}),e&&(0,_jsxRuntime.jsx)(_reactNative.TouchableOpacity,{"sentry-label":"ignore devtools explorer delete button in toggle",onPress:g,style:styles.deleteButtonInToggle,accessibilityLabel:"Delete item",hitSlop:HIT_SLOP_OPTIMIZED,activeOpacity:.7,children:(0,_jsxRuntime.jsx)(_sharedUi.Trash,{size:14,strokeWidth:2,color:_sharedUi.buoyColors.error+"CC"})})]})}function Explorer({editable:t,label:o,value:e,defaultExpanded:n,dataPath:C,itemsDeletable:g,dataVersion:b=0}){const s=(0,_editorContext.useResponseEditor)();const[c,w]=(0,_react.useState)(false);const[f,x]=(0,_react.useState)("");(0,_react.useEffect)(()=>{if(e!==null&&e!==void 0&&(typeof e==="string"||typeof e==="number")){const a=e.toString();x(a)}},[e,o,b]);const p=(0,_react.useMemo)(()=>{const a=o.toUpperCase();return["DATA","QUERY","QUERYKEY","TYPES","STATS","OPTIONS","OBSERVERS"].includes(a)},[o]);const[S,I]=(0,_react.useState)((n||[]).includes(o));const B=()=>I(a=>!a);const[R,F]=(0,_react.useState)([]);const h=(0,_react.useMemo)(()=>{if(e===null||e===void 0||typeof e!=="object"){return[]}if(Array.isArray(e)){const r=e.length>1e3?e.slice(0,1e3):e;return r.map((l,u)=>({label:u.toString(),value:l}))}if(e instanceof Map){const r=Array.from(e.entries()).slice(0,1e3);return r.map(([l,u])=>({label:l.toString(),value:u}))}if(e instanceof Set){const r=Array.from(e).slice(0,1e3);return r.map((l,u)=>({label:u.toString(),value:l}))}const a=Object.entries(e).slice(0,1e3);return a.map(([r,l])=>({label:r,value:l}))},[e]);const i=(0,_react.useMemo)(()=>{if(Array.isArray(e))return"array";if(e===null||typeof e!=="object")return typeof e;if(e instanceof Map||e instanceof Set)return"Iterable";return"object"},[e]);const y=(0,_react.useMemo)(()=>{return chunkArray(h,CHUNK_SIZE)},[h]);const d=C??[];const j=(0,_react.useRef)(s);const T=(0,_react.useRef)(d);const W=(0,_react.useRef)(i);j.current=s;T.current=d;W.current=i;const m=(0,_react.useCallback)((a,r)=>{x(r);const l=j.current;if(!l)return;if(a&&isNaN(Number(r)))return;const u=W.current==="number"?Number(r):r;l.onChange((0,_updateNestedDataByPath.updateNestedDataByPath)(l.root,T.current,u))},[x]);return(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.minWidthWrapper,children:(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.fullWidthMarginRight,children:[y.length>0&&(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:[styles.flexRowItemsCenterGap,p&&styles.flexRowItemsCenterGapMain],children:[(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{"sentry-label":"ignore devtools explorer expander button",style:styles.expanderButton,onPress:B,hitSlop:HIT_SLOP_OPTIMIZED,activeOpacity:.6,children:[(0,_jsxRuntime.jsx)(Expander,{expanded:S,isFocused:c,isMain:p}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:[styles.labelText,c&&styles.labelTextFocused,p&&styles.labelTextMain],children:o}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.textGray500,children:`${String(i).toLowerCase()==="iterable"?"(Iterable) ":""}${h.length} ${h.length>1?`items`:`item`}`})]}),t&&(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.flexRowGapItemsCenter,children:[(0,_jsxRuntime.jsx)(CopyButton,{value:e,isFocused:c}),g&&s!==null&&(0,_jsxRuntime.jsx)(DeleteItemButton,{dataPath:d,isFocused:c}),i==="array"&&s!==null&&(0,_jsxRuntime.jsx)(ClearArrayButton,{dataPath:d,isFocused:c})]})]}),S&&(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[y.length===1&&(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.singleEntryContainer,p&&styles.singleEntryContainerMain],children:h.map((a,r)=>(0,_jsxRuntime.jsx)(Explorer,{defaultExpanded:n,label:a.label,value:a.value,editable:t,dataPath:[...d,a.label],itemsDeletable:i==="array"||i==="Iterable"||i==="object",dataVersion:b},a.label+r))}),y.length>1&&(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.multiEntryContainer,children:y.map((a,r)=>(0,_jsxRuntime.jsx)(_reactNative.View,{children:(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.relativeOutlineNone,children:[(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{"sentry-label":"ignore devtools explorer page toggle",onPress:()=>F(l=>l.includes(r)?l.filter(u=>u!==r):[...l,r]),style:styles.pageExpanderButton,hitSlop:HIT_SLOP_OPTIMIZED,children:[(0,_jsxRuntime.jsx)(Expander,{expanded:R.includes(r)}),(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:styles.pageRangeText,children:["[",r*CHUNK_SIZE,"...",r*CHUNK_SIZE+CHUNK_SIZE-1,"]"]})]}),R.includes(r)&&(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.entriesContainer,children:a.map(l=>(0,_jsxRuntime.jsx)(Explorer,{defaultExpanded:n,label:l.label,value:l.value,editable:t,dataPath:[...d,l.label],dataVersion:b},l.label))})]})},r))})]})]}),y.length===0&&(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.flexRowGapFullWidth,children:[t&&s!==null&&(i==="string"||i==="number"||i==="boolean")?(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[t&&s&&(i==="string"||i==="number")&&(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.nebulaInputWrapper,children:(0,_jsxRuntime.jsx)(_dataViewer.CyberpunkInput,{label:o,accessibilityLabel:"Data input field for editing values",style:[i==="number"?styles.textNumber:styles.textString],keyboardType:i==="number"?"numeric":"default",value:f,onChangeText:a=>m(i==="number",a),onFocus:()=>w(true),onBlur:()=>w(false),showNumberControls:i==="number",onIncrement:()=>{const a=Number(f)||0;m(true,String(a+1))},onDecrement:()=>{const a=Number(f)||0;m(true,String(a-1))},showDeleteButton:g,onDelete:()=>{s.onChange((0,_deleteNestedDataByPath.deleteNestedDataByPath)(s.root,d))}})}),i==="boolean"&&(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.booleanRowContainer,children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.booleanLabel,children:o}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.booleanToggleWrapper,children:(0,_jsxRuntime.jsx)(ToggleValueButton,{dataPath:d,value:e,itemsDeletable:g})})]})]}):(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.text344054,children:o}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.displayValueText,children:(0,_sharedUi.displayValue)(e)})]}),t&&g&&s!==null&&i!=="string"&&i!=="number"&&i!=="boolean"&&(0,_jsxRuntime.jsx)(DeleteItemButton,{dataPath:d,isFocused:c})]})]})})}const styles=_reactNative.StyleSheet.create({buttonStyle:{backgroundColor:_sharedUi.buoyColors.card+"E6",borderWidth:1,borderColor:_sharedUi.buoyColors.textSecondary+"33",borderRadius:6,flexDirection:"row",alignItems:"center",justifyContent:"center",width:28,height:28,position:"relative",shadowColor:"#000",shadowOffset:{width:0,height:1},shadowOpacity:.2,shadowRadius:2},buttonStyleFocused:{borderColor:_sharedUi.buoyColors.primary+"CC",backgroundColor:_sharedUi.buoyColors.primary+"26",shadowColor:_sharedUi.buoyColors.primary,shadowOpacity:.3,shadowRadius:4},deleteButton:{backgroundColor:_sharedUi.buoyColors.error+"1A",borderColor:_sharedUi.buoyColors.error+"4D",borderWidth:1,borderRadius:6,padding:0,alignItems:"center",justifyContent:"center",width:28,height:28,position:"relative",shadowColor:_sharedUi.buoyColors.error,shadowOffset:{width:0,height:0},shadowOpacity:.15,shadowRadius:3},deleteButtonFocused:{borderColor:_sharedUi.buoyColors.error+"CC",backgroundColor:_sharedUi.buoyColors.error+"33",shadowOpacity:.3,shadowRadius:5},deleteButtonInToggle:{backgroundColor:_sharedUi.buoyColors.error+"1A",borderColor:_sharedUi.buoyColors.error+"4D",borderWidth:1,borderRadius:6,padding:0,alignItems:"center",justifyContent:"center",width:28,height:28,shadowColor:_sharedUi.buoyColors.error,shadowOffset:{width:0,height:0},shadowOpacity:.15,shadowRadius:3},clearButton:{backgroundColor:_sharedUi.buoyColors.warning+"1A",borderWidth:1,borderColor:_sharedUi.buoyColors.warning+"4D",borderRadius:6,flexDirection:"row",padding:0,alignItems:"center",justifyContent:"center",width:28,height:28,position:"relative",zIndex:10,shadowColor:_sharedUi.buoyColors.warning,shadowOffset:{width:0,height:0},shadowOpacity:.15,shadowRadius:3},clearButtonFocused:{borderColor:_sharedUi.buoyColors.warning+"CC",backgroundColor:_sharedUi.buoyColors.warning+"33",shadowOpacity:.3,shadowRadius:5},clearButtonText:{fontSize:12,fontWeight:"700",fontFamily:_sharedUi.monoFont},expanderIcon:{width:18,height:18,alignItems:"center",justifyContent:"center",marginRight:1,backgroundColor:_sharedUi.buoyColors.textSecondary+"14",borderRadius:3},expanderIconMain:{backgroundColor:_sharedUi.buoyColors.textSecondary+"1A",width:20,height:20,borderRadius:4,borderWidth:.5,borderColor:_sharedUi.buoyColors.textSecondary+"33"},expanded:{transform:[{rotate:"0deg"}]},collapsed:{transform:[{rotate:"0deg"}]},minWidthWrapper:{minWidth:180,fontSize:11,flexDirection:"row",flexWrap:"wrap",width:"100%",marginVertical:.5},fullWidthMarginRight:{position:"relative",width:"100%",marginRight:1},flexRowItemsCenterGap:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",paddingVertical:3,paddingHorizontal:6,marginVertical:1,borderRadius:4,backgroundColor:_sharedUi.buoyColors.card+"66",borderWidth:.5,borderColor:_sharedUi.buoyColors.textSecondary+"1A"},flexRowItemsCenterGapMain:{backgroundColor:_sharedUi.buoyColors.card+"E6",borderLeftWidth:2.5,borderLeftColor:_sharedUi.buoyColors.textSecondary+"80",borderColor:_sharedUi.buoyColors.textSecondary+"26",paddingVertical:5,paddingHorizontal:8,marginBottom:3,borderWidth:1,shadowColor:"#000",shadowOffset:{width:0,height:0},shadowOpacity:.08,shadowRadius:3},expanderButton:{flexDirection:"row",alignItems:"center",backgroundColor:"transparent",paddingVertical:1,paddingHorizontal:2,gap:6,borderWidth:0,minHeight:24,flex:1},labelText:{color:_sharedUi.buoyColors.textSecondary,fontSize:10,fontWeight:"600",marginRight:4,fontFamily:_sharedUi.monoFont,letterSpacing:.4},labelTextFocused:{color:_sharedUi.buoyColors.text},labelTextMain:{color:_sharedUi.buoyColors.text,fontSize:11,fontWeight:"700",letterSpacing:.6},textGray500:{color:_sharedUi.buoyColors.textMuted,fontSize:10,fontWeight:"400",fontFamily:_sharedUi.monoFont,opacity:.7},pageRangeText:{color:_sharedUi.buoyColors.textSecondary,fontSize:10,fontWeight:"600",fontFamily:_sharedUi.monoFont},flexRowGapItemsCenter:{flexDirection:"row",alignItems:"center",gap:4,paddingLeft:2},singleEntryContainer:{marginLeft:2,marginTop:2,paddingLeft:8,borderLeftWidth:1.5,borderLeftColor:_sharedUi.buoyColors.textSecondary+"40"},singleEntryContainerMain:{borderLeftColor:_sharedUi.buoyColors.textSecondary+"4D",marginLeft:4,paddingLeft:10},multiEntryContainer:{marginLeft:2,marginTop:2,paddingLeft:8,borderLeftWidth:1.5,borderLeftColor:_sharedUi.buoyColors.textSecondary+"40"},multiEntryContainerMain:{borderLeftColor:_sharedUi.buoyColors.textSecondary+"4D",marginLeft:4,paddingLeft:10},relativeOutlineNone:{position:"relative"},pageExpanderButton:{flexDirection:"row",alignItems:"center",backgroundColor:_sharedUi.buoyColors.card+"66",paddingVertical:3,paddingHorizontal:6,gap:6,borderRadius:4,borderWidth:.5,borderColor:_sharedUi.buoyColors.textSecondary+"1A",marginBottom:2,minHeight:24},entriesContainer:{marginLeft:2,paddingLeft:8,marginTop:2,borderLeftWidth:1.5,borderLeftColor:_sharedUi.buoyColors.textSecondary+"40"},textNumber:{color:_sharedUi.buoyColors.text,fontWeight:"600",fontFamily:_sharedUi.monoFont},textString:{color:_sharedUi.buoyColors.text,fontFamily:_sharedUi.monoFont},flexRowGapFullWidth:{flexDirection:"row",width:"100%",alignItems:"center",marginVertical:1,gap:6,paddingHorizontal:4,paddingVertical:2,borderRadius:3},text344054:{color:_sharedUi.buoyColors.textSecondary,fontWeight:"600",fontSize:9,minWidth:50,fontFamily:_sharedUi.monoFont,letterSpacing:.4,opacity:.8},numberInputButtons:{position:"absolute",right:8,top:"50%",transform:[{translateY:-18}],flexDirection:"row",gap:4,zIndex:10},touchableButton:{width:32,height:32,borderRadius:6,backgroundColor:_sharedUi.buoyColors.card+"E6",borderWidth:1,borderColor:_sharedUi.buoyColors.textSecondary+"33",alignItems:"center",justifyContent:"center",marginLeft:2,shadowColor:"#000",shadowOffset:{width:0,height:1},shadowOpacity:.2,shadowRadius:2},touchableButtonFocused:{borderColor:_sharedUi.buoyColors.primary+"CC",backgroundColor:_sharedUi.buoyColors.primary+"26",shadowColor:_sharedUi.buoyColors.primary,shadowOffset:{width:0,height:0},shadowOpacity:.3,shadowRadius:4,elevation:3},nebulaInputWrapper:{flex:1,width:"100%",position:"relative"},displayValueText:{flex:1,color:_sharedUi.buoyColors.text,fontWeight:"400",fontFamily:_sharedUi.monoFont,fontSize:12,paddingVertical:6,paddingHorizontal:10,borderRadius:6,borderWidth:1,borderColor:_sharedUi.buoyColors.textMuted+"66",minHeight:34},dataRow:{flexDirection:"row",alignItems:"center",paddingVertical:4,paddingHorizontal:8,minHeight:44,gap:12},dataLabel:{color:_sharedUi.buoyColors.textSecondary,fontSize:13,fontWeight:"500",minWidth:80,flexShrink:0},dataValueContainer:{flex:1,flexDirection:"row",alignItems:"center"},inputWithActions:{flex:1,position:"relative"},numberControls:{position:"absolute",right:8,top:"50%",transform:[{translateY:-16}],flexDirection:"column",gap:2},numberButton:{width:32,height:16,borderRadius:4,alignItems:"center",justifyContent:"center",borderWidth:1,borderColor:_sharedUi.buoyColors.primary+"0F"},readOnlyValue:{color:_sharedUi.buoyColors.text,fontSize:13,fontFamily:_sharedUi.monoFont,paddingVertical:8,paddingHorizontal:12,borderRadius:6,borderWidth:1,borderColor:_sharedUi.buoyColors.textMuted+"33",flex:1},actionButtons:{flexDirection:"row",gap:6,paddingLeft:8},booleanContainer:{flexDirection:"row",alignItems:"center",padding:8,borderRadius:6,borderWidth:1,borderColor:_sharedUi.buoyColors.textMuted+"4D",flex:1},booleanText:{marginLeft:8,color:_sharedUi.buoyColors.warning,fontWeight:"500",fontFamily:_sharedUi.monoFont},modernToggleButton:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",borderRadius:6,borderWidth:1,borderColor:_sharedUi.buoyColors.textMuted+"99",paddingHorizontal:8,paddingVertical:6,marginVertical:2,minHeight:34,gap:8},toggleIconContainer:{marginRight:6},toggleIcon:{padding:8,borderRadius:8,alignItems:"center",justifyContent:"center",width:32,height:32},toggleIconSmall:{width:8,height:8,borderRadius:4},toggleContent:{flex:1,minWidth:0},toggleLabel:{color:"#E5E7EB",fontSize:11,fontWeight:"600",fontFamily:_sharedUi.monoFont,letterSpacing:.3},toggleStatus:{color:"#9CA3AF",fontSize:11},toggleBadge:{marginLeft:6,paddingHorizontal:6,paddingVertical:3,borderRadius:4,borderWidth:1},toggleBadgeText:{fontSize:9,fontWeight:"700",textTransform:"uppercase",letterSpacing:.8,fontFamily:_sharedUi.monoFont},toggleIconTrue:{backgroundColor:_sharedUi.buoyColors.primary},toggleIconFalse:{backgroundColor:_sharedUi.buoyColors.textMuted},toggleBadgeTrue:{backgroundColor:_sharedUi.buoyColors.primary+"1A",borderColor:_sharedUi.buoyColors.primary+"4D"},toggleBadgeFalse:{backgroundColor:_sharedUi.buoyColors.textMuted+"1A",borderColor:_sharedUi.buoyColors.textMuted+"4D"},toggleTextTrue:{color:_sharedUi.buoyColors.primary,fontWeight:"600"},toggleTextFalse:{color:_sharedUi.buoyColors.textSecondary,fontWeight:"500"},booleanRowContainer:{flexDirection:"row",alignItems:"center",width:"100%",gap:8,paddingVertical:2},booleanLabel:{color:_sharedUi.buoyColors.textSecondary,fontSize:10,fontWeight:"600",fontFamily:_sharedUi.monoFont,letterSpacing:.4,minWidth:60,flexShrink:0},booleanToggleWrapper:{flex:1}});
|