@automovie/viewer 0.3.4 → 0.4.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/README.md +8 -87
- package/lib/IAutoMovieViewerCompletedFrame.d.ts +19 -11
- package/lib/IAutoMovieViewerDisplayMetadata.d.ts +0 -5
- package/lib/IAutoMovieViewerHandle.d.ts +3 -25
- package/lib/IMountViewerOptions.d.ts +24 -38
- package/lib/IViewerCameraStateSnapshot.d.ts +0 -5
- package/lib/IViewerFrameTransfer.d.ts +11 -0
- package/lib/IViewerFrameTransfer.js +3 -0
- package/lib/IViewerFrameTransfer.js.map +1 -0
- package/lib/IViewerFrameTransfer.mjs +0 -0
- package/lib/applyCaptureCanvasSize.d.ts +9 -10
- package/lib/applyCaptureCanvasSize.js +7 -13
- package/lib/applyCaptureCanvasSize.js.map +1 -1
- package/lib/applyCaptureCanvasSize.mjs +7 -10
- package/lib/applyCaptureCanvasSize.mjs.map +1 -1
- package/lib/audio/IAutoMovieAudioCue.d.ts +3 -8
- package/lib/audio/planAutoMovieAudioPlayback.d.ts +8 -21
- package/lib/audio/planAutoMovieAudioPlayback.js +8 -14
- package/lib/audio/planAutoMovieAudioPlayback.js.map +1 -1
- package/lib/audio/planAutoMovieAudioPlayback.mjs +8 -14
- package/lib/audio/planAutoMovieAudioPlayback.mjs.map +1 -1
- package/lib/audio/playAutoMovieAudioCues.d.ts +4 -11
- package/lib/audio/playAutoMovieAudioCues.js +4 -11
- package/lib/audio/playAutoMovieAudioCues.js.map +1 -1
- package/lib/audio/playAutoMovieAudioCues.mjs +4 -11
- package/lib/audio/playAutoMovieAudioCues.mjs.map +1 -1
- package/lib/createViewerCameraState.d.ts +3 -11
- package/lib/createViewerCameraState.js +80 -121
- package/lib/createViewerCameraState.js.map +1 -1
- package/lib/createViewerCameraState.mjs +46 -98
- package/lib/createViewerCameraState.mjs.map +1 -1
- package/lib/createViewerDisplayClock.d.ts +2 -10
- package/lib/createViewerDisplayClock.js +4 -12
- package/lib/createViewerDisplayClock.js.map +1 -1
- package/lib/createViewerDisplayClock.mjs +3 -11
- package/lib/createViewerDisplayClock.mjs.map +1 -1
- package/lib/createViewerDisplayPublication.d.ts +7 -15
- package/lib/createViewerDisplayPublication.js +7 -15
- package/lib/createViewerDisplayPublication.js.map +1 -1
- package/lib/createViewerDisplayPublication.mjs +7 -15
- package/lib/createViewerDisplayPublication.mjs.map +1 -1
- package/lib/createViewerDisplaySave.d.ts +8 -16
- package/lib/createViewerDisplaySave.js +8 -16
- package/lib/createViewerDisplaySave.js.map +1 -1
- package/lib/createViewerDisplaySave.mjs +8 -16
- package/lib/createViewerDisplaySave.mjs.map +1 -1
- package/lib/createViewerFrameControl.d.ts +8 -10
- package/lib/createViewerFrameControl.js +3 -15
- package/lib/createViewerFrameControl.js.map +1 -1
- package/lib/createViewerFrameControl.mjs +3 -12
- package/lib/createViewerFrameControl.mjs.map +1 -1
- package/lib/createViewerViewportResize.d.ts +4 -12
- package/lib/createViewerViewportResize.js +7 -20
- package/lib/createViewerViewportResize.js.map +1 -1
- package/lib/createViewerViewportResize.mjs +6 -14
- package/lib/createViewerViewportResize.mjs.map +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +6 -1
- package/lib/inspector/AutoMovieInspector.d.ts +33 -13
- package/lib/inspector/AutoMovieInspector.js +110 -19
- package/lib/inspector/AutoMovieInspector.js.map +1 -1
- package/lib/inspector/AutoMovieInspector.mjs +121 -18
- package/lib/inspector/AutoMovieInspector.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorBeauty.d.ts +41 -0
- package/lib/inspector/AutoMovieInspectorBeauty.js +56 -0
- package/lib/inspector/AutoMovieInspectorBeauty.js.map +1 -0
- package/lib/inspector/AutoMovieInspectorBeauty.mjs +55 -0
- package/lib/inspector/AutoMovieInspectorBeauty.mjs.map +1 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticLog.d.ts +48 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticLog.js +186 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticLog.js.map +1 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticLog.mjs +171 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticLog.mjs.map +1 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticsPanel.d.ts +23 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticsPanel.js +37 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticsPanel.js.map +1 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticsPanel.mjs +85 -0
- package/lib/inspector/AutoMovieInspectorDiagnosticsPanel.mjs.map +1 -0
- package/lib/inspector/AutoMovieInspectorMarksPanel.d.ts +4 -10
- package/lib/inspector/AutoMovieInspectorMarksPanel.js +18 -35
- package/lib/inspector/AutoMovieInspectorMarksPanel.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorMarksPanel.mjs +32 -38
- package/lib/inspector/AutoMovieInspectorMarksPanel.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorPlayhead.d.ts +35 -96
- package/lib/inspector/AutoMovieInspectorPlayhead.js +41 -101
- package/lib/inspector/AutoMovieInspectorPlayhead.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorPlayhead.mjs +44 -98
- package/lib/inspector/AutoMovieInspectorPlayhead.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorRequestPanel.d.ts +9 -10
- package/lib/inspector/AutoMovieInspectorRequestPanel.js +18 -12
- package/lib/inspector/AutoMovieInspectorRequestPanel.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorRequestPanel.mjs +32 -14
- package/lib/inspector/AutoMovieInspectorRequestPanel.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorSelectionPanel.d.ts +0 -8
- package/lib/inspector/AutoMovieInspectorSelectionPanel.js +0 -8
- package/lib/inspector/AutoMovieInspectorSelectionPanel.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorSelectionPanel.mjs +0 -8
- package/lib/inspector/AutoMovieInspectorSelectionPanel.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorShadePanel.d.ts +2 -9
- package/lib/inspector/AutoMovieInspectorShadePanel.js +18 -25
- package/lib/inspector/AutoMovieInspectorShadePanel.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorShadePanel.mjs +18 -27
- package/lib/inspector/AutoMovieInspectorShadePanel.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorTimePanel.d.ts +0 -8
- package/lib/inspector/AutoMovieInspectorTimePanel.js +0 -8
- package/lib/inspector/AutoMovieInspectorTimePanel.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorTimePanel.mjs +0 -8
- package/lib/inspector/AutoMovieInspectorTimePanel.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorTimeReadout.d.ts +0 -8
- package/lib/inspector/AutoMovieInspectorTimeReadout.js +4 -10
- package/lib/inspector/AutoMovieInspectorTimeReadout.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorTimeReadout.mjs +3 -12
- package/lib/inspector/AutoMovieInspectorTimeReadout.mjs.map +1 -1
- package/lib/inspector/AutoMovieInspectorTransition.d.ts +79 -0
- package/lib/inspector/AutoMovieInspectorTransition.js +131 -0
- package/lib/inspector/AutoMovieInspectorTransition.js.map +1 -0
- package/lib/inspector/AutoMovieInspectorTransition.mjs +119 -0
- package/lib/inspector/AutoMovieInspectorTransition.mjs.map +1 -0
- package/lib/inspector/AutoMovieInspectorViewPanel.d.ts +0 -8
- package/lib/inspector/AutoMovieInspectorViewPanel.js +0 -8
- package/lib/inspector/AutoMovieInspectorViewPanel.js.map +1 -1
- package/lib/inspector/AutoMovieInspectorViewPanel.mjs +0 -8
- package/lib/inspector/AutoMovieInspectorViewPanel.mjs.map +1 -1
- package/lib/inspector/IAutoMovieInspectorAction.d.ts +54 -95
- package/lib/inspector/IAutoMovieInspectorLive.d.ts +43 -0
- package/lib/inspector/IAutoMovieInspectorLive.js +3 -0
- package/lib/inspector/IAutoMovieInspectorLive.js.map +1 -0
- package/lib/inspector/IAutoMovieInspectorLive.mjs +0 -0
- package/lib/inspector/IAutoMovieInspectorPathNode.d.ts +14 -9
- package/lib/inspector/IAutoMovieInspectorProps.d.ts +3 -14
- package/lib/inspector/IAutoMovieInspectorScene.d.ts +96 -100
- package/lib/inspector/IAutoMovieInspectorSceneHost.d.ts +37 -102
- package/lib/inspector/IAutoMovieInspectorState.d.ts +6 -7
- package/lib/inspector/assertAutoMovieInspectorRaster.d.ts +7 -0
- package/lib/inspector/assertAutoMovieInspectorRaster.js +19 -0
- package/lib/inspector/assertAutoMovieInspectorRaster.js.map +1 -0
- package/lib/inspector/assertAutoMovieInspectorRaster.mjs +17 -0
- package/lib/inspector/assertAutoMovieInspectorRaster.mjs.map +1 -0
- package/lib/inspector/buildAutoMovieInspectorPathTree.d.ts +9 -10
- package/lib/inspector/buildAutoMovieInspectorPathTree.js +9 -10
- package/lib/inspector/buildAutoMovieInspectorPathTree.js.map +1 -1
- package/lib/inspector/buildAutoMovieInspectorPathTree.mjs +9 -10
- package/lib/inspector/buildAutoMovieInspectorPathTree.mjs.map +1 -1
- package/lib/inspector/changesAutoMovieObservedScene.d.ts +16 -0
- package/lib/inspector/changesAutoMovieObservedScene.js +28 -0
- package/lib/inspector/changesAutoMovieObservedScene.js.map +1 -0
- package/lib/inspector/changesAutoMovieObservedScene.mjs +21 -0
- package/lib/inspector/changesAutoMovieObservedScene.mjs.map +1 -0
- package/lib/inspector/createAutoMovieInspectorAddressWriter.d.ts +13 -11
- package/lib/inspector/createAutoMovieInspectorAddressWriter.js +13 -11
- package/lib/inspector/createAutoMovieInspectorAddressWriter.js.map +1 -1
- package/lib/inspector/createAutoMovieInspectorAddressWriter.mjs +13 -11
- package/lib/inspector/createAutoMovieInspectorAddressWriter.mjs.map +1 -1
- package/lib/inspector/createAutoMovieInspectorCanvasHost.d.ts +7 -10
- package/lib/inspector/createAutoMovieInspectorCanvasHost.js +14 -11
- package/lib/inspector/createAutoMovieInspectorCanvasHost.js.map +1 -1
- package/lib/inspector/createAutoMovieInspectorCanvasHost.mjs +17 -14
- package/lib/inspector/createAutoMovieInspectorCanvasHost.mjs.map +1 -1
- package/lib/inspector/createAutoMovieInspectorState.d.ts +3 -9
- package/lib/inspector/createAutoMovieInspectorState.js +3 -9
- package/lib/inspector/createAutoMovieInspectorState.js.map +1 -1
- package/lib/inspector/createAutoMovieInspectorState.mjs +3 -9
- package/lib/inspector/createAutoMovieInspectorState.mjs.map +1 -1
- package/lib/inspector/firstAutoMovieInspectorSecond.d.ts +6 -0
- package/lib/inspector/firstAutoMovieInspectorSecond.js +13 -0
- package/lib/inspector/firstAutoMovieInspectorSecond.js.map +1 -0
- package/lib/inspector/firstAutoMovieInspectorSecond.mjs +11 -0
- package/lib/inspector/firstAutoMovieInspectorSecond.mjs.map +1 -0
- package/lib/inspector/followAutoMovieInspectorSize.d.ts +11 -0
- package/lib/inspector/followAutoMovieInspectorSize.js +26 -0
- package/lib/inspector/followAutoMovieInspectorSize.js.map +1 -0
- package/lib/inspector/followAutoMovieInspectorSize.mjs +26 -0
- package/lib/inspector/followAutoMovieInspectorSize.mjs.map +1 -0
- package/lib/inspector/formatAutoMovieInspectorAddress.d.ts +11 -10
- package/lib/inspector/formatAutoMovieInspectorAddress.js +15 -11
- package/lib/inspector/formatAutoMovieInspectorAddress.js.map +1 -1
- package/lib/inspector/formatAutoMovieInspectorAddress.mjs +15 -11
- package/lib/inspector/formatAutoMovieInspectorAddress.mjs.map +1 -1
- package/lib/inspector/formatAutoMovieInspectorCommand.d.ts +20 -14
- package/lib/inspector/formatAutoMovieInspectorCommand.js +33 -14
- package/lib/inspector/formatAutoMovieInspectorCommand.js.map +1 -1
- package/lib/inspector/formatAutoMovieInspectorCommand.mjs +26 -15
- package/lib/inspector/formatAutoMovieInspectorCommand.mjs.map +1 -1
- package/lib/inspector/handleAutoMovieInspectorKey.d.ts +24 -15
- package/lib/inspector/handleAutoMovieInspectorKey.js +27 -16
- package/lib/inspector/handleAutoMovieInspectorKey.js.map +1 -1
- package/lib/inspector/handleAutoMovieInspectorKey.mjs +27 -16
- package/lib/inspector/handleAutoMovieInspectorKey.mjs.map +1 -1
- package/lib/inspector/index.d.ts +5 -0
- package/lib/inspector/index.js +5 -0
- package/lib/inspector/index.js.map +1 -1
- package/lib/inspector/index.mjs +6 -1
- package/lib/inspector/inspectAutoMovieInspectorRequest.d.ts +19 -0
- package/lib/inspector/inspectAutoMovieInspectorRequest.js +20 -0
- package/lib/inspector/inspectAutoMovieInspectorRequest.js.map +1 -0
- package/lib/inspector/inspectAutoMovieInspectorRequest.mjs +20 -0
- package/lib/inspector/inspectAutoMovieInspectorRequest.mjs.map +1 -0
- package/lib/inspector/installAutoMovieInspectorRequest.d.ts +20 -0
- package/lib/inspector/installAutoMovieInspectorRequest.js +36 -0
- package/lib/inspector/installAutoMovieInspectorRequest.js.map +1 -0
- package/lib/inspector/installAutoMovieInspectorRequest.mjs +35 -0
- package/lib/inspector/installAutoMovieInspectorRequest.mjs.map +1 -0
- package/lib/inspector/locateAutoMovieInspectorFinding.d.ts +19 -0
- package/lib/inspector/locateAutoMovieInspectorFinding.js +34 -0
- package/lib/inspector/locateAutoMovieInspectorFinding.js.map +1 -0
- package/lib/inspector/locateAutoMovieInspectorFinding.mjs +37 -0
- package/lib/inspector/locateAutoMovieInspectorFinding.mjs.map +1 -0
- package/lib/inspector/messageOfAutoMovieInspectorError.d.ts +2 -0
- package/lib/inspector/messageOfAutoMovieInspectorError.js +8 -0
- package/lib/inspector/messageOfAutoMovieInspectorError.js.map +1 -0
- package/lib/inspector/messageOfAutoMovieInspectorError.mjs +8 -0
- package/lib/inspector/messageOfAutoMovieInspectorError.mjs.map +1 -0
- package/lib/inspector/mountAutoMovieInspectorPage.d.ts +5 -8
- package/lib/inspector/mountAutoMovieInspectorPage.js +3 -9
- package/lib/inspector/mountAutoMovieInspectorPage.js.map +1 -1
- package/lib/inspector/mountAutoMovieInspectorPage.mjs +4 -9
- package/lib/inspector/mountAutoMovieInspectorPage.mjs.map +1 -1
- package/lib/inspector/mountAutoMovieInspectorScene.d.ts +55 -12
- package/lib/inspector/mountAutoMovieInspectorScene.js +238 -164
- package/lib/inspector/mountAutoMovieInspectorScene.js.map +1 -1
- package/lib/inspector/mountAutoMovieInspectorScene.mjs +223 -149
- package/lib/inspector/mountAutoMovieInspectorScene.mjs.map +1 -1
- package/lib/inspector/placeAutoMovieInspectorLabels.d.ts +29 -0
- package/lib/inspector/placeAutoMovieInspectorLabels.js +33 -0
- package/lib/inspector/placeAutoMovieInspectorLabels.js.map +1 -0
- package/lib/inspector/placeAutoMovieInspectorLabels.mjs +32 -0
- package/lib/inspector/placeAutoMovieInspectorLabels.mjs.map +1 -0
- package/lib/inspector/readAutoMovieInspectorAddress.d.ts +8 -11
- package/lib/inspector/readAutoMovieInspectorAddress.js +8 -11
- package/lib/inspector/readAutoMovieInspectorAddress.js.map +1 -1
- package/lib/inspector/readAutoMovieInspectorAddress.mjs +8 -11
- package/lib/inspector/readAutoMovieInspectorAddress.mjs.map +1 -1
- package/lib/inspector/readAutoMovieInspectorFacts.d.ts +17 -0
- package/lib/inspector/readAutoMovieInspectorFacts.js +34 -0
- package/lib/inspector/readAutoMovieInspectorFacts.js.map +1 -0
- package/lib/inspector/readAutoMovieInspectorFacts.mjs +28 -0
- package/lib/inspector/readAutoMovieInspectorFacts.mjs.map +1 -0
- package/lib/inspector/readsAutoMovieInspectorPlacedScene.d.ts +9 -0
- package/lib/inspector/readsAutoMovieInspectorPlacedScene.js +14 -0
- package/lib/inspector/readsAutoMovieInspectorPlacedScene.js.map +1 -0
- package/lib/inspector/readsAutoMovieInspectorPlacedScene.mjs +14 -0
- package/lib/inspector/readsAutoMovieInspectorPlacedScene.mjs.map +1 -0
- package/lib/inspector/reduceAutoMovieInspectorState.d.ts +10 -10
- package/lib/inspector/reduceAutoMovieInspectorState.js +17 -11
- package/lib/inspector/reduceAutoMovieInspectorState.js.map +1 -1
- package/lib/inspector/reduceAutoMovieInspectorState.mjs +16 -11
- package/lib/inspector/reduceAutoMovieInspectorState.mjs.map +1 -1
- package/lib/inspector/releaseAutoMovieInspectorSteps.d.ts +6 -0
- package/lib/inspector/releaseAutoMovieInspectorSteps.js +23 -0
- package/lib/inspector/releaseAutoMovieInspectorSteps.js.map +1 -0
- package/lib/inspector/releaseAutoMovieInspectorSteps.mjs +19 -0
- package/lib/inspector/releaseAutoMovieInspectorSteps.mjs.map +1 -0
- package/lib/inspector/reportAutoMovieInspectorLabels.d.ts +21 -0
- package/lib/inspector/reportAutoMovieInspectorLabels.js +27 -0
- package/lib/inspector/reportAutoMovieInspectorLabels.js.map +1 -0
- package/lib/inspector/reportAutoMovieInspectorLabels.mjs +30 -0
- package/lib/inspector/reportAutoMovieInspectorLabels.mjs.map +1 -0
- package/lib/inspector/resolveAutoMovieInspectorCamera.d.ts +22 -0
- package/lib/inspector/resolveAutoMovieInspectorCamera.js +34 -0
- package/lib/inspector/resolveAutoMovieInspectorCamera.js.map +1 -0
- package/lib/inspector/resolveAutoMovieInspectorCamera.mjs +34 -0
- package/lib/inspector/resolveAutoMovieInspectorCamera.mjs.map +1 -0
- package/lib/inspector/showAutoMovieInspectorFinding.d.ts +25 -0
- package/lib/inspector/showAutoMovieInspectorFinding.js +26 -0
- package/lib/inspector/showAutoMovieInspectorFinding.js.map +1 -0
- package/lib/inspector/showAutoMovieInspectorFinding.mjs +26 -0
- package/lib/inspector/showAutoMovieInspectorFinding.mjs.map +1 -0
- package/lib/inspector/stopAutoMovieInspectorTime.d.ts +11 -0
- package/lib/inspector/stopAutoMovieInspectorTime.js +17 -0
- package/lib/inspector/stopAutoMovieInspectorTime.js.map +1 -0
- package/lib/inspector/stopAutoMovieInspectorTime.mjs +18 -0
- package/lib/inspector/stopAutoMovieInspectorTime.mjs.map +1 -0
- package/lib/inspector/writeAutoMovieInspectorInspection.d.ts +6 -0
- package/lib/inspector/writeAutoMovieInspectorInspection.js +12 -0
- package/lib/inspector/writeAutoMovieInspectorInspection.js.map +1 -0
- package/lib/inspector/writeAutoMovieInspectorInspection.mjs +12 -0
- package/lib/inspector/writeAutoMovieInspectorInspection.mjs.map +1 -0
- package/lib/internal.d.ts +7 -0
- package/lib/internal.js +25 -0
- package/lib/internal.js.map +1 -0
- package/lib/internal.mjs +8 -0
- package/lib/mountViewer.d.ts +16 -10
- package/lib/mountViewer.js +17 -14
- package/lib/mountViewer.js.map +1 -1
- package/lib/mountViewer.mjs +18 -12
- package/lib/mountViewer.mjs.map +1 -1
- package/lib/publishViewerCompletedFrame.d.ts +12 -10
- package/lib/publishViewerCompletedFrame.js +11 -9
- package/lib/publishViewerCompletedFrame.js.map +1 -1
- package/lib/publishViewerCompletedFrame.mjs +11 -9
- package/lib/publishViewerCompletedFrame.mjs.map +1 -1
- package/lib/redrawViewerCompletedFrame.d.ts +2 -10
- package/lib/redrawViewerCompletedFrame.js +4 -12
- package/lib/redrawViewerCompletedFrame.js.map +1 -1
- package/lib/redrawViewerCompletedFrame.mjs +3 -11
- package/lib/redrawViewerCompletedFrame.mjs.map +1 -1
- package/lib/releaseMountedViewer.d.ts +5 -9
- package/lib/releaseMountedViewer.js +5 -9
- package/lib/releaseMountedViewer.js.map +1 -1
- package/lib/releaseMountedViewer.mjs +5 -9
- package/lib/releaseMountedViewer.mjs.map +1 -1
- package/lib/transport/AutoMovieViewerTransport.d.ts +13 -122
- package/lib/transport/AutoMovieViewerTransport.js +10 -74
- package/lib/transport/AutoMovieViewerTransport.js.map +1 -1
- package/lib/transport/AutoMovieViewerTransport.mjs +10 -65
- package/lib/transport/AutoMovieViewerTransport.mjs.map +1 -1
- package/lib/transport/readAutoMovieReviewInterval.d.ts +3 -10
- package/lib/transport/readAutoMovieReviewInterval.js +11 -16
- package/lib/transport/readAutoMovieReviewInterval.js.map +1 -1
- package/lib/transport/readAutoMovieReviewInterval.mjs +8 -14
- package/lib/transport/readAutoMovieReviewInterval.mjs.map +1 -1
- package/package.json +12 -8
- package/src/IAutoMovieViewerCompletedFrame.ts +21 -11
- package/src/IAutoMovieViewerDisplayMetadata.ts +0 -5
- package/src/IAutoMovieViewerHandle.ts +3 -25
- package/src/IMountViewerOptions.ts +24 -38
- package/src/IViewerCameraStateSnapshot.ts +0 -5
- package/src/IViewerFrameTransfer.ts +13 -0
- package/src/applyCaptureCanvasSize.ts +9 -18
- package/src/audio/IAutoMovieAudioCue.ts +3 -8
- package/src/audio/planAutoMovieAudioPlayback.ts +9 -23
- package/src/audio/playAutoMovieAudioCues.ts +4 -11
- package/src/createViewerCameraState.ts +119 -175
- package/src/createViewerDisplayClock.ts +4 -12
- package/src/createViewerDisplayPublication.ts +7 -15
- package/src/createViewerDisplaySave.ts +8 -16
- package/src/createViewerFrameControl.ts +16 -24
- package/src/createViewerViewportResize.ts +7 -23
- package/src/index.ts +1 -0
- package/src/inspector/AutoMovieInspector.tsx +183 -20
- package/src/inspector/AutoMovieInspectorBeauty.ts +89 -0
- package/src/inspector/AutoMovieInspectorDiagnosticLog.ts +235 -0
- package/src/inspector/AutoMovieInspectorDiagnosticsPanel.tsx +118 -0
- package/src/inspector/AutoMovieInspectorMarksPanel.tsx +26 -34
- package/src/inspector/AutoMovieInspectorPlayhead.ts +53 -110
- package/src/inspector/AutoMovieInspectorRequestPanel.tsx +57 -29
- package/src/inspector/AutoMovieInspectorSelectionPanel.tsx +0 -8
- package/src/inspector/AutoMovieInspectorShadePanel.tsx +24 -29
- package/src/inspector/AutoMovieInspectorTimePanel.tsx +0 -8
- package/src/inspector/AutoMovieInspectorTimeReadout.tsx +4 -10
- package/src/inspector/AutoMovieInspectorTransition.ts +178 -0
- package/src/inspector/AutoMovieInspectorViewPanel.tsx +0 -8
- package/src/inspector/IAutoMovieInspectorAction.ts +57 -94
- package/src/inspector/IAutoMovieInspectorLive.ts +62 -0
- package/src/inspector/IAutoMovieInspectorPathNode.ts +14 -9
- package/src/inspector/IAutoMovieInspectorProps.ts +4 -14
- package/src/inspector/IAutoMovieInspectorScene.ts +104 -99
- package/src/inspector/IAutoMovieInspectorSceneHost.ts +43 -102
- package/src/inspector/IAutoMovieInspectorState.ts +6 -7
- package/src/inspector/assertAutoMovieInspectorRaster.ts +23 -0
- package/src/inspector/buildAutoMovieInspectorPathTree.ts +9 -10
- package/src/inspector/changesAutoMovieObservedScene.ts +30 -0
- package/src/inspector/createAutoMovieInspectorAddressWriter.ts +13 -11
- package/src/inspector/createAutoMovieInspectorCanvasHost.ts +14 -12
- package/src/inspector/createAutoMovieInspectorState.ts +3 -9
- package/src/inspector/firstAutoMovieInspectorSecond.ts +13 -0
- package/src/inspector/followAutoMovieInspectorSize.ts +32 -0
- package/src/inspector/formatAutoMovieInspectorAddress.ts +15 -11
- package/src/inspector/formatAutoMovieInspectorCommand.ts +44 -15
- package/src/inspector/handleAutoMovieInspectorKey.ts +27 -16
- package/src/inspector/index.ts +5 -0
- package/src/inspector/inspectAutoMovieInspectorRequest.ts +37 -0
- package/src/inspector/installAutoMovieInspectorRequest.ts +50 -0
- package/src/inspector/locateAutoMovieInspectorFinding.ts +40 -0
- package/src/inspector/messageOfAutoMovieInspectorError.ts +4 -0
- package/src/inspector/mountAutoMovieInspectorPage.tsx +7 -8
- package/src/inspector/mountAutoMovieInspectorScene.ts +290 -232
- package/src/inspector/placeAutoMovieInspectorLabels.ts +53 -0
- package/src/inspector/readAutoMovieInspectorAddress.ts +8 -11
- package/src/inspector/readAutoMovieInspectorFacts.ts +50 -0
- package/src/inspector/readsAutoMovieInspectorPlacedScene.ts +16 -0
- package/src/inspector/reduceAutoMovieInspectorState.ts +17 -11
- package/src/inspector/releaseAutoMovieInspectorSteps.ts +19 -0
- package/src/inspector/reportAutoMovieInspectorLabels.ts +45 -0
- package/src/inspector/resolveAutoMovieInspectorCamera.ts +50 -0
- package/src/inspector/showAutoMovieInspectorFinding.ts +40 -0
- package/src/inspector/stopAutoMovieInspectorTime.ts +19 -0
- package/src/inspector/writeAutoMovieInspectorInspection.ts +12 -0
- package/src/internal.ts +9 -0
- package/src/mountViewer.ts +17 -14
- package/src/publishViewerCompletedFrame.ts +14 -10
- package/src/redrawViewerCompletedFrame.ts +3 -12
- package/src/releaseMountedViewer.ts +5 -9
- package/src/transport/AutoMovieViewerTransport.ts +17 -144
- package/src/transport/readAutoMovieReviewInterval.ts +15 -16
|
@@ -4,6 +4,7 @@ exports.AutoMovieInspector = AutoMovieInspector;
|
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const render_1 = require("@automovie/render");
|
|
6
6
|
const react_1 = require("react");
|
|
7
|
+
const AutoMovieInspectorDiagnosticsPanel_js_1 = require("./AutoMovieInspectorDiagnosticsPanel.js");
|
|
7
8
|
const AutoMovieInspectorMarksPanel_js_1 = require("./AutoMovieInspectorMarksPanel.js");
|
|
8
9
|
const AutoMovieInspectorPlayhead_js_1 = require("./AutoMovieInspectorPlayhead.js");
|
|
9
10
|
const AutoMovieInspectorRequestPanel_js_1 = require("./AutoMovieInspectorRequestPanel.js");
|
|
@@ -24,31 +25,51 @@ const UNLABELLED = {
|
|
|
24
25
|
dropped: 0,
|
|
25
26
|
};
|
|
26
27
|
/**
|
|
27
|
-
* The inspection page as a React component: one canvas showing a subject
|
|
28
|
+
* The inspection page as a React component: one canvas showing a subject
|
|
29
|
+
* through one request, and the panels that edit that request.
|
|
28
30
|
*
|
|
29
|
-
* The request is the component's only state that changes the picture. Every
|
|
31
|
+
* The request is the component's only state that changes the picture. Every
|
|
32
|
+
* panel dispatches an edit to `reduceAutoMovieInspectorState`, the canvas is a
|
|
33
|
+
* plain three.js scene from `@automovie/render` mounted by
|
|
34
|
+
* `mountAutoMovieInspectorScene` in an effect, and every change of the request
|
|
35
|
+
* reaches `onRequestChange` as address text, so the page keeps its address
|
|
36
|
+
* equal to the request. The playhead is an `AutoMovieInspectorPlayhead` outside
|
|
37
|
+
* React that the render loop advances, so a playing frame re-renders only the
|
|
38
|
+
* time readout, and starting or stopping also the play button.
|
|
30
39
|
*
|
|
31
|
-
* The canvas has the transport directly under it. Beside it, or under the
|
|
40
|
+
* The canvas has the transport directly under it. Beside it, or under the
|
|
41
|
+
* transport when the inspector is narrower than 900 pixels, a column holds one
|
|
42
|
+
* collapsible section per panel, each heading saying what is active: View and
|
|
43
|
+
* Shade start open, Marks, Selection and Request start closed, so a first look
|
|
44
|
+
* shows the picture and how it is drawn, and Diagnostics opens once the mount
|
|
45
|
+
* reports a confirmed error. Diagnostics keeps the newest incidents the mount
|
|
46
|
+
* reports, which the console also receives, and moves the picture to a chosen
|
|
47
|
+
* witness through an ordinary request edit; hiding its witnesses hides the
|
|
48
|
+
* cubes and the status line, not the checks. While focus is inside the
|
|
49
|
+
* inspector, the playback keys of `handleAutoMovieInspectorKey` drive the
|
|
50
|
+
* playhead, except a key held with Ctrl, Meta or Alt and a key that goes to a
|
|
51
|
+
* control answering it itself.
|
|
32
52
|
*
|
|
33
|
-
* The mount effect depends on the chosen subject object only, which
|
|
53
|
+
* The mount effect depends on the chosen subject object only, which
|
|
54
|
+
* selectAutoMovieDrawSubject picks by the request's subject key, so each
|
|
55
|
+
* subject must keep its identity across renders; the request reaches a mounted
|
|
56
|
+
* scene through its `apply`, and a request the scene refuses is set back to the
|
|
57
|
+
* one it still draws, with the reason shown. Under StrictMode the mount effect
|
|
58
|
+
* runs, cleans up and runs again on the same canvas, which the mount supports
|
|
59
|
+
* with one renderer alive at the end.
|
|
34
60
|
*
|
|
35
61
|
* ```tsx
|
|
36
62
|
* createRoot(element).render(
|
|
37
63
|
* <AutoMovieInspector
|
|
38
64
|
* subjects={subjects}
|
|
39
65
|
* initialText={location.search}
|
|
40
|
-
* onRequestChange={createAutoMovieInspectorAddressWriter({
|
|
66
|
+
* onRequestChange={createAutoMovieInspectorAddressWriter({
|
|
67
|
+
* location,
|
|
68
|
+
* history,
|
|
69
|
+
* })}
|
|
41
70
|
* />,
|
|
42
71
|
* );
|
|
43
72
|
* ```
|
|
44
|
-
*
|
|
45
|
-
* @evidence contracts/development/common.md#meaningful-documentation States what the component shows and how it is laid out, where its state lives and changes, how the address follows it, why a playing frame renders only the readout and a start or stop the play button too, the keys, the effect split and the StrictMode behaviour, and shows the mount.
|
|
46
|
-
* @evidence contracts/development/implementation.md#principled-implementation React owns layout and dispatch only: `useReducer` holds the request, `useEffect` owns the scene's lifetime per subject and forwards each request, and the canvas is drawn by three.js outside React's render, as the campaign decides against a React scene graph.
|
|
47
|
-
* @evidence contracts/development/implementation.md#clear-and-simple-structure One component composes six panels, each a function of the request and a dispatch, five of them in collapsible sections of the platform's `details` element; every state change is the reducer's and every scene change the mount's.
|
|
48
|
-
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No panel writes the scene, and a scene refusal is answered by restoring the request, never by drawing a picture the address does not name.
|
|
49
|
-
* @evidence contracts/development/implementation.md#efficient-algorithms A dispatched edit renders the panels once and re-applies the inspection only when its text changed; a playing frame renders the readout alone, and a start or stop the play button too.
|
|
50
|
-
* @evidence contracts/development/implementation.md#reuse-equivalent-work The mount, its renderer and its instance live while the subject stays; a request change reuses them.
|
|
51
|
-
* @evidence contracts/development/implementation.md#bound-retention-and-release-resources The component owns one playhead and at most one mount at a time, disposed by the effect cleanup when the subject changes or the component unmounts.
|
|
52
73
|
*/
|
|
53
74
|
function AutoMovieInspector(props) {
|
|
54
75
|
const [state, dispatch] = (0, react_1.useReducer)(reduceAutoMovieInspectorState_js_1.reduceAutoMovieInspectorState, props.initialText, createAutoMovieInspectorState_js_1.createAutoMovieInspectorState);
|
|
@@ -57,6 +78,9 @@ function AutoMovieInspector(props) {
|
|
|
57
78
|
const [legend, setLegend] = (0, react_1.useState)([]);
|
|
58
79
|
const [labels, setLabels] = (0, react_1.useState)(UNLABELLED);
|
|
59
80
|
const [failure, setFailure] = (0, react_1.useState)(null);
|
|
81
|
+
const [diagnosticMessage, setDiagnosticMessage] = (0, react_1.useState)(null);
|
|
82
|
+
const [incidents, setIncidents] = (0, react_1.useState)([]);
|
|
83
|
+
const [witnesses, setWitnesses] = (0, react_1.useState)(true);
|
|
60
84
|
const canvas = (0, react_1.useRef)(null);
|
|
61
85
|
const scene = (0, react_1.useRef)(null);
|
|
62
86
|
const { onRequestChange } = props;
|
|
@@ -87,6 +111,14 @@ function AutoMovieInspector(props) {
|
|
|
87
111
|
legend: setLegend,
|
|
88
112
|
labels: setLabels,
|
|
89
113
|
error: setFailure,
|
|
114
|
+
diagnostics: (packet) => setDiagnosticMessage(describeDiagnostics(packet)),
|
|
115
|
+
diagnosticIncident: (entry) => {
|
|
116
|
+
setIncidents((list) => [entry, ...list].slice(0, INCIDENT_LIMIT));
|
|
117
|
+
if (entry.kind === "first")
|
|
118
|
+
console.error(`AutoMovie ${describeFinding(entry.observation)}`, entry.observation);
|
|
119
|
+
else
|
|
120
|
+
console.error(`AutoMovie ${entry.episode.first.finding.paths.join(" / ")} ${entry.basis === "frames" ? "on consecutive frames" : "in painted playback samples, unchecked between them,"} from ${describeTime(entry.firstSample)} to ${describeTime(entry.episode.last)}. Worst ${entry.basis === "frames" ? "measured" : "observed"} at ${describeFinding(entry.episode.worst)}`, entry.episode);
|
|
121
|
+
},
|
|
90
122
|
refused: (drawn, message) => dispatch({ type: "restore", request: drawn, error: message }),
|
|
91
123
|
},
|
|
92
124
|
});
|
|
@@ -95,9 +127,15 @@ function AutoMovieInspector(props) {
|
|
|
95
127
|
scene.current = null;
|
|
96
128
|
setFacts(null);
|
|
97
129
|
setLabels(UNLABELLED);
|
|
130
|
+
setDiagnosticMessage(null);
|
|
131
|
+
setIncidents([]);
|
|
98
132
|
mounted.dispose();
|
|
99
133
|
};
|
|
100
134
|
}, [subject, name, playhead]);
|
|
135
|
+
// Witness visibility is a display choice the mount reads on its next frame.
|
|
136
|
+
(0, react_1.useEffect)(() => {
|
|
137
|
+
scene.current?.overlay(witnesses);
|
|
138
|
+
}, [witnesses, subject]);
|
|
101
139
|
// Every request reaches the scene and the page's address.
|
|
102
140
|
(0, react_1.useEffect)(() => {
|
|
103
141
|
scene.current?.apply(request);
|
|
@@ -123,7 +161,8 @@ function AutoMovieInspector(props) {
|
|
|
123
161
|
ctrlKey: event.ctrlKey,
|
|
124
162
|
metaKey: event.metaKey,
|
|
125
163
|
altKey: event.altKey,
|
|
126
|
-
|
|
164
|
+
// The key goes to the focused element, which is the event's target.
|
|
165
|
+
target: event.currentTarget.ownerDocument.activeElement,
|
|
127
166
|
}, playhead, facts?.fps ?? null);
|
|
128
167
|
if (!result.handled)
|
|
129
168
|
return;
|
|
@@ -155,8 +194,8 @@ function AutoMovieInspector(props) {
|
|
|
155
194
|
color: "#fff",
|
|
156
195
|
whiteSpace: "nowrap",
|
|
157
196
|
pointerEvents: "none",
|
|
158
|
-
}, children: label.text }, label.path)))] }), (0, jsx_runtime_1.jsx)(AutoMovieInspectorTimePanel_js_1.AutoMovieInspectorTimePanel, { playhead: playhead, fps: facts?.fps ?? null, dispatch: dispatch }), [unnamed, failure, state.error]
|
|
159
|
-
.
|
|
197
|
+
}, children: label.text }, label.path)))] }), witnesses && diagnosticMessage !== null && ((0, jsx_runtime_1.jsx)("p", { role: "status", style: { margin: "4px 0" }, children: diagnosticMessage })), (0, jsx_runtime_1.jsx)(AutoMovieInspectorTimePanel_js_1.AutoMovieInspectorTimePanel, { playhead: playhead, fps: facts?.fps ?? null, dispatch: dispatch }), [unnamed, failure, state.error]
|
|
198
|
+
.flatMap((message) => message === null ? [] : [message])
|
|
160
199
|
.map((message) => ((0, jsx_runtime_1.jsx)("p", { role: "alert", style: { color: "#c00", margin: "4px 0" }, children: message }, message)))] }), (0, jsx_runtime_1.jsxs)("div", { style: narrow
|
|
161
200
|
? { width: "100%" }
|
|
162
201
|
: { flex: "0 0 300px", overflowY: "auto", maxHeight: "100vh" }, children: [names.length > 1 ? ((0, jsx_runtime_1.jsxs)("label", { style: { display: "block", marginBottom: 8 }, children: ["Subject", " ", (0, jsx_runtime_1.jsxs)("select", { value: request.subject ?? "", onChange: (event) => dispatch({
|
|
@@ -164,18 +203,70 @@ function AutoMovieInspector(props) {
|
|
|
164
203
|
name: event.target.value === "" ? null : event.target.value,
|
|
165
204
|
}), children: [(0, jsx_runtime_1.jsx)("option", { value: "", children: "(choose)" }), names.map((candidate) => ((0, jsx_runtime_1.jsx)("option", { value: candidate, children: candidate }, candidate)))] })] })) : null, (0, jsx_runtime_1.jsx)(Section, { title: "View", open: true, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorViewPanel_js_1.AutoMovieInspectorViewPanel, { request: request, views: facts?.views ?? [], dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "Shade", open: true, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorShadePanel_js_1.AutoMovieInspectorShadePanel, { request: request, dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "Marks", note: inspection.marks.length === 0
|
|
166
205
|
? "none on"
|
|
167
|
-
: `${inspection.marks.length} on`, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorMarksPanel_js_1.AutoMovieInspectorMarksPanel, { request: request, marks: facts?.marks ?? [], legend: legend, dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "Selection", note: inspection.parts.length +
|
|
206
|
+
: `${inspection.marks.length} on`, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorMarksPanel_js_1.AutoMovieInspectorMarksPanel, { request: request, marks: facts?.marks ?? [], markKinds: facts?.markKinds ?? [], legend: legend, dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "Selection", note: inspection.parts.length +
|
|
168
207
|
inspection.hide.length +
|
|
169
208
|
inspection.label.length +
|
|
170
209
|
inspection.color.length ===
|
|
171
210
|
0
|
|
172
211
|
? `${facts?.paths.length ?? 0} paths`
|
|
173
|
-
: `${inspection.parts.length} selected, ${inspection.hide.length} hidden, ${inspection.label.length} labelled`, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorSelectionPanel_js_1.AutoMovieInspectorSelectionPanel, { request: request, paths: facts?.paths ?? [], dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "
|
|
212
|
+
: `${inspection.parts.length} selected, ${inspection.hide.length} hidden, ${inspection.label.length} labelled`, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorSelectionPanel_js_1.AutoMovieInspectorSelectionPanel, { request: request, paths: facts?.paths ?? [], dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "Diagnostics", open: incidents.length !== 0, note: incidents.length === 0
|
|
213
|
+
? "none reported"
|
|
214
|
+
: `${incidents.length} reported`, children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorDiagnosticsPanel_js_1.AutoMovieInspectorDiagnosticsPanel, { incidents: incidents, paths: facts?.paths ?? [], witnesses: witnesses, onWitnesses: setWitnesses, playhead: playhead, dispatch: dispatch }) }), (0, jsx_runtime_1.jsx)(Section, { title: "Request", note: props.captureCommand ? "address and capture command" : "address", children: (0, jsx_runtime_1.jsx)(AutoMovieInspectorRequestPanel_js_1.AutoMovieInspectorRequestPanel, { request: request, dispatch: dispatch, captureCommand: props.captureCommand }) })] })] }));
|
|
174
215
|
}
|
|
175
216
|
/** Below this width, in pixels, the sections move under the transport. */
|
|
176
217
|
const NARROW = 900;
|
|
177
|
-
/**
|
|
218
|
+
/**
|
|
219
|
+
* Most recent incidents the Diagnostics section keeps; the console keeps every
|
|
220
|
+
* one.
|
|
221
|
+
*/
|
|
222
|
+
const INCIDENT_LIMIT = 50;
|
|
223
|
+
/**
|
|
224
|
+
* One collapsible section of the column: a heading that says what is active,
|
|
225
|
+
* over its panel.
|
|
226
|
+
*/
|
|
178
227
|
function Section(props) {
|
|
179
228
|
return ((0, jsx_runtime_1.jsxs)("details", { open: props.open === true, style: { borderTop: "1px solid #ddd", padding: "6px 0" }, children: [(0, jsx_runtime_1.jsxs)("summary", { style: { cursor: "pointer", fontWeight: 600 }, children: [props.title, props.note === undefined ? null : ((0, jsx_runtime_1.jsxs)("span", { style: { fontWeight: "normal", color: "#666" }, children: [": ", props.note] }))] }), (0, jsx_runtime_1.jsx)("div", { style: { paddingTop: 6 }, children: props.children })] }));
|
|
180
229
|
}
|
|
230
|
+
/**
|
|
231
|
+
* Describe a sample's clock to the millisecond without inventing an output
|
|
232
|
+
* frame; the logged object keeps the exact seconds.
|
|
233
|
+
*/
|
|
234
|
+
function describeTime(time) {
|
|
235
|
+
const seconds = `${Number(time.filmSeconds.toFixed(3))} s`;
|
|
236
|
+
return time.outputFrame === undefined
|
|
237
|
+
? seconds
|
|
238
|
+
: `${seconds} (frame ${time.outputFrame})`;
|
|
239
|
+
}
|
|
240
|
+
/** Display the named parts and the checker-owned measurements of one finding. */
|
|
241
|
+
function describeFinding(observation) {
|
|
242
|
+
const { finding, time } = observation;
|
|
243
|
+
const paths = finding.paths.join(" / ");
|
|
244
|
+
const measures = (finding.witness.measurements ?? []).map((entry) => `${entry.name} ${entry.value} ${entry.unit}`);
|
|
245
|
+
return [
|
|
246
|
+
`${describeTime(time)} · ${finding.message}`,
|
|
247
|
+
...(paths === "" ? [] : [paths]),
|
|
248
|
+
...measures,
|
|
249
|
+
].join(" · ");
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* Show the strongest current finding and any limits on what this sample could
|
|
253
|
+
* check.
|
|
254
|
+
*/
|
|
255
|
+
function describeDiagnostics(packet) {
|
|
256
|
+
const strongest = packet.findings.find((finding) => finding.confidence === "confirmed" && finding.category === "error") ?? packet.findings[0];
|
|
257
|
+
const unavailable = [];
|
|
258
|
+
for (const row of packet.coverage)
|
|
259
|
+
if (row.status === "deferred" ||
|
|
260
|
+
(row.status === "unsupported" && row.required))
|
|
261
|
+
if (!unavailable.includes(row.reason))
|
|
262
|
+
unavailable.push(row.reason);
|
|
263
|
+
const messages = [];
|
|
264
|
+
if (strongest !== undefined) {
|
|
265
|
+
const status = strongest.confidence === "candidate" ? "Possible" : "Confirmed";
|
|
266
|
+
messages.push(`${status} — ${describeFinding({ finding: strongest, time: strongest.witness.time ?? packet.time })}`);
|
|
267
|
+
}
|
|
268
|
+
if (unavailable.length !== 0)
|
|
269
|
+
messages.push(`At ${describeTime(packet.time)}. Inspection incomplete · ${unavailable.join(" · ")}`);
|
|
270
|
+
return messages.length === 0 ? null : messages.join(" · ");
|
|
271
|
+
}
|
|
181
272
|
//# sourceMappingURL=AutoMovieInspector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AutoMovieInspector.js","sourceRoot":"","sources":["../../src/inspector/AutoMovieInspector.tsx"],"names":[],"mappings":";;;;AACA,8CAA2F;AAC3F,iCAYe;AAEf,uFAAiF;AACjF,mFAA6E;AAC7E,2FAAqF;AACrF,+FAAyF;AACzF,uFAAiF;AACjF,qFAA+E;AAC/E,qFAA+E;AAI/E,mGAA6F;AAC7F,yFAAmF;AACnF,6FAAuF;AACvF,qFAA+E;AAC/E,uFAAiF;AACjF,yFAAmF;AAEnF,+DAA+D;AAC/D,MAAM,UAAU,GAAqC;IACnD,MAAM,EAAE,EAAE;IACV,UAAU,EAAE,CAAC;IACb,OAAO,EAAE,CAAC;CACX,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,4BACE,KAA+B;IAE/B,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,IAAA,kBAAU,EAClC,gEAA6B,EAC7B,KAAK,CAAC,WAAW,EACjB,gEAA6B,CAC9B,CAAC;IACF,MAAM,CAAC,QAAQ,CAAC,GAAG,IAAA,gBAAQ,EACzB,GAA+B,EAAE,CAAC,IAAI,0DAA0B,EAAE,CACnE,CAAC;IACF,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,IAAA,gBAAQ,EAChC,IAAI,CACL,CAAC;IACF,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,IAAA,gBAAQ,EAAoC,EAAE,CAAC,CAAC;IAC5E,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GACvB,IAAA,gBAAQ,EAAmC,UAAU,CAAC,CAAC;IACzD,MAAM,CA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,GAAG,CAAC,MAAM,CAAC,CAAC;IACxE,MAAM,QAAQ,GAAa,EAAE,CAAC;IAC9B,IAAI,SAAS,KAAK,SAAS,EAAE,CAAC;QAC5B,MAAM,MAAM,GACV,SAAS,CAAC,UAAU,KAAK,WAAW,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,WAAW,CAAC;QAClE,QAAQ,CAAC,IAAI,CACX,GAAG,MAAM,MAAM,eAAe,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,SAAS,CAAC,OAAO,CAAC,IAAI,IAAI,MAAM,CAAC,IAAI,EAAE,CAAC,EAAE,CACtG,CAAC;IACJ,CAAC;IACD,IAAI,WAAW,CAAC,MAAM,KAAK,CAAC;QAC1B,QAAQ,CAAC,IAAI,CACX,MAAM,YAAY,CAAC,MAAM,CAAC,IAAI,CAAC,6BAA6B,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CACtF,CAAC;IACJ,OAAO,QAAQ,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAC7D,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { AutoMovieInspectorDiagnosticsPanel } from "./AutoMovieInspectorDiagnosticsPanel.mjs";
|
|
1
2
|
import { AutoMovieInspectorMarksPanel } from "./AutoMovieInspectorMarksPanel.mjs";
|
|
2
3
|
import { AutoMovieInspectorPlayhead } from "./AutoMovieInspectorPlayhead.mjs";
|
|
3
4
|
import { AutoMovieInspectorRequestPanel } from "./AutoMovieInspectorRequestPanel.mjs";
|
|
@@ -22,31 +23,51 @@ const UNLABELLED = {
|
|
|
22
23
|
dropped: 0
|
|
23
24
|
};
|
|
24
25
|
/**
|
|
25
|
-
* The inspection page as a React component: one canvas showing a subject
|
|
26
|
+
* The inspection page as a React component: one canvas showing a subject
|
|
27
|
+
* through one request, and the panels that edit that request.
|
|
26
28
|
*
|
|
27
|
-
* The request is the component's only state that changes the picture. Every
|
|
29
|
+
* The request is the component's only state that changes the picture. Every
|
|
30
|
+
* panel dispatches an edit to `reduceAutoMovieInspectorState`, the canvas is a
|
|
31
|
+
* plain three.js scene from `@automovie/render` mounted by
|
|
32
|
+
* `mountAutoMovieInspectorScene` in an effect, and every change of the request
|
|
33
|
+
* reaches `onRequestChange` as address text, so the page keeps its address
|
|
34
|
+
* equal to the request. The playhead is an `AutoMovieInspectorPlayhead` outside
|
|
35
|
+
* React that the render loop advances, so a playing frame re-renders only the
|
|
36
|
+
* time readout, and starting or stopping also the play button.
|
|
28
37
|
*
|
|
29
|
-
* The canvas has the transport directly under it. Beside it, or under the
|
|
38
|
+
* The canvas has the transport directly under it. Beside it, or under the
|
|
39
|
+
* transport when the inspector is narrower than 900 pixels, a column holds one
|
|
40
|
+
* collapsible section per panel, each heading saying what is active: View and
|
|
41
|
+
* Shade start open, Marks, Selection and Request start closed, so a first look
|
|
42
|
+
* shows the picture and how it is drawn, and Diagnostics opens once the mount
|
|
43
|
+
* reports a confirmed error. Diagnostics keeps the newest incidents the mount
|
|
44
|
+
* reports, which the console also receives, and moves the picture to a chosen
|
|
45
|
+
* witness through an ordinary request edit; hiding its witnesses hides the
|
|
46
|
+
* cubes and the status line, not the checks. While focus is inside the
|
|
47
|
+
* inspector, the playback keys of `handleAutoMovieInspectorKey` drive the
|
|
48
|
+
* playhead, except a key held with Ctrl, Meta or Alt and a key that goes to a
|
|
49
|
+
* control answering it itself.
|
|
30
50
|
*
|
|
31
|
-
* The mount effect depends on the chosen subject object only, which
|
|
51
|
+
* The mount effect depends on the chosen subject object only, which
|
|
52
|
+
* selectAutoMovieDrawSubject picks by the request's subject key, so each
|
|
53
|
+
* subject must keep its identity across renders; the request reaches a mounted
|
|
54
|
+
* scene through its `apply`, and a request the scene refuses is set back to the
|
|
55
|
+
* one it still draws, with the reason shown. Under StrictMode the mount effect
|
|
56
|
+
* runs, cleans up and runs again on the same canvas, which the mount supports
|
|
57
|
+
* with one renderer alive at the end.
|
|
32
58
|
*
|
|
33
59
|
* ```tsx
|
|
34
60
|
* createRoot(element).render(
|
|
35
61
|
* <AutoMovieInspector
|
|
36
62
|
* subjects={subjects}
|
|
37
63
|
* initialText={location.search}
|
|
38
|
-
* onRequestChange={createAutoMovieInspectorAddressWriter({
|
|
64
|
+
* onRequestChange={createAutoMovieInspectorAddressWriter({
|
|
65
|
+
* location,
|
|
66
|
+
* history,
|
|
67
|
+
* })}
|
|
39
68
|
* />,
|
|
40
69
|
* );
|
|
41
70
|
* ```
|
|
42
|
-
*
|
|
43
|
-
* @evidence contracts/development/common.md#meaningful-documentation States what the component shows and how it is laid out, where its state lives and changes, how the address follows it, why a playing frame renders only the readout and a start or stop the play button too, the keys, the effect split and the StrictMode behaviour, and shows the mount.
|
|
44
|
-
* @evidence contracts/development/implementation.md#principled-implementation React owns layout and dispatch only: `useReducer` holds the request, `useEffect` owns the scene's lifetime per subject and forwards each request, and the canvas is drawn by three.js outside React's render, as the campaign decides against a React scene graph.
|
|
45
|
-
* @evidence contracts/development/implementation.md#clear-and-simple-structure One component composes six panels, each a function of the request and a dispatch, five of them in collapsible sections of the platform's `details` element; every state change is the reducer's and every scene change the mount's.
|
|
46
|
-
* @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No panel writes the scene, and a scene refusal is answered by restoring the request, never by drawing a picture the address does not name.
|
|
47
|
-
* @evidence contracts/development/implementation.md#efficient-algorithms A dispatched edit renders the panels once and re-applies the inspection only when its text changed; a playing frame renders the readout alone, and a start or stop the play button too.
|
|
48
|
-
* @evidence contracts/development/implementation.md#reuse-equivalent-work The mount, its renderer and its instance live while the subject stays; a request change reuses them.
|
|
49
|
-
* @evidence contracts/development/implementation.md#bound-retention-and-release-resources The component owns one playhead and at most one mount at a time, disposed by the effect cleanup when the subject changes or the component unmounts.
|
|
50
71
|
*/
|
|
51
72
|
function AutoMovieInspector(props) {
|
|
52
73
|
const [state, dispatch] = useReducer(reduceAutoMovieInspectorState, props.initialText, createAutoMovieInspectorState);
|
|
@@ -55,6 +76,9 @@ function AutoMovieInspector(props) {
|
|
|
55
76
|
const [legend, setLegend] = useState([]);
|
|
56
77
|
const [labels, setLabels] = useState(UNLABELLED);
|
|
57
78
|
const [failure, setFailure] = useState(null);
|
|
79
|
+
const [diagnosticMessage, setDiagnosticMessage] = useState(null);
|
|
80
|
+
const [incidents, setIncidents] = useState([]);
|
|
81
|
+
const [witnesses, setWitnesses] = useState(true);
|
|
58
82
|
const canvas = useRef(null);
|
|
59
83
|
const scene = useRef(null);
|
|
60
84
|
const { onRequestChange } = props;
|
|
@@ -81,6 +105,12 @@ function AutoMovieInspector(props) {
|
|
|
81
105
|
legend: setLegend,
|
|
82
106
|
labels: setLabels,
|
|
83
107
|
error: setFailure,
|
|
108
|
+
diagnostics: (packet) => setDiagnosticMessage(describeDiagnostics(packet)),
|
|
109
|
+
diagnosticIncident: (entry) => {
|
|
110
|
+
setIncidents((list) => [entry, ...list].slice(0, INCIDENT_LIMIT));
|
|
111
|
+
if (entry.kind === "first") console.error(`AutoMovie ${describeFinding(entry.observation)}`, entry.observation);
|
|
112
|
+
else console.error(`AutoMovie ${entry.episode.first.finding.paths.join(" / ")} ${entry.basis === "frames" ? "on consecutive frames" : "in painted playback samples, unchecked between them,"} from ${describeTime(entry.firstSample)} to ${describeTime(entry.episode.last)}. Worst ${entry.basis === "frames" ? "measured" : "observed"} at ${describeFinding(entry.episode.worst)}`, entry.episode);
|
|
113
|
+
},
|
|
84
114
|
refused: (drawn, message) => dispatch({
|
|
85
115
|
type: "restore",
|
|
86
116
|
request: drawn,
|
|
@@ -93,6 +123,8 @@ function AutoMovieInspector(props) {
|
|
|
93
123
|
scene.current = null;
|
|
94
124
|
setFacts(null);
|
|
95
125
|
setLabels(UNLABELLED);
|
|
126
|
+
setDiagnosticMessage(null);
|
|
127
|
+
setIncidents([]);
|
|
96
128
|
mounted.dispose();
|
|
97
129
|
};
|
|
98
130
|
}, [
|
|
@@ -100,6 +132,9 @@ function AutoMovieInspector(props) {
|
|
|
100
132
|
name,
|
|
101
133
|
playhead
|
|
102
134
|
]);
|
|
135
|
+
useEffect(() => {
|
|
136
|
+
scene.current?.overlay(witnesses);
|
|
137
|
+
}, [witnesses, subject]);
|
|
103
138
|
useEffect(() => {
|
|
104
139
|
scene.current?.apply(request);
|
|
105
140
|
onRequestChange?.(formatAutoMovieInspectorAddress(request));
|
|
@@ -118,7 +153,7 @@ function AutoMovieInspector(props) {
|
|
|
118
153
|
ctrlKey: event.ctrlKey,
|
|
119
154
|
metaKey: event.metaKey,
|
|
120
155
|
altKey: event.altKey,
|
|
121
|
-
target: event.
|
|
156
|
+
target: event.currentTarget.ownerDocument.activeElement
|
|
122
157
|
}, playhead, facts?.fps ?? null);
|
|
123
158
|
if (!result.handled) return;
|
|
124
159
|
event.preventDefault();
|
|
@@ -174,6 +209,11 @@ function AutoMovieInspector(props) {
|
|
|
174
209
|
children: label.text
|
|
175
210
|
}, label.path))]
|
|
176
211
|
}),
|
|
212
|
+
witnesses && diagnosticMessage !== null && /* @__PURE__ */ jsx("p", {
|
|
213
|
+
role: "status",
|
|
214
|
+
style: { margin: "4px 0" },
|
|
215
|
+
children: diagnosticMessage
|
|
216
|
+
}),
|
|
177
217
|
/* @__PURE__ */ jsx(AutoMovieInspectorTimePanel, {
|
|
178
218
|
playhead,
|
|
179
219
|
fps: facts?.fps ?? null,
|
|
@@ -183,7 +223,7 @@ function AutoMovieInspector(props) {
|
|
|
183
223
|
unnamed,
|
|
184
224
|
failure,
|
|
185
225
|
state.error
|
|
186
|
-
].
|
|
226
|
+
].flatMap((message) => message === null ? [] : [message]).map((message) => /* @__PURE__ */ jsx("p", {
|
|
187
227
|
role: "alert",
|
|
188
228
|
style: {
|
|
189
229
|
color: "#c00",
|
|
@@ -246,6 +286,7 @@ function AutoMovieInspector(props) {
|
|
|
246
286
|
children: /* @__PURE__ */ jsx(AutoMovieInspectorMarksPanel, {
|
|
247
287
|
request,
|
|
248
288
|
marks: facts?.marks ?? [],
|
|
289
|
+
markKinds: facts?.markKinds ?? [],
|
|
249
290
|
legend,
|
|
250
291
|
dispatch
|
|
251
292
|
})
|
|
@@ -259,12 +300,26 @@ function AutoMovieInspector(props) {
|
|
|
259
300
|
dispatch
|
|
260
301
|
})
|
|
261
302
|
}),
|
|
303
|
+
/* @__PURE__ */ jsx(Section, {
|
|
304
|
+
title: "Diagnostics",
|
|
305
|
+
open: incidents.length !== 0,
|
|
306
|
+
note: incidents.length === 0 ? "none reported" : `${incidents.length} reported`,
|
|
307
|
+
children: /* @__PURE__ */ jsx(AutoMovieInspectorDiagnosticsPanel, {
|
|
308
|
+
incidents,
|
|
309
|
+
paths: facts?.paths ?? [],
|
|
310
|
+
witnesses,
|
|
311
|
+
onWitnesses: setWitnesses,
|
|
312
|
+
playhead,
|
|
313
|
+
dispatch
|
|
314
|
+
})
|
|
315
|
+
}),
|
|
262
316
|
/* @__PURE__ */ jsx(Section, {
|
|
263
317
|
title: "Request",
|
|
264
|
-
note: "address and capture command",
|
|
318
|
+
note: props.captureCommand ? "address and capture command" : "address",
|
|
265
319
|
children: /* @__PURE__ */ jsx(AutoMovieInspectorRequestPanel, {
|
|
266
320
|
request,
|
|
267
|
-
dispatch
|
|
321
|
+
dispatch,
|
|
322
|
+
captureCommand: props.captureCommand
|
|
268
323
|
})
|
|
269
324
|
})
|
|
270
325
|
]
|
|
@@ -273,7 +328,15 @@ function AutoMovieInspector(props) {
|
|
|
273
328
|
}
|
|
274
329
|
/** Below this width, in pixels, the sections move under the transport. */
|
|
275
330
|
const NARROW = 900;
|
|
276
|
-
/**
|
|
331
|
+
/**
|
|
332
|
+
* Most recent incidents the Diagnostics section keeps; the console keeps every
|
|
333
|
+
* one.
|
|
334
|
+
*/
|
|
335
|
+
const INCIDENT_LIMIT = 50;
|
|
336
|
+
/**
|
|
337
|
+
* One collapsible section of the column: a heading that says what is active,
|
|
338
|
+
* over its panel.
|
|
339
|
+
*/
|
|
277
340
|
function Section(props) {
|
|
278
341
|
return /* @__PURE__ */ jsxs("details", {
|
|
279
342
|
open: props.open === true,
|
|
@@ -299,6 +362,46 @@ function Section(props) {
|
|
|
299
362
|
})]
|
|
300
363
|
});
|
|
301
364
|
}
|
|
365
|
+
/**
|
|
366
|
+
* Describe a sample's clock to the millisecond without inventing an output
|
|
367
|
+
* frame; the logged object keeps the exact seconds.
|
|
368
|
+
*/
|
|
369
|
+
function describeTime(time) {
|
|
370
|
+
const seconds = `${Number(time.filmSeconds.toFixed(3))} s`;
|
|
371
|
+
return time.outputFrame === void 0 ? seconds : `${seconds} (frame ${time.outputFrame})`;
|
|
372
|
+
}
|
|
373
|
+
/** Display the named parts and the checker-owned measurements of one finding. */
|
|
374
|
+
function describeFinding(observation) {
|
|
375
|
+
const { finding, time } = observation;
|
|
376
|
+
const paths = finding.paths.join(" / ");
|
|
377
|
+
const measures = (finding.witness.measurements ?? []).map((entry) => `${entry.name} ${entry.value} ${entry.unit}`);
|
|
378
|
+
return [
|
|
379
|
+
`${describeTime(time)} · ${finding.message}`,
|
|
380
|
+
...paths === "" ? [] : [paths],
|
|
381
|
+
...measures
|
|
382
|
+
].join(" · ");
|
|
383
|
+
}
|
|
384
|
+
/**
|
|
385
|
+
* Show the strongest current finding and any limits on what this sample could
|
|
386
|
+
* check.
|
|
387
|
+
*/
|
|
388
|
+
function describeDiagnostics(packet) {
|
|
389
|
+
const strongest = packet.findings.find((finding) => finding.confidence === "confirmed" && finding.category === "error") ?? packet.findings[0];
|
|
390
|
+
const unavailable = [];
|
|
391
|
+
for (const row of packet.coverage) if (row.status === "deferred" || row.status === "unsupported" && row.required) {
|
|
392
|
+
if (!unavailable.includes(row.reason)) unavailable.push(row.reason);
|
|
393
|
+
}
|
|
394
|
+
const messages = [];
|
|
395
|
+
if (strongest !== void 0) {
|
|
396
|
+
const status = strongest.confidence === "candidate" ? "Possible" : "Confirmed";
|
|
397
|
+
messages.push(`${status} — ${describeFinding({
|
|
398
|
+
finding: strongest,
|
|
399
|
+
time: strongest.witness.time ?? packet.time
|
|
400
|
+
})}`);
|
|
401
|
+
}
|
|
402
|
+
if (unavailable.length !== 0) messages.push(`At ${describeTime(packet.time)}. Inspection incomplete · ${unavailable.join(" · ")}`);
|
|
403
|
+
return messages.length === 0 ? null : messages.join(" · ");
|
|
404
|
+
}
|
|
302
405
|
export { AutoMovieInspector };
|
|
303
406
|
|
|
304
407
|
//# sourceMappingURL=AutoMovieInspector.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AutoMovieInspector.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspector.tsx"],"sourcesContent":["import type { IAutoMovieInspectionLegendEntry } from \"@automovie/interface\";\nimport { type IAutoMovieDrawSubject, selectAutoMovieDrawSubject } from \"@automovie/render\";\nimport {\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type KeyboardEvent,\n type ReactNode,\n type RefObject,\n type SetStateAction,\n useEffect,\n useReducer,\n useRef,\n useState,\n} from \"react\";\n\nimport { AutoMovieInspectorMarksPanel } from \"./AutoMovieInspectorMarksPanel.js\";\nimport { AutoMovieInspectorPlayhead } from \"./AutoMovieInspectorPlayhead.js\";\nimport { AutoMovieInspectorRequestPanel } from \"./AutoMovieInspectorRequestPanel.js\";\nimport { AutoMovieInspectorSelectionPanel } from \"./AutoMovieInspectorSelectionPanel.js\";\nimport { AutoMovieInspectorShadePanel } from \"./AutoMovieInspectorShadePanel.js\";\nimport { AutoMovieInspectorTimePanel } from \"./AutoMovieInspectorTimePanel.js\";\nimport { AutoMovieInspectorViewPanel } from \"./AutoMovieInspectorViewPanel.js\";\nimport type { IAutoMovieInspectorProps } from \"./IAutoMovieInspectorProps.js\";\nimport type { IAutoMovieInspectorScene } from \"./IAutoMovieInspectorScene.js\";\nimport type { IAutoMovieInspectorState } from \"./IAutoMovieInspectorState.js\";\nimport { createAutoMovieInspectorCanvasHost } from \"./createAutoMovieInspectorCanvasHost.js\";\nimport { createAutoMovieInspectorState } from \"./createAutoMovieInspectorState.js\";\nimport { formatAutoMovieInspectorAddress } from \"./formatAutoMovieInspectorAddress.js\";\nimport { handleAutoMovieInspectorKey } from \"./handleAutoMovieInspectorKey.js\";\nimport { mountAutoMovieInspectorScene } from \"./mountAutoMovieInspectorScene.js\";\nimport { reduceAutoMovieInspectorState } from \"./reduceAutoMovieInspectorState.js\";\n\n/** No labels, the state before a paused picture places any. */\nconst UNLABELLED: IAutoMovieInspectorScene.ILabels = {\n labels: [],\n lineHeight: 0,\n dropped: 0,\n};\n\n/**\n * The inspection page as a React component: one canvas showing a subject through one request, and the panels that edit that request.\n *\n * The request is the component's only state that changes the picture. Every panel dispatches an edit to `reduceAutoMovieInspectorState`, the canvas is a plain three.js scene from `@automovie/render` mounted by `mountAutoMovieInspectorScene` in an effect, and every change of the request reaches `onRequestChange` as address text, so the page keeps its address equal to the request. The playhead is an `AutoMovieInspectorPlayhead` outside React that the render loop advances, so a playing frame re-renders only the time readout, and starting or stopping also the play button.\n *\n * The canvas has the transport directly under it. Beside it, or under the transport when the inspector is narrower than 900 pixels, a column holds one collapsible section per panel, each heading saying what is active: View and Shade start open, Marks, Selection and Request start closed, so a first look shows the picture and how it is drawn. While focus is inside the inspector, the playback keys of `handleAutoMovieInspectorKey` drive the playhead, except a key held with Ctrl, Meta or Alt and a key that goes to a control answering it itself.\n *\n * The mount effect depends on the chosen subject object only, which selectAutoMovieDrawSubject picks by the request's subject key, so each subject must keep its identity across renders; the request reaches a mounted scene through its `apply`, and a request the scene refuses is set back to the one it still draws, with the reason shown. Under StrictMode the mount effect runs, cleans up and runs again on the same canvas, which the mount supports with one renderer alive at the end.\n *\n * ```tsx\n * createRoot(element).render(\n * <AutoMovieInspector\n * subjects={subjects}\n * initialText={location.search}\n * onRequestChange={createAutoMovieInspectorAddressWriter({ location, history })}\n * />,\n * );\n * ```\n *\n * @evidence contracts/development/common.md#meaningful-documentation States what the component shows and how it is laid out, where its state lives and changes, how the address follows it, why a playing frame renders only the readout and a start or stop the play button too, the keys, the effect split and the StrictMode behaviour, and shows the mount.\n * @evidence contracts/development/implementation.md#principled-implementation React owns layout and dispatch only: `useReducer` holds the request, `useEffect` owns the scene's lifetime per subject and forwards each request, and the canvas is drawn by three.js outside React's render, as the campaign decides against a React scene graph.\n * @evidence contracts/development/implementation.md#clear-and-simple-structure One component composes six panels, each a function of the request and a dispatch, five of them in collapsible sections of the platform's `details` element; every state change is the reducer's and every scene change the mount's.\n * @evidence contracts/development/implementation.md#prohibited-implementation-shortcuts No panel writes the scene, and a scene refusal is answered by restoring the request, never by drawing a picture the address does not name.\n * @evidence contracts/development/implementation.md#efficient-algorithms A dispatched edit renders the panels once and re-applies the inspection only when its text changed; a playing frame renders the readout alone, and a start or stop the play button too.\n * @evidence contracts/development/implementation.md#reuse-equivalent-work The mount, its renderer and its instance live while the subject stays; a request change reuses them.\n * @evidence contracts/development/implementation.md#bound-retention-and-release-resources The component owns one playhead and at most one mount at a time, disposed by the effect cleanup when the subject changes or the component unmounts.\n */\nexport function AutoMovieInspector(\n props: IAutoMovieInspectorProps,\n): JSX.Element {\n const [state, dispatch] = useReducer(\n reduceAutoMovieInspectorState,\n props.initialText,\n createAutoMovieInspectorState,\n );\n const [playhead] = useState<AutoMovieInspectorPlayhead>(\n (): AutoMovieInspectorPlayhead => new AutoMovieInspectorPlayhead(),\n );\n const [facts, setFacts] = useState<IAutoMovieInspectorScene.IFacts | null>(\n null,\n );\n const [legend, setLegend] = useState<IAutoMovieInspectionLegendEntry[]>([]);\n const [labels, setLabels] =\n useState<IAutoMovieInspectorScene.ILabels>(UNLABELLED);\n const [failure, setFailure] = useState<string | null>(null);\n const canvas: RefObject<HTMLCanvasElement | null> =\n useRef<HTMLCanvasElement>(null);\n const scene: RefObject<IAutoMovieInspectorScene | null> =\n useRef<IAutoMovieInspectorScene>(null);\n const { onRequestChange } = props;\n\n // A subject the request cannot name is shown as an error, with the subject choice still offered.\n const names: string[] = Object.keys(props.subjects);\n let name: string | null = null;\n let unnamed: string | null = null;\n try {\n name = selectAutoMovieDrawSubject(names, state.request.subject);\n } catch (error) {\n unnamed = error instanceof Error ? error.message : String(error);\n }\n\n // The scene lives as long as its subject; the effect reruns only then, so the request it captures is the one in force at mount.\n const request: IAutoMovieInspectorState[\"request\"] = state.request;\n const subject: IAutoMovieDrawSubject | null =\n name === null ? null : props.subjects[name]!;\n useEffect((): (() => void) | undefined => {\n if (canvas.current === null || subject === null || name === null)\n return undefined;\n const mounted: IAutoMovieInspectorScene = mountAutoMovieInspectorScene({\n subject,\n name,\n request,\n playhead,\n host: createAutoMovieInspectorCanvasHost(canvas.current),\n report: {\n ready: setFacts,\n legend: setLegend,\n labels: setLabels,\n error: setFailure,\n refused: (\n drawn: IAutoMovieInspectorState[\"request\"],\n message: string,\n ): void =>\n dispatch({ type: \"restore\", request: drawn, error: message }),\n },\n });\n scene.current = mounted;\n return (): void => {\n scene.current = null;\n setFacts(null);\n setLabels(UNLABELLED);\n mounted.dispose();\n };\n }, [subject, name, playhead]);\n\n // Every request reaches the scene and the page's address.\n useEffect((): void => {\n scene.current?.apply(request);\n onRequestChange?.(formatAutoMovieInspectorAddress(request));\n }, [request, onRequestChange]);\n\n // The column of sections moves under the transport when the inspector is\n // too narrow for both, measured on the inspector itself, since the page's\n // width is not the component's.\n const root: RefObject<HTMLDivElement | null> = useRef<HTMLDivElement>(null);\n const [narrow, setNarrow]: [boolean, Dispatch<SetStateAction<boolean>>] =\n useState<boolean>(false);\n useEffect((): (() => void) | undefined => {\n if (root.current === null || typeof ResizeObserver === \"undefined\")\n return undefined;\n const observer: ResizeObserver = new ResizeObserver(\n (entries: ResizeObserverEntry[]): void =>\n setNarrow((entries[0]?.contentRect.width ?? NARROW) < NARROW),\n );\n observer.observe(root.current);\n return (): void => observer.disconnect();\n }, []);\n\n // The playback keys, while focus is in the inspector; the handler leaves a\n // shortcut and a key a control answers itself to the page.\n const keys: (event: KeyboardEvent<HTMLDivElement>) => void = (\n event: KeyboardEvent<HTMLDivElement>,\n ): void => {\n const result: { handled: boolean; seconds: number | null } =\n handleAutoMovieInspectorKey(\n {\n key: event.key,\n ctrlKey: event.ctrlKey,\n metaKey: event.metaKey,\n altKey: event.altKey,\n target: event.target instanceof Element ? event.target : null,\n },\n playhead,\n facts?.fps ?? null,\n );\n if (!result.handled) return;\n event.preventDefault();\n if (result.seconds !== null)\n dispatch({ type: \"time\", seconds: result.seconds });\n };\n\n const inspection: IAutoMovieInspectorState[\"request\"][\"inspection\"] =\n request.inspection;\n return (\n <div\n ref={root}\n onKeyDown={keys}\n style={{\n display: \"flex\",\n flexDirection: narrow ? \"column\" : \"row\",\n gap: 12,\n fontFamily: \"sans-serif\",\n fontSize: 13,\n }}\n >\n <div style={{ flex: \"1 1 auto\", minWidth: 0 }}>\n <div style={{ position: \"relative\" }}>\n <canvas\n ref={canvas}\n tabIndex={0}\n role=\"application\"\n aria-label=\"The inspected picture; Space or K plays or pauses, J and L seek a second, comma and full stop step a frame, Home and End go to the ends\"\n style={{\n display: \"block\",\n width: \"100%\",\n aspectRatio:\n facts === null ? \"16 / 9\" : `${facts.width} / ${facts.height}`,\n background: \"#222\",\n }}\n />\n {labels.labels.map(\n (\n label: IAutoMovieInspectorScene.ILabels[\"labels\"][number],\n ): JSX.Element => (\n <span\n key={label.path}\n style={{\n position: \"absolute\",\n left: label.left,\n top: label.top,\n height: labels.lineHeight,\n fontSize: labels.lineHeight * 0.8,\n lineHeight: `${labels.lineHeight}px`,\n fontFamily: \"monospace\",\n background: \"#000\",\n color: \"#fff\",\n whiteSpace: \"nowrap\",\n pointerEvents: \"none\",\n }}\n >\n {label.text}\n </span>\n ),\n )}\n </div>\n <AutoMovieInspectorTimePanel\n playhead={playhead}\n fps={facts?.fps ?? null}\n dispatch={dispatch}\n />\n {[unnamed, failure, state.error]\n .filter(\n (message: string | null): message is string => message !== null,\n )\n .map(\n (message: string): JSX.Element => (\n <p\n key={message}\n role=\"alert\"\n style={{ color: \"#c00\", margin: \"4px 0\" }}\n >\n {message}\n </p>\n ),\n )}\n </div>\n <div\n style={\n narrow\n ? { width: \"100%\" }\n : { flex: \"0 0 300px\", overflowY: \"auto\", maxHeight: \"100vh\" }\n }\n >\n {names.length > 1 ? (\n <label style={{ display: \"block\", marginBottom: 8 }}>\n Subject{\" \"}\n <select\n value={request.subject ?? \"\"}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void =>\n dispatch({\n type: \"subject\",\n name: event.target.value === \"\" ? null : event.target.value,\n })\n }\n >\n <option value=\"\">(choose)</option>\n {names.map(\n (candidate: string): JSX.Element => (\n <option key={candidate} value={candidate}>\n {candidate}\n </option>\n ),\n )}\n </select>\n </label>\n ) : null}\n <Section title=\"View\" open>\n <AutoMovieInspectorViewPanel\n request={request}\n views={facts?.views ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Shade\" open>\n <AutoMovieInspectorShadePanel request={request} dispatch={dispatch} />\n </Section>\n <Section\n title=\"Marks\"\n note={\n inspection.marks.length === 0\n ? \"none on\"\n : `${inspection.marks.length} on`\n }\n >\n <AutoMovieInspectorMarksPanel\n request={request}\n marks={facts?.marks ?? []}\n legend={legend}\n dispatch={dispatch}\n />\n </Section>\n <Section\n title=\"Selection\"\n note={\n inspection.parts.length +\n inspection.hide.length +\n inspection.label.length +\n inspection.color.length ===\n 0\n ? `${facts?.paths.length ?? 0} paths`\n : `${inspection.parts.length} selected, ${inspection.hide.length} hidden, ${inspection.label.length} labelled`\n }\n >\n <AutoMovieInspectorSelectionPanel\n request={request}\n paths={facts?.paths ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Request\" note=\"address and capture command\">\n <AutoMovieInspectorRequestPanel\n request={request}\n dispatch={dispatch}\n />\n </Section>\n </div>\n </div>\n );\n}\n\n/** Below this width, in pixels, the sections move under the transport. */\nconst NARROW: number = 900;\n\n/** One collapsible section of the column: a heading that says what is active, over its panel. */\nfunction Section(props: {\n title: string;\n note?: string;\n open?: boolean;\n children: ReactNode;\n}): JSX.Element {\n return (\n <details\n open={props.open === true}\n style={{ borderTop: \"1px solid #ddd\", padding: \"6px 0\" }}\n >\n <summary style={{ cursor: \"pointer\", fontWeight: 600 }}>\n {props.title}\n {props.note === undefined ? null : (\n <span style={{ fontWeight: \"normal\", color: \"#666\" }}>\n : {props.note}\n </span>\n )}\n </summary>\n <div style={{ paddingTop: 6 }}>{props.children}</div>\n </details>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAkCA,MAAM,aAA+C;CACnD,QAAQ,CAAC;CACT,YAAY;CACZ,SAAS;AACX;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,SAAgB,mBACd,OACa;CACb,MAAM,CAAC,OAAO,YAAY,WACxB,+BACA,MAAM,aACN,6BACF;CACA,MAAM,CAAC,YAAY,eACiB,IAAI,2BAA2B,CACnE;CACA,MAAM,CAAC,OAAO,YAAY,SACxB,IACF;CACA,MAAM,CAAC,QAAQ,aAAa,SAA4C,CAAC,CAAC;CAC1E,MAAM,CAAC,QAAQ,aACb,SAA2C,UAAU;CACvD,MAAM,CAAC,SAAS,cAAc,SAAwB,IAAI;CAC1D,MAAM,SACJ,OAA0B,IAAI;CAChC,MAAM,QACJ,OAAiC,IAAI;CACvC,MAAM,EAAE,oBAAoB;CAG5B,MAAM,QAAkB,OAAO,KAAK,MAAM,QAAQ;CAClD,IAAI,OAAsB;CAC1B,IAAI,UAAyB;CAC7B,IAAI;EACF,OAAO,2BAA2B,OAAO,MAAM,QAAQ,OAAO;CAChE,SAAS,OAAO;EACd,UAAU,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;CACjE;CAGA,MAAM,UAA+C,MAAM;CAC3D,MAAM,UACJ,SAAS,OAAO,OAAO,MAAM,SAAS;CACxC,gBAA0C;EACxC,IAAI,OAAO,YAAY,QAAQ,YAAY,QAAQ,SAAS,MAC1D,OAAO,KAAA;EACT,MAAM,UAAoC,6BAA6B;GACrE;GACA;GACA;GACA;GACA,MAAM,mCAAmC,O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UAAA,CAIE,qBAAC,WAAD;GAAS,OAAO;IAAE,QAAQ;IAAW,YAAY;GAAI;GAArD,UAAA,CACG,MAAM,OACN,MAAM,SAAS,KAAA,IAAY,OAC1B,qBAAC,QAAD;IAAM,OAAO;KAAE,YAAY;KAAU,OAAO;IAAO;IAAnD,UAAA,CAAsD,MACjD,MAAM,IACL;GAED,CAAA,CAAA;EACT,CAAA,GAAA,oBAAC,OAAD;GAAK,OAAO,EAAE,YAAY,EAAE;GAAI,UAAA,MAAM;EAAc,CAAA,CAC7C;;AAEb"}
|
|
1
|
+
{"version":3,"file":"AutoMovieInspector.mjs","names":[],"sources":["../../src/inspector/AutoMovieInspector.tsx"],"sourcesContent":["import type {\n IAutoMovieInspectionDiagnostics,\n IAutoMovieInspectionLegendEntry,\n} from \"@automovie/interface\";\nimport {\n type IAutoMovieDrawSubject,\n selectAutoMovieDrawSubject,\n} from \"@automovie/render\";\nimport {\n type ChangeEvent,\n type Dispatch,\n type JSX,\n type KeyboardEvent,\n type ReactNode,\n type RefObject,\n type SetStateAction,\n useEffect,\n useReducer,\n useRef,\n useState,\n} from \"react\";\n\nimport { AutoMovieInspectorDiagnosticsPanel } from \"./AutoMovieInspectorDiagnosticsPanel.js\";\nimport { AutoMovieInspectorMarksPanel } from \"./AutoMovieInspectorMarksPanel.js\";\nimport { AutoMovieInspectorPlayhead } from \"./AutoMovieInspectorPlayhead.js\";\nimport { AutoMovieInspectorRequestPanel } from \"./AutoMovieInspectorRequestPanel.js\";\nimport { AutoMovieInspectorSelectionPanel } from \"./AutoMovieInspectorSelectionPanel.js\";\nimport { AutoMovieInspectorShadePanel } from \"./AutoMovieInspectorShadePanel.js\";\nimport { AutoMovieInspectorTimePanel } from \"./AutoMovieInspectorTimePanel.js\";\nimport { AutoMovieInspectorViewPanel } from \"./AutoMovieInspectorViewPanel.js\";\nimport type { IAutoMovieInspectorProps } from \"./IAutoMovieInspectorProps.js\";\nimport type { IAutoMovieInspectorScene } from \"./IAutoMovieInspectorScene.js\";\nimport type { IAutoMovieInspectorState } from \"./IAutoMovieInspectorState.js\";\nimport { createAutoMovieInspectorCanvasHost } from \"./createAutoMovieInspectorCanvasHost.js\";\nimport { createAutoMovieInspectorState } from \"./createAutoMovieInspectorState.js\";\nimport { formatAutoMovieInspectorAddress } from \"./formatAutoMovieInspectorAddress.js\";\nimport { handleAutoMovieInspectorKey } from \"./handleAutoMovieInspectorKey.js\";\nimport { mountAutoMovieInspectorScene } from \"./mountAutoMovieInspectorScene.js\";\nimport { reduceAutoMovieInspectorState } from \"./reduceAutoMovieInspectorState.js\";\n\n/** No labels, the state before a paused picture places any. */\nconst UNLABELLED: IAutoMovieInspectorScene.ILabels = {\n labels: [],\n lineHeight: 0,\n dropped: 0,\n};\n\n/**\n * The inspection page as a React component: one canvas showing a subject\n * through one request, and the panels that edit that request.\n *\n * The request is the component's only state that changes the picture. Every\n * panel dispatches an edit to `reduceAutoMovieInspectorState`, the canvas is a\n * plain three.js scene from `@automovie/render` mounted by\n * `mountAutoMovieInspectorScene` in an effect, and every change of the request\n * reaches `onRequestChange` as address text, so the page keeps its address\n * equal to the request. The playhead is an `AutoMovieInspectorPlayhead` outside\n * React that the render loop advances, so a playing frame re-renders only the\n * time readout, and starting or stopping also the play button.\n *\n * The canvas has the transport directly under it. Beside it, or under the\n * transport when the inspector is narrower than 900 pixels, a column holds one\n * collapsible section per panel, each heading saying what is active: View and\n * Shade start open, Marks, Selection and Request start closed, so a first look\n * shows the picture and how it is drawn, and Diagnostics opens once the mount\n * reports a confirmed error. Diagnostics keeps the newest incidents the mount\n * reports, which the console also receives, and moves the picture to a chosen\n * witness through an ordinary request edit; hiding its witnesses hides the\n * cubes and the status line, not the checks. While focus is inside the\n * inspector, the playback keys of `handleAutoMovieInspectorKey` drive the\n * playhead, except a key held with Ctrl, Meta or Alt and a key that goes to a\n * control answering it itself.\n *\n * The mount effect depends on the chosen subject object only, which\n * selectAutoMovieDrawSubject picks by the request's subject key, so each\n * subject must keep its identity across renders; the request reaches a mounted\n * scene through its `apply`, and a request the scene refuses is set back to the\n * one it still draws, with the reason shown. Under StrictMode the mount effect\n * runs, cleans up and runs again on the same canvas, which the mount supports\n * with one renderer alive at the end.\n *\n * ```tsx\n * createRoot(element).render(\n * <AutoMovieInspector\n * subjects={subjects}\n * initialText={location.search}\n * onRequestChange={createAutoMovieInspectorAddressWriter({\n * location,\n * history,\n * })}\n * />,\n * );\n * ```\n */\nexport function AutoMovieInspector(\n props: IAutoMovieInspectorProps,\n): JSX.Element {\n const [state, dispatch] = useReducer(\n reduceAutoMovieInspectorState,\n props.initialText,\n createAutoMovieInspectorState,\n );\n const [playhead] = useState<AutoMovieInspectorPlayhead>(\n (): AutoMovieInspectorPlayhead => new AutoMovieInspectorPlayhead(),\n );\n const [facts, setFacts] = useState<IAutoMovieInspectorScene.IFacts | null>(\n null,\n );\n const [legend, setLegend] = useState<IAutoMovieInspectionLegendEntry[]>([]);\n const [labels, setLabels] =\n useState<IAutoMovieInspectorScene.ILabels>(UNLABELLED);\n const [failure, setFailure] = useState<string | null>(null);\n const [diagnosticMessage, setDiagnosticMessage] = useState<string | null>(\n null,\n );\n const [incidents, setIncidents] = useState<\n IAutoMovieInspectorScene.IIncident[]\n >([]);\n const [witnesses, setWitnesses] = useState<boolean>(true);\n const canvas: RefObject<HTMLCanvasElement | null> =\n useRef<HTMLCanvasElement>(null);\n const scene: RefObject<IAutoMovieInspectorScene | null> =\n useRef<IAutoMovieInspectorScene>(null);\n const { onRequestChange } = props;\n\n // A subject the request cannot name is shown as an error, with the subject choice still offered.\n const names: string[] = Object.keys(props.subjects);\n let name: string | null = null;\n let unnamed: string | null = null;\n try {\n name = selectAutoMovieDrawSubject(names, state.request.subject);\n } catch (error) {\n unnamed = error instanceof Error ? error.message : String(error);\n }\n\n // The scene lives as long as its subject; the effect reruns only then, so the request it captures is the one in force at mount.\n const request: IAutoMovieInspectorState[\"request\"] = state.request;\n const subject: IAutoMovieDrawSubject | null =\n name === null ? null : props.subjects[name]!;\n useEffect((): (() => void) | undefined => {\n if (canvas.current === null || subject === null || name === null)\n return undefined;\n const mounted: IAutoMovieInspectorScene = mountAutoMovieInspectorScene({\n subject,\n name,\n request,\n playhead,\n host: createAutoMovieInspectorCanvasHost(canvas.current),\n report: {\n ready: setFacts,\n legend: setLegend,\n labels: setLabels,\n error: setFailure,\n diagnostics: (packet: IAutoMovieInspectionDiagnostics): void =>\n setDiagnosticMessage(describeDiagnostics(packet)),\n diagnosticIncident: (\n entry: IAutoMovieInspectorScene.IIncident,\n ): void => {\n setIncidents(\n (\n list: IAutoMovieInspectorScene.IIncident[],\n ): IAutoMovieInspectorScene.IIncident[] =>\n [entry, ...list].slice(0, INCIDENT_LIMIT),\n );\n if (entry.kind === \"first\")\n console.error(\n `AutoMovie ${describeFinding(entry.observation)}`,\n entry.observation,\n );\n else\n console.error(\n `AutoMovie ${entry.episode.first.finding.paths.join(\" / \")} ${entry.basis === \"frames\" ? \"on consecutive frames\" : \"in painted playback samples, unchecked between them,\"} from ${describeTime(entry.firstSample)} to ${describeTime(entry.episode.last)}. Worst ${entry.basis === \"frames\" ? \"measured\" : \"observed\"} at ${describeFinding(entry.episode.worst)}`,\n entry.episode,\n );\n },\n refused: (\n drawn: IAutoMovieInspectorState[\"request\"],\n message: string,\n ): void =>\n dispatch({ type: \"restore\", request: drawn, error: message }),\n },\n });\n scene.current = mounted;\n return (): void => {\n scene.current = null;\n setFacts(null);\n setLabels(UNLABELLED);\n setDiagnosticMessage(null);\n setIncidents([]);\n mounted.dispose();\n };\n }, [subject, name, playhead]);\n\n // Witness visibility is a display choice the mount reads on its next frame.\n useEffect((): void => {\n scene.current?.overlay(witnesses);\n }, [witnesses, subject]);\n\n // Every request reaches the scene and the page's address.\n useEffect((): void => {\n scene.current?.apply(request);\n onRequestChange?.(formatAutoMovieInspectorAddress(request));\n }, [request, onRequestChange]);\n\n // The column of sections moves under the transport when the inspector is\n // too narrow for both, measured on the inspector itself, since the page's\n // width is not the component's.\n const root: RefObject<HTMLDivElement | null> = useRef<HTMLDivElement>(null);\n const [narrow, setNarrow]: [boolean, Dispatch<SetStateAction<boolean>>] =\n useState<boolean>(false);\n useEffect((): (() => void) | undefined => {\n if (root.current === null || typeof ResizeObserver === \"undefined\")\n return undefined;\n const observer: ResizeObserver = new ResizeObserver(\n (entries: ResizeObserverEntry[]): void =>\n setNarrow((entries[0]?.contentRect.width ?? NARROW) < NARROW),\n );\n observer.observe(root.current);\n return (): void => observer.disconnect();\n }, []);\n\n // The playback keys, while focus is in the inspector; the handler leaves a\n // shortcut and a key a control answers itself to the page.\n const keys: (event: KeyboardEvent<HTMLDivElement>) => void = (\n event: KeyboardEvent<HTMLDivElement>,\n ): void => {\n const result: { handled: boolean; seconds: number | null } =\n handleAutoMovieInspectorKey(\n {\n key: event.key,\n ctrlKey: event.ctrlKey,\n metaKey: event.metaKey,\n altKey: event.altKey,\n // The key goes to the focused element, which is the event's target.\n target: event.currentTarget.ownerDocument.activeElement,\n },\n playhead,\n facts?.fps ?? null,\n );\n if (!result.handled) return;\n event.preventDefault();\n if (result.seconds !== null)\n dispatch({ type: \"time\", seconds: result.seconds });\n };\n\n const inspection: IAutoMovieInspectorState[\"request\"][\"inspection\"] =\n request.inspection;\n return (\n <div\n ref={root}\n onKeyDown={keys}\n style={{\n display: \"flex\",\n flexDirection: narrow ? \"column\" : \"row\",\n gap: 12,\n fontFamily: \"sans-serif\",\n fontSize: 13,\n }}\n >\n <div style={{ flex: \"1 1 auto\", minWidth: 0 }}>\n <div style={{ position: \"relative\" }}>\n <canvas\n ref={canvas}\n tabIndex={0}\n role=\"application\"\n aria-label=\"The inspected picture; Space or K plays or pauses, J and L seek a second, comma and full stop step a frame, Home and End go to the ends\"\n style={{\n display: \"block\",\n width: \"100%\",\n aspectRatio:\n facts === null ? \"16 / 9\" : `${facts.width} / ${facts.height}`,\n background: \"#222\",\n }}\n />\n {labels.labels.map(\n (\n label: IAutoMovieInspectorScene.ILabels[\"labels\"][number],\n ): JSX.Element => (\n <span\n key={label.path}\n style={{\n position: \"absolute\",\n left: label.left,\n top: label.top,\n height: labels.lineHeight,\n fontSize: labels.lineHeight * 0.8,\n lineHeight: `${labels.lineHeight}px`,\n fontFamily: \"monospace\",\n background: \"#000\",\n color: \"#fff\",\n whiteSpace: \"nowrap\",\n pointerEvents: \"none\",\n }}\n >\n {label.text}\n </span>\n ),\n )}\n </div>\n {witnesses && diagnosticMessage !== null && (\n <p role=\"status\" style={{ margin: \"4px 0\" }}>\n {diagnosticMessage}\n </p>\n )}\n <AutoMovieInspectorTimePanel\n playhead={playhead}\n fps={facts?.fps ?? null}\n dispatch={dispatch}\n />\n {[unnamed, failure, state.error]\n .flatMap((message: string | null): string[] =>\n message === null ? [] : [message],\n )\n .map(\n (message: string): JSX.Element => (\n <p\n key={message}\n role=\"alert\"\n style={{ color: \"#c00\", margin: \"4px 0\" }}\n >\n {message}\n </p>\n ),\n )}\n </div>\n <div\n style={\n narrow\n ? { width: \"100%\" }\n : { flex: \"0 0 300px\", overflowY: \"auto\", maxHeight: \"100vh\" }\n }\n >\n {names.length > 1 ? (\n <label style={{ display: \"block\", marginBottom: 8 }}>\n Subject{\" \"}\n <select\n value={request.subject ?? \"\"}\n onChange={(event: ChangeEvent<HTMLSelectElement>): void =>\n dispatch({\n type: \"subject\",\n name: event.target.value === \"\" ? null : event.target.value,\n })\n }\n >\n <option value=\"\">(choose)</option>\n {names.map(\n (candidate: string): JSX.Element => (\n <option key={candidate} value={candidate}>\n {candidate}\n </option>\n ),\n )}\n </select>\n </label>\n ) : null}\n <Section title=\"View\" open>\n <AutoMovieInspectorViewPanel\n request={request}\n views={facts?.views ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section title=\"Shade\" open>\n <AutoMovieInspectorShadePanel request={request} dispatch={dispatch} />\n </Section>\n <Section\n title=\"Marks\"\n note={\n inspection.marks.length === 0\n ? \"none on\"\n : `${inspection.marks.length} on`\n }\n >\n <AutoMovieInspectorMarksPanel\n request={request}\n marks={facts?.marks ?? []}\n markKinds={facts?.markKinds ?? []}\n legend={legend}\n dispatch={dispatch}\n />\n </Section>\n <Section\n title=\"Selection\"\n note={\n inspection.parts.length +\n inspection.hide.length +\n inspection.label.length +\n inspection.color.length ===\n 0\n ? `${facts?.paths.length ?? 0} paths`\n : `${inspection.parts.length} selected, ${inspection.hide.length} hidden, ${inspection.label.length} labelled`\n }\n >\n <AutoMovieInspectorSelectionPanel\n request={request}\n paths={facts?.paths ?? []}\n dispatch={dispatch}\n />\n </Section>\n <Section\n title=\"Diagnostics\"\n open={incidents.length !== 0}\n note={\n incidents.length === 0\n ? \"none reported\"\n : `${incidents.length} reported`\n }\n >\n <AutoMovieInspectorDiagnosticsPanel\n incidents={incidents}\n paths={facts?.paths ?? []}\n witnesses={witnesses}\n onWitnesses={setWitnesses}\n playhead={playhead}\n dispatch={dispatch}\n />\n </Section>\n <Section\n title=\"Request\"\n note={props.captureCommand ? \"address and capture command\" : \"address\"}\n >\n <AutoMovieInspectorRequestPanel\n request={request}\n dispatch={dispatch}\n captureCommand={props.captureCommand}\n />\n </Section>\n </div>\n </div>\n );\n}\n\n/** Below this width, in pixels, the sections move under the transport. */\nconst NARROW: number = 900;\n\n/**\n * Most recent incidents the Diagnostics section keeps; the console keeps every\n * one.\n */\nconst INCIDENT_LIMIT: number = 50;\n\n/**\n * One collapsible section of the column: a heading that says what is active,\n * over its panel.\n */\nfunction Section(props: {\n title: string;\n note?: string;\n open?: boolean;\n children: ReactNode;\n}): JSX.Element {\n return (\n <details\n open={props.open === true}\n style={{ borderTop: \"1px solid #ddd\", padding: \"6px 0\" }}\n >\n <summary style={{ cursor: \"pointer\", fontWeight: 600 }}>\n {props.title}\n {props.note === undefined ? null : (\n <span style={{ fontWeight: \"normal\", color: \"#666\" }}>\n : {props.note}\n </span>\n )}\n </summary>\n <div style={{ paddingTop: 6 }}>{props.children}</div>\n </details>\n );\n}\n\n/**\n * Describe a sample's clock to the millisecond without inventing an output\n * frame; the logged object keeps the exact seconds.\n */\nfunction describeTime(time: IAutoMovieInspectionDiagnostics.ITime): string {\n const seconds: string = `${Number(time.filmSeconds.toFixed(3))} s`;\n return time.outputFrame === undefined\n ? seconds\n : `${seconds} (frame ${time.outputFrame})`;\n}\n\n/** Display the named parts and the checker-owned measurements of one finding. */\nfunction describeFinding(\n observation: IAutoMovieInspectionDiagnostics.IObservation,\n): string {\n const { finding, time } = observation;\n const paths: string = finding.paths.join(\" / \");\n const measures: string[] = (finding.witness.measurements ?? []).map(\n (entry: IAutoMovieInspectionDiagnostics.IMeasurement): string =>\n `${entry.name} ${entry.value} ${entry.unit}`,\n );\n return [\n `${describeTime(time)} · ${finding.message}`,\n ...(paths === \"\" ? [] : [paths]),\n ...measures,\n ].join(\" · \");\n}\n\n/**\n * Show the strongest current finding and any limits on what this sample could\n * check.\n */\nfunction describeDiagnostics(\n packet: IAutoMovieInspectionDiagnostics,\n): string | null {\n const strongest: IAutoMovieInspectionDiagnostics.IFinding | undefined =\n packet.findings.find(\n (finding: IAutoMovieInspectionDiagnostics.IFinding): boolean =>\n finding.confidence === \"confirmed\" && finding.category === \"error\",\n ) ?? packet.findings[0];\n const unavailable: string[] = [];\n for (const row of packet.coverage)\n if (\n row.status === \"deferred\" ||\n (row.status === \"unsupported\" && row.required)\n )\n if (!unavailable.includes(row.reason)) unavailable.push(row.reason);\n const messages: string[] = [];\n if (strongest !== undefined) {\n const status: string =\n strongest.confidence === \"candidate\" ? \"Possible\" : \"Confirmed\";\n messages.push(\n `${status} — ${describeFinding({ finding: strongest, time: strongest.witness.time ?? packet.time })}`,\n );\n }\n if (unavailable.length !== 0)\n messages.push(\n `At ${describeTime(packet.time)}. Inspection incomplete · ${unavailable.join(\" · \")}`,\n );\n return messages.length === 0 ? null : messages.join(\" · \");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAyCA,MAAM,aAA+C;CACnD,QAAQ,CAAC;CACT,YAAY;CACZ,SAAS;AACX;;;;;;;;;;;;;;;;;;;;;;;;;;;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