mirror of
https://github.com/wu736139669/hapi.git
synced 2026-11-24 04:47:03 +00:00
* feat(web): show project in session header * fix(web): hide unknown worktree project paths
29 lines
694 B
TypeScript
29 lines
694 B
TypeScript
export type SessionHeaderSecondaryMetadataKey =
|
|
| 'project'
|
|
| 'model'
|
|
| 'reasoning'
|
|
| 'machine'
|
|
| 'lastActive'
|
|
| 'updatedAt'
|
|
| 'createdAt'
|
|
| 'worktree'
|
|
| 'fastMode'
|
|
|
|
const MOBILE_SECONDARY_PRIORITY: ReadonlyArray<SessionHeaderSecondaryMetadataKey> = [
|
|
'project',
|
|
'machine',
|
|
'lastActive',
|
|
'model',
|
|
'reasoning',
|
|
'fastMode',
|
|
'createdAt',
|
|
'updatedAt',
|
|
'worktree',
|
|
]
|
|
|
|
export function selectMobileSessionHeaderSecondary(
|
|
available: Partial<Record<SessionHeaderSecondaryMetadataKey, boolean>>
|
|
): SessionHeaderSecondaryMetadataKey | null {
|
|
return MOBILE_SECONDARY_PRIORITY.find((key) => available[key] === true) ?? null
|
|
}
|