Browse Source

fix: Fixed dnd for group by

pull/6812/head
Muhammed Mustafa 1 year ago
parent
commit
47bca8fcf3
  1. 6
      packages/nc-gui/components/smartsheet/grid/useColumnDrag.ts

6
packages/nc-gui/components/smartsheet/grid/useColumnDrag.ts

@ -48,7 +48,11 @@ export const useColumnDrag = ({
e.dataTransfer.setData('text/plain', colId)
draggedCol.value = fields.value.find((f) => f.id === colId) ?? null
dragColPlaceholderDomRef.value!.style.height = `${tableBodyEl.value?.getBoundingClientRect().height}px`
const remInPx = parseFloat(getComputedStyle(document.documentElement).fontSize)
const placeholderHeight = tableBodyEl.value?.getBoundingClientRect().height ?? 6.1 * remInPx
dragColPlaceholderDomRef.value!.style.height = `${placeholderHeight}px`
const x = e.clientX - leftSidebarWidth.value

Loading…
Cancel
Save