UNPKG

homebridge-levoit-humidifiers

Version:
25 lines 824 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const VeSyncFan_1 = require("../api/VeSyncFan"); const characteristic = { get: async function () { await this.device.updateInfo(); // If device is off, set the mode to null so the switch displays Off if (!this.device.isOn) { return false; } return this.device.mode === VeSyncFan_1.Mode.AutoPro; }, set: async function (value) { switch (value) { case true: await this.device.changeMode(VeSyncFan_1.Mode.AutoPro); break; case false: await this.device.changeMode(VeSyncFan_1.Mode.Manual); break; } }, }; exports.default = characteristic; //# sourceMappingURL=AutoProState.js.map