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

unblock-diaog not taking registering "Enter" keypress to trigger unblock functionality #103

Closed
itSarthak opened this issue Sep 25, 2024 · 7 comments
Labels
feature request new feature help wanted Extra attention is needed relevant Important

Comments

@itSarthak
Copy link
Contributor

I am a long time user of this extension and I absolutely love because it just works. But the problem I face daily is when I have to unblock a site for a while. In unblock-dialog, after setting the time I want the site to be unblocked, I press enter but it doesn't do anything which is frustrating because it's very common for applications to register enter event.

Your environment

  • Ubuntu 24.04.01 LTS
  • version of the extension: 2.8.1
  • Mozilla Firefox 130.0.1

Steps to reproduce

  1. Blacklist a site, you can try blacklisting youtube.com
  2. Open youtube.com
  3. You will be greeted with the Blocked Page
    image
  4. Click UNBLOCK button and then this window will popup. Choose any option.
    image
  5. Press ENTER, nothing happens

Expected behaviour

ENTER keyword should trigger the unblock functionality. Whatever option was selected and the value from radiogroup should be saved and unblock-dialog should close down

Actual behaviour

Currently, nothing of that sort happens because there's no onKeyDown event added in RadioGroup currently.

@AXeL-dev
Copy link
Owner

Hello @itSarthak,

Thank you for taking the time to submit the feature request. I do agree that the keyboard accessibility is missing in many parts of the extension, i'll try to find some time to implement it or maybe if any contributor is interested into working on it, that would be helpful.

I will let you know in case i have some news. Thanks again.

@AXeL-dev AXeL-dev added help wanted Extra attention is needed relevant Important feature request new feature labels Sep 25, 2024
@itSarthak
Copy link
Contributor Author

itSarthak commented Sep 25, 2024

Hey @AXeL-dev ,
Glad to hear your response on this and I would like to work on this functionality. I think all we have to do is to add an onKeyDown event listener for ENTER key? Why don't I try submitting a pr for this issue, it will only be 3 lines at max.

@AXeL-dev
Copy link
Owner

Hey @AXeL-dev , Glad to hear your response on this and I would like to work on this functionality. I think all we have to do is to add an onKeyDown event listener for ENTER key? Why don't I try submitting a pr for this issue, it will only be 3 lines at max.

Alright, that's pretty cool, your PR looks good to me, i'll merge it & test it before creating a new release.

AXeL-dev added a commit that referenced this issue Sep 25, 2024
AXeL-dev added a commit that referenced this issue Sep 25, 2024
@AXeL-dev
Copy link
Owner

AXeL-dev commented Sep 25, 2024

@itSarthak After testing i noticed that the onKeyDown event was not called, and this is likely due to the fact that it is only registered on the RadioGroup component, so i simply moved it to the dialog container props and now everything seems to work as expected.

The fix is now deployed in version 2.8.2, let me know once you test it & thank you for your valuable contribution! 🎉

@itSarthak
Copy link
Contributor Author

@AXeL-dev Your response is really appreciated. I can see why it happened, please accept my apologies for not testing it thoroughly. I am still new to open source and figuring out my way into it.
I tested the functionality and it is working like a charm, thank you so much for making time to fix it.

@AXeL-dev
Copy link
Owner

@AXeL-dev Your response is really appreciated. I can see why it happened, please accept my apologies for not testing it thoroughly. I am still new to open source and figuring out my way into it.

That's okay, you don't have to worry about it, you did a great job all the way through.

I tested the functionality and it is working like a charm, thank you so much for making time to fix it.

Absolutely welcome, and i wanna thank you back for your contribution, it's quite rare to find people interested in contributing to the project, the most of people just make feature or bug requests and later they may complain if their requests are not yet resolved, so yeah it was a pleasure to see your contribution and good luck for the rest.

@itSarthak
Copy link
Contributor Author

I am a long time user of this extension and it was really motivating to work on something I use daily. Thank you for such nice words, I will be looking forwards for the upcoming features.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request new feature help wanted Extra attention is needed relevant Important
Projects
None yet
Development

No branches or pull requests

2 participants