mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-05-07 02:51:50 +00:00
refactor(tui): /clean pass on blitz closeout — trim comments, flatten logic
- normalizeStatusBar collapses to one ternary expression
- /statusbar slash hoists the toggle value and flattens the branch tree
- shift-tab yolo comment reduced to one line
- cursorLayout/offsetFromPosition lose paragraph-length comments
- appLayout collapses the three {!overlay.agents && …} into one fragment
- StatusRule drops redundant flexShrink={0} (Yoga default)
- server.py uses a walrus + frozenset and trims the compat helper
Net -43 LoC. 237 vitest + 46 pytest green, layouts unchanged.
This commit is contained in:
parent
1e8cfa9092
commit
48f2ac3352
8 changed files with 40 additions and 83 deletions
|
|
@ -50,17 +50,8 @@ export default function wrapText(text: string, maxWidth: number, wrapType: Style
|
|||
})
|
||||
}
|
||||
|
||||
// Char-granularity wrap: break at exact column boundaries regardless of
|
||||
// whitespace. Used for text inputs where the cursor position must track
|
||||
// the wrap boundary deterministically — word-wrap's whitespace-preferring
|
||||
// reshuffle causes visible cursor flicker as each keystroke can push a
|
||||
// word across a line break.
|
||||
if (wrapType === 'wrap-char') {
|
||||
return wrapAnsi(text, maxWidth, {
|
||||
trim: false,
|
||||
hard: true,
|
||||
wordWrap: false
|
||||
})
|
||||
return wrapAnsi(text, maxWidth, { trim: false, hard: true, wordWrap: false })
|
||||
}
|
||||
|
||||
if (wrapType === 'wrap-trim') {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue