Add support for various tar archive formats

This commit is contained in:
2024-12-04 15:06:58 +01:00
parent 1c07f6ed1d
commit c36a3dc0c7
5 changed files with 56 additions and 15 deletions

View File

@@ -251,7 +251,11 @@ export const fs_node_type = (node: FSNode) => {
return "torrent"
} else if (
node.file_type === "application/zip" ||
node.file_type === "application/x-7z-compressed"
node.file_type === "application/x-7z-compressed" ||
node.file_type === "application/x-tar" ||
(node.file_type === "application/gzip" && node.name.endsWith(".tar.gz")) ||
(node.file_type === "application/x-xz" && node.name.endsWith(".tar.xz")) ||
(node.file_type === "application/zstd" && node.name.endsWith(".tar.zst"))
) {
return "zip"
} else if (node.file_type.startsWith("image")) {