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

[Bug]: data table expandable prop does not work to dynamically make rows expandable #17612

Open
2 tasks done
rsimpso1 opened this issue Sep 30, 2024 · 0 comments
Open
2 tasks done
Labels

Comments

@rsimpso1
Copy link

Package

@carbon/web-components

Browser

Chrome

Package version

2.11.1

React version

18.2.0

Description

In our use case we would like only some rows to be expandable. The storybook docs mention

In case you only want to set specific rows to be expandable, be sure to set the expandable prop only on that specific component, and have its adjacent sibling directly following it.

I've tried this a few different times with and without sorting / other props we've added and I can't get it to work. Setting expandable for the entire data-table works, but then there are rows that won't have content within the expandable section which isn't what we want.

It was also pointed out by @ariellalgilmore

This looks to be a bug unfortunately. I would also expect the expandable buttons shouldn't be visible if there are no even with the expandable prop

Reproduction/example

https://stackblitz.com/edit/github-kbd9xw-xb63ek?file=index.html

Steps to reproduce

  1. Open the link
  2. View the code in index.html that is authored using the format storybook docs suggest (setting expandable on a specific row with an adjacent sibling expanded row following it)
  3. View the output that does not have one expandable row and one "normal" row.

Suggested Severity

Severity 2 = User cannot complete task, and/or no workaround within the user experience of a given component.

Application/PAL

watsonx Assistant

Code of Conduct

@sstrubberg sstrubberg moved this to 🕵️‍♀️ Triage in Design System Oct 8, 2024
@2nikhiltom 2nikhiltom added the package: @carbon/web-components @carbon/web-components label Oct 9, 2024
@alisonjoseph alisonjoseph moved this from 🕵️‍♀️ Triage to ⏱ Backlog in Design System Dec 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: ⏱ Backlog
Development

No branches or pull requests

3 participants