╭─────────────╮ │scroll to top│ ╰─────────────╯ ╭ Refs.zig ─────────────────────────────────────────────────────╮ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ╰───────────────────────────────────────────────────────────────╯
╭────╮ ╭ clone ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ╮ │http│ ssh │ │ ╰────╯ ╰ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ╯
353 var copy = self; 354 const col = copy.activeColumn() orelse return null; 355 const cur_id = col.getFocus().child_id orelse return null; 356 return col.children.getIndex(cur_id); 357 } 358 }; 359 360 // the "a:" link to `kind`'s column paginated to `after` within `identity` 361 // ("owner/name"). the other column resets to its first window. 362 fn windowLink(page_arena: *std.heap.ArenaAllocator, identity: []const u8, kind: ui.RoutablePage.RefKind, after: usize) ![]const u8 { 363 const route = ui.RoutablePage.repoRefsRoute(identity, kind, after) orelse return error.RouteTooLong; 364 const url = try route.urlAlloc(page_arena); 365 return std.fmt.allocPrint(page_arena.allocator(), "a:{s}", .{url}); 366 } 367