import Component from '../component.js';
import DivComponent from '../div.js';
import CoEuiIconButtonExpander from './eui-icon-button-expander.js';

export default class CoEuiTreeListItemRightContent extends Component {

  constructor(parent) {
    let selector = 'div[contains(@class,"eui-tree-list-item-header__content-right-content")]';
    super(parent, selector);
    //https://citnet.tech.ec.europa.eu/CITnet/stash/projects/CSDR/repos/eui/browse/packages/components/eui-tree-list/eui-tree-list-item.component.html
  }
  get wrapperCO(){
    return new DivComponent(this.currentPath).addPredicateClassContains('eui-tree-list-item-header__content-expand-toggle-wrapper');
  }
  get iconExpanderCO(){
    return new CoEuiIconButtonExpander(this.wrapperCO);
  }
  async notAlwaysExpanded(){
    return await (await this.iconExpanderCO.element()).isExisting();
  }
}


