2026-09-28 16:18:32 +00:00
|
|
|
// Module ID: 11869
|
|
|
|
|
// Function ID: 11870
|
2026-09-18 19:45:33 +00:00
|
|
|
// Name: TouchableBackground
|
2026-09-28 16:18:32 +00:00
|
|
|
// Dependencies: [32, 19, 17, 21, 4836, 576, 2]
|
2026-09-26 17:57:22 +00:00
|
|
|
// Exports: default
|
2026-09-18 19:45:33 +00:00
|
|
|
|
2026-09-28 16:18:32 +00:00
|
|
|
// Module 11869 (TouchableBackground)
|
2026-10-01 14:13:23 +00:00
|
|
|
import Fragment from "Fragment" /* 21 */;
|
2026-09-26 17:57:22 +00:00
|
|
|
import nativeDefault from "native" /* 576 */;
|
2026-10-01 14:13:23 +00:00
|
|
|
import _slicedToArray from "_slicedToArray" /* 32 */;
|
|
|
|
|
import react from "react" /* 19 */;
|
|
|
|
|
import react_native from "react-native" /* 17 */;
|
|
|
|
|
import createStyles from "createStyles" /* 4836 */;
|
|
|
|
|
import size from "module_2" /* 2 */;
|
2026-09-18 19:45:33 +00:00
|
|
|
|
2026-10-01 14:13:23 +00:00
|
|
|
let c2;
|
|
|
|
|
let c3;
|
|
|
|
|
let obj2;
|
|
|
|
|
({ View: c2, Pressable: c3 } = react_native);
|
|
|
|
|
const jsx = Fragment.jsx;
|
|
|
|
|
const obj = { default: obj2 };
|
|
|
|
|
obj2 = { backgroundColor: nativeDefault.colors.INTERACTIVE_BACKGROUND_ACTIVE };
|
|
|
|
|
let closure_5 = createStyles.createStyles(obj);
|
2026-09-18 19:45:33 +00:00
|
|
|
const result = size.fileFinishedImporting("components_native/common/TouchableBackground.tsx");
|
|
|
|
|
|
2026-09-26 17:57:22 +00:00
|
|
|
export default function TouchableBackground(onPressOut) {
|
2026-10-01 14:13:23 +00:00
|
|
|
let activeBackgroundColor;
|
|
|
|
|
let c2;
|
|
|
|
|
let children;
|
|
|
|
|
let onPressIn;
|
|
|
|
|
let pressableStyle;
|
|
|
|
|
let style;
|
|
|
|
|
let tmp4;
|
2026-09-18 19:45:33 +00:00
|
|
|
({ activeBackgroundColor, onPressIn } = onPressOut);
|
|
|
|
|
onPressOut = onPressOut.onPressOut;
|
|
|
|
|
({ pressableStyle, style, children } = onPressOut);
|
|
|
|
|
const merged = Object.assign(onPressOut, Object.assign({ activeBackgroundColor: 0, pressableStyle: 0, style: 0, children: 0, onPressIn: 0, onPressOut: 0 }));
|
|
|
|
|
c2 = undefined;
|
2026-09-26 17:57:22 +00:00
|
|
|
const tmp2 = closure_5();
|
2026-10-01 14:13:23 +00:00
|
|
|
[tmp4, c2] = _slicedToArray(react.useState(false), 2);
|
2026-09-18 19:45:33 +00:00
|
|
|
const items = [onPressIn];
|
|
|
|
|
const items1 = [onPressOut];
|
2026-10-01 14:13:23 +00:00
|
|
|
const tmp3 = _slicedToArray(react.useState(false), 2);
|
|
|
|
|
const callback = react.useCallback((arg0) => {
|
2026-09-18 19:45:33 +00:00
|
|
|
_undefined(true);
|
|
|
|
|
if (onPressIn != null) {
|
|
|
|
|
tmp2(arg0);
|
|
|
|
|
}
|
|
|
|
|
}, items);
|
2026-10-01 14:13:23 +00:00
|
|
|
const callback1 = react.useCallback((arg0) => {
|
2026-09-18 19:45:33 +00:00
|
|
|
if (onPressOut != null) {
|
|
|
|
|
tmp(arg0);
|
|
|
|
|
}
|
|
|
|
|
_undefined(false);
|
|
|
|
|
}, items1);
|
|
|
|
|
const merged1 = Object.assign(merged);
|
|
|
|
|
const items2 = [style, ];
|
|
|
|
|
if (tmp4) {
|
|
|
|
|
if (activeBackgroundColor == null) {
|
|
|
|
|
activeBackgroundColor = tmp2.default.backgroundColor;
|
|
|
|
|
}
|
2026-10-01 14:13:23 +00:00
|
|
|
tmp4 = { backgroundColor: activeBackgroundColor };
|
2026-09-18 19:45:33 +00:00
|
|
|
}
|
|
|
|
|
items2[1] = tmp4;
|
2026-10-01 14:13:23 +00:00
|
|
|
return <tmp8 accessibilityRole="button" style={pressableStyle} onPressIn={callback} onPressOut={callback1}><tmp10 style={items2}>{children}</tmp10></tmp8>;
|
2026-09-26 17:57:22 +00:00
|
|
|
};
|