feat(tui): add Tab key to toggle JSON pretty-print
Press Tab to switch JSON log lines between raw single-line and indented multi-line format (2-space indent, like jq output). Only JSON Object lines are affected; plain text lines stay unchanged. - Add json_format bool field to App, toggled by Tab - Add format_json_line() standalone function with serde_json::to_string_pretty - Integrate into recompute_wrap_cache with \n-split sub-line wrapping - Center viewport on cursor after cache rebuild to prevent jump on toggle - Add 12 unit tests covering format, toggle, and edge cases Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
1
Cargo.lock
generated
1
Cargo.lock
generated
@@ -2327,6 +2327,7 @@ dependencies = [
|
||||
"crossterm",
|
||||
"log-viewer-core",
|
||||
"ratatui",
|
||||
"serde_json",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
||||
Reference in New Issue
Block a user