// Metro module 16109 (f16110). import { useCallback, useMemo } from "react"; import { ActivityIndicator, Linking, View, StyleSheet } from "react-native"; import Module6759 from "./Module6759"; let styles; const injectedJavaScript = `(${String(function() { const postMessage = window.ReactNativeWebView.postMessage; const patchedPostMessage = function patchedPostMessage(a0, a1, a2) { postMessage(a0, a1, a2); }; patchedPostMessage.toString = function() { return String(Object.hasOwnProperty).replace("hasOwnProperty", "postMessage"); }; window.ReactNativeWebView.postMessage = patchedPostMessage; })})();`; styles = StyleSheet.create({ loadingOverlay: { bottom: 0, justifyContent: "center", left: 0, position: "absolute", right: 0, top: 0 } }); export default (a0) => { const { onMessage, siteKey, style, url, languageCode } = a0; a0.cancelButtonText; const { showLoading, loadingIndicatorColor, backgroundColor, theme: theme2 } = a0; let theme = theme2; let rqdata = a0.rqdata; const r23 = "https://hcaptcha.com/1/api.js?render=explicit&onload=onloadCallback" + `&host=${siteKey ? siteKey : "missing-sitekey"}.react-native.hcaptcha.com`; const r24 = languageCode ? r23 + ("&hl=" + languageCode) : r23; let c22798_5 = typeof theme2 === "object" ? r24 + "&custom=true" : r24; const r29 = theme2 ? typeof theme2 === "string" : theme2; let r30 = theme2; if (r29) { theme = `"${theme2}"`; r30 = theme; } if (rqdata && typeof rqdata === "string") { rqdata = `"${rqdata}"`; } return { let r2 = event.url.slice(0, 24) !== "https://www.hcaptcha.com"; if (!r2) { Linking.openURL(event.url); r2 = false; } return r2; }} mixedContentMode="always" onMessage={onMessage} javaScriptEnabled injectedJavaScript={injectedJavaScript} automaticallyAdjustContentInsets style={[{ backgroundColor: "transparent", width: "100%" }, style]} source={{ html: useMemo(() => { let r10 = siteKey; if (!siteKey) { r10 = ""; } return `
`; }, [siteKey, backgroundColor, r30]), baseUrl: `${url}` }} renderLoading={useCallback(() => , [loadingIndicatorColor])} startInLoadingState={showLoading} />; };