Wrap long permission request text in approval UIs
The macOS ApprovalBar put the title and action buttons on one row, so a long file-path title got truncated. Stack title above the buttons so it wraps to as many lines as needed. Bump the iOS card's input summary cap from 3 to 8 lines. Both made text-selectable. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
@@ -35,7 +35,8 @@ struct ApprovalCardView: View {
|
|||||||
}
|
}
|
||||||
Text(approval.input.compactSummary)
|
Text(approval.input.compactSummary)
|
||||||
.font(.caption.monospaced())
|
.font(.caption.monospaced())
|
||||||
.lineLimit(3)
|
.lineLimit(8)
|
||||||
|
.textSelection(.enabled)
|
||||||
.padding(8)
|
.padding(8)
|
||||||
.frame(maxWidth: .infinity, alignment: .leading)
|
.frame(maxWidth: .infinity, alignment: .leading)
|
||||||
.background(Color(.secondarySystemBackground), in: RoundedRectangle(cornerRadius: 8))
|
.background(Color(.secondarySystemBackground), in: RoundedRectangle(cornerRadius: 8))
|
||||||
|
|||||||
Reference in New Issue
Block a user