Dim secondary splash facts

This commit is contained in:
piexel committed 2026-11-18 20:32:17 +01:00
1 parent 415aee9f4d
commit 5f70643446
3 files changed
+36 -8

No files matched your search

@@ -1545,7 +1545,7 @@ public final class IrisRuntime implements IrisPluginRuntime {
boolean eagerInjection = IrisSettings.get().getGeneral().isEagerRuntimeInjection(); boolean eagerInjection = IrisSettings.get().getGeneral().isEagerRuntimeInjection();
boolean datapackFromBootstrap = DefaultPackBootstrapProvisioner.wasProvisionedThisStartup(); boolean datapackFromBootstrap = DefaultPackBootstrapProvisioner.wasProvisionedThisStartup();
return List.of( return List.of(
List.of(new IrisSplashComposer.Detail("Packs", IrisSplashComposer.packSummary(packs))), List.of(IrisSplashComposer.Detail.key("Packs", IrisSplashComposer.packSummary(packs))),
List.of(new IrisSplashComposer.Detail("Custom biomes", String.valueOf(INMS.get().countCustomBiomes()))), List.of(new IrisSplashComposer.Detail("Custom biomes", String.valueOf(INMS.get().countCustomBiomes()))),
List.of(new IrisSplashComposer.Detail("SIMD", SimdSupport.shortStatus()), List.of(new IrisSplashComposer.Detail("SIMD", SimdSupport.shortStatus()),
new IrisSplashComposer.Detail("Datapack", datapackFromBootstrap ? "bootstrap" : "startup install"), new IrisSplashComposer.Detail("Datapack", datapackFromBootstrap ? "bootstrap" : "startup install"),
@@ -54,7 +54,9 @@ public final class IrisSplashComposer {
StringBuilder styled = new StringBuilder(); StringBuilder styled = new StringBuilder();
for (Detail detail : row) { for (Detail detail : row) {
String separator = styled.isEmpty() ? " " : " | "; String separator = styled.isEmpty() ? " " : " | ";
styled.append(style.label(separator + detail.label() + ": ")).append(style.value(detail.value())); String label = separator + detail.label() + ": ";
styled.append(detail.key() ? style.label(label) : style.quietLabel(label))
.append(detail.key() ? style.value(detail.value()) : style.quietValue(detail.value()));
} }
return styled.toString(); return styled.toString();
} }
@@ -71,10 +73,10 @@ public final class IrisSplashComposer {
"", "",
prefix + style.title(" Iris, ") + style.subtitle("Dimension Engine ") + style.tag("[" + releaseTrain + "]"), prefix + style.title(" Iris, ") + style.subtitle("Dimension Engine ") + style.tag("[" + releaseTrain + "]"),
prefix + style.label(" Version: ") + style.value(version), prefix + style.label(" Version: ") + style.value(version),
prefix + style.label(" By: ") + style.value("Volmit Software (Arcane Arts)"), prefix + style.quietLabel(" By: ") + style.quietValue("Volmit Software (Arcane Arts)"),
prefix + style.label(" Web: ") + style.value("VolmitSoftware.com"), prefix + style.quietLabel(" Web: ") + style.quietValue("VolmitSoftware.com"),
prefix + style.label(" Server: ") + style.value(serverLine), prefix + style.label(" Server: ") + style.value(serverLine),
prefix + style.label(" Java: ") + style.value(javaVersion() < 0 ? "unknown" : String.valueOf(javaVersion())) + style.label(" | Date: ") + style.value(startupDate()), prefix + style.quietLabel(" Java: ") + style.quietValue(javaVersion() < 0 ? "unknown" : String.valueOf(javaVersion())) + style.quietLabel(" | Date: ") + style.quietValue(startupDate()),
prefix + style.label(" Commit: ") + style.value(shortCommit()) + style.label("/") + style.value(BuildConstants.ENVIRONMENT), prefix + style.label(" Commit: ") + style.value(shortCommit()) + style.label("/") + style.value(BuildConstants.ENVIRONMENT),
"", "",
"", "",
@@ -142,7 +144,15 @@ public final class IrisSplashComposer {
return LocalDate.now().format(DateTimeFormatter.ISO_LOCAL_DATE); return LocalDate.now().format(DateTimeFormatter.ISO_LOCAL_DATE);
} }
public record Detail(String label, String value) { /** One labelled fact; a key fact is what support reads first and keeps the accent color, the rest are dimmed. */
public record Detail(String label, String value, boolean key) {
public Detail(String label, String value) {
this(label, value, false);
}
public static Detail key(String label, String value) {
return new Detail(label, value, true);
}
} }
public interface InfoStyle { public interface InfoStyle {
@@ -172,5 +182,13 @@ public final class IrisSplashComposer {
default String value(String text) { default String value(String text) {
return text; return text;
} }
default String quietLabel(String text) {
return label(text);
}
default String quietValue(String text) {
return value(text);
}
} }
} }
@@ -68,12 +68,12 @@ public enum Mode {
@Override @Override
public String subtitle(String text) { public String subtitle(String text) {
return C.AQUA + text; return C.WHITE + text;
} }
@Override @Override
public String tag(String text) { public String tag(String text) {
return C.RED + text; return C.DARK_GRAY + text;
} }
@Override @Override
@@ -85,6 +85,16 @@ public enum Mode {
public String value(String text) { public String value(String text) {
return color + text; return color + text;
} }
@Override
public String quietLabel(String text) {
return C.DARK_GRAY + text;
}
@Override
public String quietValue(String text) {
return C.GRAY + text;
}
}; };
} }