Capability used to mark lights that support setting color temperature natively.
js
- if(thing.matches('cap:color:temperature')) {
console.log('Range is', thing.colorTemperatureRange);
}
Implementors of this capability should call setColorTemperatureRange
either in the constructor or initCallback
.
Example:
js
const { Light, ColorTemperature } = require('abstract-things/lights');
class Example extends Light.with(ColorTemperature) {
- constructor() {
super();
this.updateColorTemperatureRange(2000, 5000);
}
}