╭ changed ─────────╮ │src/ui/NewRepo.zig│ ╰──────────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │22 │ │23 // `route` is the page's own new-repo route, which the web form posts to │ │24 pub fn init(allocator: std.mem.Allocator, session: *ui.Session, route: ui.RoutablePage) !View { │ │25 - var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = null, .direction = .vert }); │ │25 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border = null, .direction = .vert }); │ │26 errdefer box.deinit(allocator); │ │27 box.getFocus().kind = .{ .custom = try session.page_arena.allocator().print("form:{s}", .{try route.toUrl(session.page_arena)}) };│ │28 │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │29 const saved_fields = if (session.formFeedback(.repo)) |saved| saved.fields else null; │ │30 │ │31 { │ │32 - var name = try wgt.TextInput.init(allocator, .{ .label = " name ", .name = "name", .visible_width = 30, .round_corners = true, .render_content = session.is_terminal }); │ │32 + var name = try wgt.TextInput.init(allocator, .{ .top_label = .{ .text = " name " }, .name = "name", .visible_width = 30, .round_corners = true, .render_content = session.is_terminal });│ │33 errdefer name.deinit(allocator); │ │34 name.getFocus().mode = .all; │ │35 if (saved_fields) |saved| try name.setContent(allocator, saved.name); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │38 } │ │39 │ │40 { │ │41 - var description = try wgt.TextInput.init(allocator, .{ .label = " description ", .name = "description", .visible_width = 30, .round_corners = true, .render_content = session.is_terminal }); │ │41 + var description = try wgt.TextInput.init(allocator, .{ .top_label = .{ .text = " description " }, .name = "description", .visible_width = 30, .round_corners = true, .render_content = session.is_terminal });│ │42 errdefer description.deinit(allocator); │ │43 description.getFocus().mode = .all; │ │44 if (saved_fields) |saved| try description.setContent(allocator, saved.description); │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │73 pub fn build(self: *View, allocator: std.mem.Allocator, constraint: layout.Constraint, root_focus: *Focus) !void {│ │74 self.clearGrid(); │ │75 const failure = if (self.session.formFeedback(.repo)) |saved| saved.failure else null; │ │76 - (try formField(self.formBox(), "name")).options.label = if (failure) |value| switch (value) { │ │76 + (try formField(self.formBox(), "name")).options.top_label.text = if (failure) |value| switch (value) { │ │77 .required_name => " name (required) ", │ │78 .invalid_name => " name (invalid) ", │ │79 .name_taken => " name (taken) ", │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