╭ changed ────╮ │build.zig.zon│ ╰─────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────╮ │ 3 .version = "0.0.0", │ │ 4 .dependencies = .{ │ │ 5 .xit = .{ │ │ 6 - .url = "git+https://github.com/xit-vcs/xit#3cdb97c108b48fa9fd0501ed1b910da5839e7acc",│ │ 7 - .hash = "xit-0.0.0-Ub3nDCJQHQAAmpC-ESpredoNkuBEUG7NjhCF9yo8Zn6x", │ │ 6 + .url = "git+https://github.com/xit-vcs/xit#97a26b03ff4d6b08627ca6281b63b917dc78258c",│ │ 7 + .hash = "xit-0.0.0-Ub3nDB1RHQB9m6S3qseYL1FAtLIqgbxXLiRdidwHht-U", │ │ 8 }, │ │ 9 }, │ │10 .paths = .{ │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ────────────╮ │src/ui/Home/Users.zig│ ╰─────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │79 errdefer box.deinit(allocator); │ │80 │ │81 { │ │82 - var header = try wgt.Box(ui.Widget).init(allocator, .{ .border = null, .direction = .horiz }); │ │83 - errdefer header.deinit(allocator); │ │82 + var header_scroll = try ui.widget.HeaderScroll.init(allocator, session); │ │83 + errdefer header_scroll.deinit(allocator); │ │84 + const header = header_scroll.row(); │ │85 { │ │86 var search_box = try ui.widget.SearchBox.init(allocator, session, " search ", "search", data.search);│ │87 errdefer search_box.deinit(allocator); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │ 94 errdefer spacer.deinit(allocator); │ │ 95 try header.children.put(allocator, spacer.getFocus().id, .{ .widget = .{ .spacer = spacer }, .rect = null, .min_size = null }); │ │ 96 } │ │ 96 - try box.children.put(allocator, header.getFocus().id, .{ .widget = .{ .box = header }, .rect = null, .min_size = .{ .width = null, .height = ui.widget.SearchBox.min_size.height } }); │ │ 97 + try box.children.put(allocator, header_scroll.getFocus().id, .{ .widget = .{ .header_scroll = header_scroll }, .rect = null, .min_size = .{ .width = null, .height = ui.widget.SearchBox.min_size.height } });│ │ 98 } │ │ 99 │ │100 // an empty first window has no rows, not even paging ones │ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │185 } │ │186 │ │187 fn searchBox(self: *View) *ui.widget.SearchBox { │ │187 - return &self.box.children.values()[header_index].widget.box.children.values()[0].widget.search_box; │ │188 + return &self.box.children.values()[header_index].widget.header_scroll.row().children.values()[0].widget.search_box;│ │189 } │ │190 │ │191 fn listScroll(self: *View) *ui.widget.FlowBox.Scroll { │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─────────────╮ │src/ui/Repo/Events.zig│ ╰──────────────────────╯ ╭──────────────────────────────────────────────────────────────────────╮ │709 } │ │710 │ │711 pub const View = struct { │ │712 - box: wgt.Box(ui.Widget), │ │712 + scroll: ui.widget.HeaderScroll, │ │713 session: *ui.Session, │ │714 tab_ids: [2]usize, │ │715 // the tab stays selected while the sync button has focus│ ╰──────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │717 button_id: ?usize, │ │718 │ │719 pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !Header.View { │ │720 - var box = try wgt.Box(ui.Widget).init(allocator, .{ .border = null, .direction = .horiz }); │ │721 - errdefer box.deinit(allocator); │ │720 + var scroll = try ui.widget.HeaderScroll.init(allocator, session); │ │721 + errdefer scroll.deinit(allocator); │ │722 + const box = scroll.row(); │ │723 var tab_ids: [2]usize = undefined; │ │724 const view_labels = [_][]const u8{ active_tab_label, removed_tab_label }; │ │725 inline for ([_]ui.RoutablePage.EventsView{ .active, .removed }, view_labels, 0..) |view, view_label, i| {│ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │749 button.getFocus().mode = .all; │ │750 button.getFocus().kind = .{ .custom = "submit" }; │ │751 button_id = button.getFocus().id; │ │751 - try box.children.put(allocator, button.getFocus().id, .{ .widget = .{ .text_box = button }, .rect = null, .min_size = null }); │ │752 + try box.children.put(allocator, button.getFocus().id, .{ .widget = .{ .text_box = button }, .rect = null, .min_size = .{ .width = "sync".len + 2, .height = null } });│ │753 } │ │754 │ │755 if (data.header.sync_status) |status_text| { │ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │758 try box.children.put(allocator, status.getFocus().id, .{ .widget = .{ .text_box = status }, .rect = null, .min_size = null, .flex = .shrink });│ │759 } │ │760 box.getFocus().child_id = tab_ids[@backingInt(data.view)]; │ │760 - return .{ .box = box, .session = session, .tab_ids = tab_ids, .selected_tab = @backingInt(data.view), .button_id = button_id }; │ │761 + return .{ .scroll = scroll, .session = session, .tab_ids = tab_ids, .selected_tab = @backingInt(data.view), .button_id = button_id }; │ │762 } │ │763 │ │764 pub fn deinit(self: *Header.View, allocator: std.mem.Allocator) void { │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │764 - self.box.deinit(allocator); │ │765 + self.scroll.deinit(allocator); │ │766 } │ │767 │ │768 pub fn build(self: *Header.View, allocator: std.mem.Allocator, constraint: layout.Constraint, root_focus: *Focus) !void {│ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────╮ │769 self.clearGrid(); │ │770 if (self.getSelectedIndex()) |index| self.selected_tab = index; │ │771 for (self.tab_ids, 0..) |id, index| { │ │771 - const child = self.box.children.getPtr(id) orelse continue; │ │772 + const child = self.scroll.row().children.getPtr(id) orelse continue;│ │773 const tab = switch (child.widget) { │ │774 .text_box => |*text_box| text_box, │ │775 else => continue, │ ╰─────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────╮ │next →│ ╰──────╯