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: SelectionMode props behave weird in mobile #7396

Open
anicarrr opened this issue Nov 6, 2024 · 4 comments
Open

DataTable: SelectionMode props behave weird in mobile #7396

anicarrr opened this issue Nov 6, 2024 · 4 comments
Labels
Device: Mobile Issue or pull request is *only* related to Mobile device

Comments

@anicarrr
Copy link

anicarrr commented Nov 6, 2024

Describe the bug

When i set value "multiple" in selectionMode prop in mobile version the events onCellSelect and onCellUnselect are being triggered, in fact onCellUnselect is being triggered more than once. In case of "single" selectionMode the onCellUnselect event is not being triggered at all when a cell is unselected . In Desktop everything is fine.

Reproducer

https://codesandbox.io/p/sandbox/wmvdys

System Information

System:
    OS: macOS 14.6.1
    CPU: (12) arm64 Apple M3 Pro
    Memory: 3.17 GB / 36.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.15.0 - ~/.nvm/versions/node/v20.15.0/bin/node
    npm: 10.8.1 - ~/.nvm/versions/node/v20.15.0/bin/npm
  Browsers:
    Chrome: 130.0.6723.116
    Safari: 17.6
  npmPackages:
    primereact: ^10.8.4 => 10.8.4
    react: ^18.3.1 => 18.3.1

Steps to reproduce the behavior

  1. Go to mobile mode in codesandbox from devtool (easier from here).
  2. Click in more than one cell in the table to select them.
  3. Click in any selected cell to unselect it.

Expected behavior

  • Only one toast should be shown when a cell is unselected in mobile version with "multiple" selection mode. (show more than 1 in some cases)
  • Only one toast should be shown when a cell is unselected in mobile version with "single" selection mode. (event is not triggered at all)
@anicarrr anicarrr 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 6, 2024
@melloware
Copy link
Member

Duplicate of #7388

@melloware melloware marked this as a duplicate of #7388 Nov 6, 2024
@melloware melloware added Resolution: Duplicate Issue has already been reported or a pull request related to same issue has already been submitted 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 6, 2024
Copy link

github-actions bot commented Nov 6, 2024

This issue is a duplicate and has already been reported and possibly fixed. Please review other issues both open and closed for a similar issue to this one.

@anicarrr
Copy link
Author

anicarrr commented Nov 6, 2024

It is related to #7388 but is not the same

@melloware melloware added Device: Mobile Issue or pull request is *only* related to Mobile device and removed Resolution: Duplicate Issue has already been reported or a pull request related to same issue has already been submitted labels Nov 6, 2024
@melloware
Copy link
Member

OK I updated the ticket label.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Device: Mobile Issue or pull request is *only* related to Mobile device
Projects
None yet
Development

No branches or pull requests

2 participants