- Admin: campaign stats panel (impressions, clicks, CTR per campaign and ad) with date range
- My posts: GET /api/v1/users/{id}/posts with paging, fallback to the legacy route
- Ad creation: retry after a failed video upload reuses the created ad; show backend 400 text
- Fullscreen ad form: only absolute http(s) target URLs
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- apiFetch: proactive refresh, cross-tab single-flight via Web Locks, no logout on transient errors
- AuthContext: save tokens returned on own login change, revoke refresh on logout, sync tabs
- Ads: X-Session-Id, impressionToken in impression/click, IAB viewability, safe http(s) targetUrl
- STOMP: refresh before CONNECT, stop reconnect loop on dead session, /user/queue/errors behind flag
- Auth form: password 8 chars / 72 bytes; 429/413 messages via describeApiError
- My posts with auth + moderation badges; post form step validation and field limits
- Map: escape user text in Yandex hint/template
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
They are imported by CreateUpdatePost.jsx and useYandexMap.js but were left
out of d3f4ae0, which broke the Docker build.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
"Написать" now looks up an existing chat for the ad (GET, never creates).
If there is none it opens /chats/new as a draft with the ad in the header;
the first send calls POST /chats/with/{userId}/messages, which creates the
chat with that message, and the page switches to /chats/{id}. Reloading
/chats/new without draft data goes back to the chat list.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The feed card showed the contact button on the user's own ads (isOwner is
false in the main feed), and the backend rejects a chat with yourself
with 400. The button is now hidden when ad.userId is the current user,
and createOrGetChat logs the backend error message.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
createOrGetChat stored the clicked card's post for the returned chat id,
even when the backend returned an existing chat about another ad. The
chat then showed the new ad's image until the next list fetch replaced
it with the real one. The backend's chat.post is now the source of truth;
card data only adds the emoji for the same ad.
Also limit the chat input to 4000 characters, matching the backend.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The infinite-scroll sentinel is visible on the first render (empty list,
loading=false) and could request page 1 before page 0 was loaded. Its
newer requestId made the page 0 response stale, so the feed showed only
the second page. Append requests are now ignored until the first page has
loaded and while a page 0 reload is in flight.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>