/* 根节点不拦截事件，空白区域 mousedown 可透传到下层，让 react-zoom-pan-pinch 正常平移画布 */
.pisell-floor-map-layout-editable-item-layer {
  cursor: default;
  pointer-events: none;
}

.pisell-floor-map-layout-editable-item {
  cursor: move;
  outline: none;
  pointer-events: auto;
  /* 避免触控时浏览器滚动/缩放抢走 gesture，保证可连续收到 pointermove */
  touch-action: none;

  &-selected {
    box-shadow: 0 0 0 2px #1677ff;
    z-index: 2;
  }

  &-inner {
    width: 100%;
    height: 100%;
    pointer-events: none;
  }
}

.pisell-floor-map-layout-editable-resize-handle {
  width: 10px;
  height: 10px;
  margin: -5px;
  background: #1677ff;
  border: 1px solid #fff;
  border-radius: 2px;
  cursor: nwse-resize;
  pointer-events: auto;
  touch-action: none;
  z-index: 3;

  &-nw {
    left: 0;
    top: 0;
    cursor: nwse-resize;
  }

  &-n {
    left: 50%;
    top: 0;
    margin-left: -5px;
    cursor: ns-resize;
  }

  &-ne {
    right: 0;
    top: 0;
    cursor: nesw-resize;
  }

  &-e {
    right: 0;
    top: 50%;
    margin-top: -5px;
    cursor: ew-resize;
  }

  &-se {
    right: 0;
    bottom: 0;
    cursor: nwse-resize;
  }

  &-s {
    left: 50%;
    bottom: 0;
    margin-left: -5px;
    cursor: ns-resize;
  }

  &-sw {
    left: 0;
    bottom: 0;
    cursor: nesw-resize;
  }

  &-w {
    left: 0;
    top: 50%;
    margin-top: -5px;
    cursor: ew-resize;
  }
}
