Repository Public MIT
1{2 "accessibility" : [3 "The indicator and its label are one element: label (or \"Loading\" when none), value \"42 percent\" (or \"Loading\" when indeterminate), with the updates-frequently trait.",4 "The cancel button is a separate element labelled \"Cancel\" with the minimum hit target.",5 "The percentage uses monospaced digits so the label does not shift as the value changes."6 ],7 "category" : "feedback",8 "changelog" : [9 {10 "changes" : [11 "Release 1.1.0: see the project changelog."12 ],13 "date" : "2026-12-03",14 "version" : "1.1.0"15 },16 {17 "changes" : [18 "Initial release."19 ],20 "date" : "2026-12-02",21 "version" : "1.0.0"22 }23 ],24 "dependencies" : [25 {26 "id" : "glass-foundation",27 "version" : "1.1.0"28 }29 ],30 "description" : "Determinate or indeterminate system progress with an optional cancel action.",31 "examples" : [32 {33 "code" : "import SwiftUI\nimport SPGlassKit\n\npublic struct GlassProgressExample: GlassExample {\n public static let componentID = \"glass-progress\"\n @State private var uploaded = 30.0\n @State private var isCancelled = false\n\n public init() {}\n\n public var body: some View {\n VStack(alignment: .leading, spacing: 20) {\n if isCancelled {\n Text(\"Upload cancelled\").foregroundStyle(.secondary)\n } else {\n GlassProgress(\"Uploading sample.pdf\", value: uploaded, total: 120, onCancel: { isCancelled = true })\n }\n GlassProgress(\"Storage used\", value: 0.82, style: .circular)\n GlassProgress(\"Connecting\")\n GlassProgress(style: .circular)\n HStack(spacing: 24) {\n GlassProgress(\"Storage\", value: 0.82, style: .ring)\n GlassProgress(\"Battery\", value: 0.46, style: .ring)\n }\n GlassProgress(\"Shipping address\", step: 2, of: 4)\n HStack {\n GlassButton(\"Add 30 MB\") { uploaded += 30 }\n GlassButton(\"Restart\") {\n uploaded = 0\n isCancelled = false\n }\n }\n }\n .padding()\n }\n}\n\n#Preview(\"GlassProgress\") { GlassProgressExample() }\n",34 "title" : "GlassProgress example"35 }36 ],37 "files" : [38 {39 "bytes" : 14859,40 "path" : "Components/Feedback/GlassProgress.swift",41 "sha256" : "522ad99d9af9927f32f08991472f4ebab3a6381e2bfddbc8ca6ccf0b859be834"42 }43 ],44 "frameworks" : [4546 ],47 "id" : "glass-progress",48 "kind" : "native-wrapper",49 "license" : "MIT",50 "minimumOS" : {51 "iOS" : "26.0",52 "iPadOS" : "26.0",53 "macOS" : "26.0"54 },55 "name" : "GlassProgress",56 "platforms" : [57 "iOS",58 "iPadOS",59 "macOS"60 ],61 "schemaVersion" : 1,62 "sha256" : "defa9f1f04d4455d98b6aef780085fe05a69b04e5ccfc021126ad7d5549b8b09",63 "symbols" : [64 "GlassProgressStyle",65 "GlassProgressMath",66 "GlassProgress"67 ],68 "version" : "1.1.0"69}70