Skip to content

Commit

Permalink
Change stringifier useLegacyColors default to false (#33)
Browse files Browse the repository at this point in the history
  • Loading branch information
Phoenix616 committed Jun 11, 2024
1 parent 330e708 commit 7b8163a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>de.themoep</groupId>
<artifactId>minedown-adventure</artifactId>
<version>1.7.2-SNAPSHOT</version>
<version>1.7.3-SNAPSHOT</version>

<name>MineDown</name>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import net.kyori.adventure.text.format.Style;
import net.kyori.adventure.text.format.TextDecoration;
import net.kyori.adventure.text.format.TextColor;
import net.kyori.adventure.text.format.TextFormat;

import java.util.ArrayDeque;
import java.util.ArrayList;
Expand All @@ -51,9 +50,9 @@
public class MineDownStringifier {

/**
* Whether or not to use legacy color codes (Default: true)
* Whether or not to use legacy color codes (Default: false)
*/
private boolean useLegacyColors = true;
private boolean useLegacyColors = false;

/**
* Whether or not to translate legacy formatting codes over Minedown ones (Default: false)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
import net.kyori.adventure.text.event.ClickEvent;
import net.kyori.adventure.text.event.HoverEvent;
import net.kyori.adventure.text.format.NamedTextColor;
import net.kyori.adventure.text.format.TextColor;
import net.kyori.adventure.text.format.TextDecoration;
import net.kyori.adventure.text.serializer.gson.GsonComponentSerializer;
import org.junit.jupiter.api.Assertions;
Expand Down Expand Up @@ -60,6 +61,7 @@ public void testStringify() {
)
.append(Component.text(". Test Text."))
.build()),
() -> stringify(Component.text("test").color(TextColor.color(0x11FF00))),
() -> stringify(Component.text("Test insertion")
.insertion("Insert text"))
);
Expand Down

0 comments on commit 7b8163a

Please sign in to comment.