2026-07-20 16:05:17 +00:00
|
|
|
// Module ID: 212
|
2026-07-29 08:29:29 +00:00
|
|
|
// Function ID: 213
|
2026-07-20 16:05:17 +00:00
|
|
|
// Name: binaryToBase64
|
2026-07-23 10:11:24 +00:00
|
|
|
// Dependencies: [206]
|
2026-07-20 16:05:17 +00:00
|
|
|
|
|
|
|
|
// Module 212 (binaryToBase64)
|
2026-07-23 10:11:24 +00:00
|
|
|
const require = arg1;
|
|
|
|
|
const dependencyMap = arg6;
|
2026-07-20 16:05:17 +00:00
|
|
|
arg5.default = function binaryToBase64(arg0) {
|
|
|
|
|
let byteLength;
|
|
|
|
|
let byteOffset;
|
|
|
|
|
let uint8Array = arg0;
|
|
|
|
|
if (arg0 instanceof ArrayBuffer) {
|
|
|
|
|
const _Uint8Array = Uint8Array;
|
|
|
|
|
uint8Array = new Uint8Array(arg0);
|
|
|
|
|
}
|
|
|
|
|
if (uint8Array instanceof Uint8Array) {
|
2026-07-29 08:29:29 +00:00
|
|
|
return require(206) /* byteLength */.fromByteArray(uint8Array);
|
2026-07-20 16:05:17 +00:00
|
|
|
} else {
|
|
|
|
|
const _ArrayBuffer = ArrayBuffer;
|
|
|
|
|
if (ArrayBuffer.isView(uint8Array)) {
|
|
|
|
|
const buffer = uint8Array.buffer;
|
|
|
|
|
({ byteOffset, byteLength } = uint8Array);
|
|
|
|
|
const _Uint8Array2 = Uint8Array;
|
|
|
|
|
const uint8Array1 = new Uint8Array(buffer, byteOffset, byteLength);
|
2026-07-29 08:29:29 +00:00
|
|
|
return require(206) /* byteLength */.fromByteArray(uint8Array1);
|
2026-07-20 16:05:17 +00:00
|
|
|
} else {
|
|
|
|
|
const _Error = Error;
|
|
|
|
|
const error = new Error("data must be ArrayBuffer or typed array");
|
|
|
|
|
throw error;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
};
|