BatteryManager.dischargingTime
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
Indica a quantidade de tempo, em segundos, que restam até a bateria estar totalmente descarregada.
Sintaxe
var time = navigator.battery.dischargingTime
No retorno, time
é o tempo restante em segundos até que a bateria esteja totamente descarregada e o sistema suspenda. Este valor é Infinity
se a bateria estiver carregando, ao invés de descarregando, ou se o sistema não for capaz de determinar o tempo restante de carregamento (ou ainda se não existir uma bateria disponível).
Especificações
Specification |
---|
Battery Status API # dom-batterymanager-dischargingtime |
Compatibilidade com navegadores
Report problems with this compatibility data on GitHubdesktop | mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
dischargingTime |
Legend
Tip: you can click/tap on a cell for more information.
- Full support
- Full support
- Partial support
- Partial support
- No support
- No support
- Has more compatibility info.