Skip to content
Progress Bar preview
Rendered from the SwiftUI source on this page.

Progress Bar

From syxUI — written for both platforms, not translated between them.

A determinate progress bar.

Loaders · SwiftUI · iOS 17

  • loaders
  • swiftui

The actual source

ProgressBarLoader.swift
// Progress Bar · syxUI · https://syxui.dev/components/loader-progress
// Free in any project. Keep this line and credit syxUI where a person can read it.

import SwiftUI

let ldBlue = Color(red: 0.0, green: 0.47, blue: 1.0)

struct ProgressBarLoader: View { var body: some View { VStack(alignment: .leading, spacing: 8) { HStack { Text("Uploading").font(.system(size: 14, weight: .medium)); Spacer(); Text("68%").font(.system(size: 13)).foregroundStyle(.secondary) }; GeometryReader { g in ZStack(alignment: .leading) { Capsule().fill(Color.primary.opacity(0.08)).frame(height: 8); Capsule().fill(ldBlue).frame(width: g.size.width * 0.68, height: 8) } }.frame(height: 8) }.frame(width: 280) } }
iOS 17 · No dependencies

Dependencies

SwiftUI
No external dependencies

Requires iOS 17