mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-12-24 01:51:57 +03:00
Set file selection on drag when necessary
- the behaviour was unexpected if another file was already open
This commit is contained in:
parent
e4fab86085
commit
5ad6db4e07
@ -81,7 +81,7 @@
|
|||||||
on:dragstart={() => {
|
on:dragstart={() => {
|
||||||
// Reset selection if the file being dragged is not in the selected list
|
// Reset selection if the file being dragged is not in the selected list
|
||||||
if ($selectedFiles.length > 0 && !$selectedFiles.find((f) => f.id == file.id)) {
|
if ($selectedFiles.length > 0 && !$selectedFiles.find((f) => f.id == file.id)) {
|
||||||
$selectedFiles = [];
|
$selectedFiles = [file];
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
use:draggable={{
|
use:draggable={{
|
||||||
|
Loading…
Reference in New Issue
Block a user