Skip to content

Conversation

@Alan-TheGentleman
Copy link
Contributor

Context

This PR addresses multiple UI bugs and improvements identified during review. The fixes span across various components including the threat map, service watchlist, compliance filters, and pagination.

Description

Threat Map Improvements

  • Add support for all provider types (AWS, Azure, GCP, Kubernetes, M365, GitHub, IAC, OracleCloud, MongoDBAtlas)
  • Add global region support for GCP
  • Improve region filtering and global region handling
  • Fix infinite loop on hover
  • Extract threat map types and utils for better maintainability
  • Reset bar chart on region change and show global aggregated data

Service Watchlist

  • Remove icons from service watchlist for cleaner UI

Compliance Page

  • Fix Regions "Select All" behavior - now correctly shows all values as selected when no filter param exists (defaultToSelectAll)

Pagination

  • Update rows per page selector to use shadcn select component with proper design tokens

Steps to review

  1. Threat Map: Navigate to Overview and check the threat map with different providers (AWS, Azure, GCP). Verify:

    • Region filtering works correctly
    • Global region shows aggregated data
    • Hovering doesn't cause infinite loops
    • Bar chart resets on region change
  2. Service Watchlist: Check Overview page - service watchlist should not show icons

  3. Compliance Regions Filter: Go to Compliance detail page, check:

    • Regions dropdown shows all regions as selected by default
    • "Select All" toggles correctly between all/none
  4. Pagination: Check any table with pagination - rows per page dropdown should have updated styling matching the design system

Checklist

UI

  • All issue/task requirements work as expected on the UI
  • Screenshots/Video of the functionality flow (if applicable) - Mobile (X < 640px)
  • Screenshots/Video of the functionality flow (if applicable) - Table (640px > X < 1024px)
  • Screenshots/Video of the functionality flow (if applicable) - Desktop (X > 1024px)
  • Ensure new entries are added to CHANGELOG.md, if applicable.

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Add coordinate mappings for all supported providers:
- OracleCloud: 28 regions with proper coordinates
- Kubernetes: global fallback (can run anywhere)
- M365: global fallback (Microsoft datacenters)
- GitHub: global fallback
- IAC: global fallback (code scanning, no regions)
- MongoDBAtlas: global fallback (inherits from cloud provider)

The implementation includes automatic fallback to 'global'
coordinates for providers that don't have specific regional
mappings, ensuring all providers can be displayed on the map.
GCP returns 'global' as the region for certain services.
Add global coordinate (Google HQ in Mountain View, CA) to
GCP region coordinates and provider aliases to ensure GCP
data appears on the threat map.
- Change region filter to use actual region codes instead of providers
- Hide global region dots from map (no clear geographic position)
- Show global first in region dropdown
- Paint entire map red when global region is selected
- Sort regions alphabetically with global at top
Compute filtered locations inside useEffect instead of using derived
filteredLocations array. The old approach created new array references
on each render, causing the useEffect to re-run infinitely on hover.
- Extract types/constants to threat-map.types.ts (65 lines)
- Extract utility functions to threat-map.utils.ts (73 lines)
- Simplify main component with LocationDetails sub-component
- Use named d3 imports (geoPath, geoNaturalEarth1)
- Replace inline styles with Tailwind semantic color classes
- Reduce main component from 635 to ~465 lines
- Update pagination to use shadcn select component with proper design tokens
- Fix regions 'Select All' to show all values as selected when no filter param exists
@Alan-TheGentleman Alan-TheGentleman requested a review from a team as a code owner November 28, 2025 11:26
@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

Conflict Markers Resolved

All conflict markers have been successfully resolved in this pull request.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

⚠️ Changes detected in the following folders without a corresponding update to the CHANGELOG.md:

  • ui

Please add an entry to the corresponding CHANGELOG.md file to maintain a clear history of changes.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 28, 2025

🔒 Container Security Scan

Image: prowler-ui:3119133
Last scan: 2025-12-01 11:52:48 UTC

✅ No Vulnerabilities Detected

The container image passed all security checks. No known CVEs were found.

📋 Resources:

@Alan-TheGentleman Alan-TheGentleman added the no-changelog Skip including change in changelog/release notes label Dec 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component/ui no-changelog Skip including change in changelog/release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants