Tilt the complication dumbbell to match the app icon
Rotate the dumbbell glyph -35° (counter-clockwise) in the circular, corner, and rectangular accessory families so it runs lower-left to upper-right like the app icon. Inline stays upright since that template renders the symbol on the time line.
This commit is contained in:
@@ -30,22 +30,32 @@ private struct LauncherView: View {
|
||||
|
||||
private let glyph = "dumbbell.fill"
|
||||
|
||||
// The app icon's dumbbell runs lower-left to upper-right; tilt the glyph
|
||||
// counter-clockwise to match (SwiftUI rotates clockwise for positive angles).
|
||||
private var dumbbell: some View {
|
||||
Image(systemName: glyph)
|
||||
.rotationEffect(.degrees(-35))
|
||||
}
|
||||
|
||||
var body: some View {
|
||||
switch family {
|
||||
case .accessoryInline:
|
||||
// Inline templates render the symbol upright next to text; leave as-is.
|
||||
Label("Workouts", systemImage: glyph)
|
||||
case .accessoryRectangular:
|
||||
Label("Workouts", systemImage: glyph)
|
||||
.font(.headline)
|
||||
HStack(spacing: 6) {
|
||||
dumbbell.font(.title3)
|
||||
Text("Workouts").font(.headline)
|
||||
}
|
||||
.frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .leading)
|
||||
case .accessoryCorner:
|
||||
Image(systemName: glyph)
|
||||
dumbbell
|
||||
.font(.title2)
|
||||
.widgetLabel("Workouts")
|
||||
default: // .accessoryCircular and any future families
|
||||
ZStack {
|
||||
AccessoryWidgetBackground()
|
||||
Image(systemName: glyph)
|
||||
dumbbell
|
||||
.font(.title3)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user