╭──────────╮ │← previous│ ╰──────────╯ ╭ changed ───────────────╮ │src/ui/widget/thread.zig│ ╰────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1624 { │ │1625 var tags = try wgt.TextInput.init(allocator, .{ .label = " tags (separate with spaces) ", .name = "tags", .visible_width = null, .rounded_corners = true, .render_content = session.is_terminal });│ │1626 errdefer tags.deinit(allocator); │ │1626 - tags.getFocus().focusable = true; │ │1627 + tags.getFocus().mode = .all; │ │1628 if (saved_fields) |saved| │ │1629 try tags.setContent(allocator, saved.tags) │ │1630 else if (record) |r| │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1635 { │ │1636 var description = try wgt.TextInput.init(allocator, .{ .label = " description ", .name = "description", .visible_width = null, .rounded_corners = true, .render_content = session.is_terminal, .multiline = true, .scroll = .{ .fill = true } });│ │1637 errdefer description.deinit(allocator); │ │1637 - description.getFocus().focusable = true; │ │1638 + description.getFocus().mode = .all; │ │1639 if (saved_fields) |saved| │ │1640 try description.setContent(allocator, saved.description) │ │1641 else if (record) |r| │ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1646 if (supports_drafts) { │ │1647 var target = try wgt.TextInput.init(allocator, .{ .label = " target branch ", .name = "target_branch", .visible_width = null, .rounded_corners = true, .render_content = session.is_terminal });│ │1648 errdefer target.deinit(allocator); │ │1648 - target.getFocus().focusable = true; │ │1649 + target.getFocus().mode = .all; │ │1650 const content = if (saved_fields) |saved| saved.target_branch else if (record) |r| r.event.target_branch else data.default_target_branch; │ │1651 try target.setContent(allocator, content); │ │1652 try box.children.put(allocator, target.getFocus().id, .{ .widget = .{ .text_input = target }, .rect = null, .min_size = .{ .width = null, .height = 3 } }); │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1683 .scroll = .{ .fill = true }, │ │1684 }); │ │1685 errdefer body.deinit(allocator); │ │1685 - body.getFocus().focusable = true; │ │1686 + body.getFocus().mode = .all; │ │1687 if (initial_body) |text| try body.setContent(allocator, text); │ │1688 try box.children.put(allocator, body.getFocus().id, .{ .widget = .{ .text_input = body }, .rect = null, .min_size = null });│ │1689 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1710 for (buttons, 0..) |options, index| { │ │1711 var button = try wgt.TextBox.init(allocator, options.label, .{ .border_style = .single, .rounded_corners = true, .wrap_kind = .none });│ │1712 errdefer button.deinit(allocator); │ │1712 - button.getFocus().focusable = true; │ │1713 + button.getFocus().mode = .all; │ │1714 button.getFocus().kind = .{ .custom = options.action }; │ │1715 try box.children.put(allocator, button.getFocus().id, .{ .widget = .{ .text_box = button }, .rect = null, .min_size = null }); │ │1716 if (index == 0) box.getFocus().child_id = button.getFocus().id; │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1782 .same => |text| { │ │1783 var tb = try wgt.TextBox.init(allocator, text, .{ .border_style = .single, .rounded_corners = true, .wrap_kind = .word });│ │1784 errdefer tb.deinit(allocator); │ │1784 - tb.getFocus().focusable = true; │ │1785 + tb.getFocus().mode = .all; │ │1786 try box.children.put(allocator, tb.getFocus().id, .{ .widget = .{ .text_box = tb }, .rect = null, .min_size = null }); │ │1787 }, │ │1788 // an auto-resolved chunk: only one side changed it, so its │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1796 }; │ │1797 var tb = try wgt.TextBox.init(allocator, auto.text orelse "(removed)", .{ .border_style = .single, .rounded_corners = true, .wrap_kind = .word, .label = label });│ │1798 errdefer tb.deinit(allocator); │ │1798 - tb.getFocus().focusable = true; │ │1799 + tb.getFocus().mode = .all; │ │1800 try box.children.put(allocator, tb.getFocus().id, .{ .widget = .{ .text_box = tb }, .rect = null, .min_size = null }); │ │1801 }, │ │1802 .conflict => |hunk| { │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1810 try addVersionRow(allocator, &box, try sideLabel(aa, desc.theirs_author, false), hunk.theirs orelse "", try useThisLink(session, data, name, true)); │ │1811 var resolution_input = try wgt.TextInput.init(allocator, .{ .label = " resolution ", .name = name, .visible_width = null, .rounded_corners = true, .render_content = session.is_terminal, .multiline = true });│ │1812 errdefer resolution_input.deinit(allocator); │ │1812 - resolution_input.getFocus().focusable = true; │ │1813 + resolution_input.getFocus().mode = .all; │ │1814 try resolution_input.setContent(allocator, (if (picked_theirs) hunk.theirs else hunk.ours) orelse ""); │ │1815 try box.children.put(allocator, resolution_input.getFocus().id, .{ .widget = .{ .text_input = resolution_input }, .rect = null, .min_size = null }); │ │1816 if (chunk_index + 1 < desc.chunks.len) try addGap(allocator, &box); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1834 │ │1835 var resolution_input = try wgt.TextInput.init(allocator, .{ .label = " resolution ", .name = name, .visible_width = null, .rounded_corners = true, .render_content = session.is_terminal });│ │1836 errdefer resolution_input.deinit(allocator); │ │1836 - resolution_input.getFocus().focusable = true; │ │1837 + resolution_input.getFocus().mode = .all; │ │1838 try resolution_input.setContent(allocator, if (data.theirsPicked(name)) fc.theirs.text else fc.ours.text); │ │1839 try box.children.put(allocator, resolution_input.getFocus().id, .{ .widget = .{ .text_input = resolution_input }, .rect = null, .min_size = null }); │ │1840 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1851 .label = " resolution ", │ │1852 }); │ │1853 errdefer selected.deinit(allocator); │ │1853 - selected.getFocus().focusable = true; │ │1854 + selected.getFocus().mode = .all; │ │1855 try box.children.put(allocator, selected.getFocus().id, .{ .widget = .{ .text_box = selected }, .rect = null, .min_size = null });│ │1856 } │ │1857 │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────╮ │next →│ ╰──────╯