Radio button option

Example
TODO: Redo Kotlin example with Kotlin DSL for enumerables and radiobuttons
Using an integer index
@RadioButton(
title = "My Radio",
description = "This is my radio", // Recommended, default = ""
icon = "/my_radio.svg", // Optional, default = ""
category = "Radio Buttons", // Recommended, default = "General"
subcategory = "General", // Recommended, default = "General"
options = { "HELLO", "WORLD", "ONECONFIG" } // Recommended, default = {}
)
public static int myRadio = 0; // 0 = "HELLO"
Using a custom enum class
public enum MyRadioOptions {
HELLO,
WORLD,
ONECONFIG;
}
@RadioButton(
title = "My Radio",
description = "This is my radio", // Recommended, default = ""
icon = "/my_radio.svg", // Optional, default = ""
category = "Radio Buttons", // Recommended, default = "General"
subcategory = "General", // Recommended, default = "General"
// this field cannot be present when using an enum: options = { "HELLO", "WORLD", "ONECONFIG" }
)
public static MyRadioOptions myRadio = MyRadioOptions.HELLO;
Last updated