@buoy-gg/network 7.0.40 → 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 -79
- package/lib/commonjs/index.js +1 -325
- 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 -404
- package/lib/commonjs/network/components/NetworkListScreen.web.js +1 -625
- 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 -110
- 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 -453
- package/lib/commonjs/network/overrides/engine.js +1 -93
- package/lib/commonjs/network/overrides/matchRule.js +1 -81
- package/lib/commonjs/network/overrides/overriddenRows.js +1 -0
- 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 -393
- package/lib/commonjs/network/utils/networkListener.js +4 -1259
- 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 -0
- package/lib/commonjs/network/utils/resolveRequestUrl.js +1 -0
- package/lib/commonjs/network/utils/selectSavedEvents.js +1 -39
- package/lib/commonjs/network/utils/startNetworkCapture.js +1 -0
- package/lib/commonjs/network/utils/withPinnedFirst.js +1 -32
- package/lib/commonjs/preset.js +1 -102
- package/lib/module/index.js +1 -103
- 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 -400
- package/lib/module/network/components/NetworkListScreen.web.js +1 -623
- 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 -106
- 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 -446
- package/lib/module/network/overrides/engine.js +1 -85
- package/lib/module/network/overrides/matchRule.js +1 -75
- package/lib/module/network/overrides/overriddenRows.js +1 -0
- 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 -391
- package/lib/module/network/utils/networkListener.js +4 -1249
- 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 -0
- package/lib/module/network/utils/resolveRequestUrl.js +1 -0
- package/lib/module/network/utils/selectSavedEvents.js +1 -35
- package/lib/module/network/utils/startNetworkCapture.js +1 -0
- package/lib/module/network/utils/withPinnedFirst.js +1 -28
- package/lib/module/preset.js +1 -100
- package/lib/typescript/index.d.ts +1 -0
- package/lib/typescript/network/overrides/applyToXhr.d.ts +1 -0
- 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/overriddenRows.d.ts +16 -0
- 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 +14 -4
- package/lib/typescript/network/utils/networkSavedStore.d.ts +4 -4
- package/lib/typescript/network/utils/realNow.d.ts +18 -0
- package/lib/typescript/network/utils/requestId.d.ts +2 -0
- package/lib/typescript/network/utils/resolveRequestUrl.d.ts +3 -0
- package/lib/typescript/network/utils/startNetworkCapture.d.ts +6 -0
- package/lib/web/index.mjs +145 -0
- package/package.json +32 -10
- 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/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/selectSavedEvents.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,623 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.NetworkClearButton = NetworkClearButton;
|
|
7
|
-
exports.NetworkDetailPinActions = NetworkDetailPinActions;
|
|
8
|
-
exports.NetworkHeaderBadges = NetworkHeaderBadges;
|
|
9
|
-
exports.NetworkHeaderCopyButton = NetworkHeaderCopyButton;
|
|
10
|
-
exports.NetworkSavedButton = NetworkSavedButton;
|
|
11
|
-
var _react = require("react");
|
|
12
|
-
var _sharedUi = require("@buoy-gg/shared-ui");
|
|
13
|
-
var _networkEventStore = require("../utils/networkEventStore");
|
|
14
|
-
var _networkSavedStore = require("../utils/networkSavedStore");
|
|
15
|
-
var _useNetworkSaved = require("../hooks/useNetworkSaved");
|
|
16
|
-
var _useNetworkSelection = require("../hooks/useNetworkSelection");
|
|
17
|
-
var _useNetworkBadgeCounts = require("../hooks/useNetworkBadgeCounts");
|
|
18
|
-
var _useNetworkHasMatches = require("../hooks/useNetworkHasMatches");
|
|
19
|
-
var _generateNetworkCopyText = require("../utils/generateNetworkCopyText");
|
|
20
|
-
var _filterNetworkEvents = require("../utils/filterNetworkEvents");
|
|
21
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
22
|
-
/**
|
|
23
|
-
* NetworkHeaderLive.web — DOM twin of NetworkHeaderLive.tsx.
|
|
24
|
-
*
|
|
25
|
-
* The header pieces that consume LIVE event data, each its own narrow store
|
|
26
|
-
* subscriber (same decomposition + hooks as native — `useNetworkBadgeCounts`,
|
|
27
|
-
* `useNetworkHasEvents`, `useNetworkSaved` are platform-free and reused, not
|
|
28
|
-
* forked):
|
|
29
|
-
*
|
|
30
|
-
* - `NetworkHeaderBadges` — success/error/pending count chips (tap toggles
|
|
31
|
-
* the status filter)
|
|
32
|
-
* - `NetworkClearButton` — trash button, enabled while the store has events
|
|
33
|
-
* - `NetworkSavedButton` — Saved-screen entry point with its live count
|
|
34
|
-
* - `NetworkDetailPinActions` — pin + save toggles for the request-DETAIL
|
|
35
|
-
* header (ported with the F3 detail-view feature; same flagsForEventId /
|
|
36
|
-
* cap logic and press-time event resolution as native)
|
|
37
|
-
* - `NetworkHeaderCopyButton` — copy-all button / labelled ⋯-menu row
|
|
38
|
-
* (ported with the F5 saved+copy feature; the copy text is the SAME
|
|
39
|
-
* platform-free `generateNetworkCopyText`, resolved lazily at press time
|
|
40
|
-
* from a live store read, exactly like native)
|
|
41
|
-
*
|
|
42
|
-
* shared-ui RN chrome is replicated as DOM with provenance (web consumers
|
|
43
|
-
* resolve `@buoy-gg/shared-ui` to a minimal shim):
|
|
44
|
-
* - `macOSColors` — inlined verbatim subset from
|
|
45
|
-
* shared/src/ui/gameUI/constants/macOSDesignSystemColors.ts.
|
|
46
|
-
* - Icons — inline lucide SVGs (shared-ui's icons are lucide re-exports).
|
|
47
|
-
* - The active chip's native shadow (shadowOffset 0/1, opacity 0.08,
|
|
48
|
-
* radius 2) → an equivalent CSS box-shadow.
|
|
49
|
-
* - shared-ui `CopyButton` (the Pro branch of the copy button) — inlined
|
|
50
|
-
* labelled DOM twin below: same idle/success/error icon set, 1500ms
|
|
51
|
-
* feedback, lazy function value, and label-follows-labelStyle behavior.
|
|
52
|
-
*
|
|
53
|
-
* Intentional deviations (all logged):
|
|
54
|
-
* - shared-ui CopyButton's ClipboardHintBanner and internal
|
|
55
|
-
* @buoy-gg/license Pro modal are not ported — license gating isn't part
|
|
56
|
-
* of the web port; the explicit `isPro` prop branch (native's own outer
|
|
57
|
-
* gate) still routes free users to `onUpgradePress`.
|
|
58
|
-
* - `CopySettings` is imported from the platform-free
|
|
59
|
-
* `generateNetworkCopyText` module (the native file imports it from
|
|
60
|
-
* NetworkCopySettingsView.tsx, which would drag react-native in).
|
|
61
|
-
*
|
|
62
|
-
* @platform React DOM Web
|
|
63
|
-
*/
|
|
64
|
-
|
|
65
|
-
// =============================
|
|
66
|
-
// Native palette (provenance)
|
|
67
|
-
// =============================
|
|
68
|
-
|
|
69
|
-
/** macOSColors subset — shared/src/ui/gameUI/constants/macOSDesignSystemColors.ts, verbatim. */const macOSColors = {
|
|
70
|
-
background: {
|
|
71
|
-
hover: "#1D1D1F"
|
|
72
|
-
},
|
|
73
|
-
border: {
|
|
74
|
-
default: "#2D2D2F"
|
|
75
|
-
},
|
|
76
|
-
text: {
|
|
77
|
-
primary: "#F5F5F7",
|
|
78
|
-
secondary: "#A1A1A6",
|
|
79
|
-
muted: "#8E8E93",
|
|
80
|
-
disabled: "#9E9EA0"
|
|
81
|
-
},
|
|
82
|
-
semantic: {
|
|
83
|
-
success: "#34C759",
|
|
84
|
-
error: "#FF453A",
|
|
85
|
-
warning: "#FFEB3B",
|
|
86
|
-
info: "#00B8E6",
|
|
87
|
-
infoBackground: "rgba(0, 184, 230, 0.1)",
|
|
88
|
-
debug: "#BF5AF2"
|
|
89
|
-
}
|
|
90
|
-
};
|
|
91
|
-
|
|
92
|
-
// =============================
|
|
93
|
-
// Inline lucide icons (shared-ui icons are lucide re-exports)
|
|
94
|
-
// =============================
|
|
95
|
-
|
|
96
|
-
function Svg({
|
|
97
|
-
size = 14,
|
|
98
|
-
color = "currentColor",
|
|
99
|
-
children
|
|
100
|
-
}) {
|
|
101
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)("svg", {
|
|
102
|
-
width: size,
|
|
103
|
-
height: size,
|
|
104
|
-
viewBox: "0 0 24 24",
|
|
105
|
-
fill: "none",
|
|
106
|
-
stroke: color,
|
|
107
|
-
strokeWidth: 2,
|
|
108
|
-
strokeLinecap: "round",
|
|
109
|
-
strokeLinejoin: "round",
|
|
110
|
-
style: {
|
|
111
|
-
flexShrink: 0,
|
|
112
|
-
display: "block"
|
|
113
|
-
},
|
|
114
|
-
children: children
|
|
115
|
-
});
|
|
116
|
-
}
|
|
117
|
-
const CheckCircle = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
118
|
-
...p,
|
|
119
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
120
|
-
d: "M21.801 10A10 10 0 1 1 17 3.335"
|
|
121
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
122
|
-
d: "m9 11 3 3L22 4"
|
|
123
|
-
})]
|
|
124
|
-
});
|
|
125
|
-
const XCircle = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
126
|
-
...p,
|
|
127
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("circle", {
|
|
128
|
-
cx: "12",
|
|
129
|
-
cy: "12",
|
|
130
|
-
r: "10"
|
|
131
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
132
|
-
d: "m15 9-6 6"
|
|
133
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
134
|
-
d: "m9 9 6 6"
|
|
135
|
-
})]
|
|
136
|
-
});
|
|
137
|
-
const Clock = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
138
|
-
...p,
|
|
139
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("circle", {
|
|
140
|
-
cx: "12",
|
|
141
|
-
cy: "12",
|
|
142
|
-
r: "10"
|
|
143
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("polyline", {
|
|
144
|
-
points: "12 6 12 12 16 14"
|
|
145
|
-
})]
|
|
146
|
-
});
|
|
147
|
-
const Trash2 = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
148
|
-
...p,
|
|
149
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
150
|
-
d: "M3 6h18"
|
|
151
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
152
|
-
d: "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6"
|
|
153
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
154
|
-
d: "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"
|
|
155
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("line", {
|
|
156
|
-
x1: "10",
|
|
157
|
-
x2: "10",
|
|
158
|
-
y1: "11",
|
|
159
|
-
y2: "17"
|
|
160
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("line", {
|
|
161
|
-
x1: "14",
|
|
162
|
-
x2: "14",
|
|
163
|
-
y1: "11",
|
|
164
|
-
y2: "17"
|
|
165
|
-
})]
|
|
166
|
-
});
|
|
167
|
-
const Bookmark = p => /*#__PURE__*/(0, _jsxRuntime.jsx)(Svg, {
|
|
168
|
-
...p,
|
|
169
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
170
|
-
d: "m19 21-7-4-7 4V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v16z"
|
|
171
|
-
})
|
|
172
|
-
});
|
|
173
|
-
const Pin = ({
|
|
174
|
-
active,
|
|
175
|
-
...p
|
|
176
|
-
}) => /*#__PURE__*/(0, _jsxRuntime.jsx)(Svg, {
|
|
177
|
-
...p,
|
|
178
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("g", {
|
|
179
|
-
transform: active ? "rotate(-45 12 12) translate(12 12) scale(0.92) translate(-12 -12)" : undefined,
|
|
180
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
181
|
-
d: "M2.97 21.03 8.18 15.82"
|
|
182
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
183
|
-
d: "M4.4 10.81 13.19 19.6"
|
|
184
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
185
|
-
d: "M5.17 10.54 11.43 8.83"
|
|
186
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
187
|
-
d: "M13.46 18.83 15.17 12.57"
|
|
188
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("rect", {
|
|
189
|
-
x: "12.15",
|
|
190
|
-
y: "5.4",
|
|
191
|
-
width: "9.38",
|
|
192
|
-
height: "3.52",
|
|
193
|
-
rx: "1.07",
|
|
194
|
-
transform: "rotate(-45 16.84 7.16)"
|
|
195
|
-
})]
|
|
196
|
-
})
|
|
197
|
-
});
|
|
198
|
-
const Copy = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
199
|
-
...p,
|
|
200
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("rect", {
|
|
201
|
-
width: "14",
|
|
202
|
-
height: "14",
|
|
203
|
-
x: "8",
|
|
204
|
-
y: "8",
|
|
205
|
-
rx: "2",
|
|
206
|
-
ry: "2"
|
|
207
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
208
|
-
d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"
|
|
209
|
-
})]
|
|
210
|
-
});
|
|
211
|
-
const CheckCircle2 = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
212
|
-
...p,
|
|
213
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("circle", {
|
|
214
|
-
cx: "12",
|
|
215
|
-
cy: "12",
|
|
216
|
-
r: "10"
|
|
217
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
218
|
-
d: "m9 12 2 2 4-4"
|
|
219
|
-
})]
|
|
220
|
-
});
|
|
221
|
-
const AlertTriangle = p => /*#__PURE__*/(0, _jsxRuntime.jsxs)(Svg, {
|
|
222
|
-
...p,
|
|
223
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
224
|
-
d: "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"
|
|
225
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
226
|
-
d: "M12 9v4"
|
|
227
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("path", {
|
|
228
|
-
d: "M12 17h.01"
|
|
229
|
-
})]
|
|
230
|
-
});
|
|
231
|
-
/** Success / error / pending chips — tap to toggle the status filter. */
|
|
232
|
-
function NetworkHeaderBadges({
|
|
233
|
-
activeStatus,
|
|
234
|
-
onToggleStatus,
|
|
235
|
-
ignoredPatterns,
|
|
236
|
-
paused
|
|
237
|
-
}) {
|
|
238
|
-
const counts = (0, _useNetworkBadgeCounts.useNetworkBadgeCounts)({
|
|
239
|
-
ignoredPatterns,
|
|
240
|
-
paused
|
|
241
|
-
});
|
|
242
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
243
|
-
style: styles.headerChipRow,
|
|
244
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("button", {
|
|
245
|
-
type: "button",
|
|
246
|
-
style: {
|
|
247
|
-
...styles.headerChip,
|
|
248
|
-
...(activeStatus === "success" ? styles.headerChipActive : null)
|
|
249
|
-
},
|
|
250
|
-
onClick: () => onToggleStatus("success"),
|
|
251
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(CheckCircle, {
|
|
252
|
-
size: 12,
|
|
253
|
-
color: macOSColors.semantic.success
|
|
254
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
255
|
-
style: {
|
|
256
|
-
...styles.headerChipValue,
|
|
257
|
-
color: macOSColors.semantic.success
|
|
258
|
-
},
|
|
259
|
-
children: counts.successful
|
|
260
|
-
})]
|
|
261
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("button", {
|
|
262
|
-
type: "button",
|
|
263
|
-
style: {
|
|
264
|
-
...styles.headerChip,
|
|
265
|
-
...(activeStatus === "error" ? styles.headerChipActive : null)
|
|
266
|
-
},
|
|
267
|
-
onClick: () => onToggleStatus("error"),
|
|
268
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(XCircle, {
|
|
269
|
-
size: 12,
|
|
270
|
-
color: macOSColors.semantic.error
|
|
271
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
272
|
-
style: {
|
|
273
|
-
...styles.headerChipValue,
|
|
274
|
-
color: macOSColors.semantic.error
|
|
275
|
-
},
|
|
276
|
-
children: counts.failed
|
|
277
|
-
})]
|
|
278
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("button", {
|
|
279
|
-
type: "button",
|
|
280
|
-
style: {
|
|
281
|
-
...styles.headerChip,
|
|
282
|
-
...(activeStatus === "pending" ? styles.headerChipActive : null)
|
|
283
|
-
},
|
|
284
|
-
onClick: () => onToggleStatus("pending"),
|
|
285
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Clock, {
|
|
286
|
-
size: 12,
|
|
287
|
-
color: macOSColors.semantic.warning
|
|
288
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
289
|
-
style: {
|
|
290
|
-
...styles.headerChipValue,
|
|
291
|
-
color: macOSColors.semantic.warning
|
|
292
|
-
},
|
|
293
|
-
children: counts.pending
|
|
294
|
-
})]
|
|
295
|
-
})]
|
|
296
|
-
});
|
|
297
|
-
}
|
|
298
|
-
/** Trash button — handler co-located; enabled while the store has events.
|
|
299
|
-
* Subscribes to a flip-guarded boolean, so it renders when the store goes
|
|
300
|
-
* empty↔non-empty, not on every count change. */
|
|
301
|
-
function NetworkClearButton({
|
|
302
|
-
paused
|
|
303
|
-
}) {
|
|
304
|
-
const hasEvents = (0, _useNetworkHasMatches.useNetworkHasEvents)({
|
|
305
|
-
paused
|
|
306
|
-
});
|
|
307
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)("button", {
|
|
308
|
-
type: "button",
|
|
309
|
-
"aria-label": "Clear network requests",
|
|
310
|
-
onClick: () => _networkEventStore.networkEventStore.clearEvents(),
|
|
311
|
-
style: {
|
|
312
|
-
...styles.headerActionButton,
|
|
313
|
-
...(!hasEvents ? styles.headerActionButtonDisabled : null)
|
|
314
|
-
},
|
|
315
|
-
disabled: !hasEvents,
|
|
316
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(Trash2, {
|
|
317
|
-
size: 14,
|
|
318
|
-
color: hasEvents ? macOSColors.text.muted : macOSColors.text.disabled
|
|
319
|
-
})
|
|
320
|
-
});
|
|
321
|
-
}
|
|
322
|
-
/**
|
|
323
|
-
* Entry point to the Saved screen, with its count. A self-subscribing leaf so
|
|
324
|
-
* the badge tracks the store without the modal header re-rendering.
|
|
325
|
-
*/
|
|
326
|
-
function NetworkSavedButton({
|
|
327
|
-
onPress
|
|
328
|
-
}) {
|
|
329
|
-
const {
|
|
330
|
-
savedRecords
|
|
331
|
-
} = (0, _useNetworkSaved.useNetworkSaved)();
|
|
332
|
-
const count = savedRecords.length;
|
|
333
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("button", {
|
|
334
|
-
type: "button",
|
|
335
|
-
onClick: onPress,
|
|
336
|
-
"aria-label": "Saved requests",
|
|
337
|
-
style: styles.headerActionButton,
|
|
338
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Bookmark, {
|
|
339
|
-
size: 14,
|
|
340
|
-
color: count > 0 ? macOSColors.semantic.debug : macOSColors.text.muted
|
|
341
|
-
}), count > 0 ? /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
342
|
-
style: styles.savedBadge,
|
|
343
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
344
|
-
style: styles.savedBadgeText,
|
|
345
|
-
children: count > 99 ? "99+" : count
|
|
346
|
-
})
|
|
347
|
-
}) : null]
|
|
348
|
-
});
|
|
349
|
-
}
|
|
350
|
-
/**
|
|
351
|
-
* Pin + Save toggles for the request-detail header — same self-subscribing
|
|
352
|
-
* leaf as native, for the same two reasons: the host root stays free of
|
|
353
|
-
* subscriptions, and these buttons deliberately do NOT live inside
|
|
354
|
-
* `NetworkEventDetailView` (the Events tool renders that same detail view
|
|
355
|
-
* with no saved store behind it).
|
|
356
|
-
*
|
|
357
|
-
* The event object is resolved at PRESS time (live store first, then the
|
|
358
|
-
* saved snapshot), and the selected id is SUBSCRIBED here rather than passed
|
|
359
|
-
* down, so stepping through requests doesn't rebuild the host header.
|
|
360
|
-
*/
|
|
361
|
-
function NetworkDetailPinActions({
|
|
362
|
-
isPro,
|
|
363
|
-
onUpgradePress
|
|
364
|
-
}) {
|
|
365
|
-
const eventId = (0, _useNetworkSelection.useSelectedNetworkEventId)();
|
|
366
|
-
const state = (0, _useNetworkSaved.useNetworkSaved)();
|
|
367
|
-
const {
|
|
368
|
-
pinned,
|
|
369
|
-
saved
|
|
370
|
-
} = (0, _networkSavedStore.flagsForEventId)(state, eventId);
|
|
371
|
-
const savedLimit = (0, _sharedUi.useLimit)("network.saved");
|
|
372
|
-
const atPinCap = !pinned && state.pinnedEvents.length >= _networkSavedStore.MAX_PINNED;
|
|
373
|
-
const atSavedCap = !saved && state.savedRecords.length >= savedLimit;
|
|
374
|
-
const resolveEvent = () => {
|
|
375
|
-
if (!eventId) return null;
|
|
376
|
-
return _networkEventStore.networkEventStore.getEvents().find(event => event.id === eventId) ?? _networkSavedStore.networkSavedStore.getEventById(eventId);
|
|
377
|
-
};
|
|
378
|
-
const handlePin = () => {
|
|
379
|
-
const event = resolveEvent();
|
|
380
|
-
if (event) state.togglePin(event);
|
|
381
|
-
};
|
|
382
|
-
const handleSave = () => {
|
|
383
|
-
// Hitting the free ceiling is an upgrade moment, not a dead button.
|
|
384
|
-
if (atSavedCap && !isPro) {
|
|
385
|
-
onUpgradePress();
|
|
386
|
-
return;
|
|
387
|
-
}
|
|
388
|
-
const event = resolveEvent();
|
|
389
|
-
if (event) state.toggleSave(event);
|
|
390
|
-
};
|
|
391
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
392
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("button", {
|
|
393
|
-
type: "button",
|
|
394
|
-
onClick: handlePin,
|
|
395
|
-
disabled: atPinCap,
|
|
396
|
-
"aria-label": pinned ? "Unpin request" : "Pin request",
|
|
397
|
-
title: atPinCap ? `Pin limit reached (${_networkSavedStore.MAX_PINNED})` : undefined,
|
|
398
|
-
style: {
|
|
399
|
-
...styles.headerActionButton,
|
|
400
|
-
...(pinned ? styles.headerActionButtonActive : null),
|
|
401
|
-
...(atPinCap ? styles.headerActionButtonDisabled : null)
|
|
402
|
-
},
|
|
403
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(Pin, {
|
|
404
|
-
size: 14,
|
|
405
|
-
active: pinned,
|
|
406
|
-
color: pinned ? macOSColors.semantic.info : atPinCap ? macOSColors.text.disabled : macOSColors.text.secondary
|
|
407
|
-
})
|
|
408
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("button", {
|
|
409
|
-
type: "button",
|
|
410
|
-
onClick: handleSave,
|
|
411
|
-
disabled: atSavedCap && isPro,
|
|
412
|
-
"aria-label": saved ? "Remove from saved" : "Save request",
|
|
413
|
-
title: atSavedCap && isPro ? `Saved limit reached (${_networkSavedStore.MAX_SAVED})` : undefined,
|
|
414
|
-
style: {
|
|
415
|
-
...styles.headerActionButton,
|
|
416
|
-
...(saved ? styles.headerActionButtonSaved : null),
|
|
417
|
-
...(atSavedCap && isPro ? styles.headerActionButtonDisabled : null)
|
|
418
|
-
},
|
|
419
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(Bookmark, {
|
|
420
|
-
size: 14,
|
|
421
|
-
color: saved ? macOSColors.semantic.debug : atSavedCap && isPro ? macOSColors.text.disabled : macOSColors.text.secondary
|
|
422
|
-
})
|
|
423
|
-
})]
|
|
424
|
-
});
|
|
425
|
-
}
|
|
426
|
-
/**
|
|
427
|
-
* Copy-all-requests button. Subscribes to a flip-guarded boolean (its
|
|
428
|
-
* enabled state); the copy text is generated at PRESS time from a live
|
|
429
|
-
* store read, so there's no per-event work and no stale closure.
|
|
430
|
-
*
|
|
431
|
-
* The Pro branch inlines shared-ui CopyButton's copy/feedback loop (same
|
|
432
|
-
* icon set, 1500ms feedback, label keeps its own color while the icon
|
|
433
|
-
* follows the state — native's `labelStyle` wins over the state color).
|
|
434
|
-
*/
|
|
435
|
-
function NetworkHeaderCopyButton({
|
|
436
|
-
isPro,
|
|
437
|
-
filter,
|
|
438
|
-
ignoredPatterns,
|
|
439
|
-
copySettings,
|
|
440
|
-
paused,
|
|
441
|
-
onUpgradePress,
|
|
442
|
-
label
|
|
443
|
-
}) {
|
|
444
|
-
const hasEvents = (0, _useNetworkHasMatches.useNetworkHasMatches)({
|
|
445
|
-
filter,
|
|
446
|
-
ignoredPatterns,
|
|
447
|
-
paused
|
|
448
|
-
});
|
|
449
|
-
const [copyState, setCopyState] = (0, _react.useState)("idle");
|
|
450
|
-
const timeoutRef = (0, _react.useRef)(null);
|
|
451
|
-
(0, _react.useEffect)(() => () => {
|
|
452
|
-
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
453
|
-
}, []);
|
|
454
|
-
if (!isPro) {
|
|
455
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("button", {
|
|
456
|
-
type: "button",
|
|
457
|
-
onClick: onUpgradePress,
|
|
458
|
-
style: {
|
|
459
|
-
...(label ? styles.copyMenuRow : styles.headerActionButton),
|
|
460
|
-
...(!hasEvents ? styles.headerActionButtonDisabled : null)
|
|
461
|
-
},
|
|
462
|
-
disabled: !hasEvents,
|
|
463
|
-
"aria-label": label ?? "Copy requests",
|
|
464
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Copy, {
|
|
465
|
-
size: 14,
|
|
466
|
-
color: hasEvents ? macOSColors.text.secondary : macOSColors.text.disabled
|
|
467
|
-
}), label ? /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
468
|
-
style: styles.copyMenuLabel,
|
|
469
|
-
children: label
|
|
470
|
-
}) : null]
|
|
471
|
-
});
|
|
472
|
-
}
|
|
473
|
-
const settle = state => {
|
|
474
|
-
setCopyState(state);
|
|
475
|
-
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
476
|
-
// 1500ms — shared-ui CopyButton's `feedbackDuration` default.
|
|
477
|
-
timeoutRef.current = setTimeout(() => {
|
|
478
|
-
setCopyState("idle");
|
|
479
|
-
timeoutRef.current = null;
|
|
480
|
-
}, 1500);
|
|
481
|
-
};
|
|
482
|
-
const handleCopy = async () => {
|
|
483
|
-
try {
|
|
484
|
-
// Lazy value: resolved at copy time from the LIVE store — no per-event
|
|
485
|
-
// work, no staleness (native's CopyButton function-value contract).
|
|
486
|
-
const text = (0, _generateNetworkCopyText.generateNetworkCopyText)((0, _filterNetworkEvents.filterNetworkEvents)((0, _filterNetworkEvents.applyIgnoredPatterns)(_networkEventStore.networkEventStore.getEvents(), ignoredPatterns), filter), copySettings);
|
|
487
|
-
await navigator.clipboard.writeText(text);
|
|
488
|
-
settle("success");
|
|
489
|
-
} catch {
|
|
490
|
-
settle("error");
|
|
491
|
-
}
|
|
492
|
-
};
|
|
493
|
-
const iconColor = copyState === "success" ? macOSColors.semantic.success : copyState === "error" ? macOSColors.semantic.error : hasEvents ? macOSColors.text.secondary : macOSColors.text.disabled;
|
|
494
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("button", {
|
|
495
|
-
type: "button",
|
|
496
|
-
onClick: copyState === "idle" ? handleCopy : undefined,
|
|
497
|
-
style: {
|
|
498
|
-
...(label ? styles.copyMenuRow : styles.headerActionButton),
|
|
499
|
-
...(!hasEvents ? styles.headerActionButtonDisabled : null)
|
|
500
|
-
},
|
|
501
|
-
disabled: !hasEvents,
|
|
502
|
-
"aria-label": copyState === "idle" ? label ?? "Copy to clipboard" : copyState === "success" ? "Copied to clipboard" : "Failed to copy",
|
|
503
|
-
children: [copyState === "success" ? /*#__PURE__*/(0, _jsxRuntime.jsx)(CheckCircle2, {
|
|
504
|
-
size: 14,
|
|
505
|
-
color: iconColor
|
|
506
|
-
}) : copyState === "error" ? /*#__PURE__*/(0, _jsxRuntime.jsx)(AlertTriangle, {
|
|
507
|
-
size: 14,
|
|
508
|
-
color: iconColor
|
|
509
|
-
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(Copy, {
|
|
510
|
-
size: 14,
|
|
511
|
-
color: iconColor
|
|
512
|
-
}), label ? /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
513
|
-
style: styles.copyMenuLabel,
|
|
514
|
-
children: label
|
|
515
|
-
}) : null]
|
|
516
|
-
});
|
|
517
|
-
}
|
|
518
|
-
|
|
519
|
-
// Values mirror the native StyleSheet block 1:1.
|
|
520
|
-
const styles = {
|
|
521
|
-
/** The overflow-menu variant: a full-width row, matching the other items. */
|
|
522
|
-
copyMenuRow: {
|
|
523
|
-
display: "flex",
|
|
524
|
-
width: "100%",
|
|
525
|
-
boxSizing: "border-box",
|
|
526
|
-
flexDirection: "row",
|
|
527
|
-
alignItems: "center",
|
|
528
|
-
gap: 10,
|
|
529
|
-
padding: "11px 6px",
|
|
530
|
-
justifyContent: "flex-start",
|
|
531
|
-
background: "none",
|
|
532
|
-
border: "none",
|
|
533
|
-
cursor: "pointer",
|
|
534
|
-
margin: 0,
|
|
535
|
-
fontFamily: "inherit",
|
|
536
|
-
textAlign: "left"
|
|
537
|
-
},
|
|
538
|
-
copyMenuLabel: {
|
|
539
|
-
fontSize: 13,
|
|
540
|
-
fontWeight: 600,
|
|
541
|
-
color: macOSColors.text.primary
|
|
542
|
-
},
|
|
543
|
-
headerChipRow: {
|
|
544
|
-
display: "flex",
|
|
545
|
-
flexDirection: "row",
|
|
546
|
-
alignItems: "center",
|
|
547
|
-
gap: 8
|
|
548
|
-
},
|
|
549
|
-
/**
|
|
550
|
-
* Counter chips and toolbar buttons carry a permanent outline; the fill
|
|
551
|
-
* marks the active filter.
|
|
552
|
-
*/
|
|
553
|
-
headerChip: {
|
|
554
|
-
display: "inline-flex",
|
|
555
|
-
flexDirection: "row",
|
|
556
|
-
alignItems: "center",
|
|
557
|
-
gap: 4,
|
|
558
|
-
backgroundColor: macOSColors.background.hover,
|
|
559
|
-
padding: "5px 10px",
|
|
560
|
-
borderRadius: 12,
|
|
561
|
-
border: `1px solid ${macOSColors.border.default}`,
|
|
562
|
-
cursor: "pointer",
|
|
563
|
-
margin: 0
|
|
564
|
-
},
|
|
565
|
-
headerChipActive: {
|
|
566
|
-
backgroundColor: macOSColors.semantic.infoBackground,
|
|
567
|
-
border: `1px solid ${macOSColors.semantic.info}50`,
|
|
568
|
-
// Native: shadowColor info, offset 0/1, opacity 0.08, radius 2.
|
|
569
|
-
boxShadow: "0 1px 2px rgba(0, 184, 230, 0.08)"
|
|
570
|
-
},
|
|
571
|
-
headerChipValue: {
|
|
572
|
-
fontSize: 12,
|
|
573
|
-
fontWeight: 600,
|
|
574
|
-
fontFamily: "ui-monospace, Menlo, monospace"
|
|
575
|
-
},
|
|
576
|
-
headerActionButton: {
|
|
577
|
-
position: "relative",
|
|
578
|
-
display: "inline-flex",
|
|
579
|
-
width: 32,
|
|
580
|
-
height: 32,
|
|
581
|
-
boxSizing: "border-box",
|
|
582
|
-
borderRadius: 8,
|
|
583
|
-
backgroundColor: macOSColors.background.hover,
|
|
584
|
-
border: `1px solid ${macOSColors.border.default}`,
|
|
585
|
-
alignItems: "center",
|
|
586
|
-
justifyContent: "center",
|
|
587
|
-
cursor: "pointer",
|
|
588
|
-
padding: 0,
|
|
589
|
-
margin: 0
|
|
590
|
-
},
|
|
591
|
-
headerActionButtonDisabled: {
|
|
592
|
-
opacity: 0.55,
|
|
593
|
-
cursor: "default"
|
|
594
|
-
},
|
|
595
|
-
headerActionButtonActive: {
|
|
596
|
-
backgroundColor: macOSColors.semantic.infoBackground,
|
|
597
|
-
border: `1px solid ${macOSColors.semantic.info}50`
|
|
598
|
-
},
|
|
599
|
-
headerActionButtonSaved: {
|
|
600
|
-
backgroundColor: `${macOSColors.semantic.debug}1A`,
|
|
601
|
-
border: `1px solid ${macOSColors.semantic.debug}50`
|
|
602
|
-
},
|
|
603
|
-
savedBadge: {
|
|
604
|
-
position: "absolute",
|
|
605
|
-
top: -3,
|
|
606
|
-
right: -3,
|
|
607
|
-
minWidth: 14,
|
|
608
|
-
height: 14,
|
|
609
|
-
boxSizing: "border-box",
|
|
610
|
-
padding: "0 3px",
|
|
611
|
-
borderRadius: 7,
|
|
612
|
-
backgroundColor: macOSColors.semantic.debug,
|
|
613
|
-
display: "inline-flex",
|
|
614
|
-
alignItems: "center",
|
|
615
|
-
justifyContent: "center"
|
|
616
|
-
},
|
|
617
|
-
savedBadgeText: {
|
|
618
|
-
color: "#FFFFFF",
|
|
619
|
-
fontSize: 9,
|
|
620
|
-
fontWeight: 700,
|
|
621
|
-
fontFamily: "ui-monospace, Menlo, monospace"
|
|
622
|
-
}
|
|
623
|
-
};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.NetworkClearButton=NetworkClearButton;exports.NetworkDetailPinActions=NetworkDetailPinActions;exports.NetworkHeaderBadges=NetworkHeaderBadges;exports.NetworkHeaderCopyButton=NetworkHeaderCopyButton;exports.NetworkSavedButton=NetworkSavedButton;var _react=require("react");var _sharedUi=require("@buoy-gg/shared-ui");var _networkEventStore=require("../utils/networkEventStore");var _networkSavedStore=require("../utils/networkSavedStore");var _useNetworkSaved=require("../hooks/useNetworkSaved");var _useNetworkSelection=require("../hooks/useNetworkSelection");var _useNetworkBadgeCounts=require("../hooks/useNetworkBadgeCounts");var _useNetworkHasMatches=require("../hooks/useNetworkHasMatches");var _generateNetworkCopyText=require("../utils/generateNetworkCopyText");var _filterNetworkEvents=require("../utils/filterNetworkEvents");var _jsxRuntime=require("react/jsx-runtime");const macOSColors={background:{hover:"#1D1D1F"},border:{default:"#2D2D2F"},text:{primary:"#F5F5F7",secondary:"#A1A1A6",muted:"#8E8E93",disabled:"#9E9EA0"},semantic:{success:"#34C759",error:"#FF453A",warning:"#FFEB3B",info:"#00B8E6",infoBackground:"rgba(0, 184, 230, 0.1)",debug:"#BF5AF2"}};function Svg({size:e=14,color:t="currentColor",children:r}){return(0,_jsxRuntime.jsx)("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"none",stroke:t,strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round",style:{flexShrink:0,display:"block"},children:r})}const CheckCircle=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("path",{d:"M21.801 10A10 10 0 1 1 17 3.335"}),(0,_jsxRuntime.jsx)("path",{d:"m9 11 3 3L22 4"})]});const XCircle=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,_jsxRuntime.jsx)("path",{d:"m15 9-6 6"}),(0,_jsxRuntime.jsx)("path",{d:"m9 9 6 6"})]});const Clock=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,_jsxRuntime.jsx)("polyline",{points:"12 6 12 12 16 14"})]});const Trash2=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("path",{d:"M3 6h18"}),(0,_jsxRuntime.jsx)("path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6"}),(0,_jsxRuntime.jsx)("path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"}),(0,_jsxRuntime.jsx)("line",{x1:"10",x2:"10",y1:"11",y2:"17"}),(0,_jsxRuntime.jsx)("line",{x1:"14",x2:"14",y1:"11",y2:"17"})]});const Bookmark=e=>(0,_jsxRuntime.jsx)(Svg,{...e,children:(0,_jsxRuntime.jsx)("path",{d:"m19 21-7-4-7 4V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v16z"})});const Pin=({active:e,...t})=>(0,_jsxRuntime.jsx)(Svg,{...t,children:(0,_jsxRuntime.jsxs)("g",{transform:e?"rotate(-45 12 12) translate(12 12) scale(0.92) translate(-12 -12)":void 0,children:[(0,_jsxRuntime.jsx)("path",{d:"M2.97 21.03 8.18 15.82"}),(0,_jsxRuntime.jsx)("path",{d:"M4.4 10.81 13.19 19.6"}),(0,_jsxRuntime.jsx)("path",{d:"M5.17 10.54 11.43 8.83"}),(0,_jsxRuntime.jsx)("path",{d:"M13.46 18.83 15.17 12.57"}),(0,_jsxRuntime.jsx)("rect",{x:"12.15",y:"5.4",width:"9.38",height:"3.52",rx:"1.07",transform:"rotate(-45 16.84 7.16)"})]})});const Copy=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2"}),(0,_jsxRuntime.jsx)("path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"})]});const CheckCircle2=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("circle",{cx:"12",cy:"12",r:"10"}),(0,_jsxRuntime.jsx)("path",{d:"m9 12 2 2 4-4"})]});const AlertTriangle=e=>(0,_jsxRuntime.jsxs)(Svg,{...e,children:[(0,_jsxRuntime.jsx)("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"}),(0,_jsxRuntime.jsx)("path",{d:"M12 9v4"}),(0,_jsxRuntime.jsx)("path",{d:"M12 17h.01"})]});function NetworkHeaderBadges({activeStatus:e,onToggleStatus:t,ignoredPatterns:r,paused:a}){const o=(0,_useNetworkBadgeCounts.useNetworkBadgeCounts)({ignoredPatterns:r,paused:a});return(0,_jsxRuntime.jsxs)("div",{style:styles.headerChipRow,children:[(0,_jsxRuntime.jsxs)("button",{type:"button",style:{...styles.headerChip,...e==="success"?styles.headerChipActive:null},onClick:()=>t("success"),children:[(0,_jsxRuntime.jsx)(CheckCircle,{size:12,color:macOSColors.semantic.success}),(0,_jsxRuntime.jsx)("span",{style:{...styles.headerChipValue,color:macOSColors.semantic.success},children:o.successful})]}),(0,_jsxRuntime.jsxs)("button",{type:"button",style:{...styles.headerChip,...e==="error"?styles.headerChipActive:null},onClick:()=>t("error"),children:[(0,_jsxRuntime.jsx)(XCircle,{size:12,color:macOSColors.semantic.error}),(0,_jsxRuntime.jsx)("span",{style:{...styles.headerChipValue,color:macOSColors.semantic.error},children:o.failed})]}),(0,_jsxRuntime.jsxs)("button",{type:"button",style:{...styles.headerChip,...e==="pending"?styles.headerChipActive:null},onClick:()=>t("pending"),children:[(0,_jsxRuntime.jsx)(Clock,{size:12,color:macOSColors.semantic.warning}),(0,_jsxRuntime.jsx)("span",{style:{...styles.headerChipValue,color:macOSColors.semantic.warning},children:o.pending})]})]})}function NetworkClearButton({paused:e}){const t=(0,_useNetworkHasMatches.useNetworkHasEvents)({paused:e});return(0,_jsxRuntime.jsx)("button",{type:"button","aria-label":"Clear network requests",onClick:()=>_networkEventStore.networkEventStore.clearEvents(),style:{...styles.headerActionButton,...!t?styles.headerActionButtonDisabled:null},disabled:!t,children:(0,_jsxRuntime.jsx)(Trash2,{size:14,color:t?macOSColors.text.muted:macOSColors.text.disabled})})}function NetworkSavedButton({onPress:e}){const{savedRecords:t}=(0,_useNetworkSaved.useNetworkSaved)();const r=t.length;return(0,_jsxRuntime.jsxs)("button",{type:"button",onClick:e,"aria-label":"Saved requests",style:styles.headerActionButton,children:[(0,_jsxRuntime.jsx)(Bookmark,{size:14,color:r>0?macOSColors.semantic.debug:macOSColors.text.muted}),r>0?(0,_jsxRuntime.jsx)("span",{style:styles.savedBadge,children:(0,_jsxRuntime.jsx)("span",{style:styles.savedBadgeText,children:r>99?"99+":r})}):null]})}function NetworkDetailPinActions({isPro:e,onUpgradePress:t}){const r=(0,_useNetworkSelection.useSelectedNetworkEventId)();const a=(0,_useNetworkSaved.useNetworkSaved)();const{pinned:o,saved:l}=(0,_networkSavedStore.flagsForEventId)(a,r);const i=(0,_sharedUi.useLimit)("network.saved");const s=!o&&a.pinnedEvents.length>=_networkSavedStore.MAX_PINNED;const n=!l&&a.savedRecords.length>=i;const u=()=>{if(!r)return null;return _networkEventStore.networkEventStore.getEvents().find(c=>c.id===r)??_networkSavedStore.networkSavedStore.getEventById(r)};const d=()=>{const c=u();if(c)a.togglePin(c)};const h=()=>{if(n&&!e){t();return}const c=u();if(c)a.toggleSave(c)};return(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[(0,_jsxRuntime.jsx)("button",{type:"button",onClick:d,disabled:s,"aria-label":o?"Unpin request":"Pin request",title:s?`Pin limit reached (${_networkSavedStore.MAX_PINNED})`:void 0,style:{...styles.headerActionButton,...o?styles.headerActionButtonActive:null,...s?styles.headerActionButtonDisabled:null},children:(0,_jsxRuntime.jsx)(Pin,{size:14,active:o,color:o?macOSColors.semantic.info:s?macOSColors.text.disabled:macOSColors.text.secondary})}),(0,_jsxRuntime.jsx)("button",{type:"button",onClick:h,disabled:n&&e,"aria-label":l?"Remove from saved":"Save request",title:n&&e?`Saved limit reached (${_networkSavedStore.MAX_SAVED})`:void 0,style:{...styles.headerActionButton,...l?styles.headerActionButtonSaved:null,...n&&e?styles.headerActionButtonDisabled:null},children:(0,_jsxRuntime.jsx)(Bookmark,{size:14,color:l?macOSColors.semantic.debug:n&&e?macOSColors.text.disabled:macOSColors.text.secondary})})]})}function NetworkHeaderCopyButton({isPro:e,filter:t,ignoredPatterns:r,copySettings:a,paused:o,onUpgradePress:l,label:i}){const s=(0,_useNetworkHasMatches.useNetworkHasMatches)({filter:t,ignoredPatterns:r,paused:o});const[n,u]=(0,_react.useState)("idle");const d=(0,_react.useRef)(null);(0,_react.useEffect)(()=>()=>{if(d.current)clearTimeout(d.current)},[]);if(!e){return(0,_jsxRuntime.jsxs)("button",{type:"button",onClick:l,style:{...i?styles.copyMenuRow:styles.headerActionButton,...!s?styles.headerActionButtonDisabled:null},disabled:!s,"aria-label":i??"Copy requests",children:[(0,_jsxRuntime.jsx)(Copy,{size:14,color:s?macOSColors.text.secondary:macOSColors.text.disabled}),i?(0,_jsxRuntime.jsx)("span",{style:styles.copyMenuLabel,children:i}):null]})}const h=p=>{u(p);if(d.current)clearTimeout(d.current);d.current=setTimeout(()=>{u("idle");d.current=null},1500)};const c=async()=>{try{const p=(0,_generateNetworkCopyText.generateNetworkCopyText)((0,_filterNetworkEvents.filterNetworkEvents)((0,_filterNetworkEvents.applyIgnoredPatterns)(_networkEventStore.networkEventStore.getEvents(),r),t),a);await navigator.clipboard.writeText(p);h("success")}catch{h("error")}};const x=n==="success"?macOSColors.semantic.success:n==="error"?macOSColors.semantic.error:s?macOSColors.text.secondary:macOSColors.text.disabled;return(0,_jsxRuntime.jsxs)("button",{type:"button",onClick:n==="idle"?c:void 0,style:{...i?styles.copyMenuRow:styles.headerActionButton,...!s?styles.headerActionButtonDisabled:null},disabled:!s,"aria-label":n==="idle"?i??"Copy to clipboard":n==="success"?"Copied to clipboard":"Failed to copy",children:[n==="success"?(0,_jsxRuntime.jsx)(CheckCircle2,{size:14,color:x}):n==="error"?(0,_jsxRuntime.jsx)(AlertTriangle,{size:14,color:x}):(0,_jsxRuntime.jsx)(Copy,{size:14,color:x}),i?(0,_jsxRuntime.jsx)("span",{style:styles.copyMenuLabel,children:i}):null]})}const styles={copyMenuRow:{display:"flex",width:"100%",boxSizing:"border-box",flexDirection:"row",alignItems:"center",gap:10,padding:"11px 6px",justifyContent:"flex-start",background:"none",border:"none",cursor:"pointer",margin:0,fontFamily:"inherit",textAlign:"left"},copyMenuLabel:{fontSize:13,fontWeight:600,color:macOSColors.text.primary},headerChipRow:{display:"flex",flexDirection:"row",alignItems:"center",gap:8},headerChip:{display:"inline-flex",flexDirection:"row",alignItems:"center",gap:4,backgroundColor:macOSColors.background.hover,padding:"5px 10px",borderRadius:12,border:`1px solid ${macOSColors.border.default}`,cursor:"pointer",margin:0},headerChipActive:{backgroundColor:macOSColors.semantic.infoBackground,border:`1px solid ${macOSColors.semantic.info}50`,boxShadow:"0 1px 2px rgba(0, 184, 230, 0.08)"},headerChipValue:{fontSize:12,fontWeight:600,fontFamily:"ui-monospace, Menlo, monospace"},headerActionButton:{position:"relative",display:"inline-flex",width:32,height:32,boxSizing:"border-box",borderRadius:8,backgroundColor:macOSColors.background.hover,border:`1px solid ${macOSColors.border.default}`,alignItems:"center",justifyContent:"center",cursor:"pointer",padding:0,margin:0},headerActionButtonDisabled:{opacity:.55,cursor:"default"},headerActionButtonActive:{backgroundColor:macOSColors.semantic.infoBackground,border:`1px solid ${macOSColors.semantic.info}50`},headerActionButtonSaved:{backgroundColor:`${macOSColors.semantic.debug}1A`,border:`1px solid ${macOSColors.semantic.debug}50`},savedBadge:{position:"absolute",top:-3,right:-3,minWidth:14,height:14,boxSizing:"border-box",padding:"0 3px",borderRadius:7,backgroundColor:macOSColors.semantic.debug,display:"inline-flex",alignItems:"center",justifyContent:"center"},savedBadgeText:{color:"#FFFFFF",fontSize:9,fontWeight:700,fontFamily:"ui-monospace, Menlo, monospace"}};
|