code: function setAttributes($inner, el) {
    const popper = el.popper;
    $inner.innerHTML = el.popper._content;
    if (!popper.popper) return;
    const isShow = !popper._disabled && (popper._visible || popper._always) && (!popper._ellipsis || isEllipsisTooltip(el));
  
    /**
     *  如果appendToBody popper显示和隐藏是通过直接在document body上移除和添加该元素
     *  否则，设置popper元素的display属性
     */
    if (popper._appendToBody) {
      if (isShow && popper.popper.parentNode !== document.body) {
        document.body.appendChild(popper.popper);
      }
      if (!isShow && popper.popper.parentNode === document.body) {
        document.body.removeChild(popper.popper);
      }
    } else {
      popper.popper.style.display = isShow ? '' : 'none';
    }
  }
docs: 设置innerhtml并计算popper的display