close: tui view mode state

This commit is contained in:
Keisuke Hirata 2026-05-31 22:45:41 +09:00
parent 9afe8a3243
commit 0a538380a9
No known key found for this signature in database
4 changed files with 50 additions and 2 deletions

View File

@ -2,12 +2,12 @@
id: 20260531-074258-tui-move-view-mode-state
slug: tui-move-view-mode-state
title: TUI: move view mode state out of ui module
status: open
status: closed
kind: task
priority: P2
labels: [tui, cleanup]
created_at: 2026-05-31T07:42:58Z
updated_at: 2026-05-31T13:45:04Z
updated_at: 2026-05-31T13:45:39Z
assignee: null
legacy_ticket: null
---

View File

@ -0,0 +1,20 @@
Moved single-Pod view/history mode state out of the render module.
Implementation:
- Added `crates/tui/src/view_mode.rs`.
- Moved `Mode` from `ui.rs` to `view_mode.rs` without changing variants or methods.
- Updated `app.rs`, `ui.rs`, and `tool.rs` imports to use `crate::view_mode::Mode`.
- Removed the `app.rs -> ui.rs` dependency caused solely by `Mode`.
- Kept render/key/command behavior unchanged.
Review:
- External reviewer `tui-view-mode-reviewer-20260531` approved implementation commit `bc31bfa`.
Validation after merge:
- `cargo fmt --check`
- `cargo test -p tui mode`
- `cargo test -p tui`
- `cargo check -p tui` (passed with existing dead-code warnings)
- `./tickets.sh doctor`
- `git diff --check`
- `rg "crate::ui::Mode|ui::Mode" crates/tui/src || true` produced no active source hits.

View File

@ -35,4 +35,32 @@ Validation adequacy:
- Reviewer additionally performed read-only diff/reference checks and found no issues.
---
<!-- event: close author: hare at: 2026-05-31T13:45:39Z status: closed -->
## Closed
Moved single-Pod view/history mode state out of the render module.
Implementation:
- Added `crates/tui/src/view_mode.rs`.
- Moved `Mode` from `ui.rs` to `view_mode.rs` without changing variants or methods.
- Updated `app.rs`, `ui.rs`, and `tool.rs` imports to use `crate::view_mode::Mode`.
- Removed the `app.rs -> ui.rs` dependency caused solely by `Mode`.
- Kept render/key/command behavior unchanged.
Review:
- External reviewer `tui-view-mode-reviewer-20260531` approved implementation commit `bc31bfa`.
Validation after merge:
- `cargo fmt --check`
- `cargo test -p tui mode`
- `cargo test -p tui`
- `cargo check -p tui` (passed with existing dead-code warnings)
- `./tickets.sh doctor`
- `git diff --check`
- `rg "crate::ui::Mode|ui::Mode" crates/tui/src || true` produced no active source hits.
---