DataTable: selecting text values in tablecell shows weird behavior when using tablewide row selection
See original GitHub issue1) Environment
- PrimeFaces version: PrimeFaces-7.0.RC3 on Mojarra-2.3.2 (is reproducible in the “Showcase” on the official page at the time of writing - see https://primefaces.org/showcase/ui/data/datatable/selection.xhtml)
- Does it work on the newest released PrimeFaces version? As stated above, reproducible in the showcase
- Does it work on the newest sources in GitHub? Not tested, I presume not.
- Application server + version: See Showcase
- Affected browsers: Firefox 66.0.1, Chromium 73.0.3683.75 - both on Linux Mint 19.1
2) Expected behavior
This is difficult to explain because of the 2 “selections” playing in on this, but I’ll try. I’ll differentiate between row-select (i.e. click on a row to select it) and text-select (i.e. click-and-drag the mousepointer over a portion of text).
When a DataTable is used with the row-select feature (i.e. “selection”, both single and multiple), it gets hard to text-select (i.e. click-and-drag) a cell’s content.
I’d expect, that if I text-select a value in a cell, this value is then selected - i.e. in this case both the row and the text are selected.
3) Actual behavior
When I text-select a value in a table cell, and the mouse button is released (i.e. mouseup
event) while the mouse pointer is still inside the cell, the row is row-selected, but the text is not selected anymore. If the pointer moves outside the cell (e.g. into the cell to the right of the one containing the value I’d like to text-select), then the row is not row-selected, but the cell’s content is text-selected.
4) Steps to reproduce
- Open https://www.primefaces.org/showcase/ui/data/datatable/selection.xhtml, and scroll down to table “Single with Row Click”.
- In the first row (any other shows the same behavior) push the left mouse button down, hold it
5) Sample XHTML
See https://www.primefaces.org/showcase/ui/data/datatable/selection.xhtml, Table “Single with Row Click”.
6) Sample bean
Not relevant.
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (2 by maintainers)
I reopened it
The issue still persists, but it seems I can’t reopen? @melloware shall I enter a new one?