Skip to content

UI Standard — MyHoreca Pay ​

Короткая точка входа в UI-систему. Полные правила: design-system.md, icon-system.md, ui-migration.md, ui-audit.md.

Источник правды ​

СлойПутьНазначение
Design systemfrontend/src/shared/uiTokens, theme, layout, primitives, workflow widgets, icons, domain statuses

Canonical import: @/shared/ui

Структура страницы ​

tsx
import { PageShell, PageHeader, Card, AppDataTable, LoadingState, ErrorState } from '@/shared/ui';

export default function ExamplePage() {
  return (
    <PageShell>
      <PageHeader title="…" subtitle="…" actions={…} />
      <Card title="…">
        <AppDataTable columns={…} rows={…} />
      </Card>
    </PageShell>
  );
}
  • Padding задаётся только в AppShellMain (.mainInner).
  • PageShell = PageContainer + вертикальный Stack.
  • Не создавать локальные .page-header / .btn / .data-table.

Ключевые компоненты ​

ГруппаКомпоненты
ActionsButton (primary / secondary / subtle / ghost / danger), IconButtonWithTooltip
LayoutPageShell, PageHeader, PageSection, Toolbar, FilterBar
SurfacesCard, Panel, Surface
FeedbackLoadingState, ErrorState, EmptyState, NoPermissionState
DataAppDataTable / DataTable, MoneyAmount, StatusBadge, domain *StatusBadge
WorkflowWorkflowStepper, StatusTabs, AdvancedDiagnosticsPanel, FileUploadDropzone
IconsactionIcons, domainIcons, statusIcons, navIconMap

Запрещено ​

  • Прямой import @mantine/core / @mantine/hooks вне shared/ui (ESLint).
  • Прямой import @tabler/icons-react вне shared/ui (ESLint).
  • Параллельный UI barrel (components/ui) — удалён; только @/shared/ui.
  • Icon-only для posting / allocation / delete / retry без текста.
  • Цвет как единственный носитель статуса.
  • Page-local button/table systems.

Migration rule ​

Сначала контракт в shared/ui, затем страница на контракт. Матрица: ui-migration.md.