feat: add 't' key to transpose row/column axes

Pressing 't' swaps all Row-axis categories to Column and all
Column-axis categories to Row, leaving Page categories unchanged.
Selection and scroll offsets are reset to (0,0).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Ed L
2026-03-24 09:40:02 -07:00
parent c42553fa97
commit cb43a8130e
2 changed files with 46 additions and 1 deletions

View File

@ -283,6 +283,11 @@ impl App {
}
}
// ── Grid transpose ─────────────────────────────────────────────
(KeyCode::Char('t'), KeyModifiers::NONE) => {
self.model.active_view_mut().transpose_axes();
}
// ── Tile movement ──────────────────────────────────────────────
// T = enter tile select mode (single key, no Ctrl needed)
(KeyCode::Char('T'), _) => {
@ -1135,7 +1140,7 @@ impl App {
/// Hint text for the status bar (context-sensitive)
pub fn hint_text(&self) -> &'static str {
match &self.mode {
AppMode::Normal => "hjkl:nav Enter:advance i:edit x:clear /:search F/C/V:panels T:tiles [:]:page ::cmd",
AppMode::Normal => "hjkl:nav Enter:advance i:edit x:clear t:transpose /:search F/C/V:panels T:tiles [:]:page ::cmd",
AppMode::Editing { .. } => "Enter:commit Esc:cancel",
AppMode::FormulaPanel => "n:new d:delete jk:nav Esc:back",
AppMode::FormulaEdit { .. } => "Enter:save Esc:cancel — type: Name = expression",