Repository: expo/expo
File: packages/expo-router/src/link/elements.tsx (TypeScript)

Code before:
  destructive?: boolean;
  /**
   * If `true`, the menu item will be disabled and not selectable.
   *
   * @see [Apple documentation](https://developer.apple.com/documentation/uikit/uimenuelement/attributes/disabled) for more information.
   */
  disabled?: boolean;
  /**
   * An elaborated title that explains the purpose of the action.
   */
  discoverabilityLabel?: string;
  /**
   * Whether the menu element should be hidden.
   *
   * @see [Apple documentation](https://developer.apple.com/documentation/uikit/uimenuelement/attributes/hidden) for more information.
   *
   * @default false
   */
  hidden?: boolean;
  // TODO: support ImageSourcePropType icons in addition to SFSymbols
  /**
   * SF Symbol displayed alongside the menu item.
   */
  icon?: SFSymbol;
  /**
   * Custom image loaded using expo-image's `useImage` hook.
   * Takes priority over `icon` (SF Symbol) when both are provided.
   *
   * @example
   * ```tsx
   * import { useImage } from 'expo-image';
   * import { Link } from 'expo-router';
   *
   * const customIcon = useImage('https://picsum.photos/128', {
   *   maxWidth: 32,
   *   maxHeight: 32,
   * });
   *
   * <Link.Menu title="Menu">
   *   <Link.MenuAction image={customIcon} title="Action" onPress={() => {}} />
   * </Link.Menu>
   * ```
   */
  image?: ImageRef | null;
  /**
   * If `true`, the menu item will be displayed as selected.
   */
  isOn?: boolean;
  onPress?: () => void;
  /**
   * An optional subtitle for the menu item.

Review comment (suggestion):
```suggestion
   * Custom image loaded using `useImage()` hook from `expo-image`.
```


Code after:
  destructive?: boolean;
  /**
   * If `true`, the menu item will be disabled and not selectable.
   *
   * @see [Apple documentation](https://developer.apple.com/documentation/uikit/uimenuelement/attributes/disabled) for more information.
   */
  disabled?: boolean;
  /**
   * An elaborated title that explains the purpose of the action.
   */
  discoverabilityLabel?: string;
  /**
   * Whether the menu element should be hidden.
   *
   * @see [Apple documentation](https://developer.apple.com/documentation/uikit/uimenuelement/attributes/hidden) for more information.
   *
   * @default false
   */
  hidden?: boolean;
  // TODO: support ImageSourcePropType icons in addition to SFSymbols
  /**
   * SF Symbol displayed alongside the menu item.
   */
  icon?: SFSymbol;
  /**
   * Custom image loaded using `useImage()` hook from `expo-image`.
   * Takes priority over `icon` (SF Symbol) when both are provided.
   *
   * @example
   * ```tsx
   * import { useImage } from 'expo-image';
   * import { Link } from 'expo-router';
   *
   * const customIcon = useImage('https://simpleicons.org/icons/expo.svg', {
   *   maxWidth: 24,
   *   maxHeight: 24,
   * });
   *
   * <Link.Menu title="Menu">
   *   <Link.MenuAction image={customIcon} title="Action" onPress={() => {}} />
   * </Link.Menu>
   * ```
   */
  image?: ImageRef | null;
  /**
   * If `true`, the menu item will be displayed as selected.
   */
  isOn?: boolean;
  onPress?: () => void;
  /**
   * An optional subtitle for the menu item.