mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-13 17:56:25 +00:00
fix: GIFs don't animate
This commit is contained in:
@@ -258,8 +258,9 @@ function handleAttachmentDrop (codeEditor, storageKey, noteKey, dropEvent) {
|
|||||||
const originalFileName = path.basename(filePath)
|
const originalFileName = path.basename(filePath)
|
||||||
const fileType = file['type']
|
const fileType = file['type']
|
||||||
const isImage = fileType.startsWith('image')
|
const isImage = fileType.startsWith('image')
|
||||||
|
const isGif = fileType.endsWith('gif')
|
||||||
let promise
|
let promise
|
||||||
if (isImage) {
|
if (isImage && !isGif) {
|
||||||
promise = fixRotate(file).then(base64data => {
|
promise = fixRotate(file).then(base64data => {
|
||||||
return copyAttachment({type: 'base64', data: base64data, sourceFilePath: filePath}, storageKey, noteKey)
|
return copyAttachment({type: 'base64', data: base64data, sourceFilePath: filePath}, storageKey, noteKey)
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user