Skip to content

DataGrid: add support for RowBackground and AlternatingRowBackground#1350

Merged
pomianowski merged 1 commit intolepoco:mainfrom
chucker:feature/data-grid-row-background
Feb 17, 2025
Merged

DataGrid: add support for RowBackground and AlternatingRowBackground#1350
pomianowski merged 1 commit intolepoco:mainfrom
chucker:feature/data-grid-row-background

Conversation

@chucker
Copy link
Copy Markdown
Collaborator

@chucker chucker commented Feb 16, 2025

Add support for setting a row background, and optionally an alternating row background (e.g., alternating white/light grey stripes).

Pull request type

Please check the type of change your PR introduces:

  • Update
  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes

What is the current behavior?

Previously, the RowBackground and AlternatingRowBackground properties were effectively ignored, as the style/control template didn't evaluate them.

Issue Number: #1192 (comment)

What is the new behavior?

The properties are now taken into account.

  • if both properties are set, odd rows use RowBackground, and even rows use AlternatingRowBackground.
  • if only RowBackground is set, all rows use that
  • if neither is set, rows have a transparent background

@chucker chucker requested a review from pomianowski as a code owner February 16, 2025 21:24
@github-actions github-actions bot added controls Changes to the appearance or logic of custom controls. styles Topic is related to styles PR Pull request release labels Feb 16, 2025
@pomianowski pomianowski merged commit ef9e0c9 into lepoco:main Feb 17, 2025
2 checks passed
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 22, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

controls Changes to the appearance or logic of custom controls. PR Pull request release styles Topic is related to styles

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants