rusackas opened a new pull request, #43917: URL: https://github.com/apache/superset/pull/43917
### SUMMARY Column headers (`<thead>`) and row totals (`.pvtRowTotals`) already stick via CSS, but the row-label column and the corner cell(s) above it did not, so on wide/tall pivot tables they scrolled out of view while the header and totals row stayed put. This adds `position: sticky; left: 0` to `.pvtRowLabel` cells, plus a combined top+left sticky rule (with a higher z-index so it wins over the row-label column at the intersection) for the corner cell(s): the placeholder cell spanning the column-attribute rows, and the row-attribute name cell(s) in the final header row. Both are gated by the existing `isDashboardEditMode` flag, same as the pre-existing sticky rules. This is scoped to single-level row headers (a fixed `left: 0` offset). Multi-level row headers (more than one row dimension) need a per-column inline `left` style computed in `TableRenderers.tsx`, which is a reasonable fast-follow rather than something that should block this fix, per the discussion on #43352. ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF N/A (CSS-only change to an existing scroll behavior; see testing instructions to verify visually). ### TESTING INSTRUCTIONS 1. Added `plugins/plugin-chart-pivot-table/test/react-pivottable/Styles.test.tsx`, which renders a pivot table and asserts (via `getComputedStyle`) that `.pvtRowLabel` and the corner header cell(s) are `position: sticky` with the expected offsets and z-index ordering, and that this is suppressed in dashboard edit mode. This test fails against the pre-fix `Styles.ts` and passes with the fix. 2. Manually: create a Pivot Table chart with enough rows/columns to require scrolling in both directions, and confirm the row-label column and the corner cell stay pinned to the left/top while scrolling. ``` npm run test -- plugins/plugin-chart-pivot-table/test/react-pivottable/Styles.test.tsx ``` ### ADDITIONAL INFORMATION - [x] Has associated issue: Fixes #43352 - [ ] Required feature flags: - [x] Changes UI - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351)) - [ ] Migration is atomic, supports rollback & is backwards-compatible - [ ] Confirm DB migration upgrade and downgrade tested - [ ] Runtime estimates and downtime expectations provided - [ ] 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]
