diff options
Diffstat (limited to 'src/main/java/dev/isxander/yacl3/gui/DescriptionWithName.java')
-rw-r--r-- | src/main/java/dev/isxander/yacl3/gui/DescriptionWithName.java | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main/java/dev/isxander/yacl3/gui/DescriptionWithName.java b/src/main/java/dev/isxander/yacl3/gui/DescriptionWithName.java new file mode 100644 index 0000000..6ad72e8 --- /dev/null +++ b/src/main/java/dev/isxander/yacl3/gui/DescriptionWithName.java @@ -0,0 +1,11 @@ +package dev.isxander.yacl3.gui; + +import dev.isxander.yacl3.api.OptionDescription; +import net.minecraft.ChatFormatting; +import net.minecraft.network.chat.Component; + +public record DescriptionWithName(Component name, OptionDescription description) { + public static DescriptionWithName of(Component name, OptionDescription description) { + return new DescriptionWithName(name.copy().withStyle(ChatFormatting.BOLD), description); + } +} |