
Update Banner
From syxUI — written for both platforms, not translated between them.
An app-update banner with a CTA.
Banners · SwiftUI · iOS 17
- banners
- swiftui
The actual source
UpdateBanner.swift
// Update Banner · syxUI · https://syxui.dev/components/bt-update
// Free in any project. Keep this line and credit syxUI where a person can read it.
import SwiftUI
let btBlue = Color(red: 0.0, green: 0.47, blue: 1.0)
// Update available banner
struct UpdateBanner: View {
var body: some View {
HStack(spacing: 12) {
Image(systemName: "arrow.down.circle.fill").font(.system(size: 24)).foregroundStyle(btBlue)
VStack(alignment: .leading, spacing: 2) { Text("Update available").font(.system(size: 14, weight: .semibold)); Text("Version 2.5 · Bug fixes & improvements").font(.system(size: 12)).foregroundStyle(.secondary) }
Spacer()
Text("Update").font(.system(size: 13, weight: .semibold)).foregroundStyle(.white).padding(.horizontal, 14).padding(.vertical, 7).background(btBlue, in: Capsule())
}.padding(14).frame(width: 350).background(Color(.systemBackground), in: RoundedRectangle(cornerRadius: 16, style: .continuous)).overlay(RoundedRectangle(cornerRadius: 16, style: .continuous).stroke(Color.primary.opacity(0.08), lineWidth: 1)).shadow(color: .black.opacity(0.06), radius: 12, y: 5)
}
}
iOS 17 · No dependencies
Dependencies
- SwiftUI
- No external dependencies
Requires iOS 17


