from selenium.webdriver.common.by import By


class MainPageLocators():
    MAIN_LINK = (By.CSS_SELECTOR, '#login_link')
    BROWSE_STORE = (By.ID, "browse")
    ALL_BOOKS = (By.XPATH, "//*[@id='browse']/li/ul/li[1]/a")
    HEADER_ALLBOOKS = (By.CLASS_NAME, "action")


class LoginPageLocators():
    LOGIN_FORM = (By.ID, 'login_form')
    REG_FORM = (By.ID, 'register_form')
    REG_LOGIN = (By.ID, 'id_registration-email')
    REG_PASSWORD1 = (By.ID, 'id_registration-password1')
    REG_PASSWORD2 = (By.ID, 'id_registration-password2')
    SUBMIT_BUTTON = (By.CSS_SELECTOR, 'button[name^="registration_submit"]')


class ProductPageLocators():
    ADD_TO_BASKET_BUTTON = (By.CLASS_NAME, "btn-add-to-basket")
    ITEM_NAME = (By.CSS_SELECTOR, '.product_main>h1')
    SUCCESS_MESSAGE = (By.CSS_SELECTOR, '.alertinner>strong:nth-child(1)')
    PRICE = (By.CSS_SELECTOR, '.product_main>.price_color')
    PRICE_MESSAGE = (By.CSS_SELECTOR, '.alertinner>p>strong')
    BASKET_BUTTON = (By.CSS_SELECTOR, '.basket-mini>span>a')
    EMPTY_BASKET = (By.ID, "content_inner")
    BASKET_EMPTY_MESSAGE = (By.XPATH, '//div[@id="content_inner"]//p[contains(text(),"Your basket is empty.")]')


class BasePageLocators():
    LOGIN_LINK = (By.CSS_SELECTOR, "#login_link")
    LOGIN_LINK_INVALID = (By.CSS_SELECTOR, "#login_link_inc")
    USER_ICON = (By.CLASS_NAME, "icon-user")

d6f87dcd4d5b0aaa302907372d3e9f51e434f801
<mask token>


class LoginPageLocators:
    LOGIN_FORM = By.ID, 'login_form'
    REG_FORM = By.ID, 'register_form'
    REG_LOGIN = By.ID, 'id_registration-email'
    REG_PASSWORD1 = By.ID, 'id_registration-password1'
    REG_PASSWORD2 = By.ID, 'id_registration-password2'
    SUBMIT_BUTTON = By.CSS_SELECTOR, 'button[name^="registration_submit"]'


class ProductPageLocators:
    ADD_TO_BASKET_BUTTON = By.CLASS_NAME, 'btn-add-to-basket'
    ITEM_NAME = By.CSS_SELECTOR, '.product_main>h1'
    SUCCESS_MESSAGE = By.CSS_SELECTOR, '.alertinner>strong:nth-child(1)'
    PRICE = By.CSS_SELECTOR, '.product_main>.price_color'
    PRICE_MESSAGE = By.CSS_SELECTOR, '.alertinner>p>strong'
    BASKET_BUTTON = By.CSS_SELECTOR, '.basket-mini>span>a'
    EMPTY_BASKET = By.ID, 'content_inner'
    BASKET_EMPTY_MESSAGE = (By.XPATH,
        '//div[@id="content_inner"]//p[contains(text(),"Your basket is empty.")]'
        )


class BasePageLocators:
    LOGIN_LINK = By.CSS_SELECTOR, '#login_link'
    LOGIN_LINK_INVALID = By.CSS_SELECTOR, '#login_link_inc'
    USER_ICON = By.CLASS_NAME, 'icon-user'

<mask token>


class MainPageLocators:
    <mask token>
    <mask token>
    <mask token>
    <mask token>


class LoginPageLocators:
    LOGIN_FORM = By.ID, 'login_form'
    REG_FORM = By.ID, 'register_form'
    REG_LOGIN = By.ID, 'id_registration-email'
    REG_PASSWORD1 = By.ID, 'id_registration-password1'
    REG_PASSWORD2 = By.ID, 'id_registration-password2'
    SUBMIT_BUTTON = By.CSS_SELECTOR, 'button[name^="registration_submit"]'


class ProductPageLocators:
    ADD_TO_BASKET_BUTTON = By.CLASS_NAME, 'btn-add-to-basket'
    ITEM_NAME = By.CSS_SELECTOR, '.product_main>h1'
    SUCCESS_MESSAGE = By.CSS_SELECTOR, '.alertinner>strong:nth-child(1)'
    PRICE = By.CSS_SELECTOR, '.product_main>.price_color'
    PRICE_MESSAGE = By.CSS_SELECTOR, '.alertinner>p>strong'
    BASKET_BUTTON = By.CSS_SELECTOR, '.basket-mini>span>a'
    EMPTY_BASKET = By.ID, 'content_inner'
    BASKET_EMPTY_MESSAGE = (By.XPATH,
        '//div[@id="content_inner"]//p[contains(text(),"Your basket is empty.")]'
        )


class BasePageLocators:
    LOGIN_LINK = By.CSS_SELECTOR, '#login_link'
    LOGIN_LINK_INVALID = By.CSS_SELECTOR, '#login_link_inc'
    USER_ICON = By.CLASS_NAME, 'icon-user'

<mask token>


class MainPageLocators:
    MAIN_LINK = By.CSS_SELECTOR, '#login_link'
    BROWSE_STORE = By.ID, 'browse'
    ALL_BOOKS = By.XPATH, "//*[@id='browse']/li/ul/li[1]/a"
    HEADER_ALLBOOKS = By.CLASS_NAME, 'action'


