add drag&drop to kanban

This commit is contained in:
marlon-erler
2024-07-12 01:05:00 +02:00
parent a49724d71f
commit 5d645a084a
3 changed files with 79 additions and 11 deletions
+10 -1
View File
@@ -21,6 +21,10 @@ export function ObjectEntryView(
isShowingObjectModal.value = true;
}
function dragStart(event: DragEvent) {
event.dataTransfer?.setData("text", messageObject.id);
}
const fields = {
[icons.noteContent]: "---",
[icons.priority]: "---",
@@ -49,7 +53,12 @@ export function ObjectEntryView(
});
return (
<button class="tile justify-start" on:click={select}>
<button
class="tile justify-start"
on:click={select}
draggable="true"
on:dragstart={dragStart}
>
<div>
<b>{chat.getObjectTitle(messageObject)}</b>
<hr></hr>