selecto icon indicating copy to clipboard operation
selecto copied to clipboard

Selectro Drag Area In Wrong Place (Offset by pixels)

Open jessejamesrich opened this issue 3 years ago • 2 comments

Environments

  • Framework name: Node / React
  • Framework version: v14.15.5 / 16.14.0
  • Component name: Selecto
  • Component version: 1.11.1
  • Testable Address(optional):

Description

When dragging the select area the area starts in the wrong spot, offset by top and left, often to the right and below the original area. The dragContainer is being resized after the component mounts which is potentially/likely causing the issue, though. Additionally, there is a transform: scale on the dragContainer.

There doesn't appear to method to update/recalculate the dragContainer bounding rect. Ideas on how to fix this?

jessejamesrich avatar Jun 15 '21 17:06 jessejamesrich

@jessejamesrich

  • selecto 1.12.1
  • react-selecto 1.12.0
  • preact-selecto 1.12.0
  • ngx-selecto 1.12.0
  • svelte-selecto 1.12.0
  • lit-selecto 1.12.0

selecto's new version is released.

rootContainer is added.

If you set the rootContainer it will work just fine. The rootContainer must not have a transform set.

daybrush avatar Jun 16 '21 18:06 daybrush

Thank you!

jessejamesrich avatar Jun 26 '21 07:06 jessejamesrich