-
Notifications
You must be signed in to change notification settings - Fork 94
feat: data-browsing monaco core implementation VSCODE-727 #1237
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
feat: data-browsing monaco core implementation VSCODE-727 #1237
Conversation
| return 'hc-black'; | ||
| case vscode.ColorThemeKind.Dark: | ||
| default: | ||
| return 'vs-dark'; |
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.
super nit, feel free to ignore, but I'm wondering if we should just do some kind of substring checks for things like light/dark, etc
We could then at least have a test that lists all the known themes that ship with vscode, loop through them and see which one we pick:
I wonder where they store those groupings. Some metadata we have access to perhaps? Because somehow vscode itself knows to group everything under light, dark or high contrast 🤔
Anyway. Not necessary for this PR.
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.
its definitely a rabbit hole...I'd leave if for last if we have the time TBH.
| themeColors?: TokenColors; | ||
| themeKind: MonacoBaseTheme; | ||
| } | ||
| const monacoWrapperStyles = css({ |
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.
Are you sure this is necessary? I just removed it now and don't see the white boxes. Wasn't it something else that hid them?
I checked because this is just moving it to a specific spot, not seeing anything that actually hides it.
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.
for me, if I remove this, the white box flashes on first load, but then disappears...looks janky.
| }, [themeColors]); | ||
|
|
||
| useEffect(() => { | ||
| if (monaco) { |
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.
Tiniest style nit, but if the whole function body is contained inside one if I'd just if (!monaco) { return; } at the top so that the nesting is less and it is easier to read. ie. no one then has to scan to find the closing curly bracket.
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.
totally agree, will update for the next PR.
lerouxb
left a comment
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.
Good work! Let's get it in and iterate on top of it.
Description
Ticket: https://jira.mongodb.org/browse/VSCODE-727
Base Monaco readonly implementation

Checklist
Motivation and Context
Open Questions
Dependents
Types of changes