patternfly / patternfly/patternfly-react

Bug - Table - Refactor Column Management with Draggable demo

Open
#7,471 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Pinned
Dominant language
TypeScript
Stars
862
Forks
392
Avg merge
4d 8h
Merged PRs (30d)
9

Description

Describe the problem
A clear and concise description of the problem. Which components are affected?

@jenny-s51 This looks great, but there seems to be a bug with column reordering via drag & drop. If I reorder columns and then click Save, upon returning to the table, it's empty.

Originally posted by @mcarrano in https://github.com/patternfly/patternfly-react/pull/7446#pullrequestreview-986229584

@mcarrano noticed this bug upon review of #7446 ... this bug already existed in the column management draggable demo. Looks like we're using DataList's deprecated onDrag API here, along with the deprecated itemOrder prop.

In order to fix this bug, we need to refactor this demo to use DragDrop with DataList here.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the column management draggable demo and inspect its DataList usage, especially the deprecated onDrag API and itemOrder prop. Refactor it to use DragDrop with DataList, then verify that reordering columns, saving, and returning to the table preserves the columns instead of showing an empty table.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.