From bedde3b0eb9430f4ca1f1c37ff0f5a6ecb88e6a5 Mon Sep 17 00:00:00 2001 From: Liam Date: Tue, 16 Apr 2024 20:47:50 +0100 Subject: [PATCH] line to html now workie --- src/main/java/xyz/mcutils/backend/common/ColorUtils.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/xyz/mcutils/backend/common/ColorUtils.java b/src/main/java/xyz/mcutils/backend/common/ColorUtils.java index 3c2c72f..786d201 100644 --- a/src/main/java/xyz/mcutils/backend/common/ColorUtils.java +++ b/src/main/java/xyz/mcutils/backend/common/ColorUtils.java @@ -78,13 +78,17 @@ public final class ColorUtils { if (nextIsColor) { // Map the current color to its hex code String color = COLOR_MAP.getOrDefault(Character.toLowerCase(character), ""); builder.append(""); nextIsColor = false; continue; } + if (character == ' ') { // Preserve space character + builder.append(" "); + continue; + } builder.append(character); // Append the char... }