import Component from '../../component.js'
import CoUxPanel from './ux-panel.js'

export default class CoUxWizardStep extends Component {

  constructor(parent) {
    let selector = 'ux-wizard-step';
    super(parent, selector);
    //https://citnet.tech.ec.europa.eu/CITnet/stash/projects/CSDR/repos/eui/browse/packages/components/src/lib/ux-components/ux-wizard-step/ux-wizard-step.component.ts
  }
  get dataE2E()  {
    let path = '//div[@data-e2e = "ux-wizard-step"]';
    return this.currentPath + path;
  }
  async isActive() {
    return !(await(await $(this.dataE2E + '/self::div[@hidden]')).isExisting());
  }
  get panelCO() {
  return new CoUxPanel(this.dataE2E);
  }
  get label()  {
    let path = '/self::ux-panel[@label]';
    return this.panelCO.currentPath + path;
  }
  get title()  {
    let path = '//h5[contains(@class,"section-title")]';
    return this.dataE2E + path;
  }
  async isShowStepTitle() {
    return await (await $(this.title)).isExisting();
  }
  get content()  {
    let path = '//div[contains(@class,"content")]';
    return this.dataE2E + path;
  }
  async hasCustomContent() {
    return await (await $(this.content)).isExisting();
  }
  get wizardStepContent()  {
    let path = '//uxWizardStepContent';
    return this.content + path;
  }
}


