mirror of
https://github.com/Kuingsmile/PicList.git
synced 2026-05-06 20:42:57 +08:00
✨ Feature(custom): uppercase image ext is now recognized as image in manage
This commit is contained in:
@@ -55,7 +55,9 @@ export const getRawData = (args: any): any => {
|
||||
const getExtension = (fileName: string) => path.extname(fileName).slice(1)
|
||||
|
||||
export const isImage = (fileName: string) =>
|
||||
['jpg', 'jpeg', 'png', 'gif', 'webp', 'bmp', 'ico', 'svg', 'avif'].includes(getExtension(fileName))
|
||||
['jpg', 'jpeg', 'png', 'gif', 'webp', 'bmp', 'ico', 'svg', 'avif'].includes(
|
||||
getExtension(fileName).toLocaleLowerCase(),
|
||||
)
|
||||
|
||||
export let tray: Tray
|
||||
|
||||
|
||||
Reference in New Issue
Block a user