@osdk/react-devtools 0.5.0
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/CHANGELOG.md +79 -0
- package/build/esm/DevToolsContext.js +19 -0
- package/build/esm/DevToolsContext.js.map +1 -0
- package/build/esm/components/ActionMetrics.js +89 -0
- package/build/esm/components/ActionMetrics.js.map +1 -0
- package/build/esm/components/BubbleChart.js +175 -0
- package/build/esm/components/BubbleChart.js.map +1 -0
- package/build/esm/components/BubbleChart.module.scss.js +6 -0
- package/build/esm/components/CacheInspectorTab.js +291 -0
- package/build/esm/components/CacheInspectorTab.js.map +1 -0
- package/build/esm/components/CacheInspectorTab.module.scss.js +39 -0
- package/build/esm/components/CacheMetrics.js +55 -0
- package/build/esm/components/CacheMetrics.js.map +1 -0
- package/build/esm/components/ComponentCard.js +124 -0
- package/build/esm/components/ComponentCard.js.map +1 -0
- package/build/esm/components/ComponentCard.module.scss.js +31 -0
- package/build/esm/components/ComputeTab.js +175 -0
- package/build/esm/components/ComputeTab.js.map +1 -0
- package/build/esm/components/CopyableCodeBlock.js +49 -0
- package/build/esm/components/CopyableCodeBlock.js.map +1 -0
- package/build/esm/components/CopyableCodeBlock.module.scss.js +10 -0
- package/build/esm/components/DebuggingTab.js +342 -0
- package/build/esm/components/DebuggingTab.js.map +1 -0
- package/build/esm/components/DebuggingTab.module.scss.js +18 -0
- package/build/esm/components/HookRow.js +180 -0
- package/build/esm/components/HookRow.js.map +1 -0
- package/build/esm/components/HookRow.module.scss.js +16 -0
- package/build/esm/components/ImprovementsTab.js +138 -0
- package/build/esm/components/ImprovementsTab.js.map +1 -0
- package/build/esm/components/ImprovementsTab.module.scss.js +30 -0
- package/build/esm/components/InspectorSelectionHeader.js +65 -0
- package/build/esm/components/InspectorSelectionHeader.js.map +1 -0
- package/build/esm/components/InterceptTab.js +862 -0
- package/build/esm/components/InterceptTab.js.map +1 -0
- package/build/esm/components/InterceptTab.module.scss.js +49 -0
- package/build/esm/components/IssueCard.js +115 -0
- package/build/esm/components/IssueCard.js.map +1 -0
- package/build/esm/components/IssueCard.module.scss.js +24 -0
- package/build/esm/components/LogEntryCard.js +94 -0
- package/build/esm/components/LogEntryCard.js.map +1 -0
- package/build/esm/components/LogEntryCard.module.scss.js +19 -0
- package/build/esm/components/MockEditor.js +316 -0
- package/build/esm/components/MockEditor.js.map +1 -0
- package/build/esm/components/MonitorErrorBoundary.js +64 -0
- package/build/esm/components/MonitorErrorBoundary.js.map +1 -0
- package/build/esm/components/MonitorErrorBoundary.module.scss.js +9 -0
- package/build/esm/components/MonitoringPanel.js +434 -0
- package/build/esm/components/MonitoringPanel.js.map +1 -0
- package/build/esm/components/MonitoringPanel.module.scss.js +81 -0
- package/build/esm/components/ObjectLoadingMetrics.js +60 -0
- package/build/esm/components/ObjectLoadingMetrics.js.map +1 -0
- package/build/esm/components/OsdkAppErrorBoundary.js +68 -0
- package/build/esm/components/OsdkAppErrorBoundary.js.map +1 -0
- package/build/esm/components/OsdkDevTools.js +40 -0
- package/build/esm/components/OsdkDevTools.js.map +1 -0
- package/build/esm/components/OverrideEditor.js +197 -0
- package/build/esm/components/OverrideEditor.js.map +1 -0
- package/build/esm/components/PerformanceTab.js +297 -0
- package/build/esm/components/PerformanceTab.js.map +1 -0
- package/build/esm/components/PrimitiveSelectionPanel.js +220 -0
- package/build/esm/components/PrimitiveSelectionPanel.js.map +1 -0
- package/build/esm/components/PrimitiveSelectionPanel.module.scss.js +26 -0
- package/build/esm/components/issueTypes.js +2 -0
- package/build/esm/components/issueTypes.js.map +1 -0
- package/build/esm/components/resolveComponentName.js +57 -0
- package/build/esm/components/resolveComponentName.js.map +1 -0
- package/build/esm/components/testHelpers.js +312 -0
- package/build/esm/components/testHelpers.js.map +1 -0
- package/build/esm/css.d.ts +20 -0
- package/build/esm/fiber/DegradationNotice.js +193 -0
- package/build/esm/fiber/DegradationNotice.js.map +1 -0
- package/build/esm/fiber/DevtoolsHook.js +252 -0
- package/build/esm/fiber/DevtoolsHook.js.map +1 -0
- package/build/esm/fiber/FiberAccess.js +65 -0
- package/build/esm/fiber/FiberAccess.js.map +1 -0
- package/build/esm/fiber/FiberInspection.js +140 -0
- package/build/esm/fiber/FiberInspection.js.map +1 -0
- package/build/esm/fiber/FiberTags.js +52 -0
- package/build/esm/fiber/FiberTags.js.map +1 -0
- package/build/esm/fiber/HookStateInspector.js +254 -0
- package/build/esm/fiber/HookStateInspector.js.map +1 -0
- package/build/esm/fiber/SafeFiberOperation.js +35 -0
- package/build/esm/fiber/SafeFiberOperation.js.map +1 -0
- package/build/esm/fiber/capabilities.js +180 -0
- package/build/esm/fiber/capabilities.js.map +1 -0
- package/build/esm/fiber/traverseFiber.js +129 -0
- package/build/esm/fiber/traverseFiber.js.map +1 -0
- package/build/esm/fiber/types.js +2 -0
- package/build/esm/fiber/types.js.map +1 -0
- package/build/esm/fiber/validation.js +155 -0
- package/build/esm/fiber/validation.js.map +1 -0
- package/build/esm/hooks/createPollingStore.js +81 -0
- package/build/esm/hooks/createPollingStore.js.map +1 -0
- package/build/esm/hooks/useActiveComponents.js +27 -0
- package/build/esm/hooks/useActiveComponents.js.map +1 -0
- package/build/esm/hooks/useComponentRegistry.js +25 -0
- package/build/esm/hooks/useComponentRegistry.js.map +1 -0
- package/build/esm/hooks/useComputeSelectors.js +43 -0
- package/build/esm/hooks/useComputeSelectors.js.map +1 -0
- package/build/esm/hooks/useConsoleLogs.js +46 -0
- package/build/esm/hooks/useConsoleLogs.js.map +1 -0
- package/build/esm/hooks/useInspectorSelection.js +93 -0
- package/build/esm/hooks/useInspectorSelection.js.map +1 -0
- package/build/esm/hooks/useMetrics.js +23 -0
- package/build/esm/hooks/useMetrics.js.map +1 -0
- package/build/esm/hooks/usePersistedState.js +89 -0
- package/build/esm/hooks/usePersistedState.js.map +1 -0
- package/build/esm/hooks/useRecommendations.js +123 -0
- package/build/esm/hooks/useRecommendations.js.map +1 -0
- package/build/esm/hooks/useSharedTick.js +49 -0
- package/build/esm/hooks/useSharedTick.js.map +1 -0
- package/build/esm/hooks/useTimeElapsed.js +51 -0
- package/build/esm/hooks/useTimeElapsed.js.map +1 -0
- package/build/esm/hooks/useTrackerSubscription.js +97 -0
- package/build/esm/hooks/useTrackerSubscription.js.map +1 -0
- package/build/esm/hooks/useUnusedFieldAnalysis.js +99 -0
- package/build/esm/hooks/useUnusedFieldAnalysis.js.map +1 -0
- package/build/esm/index.js +31 -0
- package/build/esm/index.js.map +1 -0
- package/build/esm/inspector/ClickToInspectSystem.js +228 -0
- package/build/esm/inspector/ClickToInspectSystem.js.map +1 -0
- package/build/esm/inspector/components/ComponentLabel.js +175 -0
- package/build/esm/inspector/components/ComponentLabel.js.map +1 -0
- package/build/esm/inspector/components/ComponentLabel.module.scss.js +12 -0
- package/build/esm/inspector/components/InspectorBanner.js +79 -0
- package/build/esm/inspector/components/InspectorBanner.js.map +1 -0
- package/build/esm/inspector/components/InspectorOverlay.js +149 -0
- package/build/esm/inspector/components/InspectorOverlay.js.map +1 -0
- package/build/esm/inspector/components/SelectionHighlight.js +74 -0
- package/build/esm/inspector/components/SelectionHighlight.js.map +1 -0
- package/build/esm/inspector/createClickToInspect.js +21 -0
- package/build/esm/inspector/createClickToInspect.js.map +1 -0
- package/build/esm/inspector/hooks/useAnimatedBounds.js +167 -0
- package/build/esm/inspector/hooks/useAnimatedBounds.js.map +1 -0
- package/build/esm/inspector/index.js +40 -0
- package/build/esm/inspector/index.js.map +1 -0
- package/build/esm/inspector/inspectorController.js +328 -0
- package/build/esm/inspector/inspectorController.js.map +1 -0
- package/build/esm/inspector/types.js +2 -0
- package/build/esm/inspector/types.js.map +1 -0
- package/build/esm/inspector/utils/elementBounds.js +72 -0
- package/build/esm/inspector/utils/elementBounds.js.map +1 -0
- package/build/esm/inspector/utils/interpolation.js +26 -0
- package/build/esm/inspector/utils/interpolation.js.map +1 -0
- package/build/esm/inspector/utils/labelPositioning.js +62 -0
- package/build/esm/inspector/utils/labelPositioning.js.map +1 -0
- package/build/esm/mocking/MockCacheKeyGenerator.js +109 -0
- package/build/esm/mocking/MockCacheKeyGenerator.js.map +1 -0
- package/build/esm/mocking/MockManager.js +281 -0
- package/build/esm/mocking/MockManager.js.map +1 -0
- package/build/esm/prototyping/PrototypeOverrideStore.js +66 -0
- package/build/esm/prototyping/PrototypeOverrideStore.js.map +1 -0
- package/build/esm/prototyping/index.js +18 -0
- package/build/esm/prototyping/index.js.map +1 -0
- package/build/esm/public/vite.js +19 -0
- package/build/esm/public/vite.js.map +1 -0
- package/build/esm/register.js +41 -0
- package/build/esm/register.js.map +1 -0
- package/build/esm/scss.d.ts +20 -0
- package/build/esm/store/ComputeStore.js +269 -0
- package/build/esm/store/ComputeStore.js.map +1 -0
- package/build/esm/store/ConsoleLogStore.js +289 -0
- package/build/esm/store/ConsoleLogStore.js.map +1 -0
- package/build/esm/store/MetricsStore.js +428 -0
- package/build/esm/store/MetricsStore.js.map +1 -0
- package/build/esm/store/MonitorStore.js +288 -0
- package/build/esm/store/MonitorStore.js.map +1 -0
- package/build/esm/store/SubscribableStore.js +38 -0
- package/build/esm/store/SubscribableStore.js.map +1 -0
- package/build/esm/store/WindowErrorStore.js +195 -0
- package/build/esm/store/WindowErrorStore.js.map +1 -0
- package/build/esm/styles.css +19441 -0
- package/build/esm/styles.js +31 -0
- package/build/esm/styles.js.map +1 -0
- package/build/esm/types/compute.js +2 -0
- package/build/esm/types/compute.js.map +1 -0
- package/build/esm/types/emissions.js +2 -0
- package/build/esm/types/emissions.js.map +1 -0
- package/build/esm/types/index.js +23 -0
- package/build/esm/types/index.js.map +1 -0
- package/build/esm/utils/ActionLifecycleTracker.js +178 -0
- package/build/esm/utils/ActionLifecycleTracker.js.map +1 -0
- package/build/esm/utils/CacheEfficiencyAnalyzer.js +198 -0
- package/build/esm/utils/CacheEfficiencyAnalyzer.js.map +1 -0
- package/build/esm/utils/CircularBuffer.js +96 -0
- package/build/esm/utils/CircularBuffer.js.map +1 -0
- package/build/esm/utils/ComponentContextCapture.js +215 -0
- package/build/esm/utils/ComponentContextCapture.js.map +1 -0
- package/build/esm/utils/ComponentPrimitiveDiscovery.js +173 -0
- package/build/esm/utils/ComponentPrimitiveDiscovery.js.map +1 -0
- package/build/esm/utils/ComponentQueryRegistry.js +340 -0
- package/build/esm/utils/ComponentQueryRegistry.js.map +1 -0
- package/build/esm/utils/ComputeMonitor.js +199 -0
- package/build/esm/utils/ComputeMonitor.js.map +1 -0
- package/build/esm/utils/EventTimeline.js +130 -0
- package/build/esm/utils/EventTimeline.js.map +1 -0
- package/build/esm/utils/LinkTraversalTracker.js +116 -0
- package/build/esm/utils/LinkTraversalTracker.js.map +1 -0
- package/build/esm/utils/MockDataGenerator.js +473 -0
- package/build/esm/utils/MockDataGenerator.js.map +1 -0
- package/build/esm/utils/ObservableClientMonitor.js +768 -0
- package/build/esm/utils/ObservableClientMonitor.js.map +1 -0
- package/build/esm/utils/PerformanceRecommendationEngine.js +185 -0
- package/build/esm/utils/PerformanceRecommendationEngine.js.map +1 -0
- package/build/esm/utils/PropertyAccessTracker.js +238 -0
- package/build/esm/utils/PropertyAccessTracker.js.map +1 -0
- package/build/esm/utils/RecommendationMatcher.js +53 -0
- package/build/esm/utils/RecommendationMatcher.js.map +1 -0
- package/build/esm/utils/SubscriptionTracker.js +132 -0
- package/build/esm/utils/SubscriptionTracker.js.map +1 -0
- package/build/esm/utils/UnusedFieldAnalyzer.js +186 -0
- package/build/esm/utils/UnusedFieldAnalyzer.js.map +1 -0
- package/build/esm/utils/WaterfallDetector.js +200 -0
- package/build/esm/utils/WaterfallDetector.js.map +1 -0
- package/build/esm/utils/computePayload.js +37 -0
- package/build/esm/utils/computePayload.js.map +1 -0
- package/build/esm/utils/computeRequest.js +29 -0
- package/build/esm/utils/computeRequest.js.map +1 -0
- package/build/esm/utils/format.js +69 -0
- package/build/esm/utils/format.js.map +1 -0
- package/build/esm/utils/logger.js +31 -0
- package/build/esm/utils/logger.js.map +1 -0
- package/build/esm/vite/constants.js +18 -0
- package/build/esm/vite/constants.js.map +1 -0
- package/build/esm/vite/hookInstaller.js +99 -0
- package/build/esm/vite/hookInstaller.js.map +1 -0
- package/build/esm/vite/index.js +77 -0
- package/build/esm/vite/index.js.map +1 -0
- package/build/types/DevToolsContext.d.ts +3 -0
- package/build/types/DevToolsContext.d.ts.map +1 -0
- package/build/types/components/ActionMetrics.d.ts +6 -0
- package/build/types/components/ActionMetrics.d.ts.map +1 -0
- package/build/types/components/BubbleChart.d.ts +10 -0
- package/build/types/components/BubbleChart.d.ts.map +1 -0
- package/build/types/components/CacheInspectorTab.d.ts +6 -0
- package/build/types/components/CacheInspectorTab.d.ts.map +1 -0
- package/build/types/components/CacheMetrics.d.ts +6 -0
- package/build/types/components/CacheMetrics.d.ts.map +1 -0
- package/build/types/components/ComponentCard.d.ts +13 -0
- package/build/types/components/ComponentCard.d.ts.map +1 -0
- package/build/types/components/ComputeTab.d.ts +6 -0
- package/build/types/components/ComputeTab.d.ts.map +1 -0
- package/build/types/components/CopyableCodeBlock.d.ts +7 -0
- package/build/types/components/CopyableCodeBlock.d.ts.map +1 -0
- package/build/types/components/DebuggingTab.d.ts +6 -0
- package/build/types/components/DebuggingTab.d.ts.map +1 -0
- package/build/types/components/HookRow.d.ts +9 -0
- package/build/types/components/HookRow.d.ts.map +1 -0
- package/build/types/components/ImprovementsTab.d.ts +7 -0
- package/build/types/components/ImprovementsTab.d.ts.map +1 -0
- package/build/types/components/InspectorSelectionHeader.d.ts +12 -0
- package/build/types/components/InspectorSelectionHeader.d.ts.map +1 -0
- package/build/types/components/InterceptTab.d.ts +126 -0
- package/build/types/components/InterceptTab.d.ts.map +1 -0
- package/build/types/components/IssueCard.d.ts +8 -0
- package/build/types/components/IssueCard.d.ts.map +1 -0
- package/build/types/components/LogEntryCard.d.ts +7 -0
- package/build/types/components/LogEntryCard.d.ts.map +1 -0
- package/build/types/components/MockEditor.d.ts +58 -0
- package/build/types/components/MockEditor.d.ts.map +1 -0
- package/build/types/components/MonitorErrorBoundary.d.ts +16 -0
- package/build/types/components/MonitorErrorBoundary.d.ts.map +1 -0
- package/build/types/components/MonitoringPanel.d.ts +8 -0
- package/build/types/components/MonitoringPanel.d.ts.map +1 -0
- package/build/types/components/ObjectLoadingMetrics.d.ts +7 -0
- package/build/types/components/ObjectLoadingMetrics.d.ts.map +1 -0
- package/build/types/components/OsdkAppErrorBoundary.d.ts +18 -0
- package/build/types/components/OsdkAppErrorBoundary.d.ts.map +1 -0
- package/build/types/components/OsdkDevTools.d.ts +2 -0
- package/build/types/components/OsdkDevTools.d.ts.map +1 -0
- package/build/types/components/OverrideEditor.d.ts +26 -0
- package/build/types/components/OverrideEditor.d.ts.map +1 -0
- package/build/types/components/PerformanceTab.d.ts +8 -0
- package/build/types/components/PerformanceTab.d.ts.map +1 -0
- package/build/types/components/PrimitiveSelectionPanel.d.ts +28 -0
- package/build/types/components/PrimitiveSelectionPanel.d.ts.map +1 -0
- package/build/types/components/issueTypes.d.ts +16 -0
- package/build/types/components/issueTypes.d.ts.map +1 -0
- package/build/types/components/resolveComponentName.d.ts +3 -0
- package/build/types/components/resolveComponentName.d.ts.map +1 -0
- package/build/types/components/testHelpers.d.ts +2 -0
- package/build/types/components/testHelpers.d.ts.map +1 -0
- package/build/types/css.d.d.ts +4 -0
- package/build/types/css.d.d.ts.map +1 -0
- package/build/types/fiber/DegradationNotice.d.ts +8 -0
- package/build/types/fiber/DegradationNotice.d.ts.map +1 -0
- package/build/types/fiber/DevtoolsHook.d.ts +7 -0
- package/build/types/fiber/DevtoolsHook.d.ts.map +1 -0
- package/build/types/fiber/FiberAccess.d.ts +2 -0
- package/build/types/fiber/FiberAccess.d.ts.map +1 -0
- package/build/types/fiber/FiberInspection.d.ts +6 -0
- package/build/types/fiber/FiberInspection.d.ts.map +1 -0
- package/build/types/fiber/FiberTags.d.ts +33 -0
- package/build/types/fiber/FiberTags.d.ts.map +1 -0
- package/build/types/fiber/HookStateInspector.d.ts +45 -0
- package/build/types/fiber/HookStateInspector.d.ts.map +1 -0
- package/build/types/fiber/SafeFiberOperation.d.ts +7 -0
- package/build/types/fiber/SafeFiberOperation.d.ts.map +1 -0
- package/build/types/fiber/capabilities.d.ts +38 -0
- package/build/types/fiber/capabilities.d.ts.map +1 -0
- package/build/types/fiber/traverseFiber.d.ts +5 -0
- package/build/types/fiber/traverseFiber.d.ts.map +1 -0
- package/build/types/fiber/types.d.ts +87 -0
- package/build/types/fiber/types.d.ts.map +1 -0
- package/build/types/fiber/validation.d.ts +10 -0
- package/build/types/fiber/validation.d.ts.map +1 -0
- package/build/types/hooks/createPollingStore.d.ts +5 -0
- package/build/types/hooks/createPollingStore.d.ts.map +1 -0
- package/build/types/hooks/useActiveComponents.d.ts +3 -0
- package/build/types/hooks/useActiveComponents.d.ts.map +1 -0
- package/build/types/hooks/useComponentRegistry.d.ts +3 -0
- package/build/types/hooks/useComponentRegistry.d.ts.map +1 -0
- package/build/types/hooks/useComputeSelectors.d.ts +7 -0
- package/build/types/hooks/useComputeSelectors.d.ts.map +1 -0
- package/build/types/hooks/useConsoleLogs.d.ts +7 -0
- package/build/types/hooks/useConsoleLogs.d.ts.map +1 -0
- package/build/types/hooks/useInspectorSelection.d.ts +9 -0
- package/build/types/hooks/useInspectorSelection.d.ts.map +1 -0
- package/build/types/hooks/useMetrics.d.ts +3 -0
- package/build/types/hooks/useMetrics.d.ts.map +1 -0
- package/build/types/hooks/usePersistedState.d.ts +1 -0
- package/build/types/hooks/usePersistedState.d.ts.map +1 -0
- package/build/types/hooks/useRecommendations.d.ts +10 -0
- package/build/types/hooks/useRecommendations.d.ts.map +1 -0
- package/build/types/hooks/useSharedTick.d.ts +1 -0
- package/build/types/hooks/useSharedTick.d.ts.map +1 -0
- package/build/types/hooks/useTimeElapsed.d.ts +1 -0
- package/build/types/hooks/useTimeElapsed.d.ts.map +1 -0
- package/build/types/hooks/useTrackerSubscription.d.ts +16 -0
- package/build/types/hooks/useTrackerSubscription.d.ts.map +1 -0
- package/build/types/hooks/useUnusedFieldAnalysis.d.ts +8 -0
- package/build/types/hooks/useUnusedFieldAnalysis.d.ts.map +1 -0
- package/build/types/index.d.ts +21 -0
- package/build/types/index.d.ts.map +1 -0
- package/build/types/inspector/ClickToInspectSystem.d.ts +40 -0
- package/build/types/inspector/ClickToInspectSystem.d.ts.map +1 -0
- package/build/types/inspector/components/ComponentLabel.d.ts +3 -0
- package/build/types/inspector/components/ComponentLabel.d.ts.map +1 -0
- package/build/types/inspector/components/InspectorBanner.d.ts +5 -0
- package/build/types/inspector/components/InspectorBanner.d.ts.map +1 -0
- package/build/types/inspector/components/InspectorOverlay.d.ts +3 -0
- package/build/types/inspector/components/InspectorOverlay.d.ts.map +1 -0
- package/build/types/inspector/components/SelectionHighlight.d.ts +3 -0
- package/build/types/inspector/components/SelectionHighlight.d.ts.map +1 -0
- package/build/types/inspector/createClickToInspect.d.ts +3 -0
- package/build/types/inspector/createClickToInspect.d.ts.map +1 -0
- package/build/types/inspector/hooks/useAnimatedBounds.d.ts +2 -0
- package/build/types/inspector/hooks/useAnimatedBounds.d.ts.map +1 -0
- package/build/types/inspector/index.d.ts +13 -0
- package/build/types/inspector/index.d.ts.map +1 -0
- package/build/types/inspector/inspectorController.d.ts +2 -0
- package/build/types/inspector/inspectorController.d.ts.map +1 -0
- package/build/types/inspector/types.d.ts +94 -0
- package/build/types/inspector/types.d.ts.map +1 -0
- package/build/types/inspector/utils/elementBounds.d.ts +3 -0
- package/build/types/inspector/utils/elementBounds.d.ts.map +1 -0
- package/build/types/inspector/utils/interpolation.d.ts +7 -0
- package/build/types/inspector/utils/interpolation.d.ts.map +1 -0
- package/build/types/inspector/utils/labelPositioning.d.ts +3 -0
- package/build/types/inspector/utils/labelPositioning.d.ts.map +1 -0
- package/build/types/mocking/MockCacheKeyGenerator.d.ts +41 -0
- package/build/types/mocking/MockCacheKeyGenerator.d.ts.map +1 -0
- package/build/types/mocking/MockManager.d.ts +103 -0
- package/build/types/mocking/MockManager.d.ts.map +1 -0
- package/build/types/prototyping/PrototypeOverrideStore.d.ts +33 -0
- package/build/types/prototyping/PrototypeOverrideStore.d.ts.map +1 -0
- package/build/types/prototyping/index.d.ts +1 -0
- package/build/types/prototyping/index.d.ts.map +1 -0
- package/build/types/public/vite.d.ts +2 -0
- package/build/types/public/vite.d.ts.map +1 -0
- package/build/types/register.d.ts +1 -0
- package/build/types/register.d.ts.map +1 -0
- package/build/types/scss.d.d.ts +6 -0
- package/build/types/scss.d.d.ts.map +1 -0
- package/build/types/store/ComputeStore.d.ts +47 -0
- package/build/types/store/ComputeStore.d.ts.map +1 -0
- package/build/types/store/ConsoleLogStore.d.ts +29 -0
- package/build/types/store/ConsoleLogStore.d.ts.map +1 -0
- package/build/types/store/MetricsStore.d.ts +42 -0
- package/build/types/store/MetricsStore.d.ts.map +1 -0
- package/build/types/store/MonitorStore.d.ts +86 -0
- package/build/types/store/MonitorStore.d.ts.map +1 -0
- package/build/types/store/SubscribableStore.d.ts +6 -0
- package/build/types/store/SubscribableStore.d.ts.map +1 -0
- package/build/types/store/WindowErrorStore.d.ts +32 -0
- package/build/types/store/WindowErrorStore.d.ts.map +1 -0
- package/build/types/styles.d.ts +1 -0
- package/build/types/styles.d.ts.map +1 -0
- package/build/types/types/compute.d.ts +73 -0
- package/build/types/types/compute.d.ts.map +1 -0
- package/build/types/types/emissions.d.ts +24 -0
- package/build/types/types/emissions.d.ts.map +1 -0
- package/build/types/types/index.d.ts +143 -0
- package/build/types/types/index.d.ts.map +1 -0
- package/build/types/utils/ActionLifecycleTracker.d.ts +39 -0
- package/build/types/utils/ActionLifecycleTracker.d.ts.map +1 -0
- package/build/types/utils/CacheEfficiencyAnalyzer.d.ts +45 -0
- package/build/types/utils/CacheEfficiencyAnalyzer.d.ts.map +1 -0
- package/build/types/utils/CircularBuffer.d.ts +18 -0
- package/build/types/utils/CircularBuffer.d.ts.map +1 -0
- package/build/types/utils/ComponentContextCapture.d.ts +29 -0
- package/build/types/utils/ComponentContextCapture.d.ts.map +1 -0
- package/build/types/utils/ComponentPrimitiveDiscovery.d.ts +62 -0
- package/build/types/utils/ComponentPrimitiveDiscovery.d.ts.map +1 -0
- package/build/types/utils/ComponentQueryRegistry.d.ts +91 -0
- package/build/types/utils/ComponentQueryRegistry.d.ts.map +1 -0
- package/build/types/utils/ComputeMonitor.d.ts +14 -0
- package/build/types/utils/ComputeMonitor.d.ts.map +1 -0
- package/build/types/utils/EventTimeline.d.ts +102 -0
- package/build/types/utils/EventTimeline.d.ts.map +1 -0
- package/build/types/utils/LinkTraversalTracker.d.ts +43 -0
- package/build/types/utils/LinkTraversalTracker.d.ts.map +1 -0
- package/build/types/utils/MockDataGenerator.d.ts +23 -0
- package/build/types/utils/MockDataGenerator.d.ts.map +1 -0
- package/build/types/utils/ObservableClientMonitor.d.ts +62 -0
- package/build/types/utils/ObservableClientMonitor.d.ts.map +1 -0
- package/build/types/utils/PerformanceRecommendationEngine.d.ts +67 -0
- package/build/types/utils/PerformanceRecommendationEngine.d.ts.map +1 -0
- package/build/types/utils/PropertyAccessTracker.d.ts +50 -0
- package/build/types/utils/PropertyAccessTracker.d.ts.map +1 -0
- package/build/types/utils/RecommendationMatcher.d.ts +5 -0
- package/build/types/utils/RecommendationMatcher.d.ts.map +1 -0
- package/build/types/utils/SubscriptionTracker.d.ts +17 -0
- package/build/types/utils/SubscriptionTracker.d.ts.map +1 -0
- package/build/types/utils/UnusedFieldAnalyzer.d.ts +46 -0
- package/build/types/utils/UnusedFieldAnalyzer.d.ts.map +1 -0
- package/build/types/utils/WaterfallDetector.d.ts +28 -0
- package/build/types/utils/WaterfallDetector.d.ts.map +1 -0
- package/build/types/utils/computePayload.d.ts +3 -0
- package/build/types/utils/computePayload.d.ts.map +1 -0
- package/build/types/utils/computeRequest.d.ts +20 -0
- package/build/types/utils/computeRequest.d.ts.map +1 -0
- package/build/types/utils/format.d.ts +5 -0
- package/build/types/utils/format.d.ts.map +1 -0
- package/build/types/utils/logger.d.ts +2 -0
- package/build/types/utils/logger.d.ts.map +1 -0
- package/build/types/vite/constants.d.ts +1 -0
- package/build/types/vite/constants.d.ts.map +1 -0
- package/build/types/vite/hookInstaller.d.ts +1 -0
- package/build/types/vite/hookInstaller.d.ts.map +1 -0
- package/build/types/vite/index.d.ts +20 -0
- package/build/types/vite/index.d.ts.map +1 -0
- package/package.json +114 -0
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Palantir Technologies, Inc. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import React from "react";
|
|
18
|
+
export function useTimeElapsed(startTime) {
|
|
19
|
+
const startMs = startTime?.getTime();
|
|
20
|
+
const stateRef = React.useRef({
|
|
21
|
+
tick: 0,
|
|
22
|
+
cachedTick: -1,
|
|
23
|
+
cachedValue: undefined
|
|
24
|
+
});
|
|
25
|
+
const subscribe = React.useCallback(callback => {
|
|
26
|
+
if (startMs == null) {
|
|
27
|
+
return () => {};
|
|
28
|
+
}
|
|
29
|
+
const intervalId = setInterval(() => {
|
|
30
|
+
stateRef.current.tick++;
|
|
31
|
+
callback();
|
|
32
|
+
}, 1000);
|
|
33
|
+
return () => {
|
|
34
|
+
clearInterval(intervalId);
|
|
35
|
+
};
|
|
36
|
+
}, [startMs]);
|
|
37
|
+
const getSnapshot = React.useCallback(() => {
|
|
38
|
+
if (startMs == null) {
|
|
39
|
+
return undefined;
|
|
40
|
+
}
|
|
41
|
+
const state = stateRef.current;
|
|
42
|
+
if (state.cachedTick === state.tick) {
|
|
43
|
+
return state.cachedValue;
|
|
44
|
+
}
|
|
45
|
+
state.cachedValue = Date.now() - startMs;
|
|
46
|
+
state.cachedTick = state.tick;
|
|
47
|
+
return state.cachedValue;
|
|
48
|
+
}, [startMs]);
|
|
49
|
+
return React.useSyncExternalStore(subscribe, getSnapshot);
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=useTimeElapsed.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useTimeElapsed.js","names":["React","useTimeElapsed","startTime","startMs","getTime","stateRef","useRef","tick","cachedTick","cachedValue","undefined","subscribe","useCallback","callback","intervalId","setInterval","current","clearInterval","getSnapshot","state","Date","now","useSyncExternalStore"],"sources":["useTimeElapsed.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from \"react\";\n\nexport function useTimeElapsed(\n startTime: Date | undefined,\n): number | undefined {\n const startMs = startTime?.getTime();\n\n const stateRef = React.useRef({\n tick: 0,\n cachedTick: -1,\n cachedValue: undefined as number | undefined,\n });\n\n const subscribe = React.useCallback(\n (callback: () => void) => {\n if (startMs == null) {\n return () => {};\n }\n\n const intervalId = setInterval(() => {\n stateRef.current.tick++;\n callback();\n }, 1000);\n return () => {\n clearInterval(intervalId);\n };\n },\n [startMs],\n );\n\n const getSnapshot = React.useCallback(\n (): number | undefined => {\n if (startMs == null) {\n return undefined;\n }\n const state = stateRef.current;\n if (state.cachedTick === state.tick) {\n return state.cachedValue;\n }\n state.cachedValue = Date.now() - startMs;\n state.cachedTick = state.tick;\n return state.cachedValue;\n },\n [startMs],\n );\n\n return React.useSyncExternalStore(subscribe, getSnapshot);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,KAAK,MAAM,OAAO;AAEzB,OAAO,SAASC,cAAcA,CAC5BC,SAA2B,EACP;EACpB,MAAMC,OAAO,GAAGD,SAAS,EAAEE,OAAO,CAAC,CAAC;EAEpC,MAAMC,QAAQ,GAAGL,KAAK,CAACM,MAAM,CAAC;IAC5BC,IAAI,EAAE,CAAC;IACPC,UAAU,EAAE,CAAC,CAAC;IACdC,WAAW,EAAEC;EACf,CAAC,CAAC;EAEF,MAAMC,SAAS,GAAGX,KAAK,CAACY,WAAW,CAChCC,QAAoB,IAAK;IACxB,IAAIV,OAAO,IAAI,IAAI,EAAE;MACnB,OAAO,MAAM,CAAC,CAAC;IACjB;IAEA,MAAMW,UAAU,GAAGC,WAAW,CAAC,MAAM;MACnCV,QAAQ,CAACW,OAAO,CAACT,IAAI,EAAE;MACvBM,QAAQ,CAAC,CAAC;IACZ,CAAC,EAAE,IAAI,CAAC;IACR,OAAO,MAAM;MACXI,aAAa,CAACH,UAAU,CAAC;IAC3B,CAAC;EACH,CAAC,EACD,CAACX,OAAO,CACV,CAAC;EAED,MAAMe,WAAW,GAAGlB,KAAK,CAACY,WAAW,CACnC,MAA0B;IACxB,IAAIT,OAAO,IAAI,IAAI,EAAE;MACnB,OAAOO,SAAS;IAClB;IACA,MAAMS,KAAK,GAAGd,QAAQ,CAACW,OAAO;IAC9B,IAAIG,KAAK,CAACX,UAAU,KAAKW,KAAK,CAACZ,IAAI,EAAE;MACnC,OAAOY,KAAK,CAACV,WAAW;IAC1B;IACAU,KAAK,CAACV,WAAW,GAAGW,IAAI,CAACC,GAAG,CAAC,CAAC,GAAGlB,OAAO;IACxCgB,KAAK,CAACX,UAAU,GAAGW,KAAK,CAACZ,IAAI;IAC7B,OAAOY,KAAK,CAACV,WAAW;EAC1B,CAAC,EACD,CAACN,OAAO,CACV,CAAC;EAED,OAAOH,KAAK,CAACsB,oBAAoB,CAACX,SAAS,EAAEO,WAAW,CAAC;AAC3D","ignoreList":[]}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Palantir Technologies, Inc. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import React from "react";
|
|
18
|
+
export function useTrackerSubscription(tracker, getData, emptyData, options = {}) {
|
|
19
|
+
const {
|
|
20
|
+
autoRefresh = true,
|
|
21
|
+
refreshInterval = 1000,
|
|
22
|
+
limit = 10
|
|
23
|
+
} = options;
|
|
24
|
+
const getDataRef = React.useRef(getData);
|
|
25
|
+
const emptyDataRef = React.useRef(emptyData);
|
|
26
|
+
getDataRef.current = getData;
|
|
27
|
+
emptyDataRef.current = emptyData;
|
|
28
|
+
const storeRef = React.useRef(null);
|
|
29
|
+
if (storeRef.current == null) {
|
|
30
|
+
storeRef.current = {
|
|
31
|
+
data: tracker ? getData(tracker, limit) : emptyData,
|
|
32
|
+
listeners: new Set()
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
const subscribe = React.useCallback(callback => {
|
|
36
|
+
const store = storeRef.current;
|
|
37
|
+
if (store == null) {
|
|
38
|
+
return () => {};
|
|
39
|
+
}
|
|
40
|
+
store.listeners.add(callback);
|
|
41
|
+
const doRefresh = () => {
|
|
42
|
+
if (store == null) {
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
if (tracker) {
|
|
46
|
+
store.data = getDataRef.current(tracker, limit);
|
|
47
|
+
} else {
|
|
48
|
+
store.data = emptyDataRef.current;
|
|
49
|
+
}
|
|
50
|
+
for (const listener of store.listeners) {
|
|
51
|
+
listener();
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
doRefresh();
|
|
55
|
+
let unsubscribeTracker;
|
|
56
|
+
let intervalId;
|
|
57
|
+
if (tracker && autoRefresh) {
|
|
58
|
+
unsubscribeTracker = tracker.subscribe(doRefresh);
|
|
59
|
+
intervalId = setInterval(doRefresh, refreshInterval);
|
|
60
|
+
}
|
|
61
|
+
return () => {
|
|
62
|
+
store.listeners.delete(callback);
|
|
63
|
+
if (unsubscribeTracker) {
|
|
64
|
+
unsubscribeTracker();
|
|
65
|
+
}
|
|
66
|
+
if (intervalId !== undefined) {
|
|
67
|
+
clearInterval(intervalId);
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
}, [tracker, autoRefresh, refreshInterval, limit]);
|
|
71
|
+
const getSnapshot = React.useCallback(() => {
|
|
72
|
+
if (storeRef.current == null) {
|
|
73
|
+
return emptyData;
|
|
74
|
+
}
|
|
75
|
+
return storeRef.current.data;
|
|
76
|
+
}, [emptyData]);
|
|
77
|
+
const data = React.useSyncExternalStore(subscribe, getSnapshot);
|
|
78
|
+
const refresh = React.useCallback(() => {
|
|
79
|
+
const store = storeRef.current;
|
|
80
|
+
if (store == null) {
|
|
81
|
+
return;
|
|
82
|
+
}
|
|
83
|
+
if (tracker) {
|
|
84
|
+
store.data = getDataRef.current(tracker, limit);
|
|
85
|
+
} else {
|
|
86
|
+
store.data = emptyDataRef.current;
|
|
87
|
+
}
|
|
88
|
+
for (const listener of store.listeners) {
|
|
89
|
+
listener();
|
|
90
|
+
}
|
|
91
|
+
}, [tracker, limit]);
|
|
92
|
+
return {
|
|
93
|
+
data,
|
|
94
|
+
refresh
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
//# sourceMappingURL=useTrackerSubscription.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useTrackerSubscription.js","names":["React","useTrackerSubscription","tracker","getData","emptyData","options","autoRefresh","refreshInterval","limit","getDataRef","useRef","emptyDataRef","current","storeRef","data","listeners","Set","subscribe","useCallback","callback","store","add","doRefresh","listener","unsubscribeTracker","intervalId","setInterval","delete","undefined","clearInterval","getSnapshot","useSyncExternalStore","refresh"],"sources":["useTrackerSubscription.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from \"react\";\n\ninterface Subscribable {\n subscribe(cb: () => void): () => void;\n}\n\nexport interface TrackerSubscriptionOptions {\n autoRefresh?: boolean;\n refreshInterval?: number;\n limit?: number;\n}\n\nexport function useTrackerSubscription<TTracker extends Subscribable, TData>(\n tracker: TTracker | null,\n getData: (tracker: TTracker, limit: number) => TData,\n emptyData: TData,\n options: TrackerSubscriptionOptions = {},\n): { data: TData; refresh: () => void } {\n const {\n autoRefresh = true,\n refreshInterval = 1000,\n limit = 10,\n } = options;\n\n const getDataRef = React.useRef(getData);\n const emptyDataRef = React.useRef(emptyData);\n getDataRef.current = getData;\n emptyDataRef.current = emptyData;\n\n const storeRef = React.useRef<\n {\n data: TData;\n listeners: Set<() => void>;\n } | null\n >(null);\n\n if (storeRef.current == null) {\n storeRef.current = {\n data: tracker ? getData(tracker, limit) : emptyData,\n listeners: new Set(),\n };\n }\n\n const subscribe = React.useCallback(\n (callback: () => void) => {\n const store = storeRef.current;\n if (store == null) {\n return () => {};\n }\n store.listeners.add(callback);\n\n const doRefresh = () => {\n if (store == null) {\n return;\n }\n if (tracker) {\n store.data = getDataRef.current(tracker, limit);\n } else {\n store.data = emptyDataRef.current;\n }\n for (const listener of store.listeners) {\n listener();\n }\n };\n\n doRefresh();\n\n let unsubscribeTracker: (() => void) | undefined;\n let intervalId: ReturnType<typeof setInterval> | undefined;\n\n if (tracker && autoRefresh) {\n unsubscribeTracker = tracker.subscribe(doRefresh);\n intervalId = setInterval(doRefresh, refreshInterval);\n }\n\n return () => {\n store.listeners.delete(callback);\n if (unsubscribeTracker) {\n unsubscribeTracker();\n }\n if (intervalId !== undefined) {\n clearInterval(intervalId);\n }\n };\n },\n [tracker, autoRefresh, refreshInterval, limit],\n );\n\n const getSnapshot = React.useCallback(\n (): TData => {\n if (storeRef.current == null) {\n return emptyData;\n }\n return storeRef.current.data;\n },\n [emptyData],\n );\n\n const data = React.useSyncExternalStore(subscribe, getSnapshot);\n\n const refresh = React.useCallback(() => {\n const store = storeRef.current;\n if (store == null) {\n return;\n }\n if (tracker) {\n store.data = getDataRef.current(tracker, limit);\n } else {\n store.data = emptyDataRef.current;\n }\n for (const listener of store.listeners) {\n listener();\n }\n }, [tracker, limit]);\n\n return { data, refresh };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,KAAK,MAAM,OAAO;AAYzB,OAAO,SAASC,sBAAsBA,CACpCC,OAAwB,EACxBC,OAAoD,EACpDC,SAAgB,EAChBC,OAAmC,GAAG,CAAC,CAAC,EACF;EACtC,MAAM;IACJC,WAAW,GAAG,IAAI;IAClBC,eAAe,GAAG,IA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AK,CAAC,CAAC;EAEpB,OAAO;IAAEM,IAAI;IAAEkB;EAAQ,CAAC;AAC1B","ignoreList":[]}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Palantir Technologies, Inc. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import React from "react";
|
|
18
|
+
import { UnusedFieldAnalyzer } from "../utils/UnusedFieldAnalyzer.js";
|
|
19
|
+
class AnalysisStore {
|
|
20
|
+
state = {
|
|
21
|
+
report: null,
|
|
22
|
+
isLoading: true,
|
|
23
|
+
error: null
|
|
24
|
+
};
|
|
25
|
+
listeners = new Set();
|
|
26
|
+
isAnalyzing = false;
|
|
27
|
+
constructor(monitorStore, updateIntervalMs) {
|
|
28
|
+
this.monitorStore = monitorStore;
|
|
29
|
+
this.updateIntervalMs = updateIntervalMs;
|
|
30
|
+
}
|
|
31
|
+
subscribe(callback) {
|
|
32
|
+
this.listeners.add(callback);
|
|
33
|
+
if (this.listeners.size === 1) {
|
|
34
|
+
setTimeout(() => void this.analyze(), 0);
|
|
35
|
+
this.intervalId = setInterval(() => {
|
|
36
|
+
void this.analyze();
|
|
37
|
+
}, this.updateIntervalMs);
|
|
38
|
+
}
|
|
39
|
+
return () => {
|
|
40
|
+
this.listeners.delete(callback);
|
|
41
|
+
if (this.listeners.size === 0 && this.intervalId !== undefined) {
|
|
42
|
+
clearInterval(this.intervalId);
|
|
43
|
+
this.intervalId = undefined;
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
getSnapshot() {
|
|
48
|
+
return this.state;
|
|
49
|
+
}
|
|
50
|
+
async analyze() {
|
|
51
|
+
if (this.isAnalyzing) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
this.isAnalyzing = true;
|
|
55
|
+
try {
|
|
56
|
+
this.state = {
|
|
57
|
+
...this.state,
|
|
58
|
+
isLoading: true
|
|
59
|
+
};
|
|
60
|
+
this.notify();
|
|
61
|
+
const registry = this.monitorStore.getComponentRegistry();
|
|
62
|
+
const propertyTracker = this.monitorStore.getPropertyAccessTracker();
|
|
63
|
+
const cacheSnapshot = await this.monitorStore.getCacheSnapshot();
|
|
64
|
+
const analyzer = new UnusedFieldAnalyzer(registry, propertyTracker);
|
|
65
|
+
const report = analyzer.generateGlobalReport(cacheSnapshot);
|
|
66
|
+
this.state = {
|
|
67
|
+
report,
|
|
68
|
+
isLoading: false,
|
|
69
|
+
error: null
|
|
70
|
+
};
|
|
71
|
+
this.notify();
|
|
72
|
+
} catch (error) {
|
|
73
|
+
this.state = {
|
|
74
|
+
report: null,
|
|
75
|
+
isLoading: false,
|
|
76
|
+
error: error instanceof Error ? error : new Error(String(error))
|
|
77
|
+
};
|
|
78
|
+
this.notify();
|
|
79
|
+
} finally {
|
|
80
|
+
this.isAnalyzing = false;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
notify() {
|
|
84
|
+
for (const listener of this.listeners) {
|
|
85
|
+
listener();
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
export function useUnusedFieldAnalysis(monitorStore, updateIntervalMs = 2000) {
|
|
90
|
+
const storeRef = React.useRef(null);
|
|
91
|
+
if (storeRef.current == null) {
|
|
92
|
+
storeRef.current = new AnalysisStore(monitorStore, updateIntervalMs);
|
|
93
|
+
}
|
|
94
|
+
const store = storeRef.current;
|
|
95
|
+
const subscribe = React.useCallback(callback => store.subscribe(callback), [store]);
|
|
96
|
+
const getSnapshot = React.useCallback(() => store.getSnapshot(), [store]);
|
|
97
|
+
return React.useSyncExternalStore(subscribe, getSnapshot);
|
|
98
|
+
}
|
|
99
|
+
//# sourceMappingURL=useUnusedFieldAnalysis.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useUnusedFieldAnalysis.js","names":["React","UnusedFieldAnalyzer","AnalysisStore","state","report","isLoading","error","listeners","Set","isAnalyzing","constructor","monitorStore","updateIntervalMs","subscribe","callback","add","size","setTimeout","analyze","intervalId","setInterval","delete","undefined","clearInterval","getSnapshot","notify","registry","getComponentRegistry","propertyTracker","getPropertyAccessTracker","cacheSnapshot","getCacheSnapshot","analyzer","generateGlobalReport","Error","String","listener","useUnusedFieldAnalysis","storeRef","useRef","current","store","useCallback","useSyncExternalStore"],"sources":["useUnusedFieldAnalysis.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from \"react\";\nimport type { MonitorStore } from \"../store/MonitorStore.js\";\nimport {\n UnusedFieldAnalyzer,\n type UnusedFieldReport,\n} from \"../utils/UnusedFieldAnalyzer.js\";\n\nexport interface UnusedFieldAnalysisState {\n report: UnusedFieldReport | null;\n isLoading: boolean;\n error: Error | null;\n}\n\nclass AnalysisStore {\n private state: UnusedFieldAnalysisState = {\n report: null,\n isLoading: true,\n error: null,\n };\n private listeners = new Set<() => void>();\n private intervalId: ReturnType<typeof setInterval> | undefined;\n private isAnalyzing = false;\n\n constructor(\n private readonly monitorStore: MonitorStore,\n private readonly updateIntervalMs: number,\n ) {}\n\n subscribe(callback: () => void): () => void {\n this.listeners.add(callback);\n\n if (this.listeners.size === 1) {\n setTimeout(() => void this.analyze(), 0);\n this.intervalId = setInterval(() => {\n void this.analyze();\n }, this.updateIntervalMs);\n }\n\n return () => {\n this.listeners.delete(callback);\n if (this.listeners.size === 0 && this.intervalId !== undefined) {\n clearInterval(this.intervalId);\n this.intervalId = undefined;\n }\n };\n }\n\n getSnapshot(): UnusedFieldAnalysisState {\n return this.state;\n }\n\n private async analyze(): Promise<void> {\n if (this.isAnalyzing) {\n return;\n }\n this.isAnalyzing = true;\n\n try {\n this.state = { ...this.state, isLoading: true };\n this.notify();\n\n const registry = this.monitorStore.getComponentRegistry();\n const propertyTracker = this.monitorStore.getPropertyAccessTracker();\n const cacheSnapshot = await this.monitorStore.getCacheSnapshot();\n\n const analyzer = new UnusedFieldAnalyzer(\n registry,\n propertyTracker,\n );\n\n const report = analyzer.generateGlobalReport(cacheSnapshot);\n\n this.state = {\n report,\n isLoading: false,\n error: null,\n };\n this.notify();\n } catch (error) {\n this.state = {\n report: null,\n isLoading: false,\n error: error instanceof Error ? error : new Error(String(error)),\n };\n this.notify();\n } finally {\n this.isAnalyzing = false;\n }\n }\n\n private notify(): void {\n for (const listener of this.listeners) {\n listener();\n }\n }\n}\n\nexport function useUnusedFieldAnalysis(\n monitorStore: MonitorStore,\n updateIntervalMs: number = 2000,\n): UnusedFieldAnalysisState {\n const storeRef = React.useRef<AnalysisStore | null>(null);\n\n if (\n storeRef.current == null\n ) {\n storeRef.current = new AnalysisStore(monitorStore, updateIntervalMs);\n }\n\n const store = storeRef.current;\n\n const subscribe = React.useCallback(\n (callback: () => void) => store.subscribe(callback),\n [store],\n );\n\n const getSnapshot = React.useCallback(\n () => store.getSnapshot(),\n [store],\n );\n\n return React.useSyncExternalStore(subscribe, getSnapshot);\n}\n"],"mappings":"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,gBAAwB,GAAG,IAAI,EACL;EAC1B,MAAM0B,QAAQ,GAAGtC,KAAK,CAACuC,MAAM,CAAuB,IAAI,CAAC;EAEzD,IACED,QAAQ,CAACE,OAAO,IAAI,IAAI,EACxB;IACAF,QAAQ,CAACE,OAAO,GAAG,IAAItC,aAAa,CAACS,YAAY,EAAEC,gBAAgB,CAAC;EACtE;EAEA,MAAM6B,KAAK,GAAGH,QAAQ,CAACE,OAAO;EAE9B,MAAM3B,SAAS,GAAGb,KAAK,CAAC0C,WAAW,CAChC5B,QAAoB,IAAK2B,KAAK,CAAC5B,SAAS,CAACC,QAAQ,CAAC,EACnD,CAAC2B,KAAK,CACR,CAAC;EAED,MAAMjB,WAAW,GAAGxB,KAAK,CAAC0C,WAAW,CACnC,MAAMD,KAAK,CAACjB,WAAW,CAAC,CAAC,EACzB,CAACiB,KAAK,CACR,CAAC;EAED,OAAOzC,KAAK,CAAC2C,oBAAoB,CAAC9B,SAAS,EAAEW,WAAW,CAAC;AAC3D","ignoreList":[]}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Palantir Technologies, Inc. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import "./register.js";
|
|
18
|
+
import "./styles.js";
|
|
19
|
+
export { BubbleChart } from "./components/BubbleChart.js";
|
|
20
|
+
export { MonitorErrorBoundary } from "./components/MonitorErrorBoundary.js";
|
|
21
|
+
export { MonitoringPanel, SafeMonitoringPanel } from "./components/MonitoringPanel.js";
|
|
22
|
+
export { OsdkAppErrorBoundary } from "./components/OsdkAppErrorBoundary.js";
|
|
23
|
+
export { OsdkDevTools } from "./components/OsdkDevTools.js";
|
|
24
|
+
export { useComputeMetrics, useComputeRecording, useComputeRequests } from "./hooks/useComputeSelectors.js";
|
|
25
|
+
export { useMetrics } from "./hooks/useMetrics.js";
|
|
26
|
+
export { usePersistedState } from "./hooks/usePersistedState.js";
|
|
27
|
+
export { ComputeStore } from "./store/ComputeStore.js";
|
|
28
|
+
export { MonitorStore } from "./store/MonitorStore.js";
|
|
29
|
+
export { componentContextCapture } from "./utils/ComponentContextCapture.js";
|
|
30
|
+
export { ComputeMonitor } from "./utils/ComputeMonitor.js";
|
|
31
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["BubbleChart","MonitorErrorBoundary","MonitoringPanel","SafeMonitoringPanel","OsdkAppErrorBoundary","OsdkDevTools","useComputeMetrics","useComputeRecording","useComputeRequests","useMetrics","usePersistedState","ComputeStore","MonitorStore","componentContextCapture","ComputeMonitor"],"sources":["index.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport \"./register.js\";\nimport \"./styles.js\";\n\nexport { BubbleChart } from \"./components/BubbleChart.js\";\nexport { MonitorErrorBoundary } from \"./components/MonitorErrorBoundary.js\";\nexport type { MonitorErrorBoundaryProps } from \"./components/MonitorErrorBoundary.js\";\nexport {\n MonitoringPanel,\n SafeMonitoringPanel,\n} from \"./components/MonitoringPanel.js\";\nexport type { MonitoringPanelProps } from \"./components/MonitoringPanel.js\";\nexport { OsdkAppErrorBoundary } from \"./components/OsdkAppErrorBoundary.js\";\nexport type { OsdkAppErrorBoundaryProps } from \"./components/OsdkAppErrorBoundary.js\";\nexport { OsdkDevTools } from \"./components/OsdkDevTools.js\";\n\nexport {\n useComputeMetrics,\n useComputeRecording,\n useComputeRequests,\n} from \"./hooks/useComputeSelectors.js\";\nexport { useMetrics } from \"./hooks/useMetrics.js\";\nexport { usePersistedState } from \"./hooks/usePersistedState.js\";\n\nexport type { Fiber } from \"./fiber/types.js\";\nexport { ComputeStore } from \"./store/ComputeStore.js\";\nexport { MonitorStore } from \"./store/MonitorStore.js\";\nexport { componentContextCapture } from \"./utils/ComponentContextCapture.js\";\nexport type {\n ComponentContext,\n ComponentContextCapture,\n} from \"./utils/ComponentContextCapture.js\";\nexport type { ComponentQueryRegistry } from \"./utils/ComponentQueryRegistry.js\";\nexport { ComputeMonitor } from \"./utils/ComputeMonitor.js\";\n\nexport type {\n AggregateMetrics,\n MetricRates,\n MetricsSnapshot,\n Operation,\n OperationMetadata,\n OperationType,\n PanelPosition,\n TimeSeriesData,\n} from \"./types/index.js\";\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAO,eAAe;AACtB,OAAO,aAAa;AAEpB,SAASA,WAAW,QAAQ,6BAA6B;AACzD,SAASC,oBAAoB,QAAQ,sCAAsC;AAE3E,SACEC,eAAe,EACfC,mBAAmB,QACd,iCAAiC;AAExC,SAASC,oBAAoB,QAAQ,sCAAsC;AAE3E,SAASC,YAAY,QAAQ,8BAA8B;AAE3D,SACEC,iBAAiB,EACjBC,mBAAmB,EACnBC,kBAAkB,QACb,gCAAgC;AACvC,SAASC,UAAU,QAAQ,uBAAuB;AAClD,SAASC,iBAAiB,QAAQ,8BAA8B;AAGhE,SAASC,YAAY,QAAQ,yBAAyB;AACtD,SAASC,YAAY,QAAQ,yBAAyB;AACtD,SAASC,uBAAuB,QAAQ,oCAAoC;AAM5E,SAASC,cAAc,QAAQ,2BAA2B","ignoreList":[]}
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2025 Palantir Technologies, Inc. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import React from "react";
|
|
18
|
+
import { createRoot } from "react-dom/client";
|
|
19
|
+
import { InspectorBanner } from "./components/InspectorBanner.js";
|
|
20
|
+
import { InspectorOverlay } from "./components/InspectorOverlay.js";
|
|
21
|
+
import { createInspectorController } from "./inspectorController.js";
|
|
22
|
+
export class ClickToInspectSystem {
|
|
23
|
+
state = {
|
|
24
|
+
active: false,
|
|
25
|
+
hoveredElement: null,
|
|
26
|
+
hoveredComponentId: null,
|
|
27
|
+
selectedComponentId: null
|
|
28
|
+
};
|
|
29
|
+
inspectorController = null;
|
|
30
|
+
bannerContainer = null;
|
|
31
|
+
bannerRoot = null;
|
|
32
|
+
overlayContainer = null;
|
|
33
|
+
overlayRoot = null;
|
|
34
|
+
stateUnsubscribe = null;
|
|
35
|
+
eventHandlers = new Map();
|
|
36
|
+
constructor(options = {}) {
|
|
37
|
+
this.options = options;
|
|
38
|
+
this.setupKeyboardShortcuts();
|
|
39
|
+
}
|
|
40
|
+
activate() {
|
|
41
|
+
if (this.state.active) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
this.state.active = true;
|
|
45
|
+
this.inspectorController = createInspectorController({
|
|
46
|
+
containerElement: this.options.containerElement,
|
|
47
|
+
eventHandlers: {
|
|
48
|
+
onActivate: () => {
|
|
49
|
+
this.options.onActivate?.();
|
|
50
|
+
},
|
|
51
|
+
onDeactivate: () => {
|
|
52
|
+
this.deactivate();
|
|
53
|
+
},
|
|
54
|
+
onSelect: component => {
|
|
55
|
+
this.handleComponentSelected(component);
|
|
56
|
+
},
|
|
57
|
+
onHover: component => {
|
|
58
|
+
if (component) {
|
|
59
|
+
this.state.hoveredComponentId = component.name;
|
|
60
|
+
} else {
|
|
61
|
+
this.state.hoveredComponentId = null;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
this.inspectorController.activate();
|
|
67
|
+
this.showOverlay();
|
|
68
|
+
this.showBanner();
|
|
69
|
+
this.setCursor("crosshair");
|
|
70
|
+
}
|
|
71
|
+
showOverlay() {
|
|
72
|
+
const renderTarget = this.options.renderTarget ?? document.body;
|
|
73
|
+
if (!this.overlayContainer) {
|
|
74
|
+
this.overlayContainer = document.createElement("div");
|
|
75
|
+
this.overlayContainer.id = "osdk-inspector-overlay";
|
|
76
|
+
this.overlayContainer.setAttribute("data-osdk-devtools-ignore", "");
|
|
77
|
+
renderTarget.appendChild(this.overlayContainer);
|
|
78
|
+
this.overlayRoot = createRoot(this.overlayContainer);
|
|
79
|
+
}
|
|
80
|
+
if (this.inspectorController) {
|
|
81
|
+
this.stateUnsubscribe = this.inspectorController.subscribe(controllerState => {
|
|
82
|
+
this.renderOverlay(controllerState);
|
|
83
|
+
});
|
|
84
|
+
this.renderOverlay(this.inspectorController.getState());
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
renderOverlay(controllerState) {
|
|
88
|
+
if (!this.overlayRoot) {
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
this.overlayRoot.render(/*#__PURE__*/React.createElement(InspectorOverlay, {
|
|
92
|
+
state: controllerState
|
|
93
|
+
}));
|
|
94
|
+
}
|
|
95
|
+
hideOverlay() {
|
|
96
|
+
if (this.stateUnsubscribe) {
|
|
97
|
+
this.stateUnsubscribe();
|
|
98
|
+
this.stateUnsubscribe = null;
|
|
99
|
+
}
|
|
100
|
+
if (this.overlayRoot) {
|
|
101
|
+
this.overlayRoot.render(/*#__PURE__*/React.createElement(InspectorOverlay, {
|
|
102
|
+
state: {
|
|
103
|
+
mode: "inactive",
|
|
104
|
+
mouseX: -9999,
|
|
105
|
+
mouseY: -9999,
|
|
106
|
+
hoveredElement: null,
|
|
107
|
+
selectedElement: null,
|
|
108
|
+
frozenElement: null,
|
|
109
|
+
inspectedComponent: null,
|
|
110
|
+
selectionBounds: null,
|
|
111
|
+
labelPosition: null,
|
|
112
|
+
labelStatus: "idle",
|
|
113
|
+
viewportVersion: 0
|
|
114
|
+
}
|
|
115
|
+
}));
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
showBanner() {
|
|
119
|
+
const renderTarget = this.options.renderTarget ?? document.body;
|
|
120
|
+
if (!this.bannerContainer) {
|
|
121
|
+
this.bannerContainer = document.createElement("div");
|
|
122
|
+
this.bannerContainer.id = "osdk-inspector-banner";
|
|
123
|
+
renderTarget.appendChild(this.bannerContainer);
|
|
124
|
+
this.bannerRoot = createRoot(this.bannerContainer);
|
|
125
|
+
}
|
|
126
|
+
this.bannerRoot?.render(/*#__PURE__*/React.createElement(InspectorBanner, {
|
|
127
|
+
visible: true
|
|
128
|
+
}));
|
|
129
|
+
}
|
|
130
|
+
hideBanner() {
|
|
131
|
+
if (this.bannerRoot) {
|
|
132
|
+
this.bannerRoot.render(/*#__PURE__*/React.createElement(InspectorBanner, {
|
|
133
|
+
visible: false
|
|
134
|
+
}));
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
handleComponentSelected(component) {
|
|
138
|
+
this.state.selectedComponentId = component.name;
|
|
139
|
+
this.options.onSelect?.(component);
|
|
140
|
+
this.deactivate();
|
|
141
|
+
}
|
|
142
|
+
deactivate() {
|
|
143
|
+
if (!this.state.active) {
|
|
144
|
+
return;
|
|
145
|
+
}
|
|
146
|
+
this.state.active = false;
|
|
147
|
+
this.hideOverlay();
|
|
148
|
+
if (this.inspectorController) {
|
|
149
|
+
this.inspectorController.destroy();
|
|
150
|
+
this.inspectorController = null;
|
|
151
|
+
}
|
|
152
|
+
this.hideBanner();
|
|
153
|
+
this.setCursor("default");
|
|
154
|
+
this.clearHover();
|
|
155
|
+
this.options.onDeactivate?.();
|
|
156
|
+
}
|
|
157
|
+
toggle() {
|
|
158
|
+
if (this.state.active) {
|
|
159
|
+
this.deactivate();
|
|
160
|
+
} else {
|
|
161
|
+
this.activate();
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
setupKeyboardShortcuts() {
|
|
165
|
+
const existing = this.eventHandlers.get("keydown-global");
|
|
166
|
+
if (existing) {
|
|
167
|
+
window.removeEventListener(existing.eventType, existing.handler, true);
|
|
168
|
+
this.eventHandlers.delete("keydown-global");
|
|
169
|
+
}
|
|
170
|
+
const handler = e => {
|
|
171
|
+
const keyEvent = e;
|
|
172
|
+
if ((keyEvent.ctrlKey || keyEvent.metaKey) && keyEvent.shiftKey && keyEvent.key === "C") {
|
|
173
|
+
keyEvent.preventDefault();
|
|
174
|
+
keyEvent.stopPropagation();
|
|
175
|
+
this.toggle();
|
|
176
|
+
}
|
|
177
|
+
if (keyEvent.key === "Escape" && this.state.active) {
|
|
178
|
+
keyEvent.preventDefault();
|
|
179
|
+
keyEvent.stopPropagation();
|
|
180
|
+
this.deactivate();
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
window.addEventListener("keydown", handler, true);
|
|
184
|
+
this.eventHandlers.set("keydown-global", {
|
|
185
|
+
eventType: "keydown",
|
|
186
|
+
handler
|
|
187
|
+
});
|
|
188
|
+
}
|
|
189
|
+
clearHover() {
|
|
190
|
+
this.state.hoveredElement = null;
|
|
191
|
+
this.state.hoveredComponentId = null;
|
|
192
|
+
}
|
|
193
|
+
setCursor(cursor) {
|
|
194
|
+
document.body.style.cursor = cursor;
|
|
195
|
+
}
|
|
196
|
+
dispose() {
|
|
197
|
+
this.deactivate();
|
|
198
|
+
for (const {
|
|
199
|
+
eventType,
|
|
200
|
+
handler
|
|
201
|
+
} of this.eventHandlers.values()) {
|
|
202
|
+
window.removeEventListener(eventType, handler, true);
|
|
203
|
+
}
|
|
204
|
+
this.eventHandlers.clear();
|
|
205
|
+
if (this.bannerRoot) {
|
|
206
|
+
this.bannerRoot.unmount();
|
|
207
|
+
this.bannerRoot = null;
|
|
208
|
+
}
|
|
209
|
+
if (this.bannerContainer) {
|
|
210
|
+
this.bannerContainer.remove();
|
|
211
|
+
this.bannerContainer = null;
|
|
212
|
+
}
|
|
213
|
+
if (this.overlayRoot) {
|
|
214
|
+
this.overlayRoot.unmount();
|
|
215
|
+
this.overlayRoot = null;
|
|
216
|
+
}
|
|
217
|
+
if (this.overlayContainer) {
|
|
218
|
+
this.overlayContainer.remove();
|
|
219
|
+
this.overlayContainer = null;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
getState() {
|
|
223
|
+
return {
|
|
224
|
+
...this.state
|
|
225
|
+
};
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
//# sourceMappingURL=ClickToInspectSystem.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ClickToInspectSystem.js","names":["React","createRoot","InspectorBanner","InspectorOverlay","createInspectorController","ClickToInspectSystem","state","active","hoveredElement","hoveredComponentId","selectedComponentId","inspectorController","bannerContainer","bannerRoot","overlayContainer","overlayRoot","stateUnsubscribe","eventHandlers","Map","constructor","options","setupKeyboardShortcuts","activate","containerElement","onActivate","onDeactivate","deactivate","onSelect","component","handleComponentSelected","onHover","name","showOverlay","showBanner","setCursor","renderTarget","document","body","createElement","id","setAttribute","appendChild","subscribe","controllerState","renderOverlay","getState","render","hideOverlay","mode","mouseX","mouseY","selectedElement","frozenElement","inspectedComponent","selectionBounds","labelPosition","labelStatus","viewportVersion","visible","hideBanner","destroy","clearHover","toggle","existing","get","window","removeEventListener","eventType","handler","delete","e","keyEvent","ctrlKey","metaKey","shiftKey","key","preventDefault","stopPropagation","addEventListener","set","cursor","style","dispose","values","clear","unmount","remove"],"sources":["ClickToInspectSystem.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from \"react\";\nimport { createRoot, type Root } from \"react-dom/client\";\nimport { InspectorBanner } from \"./components/InspectorBanner.js\";\nimport { InspectorOverlay } from \"./components/InspectorOverlay.js\";\nimport { createInspectorController } from \"./inspectorController.js\";\nimport type {\n InspectedComponent,\n InspectorController,\n InspectorState as InspectorControllerState,\n} from \"./types.js\";\n\nexport interface ClickToInspectOptions {\n containerElement?: HTMLElement;\n renderTarget?: HTMLElement;\n onSelect?: (component: InspectedComponent) => void;\n onActivate?: () => void;\n onDeactivate?: () => void;\n}\n\nexport interface InspectorState {\n active: boolean;\n hoveredElement: HTMLElement | null;\n hoveredComponentId: string | null;\n selectedComponentId: string | null;\n}\n\nexport class ClickToInspectSystem {\n private state: InspectorState = {\n active: false,\n hoveredElement: null,\n hoveredComponentId: null,\n selectedComponentId: null,\n };\n\n private readonly options: ClickToInspectOptions;\n private inspectorController: InspectorController | null = null;\n private bannerContainer: HTMLDivElement | null = null;\n private bannerRoot: Root | null = null;\n private overlayContainer: HTMLDivElement | null = null;\n private overlayRoot: Root | null = null;\n private stateUnsubscribe: (() => void) | null = null;\n private eventHandlers: Map<\n string,\n { eventType: string; handler: EventListener }\n > = new Map();\n\n constructor(options: ClickToInspectOptions = {}) {\n this.options = options;\n this.setupKeyboardShortcuts();\n }\n\n activate(): void {\n if (this.state.active) {\n return;\n }\n\n this.state.active = true;\n\n this.inspectorController = createInspectorController({\n containerElement: this.options.containerElement,\n eventHandlers: {\n onActivate: () => {\n this.options.onActivate?.();\n },\n onDeactivate: () => {\n this.deactivate();\n },\n onSelect: (component: InspectedComponent) => {\n this.handleComponentSelected(component);\n },\n onHover: (component: InspectedComponent | null) => {\n if (component) {\n this.state.hoveredComponentId = component.name;\n } else {\n this.state.hoveredComponentId = null;\n }\n },\n },\n });\n\n this.inspectorController.activate();\n\n this.showOverlay();\n this.showBanner();\n this.setCursor(\"crosshair\");\n }\n\n private showOverlay(): void {\n const renderTarget = this.options.renderTarget ?? document.body;\n\n if (!this.overlayContainer) {\n this.overlayContainer = document.createElement(\"div\");\n this.overlayContainer.id = \"osdk-inspector-overlay\";\n this.overlayContainer.setAttribute(\"data-osdk-devtools-ignore\", \"\");\n renderTarget.appendChild(this.overlayContainer);\n this.overlayRoot = createRoot(this.overlayContainer);\n }\n\n if (this.inspectorController) {\n this.stateUnsubscribe = this.inspectorController.subscribe(\n (controllerState) => {\n this.renderOverlay(controllerState);\n },\n );\n\n this.renderOverlay(this.inspectorController.getState());\n }\n }\n\n private renderOverlay(controllerState: InspectorControllerState): void {\n if (!this.overlayRoot) {\n return;\n }\n\n this.overlayRoot.render(\n React.createElement(InspectorOverlay, {\n state: controllerState,\n }),\n );\n }\n\n private hideOverlay(): void {\n if (this.stateUnsubscribe) {\n this.stateUnsubscribe();\n this.stateUnsubscribe = null;\n }\n\n if (this.overlayRoot) {\n this.overlayRoot.render(\n React.createElement(InspectorOverlay, {\n state: {\n mode: \"inactive\",\n mouseX: -9999,\n mouseY: -9999,\n hoveredElement: null,\n selectedElement: null,\n frozenElement: null,\n inspectedComponent: null,\n selectionBounds: null,\n labelPosition: null,\n labelStatus: \"idle\",\n viewportVersion: 0,\n },\n }),\n );\n }\n }\n\n private showBanner(): void {\n const renderTarget = this.options.renderTarget ?? document.body;\n\n if (!this.bannerContainer) {\n this.bannerContainer = document.createElement(\"div\");\n this.bannerContainer.id = \"osdk-inspector-banner\";\n renderTarget.appendChild(this.bannerContainer);\n this.bannerRoot = createRoot(this.bannerContainer);\n }\n\n this.bannerRoot?.render(\n React.createElement(InspectorBanner, { visible: true }),\n );\n }\n\n private hideBanner(): void {\n if (this.bannerRoot) {\n this.bannerRoot.render(\n React.createElement(InspectorBanner, { visible: false }),\n );\n }\n }\n\n private handleComponentSelected(component: InspectedComponent): void {\n this.state.selectedComponentId = component.name;\n this.options.onSelect?.(component);\n this.deactivate();\n }\n\n deactivate(): void {\n if (!this.state.active) {\n return;\n }\n\n this.state.active = false;\n\n this.hideOverlay();\n\n if (this.inspectorController) {\n this.inspectorController.destroy();\n this.inspectorController = null;\n }\n\n this.hideBanner();\n this.setCursor(\"default\");\n this.clearHover();\n\n this.options.onDeactivate?.();\n }\n\n toggle(): void {\n if (this.state.active) {\n this.deactivate();\n } else {\n this.activate();\n }\n }\n\n private setupKeyboardShortcuts(): void {\n const existing = this.eventHandlers.get(\"keydown-global\");\n if (existing) {\n window.removeEventListener(existing.eventType, existing.handler, true);\n this.eventHandlers.delete(\"keydown-global\");\n }\n\n const handler = (e: Event) => {\n const keyEvent = e as KeyboardEvent;\n\n if (\n (keyEvent.ctrlKey || keyEvent.metaKey) && keyEvent.shiftKey\n && keyEvent.key === \"C\"\n ) {\n keyEvent.preventDefault();\n keyEvent.stopPropagation();\n this.toggle();\n }\n\n if (keyEvent.key === \"Escape\" && this.state.active) {\n keyEvent.preventDefault();\n keyEvent.stopPropagation();\n this.deactivate();\n }\n };\n\n window.addEventListener(\"keydown\", handler, true);\n this.eventHandlers.set(\"keydown-global\", { eventType: \"keydown\", handler });\n }\n\n private clearHover(): void {\n this.state.hoveredElement = null;\n this.state.hoveredComponentId = null;\n }\n\n private setCursor(cursor: string): void {\n document.body.style.cursor = cursor;\n }\n\n dispose(): void {\n this.deactivate();\n\n for (const { eventType, handler } of this.eventHandlers.values()) {\n window.removeEventListener(eventType, handler, true);\n }\n this.eventHandlers.clear();\n\n if (this.bannerRoot) {\n this.bannerRoot.unmount();\n this.bannerRoot = null;\n }\n if (this.bannerContainer) {\n this.bannerContainer.remove();\n this.bannerContainer = null;\n }\n\n if (this.overlayRoot) {\n this.overlayRoot.unmount();\n this.overlayRoot = null;\n }\n if (this.overlayContainer) {\n this.overlayContainer.remove();\n this.overlayContainer = null;\n }\n }\n\n getState(): InspectorState {\n return { ...this.state };\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,QAAmB,kBAAkB;AACxD,SAASC,eAAe,QAAQ,iCAAiC;AACjE,SAASC,gBAAgB,QAAQ,kCAAkC;AACnE,SAASC,yBAAyB,QAAQ,0BAA0B;AAsBpE,OAAO,MAAMC,oBAAoB,CAAC;EACxBC,KAAK,GAAmB;IAC9BC,MAAM,EAAE,KAAK;IACbC,cAAc,EAAE,IAAI;IACpBC,kBAAkB,EAAE,IAAI;IACxBC,mBAAmB,EAAE;EACvB,CAAC;EAGOC,mBAAmB,GAA+B,IAAI;EACtDC,eAAe,GAA0B,IAAI;EAC7CC,UAAU,GAAgB,IAAI;EAC9BC,gBAAgB,GAA0B,IAAI;EAC9CC,WAAW,GAAgB,IAAI;EAC/BC,gBAAgB,GAAwB,IAAI;EAC5CC,aAAa,GAGjB,IAAIC,GAAG,CAAC,CAAC;EAEbC,WAAWA,CAACC,OAA8B,GAAG,CAAC,CAAC,EAAE;IAC/C,IAAI,CAACA,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