selection
selection copied to clipboard
Is it possible to change the selection area initial position?
Feature request or a solution for this issue! Currently there is no feature in the library for this issue or I could not find one. I hope there is an optimal solution for this problem.
Issue
I would like to change the area-selection initial position inside of onBeforeStart event handler.
Description about issue:
- When the user moves the mouse over one item then there will displayed a button at the bottom left corner.
- User will be able to copy the current item properties to the newly selected items by selecting a range.
- And I want to change the area-selection start position to the center of the item when user starts copying.
Desired solution
This is how I imagine the solution for this issue:
const onBeforeStart = ({ event }: SelectionEvent) => {
if (isCopy.current === true) {
// Change area selection initial position
// ...
}
// Preventing select from right click, middle mouse or left click
return allowedButtons.current.includes(event.buttons);
};
That's a really cool idea, will definitely look into it :)