LibWeb+LibGfx: Apply editorial punctuation/whitespace/markup fixes

Corresponds to d426109ea1
and fd08f81d06
This commit is contained in:
Sam Atkins 2025-06-24 11:18:14 +01:00 committed by Shannon Booth
parent a35d14eab3
commit 423cdd447d
Notes: github-actions[bot] 2025-06-24 15:13:34 +00:00
35 changed files with 108 additions and 103 deletions

View file

@ -331,7 +331,7 @@ String HTMLCanvasElement::to_data_url(StringView type, JS::Value quality)
// FIXME: 1. If this canvas element's bitmap's origin-clean flag is set to false, then throw a "SecurityError" DOMException.
// 2. If this canvas element's bitmap has no pixels (i.e. either its horizontal dimension or its vertical dimension is zero)
// 2. If this canvas element's bitmap has no pixels (i.e. either its horizontal dimension or its vertical dimension is zero),
// then return the string "data:,". (This is the shortest data: URL; it represents the empty string in a text/plain resource.)
if (!surface)
return "data:,"_string;
@ -342,7 +342,7 @@ String HTMLCanvasElement::to_data_url(StringView type, JS::Value quality)
surface->read_into_bitmap(*bitmap);
auto file = serialize_bitmap(bitmap, type, move(quality));
// 4. If file is null then return "data:,".
// 4. If file is null, then return "data:,".
if (file.is_error()) {
dbgln("HTMLCanvasElement: Failed to encode canvas bitmap to {}: {}", type, file.error());
return "data:,"_string;