╭ changed ───────────────╮ │src/ui/Repo/Markdown.zig│ ╰────────────────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │116 pub fn init(allocator: std.mem.Allocator, text: []const u8, label: []const u8, bottom_label: []const u8, page_arena: *std.heap.ArenaAllocator) !Frame { │ │117 const doc = try md.parseText(page_arena.allocator(), text); │ │118 │ │119 - var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = .single, .round_corners = true, .direction = .vert, .label = label, .bottom_label = bottom_label }); │ │119 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border = .single, .round_corners = true, .direction = .vert, .top_label = .{ .text = label }, .bottom_label = .{ .text = bottom_label } });│ │120 errdefer box.deinit(allocator); │ │121 var markdown = try View.init(allocator, doc, null, "", page_arena); │ │122 errdefer markdown.deinit(allocator); │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │131 │ │132 pub fn build(self: *Frame, allocator: std.mem.Allocator, constraint: layout.Constraint, root_focus: *Focus) !void {│ │133 const focused = if (root_focus.grandchild_id) |id| self.markdownView().owns(id) else false; │ │134 - self.box.options.border_style = if (focused) .double else .single; │ │134 + self.box.options.border = if (focused) .double else .single; │ │135 try self.box.build(allocator, constraint, root_focus); │ │136 } │ │137 │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │200 │ │201 // a vertical box of `blocks`, with a blank row between them when `gap` │ │202 fn blocksBox(b: Builder, blocks: []const md.Block, gap: bool) anyerror!wgt.Box(ui.Widget) { │ │203 - var box = try wgt.Box(ui.Widget).init(b.allocator, .{ .border_style = null, .direction = .vert, .gap = @intFromBool(gap) });│ │203 + var box = try wgt.Box(ui.Widget).init(b.allocator, .{ .border = null, .direction = .vert, .gap = @intFromBool(gap) }); │ │204 errdefer box.deinit(b.allocator); │ │205 for (blocks) |block| try b.addBlock(&box, block); │ │206 return box; │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │216 .paragraph => |inlines| try put(allocator, box, .{ .rich_text = try RichText.init(allocator, try b.runSpans(inlines, .{})) }), │ │217 .code => |lines| { │ │218 const text = try std.mem.join(b.page_arena.allocator(), "\n", lines); │ │219 - try put(allocator, box, .{ .text_box = try wgt.TextBox.init(allocator, text, .{ .border_style = .single, .round_corners = true, .wrap_kind = .char }) });│ │219 + try put(allocator, box, .{ .text_box = try wgt.TextBox.init(allocator, text, .{ .border = .single, .round_corners = true, .wrap_kind = .char }) }); │ │220 }, │ │221 .quote => |blocks| { │ │222 const gutter = gutter: { │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │227 try put(allocator, box, .{ .markdown_gutter = gutter }); │ │228 }, │ │229 .list => |list| { │ │230 - var list_box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = null, .direction = .vert });│ │230 + var list_box = try wgt.Box(ui.Widget).init(allocator, .{ .border = null, .direction = .vert }); │ │231 errdefer list_box.deinit(allocator); │ │232 // ordered markers are right-aligned to the widest number │ │233 const number_width = std.fmt.count("{d}", .{list.start + list.items.len -| 1}); │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │248 try put(allocator, box, .{ .box = list_box }); │ │249 }, │ │250 // wider than any pane, and clipped to the width │ │251 - .rule => try put(allocator, box, .{ .text_box = try wgt.TextBox.init(allocator, std.mem.asBytes(&@as([512]["─".len]u8, @splat("─".*))), .{ .border_style = null, .wrap_kind = .none, .style = .{ .dim = true } }) }),│ │251 + .rule => try put(allocator, box, .{ .text_box = try wgt.TextBox.init(allocator, std.mem.asBytes(&@as([512]["─".len]u8, @splat("─".*))), .{ .border = null, .wrap_kind = .none, .style = .{ .dim = true } }) }), │ │252 .raw => |lines| { │ │253 const text = try std.mem.join(b.page_arena.allocator(), "\n", lines); │ │254 - try put(allocator, box, .{ .text_box = try wgt.TextBox.init(allocator, text, .{ .border_style = null, .wrap_kind = .none }) }); │ │254 + try put(allocator, box, .{ .text_box = try wgt.TextBox.init(allocator, text, .{ .border = null, .wrap_kind = .none }) }); │ │255 }, │ │256 } │ │257 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │362 var text = try RichText.init(allocator, marked); │ │363 errdefer text.deinit(allocator); │ │364 │ │365 - var font_box = try wgt.TextBox.init(allocator, "", .{ .border_style = null, .wrap_kind = .none });│ │365 + var font_box = try wgt.TextBox.init(allocator, "", .{ .border = null, .wrap_kind = .none }); │ │366 errdefer font_box.deinit(allocator); │ │367 var self: Heading = .{ .focus = focus, .text = text, .font_box = font_box }; │ │368 │ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────╯