gendesign/frontend/src/hooks
Light1YT 1bbc032316
All checks were successful
CI / changes (pull_request) Successful in 8s
CI / backend-tests (pull_request) Has been skipped
CI / frontend-tests (pull_request) Successful in 1m3s
CI / openapi-codegen-check (pull_request) Successful in 1m54s
fix(site-finder): show networks & connection points on Раздел 3 map (#1961)
The "Сети" section table summarised engineering networks and distances, but
users could not see those points on the map. Three root causes:

- Connection-points layer was always empty: NSPD engineering_structures
  (cat 36328) arrive as Polygon/MultiPolygon in EPSG:3857 (prod: 587 Polygon
  + 298 MultiPolygon, zero Point), but extractLatLon only handled Point in
  EPSG:4326. Extend it to compute the outer-ring centroid for
  Polygon/MultiPolygon and reproject 3857→4326 (frontend math, no backend
  change), so the 10+ connection points render as markers with popups.
- Map vs table coverage mismatch: the table counts "В 2 км" while the OSM
  utility-infrastructure layer fetched only 500 m (1 object inside 500 m vs
  153 within 2 km). Raise the hook default to a shared
  UTILITY_COVERAGE_RADIUS_M = 2000 so the map matches the table column.
- Coherence microcopy: clarify that the map shows the same networks as the
  table (2 km), plus NSPD connection points and protection zones.

Adds unit tests for extractLatLon polygon-centroid + 3857→4326 reprojection.

Refs #1961
2026-06-27 17:52:51 +05:00
..
useBestLayouts.ts feat(layouts): PDF ТЗ endpoint + BestLayoutsBlock UI (#113 PR D) (#199) 2026-05-16 09:53:05 +00:00
useConnectionPoints.ts feat(site-finder): NSPD frontend integration в LandTab (#202) (#212) 2026-05-16 11:55:31 +00:00
useCustomPois.ts fix(week-review): автофиксы код-ревью — 169 issue (label «week ревью 1») 2026-06-15 20:21:11 +05:00
useDebouncedValue.ts feat(site-finder): debounce weight re-analyze (#201 Phase 2) (#215) 2026-05-16 12:54:51 +00:00
useIsochrones.ts feat(site-finder): isochrones UI + networks VKH + OSM substations 2026-05-11 21:48:21 +03:00
useSiteAnalysis.ts fix(week-review): автофиксы код-ревью — 169 issue (label «week ревью 1») 2026-06-15 20:21:11 +05:00
useUtilityInfrastructure.ts fix(site-finder): show networks & connection points on Раздел 3 map (#1961) 2026-06-27 17:52:51 +05:00