hassaansaleem28 opened a new pull request, #36847: URL: https://github.com/apache/superset/pull/36847
### SUMMARY - Restore sequential (continuous) coloring for Treemap when a numeric metric with varying values is present, while preserving categorical coloring for categorical/constant metrics. - Remove boxed label appearance and eliminate the 1px gap by default. - Ensure de-emphasized (filtered-out) nodes are muted via opacity rather than overriding their color so gradients remain visible. - Add unit tests to prevent regressions. ### BEFORE/AFTER SCREENSHOTS -- BEFORE : <img width="1197" height="472" alt="image" src="https://github.com/user-attachments/assets/5a4aa081-da11-46ee-9dcb-3a34b3086e48" /> -- AFTER : <img width="1912" height="891" alt="image" src="https://github.com/user-attachments/assets/33126169-c337-495f-b120-d7a0786dbf50" /> <img width="1914" height="1023" alt="Screenshot 2025-12-27 204635" src="https://github.com/user-attachments/assets/ffd50512-53bf-4254-9edd-6f2b59d67b5f" /> ### TESTING INSTRUCTIONS / FILES MODIFIED - [`transformProps.ts`](plugins/plugin-chart-echarts/src/Treemap/transformProps.ts) — core logic and label/de-emphasis changes - [`constants.ts`](plugins/plugin-chart-echarts/src/Treemap/constants.ts) — adjusted defaults for `BORDER_WIDTH` / `GAP_WIDTH` to remove thin gap - [`transformProps.test.ts`](plugins/plugin-chart-echarts/test/transformProps.test.ts) — new/updated tests ### What I Changed - **Behavior**: Treemap now: - Automatically uses a sequential palette via the sequential scheme registry when metric values vary (`min !== max`). - Falls back to categorical palette behavior otherwise. - Uses opacity for de-emphasis instead of forcing a text color. - **UI**: Labels no longer display a visible border/background by default, and that 1px gap. - **Typing**: Replaced `@ts-ignore` with a typed assignment for `visualMap`. - **Tests**: Added Jest tests validating `visualMap` existence for numeric-varying metric and absence for constant metrics. ### Fixes - Closes: [#36807](https://github.com/apache/superset/issues/36807) -- 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]
