react-data-grid icon indicating copy to clipboard operation
react-data-grid copied to clipboard

Added support for headerRowClass.

Open Agent009 opened this issue 1 year ago • 2 comments

Works similar to rowClass but gets applied on the header row.

<DataGrid ... rowClass={rowClass} headerRowClass={headerRowClass} />

Agent009 avatar Dec 13 '23 23:12 Agent009

Can we not target header row with a grid class?

<DataGrid className="custom-header" ... />
.custom-header > .rdg-header-row {
  ...
}

amanmahajan7 avatar Jan 02 '24 18:01 amanmahajan7

Can we not target header row with a grid class?

<DataGrid className="custom-header" ... />
.custom-header > .rdg-header-row {
  ...
}

Can do, but that doesn't allow for using pre-defined classes from other systems such as Tailwind. The dedicated property was added to cater for this.

Agent009 avatar Jan 04 '24 10:01 Agent009

Can you resolve the conflicts and add a test and we can merge this PR

amanmahajan7 avatar Apr 11 '25 16:04 amanmahajan7

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 98.69%. Comparing base (5a2c4d9) to head (ef73b0b). Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3405      +/-   ##
==========================================
- Coverage   98.80%   98.69%   -0.12%     
==========================================
  Files          47       47              
  Lines        3444     3451       +7     
  Branches      749      749              
==========================================
+ Hits         3403     3406       +3     
- Misses         41       45       +4     
Files with missing lines Coverage Δ
src/DataGrid.tsx 99.77% <100.00%> (+<0.01%) :arrow_up:
src/HeaderRow.tsx 100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Apr 11 '25 17:04 codecov[bot]

Thank you for the PR

amanmahajan7 avatar Apr 11 '25 18:04 amanmahajan7