MotirBuilding in public
MOTIR · moooon
onMotir
You’re viewing a public project. Anyone can view it — no account needed. Sign in to submit, upvote, or comment on requests.View-only — you can’t edit work items
MOTIR-144

2.7.4 The type/executor picker UI (create modal + detail rail) + per-type hue tokens

Done
Description

Estimate: 65m · Depends on: 2.7.1, 2.7.3

Build the picker EXACTLY as 2.7.1 specifies, on the two existing surfaces — the issue create modal and the detail rail. This is the human-facing half of the field: choosing a type, seeing the executor seeded from the default map, overriding it, and reading/editing both on the detail.

Per-type hue tokens. Add the per-type colour tier to app/globals.css--el-type-{code,design,test,content,research,review,decision,deploy,manual,chore} mapped to Tier-0 palette values (the per-component --el-* growth pattern, notes.html #20; mirror the existing --el-type-{epic,story,task,bug,subtask} kind hues). AA contrast: hue in the chip BACKGROUND with --el-text-strong text (finding #35), never a page-level tint.

Create modal. Add the type picker (a Combobox/DropdownMenu of the ten hued members) — RENDERED ONLY when the selected kind is a leaf (task/subtask/bug), absent for epic/story. On selecting a type, SEED executor via the 2.7.3 defaultExecutorForType helper (single source — the UI does NOT re-state the map) into the adjacent executor control (a segmented coding_agent | human control), still overridable. type may be left unset (null).

Detail rail. Render the type chip (hued via --el-type-*, IssueTypeIcon-adjacent) + a compact executor indicator (agent vs person glyph), both inline-editable via the same picker. A leaf with type = null shows the "set a type" affordance; an epic/story shows NO type control.

4-layer + a11y. The picker is a client component that calls the 2.7.3-backed create/update endpoints (through services — never the repository/Prisma directly). References ONLY --el-* colour + [data-display-style] shape tokens (no Tier-0 utilities — the motir-core/CLAUDE.md colour/shape rules). Keyboard-reachable; the type dropdown + executor control carry aria-labels. i18n: the ten type labels + the two executor labels + the "set a type" copy go in the issues i18n namespace (the same locale set the app ships).

Acceptance criteria

  • The create modal shows the type picker (the ten hued members) ONLY for a leaf kind; choosing a type seeds the executor from defaultExecutorForType (e.g. code → coding_agent, manual → human) into the segmented control, still overridable; type may be left null.
  • The detail rail renders the hued type chip + executor indicator and both are inline-editable; a type = null leaf shows "set a type"; an epic/story shows no type control.
  • app/globals.css gains the ten --el-type-* per-type hues (AA: hue in the background, --el-text-strong text); the picker references ONLY --el-* + shape tokens.
  • No client component touches the service/repository layer directly (it calls the create/update endpoints); the picker matches the 2.7.1 design panels (no improvised affordance).
  • a11y: keyboard-reachable, aria-labelled type + executor controls.

Context refs

  • 2.7.1 — the design asset (the four panels this implements verbatim).
  • 2.7.3 — the enum + defaultExecutorForType helper this seeds the executor from (single source).
  • motir-core/components/issues/IssueTypeIcon.tsx — the per-kind hue pattern the per-type chip extends.
  • motir-core/components/ui/Pill.tsx, the Combobox/DropdownMenu primitive, the segmented-control primitive — the composable surface.
  • motir-core/app/globals.css — where the --el-type-* per-type hue tier is added.
  • motir-core/CLAUDE.md § colour / shape + § 4-layer.
Status
Done
Type
Sub-task