╭ changed ──────╮ │src/command.zig│ ╰───────────────╯ ╭─────────────────────────────────────────────────────────────────────╮ │250 } │ │251 } else if (cmd_args.command_name) |command_name| { │ │252 return .{ .invalid = .{ .command = command_name } };│ │253 - } else if (show_help) { │ │254 - return .{ .help = null }; │ │253 } else { │ │254 return .{ .help = null }; │ │255 } │ ╰─────────────────────────────────────────────────────────────────────╯ ╭ changed ─╮ │src/ui.zig│ ╰──────────╯ ╭──────────────────────────────────────────╮ │1027 flow_box_scroll: FlowBox.Scroll,│ │1028 spacer: Spacer, │ │1029 center: Center, │ │1030 - ansi_art: AnsiArt, │ │1030 background: AnsiBackground, │ │1031 home: Home.View, │ │1032 user: User.View, │ ╰──────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1487 focus: *Focus, │ │1488 grid: ?Grid, │ │1489 child: *Widget, │ │1491 - direction: Direction, │ │1492 - │ │1493 - pub const Direction = enum { both, horiz, vert }; │ │1490 │ │1495 - pub fn init(allocator: std.mem.Allocator, child_widget: Widget, direction: Direction) !Center {│ │1491 + pub fn init(allocator: std.mem.Allocator, child_widget: Widget) !Center { │ │1492 const child = try allocator.create(Widget); │ │1493 errdefer allocator.destroy(child); │ │1494 child.* = child_widget; │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────╮ │1496 .focus = try Focus.create(allocator, .container),│ │1497 .grid = null, │ │1498 .child = child, │ │1503 - .direction = direction, │ │1499 }; │ │1500 } │ │1501 │ ╰───────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1530 const height = if (constraint.max_size.height) |h| h else if (constraint.min_size.height) |min_h| @max(min_h, child_grid.size.height) else child_grid.size.height;│ │1531 if (width == 0 or height == 0) return; │ │1532 │ │1538 - const offset_x: usize = if (self.direction == .horiz or self.direction == .both) │ │1539 - (width -| child_grid.size.width) / 2 │ │1540 - else │ │1541 - 0; │ │1542 - const offset_y: usize = if (self.direction == .vert or self.direction == .both) │ │1543 - (height -| child_grid.size.height) / 2 │ │1544 - else │ │1545 - 0; │ │1533 + const offset_x: usize = (width -| child_grid.size.width) / 2; │ │1534 + const offset_y: usize = (height -| child_grid.size.height) / 2; │ │1535 │ │1536 var grid = try Grid.init(allocator, .{ .width = width, .height = height }); │ │1537 errdefer grid.deinit(); │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │1656 } │ │1657 } │ │1658 self.grid = grid; │ │1670 - } │ │1671 - │ │1672 - pub fn input(self: *AnsiArt, allocator: std.mem.Allocator, key: inp.Key, root_focus: *Focus) !void {│ │1673 - _ = self; │ │1674 - _ = allocator; │ │1675 - _ = key; │ │1676 - _ = root_focus; │ │1659 } │ │1660 │ │1661 pub fn clearGrid(self: *AnsiArt) void { │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ────────────╮ │src/ui/Auth/Login.zig│ ╰─────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────╮ │92 box.getFocus().child_id = nav_ids[username_index]; │ │93 │ │94 return .{ │ │95 - .center = try ui.Center.init(allocator, .{ .box = box }, .both),│ │95 + .center = try ui.Center.init(allocator, .{ .box = box }), │ │96 .data = data, │ │97 .session = session, │ │98 .nav_ids = nav_ids, │ ╰────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─────────────╮ │src/ui/Auth/Logout.zig│ ╰──────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────╮ │65 box.getFocus().child_id = button_id; │ │66 │ │67 return .{ │ │68 - .center = try ui.Center.init(allocator, .{ .box = box }, .both),│ │68 + .center = try ui.Center.init(allocator, .{ .box = box }), │ │69 .data = data, │ │70 .session = session, │ │71 .button_id = button_id, │ ╰────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─────────╮ │src/ui/AuthTab.zig│ ╰──────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │18 │ │19 pub const View = struct { │ │20 text_box: wgt.TextBox(ui.Widget), │ │21 - data: *const Self, │ │21 session: *ui.Session, │ │22 │ │24 - pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !View { │ │23 + pub fn init(allocator: std.mem.Allocator, session: *ui.Session) !View { │ │24 var text_box = try wgt.TextBox(ui.Widget).init(allocator, "login", .{ .border_style = .single, .rounded_corners = true, .wrap_kind = .none });│ │25 errdefer text_box.deinit(allocator); │ │26 text_box.getFocus().focusable = true; │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────╮ │27 text_box.getFocus().kind = .{ .custom = "ai:/auth" };│ │28 return .{ │ │29 .text_box = text_box, │ │31 - .data = data, │ │30 .session = session, │ │31 }; │ │32 } │ ╰─────────────────────────────────────────────────────────────────╯ ╭──────╮ │next →│ ╰──────╯