Skip to main content
239

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Themes
Apple docs
AIApple

Tool activity

Disclose tool status and results.

Public APILumenToolActivityApple / SwiftUISwift product: LumenUI

Apple availability

Supported native targets

Import LumenUI in the target that uses this component. iPad support follows the iOS package baseline and uses native iPad layout behavior.

iPhone · iOS 16+iPad · iPadOS 16+Mac · macOS 13+Apple Vision · visionOS 1+

Native example

Use Tool activity

The host runs the tool and updates status and statusLabel. Keep it collapsed unless the result needs attention.

Tool activity rendered in the iPhone simulator Lumen playground
Captured exampleiPhone simulatorView dark appearance
swift
import LumenUI
import SwiftUI

struct ToolActivityExample: View {
    let isRunning: Bool

    var body: some View {
        LumenToolActivity("Search documentation", status: isRunning ? .running : .success,
                          statusLabel: isRunning ? "Searching…" : "Found 3 pages") {
            Text("Query: prompt composer keyboard")
        }
    }
}
Apple
A collapsible record of one tool call whose status text is announced politely when it changes.

Reference

Public API

The primary shared and platform-specific options exposed by LumenToolActivity.

APIValues or typeDefaultDescription
label / status / statusLabelsummary / tool status / status textrequired / queued / requiredThe host runs the tool and updates status and statusLabel.

Native behavior

Design and accessibility

When to use it

The host runs the tool and updates status and statusLabel. Keep it collapsed unless the result needs attention.

Accessibility

Summary button with expanded state; status label announced politely.

Shared component

Available on other platforms

React NativeAndroid / Compose Web
Apple docsSwiftUI package