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

Datatable FilterDisplay as menu: Apply with 'Enter' #3655

Closed
MelihArslan opened this issue Nov 16, 2022 · 4 comments · Fixed by #3660
Closed

Datatable FilterDisplay as menu: Apply with 'Enter' #3655

MelihArslan opened this issue Nov 16, 2022 · 4 comments · Fixed by #3660
Assignees
Labels
Resolution: Workaround Issue or pull request contains a workaround. It needs to be reviewed further by Core Team Type: Enhancement Issue contains an enhancement related to a specific component. Additional functionality has been add
Milestone

Comments

@MelihArslan
Copy link

Describe the bug

Trying to apply the filter with the FilterDisplay set on 'menu' on a datatable is not possible by pressing 'enter'. The user has to manually press on the apply button. Maybe an option where the developer can choose whether the user can apply with the 'enter' key.

Reproducer

https://www.primefaces.org/primereact/datatable/filter/

PrimeReact version

8.6.1

React version

18.x

Language

ES6

Build / Runtime

Preact

Browser(s)

No response

Steps to reproduce the behavior

Can be reproduced on the official documentation page.

Expected behavior

An option where the developer can choose whether the user can apply with 'enter' (or maybe even an other key).

@MelihArslan MelihArslan added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Nov 16, 2022
@melloware melloware added Type: Enhancement Issue contains an enhancement related to a specific component. Additional functionality has been add and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Nov 16, 2022
@melloware
Copy link
Member

Just realized if you add showApplyButton={false} on your column like..

<Column showApplyButton={false} ...

IT will filter instantly rather than making you press the Apply button.

@melloware melloware added the Resolution: Workaround Issue or pull request contains a workaround. It needs to be reviewed further by Core Team label Nov 16, 2022
melloware added a commit to melloware/primereact that referenced this issue Nov 16, 2022
@melloware
Copy link
Member

I think this is the expected behavior of most users and I know I have been confused by this before too so pressing ENTER should trigger the filter.

@zotil
Copy link

zotil commented Feb 13, 2023

I just updated primereact from 8.1.1 to 8.7.3.
I am working with a DataTable, which filterDisplay is menu and showApplyButton is false. However the filter get triggered when the input changes, it doesn't wait for enter key.

@melloware
Copy link
Member

Can you open a new issue. It's not good to reopen old tickets

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Workaround Issue or pull request contains a workaround. It needs to be reviewed further by Core Team Type: Enhancement Issue contains an enhancement related to a specific component. Additional functionality has been add
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants