file-type
Advanced tools
Comparing version 14.4.0 to 14.5.0
@@ -135,3 +135,4 @@ /// <reference types="node"/> | ||
| 'avif' | ||
| 'eps'; | ||
| 'eps' | ||
| 'lzh'; | ||
@@ -260,3 +261,4 @@ type MimeType = | ||
| 'application/vnd.sketchup.skp' | ||
| 'image/avif'; | ||
| 'image/avif' | ||
| 'application/x-lzh-compressed'; | ||
@@ -263,0 +265,0 @@ interface FileTypeResult { |
20
core.js
@@ -832,2 +832,22 @@ 'use strict'; | ||
if ( | ||
checkString('-lh0-', {offset: 2}) || | ||
checkString('-lh1-', {offset: 2}) || | ||
checkString('-lh2-', {offset: 2}) || | ||
checkString('-lh3-', {offset: 2}) || | ||
checkString('-lh4-', {offset: 2}) || | ||
checkString('-lh5-', {offset: 2}) || | ||
checkString('-lh6-', {offset: 2}) || | ||
checkString('-lh7-', {offset: 2}) || | ||
checkString('-lzs-', {offset: 2}) || | ||
checkString('-lz4-', {offset: 2}) || | ||
checkString('-lz5-', {offset: 2}) || | ||
checkString('-lhd-', {offset: 2}) | ||
) { | ||
return { | ||
ext: 'lzh', | ||
mime: 'application/x-lzh-compressed' | ||
}; | ||
} | ||
// MPEG program stream (PS or MPEG-PS) | ||
@@ -834,0 +854,0 @@ if (check([0x00, 0x00, 0x01, 0xBA])) { |
{ | ||
"name": "file-type", | ||
"version": "14.4.0", | ||
"version": "14.5.0", | ||
"description": "Detect the file type of a Buffer/Uint8Array/ArrayBuffer", | ||
@@ -178,3 +178,4 @@ "license": "MIT", | ||
"avif", | ||
"eps" | ||
"eps", | ||
"lzh" | ||
], | ||
@@ -181,0 +182,0 @@ "devDependencies": { |
@@ -402,2 +402,3 @@ # file-type [![Build Status](https://travis-ci.com/sindresorhus/file-type.svg?branch=master)](https://travis-ci.ocomrg/sindresorhus/file-type) | ||
- [`eps`](https://en.wikipedia.org/wiki/Encapsulated_PostScript) - Encapsulated PostScript | ||
- [`lzh`](https://en.wikipedia.org/wiki/LHA_(file_format)) - LZH archive | ||
@@ -404,0 +405,0 @@ *Pull requests are welcome for additional commonly used file types.* |
@@ -133,3 +133,4 @@ 'use strict'; | ||
'avif', | ||
'eps' | ||
'eps', | ||
'lzh' | ||
], | ||
@@ -258,4 +259,5 @@ mimeTypes: [ | ||
'application/vnd.sketchup.skp', | ||
'image/avif' | ||
'image/avif', | ||
'application/x-lzh-compressed' | ||
] | ||
}; |
71802
1968
429