import * as React from "react"; import { StyleProp, View, ViewStyle } from "react-native"; import Surface from "../Surface"; import { DefaultTheme } from "styled-components"; declare type Props = React.ComponentProps & { /** * Resting elevation of the card which controls the drop shadow. */ elevation?: number; /** * Function to execute on long press. */ onLongPress?: () => void; /** * Function to execute on press. */ onPress?: () => void; /** * Content of the `Card`. */ children: React.ReactNode; style?: StyleProp; /** * @optional */ theme?: DefaultTheme; /** * Pass down testID from card props to touchable */ testID?: string; /** * Pass down accessible from card props to touchable */ accessible?: boolean; }; /** * A card is a sheet of material that serves as an entry point to more detailed information. * *
* * *
* * ## Usage * ```js * import * as React from 'react'; * import { AvatarIcon } from 'react-native-simple-elements/components/Avatar'; * import Button from 'react-native-simple-elements/components/Button'; * import Card from 'react-native-simple-elements/components/Card'; * import { Title, Paragraph } from 'react-native-simple-elements/components/Text'; * * const LeftContent = props => * * const MyComponent = () => ( * * * * Card title * Card content * * * * * * * * ); * * export default MyComponent; * ``` */ declare const Card: { ({ elevation: cardElevation, onLongPress, onPress, children, style, testID, accessible, ...rest }: Props): JSX.Element; Content: { ({ index, total, siblings, style, ...rest }: import("react-native").ViewProps & React.RefAttributes & { children: React.ReactNode; index?: number; total?: number; siblings?: string[]; style?: StyleProp; }): JSX.Element; displayName: string; }; Actions: { (props: import("react-native").ViewProps & React.RefAttributes & { children: React.ReactNode; style?: StyleProp; }): JSX.Element; displayName: string; /** * A card is a sheet of material that serves as an entry point to more detailed information. * *
* * *
* * ## Usage * ```js * import * as React from 'react'; * import { AvatarIcon } from 'react-native-simple-elements/components/Avatar'; * import Button from 'react-native-simple-elements/components/Button'; * import Card from 'react-native-simple-elements/components/Card'; * import { Title, Paragraph } from 'react-native-simple-elements/components/Text'; * * const LeftContent = props => * * const MyComponent = () => ( * * * * Card title * Card content * * * * * * * * ); * * export default MyComponent; * ``` */ }; Cover: { ({ index, total, style, ...rest }: import("react-native").ImageProps & React.RefAttributes & { index?: number; total?: number; style?: StyleProp; theme?: DefaultTheme; }): JSX.Element; displayName: string; }; Title: { ({ title, titleStyle, titleNumberOfLines, subtitle, subtitleStyle, subtitleNumberOfLines, left, leftStyle, right, rightStyle, style, }: import("react-native").ViewProps & React.RefAttributes & { title: React.ReactNode; titleStyle?: StyleProp; titleNumberOfLines?: number; subtitle?: React.ReactNode; subtitleStyle?: StyleProp; subtitleNumberOfLines?: number; left?: (props: { size: number; }) => React.ReactNode; /** * Pass down testID from card props to touchable */ leftStyle?: StyleProp; right?: (props: { size: number; }) => React.ReactNode; rightStyle?: StyleProp; index?: number; total?: number; style?: StyleProp; theme?: DefaultTheme; }): JSX.Element; displayName: string; }; }; export default Card;