The devicelight event is fired when fresh data is available from a light sensor.
General info
- Specification
- Sensor
- Interface
- SensorCallback
- Bubbles
- No
- Cancelable
- No
- Target
- DefaultView (window)
- Default Action
- None
Properties
| Property | Type | Description | 
|---|---|---|
| targetRead only | EventTarget | The event target (the topmost target in the DOM tree). | 
| typeRead only | DOMString | The type of event. | 
| bubblesRead only | Boolean | Whether the event normally bubbles or not | 
| cancelableRead only | Boolean | Whether the event is cancellable or not? | 
| valueRead only | Double (float) | The sensor data for ambient light in Lux. | 
| minRead only | Double (float) | The minimum value in the range the sensor detects (if available, 0 otherwise). | 
| maxRead only | Double (float) | The maximum value in the range the sensor detects (if available, 0 otherwise). |