carto-react icon indicating copy to clipboard operation
carto-react copied to clipboard

[RFC] Add a territory selector widget

Open efernandezleon opened this issue 1 year ago • 3 comments

Target Use Case

Many projects from PS need the functionality of filtering some layers (and widgets) based on territory (state, city, county, DMA, FSA, ...). Some examples of projects that use this feature would be Telus Insight or Radarview, where a user wants to focus the data exploration on a specific geometry that comes from a well-known territory.

Implementation Proposal

To cover this functionality, the framework C4R could provide a widget composed of a UI component to select a territory (single dropdown select or autocomplete) that uses a source to show the geometry in the map by using the Spatial Filter to filter some layers. An extra ball for business strategy could be to support directly territory geometries from the DO, like https://carto.com/spatial-data-catalog/browser/geography/cdb_block_96b823a2/ or https://carto.com/spatial-data-catalog/browser/geography/mbi_counties_46ea8aaa

Some options for this widget can be:

  • Filtered sources: list of sources to be filtered when a territory is selected
  • Show the contour: boolean to indicate if the contour of the geometry should be shown or not

efernandezleon avatar Oct 05 '22 09:10 efernandezleon