ionik0 opened a new pull request, #45000: URL: https://github.com/apache/superset/pull/45000
### SUMMARY Fixes the South Africa Country Map rendering small and off-center with a detached fragment at the bottom (#44942). **Cause:** Natural Earth includes the Prince Edward Islands (Marion and Prince Edward Island, ~37.7°E 46.9°S, ~1,770 km south-east of the mainland) in the Western Cape polygon. The chart fits its projection to the bounding box of all features, so the islands stretched it far south: the mainland was squeezed into the top part of the chart and the islands showed as a speck at the bottom edge. **Fix:** - Reposition the islands as an inset just south of the Eastern Cape coast, level with the mainland's southern tip, and scale them 2× so they stay visible. This keeps the bounding box equal to the mainland's, and follows the existing pattern for Hawaii/Alaska, Svalbard and the Azores. The change is made in the generator notebook (so it survives regeneration) and applied to the committed `south_africa.geojson`. - Fix the hover popup for regions in the bottom third of any country map: it was flipped onto the cursor and captured the pointer, so the region fired `mouseout` and the popup flickered away (it only appeared while scrolling). The popup now has `pointer-events: none`, flips fully above the cursor, and picks above/below once per region instead of on every mouse move (which also drops a `getBoundingClientRect` call per move). ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF Before <img width="1097" height="657" alt="Screenshot 2026-10-06 062257" src="https://github.com/user-attachments/assets/e7e832b8-9536-4c15-a1ab-1974596e0cb5" /> After <img width="1132" height="661" alt="Screenshot 2026-10-06 062125" src="https://github.com/user-attachments/assets/494f62c1-f884-49f1-938a-a4fb4cdcbfaf" /> <img width="1910" height="898" alt="Screenshot 2026-10-06 062141" src="https://github.com/user-attachments/assets/10aeadcb-c476-456f-b4ff-607b2fe8bfe4" /> ### TESTING INSTRUCTIONS 1. Create a Country Map chart with **Country** = South Africa, **ISO 3166-2 Codes** = a column with `ZA-*` codes, and any metric. For example, this SQL Lab query saved as a dataset: ```sql SELECT 'ZA-WC' AS iso, 10 AS value UNION ALL SELECT 'ZA-NC', 20 UNION ALL SELECT 'ZA-EC', 30 UNION ALL SELECT 'ZA-NL', 40 UNION ALL SELECT 'ZA-FS', 50 UNION ALL SELECT 'ZA-GT', 60 UNION ALL SELECT 'ZA-MP', 70 UNION ALL SELECT 'ZA-LP', 80 UNION ALL SELECT 'ZA-NW', 90 ``` 2. The country is centered and fills the chart. The islands appear as a small inset below the Eastern Cape coast, not as a detached fragment at the bottom edge. 3. Hover over Western Cape, Eastern Cape and the islands. The popup shows steadily above the cursor (e.g. "Western Cape / 10" for the islands). Hover over northern provinces: the popup shows below the cursor as before. 4. Other countries (e.g. USA, Norway, France) render unchanged. Automated: `south_africa.geojson.test.ts` asserts the map's extent covers only the mainland and that the islands sit in the inset position. It fails on the previous data. ### ADDITIONAL INFORMATION - [x] Has associated issue: Fixes #44942 - [ ] 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]
