forked from MinecraftUtilities/Backend
maybe bold for html?
This commit is contained in:
parent
2be48c7c30
commit
65aa5b102b
@ -49,7 +49,7 @@ public final class ColorUtils {
|
|||||||
/**
|
/**
|
||||||
* Convert the given input
|
* Convert the given input
|
||||||
* into HTML.
|
* into HTML.
|
||||||
*
|
*
|
||||||
* @param input the input to convert
|
* @param input the input to convert
|
||||||
* @return the HTML converted input
|
* @return the HTML converted input
|
||||||
*/
|
*/
|
||||||
@ -83,15 +83,10 @@ public final class ColorUtils {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (character == 'l') { // Start bold
|
if (character == 'l') { // Start bold
|
||||||
isBold = true;
|
builder.append("<span style=\"font-weight: bold;\">");
|
||||||
builder.append("<b>");
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (character == 'r') { // Reset formatting
|
if (character == 'r') { // Reset formatting
|
||||||
if (isBold) {
|
|
||||||
builder.append("</b>");
|
|
||||||
isBold = false;
|
|
||||||
}
|
|
||||||
builder.append("</span>");
|
builder.append("</span>");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
@ -107,5 +102,4 @@ public final class ColorUtils {
|
|||||||
|
|
||||||
return builder.toString();
|
return builder.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user