decord/source/5723_parsePossibleSources.js

43 lines
1 KiB
JavaScript
Raw Normal View History

2026-08-08 06:10:11 +00:00
// Module ID: 5723
// Function ID: 5724
2026-07-29 08:29:29 +00:00
// Name: parsePossibleSources
// Dependencies: [17]
// Exports: parsePossibleSources
2026-08-08 06:10:11 +00:00
// Module 5723 (parsePossibleSources)
2026-07-29 08:29:29 +00:00
import { Image } from "get ActivityIndicator";
export const parsePossibleSources = function parsePossibleSources(source) {
const uri = source.uri;
2026-08-04 21:03:28 +00:00
if (typeof source === "string") {
2026-07-29 08:29:29 +00:00
let obj = { sourceName: null };
obj[0] = source;
} else {
2026-08-04 21:03:28 +00:00
if (typeof source === "object") {
2026-07-29 08:29:29 +00:00
if (!uri) {
obj = { sourceJson: null };
const _JSON = JSON;
obj[0] = JSON.stringify(source);
}
}
2026-08-04 21:03:28 +00:00
if (typeof source !== "object") {
2026-07-29 08:29:29 +00:00
let tmp2;
2026-08-04 21:03:28 +00:00
if (typeof source === "number") {
2026-07-29 08:29:29 +00:00
obj = { sourceDotLottieURI: null };
obj[0] = Image.resolveAssetSource(source).uri;
tmp2 = obj;
}
}
if (uri.includes(".lottie")) {
const obj1 = { sourceDotLottieURI: null };
obj1[0] = uri;
let obj2 = obj1;
} else {
obj2 = { sourceURL: null };
obj2[0] = uri;
}
}
return obj;
};