Skip to content

Commit 5ca0339

Browse files
authored
Merge pull request #2015 from nickmelnikov82/fix-factory-empty-props
Fix empty headerOpEdges.
2 parents 693b62c + 9100c7c commit 5ca0339

File tree

3 files changed

+24
-0
lines changed

3 files changed

+24
-0
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ This project adheres to [Semantic Versioning](https://semver.org/).
44

55
## [Unreleased]
66

7+
### Fixed
8+
9+
- [#2015](https://github.com/plotly/dash/pull/2015) Fix bug [#1854](https://github.com/plotly/dash/issues/1854) in which the combination of row_selectable="single or multi" and filter_action="native" caused the JS error.
10+
711
### Changed
812

913
- [#2016](https://github.com/plotly/dash/pull/2016) Drop the 375px width from default percy_snapshot calls, keep only 1280px

components/dash-table/src/dash-table/components/EdgeFactory.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,10 @@ export default class EdgeFactory {
151151
const iNext = 0;
152152
const iTarget = hTarget.rows - 1;
153153

154+
if (!isFinite(iTarget)) {
155+
return;
156+
}
157+
154158
R.forEach(
155159
j =>
156160
!EdgeFactory.hasPrecedence(

components/dash-table/tests/selenium/test_basic_operations.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -426,3 +426,19 @@ def test_tbst023_sorted_table_delete_multiple_cells_while_selected(test, props):
426426
assert target.cell(row, col).get_text() == ""
427427

428428
assert test.get_log_errors() == []
429+
430+
431+
def test_tbst024_row_selectable_filter_action(test):
432+
app = dash.Dash(__name__)
433+
434+
app.layout = DataTable(
435+
id="test-table",
436+
row_selectable="single",
437+
filter_action="native",
438+
)
439+
440+
test.start_server(app)
441+
442+
test.wait_for_element("#test-table")
443+
444+
assert test.get_log_errors() == []

0 commit comments

Comments
 (0)