From e154408e8ddeaee83242002f4c7af68b29d3a677 Mon Sep 17 00:00:00 2001 From: Anhgelus Morhtuuzh Date: Mon, 27 Apr 2026 20:49:13 +0200 Subject: feat(): support callout --- src/eval/html/Void.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/eval/html/Void.zig') diff --git a/src/eval/html/Void.zig b/src/eval/html/Void.zig index 58550f4..ec35fc7 100644 --- a/src/eval/html/Void.zig +++ b/src/eval/html/Void.zig @@ -28,7 +28,7 @@ pub fn element(self: *Self) Element { } pub fn setAttribute(self: *Self, k: []const u8, v: []const u8) Error!void { - try self.attributes.put(try self.alloc.dupe(u8, k), try self.alloc.dupe(u8, v)); + try self.attributes.put(try self.alloc.dupe(u8, k), try html.escape(self.alloc, v)); } pub fn removeAttribute(self: *Self, k: []const u8) void { @@ -40,7 +40,7 @@ pub fn hasAttribute(self: *Self, k: []const u8) bool { } pub fn appendClass(self: *Self, v: []const u8) Error!void { - try self.class_list.insert(v); + try self.class_list.insert(try html.escape(self.alloc, v)); } pub fn hasClass(self: *Self, v: []const u8) bool { -- cgit v1.2.3