Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions Sources/CodexBar/PreferencesProviderSettingsRows.swift
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,13 @@ struct ProviderSettingsFieldRowView: View {
}
}
}

if let footer = self.field.footerText, !footer.isEmpty {
Text(footer)
.font(.footnote)
.foregroundStyle(.secondary)
.fixedSize(horizontal: false, vertical: true)
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ struct CopilotProviderImplementation: ProviderImplementation {
id: "copilot-api-token",
title: "GitHub Login",
subtitle: "Requires authentication via GitHub Device Flow.",
footerText: "Device code is copied to your clipboard — paste with ⌘V.",
kind: .secure,
placeholder: "Sign in via button below",
binding: context.stringBinding(\.copilotAPIToken),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ struct ProviderSettingsFieldDescriptor: Identifiable {
let id: String
let title: String
let subtitle: String
var footerText: String? = nil
let kind: Kind
let placeholder: String?
let binding: Binding<String>
Expand Down