-
Notifications
You must be signed in to change notification settings - Fork 29k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix widget in cell editor cutoff by the titlebar. #94195
Conversation
break; | ||
} | ||
} | ||
break; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bpasero here I tried to get access to the title bar DOM node in order to change its z-index later on, is there any safer way to do this? Should we expose the DOM node through IEditorGroupView.titlebarDomNode
etc?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not a big fan of changing z-index
to begin with. I am not a fan of doing this selectively based on the editor showing. Overall, -1. Please think about an alternative if possible.
The problem we are trying to fix is changing z orders of DOM nodes:
We want to make sure The other potential solution is making @bpasero the |
The context view proposal could lend itself to improving some of the issues around context views like centralizing focus handling when the menu steals focus from the editor but we don't want it to. Peng and I have discussed this alternative and thing it can be very nice though it carries some risk in that it touches more area. |
Today, content widgets are rooted in the editor's view dom node. The editor has mouse hit testing code to figure out what is logically hit when moving the mouse pointer in the editor. This is done with a mouse move/down/up listener on the editor view dom node and it can discern, using custom attributes and |
@alexdima thanks for the insights ❤️ . I'll try to summarize the challenges we need to tackle if we are going this route:
|
@sbatten and me spent another one hour on fixing this issue again as it's somehow broken, we know what we are doing now with the PR and confident with the fix. Firstly we disable Now for an editor group, title bar, nested editors, overflowing widgets inside the editors, they are all on the same plane and
Considering the fix is intuitive and straight forward to troubleshoot when it breaks, I'm going to merge this change to master. We can continue discussion around better solution proposed above later on. |
This PR attempts fix #93930. Notebook has Monaco editors inside list view which is a scrollable element, thus there are nested
position: relative; overflow: hidden;
DOM nodes, which in the end leads to the cut off of Hovers, Parameter Hints, etc to be cut off at the boundary of the Notebook Editor.@sbatten helped me figure out a workaround to fix this issue but it requires setting
z-index
on title bar. We only want thez-index
to be set only when a notebook editor is visible and focused.TODO:
z-index
on title element when notebook is focusedposition: fixed
for Hover, Parameter Hint, etc.