fix: harden gift subscription frontend after multi-agent review

- Handle expired status in GiftResult (stop polling + show FailedState)
- Add PollErrorState for balance mode poll errors (softer UX)
- Remove non-null assertions in handleSubmit (explicit narrowing)
- Wrap gift routes in ErrorBoundary
- Add pollErrorTitle/pollErrorDesc i18n keys to all 4 locales
This commit is contained in:
Fringg
2026-03-09 20:34:41 +03:00
parent 7890d480e0
commit 6ea1de2e8a
10 changed files with 299 additions and 52 deletions

View File

@@ -425,21 +425,25 @@ function App() {
<Route
path="/gift"
element={
<ProtectedRoute>
<LazyPage>
<GiftSubscription />
</LazyPage>
</ProtectedRoute>
<ErrorBoundary level="app">
<ProtectedRoute>
<LazyPage>
<GiftSubscription />
</LazyPage>
</ProtectedRoute>
</ErrorBoundary>
}
/>
<Route
path="/gift/result"
element={
<ProtectedRoute>
<LazyPage>
<GiftResult />
</LazyPage>
</ProtectedRoute>
<ErrorBoundary level="app">
<ProtectedRoute>
<LazyPage>
<GiftResult />
</LazyPage>
</ProtectedRoute>
</ErrorBoundary>
}
/>
<Route