The best way to control Claude Code, Codex and more from any computer or phone
| 1 | import { mFallback, msg } from "gt-i18n"; |
| 2 | import type { MFunctionType } from "gt-i18n/types"; |
| 3 | |
| 4 | import type { SearchMatchHintField } from "./paletteSearch.ts"; |
| 5 | |
| 6 | const MATCH_HINT_LABELS: Readonly<Record<SearchMatchHintField, string>> = { |
| 7 | "pull-request": msg("PR", { $context: "abbreviation of pull request" }), |
| 8 | branch: msg("Branch"), |
| 9 | project: msg("Project"), |
| 10 | environment: msg("Environment"), |
| 11 | reference: msg("ID or link"), |
| 12 | }; |
| 13 | |
| 14 | /** @public */ |
| 15 | export function searchMatchHintLabel( |
| 16 | field: SearchMatchHintField, |
| 17 | resolve: MFunctionType = mFallback, |
| 18 | ): string { |
| 19 | return resolve(MATCH_HINT_LABELS[field]); |
| 20 | } |