upload.ts 567 B

12345678910111213141516171819202122232425262728
  1. // Upload related types moved to a centralized type file
  2. export enum UPLOAD_STATUS {
  3. PENDING = 'pending',
  4. UPLOADING = 'uploading',
  5. SUCCESS = 'success',
  6. FAILED = 'failed',
  7. RETRYING = 'retrying',
  8. }
  9. export interface UploadImage {
  10. file: File
  11. status: UPLOAD_STATUS
  12. url: string | null
  13. error: string | null
  14. retryCount: number
  15. originalFile: File
  16. content?: string
  17. }
  18. export interface Workbench {
  19. warehouseCode: string
  20. workStation: string
  21. }
  22. export interface EditImageExposed {
  23. editImage: (image: UploadImage, type: 'outer' | 'inner') => void
  24. }