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

feat(DataTable): Update DataTable to phase 2 spec #15662

Merged
merged 17 commits into from Feb 8, 2024

Conversation

tw15egan
Copy link
Member

@tw15egan tw15egan commented Jan 30, 2024

Closes #15708

Updates the DataTable with Slug to the new phase 2 styles. It also adds support for the full-column gradient.

Changelog

New

  • $ai-aura-start-table token, slightly more opaque than $ai-aura-start
  • getCellProps prop getter added to TableCell to check if a cell is in a column that has a Slug in the header
  • ai-table-gradient mixin to specify the DataTable specific gradients

Changed

  • Converted TableCell to a component, rather than using wrapComponent function
  • slug can now be provided the DataTableHeader, e.g. you would define your headers (with a slug) like so:
const columnSlugHeaders = [
  {
    key: 'name',
    header: 'Name',
  },
...
  {
    key: 'attached_groups',
    header: 'Attached groups',
    slug: MySlugComponent
  },
];

Testing / Reviewing

Go to Experiemental --> unstable__slug --> DataTable and ensure all variants match the spec. Ensure there are no regressions to the main DataTable

Copy link

netlify bot commented Jan 30, 2024

Deploy Preview for v11-carbon-react ready!

Name Link
🔨 Latest commit c939d1d
🔍 Latest deploy log https://app.netlify.com/sites/v11-carbon-react/deploys/65c4fd80e67a56000858b3f5
😎 Deploy Preview https://deploy-preview-15662--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@tw15egan tw15egan marked this pull request as ready for review February 6, 2024 19:16
@tw15egan tw15egan requested review from a team as code owners February 6, 2024 19:16
@tw15egan tw15egan changed the title feat(DataTable): start work on updating DataTable to phase 2 spec feat(DataTable): Update DataTable to phase 2 spec Feb 6, 2024
Copy link
Contributor

@guidari guidari left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 🚀

@tay1orjones
Copy link
Member

@aagonzales just need a visual pass on this one, looks good to go on the dev side

Copy link
Member

@aagonzales aagonzales left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks good! But can we move this slug over to the right in the header in the story "column slug with expansion and selection"

Also the hover colors in all the themes seems a little too intense/bright compared to the design. Would adding that extra stop in the gradient help with this?

image

Copy link
Member

@aagonzales aagonzales left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed it with TJ, looks good to go now! 🎉 ✅

@carbon-bot carbon-bot added this pull request to the merge queue Feb 8, 2024
Merged via the queue into carbon-design-system:main with commit 421dbc4 Feb 8, 2024
21 checks passed
@carbon-automation
Copy link
Contributor

Hey there! v11.50.0 was just released that references this issue/PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update React DataTable to phase 2 AI spec
6 participants