feat: add upload dropzone, library select, and 2-step confirm to missing media

- Upload dropzone with drag & drop, file type validation, event propagation guard
- Use from Library dropdown with image/video thumbnail previews
- 2-step confirm flow: select/upload → status card → checkmark to apply
- Single node shows node display name; multiple nodes show filename with count
- Extract MIME type constants to shared mediaUploadUtil.ts (single source)
- Locate button visible only for single-node items
This commit is contained in:
jaeone94
2026-03-19 22:16:27 +09:00
parent 39352c857b
commit 5ed88ebd39
7 changed files with 663 additions and 47 deletions

View File

@@ -11,8 +11,10 @@ import { isImageUploadInput } from '@/types/nodeDefAugmentation'
import { createAnnotatedPath } from '@/utils/createAnnotatedPath'
import { addToComboValues } from '@/utils/litegraphUtil'
const ACCEPTED_IMAGE_TYPES = 'image/png,image/jpeg,image/webp'
const ACCEPTED_VIDEO_TYPES = 'video/webm,video/mp4'
import {
ACCEPTED_IMAGE_TYPES,
ACCEPTED_VIDEO_TYPES
} from '@/utils/mediaUploadUtil'
const isImageFile = (file: File) => file.type.startsWith('image/')
const isVideoFile = (file: File) => file.type.startsWith('video/')