Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4821.js (118.4 MB)
31 lines
973 B
TypeScript
31 lines
973 B
TypeScript
// Module ID: 1222
|
|
// Function ID: 1223
|
|
// Name: ProtoUtils
|
|
// Dependencies: [1186, 2]
|
|
// Exports: b64ToProto, protoToB64
|
|
|
|
// Module 1222 (ProtoUtils)
|
|
import _mod1186 from "module_1186" /* 1186 */;
|
|
import size from "module_2" /* 2 */;
|
|
|
|
const BINARY_READ_OPTIONS = {
|
|
readerFactory(dependencyMap) {
|
|
const textDecoder = new TextDecoder("utf-8");
|
|
const binaryReader = new _mod1186.BinaryReader(dependencyMap, textDecoder);
|
|
return binaryReader;
|
|
}
|
|
};
|
|
const result = size.fileFinishedImporting("utils/ProtoUtils.tsx");
|
|
|
|
export { BINARY_READ_OPTIONS };
|
|
export const b64ToProto = function b64ToProto(fromBinary, actionData) {
|
|
let fromBinaryResult = null;
|
|
if (null != actionData) {
|
|
const obj = _mod1186;
|
|
fromBinaryResult = fromBinary.fromBinary(obj.base64decode(actionData), obj);
|
|
}
|
|
return fromBinaryResult;
|
|
};
|
|
export const protoToB64 = function protoToB64(toBinary, favoriteGifs) {
|
|
return _mod1186.base64encode(toBinary.toBinary(favoriteGifs));
|
|
};
|