Skip to content

feat(data-grid): create data-grid component - #8296

Merged
nineteen88 merged 1 commit into
masterfrom
data-grid-v1-rc
Dec 4, 2026
Merged

nineteen88 merged 1 commit into
masterfrom
data-grid-v1-rc

Conversation

@nineteen88

@nineteen88 nineteen88 commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Proposed behaviour

Creation of the DataGrid component for accessible, editable, structured data-entry workflows.

The component:

  • supports text, dropdown, checkbox, read-only and custom action cells
  • uses controlled row data through rows and onRowsChange
  • supports synchronous row-change interception; onBeforeRowChange to approve, transform or discard changes before onRowsChange
  • provides ARIA grid semantics and roving keyboard focus
  • supports arrow, Home, End, Ctrl+Home, Ctrl+End and optional Tab navigation, allowing Tab to leave the grid at its boundaries
  • provides separate navigation and editing modes
  • accepts controlled cell errors for text and dropdown cells, with consumer-owned validation and external error-summary integration
  • supports pinned columns and sticky headers
  • virtualises larger row collections
  • exposes imperative APIs for focusing and editing cells
  • provides row transaction APIs for adding, inserting, duplicating, deleting and moving rows
  • integrates Carbon Select and ActionPopover components
  • includes Data Grid context handling for popover positioning and focus restoration
  • preserves editor drafts and cursor position across virtualisation
  • avoids re-rendering unrelated rows while typing
  • supports touch activation, IME input and localised control labels
  • includes Storybook documentation, examples, playground and Data API guidance
  • includes Jest, Playwright, interaction and visual-regression coverage
  • adds authored Data Grid skill metadata and generates a complete API reference covering the column schema, cell parameters, row-change events, row-operation API and imperative handle.
  • extends the skill generator to support explicitly selected public API types and their local supporting declarations.

Known issues

  • when using VoiceOver on iOS, a user is currently unable to open the ActionPopover (a follow up ticket will be created to address this as it's a live issue with ActionPopover currently)
  • when using VoiceOver on iOS, if a user tries to navigate out of the ActionPopover they are unable to do so (this issue was resolved by fix: ensure popover based components are accessible by voiceover controls #8304)
  • when on a touch device, if a user tries to drag the data-grid horizontally and a Select Dropdown is open. If they swipe over the Dropdown, their touch will be intercepted by that component and appear like you can't navigate the data-grid (to be investigated, potentially not a bug but a slight usability consideration)

Checklist

  • Commits follow our style guide
  • Related issues linked in commit messages if required
  • Screenshots are included in the PR if useful
  • All themes are supported if required
  • Unit tests added or updated if required
  • Playwright automation tests added or updated if required
  • Storybook added or updated if required
  • Translations added or updated if required — no new fixed translatable strings are introduced
  • Typescript d.ts file added or updated if required — public TypeScript types are included in the component source
  • Related docs have been updated if required

QA

  • Tested in provided StackBlitz sandbox/Storybook
  • Add new Playwright test coverage if required
  • Carbon implementation matches Design System/designs
  • UI Tests GitHub check reviewed if required

Additional context

This PR supersedes the earlier Data Grid prototype PR: #8275

The previous PR was used to explore the component architecture and interaction model. This replacement presents the consolidated v1 release candidate as a single reviewable change.

Some example stories include application-level behaviours such as calculated values, error summaries and row actions. These demonstrate how consumers can use the Data Grid APIs; they are not built-in business rules.

The generated Data Grid skill includes the complete v1 schema and public API, allowing agents to understand and configure the component without duplicating source-derived type information in authored metadata.

No Storybook examples are currently curated into the skill. Existing Data Grid stories rely on local helpers that the current generator cannot yet include as standalone consumer examples. Incomplete snippets have therefore been omitted intentionally.

A follow-up generator improvement will support dependency-complete examples and allow comprehensive playground stories to provide capability context alongside focused recipes for validation and row action menus.

Testing instructions

Open the Data Grid documentation in Storybook and review the following:

  1. Use the playground to edit text and dropdown cells and toggle checkboxes.
  2. Confirm a single click focuses a text cell and opens a dropdown cell.
  3. Navigate between cells with the arrow keys.
  4. Confirm:
    • Home moves to the first cell in the current row.
    • End moves to the last cell in the current row.
    • Ctrl+Home moves to the first cell in the grid.
    • Ctrl+End moves to the last cell in the grid.
  5. Enable Tab navigation and confirm Tab and Shift+Tab move between cells.
  6. Confirm Enter, Space and Escape operate dropdown, checkbox and action cells as documented.
  7. Review validation and error-summary focus behaviour.
  8. Review the pinned-column examples, including multiple columns pinned on both sides.
  9. Confirm pinned columns and sticky headers remain opaque while scrolling.
  10. Open row action popovers and confirm:
    • the trigger remains the small size
    • menu items use medium spacing
    • only one popover opens at a time
    • clicking another cell dismisses the popover and retains focus on that cell
    • popovers are not clipped by the grid or sticky columns
  11. Review the large-data example and confirm rows virtualise correctly while navigating and scrolling.
  12. Check the examples in each supported theme.

This comment was marked as resolved.

edleeks87

This comment was marked as resolved.

This comment was marked as resolved.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I've added a very simple/basic test story for now to ensure pagination is possible, but not exposing it publicly as it's out of scope at present

@nineteen88
nineteen88 force-pushed the data-grid-v1-rc branch 3 times, most recently from 67b79e2 to d3d04ef Compare November 19, 2026 18:01
@nineteen88
nineteen88 requested a balanced review from Copilot November 19, 2026 18:37

This comment was marked as resolved.

This comment was marked as resolved.

tomdavies73

This comment was marked as resolved.

This comment was marked as resolved.

tomdavies73
tomdavies73 previously approved these changes Nov 23, 2026
edleeks87
edleeks87 previously approved these changes Nov 23, 2026
@ljemmo

This comment was marked as resolved.

This comment was marked as outdated.

tomdavies73
tomdavies73 previously approved these changes Dec 1, 2026

This comment was marked as resolved.

edleeks87
edleeks87 previously approved these changes Dec 2, 2026
edleeks87
edleeks87 previously approved these changes Dec 4, 2026
tomdavies73
tomdavies73 previously approved these changes Dec 4, 2026
Add an accessible, editable data grid for structured data-entry
workflows.

- support text, dropdown, checkbox, read-only and action cells
- provide keyboard navigation, editing and ARIA grid semantics
- support pinned columns, sticky headers and row virtualisation
- expose controlled row updates and imperative cell focus/edit APIs
- integrate Carbon Select and ActionPopover
- support validation states and external error summaries
- add row add, insert, duplicate, delete and reorder examples
- provide playground, usage guidance and data API documentation
- add comprehensive Jest, Playwright and visual regression coverage
@nineteen88
nineteen88 merged commit e5646d8 into master Dec 4, 2026
58 checks passed
@nineteen88
nineteen88 deleted the data-grid-v1-rc branch December 4, 2026 14:53
@carbonci

carbonci commented Dec 4, 2026

Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 164.4.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Development

Successfully merging this pull request may close these issues.

7 participants