ReadonlychargingA Boolean value indicating whether the battery is currently being charged.
ReadonlychargingA number representing the remaining time in seconds until the battery is fully charged, or 0 if the battery is already fully charged or not charging.
ReadonlydischargingA number representing the remaining time in seconds until the battery is completely discharged and the system suspends.
ReadonlyhealthBattery health status. Available in KaiOS 2.5+.
ReadonlylevelA number representing the system's battery charge level scaled to a value between 0.0 and 1.0. A value of 0 means the battery is empty and the system is about to be suspended. A value of 1.0 means the battery is full. A value of 1.0 is also returned if the system is unable to determine the battery charge level.
Event handler called when the battery health changes. Available in KaiOS 2.5+.
Event handler called when the charging state changes.
Event handler called when the chargingTime property changes.
Event handler called when the dischargingTime property changes.
Event handler called when the level property changes.
ReadonlypresentBoolean indicating whether the battery is present. Available in KaiOS 2.5+.
ReadonlytemperatureBattery temperature value. Available in KaiOS 2.5+.
The addEventListener() method of the EventTarget interface sets up a function that will be called whenever the specified event is delivered to the target.
Optionaloptions: boolean | AddEventListenerOptionsThe dispatchEvent() method of the EventTarget sends an Event to the object, (synchronously) invoking the affected event listeners in the appropriate order.
The removeEventListener() method of the EventTarget interface removes an event listener previously registered with EventTarget.addEventListener() from the target.
Optionaloptions: boolean | EventListenerOptions
The BatteryManager interface provides information about the system's battery charge level. It is returned by the navigator.getBattery() method.
Example