Skip to content

Conversation

@JMarkin
Copy link
Contributor

@JMarkin JMarkin commented Nov 24, 2022

Resolves #168.

Hello, I tried add desc and popup menu for keymaps.

@JMarkin JMarkin marked this pull request as draft November 24, 2022 14:30
@sindrets
Copy link
Owner

Thanks for the PR!

I see that you're using the Nui library here. I would like to avoid relying on additional dependencies. Especially for something as simple as creating a buffer in a floating window. That, and we already have a Panel abstraction that allows us to do this quite easily. For an example, see i.e. the commit log panel.

The way you have changed the structure of the keymap declerations in the config will unnecessarily break compatibility with vim command maps.

Also, please do not format parts of the code that you didn't touch. It makes it harder to review the changes.

Let me know if you have any questions about implementation :)

@JMarkin
Copy link
Contributor Author

JMarkin commented Nov 24, 2022

@sindrets Thanks for your review. I rewrote by your comment.

I tried to create runnable command in list, but I didn't. Before ready for merge I want to complete this feature. Can you give me a tip how to run command for current panel(not help panel), if you know ? If you think this feature is overrate, I will remove it.

@sindrets
Copy link
Owner

I tried to create runnable command in list, but I didn't.

I don't understand what that is. Can you please elaborate?

@JMarkin
Copy link
Contributor Author

JMarkin commented Nov 25, 2022

@sindrets It's like. I have menu -> press "enter" -> command under cursor would be apply.
image

@JMarkin JMarkin marked this pull request as ready for review November 25, 2022 09:48
@JMarkin
Copy link
Contributor Author

JMarkin commented Nov 25, 2022

I did it, Please review)

Copy link
Owner

@sindrets sindrets left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution! I refactored it a little bit.

@sindrets sindrets changed the title feat(help menu): add desc and help menu popup feat(help): Help panel popup Nov 27, 2022
@sindrets sindrets merged commit 3f3d7a3 into sindrets:main Nov 27, 2022
@danielo515
Copy link

Awesome! This is fantastic

@danielo515
Copy link

This is awesome, but will it be possible to add a little annotation at the top of the window about how to open the help pane? I think it is not obvious for everybody.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] action to view current keybinds

3 participants