From 7bfbbc908d53c379fa36a929282e7f20b95afde8 Mon Sep 17 00:00:00 2001 From: xander Date: Fri, 2 Sep 2022 10:45:53 +0100 Subject: fix group validation & icon & wiki test stuff --- src/main/java/dev/isxander/yacl/api/ConfigCategory.java | 3 ++- src/main/resources/fabric.mod.json | 1 + src/main/resources/icon.png | Bin 0 -> 17130 bytes 3 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 src/main/resources/icon.png (limited to 'src/main') diff --git a/src/main/java/dev/isxander/yacl/api/ConfigCategory.java b/src/main/java/dev/isxander/yacl/api/ConfigCategory.java index b6ddcc2..5aafc62 100644 --- a/src/main/java/dev/isxander/yacl/api/ConfigCategory.java +++ b/src/main/java/dev/isxander/yacl/api/ConfigCategory.java @@ -136,12 +136,13 @@ public interface ConfigCategory { public ConfigCategory build() { Validate.notNull(name, "`name` must not be null to build `ConfigCategory`"); - Validate.notEmpty(rootOptions, "`at least one option must be added to build `ConfigCategory`"); List combinedGroups = new ArrayList<>(); combinedGroups.add(new OptionGroupImpl(Text.empty(), ImmutableList.copyOf(rootOptions), true)); combinedGroups.addAll(groups); + Validate.notEmpty(combinedGroups, "at least one option must be added to build `ConfigCategory`"); + MutableText concatenatedTooltip = Text.empty(); boolean first = true; for (Text line : tooltipLines) { diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index 708c30e..0061d05 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -12,6 +12,7 @@ "issues": "https://github.com/${github}/issues", "sources": "https://github.com/${github}" }, + "icon": "icon.png", "license": "LGPL-3.0-or-later", "environment": "client", "entrypoints": { diff --git a/src/main/resources/icon.png b/src/main/resources/icon.png new file mode 100644 index 0000000..3f6dae4 Binary files /dev/null and b/src/main/resources/icon.png differ -- cgit