What worked in ComingUp:
.buttonStyle(.borderedProminent)
.tint(.brandAccent)
In a toolbar, iOS 26 draws that as tinted Liquid Glass. Older versions get a filled capsule.
#SwiftUI #iOSDev
Explore it yourself here:
exploreswiftui.com/library/butt...
FB24397477
#iOSDev #SwiftUI
Explore it yourself here:
exploreswiftui.com/library/butt...
FB24397477
#iOSDev #SwiftUI
This disables the default whole-row tap target behavior (which causes this funky stuff)
This disables the default whole-row tap target behavior (which causes this funky stuff)
🚨 Cyber Monday Mega Sale! 🚨
💥 Up to 70% OFF + FREE SHIPPING! 💥
🎁 Shop your favorite deals today and save big on must-have items!
#CyberMonday #ShopNow #FreeShipping #HolidayDeals #MondayMotivation #London #Scotland #UK #USA #ShopSmart
🚨 Cyber Monday Mega Sale! 🚨
💥 Up to 70% OFF + FREE SHIPPING! 💥
🎁 Shop your favorite deals today and save big on must-have items!
#CyberMonday #ShopNow #FreeShipping #HolidayDeals #MondayMotivation #London #Scotland #UK #USA #ShopSmart
```
struct WTF: View {
var body: some View {
TabView { Tab { Text("First") } }
.tabViewBottomAccessory {
Button("Press me") { print("pressed") }
.buttonStyle(.glassProminent)
}
}
}
```
```
struct WTF: View {
var body: some View {
TabView { Tab { Text("First") } }
.tabViewBottomAccessory {
Button("Press me") { print("pressed") }
.buttonStyle(.glassProminent)
}
}
}
```
TIL a button in a `tabViewBottomAccessory` with a `buttonStyle` applied to it will cause AttributeGraph to cycle, so an `onTapGesture` it is!
TIL a button in a `tabViewBottomAccessory` with a `buttonStyle` applied to it will cause AttributeGraph to cycle, so an `onTapGesture` it is!
My memory was that this was exposed thru the environment, but apparently it's via a Shape extension (ButtonBorderShape.buttonShape), but that appears to always […]
My memory was that this was exposed thru the environment, but apparently it's via a Shape extension (ButtonBorderShape.buttonShape), but that appears to always […]
.buttonStyle(.borderless)
.popover(isPresented: $showDatePop, attachmentAnchor: .point(.trailing),arrowEdge: .trailing) {
DatePicker("Date", selection: $selectedDate, displayedComponents: .date)
.datePickerStyle(.graphical)
.labelsHidden()
.padding()
}
}
.buttonStyle(.borderless)
.popover(isPresented: $showDatePop, attachmentAnchor: .point(.trailing),arrowEdge: .trailing) {
DatePicker("Date", selection: $selectedDate, displayedComponents: .date)
.datePickerStyle(.graphical)
.labelsHidden()
.padding()
}
}
The only thing in it is a cancel button but the text is getting clipped. Happens also if I use .topBarLeading.
If I remove the placement the word cancel is shown just fine but the placement moves to the top right. 🤔
The only thing in it is a cancel button but the text is getting clipped. Happens also if I use .topBarLeading.
If I remove the placement the word cancel is shown just fine but the placement moves to the top right. 🤔
Even if I strip down my toolbar to only have the simplest elements I can't get it to compile if I'm using .sharedBackgroundVisibility.
I get the infamous "unable to type-check...". 🤔
#SwiftUI
Even if I strip down my toolbar to only have the simplest elements I can't get it to compile if I'm using .sharedBackgroundVisibility.
I get the infamous "unable to type-check...". 🤔
#SwiftUI