decord/source/intl/native/migration.tsx

55 lines
1.5 KiB
TypeScript
Raw Normal View History

2026-07-23 10:11:24 +00:00
// Module ID: 5460
// Function ID: 46649
2026-07-20 16:05:17 +00:00
// Name: IntlLink
2026-07-23 10:11:24 +00:00
// Dependencies: [31, 33, 4130, 689, 3849, 3827, 3829, 1273, 2]
2026-07-20 16:05:17 +00:00
2026-07-23 10:11:24 +00:00
// Module 5460 (IntlLink)
import result from "result";
import { jsx } from "jsxProd";
import _createForOfIteratorHelperLoose from "_createForOfIteratorHelperLoose";
const require = arg1;
2026-07-20 16:05:17 +00:00
class IntlLink {
constructor(arg0) {
target = global.target;
tmp2 = typeof target;
2026-07-23 10:11:24 +00:00
tmp = f46652(result.useContext(require("context").AccessibilityPreferencesContext).alwaysShowLinkDecorations);
2026-07-20 16:05:17 +00:00
if ("string" === tmp2) {
fn = () => {
2026-07-23 10:11:24 +00:00
const obj = outer1_1(outer1_2[5]);
return obj.openURL(outer1_1(outer1_2[6]).sanitizeUrl(target));
2026-07-20 16:05:17 +00:00
};
} else {
str = "object";
fn = target;
if ("object" === tmp2) {
tmp3 = null;
fn = target;
if (null != target.onClick) {
fn = target.onClick;
}
}
}
2026-07-23 10:11:24 +00:00
obj = { accessible: true, accessibilityRole: "link" };
2026-07-20 16:05:17 +00:00
obj.onPress = fn;
obj.style = tmp.link;
obj.children = global.children;
2026-07-23 10:11:24 +00:00
return jsx(require("Button").LegacyText, obj);
2026-07-20 16:05:17 +00:00
}
}
2026-07-23 10:11:24 +00:00
let closure_5 = _createForOfIteratorHelperLoose.createStyles((arg0) => {
2026-07-20 16:05:17 +00:00
let obj = {};
2026-07-23 10:11:24 +00:00
obj = { color: importDefault(689).colors.TEXT_LINK };
2026-07-20 16:05:17 +00:00
let str = "none";
if (arg0) {
str = "underline";
}
obj.textDecorationLine = str;
obj.link = obj;
return obj;
});
2026-07-23 10:11:24 +00:00
const result = require("_createForOfIteratorHelperLoose").fileFinishedImporting("intl/native/migration.tsx");
2026-07-20 16:05:17 +00:00
export { IntlLink };
export const I18nLinkComponent = IntlLink;