Add unit hint to color-temperature-abs system channel type (#4451)

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
This commit is contained in:
lolodomo 2024-11-17 08:58:59 +01:00 committed by GitHub
parent 31d3434893
commit be003029b0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -243,8 +243,8 @@ public class DefaultSystemChannelTypeProvider implements ChannelTypeProvider {
*/
public static final ChannelType SYSTEM_COLOR_TEMPERATURE_ABS = ChannelTypeBuilder
.state(SYSTEM_CHANNEL_TYPE_UID_COLOR_TEMPERATURE_ABS, "Color Temperature", "Number:Temperature")
.withDescription("Controls the color temperature of the light in Kelvin").withCategory("ColorLight")
.isAdvanced(true)
.withUnitHint("K").withDescription("Controls the color temperature of the light in Kelvin")
.withCategory("ColorLight").isAdvanced(true)
.withStateDescriptionFragment(StateDescriptionFragmentBuilder.create().withMinimum(new BigDecimal(1000))
.withMaximum(new BigDecimal(10000)).withPattern("%.0f K").build())
.withTags(List.of("Control", "ColorTemperature")).build();