src/core/popover.js
/**
   * Prepares the dom element for popover
   */
Prepares the dom element for popover
Prepares the dom element for popover
makeNode() {
    let popover = this.document.getElementById(ID_POPOVER);
    if (!popover) {
      popover = Popover.createFromString(POPOVER_HTML);
      document.body.appendChild(popover);
    }
    this.node = popover;
    this.tipNode = popover.querySelector(`.${CLASS_POPOVER_TIP}`);
    this.titleNode = popover.querySelector(`.${CLASS_POPOVER_TITLE}`);
    this.descriptionNode = popover.querySelector(`.${CLASS_POPOVER_DESCRIPTION}`);
    this.footerNode = popover.querySelector(`.${CLASS_POPOVER_FOOTER}`);
    this.nextBtnNode = popover.querySelector(`.${CLASS_NEXT_STEP_BTN}`);
    this.prevBtnNode = popover.querySelector(`.${CLASS_PREV_STEP_BTN}`);
    this.closeBtnNode = popover.querySelector(`.${CLASS_CLOSE_BTN}`);
  }
makeNode ( ) { let popover = this . document . getElementById ( ID_POPOVER ) ; if ( ! popover ) { popover = Popover . createFromString ( POPOVER_HTML ) ; document . body . appendChild ( popover ) ; } this . node = popover ; this . tipNode = popover . querySelector ( ` ${ CLASS_POPOVER_TIP } ` ) ; this . titleNode = popover . querySelector ( ` ${ CLASS_POPOVER_TITLE } ` ) ; this . descriptionNode = popover . querySelector ( ` ${ CLASS_POPOVER_DESCRIPTION } ` ) ; this . footerNode = popover . querySelector ( ` ${ CLASS_POPOVER_FOOTER } ` ) ; this . nextBtnNode = popover . querySelector ( ` ${ CLASS_NEXT_STEP_BTN } ` ) ; this . prevBtnNode = popover . querySelector ( ` ${ CLASS_PREV_STEP_BTN } ` ) ; this . closeBtnNode = popover . querySelector ( ` ${ CLASS_CLOSE_BTN } ` ) ; }
Prepares the dom element for popover
Prepares the dom element for popover