rusackas opened a new pull request, #44112:
URL: https://github.com/apache/superset/pull/44112

   ### SUMMARY
   Adds a `zebra_striping` checkbox to Table V2 (`plugin-chart-ag-grid-table`), 
part of closing the remaining Table V1/V2 feature gap tracked in #44088.
   
   Table V2's shared ag-grid wrapper (`ThemedAgGridReact`) already renders a 
subtle odd-row background unconditionally for every AG Grid instance in 
Superset, including SQL Lab's results grid, it's just much subtler than Table 
V1's overt Bootstrap-style striping, easy to miss when comparing the two side 
by side.
   
   This control lets a Table V2 chart turn that subtle background on or off, 
reusing the same shared theme token (`colorFillQuaternary`) rather than 
introducing a new color, via `ThemedAgGridReact`'s existing `themeOverrides` 
prop, scoped to this plugin so SQL Lab's grid and other consumers are 
unaffected. Default is `false` for new charts, matching V2's own default look. 
A chart migrated from V1 (via `superset migrate_viz upgrade --viz_type table`) 
gets `zebra_striping` forced on, since V1's striping was never a per-chart 
toggle, always on.
   
   ### TESTING INSTRUCTIONS
   1. Enable the `AG_GRID_TABLE_ENABLED` feature flag.
   2. Create a Table V2 chart. Under Customize > Visual formatting, toggle 
"Zebra striping" and confirm rows alternate background color when on, flat when 
off.
   3. `npx jest plugins/plugin-chart-ag-grid-table` (touches `controlPanel`, 
`transformProps`, `useColDefs`).
   4. Migrate an existing Table V1 chart (`superset migrate_viz upgrade --id 
<chart_id>`) and confirm it renders striped as V2, matching its original V1 
appearance.
   5. `pytest tests/unit_tests/migrations/viz/table_v1_v2_test.py`
   
   ### ADDITIONAL INFORMATION
   - [ ] Has associated issue:
   - [ ] Required feature flags: `AG_GRID_TABLE_ENABLED` (for the target viz 
type to render)
   - [x] Changes UI (new "Zebra striping" checkbox under Visual formatting)
   - [ ] Includes DB Migration
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to