Type alias MenuItemProps

MenuItemProps: {
    componentProps?: PressableProps;
    disabled?: boolean;
    dismissKeyboardOnPress?: boolean;
    divider?: boolean;
    icon?: CarbonIcon;
    iconColor?: string;
    lastItem?: boolean;
    onLongPress?: ((event) => void);
    onPress: ((event) => void);
    style?: StyleProp<ViewStyle>;
    text: string;
    textBreakMode?: TextBreakModes;
    textType?: TextTypes;
}

Props for MenuItem component

Type declaration

  • Optional componentProps?: PressableProps

    Direct props to set on the React Native component (including iOS and Android specific props). Most use cases should not need this.

  • Optional disabled?: boolean

    Indicate if item is disabled

  • Optional dismissKeyboardOnPress?: boolean

    Indicate if keyboard should be dismissed onPress

  • Optional divider?: boolean

    Indicate that divider should be rendered (does not apply to last item)

  • Optional icon?: CarbonIcon

    Set to an icon from Carbon (size 20).

  • Optional iconColor?: string

    Color of the icon (default is primary text)

  • Optional lastItem?: boolean

    Indicates that menu item is final item (this is used internally)

  • Optional onLongPress?: ((event) => void)
      • (event): void
      • onLongPress event

        Parameters

        • event: GestureResponderEvent

        Returns void

  • onPress: ((event) => void)
      • (event): void
      • onPress event

        Parameters

        • event: GestureResponderEvent

        Returns void

  • Optional style?: StyleProp<ViewStyle>

    Style to set on the item

  • text: string

    Text to render

  • Optional textBreakMode?: TextBreakModes

    Break mode for text. Default is to wrap text

  • Optional textType?: TextTypes

    Text type to render (Standard is default. Normally only body 01 or 02 should be used)

Generated using TypeDoc