/*! phoscon-app 2024-01-19 */

export function initPages(pageParams){let c=pageParams.constants,s=pageParams.scanStates;return[{id:c.PAGE_INIT,url:"",eventHandler:[{event:c.BTN_ADD_THERMOSTAT_PRESSED,actions:[{type:c.OPEN_MODAL,data:"thermostatWizardModal"},{type:c.CALL_PAGE,data:c.PAGE_CONNECT},{type:c.REMOVE_CLASS_ELEM,data:{identifier:c.MODAL_FOOTER,c:c.DANGER}},{type:c.REMOVE_CLASS_ELEM,data:{identifier:c.MODAL_FOOTER,c:c.SUCCESS}}]}]},{id:c.PAGE_CONNECT,url:"devices-thermostats/thermostat/page-1.html",eventHandler:[{event:c.ON_ENTRY,actions:[{type:c.SHOW_PAGE,data:"PAGE_CONNECT"},{type:c.ADD_CLASS_ELEM,data:{identifier:c.BTN_NEXT,c:c.DISABLE}},{type:c.REMOVE_CLASS_ELEM,data:{identifier:c.MODAL_FOOTER,c:c.DANGER}},{type:s.START_SCAN,data:180}]},{event:c.BTN_PREV_PRESSED,actions:[{type:s.STOP_SCAN},{type:c.CLOSE_MODAL,data:"thermostatWizardModal"}]},{event:s.DEVICE_ADDED,actions:[{type:s.STOP_SCAN},{type:c.CALL_PAGE,data:"THERMOSTAT_PAGE_2"}]},{event:s.NO_DEVICE_ADDED,actions:[{type:s.STOP_SCAN},{type:c.CALL_PAGE,data:"THERMOSTAT_PAGE_ERROR"}]},{event:c.BTN_CLOSE_PRESSED,actions:[{type:s.STOP_SCAN},{type:c.CLOSE_MODAL,data:"thermostatWizardModal"}]}]},{id:"THERMOSTAT_PAGE_2",url:"devices-thermostats/thermostat/page-2.html",eventHandler:[{event:c.ON_ENTRY,actions:[{type:c.SHOW_PAGE,data:"THERMOSTAT_PAGE_2"},{type:c.ADD_CLASS_ELEM,data:{identifier:c.MODAL_FOOTER,c:c.SUCCESS}}]},{event:c.BTN_NEXT_PRESSED,actions:[{type:s.STOP_SCAN},{type:c.CLOSE_MODAL,data:"thermostatWizardModal"},{type:c.CALL_FUNC,data:"routeToDetails"}]},{event:c.BTN_CLOSE_PRESSED,actions:[{type:s.STOP_SCAN},{type:c.CLOSE_MODAL,data:"thermostatWizardModal"}]}]},{id:"THERMOSTAT_PAGE_ERROR",url:"devices-thermostats/thermostat/page-error.html",eventHandler:[{event:c.ON_ENTRY,actions:[{type:s.STOP_SCAN},{type:c.SHOW_PAGE,data:"THERMOSTAT_PAGE_ERROR"},{type:c.ADD_CLASS_ELEM,data:{identifier:c.MODAL_FOOTER,c:c.DANGER}}]},{event:c.BTN_PREV_PRESSED,actions:[{type:c.CALL_PAGE,data:"PAGE_CONNECT"}]},{event:c.BTN_CLOSE_PRESSED,actions:[{type:c.CLOSE_MODAL,data:"thermostatWizardModal"}]}]}]};