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

sort table together with expanded table not working( dont show sortable headers) #11178

Closed
2 tasks done
PabloAznarez opened this issue Nov 30, 2023 · 0 comments · Fixed by #11416
Closed
2 tasks done
Assignees
Labels
bug Something isn't working dev Needs some dev work package: carbon web components

Comments

@PabloAznarez
Copy link

PabloAznarez commented Nov 30, 2023

Description

sort table together with expanded table not working dont show sortable headers

Component(s) impacted

<cds-table expandable is-sortable> </cds-table>

Browser

No response

Carbon for IBM.com version

2.0.1

Severity

Severity 1 = The design is broken in a critical way that blocks users from completing tasks or damages the brand. Affects major functionality, no workaround.

Application/website

not public

Package

@carbon/ibmdotcom-web-components

CodeSandbox example

https://codesandbox.io/p/devbox/crazy-joana-7xd9xp?file=%2Findex.html%3A59%2C17

Steps to reproduce the issue (if applicable)

No response

Release date (if applicable)

No response

Code of Conduct

@PabloAznarez PabloAznarez added bug Something isn't working dev Needs some dev work labels Nov 30, 2023
@kennylam kennylam moved this to Backlog in Carbon for IBM.com Dec 4, 2023
@sangeethababu9223 sangeethababu9223 self-assigned this Jan 18, 2024
@sangeethababu9223 sangeethababu9223 moved this from Backlog to Doing in Carbon for IBM.com Jan 18, 2024
@sangeethababu9223 sangeethababu9223 moved this from Doing to Review in Carbon for IBM.com Jan 19, 2024
@kodiakhq kodiakhq bot closed this as completed in #11416 Feb 2, 2024
kodiakhq bot pushed a commit that referenced this issue Feb 2, 2024
### Related Ticket(s)

Closes #11178 #11481

### Description

Sorting and Expansion option works individually, but sorting is not working when used along with expansion option in Data Table. 
Checking for `is-sortable` attribute during initial load seems to fix this issue.

Selection option is enabled for Data table by default without adding the is-selectable attribute to the table element.

### Changelog

**New**

- A function to handle the sorting action is added.

**Changed**

- `is-sortable` attribute was being checked only for changeAttribute cases, this is updated to check on initial load too. 
- Added a condition to check if is-selectable attribute is added to the Data table component

<!-- React and Web Component deploy previews are enabled by default. -->
<!-- To enable additional available deploy previews, apply the following -->
<!-- labels for the corresponding package: -->
<!-- *** "test: e2e": Codesandbox examples and e2e integration tests -->
<!-- *** "package: services": Services -->
<!-- *** "package: utilities": Utilities -->
<!-- *** "RTL": React / Web Components (RTL) -->
<!-- *** "feature flag": React / Web Components (experimental) -->
@github-project-automation github-project-automation bot moved this from Review to Done in Carbon for IBM.com Feb 2, 2024
kennylam pushed a commit to kennylam/carbon-for-ibm-dotcom that referenced this issue Mar 12, 2024
…design-system#11416)

Closes carbon-design-system#11178 carbon-design-system#11481

Sorting and Expansion option works individually, but sorting is not working when used along with expansion option in Data Table.
Checking for `is-sortable` attribute during initial load seems to fix this issue.

Selection option is enabled for Data table by default without adding the is-selectable attribute to the table element.

**New**

- A function to handle the sorting action is added.

**Changed**

- `is-sortable` attribute was being checked only for changeAttribute cases, this is updated to check on initial load too.
- Added a condition to check if is-selectable attribute is added to the Data table component

<!-- React and Web Component deploy previews are enabled by default. -->
<!-- To enable additional available deploy previews, apply the following -->
<!-- labels for the corresponding package: -->
<!-- *** "test: e2e": Codesandbox examples and e2e integration tests -->
<!-- *** "package: services": Services -->
<!-- *** "package: utilities": Utilities -->
<!-- *** "RTL": React / Web Components (RTL) -->
<!-- *** "feature flag": React / Web Components (experimental) -->
kennylam pushed a commit to kennylam/carbon-for-ibm-dotcom that referenced this issue Jun 11, 2024
…design-system#11416)

### Related Ticket(s)

Closes carbon-design-system#11178 carbon-design-system#11481

### Description

Sorting and Expansion option works individually, but sorting is not working when used along with expansion option in Data Table. 
Checking for `is-sortable` attribute during initial load seems to fix this issue.

Selection option is enabled for Data table by default without adding the is-selectable attribute to the table element.

### Changelog

**New**

- A function to handle the sorting action is added.

**Changed**

- `is-sortable` attribute was being checked only for changeAttribute cases, this is updated to check on initial load too. 
- Added a condition to check if is-selectable attribute is added to the Data table component

<!-- React and Web Component deploy previews are enabled by default. -->
<!-- To enable additional available deploy previews, apply the following -->
<!-- labels for the corresponding package: -->
<!-- *** "test: e2e": Codesandbox examples and e2e integration tests -->
<!-- *** "package: services": Services -->
<!-- *** "package: utilities": Utilities -->
<!-- *** "RTL": React / Web Components (RTL) -->
<!-- *** "feature flag": React / Web Components (experimental) -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working dev Needs some dev work package: carbon web components
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants