decord/source/__polyfill/05xxx/module_5007.js
github-actions 03cf168fbc chore: update source for alpha 347.3
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4825.js (118.4 MB)
2026-09-17 08:17:09 +00:00

32 lines
976 B
JavaScript

// Module ID: 5007
// Function ID: 5008
// Dependencies: [17]
// Exports: parseAndroidIconToNativeProps
// Module 5007
import _mod17 from "module_17" /* 17 */;
const Image = _mod17.Image;
export const parseAndroidIconToNativeProps = function parseAndroidIconToNativeProps(icon) {
if (icon) {
if ("imageSource" === icon.type) {
const assetSource = Image.resolveAssetSource(icon.imageSource);
if (!assetSource) {
const _console = console;
console.error("[RNScreens] Failed to resolve an asset.");
}
const obj2 = { imageIconResource: assetSource };
return obj2;
} else if ("drawableResource" === icon.type) {
const obj = { drawableIconResourceName: icon.name };
return obj;
} else {
const _Error = Error;
const error = new Error("[RNScreens] Incorrect icon format for Android. You must provide `imageSource` or `drawableResource`.");
throw error;
}
} else {
return {};
}
};