@buoy-gg/core 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 +14 -95
- package/bin/buoy.js +19 -340
- package/lib/commonjs/Buoy.js +1 -107
- package/lib/commonjs/browserRegister.js +1 -48
- package/lib/commonjs/browserRegister.server.js +1 -10
- package/lib/commonjs/earlyHookScript.js +1 -0
- package/lib/commonjs/earlyNetwork.js +1 -0
- package/lib/commonjs/floatingMenu/AppHost.js +1 -460
- package/lib/commonjs/floatingMenu/AppHost.web.js +1 -376
- package/lib/commonjs/floatingMenu/AppHostLogic.js +1 -50
- package/lib/commonjs/floatingMenu/AppIcon.js +1 -91
- package/lib/commonjs/floatingMenu/AppIcon.web.js +1 -53
- package/lib/commonjs/floatingMenu/BrowserToolRuntime.js +1 -150
- package/lib/commonjs/floatingMenu/DefaultConfigContext.js +1 -45
- package/lib/commonjs/floatingMenu/DevToolsSettingsModal.js +1 -18
- package/lib/commonjs/floatingMenu/DevToolsSettingsModal.shared.js +1 -1114
- package/lib/commonjs/floatingMenu/DevToolsSettingsModal.web.js +1 -48
- package/lib/commonjs/floatingMenu/DevToolsVisibilityContext.js +1 -49
- package/lib/commonjs/floatingMenu/FloatingDevTools.js +1 -559
- package/lib/commonjs/floatingMenu/FloatingDevTools.web.js +1 -415
- package/lib/commonjs/floatingMenu/FloatingMenu.js +1 -371
- package/lib/commonjs/floatingMenu/MinimizedToolsContext.js +1 -274
- package/lib/commonjs/floatingMenu/MinimizedToolsStack.js +1 -288
- package/lib/commonjs/floatingMenu/MinimizedToolsStack.web.js +1 -377
- package/lib/commonjs/floatingMenu/ToggleStateManager.js +1 -36
- package/lib/commonjs/floatingMenu/ToolHost.js +1 -281
- package/lib/commonjs/floatingMenu/ToolOpenerBridge.js +1 -41
- package/lib/commonjs/floatingMenu/autoDiscoverPresets.js +1 -471
- package/lib/commonjs/floatingMenu/autoExternalSync.js +1 -443
- package/lib/commonjs/floatingMenu/defaultConfig.js +1 -167
- package/lib/commonjs/floatingMenu/deviceIdentity.js +1 -173
- package/lib/commonjs/floatingMenu/dial/DialDevTools.js +1 -904
- package/lib/commonjs/floatingMenu/dial/DialDevTools.web.js +1 -895
- package/lib/commonjs/floatingMenu/dial/DialHyperspace.js +1 -177
- package/lib/commonjs/floatingMenu/dial/DialIcon.js +1 -304
- package/lib/commonjs/floatingMenu/dial/DialPagination.js +1 -165
- package/lib/commonjs/floatingMenu/dial/DialSnow.js +1 -92
- package/lib/commonjs/floatingMenu/dial/OnboardingTooltip.js +1 -246
- package/lib/commonjs/floatingMenu/dial/OnboardingTooltip.web.js +2 -147
- package/lib/commonjs/floatingMenu/dial/dialUsageStore.js +1 -93
- package/lib/commonjs/floatingMenu/dial/onboardingConstants.js +1 -42
- package/lib/commonjs/floatingMenu/dial/onboardingConstants.web.js +1 -42
- package/lib/commonjs/floatingMenu/externalSyncGate.js +1 -49
- package/lib/commonjs/floatingMenu/floatingTools.js +1 -42
- package/lib/commonjs/floatingMenu/floatingTools.web.js +1 -30
- package/lib/commonjs/floatingMenu/optionalRequire.js +1 -37
- package/lib/commonjs/floatingMenu/settingsBus.js +1 -12
- package/lib/commonjs/floatingMenu/sync/appSyncAdapter.js +1 -115
- package/lib/commonjs/floatingMenu/types.js +1 -5
- package/lib/commonjs/floatingMenu/useDesktopSyncStatus.js +1 -28
- package/lib/commonjs/floatingMenu/useDesktopSyncStatus.web.js +1 -14
- package/lib/commonjs/index.js +1 -291
- package/lib/commonjs/index.web.js +1 -241
- package/lib/commonjs/reactDevtoolsTypes.js +1 -1
- package/lib/commonjs/releaseOptIn.js +1 -0
- package/lib/commonjs/telemetry/installPing.js +1 -131
- package/lib/commonjs/toolkit.js +1 -584
- package/lib/commonjs/toolkitComponents.js +1 -241
- package/lib/commonjs/utils/autoDiscoverPresets.web.js +1 -46
- package/lib/commonjs/utils/createWebTool.js +1 -20
- package/lib/commonjs/utils/createWebTools.js +1 -30
- package/lib/commonjs/version.js +1 -18
- package/lib/module/Buoy.js +1 -102
- package/lib/module/browserRegister.js +1 -44
- package/lib/module/browserRegister.server.js +1 -6
- package/lib/module/earlyHookScript.js +1 -0
- package/lib/module/earlyNetwork.js +1 -0
- package/lib/module/floatingMenu/AppHost.js +1 -452
- package/lib/module/floatingMenu/AppHost.web.js +1 -368
- package/lib/module/floatingMenu/AppHostLogic.js +1 -45
- package/lib/module/floatingMenu/AppIcon.js +1 -84
- package/lib/module/floatingMenu/AppIcon.web.js +1 -47
- package/lib/module/floatingMenu/BrowserToolRuntime.js +1 -146
- package/lib/module/floatingMenu/DefaultConfigContext.js +1 -39
- package/lib/module/floatingMenu/DevToolsSettingsModal.js +1 -3
- package/lib/module/floatingMenu/DevToolsSettingsModal.shared.js +1 -1110
- package/lib/module/floatingMenu/DevToolsSettingsModal.web.js +1 -44
- package/lib/module/floatingMenu/DevToolsVisibilityContext.js +1 -44
- package/lib/module/floatingMenu/FloatingDevTools.js +1 -556
- package/lib/module/floatingMenu/FloatingDevTools.web.js +1 -412
- package/lib/module/floatingMenu/FloatingMenu.js +1 -366
- package/lib/module/floatingMenu/MinimizedToolsContext.js +1 -266
- package/lib/module/floatingMenu/MinimizedToolsStack.js +1 -285
- package/lib/module/floatingMenu/MinimizedToolsStack.web.js +1 -374
- package/lib/module/floatingMenu/ToggleStateManager.js +1 -32
- package/lib/module/floatingMenu/ToolHost.js +1 -273
- package/lib/module/floatingMenu/ToolOpenerBridge.js +1 -37
- package/lib/module/floatingMenu/autoDiscoverPresets.js +1 -467
- package/lib/module/floatingMenu/autoExternalSync.js +1 -436
- package/lib/module/floatingMenu/defaultConfig.js +1 -158
- package/lib/module/floatingMenu/deviceIdentity.js +1 -163
- package/lib/module/floatingMenu/dial/DialDevTools.js +1 -900
- package/lib/module/floatingMenu/dial/DialDevTools.web.js +1 -891
- package/lib/module/floatingMenu/dial/DialHyperspace.js +1 -173
- package/lib/module/floatingMenu/dial/DialIcon.js +1 -301
- package/lib/module/floatingMenu/dial/DialPagination.js +1 -160
- package/lib/module/floatingMenu/dial/DialSnow.js +1 -90
- package/lib/module/floatingMenu/dial/OnboardingTooltip.js +1 -240
- package/lib/module/floatingMenu/dial/OnboardingTooltip.web.js +2 -142
- package/lib/module/floatingMenu/dial/dialUsageStore.js +1 -85
- package/lib/module/floatingMenu/dial/onboardingConstants.js +1 -3
- package/lib/module/floatingMenu/dial/onboardingConstants.web.js +1 -3
- package/lib/module/floatingMenu/externalSyncGate.js +1 -44
- package/lib/module/floatingMenu/floatingTools.js +1 -27
- package/lib/module/floatingMenu/floatingTools.web.js +1 -3
- package/lib/module/floatingMenu/optionalRequire.js +1 -33
- package/lib/module/floatingMenu/settingsBus.js +1 -3
- package/lib/module/floatingMenu/sync/appSyncAdapter.js +1 -112
- package/lib/module/floatingMenu/types.js +1 -3
- package/lib/module/floatingMenu/useDesktopSyncStatus.js +1 -25
- package/lib/module/floatingMenu/useDesktopSyncStatus.web.js +1 -10
- package/lib/module/index.js +1 -41
- package/lib/module/index.web.js +1 -36
- package/lib/module/reactDevtoolsTypes.js +1 -1
- package/lib/module/releaseOptIn.js +1 -0
- package/lib/module/telemetry/installPing.js +1 -127
- package/lib/module/toolkit.js +1 -62
- package/lib/module/toolkitComponents.js +1 -230
- package/lib/module/utils/autoDiscoverPresets.web.js +1 -38
- package/lib/module/utils/createWebTool.js +1 -17
- package/lib/module/utils/createWebTools.js +1 -25
- package/lib/module/version.js +1 -14
- package/lib/typescript/commonjs/browserRegister.d.ts +9 -1
- package/lib/typescript/commonjs/browserRegister.server.d.ts +1 -0
- package/lib/typescript/commonjs/earlyHookScript.d.ts +12 -0
- package/lib/typescript/commonjs/earlyNetwork.d.ts +52 -0
- package/lib/typescript/commonjs/floatingMenu/defaultConfig.d.ts +1 -1
- package/lib/typescript/commonjs/index.web.d.ts +1 -0
- package/lib/typescript/commonjs/releaseOptIn.d.ts +4 -0
- package/lib/typescript/commonjs/version.d.ts +1 -1
- package/lib/typescript/module/browserRegister.d.ts +9 -1
- package/lib/typescript/module/browserRegister.server.d.ts +1 -0
- package/lib/typescript/module/earlyHookScript.d.ts +12 -0
- package/lib/typescript/module/earlyNetwork.d.ts +52 -0
- package/lib/typescript/module/floatingMenu/defaultConfig.d.ts +1 -1
- package/lib/typescript/module/index.web.d.ts +1 -0
- package/lib/typescript/module/releaseOptIn.d.ts +4 -0
- package/lib/typescript/module/version.d.ts +1 -1
- package/lib/web/chunks/chunk-5SGL6QL4.mjs +1 -0
- package/lib/web/chunks/chunk-FROELTJH.mjs +1 -0
- package/lib/web/chunks/chunk-QZDVCMCT.mjs +1 -2
- package/lib/web/chunks/chunk-R7RGRTY5.mjs +1 -2
- package/lib/web/index.mjs +2 -3
- package/lib/web/register-server.mjs +1 -2
- package/lib/web/register.mjs +1 -2
- package/lib/web/toolkit.mjs +1 -2
- package/package.json +5 -5
- package/lib/typescript/commonjs/Buoy.d.ts.map +0 -1
- package/lib/typescript/commonjs/browserRegister.d.ts.map +0 -1
- package/lib/typescript/commonjs/browserRegister.server.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/AppHost.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/AppHost.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/AppHostLogic.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/AppIcon.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/AppIcon.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/BrowserToolRuntime.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/DefaultConfigContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/DevToolsSettingsModal.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/DevToolsSettingsModal.shared.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/DevToolsSettingsModal.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/DevToolsVisibilityContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/FloatingDevTools.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/FloatingDevTools.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/FloatingMenu.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/MinimizedToolsContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/MinimizedToolsStack.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/MinimizedToolsStack.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/ToggleStateManager.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/ToolHost.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/ToolOpenerBridge.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/autoDiscoverPresets.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/autoExternalSync.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/defaultConfig.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/deviceIdentity.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialDevTools.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialDevTools.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialHyperspace.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialIcon.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialPagination.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/DialSnow.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/OnboardingTooltip.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/OnboardingTooltip.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/dialUsageStore.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/onboardingConstants.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/dial/onboardingConstants.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/externalSyncGate.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/floatingTools.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/floatingTools.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/optionalRequire.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/settingsBus.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/sync/appSyncAdapter.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/types.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/useDesktopSyncStatus.d.ts.map +0 -1
- package/lib/typescript/commonjs/floatingMenu/useDesktopSyncStatus.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/index.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/reactDevtoolsTypes.d.ts.map +0 -1
- package/lib/typescript/commonjs/telemetry/installPing.d.ts.map +0 -1
- package/lib/typescript/commonjs/toolkit.d.ts.map +0 -1
- package/lib/typescript/commonjs/toolkitComponents.d.ts.map +0 -1
- package/lib/typescript/commonjs/utils/autoDiscoverPresets.web.d.ts.map +0 -1
- package/lib/typescript/commonjs/utils/createWebTool.d.ts.map +0 -1
- package/lib/typescript/commonjs/utils/createWebTools.d.ts.map +0 -1
- package/lib/typescript/commonjs/version.d.ts.map +0 -1
- package/lib/typescript/module/Buoy.d.ts.map +0 -1
- package/lib/typescript/module/browserRegister.d.ts.map +0 -1
- package/lib/typescript/module/browserRegister.server.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/AppHost.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/AppHost.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/AppHostLogic.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/AppIcon.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/AppIcon.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/BrowserToolRuntime.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/DefaultConfigContext.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/DevToolsSettingsModal.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/DevToolsSettingsModal.shared.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/DevToolsSettingsModal.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/DevToolsVisibilityContext.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/FloatingDevTools.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/FloatingDevTools.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/FloatingMenu.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/MinimizedToolsContext.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/MinimizedToolsStack.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/MinimizedToolsStack.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/ToggleStateManager.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/ToolHost.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/ToolOpenerBridge.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/autoDiscoverPresets.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/autoExternalSync.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/defaultConfig.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/deviceIdentity.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/DialDevTools.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/DialDevTools.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/DialHyperspace.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/DialIcon.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/DialPagination.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/DialSnow.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/OnboardingTooltip.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/OnboardingTooltip.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/dialUsageStore.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/onboardingConstants.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/dial/onboardingConstants.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/externalSyncGate.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/floatingTools.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/floatingTools.web.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/optionalRequire.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/settingsBus.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/sync/appSyncAdapter.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/types.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/useDesktopSyncStatus.d.ts.map +0 -1
- package/lib/typescript/module/floatingMenu/useDesktopSyncStatus.web.d.ts.map +0 -1
- package/lib/typescript/module/index.d.ts.map +0 -1
- package/lib/typescript/module/index.web.d.ts.map +0 -1
- package/lib/typescript/module/reactDevtoolsTypes.d.ts.map +0 -1
- package/lib/typescript/module/telemetry/installPing.d.ts.map +0 -1
- package/lib/typescript/module/toolkit.d.ts.map +0 -1
- package/lib/typescript/module/toolkitComponents.d.ts.map +0 -1
- package/lib/typescript/module/utils/autoDiscoverPresets.web.d.ts.map +0 -1
- package/lib/typescript/module/utils/createWebTool.d.ts.map +0 -1
- package/lib/typescript/module/utils/createWebTools.d.ts.map +0 -1
- package/lib/typescript/module/version.d.ts.map +0 -1
- package/lib/web/chunks/chunk-5NZOQR6Q.mjs +0 -2
- package/lib/web/chunks/chunk-CGDSLLZF.mjs +0 -2
- package/lib/web/chunks/chunk-DCJDUSNR.mjs +0 -2
- package/lib/web/chunks/chunk-IDSHFS6G.mjs +0 -2
- package/lib/web/chunks/chunk-JOAMJGCS.mjs +0 -2
- package/lib/web/chunks/chunk-KYKZ2N52.mjs +0 -2
- package/lib/web/chunks/chunk-NGM7JGGS.mjs +0 -2
- package/lib/web/chunks/chunk-Z3XWDDIO.mjs +0 -2
- package/lib/web/chunks/chunk-ZTGQ6TTY.mjs +0 -2
|
@@ -1,241 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.Badge = Badge;
|
|
7
|
-
exports.DiffViewer = DiffViewer;
|
|
8
|
-
exports.InfoRow = InfoRow;
|
|
9
|
-
exports.StatusDot = StatusDot;
|
|
10
|
-
exports.methodColor = methodColor;
|
|
11
|
-
exports.statusColor = statusColor;
|
|
12
|
-
exports.typeColor = typeColor;
|
|
13
|
-
var _react = _interopRequireDefault(require("react"));
|
|
14
|
-
var _reactNative = require("react-native");
|
|
15
|
-
var _sharedUi = require("@buoy-gg/shared-ui");
|
|
16
|
-
var _dataViewer = require("@buoy-gg/shared-ui/dataViewer");
|
|
17
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
18
|
-
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
19
|
-
/**
|
|
20
|
-
* Facade primitives for the public custom-tools toolkit (see toolkit.ts).
|
|
21
|
-
*
|
|
22
|
-
* shared-ui grew several overlapping treatments of the same jobs (seven badge
|
|
23
|
-
* variants, four copy buttons, two diff viewers...). The public surface merges
|
|
24
|
-
* each job into ONE component with variants, implemented here on toolTheme —
|
|
25
|
-
* shared-ui's internals stay unchanged for first-party tools.
|
|
26
|
-
*/
|
|
27
|
-
|
|
28
|
-
// ---------------------------------------------------------------------------
|
|
29
|
-
// Semantic color helpers — pair with <Badge>/<StatusDot> instead of exporting
|
|
30
|
-
// a preset component per domain.
|
|
31
|
-
// ---------------------------------------------------------------------------
|
|
32
|
-
const STATUS_COLORS = {
|
|
33
|
-
success: _sharedUi.toolTheme.colors.success,
|
|
34
|
-
active: _sharedUi.toolTheme.colors.success,
|
|
35
|
-
connected: _sharedUi.toolTheme.colors.success,
|
|
36
|
-
error: _sharedUi.toolTheme.colors.error,
|
|
37
|
-
failed: _sharedUi.toolTheme.colors.error,
|
|
38
|
-
warning: _sharedUi.toolTheme.colors.warning,
|
|
39
|
-
stale: _sharedUi.toolTheme.colors.warning,
|
|
40
|
-
pending: _sharedUi.toolTheme.colors.info,
|
|
41
|
-
loading: _sharedUi.toolTheme.colors.info,
|
|
42
|
-
fetching: _sharedUi.toolTheme.colors.info,
|
|
43
|
-
info: _sharedUi.toolTheme.colors.info,
|
|
44
|
-
inactive: _sharedUi.toolTheme.colors.textMuted,
|
|
45
|
-
idle: _sharedUi.toolTheme.colors.textMuted
|
|
46
|
-
};
|
|
47
|
-
|
|
48
|
-
/** Map a status word ("success", "pending", "stale"...) to a semantic color. */
|
|
49
|
-
function statusColor(status) {
|
|
50
|
-
return STATUS_COLORS[status.toLowerCase()] ?? _sharedUi.toolTheme.colors.textMuted;
|
|
51
|
-
}
|
|
52
|
-
const METHOD_COLORS = {
|
|
53
|
-
GET: _sharedUi.toolTheme.colors.info,
|
|
54
|
-
POST: _sharedUi.toolTheme.colors.success,
|
|
55
|
-
PUT: _sharedUi.toolTheme.colors.warning,
|
|
56
|
-
PATCH: _sharedUi.toolTheme.colors.warning,
|
|
57
|
-
DELETE: _sharedUi.toolTheme.colors.error
|
|
58
|
-
};
|
|
59
|
-
|
|
60
|
-
/** Map an HTTP method to its conventional color. */
|
|
61
|
-
function methodColor(method) {
|
|
62
|
-
return METHOD_COLORS[method.toUpperCase()] ?? _sharedUi.toolTheme.colors.textSecondary;
|
|
63
|
-
}
|
|
64
|
-
const TYPE_COLORS = {
|
|
65
|
-
string: _sharedUi.toolTheme.colors.success,
|
|
66
|
-
number: _sharedUi.toolTheme.colors.info,
|
|
67
|
-
boolean: _sharedUi.toolTheme.colors.warning,
|
|
68
|
-
object: _sharedUi.toolTheme.colors.accent,
|
|
69
|
-
array: _sharedUi.toolTheme.colors.accent,
|
|
70
|
-
function: _sharedUi.toolTheme.colors.error,
|
|
71
|
-
null: _sharedUi.toolTheme.colors.textMuted,
|
|
72
|
-
undefined: _sharedUi.toolTheme.colors.textMuted
|
|
73
|
-
};
|
|
74
|
-
|
|
75
|
-
/** Map a JS value-type name to its display color. */
|
|
76
|
-
function typeColor(type) {
|
|
77
|
-
return TYPE_COLORS[type.toLowerCase()] ?? _sharedUi.toolTheme.colors.textSecondary;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
// ---------------------------------------------------------------------------
|
|
81
|
-
// Badge — the one chip. Color it with statusColor()/methodColor()/typeColor()
|
|
82
|
-
// (or any hex); shape/typography are props, not sibling components.
|
|
83
|
-
// ---------------------------------------------------------------------------
|
|
84
|
-
|
|
85
|
-
function Badge({
|
|
86
|
-
children,
|
|
87
|
-
color = _sharedUi.toolTheme.colors.textSecondary,
|
|
88
|
-
icon,
|
|
89
|
-
size = "small",
|
|
90
|
-
pill = false,
|
|
91
|
-
mono = false,
|
|
92
|
-
style
|
|
93
|
-
}) {
|
|
94
|
-
const isText = typeof children === "string" || typeof children === "number";
|
|
95
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
96
|
-
style: [badgeStyles.base, size === "medium" && badgeStyles.medium, pill && badgeStyles.pill, {
|
|
97
|
-
backgroundColor: color + "1A",
|
|
98
|
-
borderColor: color + "40"
|
|
99
|
-
}, style],
|
|
100
|
-
children: [icon, isText ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
101
|
-
style: [badgeStyles.text, size === "medium" && badgeStyles.textMedium, mono && badgeStyles.textMono, {
|
|
102
|
-
color
|
|
103
|
-
}],
|
|
104
|
-
numberOfLines: 1,
|
|
105
|
-
children: children
|
|
106
|
-
}) : children]
|
|
107
|
-
});
|
|
108
|
-
}
|
|
109
|
-
const badgeStyles = _reactNative.StyleSheet.create({
|
|
110
|
-
base: {
|
|
111
|
-
flexDirection: "row",
|
|
112
|
-
alignItems: "center",
|
|
113
|
-
alignSelf: "flex-start",
|
|
114
|
-
gap: 4,
|
|
115
|
-
borderWidth: 1,
|
|
116
|
-
borderRadius: _sharedUi.toolTheme.radius.sm,
|
|
117
|
-
paddingHorizontal: 6,
|
|
118
|
-
paddingVertical: 2
|
|
119
|
-
},
|
|
120
|
-
medium: {
|
|
121
|
-
paddingHorizontal: 8,
|
|
122
|
-
paddingVertical: 3
|
|
123
|
-
},
|
|
124
|
-
pill: {
|
|
125
|
-
borderRadius: _sharedUi.toolTheme.radius.pill,
|
|
126
|
-
minWidth: 20,
|
|
127
|
-
justifyContent: "center"
|
|
128
|
-
},
|
|
129
|
-
text: {
|
|
130
|
-
fontSize: 10,
|
|
131
|
-
fontWeight: "600",
|
|
132
|
-
letterSpacing: 0.3
|
|
133
|
-
},
|
|
134
|
-
textMedium: {
|
|
135
|
-
fontSize: 12
|
|
136
|
-
},
|
|
137
|
-
textMono: {
|
|
138
|
-
fontFamily: _sharedUi.toolTheme.text.mono.fontFamily
|
|
139
|
-
}
|
|
140
|
-
});
|
|
141
|
-
|
|
142
|
-
// ---------------------------------------------------------------------------
|
|
143
|
-
// StatusDot — the bare status circle (list rows, connection indicators).
|
|
144
|
-
// ---------------------------------------------------------------------------
|
|
145
|
-
|
|
146
|
-
function StatusDot({
|
|
147
|
-
status,
|
|
148
|
-
color,
|
|
149
|
-
size = 8,
|
|
150
|
-
style
|
|
151
|
-
}) {
|
|
152
|
-
const dotColor = color ?? (status ? statusColor(status) : _sharedUi.toolTheme.colors.textMuted);
|
|
153
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
154
|
-
style: [{
|
|
155
|
-
width: size,
|
|
156
|
-
height: size,
|
|
157
|
-
borderRadius: size / 2,
|
|
158
|
-
backgroundColor: dotColor
|
|
159
|
-
}, style]
|
|
160
|
-
});
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
// ---------------------------------------------------------------------------
|
|
164
|
-
// InfoRow — the label/value line of every detail screen, with optional copy.
|
|
165
|
-
// ---------------------------------------------------------------------------
|
|
166
|
-
|
|
167
|
-
function InfoRow({
|
|
168
|
-
label,
|
|
169
|
-
value,
|
|
170
|
-
copyable = false,
|
|
171
|
-
style
|
|
172
|
-
}) {
|
|
173
|
-
const isText = typeof value === "string" || typeof value === "number";
|
|
174
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
175
|
-
style: [infoRowStyles.row, style],
|
|
176
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
177
|
-
style: infoRowStyles.label,
|
|
178
|
-
numberOfLines: 1,
|
|
179
|
-
children: label
|
|
180
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
181
|
-
style: infoRowStyles.value,
|
|
182
|
-
children: isText ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
|
183
|
-
style: infoRowStyles.valueText,
|
|
184
|
-
numberOfLines: 2,
|
|
185
|
-
children: String(value)
|
|
186
|
-
}) : value
|
|
187
|
-
}), copyable && value != null && /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.CopyButton, {
|
|
188
|
-
value: value,
|
|
189
|
-
size: 12
|
|
190
|
-
})]
|
|
191
|
-
});
|
|
192
|
-
}
|
|
193
|
-
const infoRowStyles = _reactNative.StyleSheet.create({
|
|
194
|
-
row: {
|
|
195
|
-
flexDirection: "row",
|
|
196
|
-
alignItems: "center",
|
|
197
|
-
gap: _sharedUi.toolTheme.spacing.sm,
|
|
198
|
-
paddingVertical: 3
|
|
199
|
-
},
|
|
200
|
-
label: {
|
|
201
|
-
..._sharedUi.toolTheme.text.label,
|
|
202
|
-
color: _sharedUi.toolTheme.colors.textMuted,
|
|
203
|
-
minWidth: 72
|
|
204
|
-
},
|
|
205
|
-
value: {
|
|
206
|
-
flex: 1,
|
|
207
|
-
flexDirection: "row",
|
|
208
|
-
alignItems: "center"
|
|
209
|
-
},
|
|
210
|
-
valueText: {
|
|
211
|
-
..._sharedUi.toolTheme.text.mono,
|
|
212
|
-
color: _sharedUi.toolTheme.colors.text
|
|
213
|
-
}
|
|
214
|
-
});
|
|
215
|
-
|
|
216
|
-
// ---------------------------------------------------------------------------
|
|
217
|
-
// DiffViewer — one before/after component; the rendering strategy is a mode.
|
|
218
|
-
// ---------------------------------------------------------------------------
|
|
219
|
-
|
|
220
|
-
function DiffViewer({
|
|
221
|
-
oldValue,
|
|
222
|
-
newValue,
|
|
223
|
-
mode = "tree",
|
|
224
|
-
showUnchanged = true,
|
|
225
|
-
scrollEnabled = false,
|
|
226
|
-
height = 220
|
|
227
|
-
}) {
|
|
228
|
-
if (mode === "text") {
|
|
229
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.SplitDiffViewer, {
|
|
230
|
-
oldValue: oldValue,
|
|
231
|
-
newValue: newValue,
|
|
232
|
-
height: height
|
|
233
|
-
});
|
|
234
|
-
}
|
|
235
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.TreeDiffViewer, {
|
|
236
|
-
oldValue: oldValue,
|
|
237
|
-
newValue: newValue,
|
|
238
|
-
showUnchanged: showUnchanged,
|
|
239
|
-
scrollEnabled: scrollEnabled
|
|
240
|
-
});
|
|
241
|
-
}
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.Badge=Badge;exports.DiffViewer=DiffViewer;exports.InfoRow=InfoRow;exports.StatusDot=StatusDot;exports.methodColor=methodColor;exports.statusColor=statusColor;exports.typeColor=typeColor;var _react=_interopRequireDefault(require("react"));var _reactNative=require("react-native");var _sharedUi=require("@buoy-gg/shared-ui");var _dataViewer=require("@buoy-gg/shared-ui/dataViewer");var _jsxRuntime=require("react/jsx-runtime");function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}const STATUS_COLORS={success:_sharedUi.toolTheme.colors.success,active:_sharedUi.toolTheme.colors.success,connected:_sharedUi.toolTheme.colors.success,error:_sharedUi.toolTheme.colors.error,failed:_sharedUi.toolTheme.colors.error,warning:_sharedUi.toolTheme.colors.warning,stale:_sharedUi.toolTheme.colors.warning,pending:_sharedUi.toolTheme.colors.info,loading:_sharedUi.toolTheme.colors.info,fetching:_sharedUi.toolTheme.colors.info,info:_sharedUi.toolTheme.colors.info,inactive:_sharedUi.toolTheme.colors.textMuted,idle:_sharedUi.toolTheme.colors.textMuted};function statusColor(e){return STATUS_COLORS[e.toLowerCase()]??_sharedUi.toolTheme.colors.textMuted}const METHOD_COLORS={GET:_sharedUi.toolTheme.colors.info,POST:_sharedUi.toolTheme.colors.success,PUT:_sharedUi.toolTheme.colors.warning,PATCH:_sharedUi.toolTheme.colors.warning,DELETE:_sharedUi.toolTheme.colors.error};function methodColor(e){return METHOD_COLORS[e.toUpperCase()]??_sharedUi.toolTheme.colors.textSecondary}const TYPE_COLORS={string:_sharedUi.toolTheme.colors.success,number:_sharedUi.toolTheme.colors.info,boolean:_sharedUi.toolTheme.colors.warning,object:_sharedUi.toolTheme.colors.accent,array:_sharedUi.toolTheme.colors.accent,function:_sharedUi.toolTheme.colors.error,null:_sharedUi.toolTheme.colors.textMuted,undefined:_sharedUi.toolTheme.colors.textMuted};function typeColor(e){return TYPE_COLORS[e.toLowerCase()]??_sharedUi.toolTheme.colors.textSecondary}function Badge({children:e,color:o=_sharedUi.toolTheme.colors.textSecondary,icon:t,size:r="small",pill:l=false,mono:n=false,style:s}){const i=typeof e==="string"||typeof e==="number";return(0,_jsxRuntime.jsxs)(_reactNative.View,{style:[badgeStyles.base,r==="medium"&&badgeStyles.medium,l&&badgeStyles.pill,{backgroundColor:o+"1A",borderColor:o+"40"},s],children:[t,i?(0,_jsxRuntime.jsx)(_reactNative.Text,{style:[badgeStyles.text,r==="medium"&&badgeStyles.textMedium,n&&badgeStyles.textMono,{color:o}],numberOfLines:1,children:e}):e]})}const badgeStyles=_reactNative.StyleSheet.create({base:{flexDirection:"row",alignItems:"center",alignSelf:"flex-start",gap:4,borderWidth:1,borderRadius:_sharedUi.toolTheme.radius.sm,paddingHorizontal:6,paddingVertical:2},medium:{paddingHorizontal:8,paddingVertical:3},pill:{borderRadius:_sharedUi.toolTheme.radius.pill,minWidth:20,justifyContent:"center"},text:{fontSize:10,fontWeight:"600",letterSpacing:.3},textMedium:{fontSize:12},textMono:{fontFamily:_sharedUi.toolTheme.text.mono.fontFamily}});function StatusDot({status:e,color:o,size:t=8,style:r}){const l=o??(e?statusColor(e):_sharedUi.toolTheme.colors.textMuted);return(0,_jsxRuntime.jsx)(_reactNative.View,{style:[{width:t,height:t,borderRadius:t/2,backgroundColor:l},r]})}function InfoRow({label:e,value:o,copyable:t=false,style:r}){const l=typeof o==="string"||typeof o==="number";return(0,_jsxRuntime.jsxs)(_reactNative.View,{style:[infoRowStyles.row,r],children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:infoRowStyles.label,numberOfLines:1,children:e}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:infoRowStyles.value,children:l?(0,_jsxRuntime.jsx)(_reactNative.Text,{style:infoRowStyles.valueText,numberOfLines:2,children:String(o)}):o}),t&&o!=null&&(0,_jsxRuntime.jsx)(_sharedUi.CopyButton,{value:o,size:12})]})}const infoRowStyles=_reactNative.StyleSheet.create({row:{flexDirection:"row",alignItems:"center",gap:_sharedUi.toolTheme.spacing.sm,paddingVertical:3},label:{..._sharedUi.toolTheme.text.label,color:_sharedUi.toolTheme.colors.textMuted,minWidth:72},value:{flex:1,flexDirection:"row",alignItems:"center"},valueText:{..._sharedUi.toolTheme.text.mono,color:_sharedUi.toolTheme.colors.text}});function DiffViewer({oldValue:e,newValue:o,mode:t="tree",showUnchanged:r=true,scrollEnabled:l=false,height:n=220}){if(t==="text"){return(0,_jsxRuntime.jsx)(_dataViewer.SplitDiffViewer,{oldValue:e,newValue:o,height:n})}return(0,_jsxRuntime.jsx)(_dataViewer.TreeDiffViewer,{oldValue:e,newValue:o,showUnchanged:r,scrollEnabled:l})}
|
|
@@ -1,46 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.autoDiscoverWebPresets = autoDiscoverWebPresets;
|
|
7
|
-
exports.autoDiscoverWithCustom = autoDiscoverWithCustom;
|
|
8
|
-
exports.defaultToolPresets = void 0;
|
|
9
|
-
exports.getEnabledTools = getEnabledTools;
|
|
10
|
-
exports.getToolsBySlot = getToolsBySlot;
|
|
11
|
-
/** Browser tools are registered through FloatingDevTools.apps. */
|
|
12
|
-
const defaultToolPresets = exports.defaultToolPresets = [];
|
|
13
|
-
|
|
14
|
-
/** @deprecated Pass explicitly imported presets through FloatingDevTools.apps. */
|
|
15
|
-
function autoDiscoverWebPresets() {
|
|
16
|
-
return [];
|
|
17
|
-
}
|
|
18
|
-
function autoDiscoverWithCustom(customTools = []) {
|
|
19
|
-
return [...new Map(customTools.map(tool => [tool.id, tool])).values()];
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* Get tools filtered by slot.
|
|
24
|
-
*
|
|
25
|
-
* @param tools - Array of tool configurations
|
|
26
|
-
* @param slot - Slot to filter by ('dial' or 'row')
|
|
27
|
-
* @returns Filtered array of tools that can appear in the specified slot
|
|
28
|
-
*/
|
|
29
|
-
function getToolsBySlot(tools, slot) {
|
|
30
|
-
return tools.filter(tool => {
|
|
31
|
-
const toolSlot = tool.slot || 'both';
|
|
32
|
-
return toolSlot === 'both' || toolSlot === slot;
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* Get enabled tools based on settings.
|
|
38
|
-
*
|
|
39
|
-
* @param tools - Array of all tool configurations
|
|
40
|
-
* @param enabledIds - Set or array of enabled tool IDs
|
|
41
|
-
* @returns Filtered array of enabled tools
|
|
42
|
-
*/
|
|
43
|
-
function getEnabledTools(tools, enabledIds) {
|
|
44
|
-
const idSet = enabledIds instanceof Set ? enabledIds : new Set(enabledIds);
|
|
45
|
-
return tools.filter(tool => idSet.has(tool.id));
|
|
46
|
-
}
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.autoDiscoverWebPresets=autoDiscoverWebPresets;exports.autoDiscoverWithCustom=autoDiscoverWithCustom;exports.defaultToolPresets=void 0;exports.getEnabledTools=getEnabledTools;exports.getToolsBySlot=getToolsBySlot;const defaultToolPresets=exports.defaultToolPresets=[];function autoDiscoverWebPresets(){return[]}function autoDiscoverWithCustom(e=[]){return[...new Map(e.map(t=>[t.id,t])).values()]}function getToolsBySlot(e,t){return e.filter(s=>{const o=s.slot||"both";return o==="both"||o===t})}function getEnabledTools(e,t){const s=t instanceof Set?t:new Set(t);return e.filter(o=>s.has(o.id))}
|
|
@@ -1,20 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.createWebTool = createWebTool;
|
|
7
|
-
var _react = require("react");
|
|
8
|
-
/** Adapt a shared tool preset to the browser menu's icon renderer. */
|
|
9
|
-
|
|
10
|
-
function createWebTool(preset) {
|
|
11
|
-
const icon = preset.icon;
|
|
12
|
-
return {
|
|
13
|
-
...preset,
|
|
14
|
-
icon: typeof icon === "function" ? size => /*#__PURE__*/(0, _react.createElement)(icon, {
|
|
15
|
-
size,
|
|
16
|
-
slot: preset.slot ?? "both",
|
|
17
|
-
color: preset.color
|
|
18
|
-
}) : () => icon
|
|
19
|
-
};
|
|
20
|
-
}
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.createWebTool=createWebTool;var _react=require("react");function createWebTool(o){const e=o.icon;return{...o,icon:typeof e==="function"?t=>(0,_react.createElement)(e,{size:t,slot:o.slot??"both",color:o.color}):()=>e}}
|
|
@@ -1,30 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.createWebTools = createWebTools;
|
|
7
|
-
var _sharedUi = _interopRequireWildcard(require("@buoy-gg/shared-ui"));
|
|
8
|
-
var shared = _sharedUi;
|
|
9
|
-
var _createWebTool = require("./createWebTool.js");
|
|
10
|
-
var _DevToolsVisibilityContext = require("../floatingMenu/DevToolsVisibilityContext.js");
|
|
11
|
-
var license = _interopRequireWildcard(require("@buoy-gg/license"));
|
|
12
|
-
var dataViewer = _interopRequireWildcard(require("@buoy-gg/shared-ui/dataViewer"));
|
|
13
|
-
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
14
|
-
function createWebTools(modules) {
|
|
15
|
-
(0, _sharedUi.registerToolModules)({
|
|
16
|
-
core: {
|
|
17
|
-
useDevToolsVisibility: _DevToolsVisibilityContext.useDevToolsVisibility
|
|
18
|
-
},
|
|
19
|
-
license,
|
|
20
|
-
'shared-ui': shared,
|
|
21
|
-
'shared-ui/dataViewer': dataViewer,
|
|
22
|
-
...modules
|
|
23
|
-
});
|
|
24
|
-
const seen = new Set();
|
|
25
|
-
return Object.values(modules).flatMap(module => Object.entries(module).flatMap(([name, value]) => {
|
|
26
|
-
if (!name.endsWith('Preset') || !value || typeof value.id !== 'string' || !value.component || seen.has(value.id)) return [];
|
|
27
|
-
seen.add(value.id);
|
|
28
|
-
return [(0, _createWebTool.createWebTool)(value)];
|
|
29
|
-
}));
|
|
30
|
-
}
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.createWebTools=createWebTools;var _sharedUi=_interopRequireWildcard(require("@buoy-gg/shared-ui"));var shared=_sharedUi;var _createWebTool=require("./createWebTool.js");var _DevToolsVisibilityContext=require("../floatingMenu/DevToolsVisibilityContext.js");var license=_interopRequireWildcard(require("@buoy-gg/license"));var dataViewer=_interopRequireWildcard(require("@buoy-gg/shared-ui/dataViewer"));function _interopRequireWildcard(o,n){if("function"==typeof WeakMap)var a=new WeakMap,u=new WeakMap;return(_interopRequireWildcard=function(e,l){if(!l&&e&&e.__esModule)return e;var r,s,i={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return i;if(r=l?u:a){if(r.has(e))return r.get(e);r.set(e,i)}for(const t in e)"default"!==t&&{}.hasOwnProperty.call(e,t)&&((s=(r=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,t))&&(s.get||s.set)?r(i,t,s):i[t]=e[t]);return i})(o,n)}function createWebTools(o){(0,_sharedUi.registerToolModules)({core:{useDevToolsVisibility:_DevToolsVisibilityContext.useDevToolsVisibility},license,"shared-ui":shared,"shared-ui/dataViewer":dataViewer,...o});const n=new Set;return Object.values(o).flatMap(a=>Object.entries(a).flatMap(([u,e])=>{if(!u.endsWith("Preset")||!e||typeof e.id!=="string"||!e.component||n.has(e.id))return[];n.add(e.id);return[(0,_createWebTool.createWebTool)(e)]}))}
|
package/lib/commonjs/version.js
CHANGED
|
@@ -1,18 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SDK_VERSION = void 0;
|
|
7
|
-
/**
|
|
8
|
-
* This package's published version.
|
|
9
|
-
*
|
|
10
|
-
* Hardcoded rather than read from package.json: `require("../package.json")`
|
|
11
|
-
* resolves to a different depth from `src/` than from the built `lib/`, and
|
|
12
|
-
* react-native-builder-bob (babel) has no build-time `define` the way tsup does
|
|
13
|
-
* for @buoy-gg/mcp.
|
|
14
|
-
*
|
|
15
|
-
* Drift is prevented by a test that fails when this disagrees with
|
|
16
|
-
* package.json, so a version bump that forgets this file cannot ship.
|
|
17
|
-
*/
|
|
18
|
-
const SDK_VERSION = exports.SDK_VERSION = "7.0.41";
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.SDK_VERSION=void 0;const SDK_VERSION=exports.SDK_VERSION="7.0.42";
|
package/lib/module/Buoy.js
CHANGED
|
@@ -1,102 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Buoy SDK - Main entry point for React Buoy configuration
|
|
5
|
-
*
|
|
6
|
-
* Initialize once at app startup, before rendering any components:
|
|
7
|
-
*
|
|
8
|
-
* @example
|
|
9
|
-
* ```tsx
|
|
10
|
-
* import { Buoy } from '@buoy-gg/core';
|
|
11
|
-
*
|
|
12
|
-
* Buoy.init({
|
|
13
|
-
* licenseKey: 'YOUR_LICENSE_KEY',
|
|
14
|
-
* });
|
|
15
|
-
* ```
|
|
16
|
-
*/
|
|
17
|
-
|
|
18
|
-
import { LicenseManager } from "@buoy-gg/license";
|
|
19
|
-
/**
|
|
20
|
-
* Telemetry stays on unless an app explicitly opts out. Read at ping time
|
|
21
|
-
* rather than captured, so `Buoy.init()` still wins if it runs after mount.
|
|
22
|
-
*/
|
|
23
|
-
let telemetryEnabled = true;
|
|
24
|
-
|
|
25
|
-
/** Whether the anonymous install ping is allowed to fire. */
|
|
26
|
-
export function isTelemetryEnabled() {
|
|
27
|
-
return telemetryEnabled;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* Buoy SDK namespace
|
|
32
|
-
*
|
|
33
|
-
* Use `Buoy.init()` to configure your license key at app startup.
|
|
34
|
-
*/
|
|
35
|
-
export const Buoy = {
|
|
36
|
-
/**
|
|
37
|
-
* Initialize Buoy with your license key
|
|
38
|
-
*
|
|
39
|
-
* Call this once at app startup, before rendering FloatingDevTools.
|
|
40
|
-
* Typically placed in App.tsx or index.js.
|
|
41
|
-
*
|
|
42
|
-
* @example
|
|
43
|
-
* ```tsx
|
|
44
|
-
* import { Buoy } from '@buoy-gg/core';
|
|
45
|
-
*
|
|
46
|
-
* // With hardcoded key
|
|
47
|
-
* Buoy.init({
|
|
48
|
-
* licenseKey: '36063C-27282E-8E73F5-55488F-2213DF-V3',
|
|
49
|
-
* });
|
|
50
|
-
*
|
|
51
|
-
* // With environment variable
|
|
52
|
-
* Buoy.init({
|
|
53
|
-
* licenseKey: process.env.BUOY_LICENSE_KEY!,
|
|
54
|
-
* });
|
|
55
|
-
* ```
|
|
56
|
-
*/
|
|
57
|
-
init(config) {
|
|
58
|
-
if (config.telemetry === false) telemetryEnabled = false;
|
|
59
|
-
void LicenseManager.configure(config.licenseKey).catch(error => {
|
|
60
|
-
console.warn("[Buoy] License initialization failed:", error);
|
|
61
|
-
});
|
|
62
|
-
},
|
|
63
|
-
/**
|
|
64
|
-
* Initialize Buoy asynchronously
|
|
65
|
-
*
|
|
66
|
-
* Use this if you need to wait for initialization to complete.
|
|
67
|
-
*
|
|
68
|
-
* @example
|
|
69
|
-
* ```tsx
|
|
70
|
-
* await Buoy.initAsync({
|
|
71
|
-
* licenseKey: 'YOUR_LICENSE_KEY',
|
|
72
|
-
* });
|
|
73
|
-
* console.log('Buoy is ready!');
|
|
74
|
-
* ```
|
|
75
|
-
*/
|
|
76
|
-
async initAsync(config) {
|
|
77
|
-
if (config.telemetry === false) telemetryEnabled = false;
|
|
78
|
-
return LicenseManager.configure(config.licenseKey);
|
|
79
|
-
},
|
|
80
|
-
/**
|
|
81
|
-
* Check if Buoy Pro is active
|
|
82
|
-
*/
|
|
83
|
-
isPro() {
|
|
84
|
-
return LicenseManager.isPro();
|
|
85
|
-
},
|
|
86
|
-
/**
|
|
87
|
-
* Get the current license state
|
|
88
|
-
*/
|
|
89
|
-
getState() {
|
|
90
|
-
return LicenseManager.getState();
|
|
91
|
-
},
|
|
92
|
-
/**
|
|
93
|
-
* Force device re-registration (debugging helper)
|
|
94
|
-
* Clears cached fingerprint so next init will register device again
|
|
95
|
-
*/
|
|
96
|
-
async forceReregister() {
|
|
97
|
-
await LicenseManager.forceReregister();
|
|
98
|
-
}
|
|
99
|
-
};
|
|
100
|
-
|
|
101
|
-
// Also export as default for flexibility
|
|
102
|
-
export default Buoy;
|
|
1
|
+
"use strict";import{LicenseManager as t}from"@buoy-gg/license";let r=true;export function isTelemetryEnabled(){return r}export const Buoy={init(e){if(e.telemetry===false)r=false;void t.configure(e.licenseKey).catch(i=>{console.warn("[Buoy] License initialization failed:",i)})},async initAsync(e){if(e.telemetry===false)r=false;return t.configure(e.licenseKey)},isPro(){return t.isPro()},getState(){return t.getState()},async forceReregister(){await t.forceReregister()}};export default Buoy;
|
|
@@ -1,44 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
import * as ReactDevtools from 'react-devtools-core';
|
|
4
|
-
|
|
5
|
-
/** Call before importing React DOM so render and element inspectors can see app roots. */
|
|
6
|
-
export function registerBrowserDevTools(options = {}) {
|
|
7
|
-
if (typeof window === 'undefined' || typeof document === 'undefined') return false;
|
|
8
|
-
const dev = typeof __DEV__ !== 'undefined' ? __DEV__ : process.env.NODE_ENV !== 'production';
|
|
9
|
-
if (!dev && !options.enableInRelease) return false;
|
|
10
|
-
const target = window;
|
|
11
|
-
const previous = target.__REACT_DEVTOOLS_GLOBAL_HOOK__;
|
|
12
|
-
// Fast Refresh installs a minimal hook before the application's entry runs.
|
|
13
|
-
// Preserve its callbacks and renderer IDs when installing the full backend.
|
|
14
|
-
const refreshHook = previous && previous.supportsFiber && !previous.getFiberRoots && !previous.sub && Object.getOwnPropertyDescriptor(target, '__REACT_DEVTOOLS_GLOBAL_HOOK__')?.configurable;
|
|
15
|
-
if (refreshHook) delete target.__REACT_DEVTOOLS_GLOBAL_HOOK__;
|
|
16
|
-
if (!target.__REACT_DEVTOOLS_GLOBAL_HOOK__) {
|
|
17
|
-
const initialize = ReactDevtools.initialize ?? ReactDevtools.default?.initialize;
|
|
18
|
-
initialize({
|
|
19
|
-
appendComponentStack: false,
|
|
20
|
-
breakOnConsoleErrors: false,
|
|
21
|
-
showInlineWarningsAndErrors: false,
|
|
22
|
-
hideConsoleLogsInStrictMode: false
|
|
23
|
-
});
|
|
24
|
-
if (refreshHook) {
|
|
25
|
-
const hook = target.__REACT_DEVTOOLS_GLOBAL_HOOK__;
|
|
26
|
-
const inject = hook.inject;
|
|
27
|
-
const ids = new Map();
|
|
28
|
-
hook.inject = renderer => {
|
|
29
|
-
const id = inject(renderer);
|
|
30
|
-
ids.set(id, previous.inject(renderer));
|
|
31
|
-
return id;
|
|
32
|
-
};
|
|
33
|
-
for (const name of ['onScheduleFiberRoot', 'onCommitFiberRoot', 'onCommitFiberUnmount']) {
|
|
34
|
-
const current = hook[name];
|
|
35
|
-
hook[name] = (id, ...args) => {
|
|
36
|
-
previous[name]?.(ids.get(id) ?? id, ...args);
|
|
37
|
-
return current?.(id, ...args);
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
return Boolean(target.__REACT_DEVTOOLS_GLOBAL_HOOK__);
|
|
43
|
-
}
|
|
44
|
-
registerBrowserDevTools();
|
|
1
|
+
"use strict";import*as l from"react-devtools-core";import{installEarlyNetworkRecorder as m}from"./earlyNetwork.js";import{hasReleaseOptIn as A}from"./releaseOptIn.js";export{earlyHookScript}from"./earlyHookScript.js";const d=["onScheduleFiberRoot","onCommitFiberRoot","onPostCommitFiberRoot","onCommitFiberUnmount","setStrictMode"];export function registerBrowserDevTools(u={}){if(typeof window==="undefined"||typeof document==="undefined")return false;const p=typeof __DEV__!=="undefined"?__DEV__:process.env.NODE_ENV!=="production";if(!p&&!u.enableInRelease&&!A())return false;m();const n=window;const o=n.__REACT_DEVTOOLS_GLOBAL_HOOK__;const f=o&&o.supportsFiber&&!o.getFiberRoots&&!o.sub&&Object.getOwnPropertyDescriptor(n,"__REACT_DEVTOOLS_GLOBAL_HOOK__")?.configurable;if(f)delete n.__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!n.__REACT_DEVTOOLS_GLOBAL_HOOK__){const L=l.initialize??l.default?.initialize;L({appendComponentStack:false,breakOnConsoleErrors:false,showInlineWarningsAndErrors:false,hideConsoleLogsInStrictMode:false});if(f){const i=n.__REACT_DEVTOOLS_GLOBAL_HOOK__;const O=i.inject;const _=new Map;i.inject=e=>{const t=O(e);_.set(t,o.inject(e));return t};for(const e of d){const t=i[e];if(typeof t!=="function")continue;i[e]=(r,...s)=>{if(_.has(r))o[e]?.(_.get(r),...s);return t(r,...s)}}const c=new Map;o.renderers?.forEach?.((e,t)=>c.set(t,O(e)));if(c.size){for(const e of d){const t=o[e];o[e]=function(r,...s){const E=t?.call(this,r,...s);const a=c.get(r);if(a!==void 0)i[e]?.(a,...s);return E}}}}}return Boolean(n.__REACT_DEVTOOLS_GLOBAL_HOOK__)}registerBrowserDevTools();
|
|
@@ -1,6 +1 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
/** The server entry does not load the browser's React DevTools backend. */
|
|
4
|
-
export function registerBrowserDevTools(_options = {}) {
|
|
5
|
-
return false;
|
|
6
|
-
}
|
|
1
|
+
"use strict";export{earlyHookScript}from"./earlyHookScript.js";export function registerBrowserDevTools(r={}){return false}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export const earlyHookScript="(function(){var w=window;if(w.__REACT_DEVTOOLS_GLOBAL_HOOK__)return;var n=0,r=new Map(),f=function(){};w.__REACT_DEVTOOLS_GLOBAL_HOOK__={renderers:r,supportsFiber:true,inject:function(x){var i=++n;r.set(i,x);return i},onScheduleFiberRoot:f,onCommitFiberRoot:f,onPostCommitFiberRoot:f,onCommitFiberUnmount:f,setStrictMode:f,checkDCE:f}})();";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const p=100;export function installEarlyNetworkRecorder(){if(typeof window==="undefined")return;const u=window;if(u.__BUOY_EARLY_NETWORK__)return;const d=Date.now;let f=true;const a=[];const y=c=>{a.push(c);if(a.length>p){const t=a.shift();if(t?.kind==="fetch")void t.settled.then(r=>r.clone?.body?.cancel()).catch(()=>{})}};const l=typeof window.fetch==="function"?window.fetch:void 0;if(l){window.fetch=function c(t,r){if(!f)return l.call(window,t,r);let h;try{if(t instanceof Request&&t.body&&!t.bodyUsed&&r?.body===void 0)h=t.clone()}catch{}const i=d();const o=l.call(window,t,r);const n=o.then(e=>{const s=d();const _=/event-stream|ndjson/.test(e.headers.get("content-type")??"");let w;try{if(!_)w=e.clone()}catch{}return{response:e,clone:w,headersAt:s}},e=>({error:e,headersAt:d()}));y({kind:"fetch",input:t,init:r,requestCopy:h,start:i,settled:n});return o}}if(typeof XMLHttpRequest!=="undefined"){const c=XMLHttpRequest.prototype;const{open:t,send:r,setRequestHeader:h}=c;const i=new WeakMap;c.open=function(o,n,...e){if(f)i.set(this,{method:o,url:String(n),headers:{}});return t.call(this,o,n,...e)};c.setRequestHeader=function(o,n){const e=i.get(this);if(e)e.headers[o]=n;return h.call(this,o,n)};c.send=function(o){const n=i.get(this);if(f&&n){i.delete(this);const e=d();const s=this;s.addEventListener("readystatechange",()=>{if(s.readyState===2&&s._buoyTtfb===void 0)s._buoyTtfb=d()-e;if(s.readyState===4)s._buoyEarlyEnd=d()});y({kind:"xhr",xhr:s,method:n.method,url:n.url,headers:n.headers,body:o,start:e})}return r.call(this,o)}}u.__BUOY_EARLY_NETWORK__={version:1,records:a,adopt(){f=false;return a.splice(0)}}}
|