1
0
Fork 0
mirror of https://github.com/codedread/bitjs synced 2025-10-05 02:19:24 +02:00

1.0.6: Return 'vp9' for the video codec in getFullMIMEString(). Also move the annoying warning in deprecated archive.js.

This commit is contained in:
Jeff Schiller 2022-11-25 10:58:12 -08:00
parent d3b8765b42
commit 726feee48f
6 changed files with 16 additions and 14 deletions

View file

@ -15,8 +15,6 @@ import { UnarchiveAppendEvent, UnarchiveErrorEvent, UnarchiveEvent, UnarchiveEve
UnrarrerInternal, UntarrerInternal, UnzipperInternal,
getUnarchiverInternal } from './decompress-internal.js';
console.warn(`Stop using archive.js and use decompress.js instead. This module will be removed.`);
export {
UnarchiveAppendEvent,
UnarchiveErrorEvent,
@ -58,18 +56,22 @@ export {
const createWorkerFn = (scriptFilename) => new Worker(scriptFilename);
function warn() {
console.warn(`Stop using archive.js and use decompress.js instead. This module will be removed.`);
}
// Thin wrappers of unarchivers for clients who want to construct a specific
// unarchiver themselves rather than use getUnarchiver().
export class Unzipper extends UnzipperInternal {
constructor(ab, options) { super(ab, createWorkerFn, options); }
constructor(ab, options) { warn(); super(ab, createWorkerFn, options); }
}
export class Unrarrer extends UnrarrerInternal {
constructor(ab, options) { super(ab, createWorkerFn, options); }
constructor(ab, options) { warn(); super(ab, createWorkerFn, options); }
}
export class Untarrer extends UntarrerInternal {
constructor(ab, options) { super(ab, createWorkerFn, options); }
constructor(ab, options) { warn(); super(ab, createWorkerFn, options); }
}
/**
@ -83,5 +85,6 @@ export class Untarrer extends UntarrerInternal {
* @returns {Unarchiver}
*/
export function getUnarchiver(ab, options = {}) {
warn();
return getUnarchiverInternal(ab, createWorkerFn, options);
}