/** * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * @generated SignedSource<> * * This file was translated from Flow by scripts/js-api/build-types/index.js. * Original file: packages/react-native/Libraries/Components/Touchable/TouchableOpacity.js */ import type { HostInstance } from "../../../src/private/types/HostInstance"; import type { ViewStyleProp } from "../../StyleSheet/StyleSheet"; import type { TVViewProps } from "../TV/TVViewPropTypes"; import type { TouchableWithoutFeedbackProps } from "./TouchableWithoutFeedback"; import Animated from "../../Animated/Animated"; import * as React from "react"; export type TouchableOpacityInstance = HostInstance; type TouchableOpacityBaseProps = Readonly<{ /** * Opacity of the wrapped view when touch is active. * * @default `0.2` */ activeOpacity?: number | undefined; style?: Animated.WithAnimatedValue | undefined; hostRef?: React.Ref | undefined; }>; export type TouchableOpacityProps = Readonly & Omit & Omit & {}>; declare const Touchable: (props: Omit & { ref?: React.Ref | undefined; }) => React.ReactNode; /** * A wrapper for making views respond properly to touches. On press down, the opacity of the wrapped view is decreased, dimming it. * * Opacity is controlled by wrapping the children in an `Animated.View`, which is added to the view hierarchy. Be aware that this can affect layout. * * If you need more extensive and future-proof touch handling, use `Pressable`. * * @see https://reactnative.dev/docs/touchableopacity */ declare const $$TouchableOpacity: typeof Touchable; declare type $$TouchableOpacity = typeof $$TouchableOpacity; export default $$TouchableOpacity;