feat(tradein): «Росреестр» button — copy address + open EGRN request form #550
No reviewers
Labels
No labels
admin
analytics
auth
automation
bug
business
chore
ci
compliance
data
data-moat
docs
duplicate
dx
enhancement
Fable 5 ревью
feedback/max
generative
GG-форсайт
needs-discussion
needs-human
observability
pause-bots
performance
priority/p0
priority/p1
priority/p2
priority/p3
scope/backend
scope/db
scope/devops
scope/frontend
scope/qa
scrapers
security
site-finder
stage/1
stage/2
status/blocked
status/done
status/needs-analysis
status/needs-fix
status/qa
status/ready
status/review
status/wip
tech-debt
tradein
ux
week ревью 1
wontfix
вторичка
ИРД
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: lekss361/gendesign#550
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "feat/tradein-rosreestr-deeplink"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
В строках analogs (ListingsCard) и deals (DealsCard) добавлена маленькая ghost-button «Росреестр ↗». Клик:
addressв clipboard черезnavigator.clipboard.writeText()noopener,noreferrer)Дальше пользователь сам вставляет адрес в форму и заказывает выписку о переходе прав (~850 ₽) если нужна углублённая проверка конкретной квартиры.
Why
Open dataset Росреестра не отдаёт кадастровые номера — поэтому полностью автоматическая deeplink-навигация невозможна. Минимально полезный UX: одним кликом убрать ручное копирование адреса из карточки.
Changes
tradein-mvp/frontend/src/lib/rosreestr.ts— NEW,ROSREESTR_REQUEST_URL+openRosreestrWithAddress(address)(graceful если clipboard недоступен)tradein-mvp/frontend/src/components/trade-in/DealsCard.tsx— кнопка вDealRow, новая колонка в theadtradein-mvp/frontend/src/components/trade-in/ListingsCard.tsx— кнопка вAnalogRowрядом с external-link иконкойtradein-mvp/frontend/src/components/trade-in/trade-in.css—.rosreestr-btnghost-style через CSS-переменные (--border,--muted,--fg)Constraints соблюдены
AnalogLottype не трогалиRecentSoldListне затронут (RecentSoldEntryне имеетaddress)Verification
Refs: research session 2026-05-24 — PR-D из 4-PR roadmap (после PR-A в #549).
Deep Code Review — verdict APPROVE
Summary
Security — clean
ROSREESTR_REQUEST_URLis a hardcoded constant string —addressis never interpolated into the URL → no XSS, no URL-encoding needwindow.open(URL, "_blank", "noopener,noreferrer")correctly defends against tabnabbingsafeUrl(PR #512) intentionally not used here: it's for dynamic URLs from scraped data; this URL is a trusted literaladdressfromAnalogLot.addressis typed non-nullablestring, safe forclipboard.writeTextCorrectness — clean
<th />added to thead to match new<td>button column (6=6)<th />for link cell, button placed inside existing cell withwhiteSpace: nowrap— sensiblevoidprefix on asynconClickhandler is the correct TS fire-and-forget patterntry/catchis intentional graceful degradation, documented in PR bodyConventions — clean
--border,--muted,--fgall defined in trade-in.css root"use client"not needed (already in parent component)@/lib/...alias consistent with safeUrl import patternMinor / optional polish (NOT blocking)
await navigator.clipboard.writeText(...)beforewindow.open— Safari/Firefox can lose user-gesture context afterawait. Clipboard writes typically resolve in <1ms so in practice safe; if regressions surface, swap order (open first, write after) or drop theawait.catch— user has no toast/aria-live signal. Minor UX gap; punt to a future PR.aria-labelbut visible text "Росреестр ↗" is the accessible name;titleprovides tooltip. Conforms to project convention (icon-only<a>row-link usesaria-label, text buttons don't).Cross-file impact
Merging via squash.