import Component  from '../component.js'

export default class CoEuiLanguageSelector extends Component {
    constructor(parent) {
      let selector = 'eui-language-selector[contains(@class, "eui-app-toolbar__language-selector")]';
      super(parent, selector);
    }
    get dropdown() {
      return new CoEuiDropdown(this.currentPath);
    }
    get languageSelectorLink() {
      let path = '//a[contains(@class, "eui-language-selector-link")]';
      return this.dropdown.currentPath + path;
    }
    get languageSelectorLinkIcon() {
      let path = '//span[contains(@class, "eui-language-selector-link__icon")]';
      return this.languageSelectorLink + path;
    }
    get languageSelectorLinkCode() {
      let path = '//span[contains(@class, "eui-language-selector-link__language-code")]';
      return this.languageSelectorLink + path;
    }
    // eui-dropdown-content
    get languageSelectorMenu() {
      let path = '//div[contains(@class, "eui-language-selector-menu")]';
      return this.dropdown.matDropdownContent + path;
    }
    get languageSelectorItem() {
      let path = '//div[contains(@class, "eui-language-selector-menu-language-item")]';
      return this.languageSelectorMenu + path;
    }
}


