@sprucelabs/schema 32.1.12 → 32.1.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  import { FieldDefinition } from './field.static.types';
2
- export declare const supportedFileTypes: readonly ["image/png", "image/svg+xml", "image/jpeg", "application/pdf", "text/csv", "image/*", "video/*", "*"];
2
+ export declare const supportedFileTypes: readonly ["image/png", "image/jpeg", "image/gif", "image/webp", "image/svg+xml", "image/bmp", "image/tiff", "image/heic", "video/mp4", "video/webm", "video/quicktime", "video/x-msvideo", "video/x-matroska", "audio/mpeg", "audio/wav", "audio/ogg", "audio/aac", "application/pdf", "application/msword", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", "application/vnd.ms-excel", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "application/vnd.ms-powerpoint", "application/vnd.openxmlformats-officedocument.presentationml.presentation", "text/plain", "text/csv", "application/rtf", "application/zip", "application/x-tar", "application/x-7z-compressed", "application/x-rar-compressed", "image/*", "video/*", "audio/*", "*"];
3
3
  export type SupportedFileType = (typeof supportedFileTypes)[number];
4
4
  export interface FileFieldValue {
5
5
  name: string;
@@ -1,10 +1,43 @@
1
1
  export const supportedFileTypes = [
2
+ // Images
2
3
  'image/png',
3
- 'image/svg+xml',
4
4
  'image/jpeg',
5
+ 'image/gif',
6
+ 'image/webp',
7
+ 'image/svg+xml',
8
+ 'image/bmp',
9
+ 'image/tiff',
10
+ 'image/heic',
11
+ // Video
12
+ 'video/mp4',
13
+ 'video/webm',
14
+ 'video/quicktime', // .mov
15
+ 'video/x-msvideo', // .avi
16
+ 'video/x-matroska', // .mkv
17
+ // Audio
18
+ 'audio/mpeg', // .mp3
19
+ 'audio/wav',
20
+ 'audio/ogg',
21
+ 'audio/aac',
22
+ // Documents
5
23
  'application/pdf',
24
+ 'application/msword', // .doc
25
+ 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', // .docx
26
+ 'application/vnd.ms-excel', // .xls
27
+ 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', // .xlsx
28
+ 'application/vnd.ms-powerpoint', // .ppt
29
+ 'application/vnd.openxmlformats-officedocument.presentationml.presentation', // .pptx
30
+ 'text/plain',
6
31
  'text/csv',
32
+ 'application/rtf',
33
+ // Archives
34
+ 'application/zip',
35
+ 'application/x-tar',
36
+ 'application/x-7z-compressed',
37
+ 'application/x-rar-compressed',
38
+ // Wildcards for broad support
7
39
  'image/*',
8
40
  'video/*',
41
+ 'audio/*',
9
42
  '*',
10
43
  ];
@@ -1,5 +1,5 @@
1
1
  import { FieldDefinition } from './field.static.types';
2
- export declare const supportedFileTypes: readonly ["image/png", "image/svg+xml", "image/jpeg", "application/pdf", "text/csv", "image/*", "video/*", "*"];
2
+ export declare const supportedFileTypes: readonly ["image/png", "image/jpeg", "image/gif", "image/webp", "image/svg+xml", "image/bmp", "image/tiff", "image/heic", "video/mp4", "video/webm", "video/quicktime", "video/x-msvideo", "video/x-matroska", "audio/mpeg", "audio/wav", "audio/ogg", "audio/aac", "application/pdf", "application/msword", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", "application/vnd.ms-excel", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "application/vnd.ms-powerpoint", "application/vnd.openxmlformats-officedocument.presentationml.presentation", "text/plain", "text/csv", "application/rtf", "application/zip", "application/x-tar", "application/x-7z-compressed", "application/x-rar-compressed", "image/*", "video/*", "audio/*", "*"];
3
3
  export type SupportedFileType = (typeof supportedFileTypes)[number];
4
4
  export interface FileFieldValue {
5
5
  name: string;
@@ -2,12 +2,45 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.supportedFileTypes = void 0;
4
4
  exports.supportedFileTypes = [
5
+ // Images
5
6
  'image/png',
6
- 'image/svg+xml',
7
7
  'image/jpeg',
8
+ 'image/gif',
9
+ 'image/webp',
10
+ 'image/svg+xml',
11
+ 'image/bmp',
12
+ 'image/tiff',
13
+ 'image/heic',
14
+ // Video
15
+ 'video/mp4',
16
+ 'video/webm',
17
+ 'video/quicktime', // .mov
18
+ 'video/x-msvideo', // .avi
19
+ 'video/x-matroska', // .mkv
20
+ // Audio
21
+ 'audio/mpeg', // .mp3
22
+ 'audio/wav',
23
+ 'audio/ogg',
24
+ 'audio/aac',
25
+ // Documents
8
26
  'application/pdf',
27
+ 'application/msword', // .doc
28
+ 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', // .docx
29
+ 'application/vnd.ms-excel', // .xls
30
+ 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', // .xlsx
31
+ 'application/vnd.ms-powerpoint', // .ppt
32
+ 'application/vnd.openxmlformats-officedocument.presentationml.presentation', // .pptx
33
+ 'text/plain',
9
34
  'text/csv',
35
+ 'application/rtf',
36
+ // Archives
37
+ 'application/zip',
38
+ 'application/x-tar',
39
+ 'application/x-7z-compressed',
40
+ 'application/x-rar-compressed',
41
+ // Wildcards for broad support
10
42
  'image/*',
11
43
  'video/*',
44
+ 'audio/*',
12
45
  '*',
13
46
  ];
package/package.json CHANGED
@@ -8,7 +8,7 @@
8
8
  "!build/__tests__",
9
9
  "esm"
10
10
  ],
11
- "version": "32.1.12",
11
+ "version": "32.1.14",
12
12
  "main": "./build/index.js",
13
13
  "types": "./build/index.d.ts",
14
14
  "module": "./build/esm/index.js",
@@ -58,8 +58,8 @@
58
58
  "build.copy-files": "mkdir -p build && rsync -avzq --exclude='*.ts' ./src/ ./build/"
59
59
  },
60
60
  "dependencies": {
61
- "@sprucelabs/error": "^7.0.33",
62
- "@sprucelabs/test-utils": "^6.0.53",
61
+ "@sprucelabs/error": "^7.1.0",
62
+ "@sprucelabs/test-utils": "^6.0.54",
63
63
  "email-validator": "^2.0.4",
64
64
  "just-safe-get": "^4.2.0",
65
65
  "just-safe-set": "^4.2.1"