feat(python-notebook-migration, frontend): add Jupyter panel visibility surface and mini-map expand-panel button#5265
Open
zyratlo wants to merge 4 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this PR?
Adds the panel-visibility surface to
JupyterPanelService(BehaviorSubject+ four open/close/minimize methods) and the mini-map expand-panel button that drivesopenJupyterNotebookPanel.jupyter-panel.service.tsamends:BehaviorSubjectto therxjsimport.private jupyterNotebookPanelVisible = new BehaviorSubject<boolean>(false)and the publicjupyterNotebookPanelVisible$ = this.jupyterNotebookPanelVisible.asObservable().if (!this.enabled) return;-gated methods:openPanel(panelName: string)— flips visibility totruewhenpanelName === "JupyterNotebookPanel". (ThepanelNamestring is the existing convention used elsewhere in the workspace's panel system.)closeJupyterNotebookPanel()— flips visibility tofalse, thennotebookMigrationService.deleteMapping("mapping_wid_" + workflowActionService.getWorkflow().wid).minimizeJupyterNotebookPanel()— flips visibility tofalse.openJupyterNotebookPanel()— checksnotebookMigrationService.hasMapping(...); warns vianotificationService.warning("No Jupyter notebook associated with this workflow.")and returns if the workflow has no cached mapping, otherwise flips visibility totrue.init()'s subscribe handlerdeleteMappingplaceholder with the actualthis.closeJupyterNotebookPanel()callthis.openJupyterNotebookPanel()auto-open afterprecomputeHighlightMapping().jupyter-panel.service.spec.tsamends:openPanelthencloseJupyterNotebookPanelround-trips the visibility streamminimizeJupyterNotebookPanelflips tofalseopenJupyterNotebookPanelwarns when no mapping is cachedopenJupyterNotebookPanelflips totruewhen one is;openPanelonly flips for the correct panel name.when the feature flag is disableddescribe block — one per gated method — asserting the short-circuit via observable / spy checks (nonext()emission from the method itself, nodeleteMappingcall, nonotification.warning).Mini-map expand-panel button (
mini-map.component.{ts,html,scss}, ~37 lines):*ngIf="pythonNotebookMigrationEnabled"-gated button (iconexpand-alt) at the top of the mini-map's button cluster.JupyterPanelServiceandGuiConfigService; the click handler callsjupyterPanelService.openJupyterNotebookPanel(). With the flag at its defaultfalseonmain, the button doesn't render and the rest of the mini-map UI is unchanged.Any related issues, documentation, discussions?
Closes #5264
Parent issue #4301
migration-tool-mapping-highlightingfeat(python-notebook-migration): add Jupyter panel mapping highlight service #5263How was this PR tested?
jupyter-panel.service.spec.tsis amended with 5 more visibility cases and 4 more disabled-flag casesWas this PR authored or co-authored using generative AI tooling?
Generated-by: Claude Code (Claude Opus 4.7)