Skip to content
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(repl): add settings and prototype methods for keybindings #3331

Merged
merged 17 commits into from
Jan 17, 2025

Conversation

Snehil-Shah
Copy link
Member

@Snehil-Shah Snehil-Shah commented Dec 5, 2024

Resolves #2647.

Description

What is the purpose of this pull request?

This pull request:

  • Tried a 'not-so-boring' approach to setting keybindings, where we listen to the user's keystrokes instead of them manually having to write the desired key object.
interactive_keybinding.mp4
  • Adds settings and prototype methods to get and set keybindings.

Related Issues

Does this pull request have any related issues?

This pull request:

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

I will add keybindings for existing actions in a future PR.

Checklist

Please ensure the following tasks are completed before submitting this pull request.


@stdlib-js/reviewers

@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label Dec 5, 2024
@Snehil-Shah Snehil-Shah added REPL Issue or pull request specific to the project REPL. Feature Issue or pull request for adding a new feature. labels Dec 5, 2024
@stdlib-bot
Copy link
Contributor

stdlib-bot commented Dec 5, 2024

Coverage Report

Package Statements Branches Functions Lines
repl $\color{red}11798/14641$
$\color{green}+80.58\%$
$\color{red}664/898$
$\color{green}+73.94\%$
$\color{red}154/272$
$\color{green}+56.62\%$
$\color{red}11798/14641$
$\color{green}+80.58\%$

The above coverage report was generated for the changes in this PR.

Copy link
Member

@kgryte kgryte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this, @Snehil-Shah. This looks quite clean. My primary comment concerns allowing a user to provide a second argument to explicitly set a keybinding, rather than only having the option to enter directly.

@kgryte kgryte added Needs Changes Pull request which needs changes before being merged. and removed Needs Review A pull request which needs code review. labels Dec 13, 2024
@Snehil-Shah Snehil-Shah marked this pull request as draft January 4, 2025 09:58
@Snehil-Shah Snehil-Shah marked this pull request as ready for review January 8, 2025 14:06
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label Jan 8, 2025
@Snehil-Shah Snehil-Shah requested a review from kgryte January 8, 2025 14:06
Copy link
Member

@kgryte kgryte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is looking good. Just a couple more niggles, and I think this should be ready for merge.

@kgryte kgryte removed the Needs Review A pull request which needs code review. label Jan 14, 2025
@Snehil-Shah Snehil-Shah requested a review from kgryte January 15, 2025 11:47
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label Jan 15, 2025
Copy link
Member

@kgryte kgryte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for working on this, @Snehil-Shah!

@kgryte kgryte removed Needs Changes Pull request which needs changes before being merged. Needs Review A pull request which needs code review. labels Jan 17, 2025
@kgryte kgryte merged commit 6f85e44 into stdlib-js:develop Jan 17, 2025
29 checks passed
@kgryte kgryte mentioned this pull request Jan 17, 2025
2 tasks
saurabhraghuvanshii pushed a commit to saurabhraghuvanshii/stdlib-gs that referenced this pull request Jan 18, 2025
saurabhraghuvanshii pushed a commit to saurabhraghuvanshii/stdlib-gs that referenced this pull request Jan 19, 2025
Neerajpathak07 pushed a commit to Neerajpathak07/stdlib that referenced this pull request Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Issue or pull request for adding a new feature. REPL Issue or pull request specific to the project REPL.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[RFC]: add support for custom key bindings in the REPL
3 participants