33 lines
4.4 KiB
Markdown
33 lines
4.4 KiB
Markdown
# Dashboard: predictions
|
|
|
|
`/dashboard/predictions` · `apps/{bull,bear}/src/app/(main)/dashboard/(creator)/predictions/page.tsx` · Type: account · Layout: [layout-dashboard-creator.md](layout-dashboard-creator.md), [layout-main.md](layout-main.md), [layout.md](layout.md)
|
|
|
|
| Field | Value |
|
|
| ----------- | ------------------------------------------------------------------------------------------------------------------------- |
|
|
| Robots | `noindex` (page `metadata`) |
|
|
| Status | `200` for every viewer: a guest is sent to login in the browser, an investor sees `AuthGuard`'s page-size no-access state |
|
|
| loading.tsx | `(creator)/predictions/loading.tsx`: `PredictionsTabSkeleton`, `delayed` |
|
|
| First flush | none |
|
|
| Canonical | none: `noindex` |
|
|
| H1 | bull: none (see the layout doc); bear: «داشبورد» in the layout |
|
|
| JSON-LD | none |
|
|
| Scripts | none beyond the layout's |
|
|
|
|
## Sections
|
|
|
|
In bull's document order. Everything sits in `AuthGuard role="creator"`, whose fallback is `PredictionsTabSkeleton`.
|
|
|
|
| Section | Data | HTML | JS | Index | Notes |
|
|
| --------------------------------------- | ------ | -------- | ----------- | ----- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
| PredictionsTab | viewer | skeleton | hydrate | no | `useQuery` for open and closed; before the first prediction, only the empty state with «سیگنال جدید» to `/compose/prediction` (J10-3c) |
|
|
| ↳ SignalPerformance | viewer | skeleton | hydrate | no | «عملکرد سیگنالها» from `GET /me/signal-stats`: four tiles, outcome split, risk to reward, progress to public; before the first nightly evaluation a message, never zeros; own `PartBoundary` and `<Suspense>` |
|
|
| ↳ PredictionSection «باز» | viewer | skeleton | hydrate | no | every open prediction as `OwnPredictionCard`; not drawn when empty; loads and fails on its own |
|
|
| ↳↳ ClosePredictionSheet | viewer | none | interaction | no | `next/dynamic`, rendered on the first «بستن زودهنگام» tap; its price poll loads with it |
|
|
| ↳ PredictionSection «بستهشدههای اخیر» | viewer | skeleton | hydrate | no | the two closed most recently; then «همه سیگنالها», an `<a href>` to `/dashboard/predictions/all` |
|
|
|
|
## Notes
|
|
|
|
- bull and bear differ only in `layout` (card and sheet placement). A card's tap opens its post.
|
|
- `/dashboard/predictions/all` is a separate page outside the `(creator)` group, under its own `OnboardingGuard` layout: [dashboard-predictions-all.md](dashboard-predictions-all.md).
|
|
- The tiles, progress and pending state are `dashboard/organisms/signal-stat-tiles`, `signal-progress` and `signal-stats-pending`, read through `useSignalStatsPart`, so «نمای کلی» can show the same numbers. Tips (`withTips`) appear only on this tab.
|