decord/source/modules/application_assets_v2/ApplicationAssetV2Utils.tsx
github-actions 67d978d9fb chore: update source for alpha 346.0
Skipped 1 file(s) >100MB (GitHub limit): source/__vendor/09xxx/9672_m.js (378.6 MB)
2026-09-07 16:44:02 +00:00

38 lines
1.5 KiB
TypeScript

// Module ID: 9034
// Function ID: 9035
// Name: getApplicationAssetUrl
// Dependencies: [1272, 1430, 2]
// Exports: getApplicationAssetUrl
// Module 9034 (getApplicationAssetUrl)
import set from "set" /* 2 */;
import sendRequest from "sendRequest" /* 1272 */;
import handleImageLoad from "handleImageLoad" /* 1430 */;
let result = set.fileFinishedImporting("modules/application_assets_v2/ApplicationAssetV2Utils.tsx");
export const getApplicationAssetUrl = function getApplicationAssetUrl(closure_1, asset_id, width) {
if (null != window.GLOBAL_ENV.CDN_HOST) {
const _URL2 = URL;
const _location = location;
const _window = window;
const _HermesInternal2 = HermesInternal;
let str5 = new URL("" + location.protocol + "//" + window.GLOBAL_ENV.CDN_HOST + "/app-assets/" + closure_1 + "/" + asset_id.asset_id + ".webp");
} else {
const _URL = URL;
const _HermesInternal = HermesInternal;
str5 = new URL("" + sendRequest.getAPIBaseURL() + "/applications/" + closure_1 + "/app-assets/" + asset_id.asset_id + ".webp");
const obj = sendRequest;
}
if (null != width) {
const searchParams = str5.searchParams;
const obj2 = handleImageLoad;
const result = searchParams.set("size", handleImageLoad.getBestMediaProxySize(width).toString());
const str11 = handleImageLoad.getBestMediaProxySize(width);
}
if (asset_id.metadata.is_animated) {
const searchParams2 = str5.searchParams;
const result1 = searchParams2.set("animated", "true");
}
return str5.toString();
};