aboutsummaryrefslogtreecommitdiff
path: root/test-common/src/main/java/dev/isxander/yacl/test
diff options
context:
space:
mode:
authorisXander <xandersmith2008@gmail.com>2023-05-23 23:15:24 +0100
committerisXander <xandersmith2008@gmail.com>2023-05-23 23:15:24 +0100
commit3b8e4e76b4893fc910e6af1024c3710b6f87954b (patch)
tree51438e3fa038719fbf25c788e7b9ebb7e4e0a930 /test-common/src/main/java/dev/isxander/yacl/test
parent97dd0f861434ac8faf28ce80988d24ca77b091ea (diff)
downloadYetAnotherConfigLib-3b8e4e76b4893fc910e6af1024c3710b6f87954b.tar.gz
YetAnotherConfigLib-3b8e4e76b4893fc910e6af1024c3710b6f87954b.tar.bz2
YetAnotherConfigLib-3b8e4e76b4893fc910e6af1024c3710b6f87954b.zip
Fix animated image rendering
Diffstat (limited to 'test-common/src/main/java/dev/isxander/yacl/test')
-rw-r--r--test-common/src/main/java/dev/isxander/yacl/test/GuiTest.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/test-common/src/main/java/dev/isxander/yacl/test/GuiTest.java b/test-common/src/main/java/dev/isxander/yacl/test/GuiTest.java
index 7c9cf9d..7175bcc 100644
--- a/test-common/src/main/java/dev/isxander/yacl/test/GuiTest.java
+++ b/test-common/src/main/java/dev/isxander/yacl/test/GuiTest.java
@@ -70,7 +70,7 @@ public class GuiTest {
.append(Component.literal("e").withStyle(style -> style.withHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, Component.literal("e")))))
.withStyle(style -> style.withClickEvent(new ClickEvent(ClickEvent.Action.OPEN_URL, "https://isxander.dev")))
)
- .webpImage(Path.of("D:\\Xander\\Downloads\\e.webp"), new ResourceLocation("yacl", "e.webp"))
+ .gifImage(Path.of("D:\\Xander\\Downloads\\showcaseMain.gif"), new ResourceLocation("yacl", "e.webp"))
.build())
.binding(
defaults.booleanToggle,
@@ -82,14 +82,11 @@ public class GuiTest {
.build())
.option(Option.createBuilder(boolean.class)
.name(Component.literal("Custom Boolean Toggle"))
- .description(OptionDescription.createBuilder()
- .name(Component.literal("Custom Boolean Toggle"))
+ .description(val -> OptionDescription.createBuilder()
+ .name(Component.literal("Custom Boolean Toggle " + val))
.description(Component.literal("You can customize controllers like so! YACL is truly infinitely customizable! This tooltip is long in order to demonstrate the cool, smooth scrolling of these descriptions. Did you know, they are also super clickable?! I know, cool right, YACL 3.x really is amazing."))
.image(Path.of("D:\\Xander\\Downloads\\_MG_0860-Enhanced-NR.png"), new ResourceLocation("yacl", "f.webp"))
.build())
- .tooltip(Component.literal("You can customize these controllers like this!"))
- .tooltip(Component.empty())
- .tooltip(opt -> Component.empty())
.binding(
defaults.customBooleanToggle,
() -> config.customBooleanToggle,