import { browser , element , by } from 'protractor' ; import { PageBase } from '../../core' ; export class ManageLoginPage extends PageBase { constructor ( ) { super ( '/manage/login' ) ; } email ( email ) { element ( by . id ( 'email' ) ) . sendKeys ( email ) ; return this ; } password ( password ) { element ( by . id ( 'password' ) ) . sendKeys ( password ) ; return this ; } login ( ) { this . loginButton ( ) . submit ( ) ; return this ; } canLogin ( ) { return this . loginButton ( ) . isEnabled ( ) ; } private loginButton ( ) { return element ( by . tagName ( 'button' ) ) ; } }