UNPKG

@payfit/unity-components

Version:

34 lines (33 loc) 1.91 kB
import { TextProps } from '../../text/Text.js'; export type ListViewItemTextProps = Omit<TextProps, 'variant' | 'color'>; /** * The ListViewItemText component displays the primary text label for a list item, providing accessible identification and consistent typography. * @param {ListViewItemTextProps} props - The props for the ListViewItemText component, inheriting all Text props except `variant` and `color` (which are preset) * @example * ```tsx * import { ListView, RawListViewItem, ListViewItemText } from '@payfit/unity-components' * * function Example() { * return ( * <ListView> * <RawListViewItem> * <ListViewItemLabel>Employee Name</ListViewItemLabel> * <ListViewItemText>Employee Name</ListViewItemText> * </RawListViewItem> * </ListView> * ) * } * ``` * @remarks * - This component is used to display the text content of a list item * - It inherits the disabled state styling from its parent RawListViewItem * - It uses the bodySmall variant with the neutral.low color * - It is automatically masked for privacy in Datadog recordings via the data-dd-privacy="mask" attribute * @see {@link ListViewItemTextProps} for all available props * @see Source code in {@link https://github.com/PayFit/hr-apps/tree/master/libs/shared/unity/components/src/components/list-view/parts GitHub} * @see Design specs {@link https://www.figma.com/design/poaMyU7abAgL9VRhx4ygyy/Unity-DS-%3E-Components-Library?node-id=15306-942&m=dev Figma} * @see Design docs in {@link https://www.payfit.design/ Payfit.design} * @see Developer docs in {@link https://unity-components.payfit.io/?path=/docs/component-reference-listview-listviewitemtext--docs unity-components.payfit.io} */ declare const ListViewItemText: import('react').ForwardRefExoticComponent<ListViewItemTextProps & import('react').RefAttributes<HTMLElement>>; export { ListViewItemText };