mod: bump zterm dependency with required code adaptations
Some checks failed
Zig Project Action / Lint, Spell-check and test zig project (push) Failing after 1m16s
Some checks failed
Zig Project Action / Lint, Spell-check and test zig project (push) Failing after 1m16s
This commit is contained in:
10
src/main.zig
10
src/main.zig
@@ -20,9 +20,9 @@ pub fn main() !void {
|
||||
// skip own executable name
|
||||
_ = arg_it.skip();
|
||||
|
||||
var app: App = .init(.{
|
||||
var app: App = .init(.{}, .{
|
||||
.page = .about,
|
||||
.document = .init(try std.fs.cwd().readFileAlloc("./doc/about.md", allocator, .unlimited)),
|
||||
.document = .init(try std.fs.cwd().readFileAlloc(allocator, "./doc/about.md", std.math.maxInt(usize))),
|
||||
});
|
||||
defer app.model.deinit(allocator);
|
||||
|
||||
@@ -38,7 +38,6 @@ pub fn main() !void {
|
||||
}, .{});
|
||||
defer container.deinit();
|
||||
var content_container: App.Container = undefined;
|
||||
defer content_container.deinit();
|
||||
|
||||
// header with navigation buttons and content's title
|
||||
{
|
||||
@@ -162,9 +161,8 @@ pub fn main() !void {
|
||||
}
|
||||
}
|
||||
|
||||
container.resize(try renderer.resize());
|
||||
container.reposition(.{});
|
||||
|
||||
container.resize(&app.model, try renderer.resize());
|
||||
container.reposition(&app.model, .{});
|
||||
try renderer.render(@TypeOf(container), &container, App.Model, &app.model);
|
||||
try renderer.flush();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user