@import './variable.scss';
.x-rich-text {
  position: relative;
  &.editor {
    .w-e-toolbar {
      height: 100%;
      background: #f1f1f1;
      border: 1px solid #dcdfe6;
      border-bottom: none;
      border-radius: 2px 2px 0 0;
      flex-wrap: wrap;
      z-index: 99 !important;
      .w-e-menu {
        z-index: 91 !important;
        display: flex;
        align-items: center;
        .x-icon-soure-code {
          transform: rotateY(180deg);
        }
        .w-e-droplist {
          z-index: 92;
        }
      }
      .w-e-menu-tooltip {
        top: -35px !important;
        font-size: 12px;
      }
    }
    .back-source {
      position: absolute;
      top: 0;
      right: 0;
      z-index: 96;
      display: none !important;
      height: 32px;
      background-color: #dcdfe6;
      border: 0;
      border-radius: 2px;
      outline: 0;
    }
    .w-e-text-container {
      z-index: 90 !important;
      height: auto;
      background: #fff;
      // display: flex;
      border: 1px solid #dcdfe6;
      border-radius: 0 0 2px 2px;
      min-height: 100px;
      .placeholder {
        top: 1px;
        line-height: 16px;
      }
      p,
      .placeholder,
      .w-e-menu-panel p {
        padding: 10px 0;
        font-size: 12px !important;
        margin: 0;
      }
      &::before {
        position: absolute;
        top: 10px;
        left: 10px;
        line-height: 1.5;
        color: #c9c9d1;
        pointer-events: none;
        content: attr(data-placeholder);
      }
      .w-e-text {
        table {
          word-break: keep-all;
        }
        img {
          max-width: 100% !important;
          cursor: pointer;
        }
      }
    }
    .source-code-textarea {
      position: absolute;
      top: 0;
      z-index: 100;
      width: 100%;
      height: 100% !important;
      background: #fff;
      border: 1px solid #dcdfe6;
      border-radius: 4px;
      outline: 0;
      &:hover {
        .back-source {
          display: flex !important;
        }
      }
      .source-code-box {
        width: 100%;
        height: 100%;
        border: none;
        outline: 0;
        resize: none;
      }
    }
    .readOnlyEditor {
      position: absolute;
      top: 0;
      z-index: 95;
      width: 100%;
      height: 100%;
      cursor: not-allowed;
    }
    .maskEditor {
      position: absolute;
      top: 0;
      z-index: 95;
      width: 100%;
      height: 100%;
    }
    &.editor-error {
      .w-e-toolbar {
        border-color: #f56c6c;
      }
      .w-e-text-container {
        border-color: #f56c6c;
        border-top-color: #dcdfe6;
      }
    }
    &.editor-disabled {
      .w-e-toolbar {
        background-color: #f1f1f1;
        pointer-events: none;
      }
      .w-e-text-container {
        background-color: #f5f5f5;
      }
    }
  }
  width: 100%;
  .el-input-number {
    width: 100%;
    > span[role='button'] {
      // border: none;
      background: none;
    }
    .el-input {
      .el-input__inner {
        text-align: left;
      }
    }
  }

  .w-e-toolbar p,
  .w-e-text-container p,
  .w-e-menu-panel p {
    font-size: 12px !important;
  }
}