# Карточка перевозчика — статистика и топ маршрутов

<!-- wb-memory.v1
{
  "schemaVersion": "wb-memory.v1",
  "id": "screen.carrier-card-statistics",
  "kind": "screen",
  "title": "Карточка перевозчика — статистика и топ маршрутов",
  "lifecycle": "active",
  "authority": "canonical",
  "areaId": "area.tenders",
  "routes": [],
  "links": [],
  "sourceRefs": [
    {
      "id": "S1",
      "kind": "figma",
      "authority": "evidence",
      "url": "https://www.figma.com/design/uBXBG2wjFRy2xcewiEwZnT/%D0%90%D0%B4%D0%BC%D0%B8%D0%BD%D0%B8%D1%81%D1%82%D1%80%D0%B8%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5?node-id=2193-47477",
      "status": "verified"
    },
    {
      "id": "S2",
      "kind": "spec",
      "authority": "canonical",
      "path": "specs/ux/areas/tenders.md",
      "status": "verified"
    }
  ]
}
-->

## Readiness

| Dimension | Status and evidence |
| --- | --- |
| Specification | This record covers the authored compact «Топ маршрутов» table and the currently authorized, but still pending, route-type tab correction. It does not claim an implemented product behavior. [S1] [S2] |
| Figma | The table is authored and was verified on 2026-09-24. The requested tab row and its three-row «Магистраль» filtered state remain planned until a new Figma write and fresh readback verify them. The two existing baseline cards remain outside the correction; no «СГТ» card is added. [S1] |
| Local prototype | No Angular implementation, API, persistence, navigation, or responsive work is in scope. |
| Verification | The authored table passed its identity, structure, screenshot, token, component-manifest, and root-scoped audit checks on 2026-09-24. Equivalent evidence for the pending tabs correction is still required. Project Memory remote preflight timed out externally, so the tracked sources are the documented fallback for this run. [S1] [S2] |

## Purpose

Give a logistics operator one factual, desktop-only view of the carrier's most
active routes. The table lives beneath the existing statistic cards and uses the
same date range already present in the screen shell. It is intentionally a
static Figma fixture, not a production report.

## Source and Route

- Destination: Figma file `uBXBG2wjFRy2xcewiEwZnT`, page `2185:17610`
  («↳ LUU-430 Правки в карточке перевозчика»), baseline frame `2193:47477`
  («Карточка перевозчика / Статистика»).
- The authored `top-routes` mount remains below the existing `stats` section.
  It contains the heading and visible table. Its table instance uses local
  `_table`, `_table-header`, and `_table-row` masters kept in a separate hidden
  run-owned shelf because the existing screen slot cannot contain component
  masters. The pending `Tabs_horiz_row` instance will be inserted between the
  heading and table.
- Preserve the existing Safari header, Sidebar, Header widget, Filter-row,
  «Магистраль» card, and «Последняя миля» card. Do not create, remove, or
  revise a «СГТ» card.
- Do not add a Rating tab, Finance content, Autopark content, a map, a
  lateness metric, percentage metrics, or a new date-range control. The one
  permitted route-type control is the canonical published `Tabs_horiz_row`
  with `Underline=on`; do not add a second, custom, redrawn, or detached tab
  control.

## Primary Scenario

1. A logistics operator opens the existing carrier-card Statistics frame.
2. The existing period controls provide the intended 7/14-day context; this
   narrow addition does not change them.
3. In the planned tab correction, the operator will see the static
   `Tabs_horiz_row`: «Магистраль» selected and «Последняя миля» default. This
   will be a visual Figma state, not an interactive prototype.
4. The authored bottom «Топ маршрутов» table currently preserves its five-row
   fixture. The planned tab correction narrows that fixture to the three
   visible «Магистраль» routes, without changing data or behavior.

## States, Errors, and Edge Cases

- The authored table is a populated, finite five-row fixture. The planned
  `Магистраль` tab state will hide two existing «Последняя миля» row instances
  rather than deleting them; the plain-text `Тип перевозки` column remains
  visible.
- The published tab row retains its eight nested slots. Exactly two slots are
  visible, with exactly one selected: «Магистраль» selected and «Последняя
  миля» default.
