╭ changed ────╮ │build.zig.zon│ ╰─────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────╮ │ 3 .version = "0.0.0", │ │ 4 .dependencies = .{ │ │ 5 .xit = .{ │ │ 6 - .url = "git+https://github.com/xit-vcs/xit#eb7e39bba16d9aa79e3b91494d17ad9f9a39c01b",│ │ 7 - .hash = "xit-0.0.0-Ub3nDLx1TwG9v3VNMlYx2SMNlDhNwR3ZpDk_3IXEBS_H", │ │ 6 + .url = "git+https://github.com/xit-vcs/xit#1a3a1a5fa7c4ba02744143860a163ca9c3ba6134",│ │ 7 + .hash = "xit-0.0.0-Ub3nDNd6TwHoFJU-wpiLMIT_unxAx6zF2YJvLL5LrOU6", │ │ 8 }, │ │ 9 }, │ │10 .paths = .{ │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─╮ │src/ui.zig│ ╰──────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────────────╮ │208 │ │209 pub fn build(self: *SelectableList, constraint: layout.Constraint, root_focus: *Focus) !void {│ │210 self.clearGrid(); │ │211 + const pane_has_focus = root_focus.grandchild_id == self.getFocus().id; │ │212 const children = &self.scroll.child.box.children; │ │213 for (children.keys(), children.values()) |id, *item| { │ │214 item.widget.text_box.options.border_style = if (self.getFocus().child_id == id) │ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────╮ │214 - (if (root_focus.grandchild_id == id) .double else .single) │ │215 + // pane_has_focus will be true if the widgets weren't yet in │ │216 + // the focus tree, and so setFocus stopped at the pane itself. │ │217 + // in this case, it should be treated as if it's selected. │ │218 + (if (root_focus.grandchild_id == id or pane_has_focus) .double else .single)│ │219 else │ │220 .hidden; │ │221 } │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────╮ │218 - // force a minimum row of content so an empty list still produces a │ │219 - // non-zero grid. without this, xitui's Scroll.build copies from a │ │220 - // zero-cell child grid and traps with OOB in release builds because │ │221 - // NDSlice.at's bounds check is gated on runtime_safety. │ │222 - var adjusted = constraint; │ │223 - adjusted.min_size.height = @max(adjusted.min_size.height orelse 0, 1); │ │224 - try self.scroll.build(adjusted, root_focus); │ │222 + try self.scroll.build(constraint, root_focus); │ │223 } │ │224 │ │225 pub fn input(self: *SelectableList, key: inp.Key, root_focus: *Focus) !void {│ ╰──────────────────────────────────────────────────────────────────────────────────────╯