When to use it
The host authorizes and runs the operation, then updates status. Both buttons disable once decided.
Ask for an approve or reject decision on an application-owned request.
Apple availability
Import LumenUI in the target that uses this component. iPad support follows the iOS package baseline and uses native iPad layout behavior.
Native example
The host authorizes and runs the operation, then updates status. Both buttons disable once decided.
import LumenUI
import SwiftUI
struct DeployApprovalExample: View {
@State private var status = LumenApprovalStatus.pending
var body: some View {
LumenApprovalCard("Deploy release 6.0.0", requestId: "deploy-6-0-0", status: status,
statusLabel: status == .pending ? "Waiting for your decision" : "Decision recorded",
onResponse: { _, response in
status = response == .approve ? .approved : .rejected
}) {
Text("The assistant wants to publish the docs preview.")
}
}
}Reference
The primary shared and platform-specific options exposed by LumenApprovalCard.
| API | Values or type | Default | Description |
|---|---|---|---|
| requestId / status / onResponse | request identity / decision / response callback | required / pending / required | The host authorizes and runs the operation, then updates status. |
Native behavior
The host authorizes and runs the operation, then updates status. Both buttons disable once decided.
Card named by its label; decision status announced politely.
Shared component