From b893a723996f3c7013c6d129b34b5f24ab230caf Mon Sep 17 00:00:00 2001 From: Paul Date: Thu, 22 Oct 2026 17:25:03 -0400 Subject: [PATCH] Document image prop on top-bar actions --- .../docs/mobile/4/edge-components/top-bar.md | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/resources/views/docs/mobile/4/edge-components/top-bar.md b/resources/views/docs/mobile/4/edge-components/top-bar.md index f798080cf..b3d18a138 100644 --- a/resources/views/docs/mobile/4/edge-components/top-bar.md +++ b/resources/views/docs/mobile/4/edge-components/top-bar.md @@ -103,6 +103,7 @@ On iOS, if more than 5 actions are provided, they collapse into an overflow menu - `label` - Text label. Used for accessibility and displayed in overflow menus (optional but recommended) - `url` - A URL to navigate to when tapped (optional) - `destructive` - Render in the destructive (red) tint (optional, boolean) +- `image` - An image URL drawn as a small circle over the icon, e.g. the signed-in user's avatar (optional, string). See [Action images](#action-images) +### Action images + +Set `image` to show a picture, such as the signed-in user's avatar, in place of an action's icon. It works on plain +actions and on actions that open a menu. + +@verbatim +```blade static + + + +``` +@endverbatim + +With the `NavAction` builder, use `->image($url)`. Passing `null` or a blank string leaves the image unset: + +```php +NavAction::make('account')->icon('person')->image($user->avatar_url)->press('openAccount'); +``` + +The image is drawn as a 28pt circle over the icon. The icon shows while the image loads and stays if it fails to +load, so always set an `icon` too. A `disabled` action fades the image along with the icon. When `image` is unset the +action renders exactly as before. + ### Platform icons `` resolves icons through the same contract as [``](icon#typed-icon-enums): a