-
Notifications
You must be signed in to change notification settings - Fork 0
APP-672 New Keyboard shortcuts #30
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
Conversation
|
Jira ticket: APP-670 MSQuill Spike |
|
@bholloway This nit change from the previous set of commits broke keyboard shortcut registration. There's no simple way to detect when this object will init, so checking on registration is the quickest fix. |
87debc7 to
4fed466
Compare
* Add mixed fraction type * Added definite integral command
bholloway
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.
Mostly nits but a couple of things I think worth blocking on
src/services/commands.js
Outdated
| var commands = options.commands || []; | ||
| var ignoredCharacters = options.ignoredCharacters || []; | ||
| // We're going to create an index for ignored character lookup | ||
| ignoredCharacters.forEach(char => this.cursor.grammarDicts.ignoredCharacters[char] = true); |
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.
nit the assignment return is generally considered confusing but it seems to be common practice in this code base
change probably best just to avoid the lambdas since they aren't used anywhere else
| var boundSymbol = binder(symbolDefinition); | ||
| var boundSymbol; | ||
| if (symbolDefinition.useInternalSymbolDef) boundSymbol = LatexCmds[symbolDefinition.name]; | ||
| else boundSymbol = binder(symbolDefinition); |
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.
opinion a ternary would make this assignment more declarative
| var latexWithoutBs = symbolDefinition.latex.replace('\\', ''); | ||
| symbols[latexWithoutBs] = boundSymbol; | ||
| } | ||
| if(symbolDefinition.htmlEntity) |
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.
nit space between if and parentheses.
0b55a02 to
a760607
Compare
bholloway
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.
I think this is good to go. Only one nit. Last call.
| var ignoredCharacters = options.ignoredCharacters || []; | ||
| // We're going to create an index for ignored character lookup | ||
| ignoredCharacters.forEach(char => this.cursor.grammarDicts.ignoredCharacters[char] = true); | ||
| ignoredCharacters.forEach(function(char) { this.cursor.grammarDicts.ignoredCharacters[char] = true }.bind(this)); |
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.
nit Complexity is growing here. I think this probably makes more sense as a for loop at this point.
BrandonNav
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.
Reviewed 1 of 2 files at r1, 2 of 6 files at r2, 4 of 4 files at r3.
Reviewable status: all files reviewed, 7 unresolved discussions (waiting on @bholloway and @kvnvelasco)
BrandonNav
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.
Dismissed @bholloway from 7 discussions.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @kvnvelasco)
This change is