mirror of
https://github.com/plankanban/planka.git
synced 2025-12-17 17:23:25 +03:00
Add covers for cards
This commit is contained in:
@@ -98,6 +98,15 @@ const CardModal = React.memo(
|
||||
[onUpdate],
|
||||
);
|
||||
|
||||
const handleCoverUpdate = useCallback(
|
||||
(newCoverAttachmentId) => {
|
||||
onUpdate({
|
||||
coverAttachmentId: newCoverAttachmentId,
|
||||
});
|
||||
},
|
||||
[onUpdate],
|
||||
);
|
||||
|
||||
const handleAttachmentFileSelect = useCallback(
|
||||
(file) => {
|
||||
onAttachmentCreate({
|
||||
@@ -278,6 +287,7 @@ const CardModal = React.memo(
|
||||
items={attachments}
|
||||
onUpdate={onAttachmentUpdate}
|
||||
onDelete={onAttachmentDelete}
|
||||
onCoverUpdate={handleCoverUpdate}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user