@import (reference) '~antd/es/style/themes/default.less';

.nodeTitleWrapper {
  &:hover {
    .node {
      width: 180px;
      margin-left: 20px;
      padding-left: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      background-color: #fff;
      border-radius: 4px;
      box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.08);

      .nodeIcon {
        display: flex;
        justify-content: center;
        width: 32px;
        min-width: 32px;
        margin-right: 0;
        color: #1890ff;
        background-color: rgba(229, 238, 255, 0.85);
        cursor: move;
      }

      .label {
        padding-left: 8px;
        overflow: hidden;
        background-color: #fff;
        cursor: move;
      }
    }
  }

  .node {
    display: flex;
    height: 30px;
    padding-left: 20px;
    font-size: 12px;
    line-height: 30px;

    .nodeIcon {
      display: inline-flex;
      align-items: center;
      margin-right: 4px;
      color: #bfbfbf;
    }

    .label {
      display: inline-block;
      width: 200px;
      overflow: hidden;
      white-space: nowrap;
      text-overflow: ellipsis;
    }
  }
}

.keyword {
  color: #f50;
}

.folder {
  display: flex;
  justify-content: space-between;
  padding-right: 8px;

  .label {
    display: inline-block;
    width: 184px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  .team {
    float: right;
  }
}

:global {
  .@{ant-prefix}-tree-title {
    :local {
      .doc {
        position: absolute;
        top: 0;
        right: 5px;
        color: transparent; // 防止拖拽时文档两个字被带进去
        font-size: 10px;
        line-height: 30px;
      }
    }
  }
}

.popover {
  width: 360px;
  overflow: hidden;
  .monitor {
    margin: 8px 0;
    b {
      display: block;
      line-height: 24px;
    }
  }
  .doclink {
    padding: 8px 0 0;
  }
  .description {
    max-height: 600px;
    padding: 8px 4px;
    overflow: auto;
    word-break: break-all;
    background: #fbfbfb;
    border-radius: 4px;

    h1,
    h2,
    h3,
    h4,
    h5,
    h6,
    a,
    img,
    p,
    pre {
      max-width: 100%;
      margin: 0;
      font-size: 12px !important;
      line-height: 1.5em;
      word-break: break-all !important;
    }
  }
}

.tag {
  margin: 4px 0;
  .label {
    padding-right: 4px;
  }
}
