╭─────────────╮ │scroll to top│ ╰─────────────╯ ╭ User.zig ─────────────────────────────────────────────────────╮ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ╰───────────────────────────────────────────────────────────────╯
╭────╮ ╭ clone ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ╮ │http│ ssh │ │ ╰────╯ ╰ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ╯
473 pub fn getGrid(self: ReposView) ?Grid { 474 return self.box.getGrid(); 475 } 476 477 pub fn getFocus(self: *ReposView) *Focus { 478 return self.box.getFocus(); 479 } 480 481 // up leaves the tab from the search box 482 pub fn atTop(self: *ReposView) bool { 483 return self.headerActive(); 484 } 485 486 pub fn focusHeader(self: *ReposView, root_focus: *Focus) void { 487 root_focus.setFocus(self.searchBox().getFocus().id); 488 } 489 }; 490 491 // the first window of `name`'s repos 492 fn reposRoute(name: []const u8) ?ui.RoutablePage { 493 return .{ .user_repos = .{ .name = ui.RoutablePage.Array(evt.User.name_max_len).from(name) orelse return null } }; 494 } 495