4runr-os 2.1.4 → 2.1.6
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/dist/index.js +16 -1
- package/dist/index.js.map +1 -1
- package/dist/tui_mk1/kernel.d.ts.map +1 -1
- package/dist/tui_mk1/kernel.js +107 -4
- package/dist/tui_mk1/kernel.js.map +1 -1
- package/dist/tui_mk1/layout/layoutEngine.d.ts +38 -19
- package/dist/tui_mk1/layout/layoutEngine.d.ts.map +1 -1
- package/dist/tui_mk1/layout/layoutEngine.js +521 -228
- package/dist/tui_mk1/layout/layoutEngine.js.map +1 -1
- package/dist/tui_mk1/log.d.ts +23 -0
- package/dist/tui_mk1/log.d.ts.map +1 -0
- package/dist/tui_mk1/log.js +125 -0
- package/dist/tui_mk1/log.js.map +1 -0
- package/dist/tui_mk1/logger.d.ts.map +1 -1
- package/dist/tui_mk1/logger.js +20 -10
- package/dist/tui_mk1/logger.js.map +1 -1
- package/dist/tui_mk1/mk1App.d.ts +13 -18
- package/dist/tui_mk1/mk1App.d.ts.map +1 -1
- package/dist/tui_mk1/mk1App.js +334 -157
- package/dist/tui_mk1/mk1App.js.map +1 -1
- package/dist/tui_mk1/resizeController.d.ts.map +1 -1
- package/dist/tui_mk1/resizeController.js +15 -1
- package/dist/tui_mk1/resizeController.js.map +1 -1
- package/dist/tui_mk1/stdoutGuard.d.ts.map +1 -1
- package/dist/tui_mk1/stdoutGuard.js +7 -0
- package/dist/tui_mk1/stdoutGuard.js.map +1 -1
- package/dist/tui_mk1/terminalRestore.d.ts.map +1 -1
- package/dist/tui_mk1/terminalRestore.js +19 -1
- package/dist/tui_mk1/terminalRestore.js.map +1 -1
- package/dist/tui_mk1/ui/offenderScanner.d.ts +31 -0
- package/dist/tui_mk1/ui/offenderScanner.d.ts.map +1 -0
- package/dist/tui_mk1/ui/offenderScanner.js +80 -0
- package/dist/tui_mk1/ui/offenderScanner.js.map +1 -0
- package/dist/tui_mk1/ui/safe.d.ts +9 -0
- package/dist/tui_mk1/ui/safe.d.ts.map +1 -0
- package/dist/tui_mk1/ui/safe.js +29 -0
- package/dist/tui_mk1/ui/safe.js.map +1 -0
- package/dist/tui_mk1/ui/safeText.d.ts +22 -0
- package/dist/tui_mk1/ui/safeText.d.ts.map +1 -0
- package/dist/tui_mk1/ui/safeText.js +50 -0
- package/dist/tui_mk1/ui/safeText.js.map +1 -0
- package/dist/tui_mk1/ui/uiBuilder.d.ts +44 -0
- package/dist/tui_mk1/ui/uiBuilder.d.ts.map +1 -0
- package/dist/tui_mk1/ui/uiBuilder.js +467 -0
- package/dist/tui_mk1/ui/uiBuilder.js.map +1 -0
- package/dist/tui_mk1/viewport/safeViewport.d.ts +10 -1
- package/dist/tui_mk1/viewport/safeViewport.d.ts.map +1 -1
- package/dist/tui_mk1/viewport/safeViewport.js +47 -15
- package/dist/tui_mk1/viewport/safeViewport.js.map +1 -1
- package/dist/tui_mk2/kernel.d.ts +28 -0
- package/dist/tui_mk2/kernel.d.ts.map +1 -0
- package/dist/tui_mk2/kernel.js +138 -0
- package/dist/tui_mk2/kernel.js.map +1 -0
- package/dist/tui_mk2/mk2App.d.ts +33 -0
- package/dist/tui_mk2/mk2App.d.ts.map +1 -0
- package/dist/tui_mk2/mk2App.js +135 -0
- package/dist/tui_mk2/mk2App.js.map +1 -0
- package/package.json +8 -7
- package/dist/tui_mk1/ui/panels/createSection.d.ts +0 -18
- package/dist/tui_mk1/ui/panels/createSection.d.ts.map +0 -1
- package/dist/tui_mk1/ui/panels/createSection.js +0 -42
- package/dist/tui_mk1/ui/panels/createSection.js.map +0 -1
- package/dist/tui_mk1/ui/panels.d.ts +0 -23
- package/dist/tui_mk1/ui/panels.d.ts.map +0 -1
- package/dist/tui_mk1/ui/panels.js +0 -108
- package/dist/tui_mk1/ui/panels.js.map +0 -1
- package/dist/tui_mk1/ui/render/sectionRenderer.d.ts +0 -21
- package/dist/tui_mk1/ui/render/sectionRenderer.d.ts.map +0 -1
- package/dist/tui_mk1/ui/render/sectionRenderer.js +0 -32
- package/dist/tui_mk1/ui/render/sectionRenderer.js.map +0 -1
- package/dist/tui_mk1/ui/widgetManager.d.ts +0 -58
- package/dist/tui_mk1/ui/widgetManager.d.ts.map +0 -1
- package/dist/tui_mk1/ui/widgetManager.js +0 -197
- package/dist/tui_mk1/ui/widgetManager.js.map +0 -1
- package/dist/ui/boot/sequence.d.ts +0 -10
- package/dist/ui/boot/sequence.d.ts.map +0 -1
- package/dist/ui/boot/sequence.js +0 -171
- package/dist/ui/boot/sequence.js.map +0 -1
- package/dist/ui/constraints/layoutSpec.d.ts +0 -47
- package/dist/ui/constraints/layoutSpec.d.ts.map +0 -1
- package/dist/ui/constraints/layoutSpec.js +0 -60
- package/dist/ui/constraints/layoutSpec.js.map +0 -1
- package/dist/ui/constraints/unknownHandling.d.ts +0 -29
- package/dist/ui/constraints/unknownHandling.d.ts.map +0 -1
- package/dist/ui/constraints/unknownHandling.js +0 -60
- package/dist/ui/constraints/unknownHandling.js.map +0 -1
- package/dist/ui/drilldowns/feed.d.ts +0 -11
- package/dist/ui/drilldowns/feed.d.ts.map +0 -1
- package/dist/ui/drilldowns/feed.js +0 -68
- package/dist/ui/drilldowns/feed.js.map +0 -1
- package/dist/ui/drilldowns/index.d.ts +0 -7
- package/dist/ui/drilldowns/index.d.ts.map +0 -1
- package/dist/ui/drilldowns/index.js +0 -8
- package/dist/ui/drilldowns/index.js.map +0 -1
- package/dist/ui/drilldowns/posture.d.ts +0 -11
- package/dist/ui/drilldowns/posture.d.ts.map +0 -1
- package/dist/ui/drilldowns/posture.js +0 -74
- package/dist/ui/drilldowns/posture.js.map +0 -1
- package/dist/ui/intelligence-posture-view.d.ts +0 -22
- package/dist/ui/intelligence-posture-view.d.ts.map +0 -1
- package/dist/ui/intelligence-posture-view.js +0 -169
- package/dist/ui/intelligence-posture-view.js.map +0 -1
- package/dist/ui/navigation/keymaps.d.ts +0 -26
- package/dist/ui/navigation/keymaps.d.ts.map +0 -1
- package/dist/ui/navigation/keymaps.js +0 -135
- package/dist/ui/navigation/keymaps.js.map +0 -1
- package/dist/ui/navigation/palette.d.ts +0 -10
- package/dist/ui/navigation/palette.d.ts.map +0 -1
- package/dist/ui/navigation/palette.js +0 -133
- package/dist/ui/navigation/palette.js.map +0 -1
- package/dist/ui/navigation/state.d.ts +0 -47
- package/dist/ui/navigation/state.d.ts.map +0 -1
- package/dist/ui/navigation/state.js +0 -84
- package/dist/ui/navigation/state.js.map +0 -1
- package/dist/ui/navigation/types.d.ts +0 -38
- package/dist/ui/navigation/types.d.ts.map +0 -1
- package/dist/ui/navigation/types.js +0 -36
- package/dist/ui/navigation/types.js.map +0 -1
- package/dist/ui/panels/active-assets.d.ts +0 -12
- package/dist/ui/panels/active-assets.d.ts.map +0 -1
- package/dist/ui/panels/active-assets.js +0 -83
- package/dist/ui/panels/active-assets.js.map +0 -1
- package/dist/ui/panels/capability-flags.d.ts +0 -12
- package/dist/ui/panels/capability-flags.d.ts.map +0 -1
- package/dist/ui/panels/capability-flags.js +0 -59
- package/dist/ui/panels/capability-flags.js.map +0 -1
- package/dist/ui/panels/command-surface.d.ts +0 -12
- package/dist/ui/panels/command-surface.d.ts.map +0 -1
- package/dist/ui/panels/command-surface.js +0 -55
- package/dist/ui/panels/command-surface.js.map +0 -1
- package/dist/ui/panels/network-origin.d.ts +0 -12
- package/dist/ui/panels/network-origin.d.ts.map +0 -1
- package/dist/ui/panels/network-origin.js +0 -79
- package/dist/ui/panels/network-origin.js.map +0 -1
- package/dist/ui/panels/operations-feed.d.ts +0 -12
- package/dist/ui/panels/operations-feed.d.ts.map +0 -1
- package/dist/ui/panels/operations-feed.js +0 -90
- package/dist/ui/panels/operations-feed.js.map +0 -1
- package/dist/ui/panels/posture.d.ts +0 -12
- package/dist/ui/panels/posture.d.ts.map +0 -1
- package/dist/ui/panels/posture.js +0 -84
- package/dist/ui/panels/posture.js.map +0 -1
- package/dist/ui/panels/resources.d.ts +0 -11
- package/dist/ui/panels/resources.d.ts.map +0 -1
- package/dist/ui/panels/resources.js +0 -88
- package/dist/ui/panels/resources.js.map +0 -1
- package/dist/ui/primitives/Panel.d.ts +0 -25
- package/dist/ui/primitives/Panel.d.ts.map +0 -1
- package/dist/ui/primitives/Panel.js +0 -59
- package/dist/ui/primitives/Panel.js.map +0 -1
- package/dist/ui/rendering/metricRenderer.d.ts +0 -24
- package/dist/ui/rendering/metricRenderer.d.ts.map +0 -1
- package/dist/ui/rendering/metricRenderer.js +0 -86
- package/dist/ui/rendering/metricRenderer.js.map +0 -1
- package/dist/ui/runtime/hub.d.ts +0 -12
- package/dist/ui/runtime/hub.d.ts.map +0 -1
- package/dist/ui/runtime/hub.js +0 -486
- package/dist/ui/runtime/hub.js.map +0 -1
- package/dist/ui/runtime/hubValidation.d.ts +0 -23
- package/dist/ui/runtime/hubValidation.d.ts.map +0 -1
- package/dist/ui/runtime/hubValidation.js +0 -90
- package/dist/ui/runtime/hubValidation.js.map +0 -1
- package/dist/ui/runtime/index.d.ts +0 -29
- package/dist/ui/runtime/index.d.ts.map +0 -1
- package/dist/ui/runtime/index.js +0 -297
- package/dist/ui/runtime/index.js.map +0 -1
- package/dist/ui/runtime/no-tui.d.ts +0 -12
- package/dist/ui/runtime/no-tui.d.ts.map +0 -1
- package/dist/ui/runtime/no-tui.js +0 -77
- package/dist/ui/runtime/no-tui.js.map +0 -1
- package/dist/ui/runtime/state-builder.d.ts +0 -13
- package/dist/ui/runtime/state-builder.d.ts.map +0 -1
- package/dist/ui/runtime/state-builder.js +0 -114
- package/dist/ui/runtime/state-builder.js.map +0 -1
- package/dist/ui/runtime/terminalSizeCheck.d.ts +0 -10
- package/dist/ui/runtime/terminalSizeCheck.d.ts.map +0 -1
- package/dist/ui/runtime/terminalSizeCheck.js +0 -51
- package/dist/ui/runtime/terminalSizeCheck.js.map +0 -1
- package/dist/ui/runtime/tuiLogGate.d.ts +0 -22
- package/dist/ui/runtime/tuiLogGate.d.ts.map +0 -1
- package/dist/ui/runtime/tuiLogGate.js +0 -68
- package/dist/ui/runtime/tuiLogGate.js.map +0 -1
- package/dist/ui/state/types.d.ts +0 -72
- package/dist/ui/state/types.d.ts.map +0 -1
- package/dist/ui/state/types.js +0 -6
- package/dist/ui/state/types.js.map +0 -1
- package/dist/ui/theme/borders.d.ts +0 -20
- package/dist/ui/theme/borders.d.ts.map +0 -1
- package/dist/ui/theme/borders.js +0 -55
- package/dist/ui/theme/borders.js.map +0 -1
- package/dist/ui/theme/tokens.d.ts +0 -28
- package/dist/ui/theme/tokens.d.ts.map +0 -1
- package/dist/ui/theme/tokens.js +0 -50
- package/dist/ui/theme/tokens.js.map +0 -1
- package/dist/ui/theme/typography.d.ts +0 -14
- package/dist/ui/theme/typography.d.ts.map +0 -1
- package/dist/ui/theme/typography.js +0 -30
- package/dist/ui/theme/typography.js.map +0 -1
- package/dist/ui/v3/collectors/assets.collector.d.ts +0 -20
- package/dist/ui/v3/collectors/assets.collector.d.ts.map +0 -1
- package/dist/ui/v3/collectors/assets.collector.js +0 -80
- package/dist/ui/v3/collectors/assets.collector.js.map +0 -1
- package/dist/ui/v3/collectors/capabilities.collector.d.ts +0 -18
- package/dist/ui/v3/collectors/capabilities.collector.d.ts.map +0 -1
- package/dist/ui/v3/collectors/capabilities.collector.js +0 -113
- package/dist/ui/v3/collectors/capabilities.collector.js.map +0 -1
- package/dist/ui/v3/collectors/network.collector.d.ts +0 -18
- package/dist/ui/v3/collectors/network.collector.d.ts.map +0 -1
- package/dist/ui/v3/collectors/network.collector.js +0 -37
- package/dist/ui/v3/collectors/network.collector.js.map +0 -1
- package/dist/ui/v3/collectors/posture.derive.d.ts +0 -24
- package/dist/ui/v3/collectors/posture.derive.d.ts.map +0 -1
- package/dist/ui/v3/collectors/posture.derive.js +0 -57
- package/dist/ui/v3/collectors/posture.derive.js.map +0 -1
- package/dist/ui/v3/collectors/resources.d.ts +0 -23
- package/dist/ui/v3/collectors/resources.d.ts.map +0 -1
- package/dist/ui/v3/collectors/resources.js +0 -136
- package/dist/ui/v3/collectors/resources.js.map +0 -1
- package/dist/ui/v3/commands/commandEngine.d.ts +0 -77
- package/dist/ui/v3/commands/commandEngine.d.ts.map +0 -1
- package/dist/ui/v3/commands/commandEngine.js +0 -3289
- package/dist/ui/v3/commands/commandEngine.js.map +0 -1
- package/dist/ui/v3/commands/commandResult.d.ts +0 -25
- package/dist/ui/v3/commands/commandResult.d.ts.map +0 -1
- package/dist/ui/v3/commands/commandResult.js +0 -19
- package/dist/ui/v3/commands/commandResult.js.map +0 -1
- package/dist/ui/v3/commands/diagnose.d.ts +0 -17
- package/dist/ui/v3/commands/diagnose.d.ts.map +0 -1
- package/dist/ui/v3/commands/diagnose.js +0 -62
- package/dist/ui/v3/commands/diagnose.js.map +0 -1
- package/dist/ui/v3/commands/errorClassifier.d.ts +0 -23
- package/dist/ui/v3/commands/errorClassifier.d.ts.map +0 -1
- package/dist/ui/v3/commands/errorClassifier.js +0 -63
- package/dist/ui/v3/commands/errorClassifier.js.map +0 -1
- package/dist/ui/v3/commands/parser.d.ts +0 -14
- package/dist/ui/v3/commands/parser.d.ts.map +0 -1
- package/dist/ui/v3/commands/parser.js +0 -29
- package/dist/ui/v3/commands/parser.js.map +0 -1
- package/dist/ui/v3/commands/router.d.ts +0 -13
- package/dist/ui/v3/commands/router.d.ts.map +0 -1
- package/dist/ui/v3/commands/router.js +0 -150
- package/dist/ui/v3/commands/router.js.map +0 -1
- package/dist/ui/v3/config/gateway.d.ts +0 -40
- package/dist/ui/v3/config/gateway.d.ts.map +0 -1
- package/dist/ui/v3/config/gateway.js +0 -113
- package/dist/ui/v3/config/gateway.js.map +0 -1
- package/dist/ui/v3/core/event.d.ts +0 -19
- package/dist/ui/v3/core/event.d.ts.map +0 -1
- package/dist/ui/v3/core/event.js +0 -7
- package/dist/ui/v3/core/event.js.map +0 -1
- package/dist/ui/v3/core/eventBus.d.ts +0 -39
- package/dist/ui/v3/core/eventBus.d.ts.map +0 -1
- package/dist/ui/v3/core/eventBus.js +0 -79
- package/dist/ui/v3/core/eventBus.js.map +0 -1
- package/dist/ui/v3/core/feedStore.d.ts +0 -34
- package/dist/ui/v3/core/feedStore.d.ts.map +0 -1
- package/dist/ui/v3/core/feedStore.js +0 -46
- package/dist/ui/v3/core/feedStore.js.map +0 -1
- package/dist/ui/v3/core/logger.d.ts +0 -40
- package/dist/ui/v3/core/logger.d.ts.map +0 -1
- package/dist/ui/v3/core/logger.js +0 -191
- package/dist/ui/v3/core/logger.js.map +0 -1
- package/dist/ui/v3/core/opEvent.d.ts +0 -15
- package/dist/ui/v3/core/opEvent.d.ts.map +0 -1
- package/dist/ui/v3/core/opEvent.js +0 -7
- package/dist/ui/v3/core/opEvent.js.map +0 -1
- package/dist/ui/v3/index.d.ts +0 -8
- package/dist/ui/v3/index.d.ts.map +0 -1
- package/dist/ui/v3/index.js +0 -51
- package/dist/ui/v3/index.js.map +0 -1
- package/dist/ui/v3/runtime/moduleConfig.d.ts +0 -21
- package/dist/ui/v3/runtime/moduleConfig.d.ts.map +0 -1
- package/dist/ui/v3/runtime/moduleConfig.js +0 -41
- package/dist/ui/v3/runtime/moduleConfig.js.map +0 -1
- package/dist/ui/v3/section0/index.d.ts +0 -22
- package/dist/ui/v3/section0/index.d.ts.map +0 -1
- package/dist/ui/v3/section0/index.js +0 -88
- package/dist/ui/v3/section0/index.js.map +0 -1
- package/dist/ui/v3/section0/runtime/createScreen.d.ts +0 -27
- package/dist/ui/v3/section0/runtime/createScreen.d.ts.map +0 -1
- package/dist/ui/v3/section0/runtime/createScreen.js +0 -55
- package/dist/ui/v3/section0/runtime/createScreen.js.map +0 -1
- package/dist/ui/v3/section0/runtime/lifecycle.d.ts +0 -53
- package/dist/ui/v3/section0/runtime/lifecycle.d.ts.map +0 -1
- package/dist/ui/v3/section0/runtime/lifecycle.js +0 -172
- package/dist/ui/v3/section0/runtime/lifecycle.js.map +0 -1
- package/dist/ui/v3/section1/index.d.ts +0 -19
- package/dist/ui/v3/section1/index.d.ts.map +0 -1
- package/dist/ui/v3/section1/index.js +0 -413
- package/dist/ui/v3/section1/index.js.map +0 -1
- package/dist/ui/v3/section1/runtime/commandLine.d.ts +0 -49
- package/dist/ui/v3/section1/runtime/commandLine.d.ts.map +0 -1
- package/dist/ui/v3/section1/runtime/commandLine.js +0 -183
- package/dist/ui/v3/section1/runtime/commandLine.js.map +0 -1
- package/dist/ui/v3/section1/runtime/focusLock.d.ts +0 -24
- package/dist/ui/v3/section1/runtime/focusLock.d.ts.map +0 -1
- package/dist/ui/v3/section1/runtime/focusLock.js +0 -44
- package/dist/ui/v3/section1/runtime/focusLock.js.map +0 -1
- package/dist/ui/v3/state/assertUiState.d.ts +0 -27
- package/dist/ui/v3/state/assertUiState.d.ts.map +0 -1
- package/dist/ui/v3/state/assertUiState.js +0 -89
- package/dist/ui/v3/state/assertUiState.js.map +0 -1
- package/dist/ui/v3/state/capabilitiesStore.d.ts +0 -54
- package/dist/ui/v3/state/capabilitiesStore.d.ts.map +0 -1
- package/dist/ui/v3/state/capabilitiesStore.js +0 -76
- package/dist/ui/v3/state/capabilitiesStore.js.map +0 -1
- package/dist/ui/v3/state/defaultState.d.ts +0 -19
- package/dist/ui/v3/state/defaultState.d.ts.map +0 -1
- package/dist/ui/v3/state/defaultState.js +0 -28
- package/dist/ui/v3/state/defaultState.js.map +0 -1
- package/dist/ui/v3/state/gatewayConnectionStore.d.ts +0 -72
- package/dist/ui/v3/state/gatewayConnectionStore.d.ts.map +0 -1
- package/dist/ui/v3/state/gatewayConnectionStore.js +0 -108
- package/dist/ui/v3/state/gatewayConnectionStore.js.map +0 -1
- package/dist/ui/v3/state/initializePostureState.d.ts +0 -23
- package/dist/ui/v3/state/initializePostureState.d.ts.map +0 -1
- package/dist/ui/v3/state/initializePostureState.js +0 -41
- package/dist/ui/v3/state/initializePostureState.js.map +0 -1
- package/dist/ui/v3/state/panelStore.d.ts +0 -80
- package/dist/ui/v3/state/panelStore.d.ts.map +0 -1
- package/dist/ui/v3/state/panelStore.js +0 -131
- package/dist/ui/v3/state/panelStore.js.map +0 -1
- package/dist/ui/v3/state/resourcesData.d.ts +0 -15
- package/dist/ui/v3/state/resourcesData.d.ts.map +0 -1
- package/dist/ui/v3/state/resourcesData.js +0 -7
- package/dist/ui/v3/state/resourcesData.js.map +0 -1
- package/dist/ui/v3/state/uiState.d.ts +0 -22
- package/dist/ui/v3/state/uiState.d.ts.map +0 -1
- package/dist/ui/v3/state/uiState.js +0 -13
- package/dist/ui/v3/state/uiState.js.map +0 -1
- package/dist/ui/v3/state/uiStateBuilder.d.ts +0 -32
- package/dist/ui/v3/state/uiStateBuilder.d.ts.map +0 -1
- package/dist/ui/v3/state/uiStateBuilder.js +0 -73
- package/dist/ui/v3/state/uiStateBuilder.js.map +0 -1
- package/dist/ui/v3/state/uiStateTypes.d.ts +0 -59
- package/dist/ui/v3/state/uiStateTypes.d.ts.map +0 -1
- package/dist/ui/v3/state/uiStateTypes.js +0 -8
- package/dist/ui/v3/state/uiStateTypes.js.map +0 -1
- package/dist/ui/v3/state/value.d.ts +0 -80
- package/dist/ui/v3/state/value.d.ts.map +0 -1
- package/dist/ui/v3/state/value.js +0 -96
- package/dist/ui/v3/state/value.js.map +0 -1
- package/dist/ui/v3/tui/geometry.d.ts +0 -83
- package/dist/ui/v3/tui/geometry.d.ts.map +0 -1
- package/dist/ui/v3/tui/geometry.js +0 -201
- package/dist/ui/v3/tui/geometry.js.map +0 -1
- package/dist/ui/v3/tui/startTui.d.ts +0 -37
- package/dist/ui/v3/tui/startTui.d.ts.map +0 -1
- package/dist/ui/v3/tui/startTui.js +0 -61
- package/dist/ui/v3/tui/startTui.js.map +0 -1
- package/dist/ui/v3/tui/terminalMode.d.ts +0 -31
- package/dist/ui/v3/tui/terminalMode.d.ts.map +0 -1
- package/dist/ui/v3/tui/terminalMode.js +0 -76
- package/dist/ui/v3/tui/terminalMode.js.map +0 -1
- package/dist/ui/v3/ui/debugUtils.d.ts +0 -67
- package/dist/ui/v3/ui/debugUtils.d.ts.map +0 -1
- package/dist/ui/v3/ui/debugUtils.js +0 -238
- package/dist/ui/v3/ui/debugUtils.js.map +0 -1
- package/dist/ui/v3/ui/focus.d.ts +0 -28
- package/dist/ui/v3/ui/focus.d.ts.map +0 -1
- package/dist/ui/v3/ui/focus.js +0 -38
- package/dist/ui/v3/ui/focus.js.map +0 -1
- package/dist/ui/v3/ui/layout/hubLayout.d.ts +0 -43
- package/dist/ui/v3/ui/layout/hubLayout.d.ts.map +0 -1
- package/dist/ui/v3/ui/layout/hubLayout.js +0 -170
- package/dist/ui/v3/ui/layout/hubLayout.js.map +0 -1
- package/dist/ui/v3/ui/layout/phase1Layout.d.ts +0 -63
- package/dist/ui/v3/ui/layout/phase1Layout.d.ts.map +0 -1
- package/dist/ui/v3/ui/layout/phase1Layout.js +0 -274
- package/dist/ui/v3/ui/layout/phase1Layout.js.map +0 -1
- package/dist/ui/v3/ui/layout/phase1Layout.test.d.ts +0 -5
- package/dist/ui/v3/ui/layout/phase1Layout.test.d.ts.map +0 -1
- package/dist/ui/v3/ui/layout/phase1Layout.test.js +0 -120
- package/dist/ui/v3/ui/layout/phase1Layout.test.js.map +0 -1
- package/dist/ui/v3/ui/minimalRuntime.d.ts +0 -14
- package/dist/ui/v3/ui/minimalRuntime.d.ts.map +0 -1
- package/dist/ui/v3/ui/minimalRuntime.js +0 -111
- package/dist/ui/v3/ui/minimalRuntime.js.map +0 -1
- package/dist/ui/v3/ui/panels/AssetsPanel.d.ts +0 -17
- package/dist/ui/v3/ui/panels/AssetsPanel.d.ts.map +0 -1
- package/dist/ui/v3/ui/panels/AssetsPanel.js +0 -53
- package/dist/ui/v3/ui/panels/AssetsPanel.js.map +0 -1
- package/dist/ui/v3/ui/panels/CapabilitiesPanel.d.ts +0 -20
- package/dist/ui/v3/ui/panels/CapabilitiesPanel.d.ts.map +0 -1
- package/dist/ui/v3/ui/panels/CapabilitiesPanel.js +0 -67
- package/dist/ui/v3/ui/panels/CapabilitiesPanel.js.map +0 -1
- package/dist/ui/v3/ui/panels/NetworkPanel.d.ts +0 -31
- package/dist/ui/v3/ui/panels/NetworkPanel.d.ts.map +0 -1
- package/dist/ui/v3/ui/panels/NetworkPanel.js +0 -153
- package/dist/ui/v3/ui/panels/NetworkPanel.js.map +0 -1
- package/dist/ui/v3/ui/panels/PosturePanel.d.ts +0 -16
- package/dist/ui/v3/ui/panels/PosturePanel.d.ts.map +0 -1
- package/dist/ui/v3/ui/panels/PosturePanel.js +0 -60
- package/dist/ui/v3/ui/panels/PosturePanel.js.map +0 -1
- package/dist/ui/v3/ui/panels/ResourcesPanel.d.ts +0 -20
- package/dist/ui/v3/ui/panels/ResourcesPanel.d.ts.map +0 -1
- package/dist/ui/v3/ui/panels/ResourcesPanel.js +0 -66
- package/dist/ui/v3/ui/panels/ResourcesPanel.js.map +0 -1
- package/dist/ui/v3/ui/phase1Runtime.d.ts +0 -29
- package/dist/ui/v3/ui/phase1Runtime.d.ts.map +0 -1
- package/dist/ui/v3/ui/phase1Runtime.js +0 -1648
- package/dist/ui/v3/ui/phase1Runtime.js.map +0 -1
- package/dist/ui/v3/ui/phase1RuntimeClean.d.ts +0 -34
- package/dist/ui/v3/ui/phase1RuntimeClean.d.ts.map +0 -1
- package/dist/ui/v3/ui/phase1RuntimeClean.js +0 -1841
- package/dist/ui/v3/ui/phase1RuntimeClean.js.map +0 -1
- package/dist/ui/v3/ui/primitives/Panel.d.ts +0 -39
- package/dist/ui/v3/ui/primitives/Panel.d.ts.map +0 -1
- package/dist/ui/v3/ui/primitives/Panel.js +0 -105
- package/dist/ui/v3/ui/primitives/Panel.js.map +0 -1
- package/dist/ui/v3/ui/theme.d.ts +0 -37
- package/dist/ui/v3/ui/theme.d.ts.map +0 -1
- package/dist/ui/v3/ui/theme.js +0 -40
- package/dist/ui/v3/ui/theme.js.map +0 -1
- package/dist/ui/v3/ui/uiRuntime.d.ts +0 -40
- package/dist/ui/v3/ui/uiRuntime.d.ts.map +0 -1
- package/dist/ui/v3/ui/uiRuntime.js +0 -60
- package/dist/ui/v3/ui/uiRuntime.js.map +0 -1
- package/dist/ui/v3/ui/widgets/CommandLine.d.ts +0 -26
- package/dist/ui/v3/ui/widgets/CommandLine.d.ts.map +0 -1
- package/dist/ui/v3/ui/widgets/CommandLine.js +0 -67
- package/dist/ui/v3/ui/widgets/CommandLine.js.map +0 -1
- package/dist/ui/v3/v1Adapters/agents.d.ts +0 -72
- package/dist/ui/v3/v1Adapters/agents.d.ts.map +0 -1
- package/dist/ui/v3/v1Adapters/agents.js +0 -182
- package/dist/ui/v3/v1Adapters/agents.js.map +0 -1
- package/dist/ui/v3/v1Adapters/config.d.ts +0 -67
- package/dist/ui/v3/v1Adapters/config.d.ts.map +0 -1
- package/dist/ui/v3/v1Adapters/config.js +0 -78
- package/dist/ui/v3/v1Adapters/config.js.map +0 -1
- package/dist/ui/v3/v1Adapters/connect.d.ts +0 -77
- package/dist/ui/v3/v1Adapters/connect.d.ts.map +0 -1
- package/dist/ui/v3/v1Adapters/connect.js +0 -576
- package/dist/ui/v3/v1Adapters/connect.js.map +0 -1
- package/dist/ui/v3/v1Adapters/httpDebug.d.ts +0 -19
- package/dist/ui/v3/v1Adapters/httpDebug.d.ts.map +0 -1
- package/dist/ui/v3/v1Adapters/httpDebug.js +0 -60
- package/dist/ui/v3/v1Adapters/httpDebug.js.map +0 -1
- package/dist/ui/v3/v1Adapters/runs.d.ts +0 -77
- package/dist/ui/v3/v1Adapters/runs.d.ts.map +0 -1
- package/dist/ui/v3/v1Adapters/runs.js +0 -339
- package/dist/ui/v3/v1Adapters/runs.js.map +0 -1
- package/dist/ui/v4/engine/renderFrame.d.ts +0 -47
- package/dist/ui/v4/engine/renderFrame.d.ts.map +0 -1
- package/dist/ui/v4/engine/renderFrame.js +0 -653
- package/dist/ui/v4/engine/renderFrame.js.map +0 -1
- package/dist/ui/v4/engine/resizeController.d.ts +0 -48
- package/dist/ui/v4/engine/resizeController.d.ts.map +0 -1
- package/dist/ui/v4/engine/resizeController.js +0 -285
- package/dist/ui/v4/engine/resizeController.js.map +0 -1
- package/dist/ui/v4/engine/safeViewport.d.ts +0 -47
- package/dist/ui/v4/engine/safeViewport.d.ts.map +0 -1
- package/dist/ui/v4/engine/safeViewport.js +0 -123
- package/dist/ui/v4/engine/safeViewport.js.map +0 -1
- package/dist/ui/v4/engine/terminalProfile.d.ts +0 -56
- package/dist/ui/v4/engine/terminalProfile.d.ts.map +0 -1
- package/dist/ui/v4/engine/terminalProfile.js +0 -115
- package/dist/ui/v4/engine/terminalProfile.js.map +0 -1
- package/dist/ui/v4/index.d.ts +0 -28
- package/dist/ui/v4/index.d.ts.map +0 -1
- package/dist/ui/v4/index.js +0 -993
- package/dist/ui/v4/index.js.map +0 -1
- package/dist/ui/v4/layout/layoutEngine.d.ts +0 -62
- package/dist/ui/v4/layout/layoutEngine.d.ts.map +0 -1
- package/dist/ui/v4/layout/layoutEngine.js +0 -294
- package/dist/ui/v4/layout/layoutEngine.js.map +0 -1
- package/dist/ui/v4/runtime/keepAlive.d.ts +0 -21
- package/dist/ui/v4/runtime/keepAlive.d.ts.map +0 -1
- package/dist/ui/v4/runtime/keepAlive.js +0 -149
- package/dist/ui/v4/runtime/keepAlive.js.map +0 -1
- package/dist/ui/v4/runtime/logger.d.ts +0 -35
- package/dist/ui/v4/runtime/logger.d.ts.map +0 -1
- package/dist/ui/v4/runtime/logger.js +0 -109
- package/dist/ui/v4/runtime/logger.js.map +0 -1
- package/dist/ui/v5/debug/assertNoOverflow.d.ts +0 -28
- package/dist/ui/v5/debug/assertNoOverflow.d.ts.map +0 -1
- package/dist/ui/v5/debug/assertNoOverflow.js +0 -63
- package/dist/ui/v5/debug/assertNoOverflow.js.map +0 -1
- package/dist/ui/v5/debug/debugCommands.d.ts +0 -20
- package/dist/ui/v5/debug/debugCommands.d.ts.map +0 -1
- package/dist/ui/v5/debug/debugCommands.js +0 -461
- package/dist/ui/v5/debug/debugCommands.js.map +0 -1
- package/dist/ui/v5/debugCommands.d.ts +0 -20
- package/dist/ui/v5/debugCommands.d.ts.map +0 -1
- package/dist/ui/v5/debugCommands.js +0 -81
- package/dist/ui/v5/debugCommands.js.map +0 -1
- package/dist/ui/v5/guardrails/stdoutGuard.d.ts +0 -23
- package/dist/ui/v5/guardrails/stdoutGuard.d.ts.map +0 -1
- package/dist/ui/v5/guardrails/stdoutGuard.js +0 -94
- package/dist/ui/v5/guardrails/stdoutGuard.js.map +0 -1
- package/dist/ui/v5/guardrails/terminalRestore.d.ts +0 -17
- package/dist/ui/v5/guardrails/terminalRestore.d.ts.map +0 -1
- package/dist/ui/v5/guardrails/terminalRestore.js +0 -47
- package/dist/ui/v5/guardrails/terminalRestore.js.map +0 -1
- package/dist/ui/v5/index.d.ts +0 -30
- package/dist/ui/v5/index.d.ts.map +0 -1
- package/dist/ui/v5/index.js +0 -243
- package/dist/ui/v5/index.js.map +0 -1
- package/dist/ui/v5/kernel/kernel.d.ts +0 -81
- package/dist/ui/v5/kernel/kernel.d.ts.map +0 -1
- package/dist/ui/v5/kernel/kernel.js +0 -339
- package/dist/ui/v5/kernel/kernel.js.map +0 -1
- package/dist/ui/v5/kernel.d.ts +0 -75
- package/dist/ui/v5/kernel.d.ts.map +0 -1
- package/dist/ui/v5/kernel.js +0 -289
- package/dist/ui/v5/kernel.js.map +0 -1
- package/dist/ui/v5/layout/clampRect.d.ts +0 -28
- package/dist/ui/v5/layout/clampRect.d.ts.map +0 -1
- package/dist/ui/v5/layout/clampRect.js +0 -45
- package/dist/ui/v5/layout/clampRect.js.map +0 -1
- package/dist/ui/v5/layout/layoutEngine.d.ts +0 -16
- package/dist/ui/v5/layout/layoutEngine.d.ts.map +0 -1
- package/dist/ui/v5/layout/layoutEngine.js +0 -99
- package/dist/ui/v5/layout/layoutEngine.js.map +0 -1
- package/dist/ui/v5/renderGate.d.ts +0 -19
- package/dist/ui/v5/renderGate.d.ts.map +0 -1
- package/dist/ui/v5/renderGate.js +0 -36
- package/dist/ui/v5/renderGate.js.map +0 -1
- package/dist/ui/v5/resize/resizeController.d.ts +0 -62
- package/dist/ui/v5/resize/resizeController.d.ts.map +0 -1
- package/dist/ui/v5/resize/resizeController.js +0 -141
- package/dist/ui/v5/resize/resizeController.js.map +0 -1
- package/dist/ui/v5/resizeController.d.ts +0 -55
- package/dist/ui/v5/resizeController.d.ts.map +0 -1
- package/dist/ui/v5/resizeController.js +0 -124
- package/dist/ui/v5/resizeController.js.map +0 -1
- package/dist/ui/v5/runtime/keepAlive.d.ts +0 -37
- package/dist/ui/v5/runtime/keepAlive.d.ts.map +0 -1
- package/dist/ui/v5/runtime/keepAlive.js +0 -122
- package/dist/ui/v5/runtime/keepAlive.js.map +0 -1
- package/dist/ui/v5/runtime/restoreTerminal.d.ts +0 -34
- package/dist/ui/v5/runtime/restoreTerminal.d.ts.map +0 -1
- package/dist/ui/v5/runtime/restoreTerminal.js +0 -100
- package/dist/ui/v5/runtime/restoreTerminal.js.map +0 -1
- package/dist/ui/v5/runtime/stdoutGuard.d.ts +0 -42
- package/dist/ui/v5/runtime/stdoutGuard.d.ts.map +0 -1
- package/dist/ui/v5/runtime/stdoutGuard.js +0 -156
- package/dist/ui/v5/runtime/stdoutGuard.js.map +0 -1
- package/dist/ui/v5/viewport/getViewport.d.ts +0 -23
- package/dist/ui/v5/viewport/getViewport.d.ts.map +0 -1
- package/dist/ui/v5/viewport/getViewport.js +0 -117
- package/dist/ui/v5/viewport/getViewport.js.map +0 -1
- package/dist/ui/v5/viewport.d.ts +0 -41
- package/dist/ui/v5/viewport.d.ts.map +0 -1
- package/dist/ui/v5/viewport.js +0 -90
- package/dist/ui/v5/viewport.js.map +0 -1
- package/dist/ui/widgets/flagRow.d.ts +0 -25
- package/dist/ui/widgets/flagRow.d.ts.map +0 -1
- package/dist/ui/widgets/flagRow.js +0 -57
- package/dist/ui/widgets/flagRow.js.map +0 -1
- package/dist/ui/widgets/index.d.ts +0 -9
- package/dist/ui/widgets/index.d.ts.map +0 -1
- package/dist/ui/widgets/index.js +0 -9
- package/dist/ui/widgets/index.js.map +0 -1
- package/dist/ui/widgets/meter.d.ts +0 -18
- package/dist/ui/widgets/meter.d.ts.map +0 -1
- package/dist/ui/widgets/meter.js +0 -38
- package/dist/ui/widgets/meter.js.map +0 -1
- package/dist/ui/widgets/miniMap.d.ts +0 -26
- package/dist/ui/widgets/miniMap.d.ts.map +0 -1
- package/dist/ui/widgets/miniMap.js +0 -94
- package/dist/ui/widgets/miniMap.js.map +0 -1
- package/dist/ui/widgets/sparkline.d.ts +0 -17
- package/dist/ui/widgets/sparkline.d.ts.map +0 -1
- package/dist/ui/widgets/sparkline.js +0 -65
- package/dist/ui/widgets/sparkline.js.map +0 -1
package/dist/ui/v5/kernel.js
DELETED
|
@@ -1,289 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 UI Kernel
|
|
3
|
-
*
|
|
4
|
-
* Owns the screen and all widgets. Provides atomic rebuild capability.
|
|
5
|
-
*
|
|
6
|
-
* HARD RULE: Never resize/move existing widgets.
|
|
7
|
-
* On every committed resize: destroy all widgets and recreate them.
|
|
8
|
-
*/
|
|
9
|
-
import blessed from 'neo-blessed';
|
|
10
|
-
import { safeStderrWrite } from './runtime/stdoutGuard.js';
|
|
11
|
-
import { setLayoutVersion } from './renderGate.js';
|
|
12
|
-
import { computeViewport, assertRect } from './viewport.js';
|
|
13
|
-
export class UIKernel {
|
|
14
|
-
screen;
|
|
15
|
-
widgets = null;
|
|
16
|
-
layoutVersion = 0;
|
|
17
|
-
isRebuilding = false;
|
|
18
|
-
pendingRebuild = null;
|
|
19
|
-
debugOverlayVisible = false;
|
|
20
|
-
constructor(screen) {
|
|
21
|
-
this.screen = screen;
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* Get current layout version (for render gating)
|
|
25
|
-
*/
|
|
26
|
-
getLayoutVersion() {
|
|
27
|
-
return this.layoutVersion;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Boot the kernel - initial mount
|
|
31
|
-
*/
|
|
32
|
-
boot() {
|
|
33
|
-
if (this.widgets) {
|
|
34
|
-
throw new Error('Kernel already booted');
|
|
35
|
-
}
|
|
36
|
-
const vp = computeViewport(this.screen);
|
|
37
|
-
this.widgets = this.createWidgets(vp);
|
|
38
|
-
this.layoutVersion = 1;
|
|
39
|
-
setLayoutVersion(this.layoutVersion);
|
|
40
|
-
// Force a render after a small delay to ensure screen is ready
|
|
41
|
-
setImmediate(() => {
|
|
42
|
-
this.screen.render();
|
|
43
|
-
});
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Rebuild the UI - atomic destroy and recreate
|
|
47
|
-
*/
|
|
48
|
-
rebuild(options) {
|
|
49
|
-
// A) Block re-entrant rebuild
|
|
50
|
-
if (this.isRebuilding) {
|
|
51
|
-
this.pendingRebuild = options;
|
|
52
|
-
return;
|
|
53
|
-
}
|
|
54
|
-
this.isRebuilding = true;
|
|
55
|
-
try {
|
|
56
|
-
// B) Clear the terminal buffer
|
|
57
|
-
const program = this.screen.program;
|
|
58
|
-
if (program) {
|
|
59
|
-
if (typeof program.clear === 'function') {
|
|
60
|
-
program.clear();
|
|
61
|
-
}
|
|
62
|
-
if (typeof program.flush === 'function') {
|
|
63
|
-
program.flush();
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
// C) Destroy everything currently mounted (hard)
|
|
67
|
-
this.destroyAllChildren();
|
|
68
|
-
// D) Compute viewport (single source of truth)
|
|
69
|
-
const vp = computeViewport(this.screen);
|
|
70
|
-
// E) Recreate widgets fresh using safe dimensions
|
|
71
|
-
this.widgets = this.createWidgets(vp);
|
|
72
|
-
this.layoutVersion = options.version;
|
|
73
|
-
setLayoutVersion(this.layoutVersion);
|
|
74
|
-
// F) Render once
|
|
75
|
-
this.screen.render();
|
|
76
|
-
// Update debug overlay if visible
|
|
77
|
-
this.updateDebugOverlay(options);
|
|
78
|
-
// G) Restore input focus
|
|
79
|
-
if (this.widgets.commandInput) {
|
|
80
|
-
this.widgets.commandInput.focus();
|
|
81
|
-
this.screen.render();
|
|
82
|
-
}
|
|
83
|
-
safeStderrWrite(`[V5] Rebuilt layout v${options.version} (raw: ${vp.rawCols}x${vp.rawRows}, safe: ${vp.safeCols}x${vp.safeRows}) from ${options.source} (burst: ${options.burstCount})\n`);
|
|
84
|
-
}
|
|
85
|
-
finally {
|
|
86
|
-
this.isRebuilding = false;
|
|
87
|
-
// Process pending rebuild if one was queued
|
|
88
|
-
if (this.pendingRebuild) {
|
|
89
|
-
const pending = this.pendingRebuild;
|
|
90
|
-
this.pendingRebuild = null;
|
|
91
|
-
// Use setImmediate to avoid re-entrancy issues
|
|
92
|
-
setImmediate(() => this.rebuild(pending));
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
/**
|
|
97
|
-
* Destroy the kernel and all widgets
|
|
98
|
-
*/
|
|
99
|
-
destroy() {
|
|
100
|
-
this.destroyAllChildren();
|
|
101
|
-
this.widgets = null;
|
|
102
|
-
}
|
|
103
|
-
/**
|
|
104
|
-
* Get current widgets (for external access)
|
|
105
|
-
*/
|
|
106
|
-
getWidgets() {
|
|
107
|
-
return this.widgets;
|
|
108
|
-
}
|
|
109
|
-
/**
|
|
110
|
-
* Get operations panel (for debug commands)
|
|
111
|
-
*/
|
|
112
|
-
getOperationsPanel() {
|
|
113
|
-
return this.widgets?.operationsPanel;
|
|
114
|
-
}
|
|
115
|
-
/**
|
|
116
|
-
* Toggle debug overlay
|
|
117
|
-
*/
|
|
118
|
-
toggleDebugOverlay(options) {
|
|
119
|
-
this.debugOverlayVisible = !this.debugOverlayVisible;
|
|
120
|
-
if (this.widgets) {
|
|
121
|
-
if (this.debugOverlayVisible) {
|
|
122
|
-
// Create or update debug overlay
|
|
123
|
-
if (this.widgets.debugOverlay) {
|
|
124
|
-
if (typeof this.widgets.debugOverlay.detach === 'function') {
|
|
125
|
-
this.widgets.debugOverlay.detach();
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
const vp = computeViewport(this.screen);
|
|
129
|
-
const overlayWidth = vp.safeCols;
|
|
130
|
-
this.widgets.debugOverlay = blessed.box({
|
|
131
|
-
top: 0,
|
|
132
|
-
left: 0,
|
|
133
|
-
width: overlayWidth,
|
|
134
|
-
height: 1,
|
|
135
|
-
content: `raw: ${vp.rawCols}x${vp.rawRows} safe: ${vp.safeCols}x${vp.safeRows} | v${options.version} | burst: ${options.burstCount} | ${options.source}`,
|
|
136
|
-
style: {
|
|
137
|
-
fg: 'yellow',
|
|
138
|
-
},
|
|
139
|
-
});
|
|
140
|
-
assertRect('debugOverlay', { x: 0, y: 0, w: overlayWidth, h: 1 }, vp);
|
|
141
|
-
this.screen.append(this.widgets.debugOverlay);
|
|
142
|
-
}
|
|
143
|
-
else {
|
|
144
|
-
// Remove debug overlay
|
|
145
|
-
if (this.widgets.debugOverlay) {
|
|
146
|
-
if (typeof this.widgets.debugOverlay.detach === 'function') {
|
|
147
|
-
this.widgets.debugOverlay.detach();
|
|
148
|
-
}
|
|
149
|
-
if (typeof this.widgets.debugOverlay.destroy === 'function') {
|
|
150
|
-
this.widgets.debugOverlay.destroy();
|
|
151
|
-
}
|
|
152
|
-
this.widgets.debugOverlay = undefined;
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
this.screen.render();
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
/**
|
|
159
|
-
* Update debug overlay with new info
|
|
160
|
-
*/
|
|
161
|
-
updateDebugOverlay(options) {
|
|
162
|
-
if (this.debugOverlayVisible && this.widgets?.debugOverlay) {
|
|
163
|
-
const vp = computeViewport(this.screen);
|
|
164
|
-
this.widgets.debugOverlay.setContent(`raw: ${vp.rawCols}x${vp.rawRows} safe: ${vp.safeCols}x${vp.safeRows} | v${options.version} | burst: ${options.burstCount} | ${options.source}`);
|
|
165
|
-
this.screen.render();
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
/**
|
|
169
|
-
* Destroy all children widgets (hard destroy)
|
|
170
|
-
*/
|
|
171
|
-
destroyAllChildren() {
|
|
172
|
-
// Copy list first because detach mutates
|
|
173
|
-
const kids = [...this.screen.children];
|
|
174
|
-
for (const k of kids) {
|
|
175
|
-
try {
|
|
176
|
-
if (typeof k.detach === 'function') {
|
|
177
|
-
k.detach();
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
catch (e) {
|
|
181
|
-
// Ignore detach errors
|
|
182
|
-
}
|
|
183
|
-
try {
|
|
184
|
-
if (typeof k.destroy === 'function') {
|
|
185
|
-
k.destroy();
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
catch (e) {
|
|
189
|
-
// Ignore destroy errors
|
|
190
|
-
}
|
|
191
|
-
}
|
|
192
|
-
// Remove from screen.children manually (blessed sometimes doesn't clean up)
|
|
193
|
-
const screenChildren = this.screen.children || [];
|
|
194
|
-
while (screenChildren.length > 0) {
|
|
195
|
-
screenChildren.pop();
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
/**
|
|
199
|
-
* Create all widgets fresh
|
|
200
|
-
*
|
|
201
|
-
* CRITICAL: Uses safeCols/safeRows to prevent overflow
|
|
202
|
-
*/
|
|
203
|
-
createWidgets(vp) {
|
|
204
|
-
// Use explicit pixel dimensions - use ~95% of SAFE viewport
|
|
205
|
-
const boxWidth = Math.floor(vp.safeCols * 0.95);
|
|
206
|
-
const boxHeight = Math.floor(vp.safeRows * 0.95);
|
|
207
|
-
const boxLeft = Math.floor((vp.safeCols - boxWidth) / 2);
|
|
208
|
-
const boxTop = Math.floor((vp.safeRows - boxHeight) / 2);
|
|
209
|
-
// Assert no overflow
|
|
210
|
-
assertRect('testBox', { x: boxLeft, y: boxTop, w: boxWidth, h: boxHeight }, vp);
|
|
211
|
-
const testBox = blessed.box({
|
|
212
|
-
top: boxTop,
|
|
213
|
-
left: boxLeft,
|
|
214
|
-
width: boxWidth,
|
|
215
|
-
height: boxHeight,
|
|
216
|
-
content: 'V5 Kernel - Phase 1\n\nGuardrails Active:\n✓ Stdout guard\n✓ Keep-alive\n✓ Terminal restore\n✓ Atomic resize\n✓ Safe viewport\n\nPress Ctrl+C to exit',
|
|
217
|
-
border: {
|
|
218
|
-
type: 'line',
|
|
219
|
-
},
|
|
220
|
-
style: {
|
|
221
|
-
border: {
|
|
222
|
-
fg: 'green',
|
|
223
|
-
},
|
|
224
|
-
},
|
|
225
|
-
});
|
|
226
|
-
// V5 Watermark - top right corner (within safe bounds)
|
|
227
|
-
const watermarkLeft = vp.safeCols - 10;
|
|
228
|
-
const watermark = blessed.box({
|
|
229
|
-
top: 0,
|
|
230
|
-
left: watermarkLeft,
|
|
231
|
-
width: 10,
|
|
232
|
-
height: 1,
|
|
233
|
-
content: '{cyan-fg}V5{/cyan-fg}',
|
|
234
|
-
style: {
|
|
235
|
-
fg: 'cyan',
|
|
236
|
-
},
|
|
237
|
-
tags: true,
|
|
238
|
-
});
|
|
239
|
-
assertRect('watermark', { x: watermarkLeft, y: 0, w: 10, h: 1 }, vp);
|
|
240
|
-
// Operations panel (for debug output) - hidden initially, shown when dbg:size is used
|
|
241
|
-
// Position it below the testBox so it doesn't overlap
|
|
242
|
-
const opsTop = boxTop + boxHeight + 1;
|
|
243
|
-
const opsHeight = 5;
|
|
244
|
-
const operationsPanel = blessed.box({
|
|
245
|
-
top: opsTop,
|
|
246
|
-
left: boxLeft,
|
|
247
|
-
width: boxWidth,
|
|
248
|
-
height: opsHeight,
|
|
249
|
-
content: '',
|
|
250
|
-
scrollable: true,
|
|
251
|
-
alwaysScroll: true,
|
|
252
|
-
keys: true,
|
|
253
|
-
mouse: true,
|
|
254
|
-
hidden: true, // Hidden by default
|
|
255
|
-
style: {
|
|
256
|
-
fg: 'white',
|
|
257
|
-
},
|
|
258
|
-
});
|
|
259
|
-
// Only assert if panel would be visible (not hidden)
|
|
260
|
-
// assertRect('operationsPanel', { x: boxLeft, y: opsTop, w: boxWidth, h: opsHeight }, vp);
|
|
261
|
-
// Command input (for future use) - use box instead of textbox
|
|
262
|
-
const cmdTop = vp.safeRows - 3;
|
|
263
|
-
const cmdLeft = 1;
|
|
264
|
-
const cmdWidth = vp.safeCols - 2;
|
|
265
|
-
const commandInput = blessed.box({
|
|
266
|
-
top: cmdTop,
|
|
267
|
-
left: cmdLeft,
|
|
268
|
-
width: cmdWidth,
|
|
269
|
-
height: 1,
|
|
270
|
-
keys: true,
|
|
271
|
-
input: true,
|
|
272
|
-
style: {
|
|
273
|
-
fg: 'white',
|
|
274
|
-
},
|
|
275
|
-
});
|
|
276
|
-
assertRect('commandInput', { x: cmdLeft, y: cmdTop, w: cmdWidth, h: 1 }, vp);
|
|
277
|
-
this.screen.append(testBox);
|
|
278
|
-
this.screen.append(watermark);
|
|
279
|
-
this.screen.append(operationsPanel);
|
|
280
|
-
this.screen.append(commandInput);
|
|
281
|
-
return {
|
|
282
|
-
testBox,
|
|
283
|
-
watermark,
|
|
284
|
-
commandInput,
|
|
285
|
-
operationsPanel,
|
|
286
|
-
};
|
|
287
|
-
}
|
|
288
|
-
}
|
|
289
|
-
//# sourceMappingURL=kernel.js.map
|
package/dist/ui/v5/kernel.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"kernel.js","sourceRoot":"","sources":["../../../src/ui/v5/kernel.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,OAAO,MAAM,aAAa,CAAC;AAElC,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,UAAU,EAAiB,MAAM,eAAe,CAAC;AAkB3E,MAAM,OAAO,QAAQ;IACX,MAAM,CAAiB;IACvB,OAAO,GAAqB,IAAI,CAAC;IACjC,aAAa,GAAW,CAAC,CAAC;IAC1B,YAAY,GAAY,KAAK,CAAC;IAC9B,cAAc,GAA0B,IAAI,CAAC;IAC7C,mBAAmB,GAAY,KAAK,CAAC;IAE7C,YAAY,MAAsB;QAChC,I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@ -1,28 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 Rect Clamping
|
|
3
|
-
*
|
|
4
|
-
* Hard requirement: Every single widget rect must pass through clampRect.
|
|
5
|
-
* No exceptions.
|
|
6
|
-
*/
|
|
7
|
-
export type Rect = {
|
|
8
|
-
x: number;
|
|
9
|
-
y: number;
|
|
10
|
-
w: number;
|
|
11
|
-
h: number;
|
|
12
|
-
};
|
|
13
|
-
/**
|
|
14
|
-
* Clamp rectangle to fit within safe bounds
|
|
15
|
-
*
|
|
16
|
-
* CRITICAL RULE: x + w <= safeCols - buffer
|
|
17
|
-
*
|
|
18
|
-
* For right-edge panels: buffer = 3 (aggressive)
|
|
19
|
-
* For command panel: buffer = 1 (less aggressive, needs full width)
|
|
20
|
-
* For other panels: buffer = 2 (moderate)
|
|
21
|
-
*
|
|
22
|
-
* Rules:
|
|
23
|
-
* 1) Clamp x/y within bounds
|
|
24
|
-
* 2) Clamp w/h so x+w <= safeCols-buffer and y+h <= safeRows-buffer
|
|
25
|
-
* 3) Enforce w>=1, h>=1
|
|
26
|
-
*/
|
|
27
|
-
export declare function clampRect(r: Rect, safeCols: number, safeRows: number, panelId?: string): Rect;
|
|
28
|
-
//# sourceMappingURL=clampRect.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"clampRect.d.ts","sourceRoot":"","sources":["../../../../src/ui/v5/layout/clampRect.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,MAAM,IAAI,GAAG;IACjB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACX,CAAC;AAEF;;;;;;;;;;;;;GAaG;AACH,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CA4B7F"}
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 Rect Clamping
|
|
3
|
-
*
|
|
4
|
-
* Hard requirement: Every single widget rect must pass through clampRect.
|
|
5
|
-
* No exceptions.
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* Clamp rectangle to fit within safe bounds
|
|
9
|
-
*
|
|
10
|
-
* CRITICAL RULE: x + w <= safeCols - buffer
|
|
11
|
-
*
|
|
12
|
-
* For right-edge panels: buffer = 3 (aggressive)
|
|
13
|
-
* For command panel: buffer = 1 (less aggressive, needs full width)
|
|
14
|
-
* For other panels: buffer = 2 (moderate)
|
|
15
|
-
*
|
|
16
|
-
* Rules:
|
|
17
|
-
* 1) Clamp x/y within bounds
|
|
18
|
-
* 2) Clamp w/h so x+w <= safeCols-buffer and y+h <= safeRows-buffer
|
|
19
|
-
* 3) Enforce w>=1, h>=1
|
|
20
|
-
*/
|
|
21
|
-
export function clampRect(r, safeCols, safeRows, panelId) {
|
|
22
|
-
let { x, y, w, h } = r;
|
|
23
|
-
// Clamp x/y to non-negative
|
|
24
|
-
x = Math.max(0, x);
|
|
25
|
-
y = Math.max(0, y);
|
|
26
|
-
// Determine buffer based on panel type
|
|
27
|
-
let buffer = 2; // Default moderate buffer
|
|
28
|
-
if (panelId === 'command') {
|
|
29
|
-
buffer = 3; // Command panel also needs aggressive buffer to prevent scrollbar
|
|
30
|
-
}
|
|
31
|
-
else if (panelId === 'network' || panelId === 'capabilities') {
|
|
32
|
-
buffer = 3; // Right-edge panels need aggressive buffer
|
|
33
|
-
}
|
|
34
|
-
// CRITICAL: Clamp width so x+w <= safeCols-buffer
|
|
35
|
-
const maxW = Math.max(1, safeCols - buffer - x);
|
|
36
|
-
w = Math.min(w, maxW);
|
|
37
|
-
// CRITICAL: Clamp height so y+h <= safeRows-buffer
|
|
38
|
-
const maxH = Math.max(1, safeRows - buffer - y);
|
|
39
|
-
h = Math.min(h, maxH);
|
|
40
|
-
// Enforce minimums
|
|
41
|
-
w = Math.max(1, w);
|
|
42
|
-
h = Math.max(1, h);
|
|
43
|
-
return { x, y, w, h };
|
|
44
|
-
}
|
|
45
|
-
//# sourceMappingURL=clampRect.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"clampRect.js","sourceRoot":"","sources":["../../../../src/ui/v5/layout/clampRect.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AASH;;;;;;;;;;;;;GAaG;AACH,MAAM,UAAU,SAAS,CAAC,CAAO,EAAE,QAAgB,EAAE,QAAgB,EAAE,OAAgB;IACrF,IAAI,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,GAAG,CAAC,CAAC;IAEvB,4BAA4B;IAC5B,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IACnB,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAEnB,uCAAuC;IACvC,IAAI,MAAM,GAAG,CAAC,CAAC,CAAC,0BAA0B;IAC1C,IAAI,OAAO,KAAK,SAAS,EAAE,CAAC;QAC1B,MAAM,GAAG,CAAC,CAAC,CAAC,kEAAkE;IAChF,CAAC;SAAM,IAAI,OAAO,KAAK,SAAS,IAAI,OAAO,KAAK,cAAc,EAAE,CAAC;QAC/D,MAAM,GAAG,CAAC,CAAC,CAAC,2CAA2C;IACzD,CAAC;IAED,kDAAkD;IAClD,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,QAAQ,GAAG,MAAM,GAAG,CAAC,CAAC,CAAC;IAChD,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;IAEtB,mDAAmD;IACnD,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,QAAQ,GAAG,MAAM,GAAG,CAAC,CAAC,CAAC;IAChD,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;IAEtB,mBAAmB;IACnB,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IACnB,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAEnB,OAAO,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC;AACxB,CAAC"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 Layout Engine
|
|
3
|
-
*
|
|
4
|
-
* Simple + deterministic layout with normal/narrow modes.
|
|
5
|
-
*/
|
|
6
|
-
import type { Rect } from './clampRect.js';
|
|
7
|
-
export type PanelId = 'posture' | 'resources' | 'assets' | 'operations' | 'network' | 'capabilities' | 'command';
|
|
8
|
-
export type Layout = {
|
|
9
|
-
mode: 'normal' | 'narrow';
|
|
10
|
-
rects: Record<PanelId, Rect>;
|
|
11
|
-
};
|
|
12
|
-
/**
|
|
13
|
-
* Compute layout from safe viewport dimensions
|
|
14
|
-
*/
|
|
15
|
-
export declare function computeLayout(safeCols: number, safeRows: number): Layout;
|
|
16
|
-
//# sourceMappingURL=layoutEngine.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"layoutEngine.d.ts","sourceRoot":"","sources":["../../../../src/ui/v5/layout/layoutEngine.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAG3C,MAAM,MAAM,OAAO,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,GAAG,YAAY,GAAG,SAAS,GAAG,cAAc,GAAG,SAAS,CAAC;AAEjH,MAAM,MAAM,MAAM,GAAG;IACnB,IAAI,EAAE,QAAQ,GAAG,QAAQ,CAAC;IAC1B,KAAK,EAAE,MAAM,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;CAC9B,CAAC;AAKF;;GAEG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM,CA0BxE"}
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 Layout Engine
|
|
3
|
-
*
|
|
4
|
-
* Simple + deterministic layout with normal/narrow modes.
|
|
5
|
-
*/
|
|
6
|
-
import { clampRect } from './clampRect.js';
|
|
7
|
-
const CMD_HEIGHT = 5; // Increased from 3 to make command panel more visible
|
|
8
|
-
const MIN_CENTER_WIDTH = 40;
|
|
9
|
-
/**
|
|
10
|
-
* Compute layout from safe viewport dimensions
|
|
11
|
-
*/
|
|
12
|
-
export function computeLayout(safeCols, safeRows) {
|
|
13
|
-
const mainH = safeRows - CMD_HEIGHT;
|
|
14
|
-
// Compute column widths with integer math
|
|
15
|
-
const leftW = Math.max(30, Math.floor(safeCols * 0.22));
|
|
16
|
-
const rightW = Math.max(34, Math.floor(safeCols * 0.27));
|
|
17
|
-
const centerW = safeCols - leftW - rightW;
|
|
18
|
-
// Check if we need narrow mode
|
|
19
|
-
if (centerW < MIN_CENTER_WIDTH) {
|
|
20
|
-
return computeNarrowLayout(safeCols, safeRows);
|
|
21
|
-
}
|
|
22
|
-
// Normal mode - 3 columns
|
|
23
|
-
const leftX = 0;
|
|
24
|
-
const centerX = leftW;
|
|
25
|
-
const rightX = leftW + centerW;
|
|
26
|
-
// Verify right edge
|
|
27
|
-
if (rightX + rightW > safeCols) {
|
|
28
|
-
// Adjust if needed
|
|
29
|
-
const adjustedRightW = safeCols - rightX;
|
|
30
|
-
return computeNormalLayout(safeCols, safeRows, leftW, adjustedRightW);
|
|
31
|
-
}
|
|
32
|
-
return computeNormalLayout(safeCols, safeRows, leftW, rightW);
|
|
33
|
-
}
|
|
34
|
-
/**
|
|
35
|
-
* Compute normal layout (3 columns)
|
|
36
|
-
*/
|
|
37
|
-
function computeNormalLayout(safeCols, safeRows, leftW, rightW) {
|
|
38
|
-
const mainH = safeRows - CMD_HEIGHT;
|
|
39
|
-
const centerW = safeCols - leftW - rightW;
|
|
40
|
-
const leftX = 0;
|
|
41
|
-
const centerX = leftW;
|
|
42
|
-
const rightX = leftW + centerW;
|
|
43
|
-
// Left stack: posture, resources, assets split equally
|
|
44
|
-
const leftPanelH = Math.floor(mainH / 3);
|
|
45
|
-
const leftRemainder = mainH - (leftPanelH * 3);
|
|
46
|
-
// Right stack: network (50%), capabilities (remainder)
|
|
47
|
-
const netH = Math.floor(mainH * 0.5);
|
|
48
|
-
const capH = mainH - netH;
|
|
49
|
-
const rects = {
|
|
50
|
-
// Left column
|
|
51
|
-
posture: { x: leftX, y: 0, w: leftW, h: leftPanelH + (leftRemainder > 0 ? 1 : 0) },
|
|
52
|
-
resources: { x: leftX, y: leftPanelH + (leftRemainder > 0 ? 1 : 0), w: leftW, h: leftPanelH + (leftRemainder > 1 ? 1 : 0) },
|
|
53
|
-
assets: { x: leftX, y: (leftPanelH * 2) + Math.min(leftRemainder, 2), w: leftW, h: leftPanelH + (leftRemainder > 2 ? 1 : 0) },
|
|
54
|
-
// Center column
|
|
55
|
-
operations: { x: centerX, y: 0, w: centerW, h: mainH },
|
|
56
|
-
// Right column (clampRect will handle -1 buffer for borders)
|
|
57
|
-
network: { x: rightX, y: 0, w: rightW, h: netH },
|
|
58
|
-
capabilities: { x: rightX, y: netH, w: rightW, h: capH },
|
|
59
|
-
// Command line
|
|
60
|
-
command: { x: 0, y: mainH, w: safeCols, h: CMD_HEIGHT },
|
|
61
|
-
};
|
|
62
|
-
// Clamp all rects (pass panelId for context-aware clamping)
|
|
63
|
-
const clampedRects = {};
|
|
64
|
-
for (const [id, rect] of Object.entries(rects)) {
|
|
65
|
-
clampedRects[id] = clampRect(rect, safeCols, safeRows, id);
|
|
66
|
-
}
|
|
67
|
-
return {
|
|
68
|
-
mode: 'normal',
|
|
69
|
-
rects: clampedRects,
|
|
70
|
-
};
|
|
71
|
-
}
|
|
72
|
-
/**
|
|
73
|
-
* Compute narrow layout (fallback for small terminals)
|
|
74
|
-
*/
|
|
75
|
-
function computeNarrowLayout(safeCols, safeRows) {
|
|
76
|
-
const mainH = safeRows - CMD_HEIGHT;
|
|
77
|
-
// Narrow mode: single column, stack vertically
|
|
78
|
-
const panelH = Math.floor(mainH / 6);
|
|
79
|
-
const remainder = mainH - (panelH * 6);
|
|
80
|
-
const rects = {
|
|
81
|
-
posture: { x: 0, y: 0, w: safeCols, h: panelH + (remainder > 0 ? 1 : 0) },
|
|
82
|
-
resources: { x: 0, y: panelH + (remainder > 0 ? 1 : 0), w: safeCols, h: panelH + (remainder > 1 ? 1 : 0) },
|
|
83
|
-
assets: { x: 0, y: (panelH * 2) + Math.min(remainder, 2), w: safeCols, h: panelH + (remainder > 2 ? 1 : 0) },
|
|
84
|
-
operations: { x: 0, y: (panelH * 3) + Math.min(remainder, 3), w: safeCols, h: panelH + (remainder > 3 ? 1 : 0) },
|
|
85
|
-
network: { x: 0, y: (panelH * 4) + Math.min(remainder, 4), w: safeCols, h: panelH + (remainder > 4 ? 1 : 0) },
|
|
86
|
-
capabilities: { x: 0, y: (panelH * 5) + Math.min(remainder, 5), w: safeCols, h: panelH + (remainder > 5 ? 1 : 0) },
|
|
87
|
-
command: { x: 0, y: mainH, w: safeCols, h: CMD_HEIGHT },
|
|
88
|
-
};
|
|
89
|
-
// Clamp all rects (pass panelId for context-aware clamping)
|
|
90
|
-
const clampedRects = {};
|
|
91
|
-
for (const [id, rect] of Object.entries(rects)) {
|
|
92
|
-
clampedRects[id] = clampRect(rect, safeCols, safeRows, id);
|
|
93
|
-
}
|
|
94
|
-
return {
|
|
95
|
-
mode: 'narrow',
|
|
96
|
-
rects: clampedRects,
|
|
97
|
-
};
|
|
98
|
-
}
|
|
99
|
-
//# sourceMappingURL=layoutEngine.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"layoutEngine.js","sourceRoot":"","sources":["../../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/**
|
|
8
|
-
* Set the current layout version (called by kernel)
|
|
9
|
-
*/
|
|
10
|
-
export declare function setLayoutVersion(version: number): void;
|
|
11
|
-
/**
|
|
12
|
-
* Get the current layout version
|
|
13
|
-
*/
|
|
14
|
-
export declare function getLayoutVersion(): number;
|
|
15
|
-
/**
|
|
16
|
-
* Safe render - only renders if version matches
|
|
17
|
-
*/
|
|
18
|
-
export declare function safeRender(screen: any, expectedVersion: number, renderFn?: () => void): boolean;
|
|
19
|
-
//# sourceMappingURL=renderGate.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"renderGate.d.ts","sourceRoot":"","sources":["../../../src/ui/v5/renderGate.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAEtD;AAED;;GAEG;AACH,wBAAgB,gBAAgB,IAAI,MAAM,CAEzC;AAED;;GAEG;AACH,wBAAgB,UAAU,CACxB,MAAM,EAAE,GAAG,EACX,eAAe,EAAE,MAAM,EACvB,QAAQ,CAAC,EAAE,MAAM,IAAI,GACpB,OAAO,CAaT"}
|
package/dist/ui/v5/renderGate.js
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 Render Gating
|
|
3
|
-
*
|
|
4
|
-
* Prevents stale renders from async events.
|
|
5
|
-
* Any render that can happen asynchronously must be gated.
|
|
6
|
-
*/
|
|
7
|
-
let currentLayoutVersion = 0;
|
|
8
|
-
/**
|
|
9
|
-
* Set the current layout version (called by kernel)
|
|
10
|
-
*/
|
|
11
|
-
export function setLayoutVersion(version) {
|
|
12
|
-
currentLayoutVersion = version;
|
|
13
|
-
}
|
|
14
|
-
/**
|
|
15
|
-
* Get the current layout version
|
|
16
|
-
*/
|
|
17
|
-
export function getLayoutVersion() {
|
|
18
|
-
return currentLayoutVersion;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Safe render - only renders if version matches
|
|
22
|
-
*/
|
|
23
|
-
export function safeRender(screen, expectedVersion, renderFn) {
|
|
24
|
-
if (expectedVersion !== currentLayoutVersion) {
|
|
25
|
-
// Stale render - ignore
|
|
26
|
-
return false;
|
|
27
|
-
}
|
|
28
|
-
if (renderFn) {
|
|
29
|
-
renderFn();
|
|
30
|
-
}
|
|
31
|
-
else {
|
|
32
|
-
screen.render();
|
|
33
|
-
}
|
|
34
|
-
return true;
|
|
35
|
-
}
|
|
36
|
-
//# sourceMappingURL=renderGate.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"renderGate.js","sourceRoot":"","sources":["../../../src/ui/v5/renderGate.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,IAAI,oBAAoB,GAAW,CAAC,CAAC;AAErC;;GAEG;AACH,MAAM,UAAU,gBAAgB,CAAC,OAAe;IAC9C,oBAAoB,GAAG,OAAO,CAAC;AACjC,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gBAAgB;IAC9B,OAAO,oBAAoB,CAAC;AAC9B,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,UAAU,CACxB,MAAW,EACX,eAAuB,EACvB,QAAqB;IAErB,IAAI,eAAe,KAAK,oBAAoB,EAAE,CAAC;QAC7C,wBAAwB;QACxB,OAAO,KAAK,CAAC;IACf,CAAC;IAED,IAAI,QAAQ,EAAE,CAAC;QACb,QAAQ,EAAE,CAAC;IACb,CAAC;SAAM,CAAC;QACN,MAAM,CAAC,MAAM,EAAE,CAAC;IAClB,CAAC;IAED,OAAO,IAAI,CAAC;AACd,CAAC"}
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* V5 Atomic Resize Controller
|
|
3
|
-
*
|
|
4
|
-
* Debounced resize handling with atomic rebuild strategy.
|
|
5
|
-
*
|
|
6
|
-
* Strategy: rebuild children on resize (remove/destroy all, recreate fresh)
|
|
7
|
-
* This avoids "ghost borders" and duplicated panels.
|
|
8
|
-
*/
|
|
9
|
-
import type { Widgets } from 'neo-blessed';
|
|
10
|
-
import type { UIKernel } from '../kernel/kernel.js';
|
|
11
|
-
export declare class ResizeController {
|
|
12
|
-
private screen;
|
|
13
|
-
private kernel;
|
|
14
|
-
private timer;
|
|
15
|
-
private layoutVersion;
|
|
16
|
-
private lastCommitted;
|
|
17
|
-
private pending;
|
|
18
|
-
private burstCount;
|
|
19
|
-
private lastResizeTs;
|
|
20
|
-
private lastSource;
|
|
21
|
-
constructor(screen: Widgets.Screen, kernel: UIKernel);
|
|
22
|
-
/**
|
|
23
|
-
* Start listening to resize events
|
|
24
|
-
*/
|
|
25
|
-
start(): void;
|
|
26
|
-
/**
|
|
27
|
-
* Stop listening to resize events
|
|
28
|
-
*/
|
|
29
|
-
stop(): void;
|
|
30
|
-
/**
|
|
31
|
-
* Get current layout version
|
|
32
|
-
*/
|
|
33
|
-
getLayoutVersion(): number;
|
|
34
|
-
/**
|
|
35
|
-
* Get last committed size
|
|
36
|
-
*/
|
|
37
|
-
getLastCommitted(): {
|
|
38
|
-
cols: number;
|
|
39
|
-
rows: number;
|
|
40
|
-
};
|
|
41
|
-
/**
|
|
42
|
-
* Get burst count
|
|
43
|
-
*/
|
|
44
|
-
getBurstCount(): number;
|
|
45
|
-
/**
|
|
46
|
-
* Get last resize timestamp
|
|
47
|
-
*/
|
|
48
|
-
getLastResizeTs(): number;
|
|
49
|
-
/**
|
|
50
|
-
* Get last resize source
|
|
51
|
-
*/
|
|
52
|
-
getLastSource(): string;
|
|
53
|
-
/**
|
|
54
|
-
* Handle resize event (debounced)
|
|
55
|
-
*/
|
|
56
|
-
private onResizeEvent;
|
|
57
|
-
/**
|
|
58
|
-
* Commit resize (atomic)
|
|
59
|
-
*/
|
|
60
|
-
private commitResize;
|
|
61
|
-
}
|
|
62
|
-
//# sourceMappingURL=resizeController.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"resizeController.d.ts","sourceRoot":"","sources":["../../../../src/ui/v5/resize/resizeController.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAE3C,OAAO,KAAK,EAAE,QAAQ,EAAkB,MAAM,qBAAqB,CAAC;AAEpE,qBAAa,gBAAgB;IAC3B,OAAO,CAAC,MAAM,CAAiB;IAC/B,OAAO,CAAC,MAAM,CAAW;IACzB,OAAO,CAAC,KAAK,CAA+B;IAC5C,OAAO,CAAC,aAAa,CAAa;IAClC,OAAO,CAAC,aAAa,CAAwD;IAC7E,OAAO,CAAC,OAAO,CAAwD;IACvE,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,YAAY,CAAa;IACjC,OAAO,CAAC,UAAU,CAAc;gBAEpB,MAAM,EAAE,OAAO,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ;IAKpD;;OAEG;IACH,KAAK,IAAI,IAAI;IAcb;;OAEG;IACH,IAAI,IAAI,IAAI;IAeZ;;OAEG;IACH,gBAAgB,IAAI,MAAM;IAI1B;;OAEG;IACH,gBAAgB,IAAI;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE;IAIlD;;OAEG;IACH,aAAa,IAAI,MAAM;IAIvB;;OAEG;IACH,eAAe,IAAI,MAAM;IAIzB;;OAEG;IACH,aAAa,IAAI,MAAM;IAIvB;;OAEG;IACH,OAAO,CAAC,aAAa;IAgBrB;;OAEG;IACH,OAAO,CAAC,YAAY;CA4CrB"}
|