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

   ### SUMMARY
   
   Funnel Chart segment labels currently apply a 1px white `textBorder`, added 
by #31590 (Ant Design v5 overhaul) when the label color moved from 
`theme.colors.grayscale.dark2` to `theme.colorText`. On lighter segments the 
white outline overwhelms the thin dark text and labels are nearly illegible. 
This PR drops the `textBorder` so the theme-provided text color stands on its 
own against the segment fill.
   
   ```diff
      const defaultLabel = {
        formatter,
        show: showLabels,
        color: theme.colorText,
   -    textBorderColor: theme.colorBgBase,
   -    textBorderWidth: 1,
      };
   ```
   
   Pixel-sampled the rendered canvas to confirm the perceived "white" labels 
are actually dark text (`rgba(0,0,0,0.88)`) surrounded by a white 1px outline 
that wins the local contrast on yellow / light segments.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   
   Funnel Chart on `cleaned_sales_data` with `product_line` + `SUM(sales)`, row 
limit 10.
   
   | Before | After |
   |---|---|
   | ![before](https://files.catbox.moe/vbndk4.png) | 
![after](https://files.catbox.moe/oezj1x.png) |
   
   ### TESTING INSTRUCTIONS
   
   1. Open a Funnel Chart in Explore with a string dimension and a numeric 
metric (e.g. `product_line` + `SUM(sales)` on `cleaned_sales_data`).
   2. Configure categories that produce a mix of light- and dark-colored 
segments.
   3. Verify each segment label is readable against its background, including 
yellow / light-colored segments.
   
   Unit coverage: 
`plugins/plugin-chart-echarts/test/Funnel/transformProps.test.ts` adds a test 
asserting `defaultLabel` does not set `textBorderColor` / `textBorderWidth`.
   
   ### ADDITIONAL INFORMATION
   
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [x] Changes UI
   - [ ] Includes DB Migration (follow approval process in 
[SIP-59](https://github.com/apache/superset/issues/13351))
   - [ ] 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