- Empty, loading, network-error, permission, unknown-route, and route-link
  failure states are intentionally not designed here because no live data or
  interaction contract is authorized.
- Tab activation, panel switching, keyboard behavior, navigation, and Angular
  state are intentionally not prototyped on this screen.
- When the tabs correction is authored, the content frame must grow through its
  vertical Hug layout from the recorded 500px baseline. No baseline Sidebar/Web
  node or card is manually resized, removed, or recreated.

## Table content and fixtures

The heading is «Топ маршрутов». The authored table has five visible rows and no
visible pagination, sorting, selection, expansion, actions, or loading state.
The planned fixed «Магистраль» tab state will hide two existing «Последняя миля»
row instances rather than removing them. The plain-text `Тип перевозки` column
remains so that the scope is explicit in every visible row.

| Маршрут | Тип перевозки | Выполнено заданий | По нормативу | Доп. заявки |
| --- | --- | ---: | ---: | ---: |
| Москва — Санкт-Петербург | Магистраль | 42 | 36 | 6 |
| Казань — Москва | Магистраль | 37 | 29 | 8 |
| Екатеринбург — Челябинск | Магистраль | 28 | 20 | 8 |

- `Маршрут` uses the published Table Cell/Link visual treatment; its destination
  is intentionally not implemented in the fixture.
- `Тип перевозки` is plain text. Counts use published right-aligned Number
  cells because the headers establish their quantitative unit.
- The existing Statistics date filter governs the intended 7/14-day context.
  The fixture does not calculate, fetch, sort, or persist values.
- A table without pagination is deliberate: it is a finite, static three-row
  Figma illustration. Empty, loading, and error states remain open product
  questions rather than invented states.

## Components and Accessibility

- The authored table uses `component.table-composition-simple` with the
  required `table-wrapper`, `table-header-row`, `table-header`, and `table-row`
  contracts.
- The pending correction must use the published `Tabs_horiz_row` for the sole
  route-type tab row:
  `component.tab-horiz-row`, `Underline=on`, component key
  `86f7e3cb6d34f19068a0ae21f56525474eb8eb9b`. The published instance has eight
  nested slots; only the two visible labels are configured here, with one
  selected. This screen-local Figma state does not create a prototype, tab
  panel, or Angular behavior.
- Use published Table Header, Table Cell/Link, Table Cell/Text, and Table
  Cell/Number instances; do not redraw cells or detach remote instances.
- Keep header/body column order and widths identical. The table stays within
  the 1316px content width, so no horizontal Scroll Container is added.
- The local body-row master has an opaque `bg/level 1 base` fill and only a 1px
  `stroke/secondary` bottom border. Header and row direct cells are top-aligned.
- Use the existing token system: `bg/level 1 base`, `stroke/secondary`, and the
  current 4/8px spacing scale. The outer table section starts 24px after the
  statistics cards, with 16px internal table framing and 8px table-internal
  grouping.

- The table heading and all five column names remain visible text; numerical
  meaning does not rely on alignment or colour alone.
- The fixture keeps full, unabridged header labels. Route names remain readable
  link text even though their navigation is intentionally not wired.
- No selection or sortable affordance is shown, so no hidden interaction is
  implied by the static screen.

## Data and integration boundary

All names and numbers above are Figma fixtures. Live top-route ranking,
period calculation, filters, user permissions, navigation, fetching, error
handling, and persistence require a separate product and Angular/API task.

## Related flows

This is an in-screen statistics view only. No cross-screen flow or route is
created in LUU-430.

## Figma evidence and rollback

The table has authoring and readback evidence in run
`20260924-1839-luu-430-carrier-card-statistics-top-routes`. The tab and
filtered-row correction is planned and has no authoring or readback evidence
yet. After it succeeds, the trace must preserve the recorded off-canvas
run-owned master root and target-side mount rather than treating the existing
`2193:47477` baseline as run-owned. Rollback removes only the run-owned mount
and master Section; the baseline returns through Hug layout to its prior 500px
height without changing pre-existing nodes.

## Open questions

- What should connect a future production tab selection to live values,
  empty/loading/error states, and route-navigation behavior?