class LoginPageLocators:
    LOGIN_FORM = By.ID, 'login_form'
    REG_FORM = By.ID, 'register_form'
    REG_LOGIN = By.ID, 'id_registration-email'
    REG_PASSWORD1 = By.ID, 'id_registration-password1'
    REG_PASSWORD2 = By.ID, 'id_registration-password2'
    SUBMIT_BUTTON = By.CSS_SELECTOR, 'button[name^="registration_submit"]'


class ProductPageLocators:
    ADD_TO_BASKET_BUTTON = By.CLASS_NAME, 'btn-add-to-basket'
    ITEM_NAME = By.CSS_SELECTOR, '.product_main>h1'
    SUCCESS_MESSAGE = By.CSS_SELECTOR, '.alertinner>strong:nth-child(1)'
    PRICE = By.CSS_SELECTOR, '.product_main>.price_color'
    PRICE_MESSAGE = By.CSS_SELECTOR, '.alertinner>p>strong'
    BASKET_BUTTON = By.CSS_SELECTOR, '.basket-mini>span>a'
    EMPTY_BASKET = By.ID, 'content_inner'
    BASKET_EMPTY_MESSAGE = (By.XPATH,
        '//div[@id="content_inner"]//p[contains(text(),"Your basket is empty.")]'
        )


class BasePageLocators:
    LOGIN_LINK = By.CSS_SELECTOR, '#login_link'
    LOGIN_LINK_INVALID = By.CSS_SELECTOR, '#login_link_inc'
    USER_ICON = By.CLASS_NAME, 'icon-user'

from selenium.webdriver.common.by import By


class MainPageLocators:
    MAIN_LINK = By.CSS_SELECTOR, '#login_link'
    BROWSE_STORE = By.ID, 'browse'
    ALL_BOOKS = By.XPATH, "//*[@id='browse']/li/ul/li[1]/a"
    HEADER_ALLBOOKS = By.CLASS_NAME, 'action'


class LoginPageLocators:
    LOGIN_FORM = By.ID, 'login_form'
    REG_FORM = By.ID, 'register_form'
    REG_LOGIN = By.ID, 'id_registration-email'
    REG_PASSWORD1 = By.ID, 'id_registration-password1'
    REG_PASSWORD2 = By.ID, 'id_registration-password2'
    SUBMIT_BUTTON = By.CSS_SELECTOR, 'button[name^="registration_submit"]'


class ProductPageLocators:
    ADD_TO_BASKET_BUTTON = By.CLASS_NAME, 'btn-add-to-basket'
    ITEM_NAME = By.CSS_SELECTOR, '.product_main>h1'
    SUCCESS_MESSAGE = By.CSS_SELECTOR, '.alertinner>strong:nth-child(1)'
    PRICE = By.CSS_SELECTOR, '.product_main>.price_color'
    PRICE_MESSAGE = By.CSS_SELECTOR, '.alertinner>p>strong'
    BASKET_BUTTON = By.CSS_SELECTOR, '.basket-mini>span>a'
    EMPTY_BASKET = By.ID, 'content_inner'
    BASKET_EMPTY_MESSAGE = (By.XPATH,
        '//div[@id="content_inner"]//p[contains(text(),"Your basket is empty.")]'
        )


class BasePageLocators:
    LOGIN_LINK = By.CSS_SELECTOR, '#login_link'
    LOGIN_LINK_INVALID = By.CSS_SELECTOR, '#login_link_inc'
    USER_ICON = By.CLASS_NAME, 'icon-user'

from selenium.webdriver.common.by import By


class MainPageLocators():
    MAIN_LINK = (By.CSS_SELECTOR, '#login_link')
    BROWSE_STORE = (By.ID, "browse")
    ALL_BOOKS = (By.XPATH, "//*[@id='browse']/li/ul/li[1]/a")
    HEADER_ALLBOOKS = (By.CLASS_NAME, "action")


class LoginPageLocators():
    LOGIN_FORM = (By.ID, 'login_form')
    REG_FORM = (By.ID, 'register_form')
    REG_LOGIN = (By.ID, 'id_registration-email')
    REG_PASSWORD1 = (By.ID, 'id_registration-password1')
    REG_PASSWORD2 = (By.ID, 'id_registration-password2')
    SUBMIT_BUTTON = (By.CSS_SELECTOR, 'button[name^="registration_submit"]')


class ProductPageLocators():
    ADD_TO_BASKET_BUTTON = (By.CLASS_NAME, "btn-add-to-basket")
    ITEM_NAME = (By.CSS_SELECTOR, '.product_main>h1')
    SUCCESS_MESSAGE = (By.CSS_SELECTOR, '.alertinner>strong:nth-child(1)')
    PRICE = (By.CSS_SELECTOR, '.product_main>.price_color')
    PRICE_MESSAGE = (By.CSS_SELECTOR, '.alertinner>p>strong')
    BASKET_BUTTON = (By.CSS_SELECTOR, '.basket-mini>span>a')
    EMPTY_BASKET = (By.ID, "content_inner")
    BASKET_EMPTY_MESSAGE = (By.XPATH, '//div[@id="content_inner"]//p[contains(text(),"Your basket is empty.")]')


class BasePageLocators():
    LOGIN_LINK = (By.CSS_SELECTOR, "#login_link")
    LOGIN_LINK_INVALID = (By.CSS_SELECTOR, "#login_link_inc")
    USER_ICON = (By.CLASS_NAME, "icon-user")
