-
Notifications
You must be signed in to change notification settings - Fork 132
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
Monaco Editor In Zui #2824
Monaco Editor In Zui #2824
Conversation
"uint8", | ||
"uint16", | ||
"uint32", | ||
"uint64", | ||
"int8", | ||
"int16", | ||
"int32", | ||
"int64", | ||
"float16", | ||
"float32", | ||
"float64", | ||
"bool", | ||
"string", | ||
"duration", | ||
"time", | ||
"bytes", | ||
"ip", | ||
"net", | ||
"type", | ||
"null", |
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.
The Zed types in zed-js (e.g, TypeOfUint8) have a name property. Would it make sense to use those name properties here?
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.
Yes, that could work.
const isEnterKey = e.key === "Enter" | ||
const isModKey = e.shiftKey || cmdOrCtrl(e) | ||
if (isEnterKey) { | ||
if ((runOnEnter && !isModKey) || (!runOnEnter && isModKey)) { |
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.
Maybe simplify this?
if ((runOnEnter && !isModKey) || (!runOnEnter && isModKey)) { | |
if (runOnEnter !== isModKey) { |
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.
That's too smart for me. 😅
Replaced code mirror with Monaco. This PR includes some minimal syntax highlighting.
CleanShot.2023-07-27.at.16.52.05.mp4
Closes #2812
Closes #2762