/** * 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/TV/TVViewPropTypes.js */ export type TVParallaxPropertiesType = Readonly<{ /** * If true, parallax effects are enabled. Defaults to true. */ enabled?: boolean | undefined; /** * Defaults to 2.0. */ shiftDistanceX?: number | undefined; /** * Defaults to 2.0. */ shiftDistanceY?: number | undefined; /** * Defaults to 0.05. */ tiltAngle?: number | undefined; /** * Defaults to 1.0 */ magnification?: number | undefined; /** * Defaults to 1.0 */ pressMagnification?: number | undefined; /** * Defaults to 0.3 */ pressDuration?: number | undefined; /** * Defaults to 0.3 */ pressDelay?: number | undefined; }>; /** * These props are for both Apple TV and Android TV. * TODO: update `@react-native/eslint-plugin` so that the * name can be changed to TVViewProps */ export type TVViewProps = Readonly<{ /** * @deprecated Replaced by `focusable`. * * @platform ios */ isTVSelectable?: boolean | undefined; /** * Whether this `View` should be focusable with a non-touch input device, eg. receive focus with a hardware keyboard. * */ focusable?: boolean | undefined; /** * May be set to true to force the focus engine to move focus to this view. * */ hasTVPreferredFocus?: boolean | undefined; /** * *(Apple TV only)* Object with properties to control Apple TV parallax effects. * * @platform ios */ tvParallaxProperties?: TVParallaxPropertiesType | undefined; /** * Additional properties needed for flow checks on TVFocusGuideView */ destinations?: Object[] | undefined; enabled?: boolean | undefined; autoFocus?: boolean | undefined; safePadding?: string | null | undefined; onPressIn?: ((event: any) => void) | undefined; onPressOut?: ((event: any) => void) | undefined; /** * TV next focus forward (see documentation for the View component). * * @platform android */ nextFocusForward?: number | undefined; /** * TV next focus down (see documentation for the View component). * */ nextFocusDown?: number | undefined; /** * TV next focus left (see documentation for the View component). * */ nextFocusLeft?: number | undefined; /** * TV next focus right (see documentation for the View component). * */ nextFocusRight?: number | undefined; /** * TV next focus up (see documentation for the View component). * */ nextFocusUp?: number | undefined; /** * Scroll snap alignment (used with snapToAlignment="item" in ScrollView). * */ scrollSnapAlign?: ("start" | "center" | "end") | undefined; /** * Per-item scroll snap offset in dp/pt. When set on a View inside a * ScrollView with `snapToAlignment="item"`, the focus engine lands the * View's top at viewport y = scrollSnapOffset. Standalone alternative to * `scrollSnapAlign` — set one or the other; if both are set on the same * View, `scrollSnapOffset` takes precedence. */ scrollSnapOffset?: number | undefined; }>;