file-type 18.1.0 → 18.2.0

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.
package/core.d.ts CHANGED
@@ -143,7 +143,8 @@ export type FileExtension =
143
143
  | 'vcf'
144
144
  | 'jls'
145
145
  | 'pst'
146
- | 'dwg';
146
+ | 'dwg'
147
+ | 'parquet';
147
148
 
148
149
  export type MimeType =
149
150
  | 'image/jpeg'
@@ -282,7 +283,8 @@ export type MimeType =
282
283
  | 'application/zstd'
283
284
  | 'image/jls'
284
285
  | 'application/vnd.ms-outlook'
285
- | 'image/vnd.dwg';
286
+ | 'image/vnd.dwg'
287
+ | 'application/x-parquet';
286
288
 
287
289
  export type FileTypeResult = {
288
290
  /**
package/core.js CHANGED
@@ -815,6 +815,13 @@ class FileTypeParser {
815
815
  };
816
816
  }
817
817
 
818
+ if (this.checkString('PAR1')) {
819
+ return {
820
+ ext: 'parquet',
821
+ mime: 'application/x-parquet',
822
+ };
823
+ }
824
+
818
825
  // -- 5-byte signatures --
819
826
 
820
827
  if (this.check([0x4F, 0x54, 0x54, 0x4F, 0x00])) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "file-type",
3
- "version": "18.1.0",
3
+ "version": "18.2.0",
4
4
  "description": "Detect the file type of a Buffer/Uint8Array/ArrayBuffer",
5
5
  "license": "MIT",
6
6
  "repository": "sindresorhus/file-type",
@@ -196,7 +196,8 @@
196
196
  "vcf",
197
197
  "jls",
198
198
  "pst",
199
- "dwg"
199
+ "dwg",
200
+ "parquet"
200
201
  ],
201
202
  "dependencies": {
202
203
  "readable-web-to-node-stream": "^3.0.2",
package/readme.md CHANGED
@@ -440,6 +440,7 @@ Returns a `Set<string>` of supported MIME types.
440
440
  - [`opus`](https://en.wikipedia.org/wiki/Opus_(audio_format)) - Audio file
441
441
  - [`orf`](https://en.wikipedia.org/wiki/ORF_format) - Olympus Raw image file
442
442
  - [`otf`](https://en.wikipedia.org/wiki/OpenType) - OpenType font
443
+ - [`parquet`](https://en.wikipedia.org/wiki/Apache_Parquet) - Apache Parquet
443
444
  - [`pcap`](https://wiki.wireshark.org/Development/LibpcapFileFormat) - Libpcap File Format
444
445
  - [`pdf`](https://en.wikipedia.org/wiki/Portable_Document_Format) - Portable Document Format
445
446
  - [`pgp`](https://en.wikipedia.org/wiki/Pretty_Good_Privacy) - Pretty Good Privacy
package/supported.js CHANGED
@@ -141,6 +141,7 @@ export const extensions = [
141
141
  'jls',
142
142
  'pst',
143
143
  'dwg',
144
+ 'parquet',
144
145
  ];
145
146
 
146
147
  export const mimeTypes = [
@@ -281,4 +282,5 @@ export const mimeTypes = [
281
282
  'image/jls',
282
283
  'application/vnd.ms-outlook',
283
284
  'image/vnd.dwg',
285
+ 'application/x-parquet',
284
286
  ];