Post

Replies

Boosts

Views

Activity

Xcode 12.1 WidgetExtension Canvas Bug
I created a widget extension with Xcode 12. At that time everything was fine. But recently I update Xcode to 12.1, some elements of preview in canvas is missing. For example: Text element that foregroundColor has alpha was missing, either using withAlphaComponent of UIColor or opacity struct TWidgetEntryView : View {     var entry: Provider.Entry     let alphaColor = UIColor.red.withAlphaComponent(0.8)     var body: some View {         Text("Some Text")             .foregroundColor(Color(alphaColor))     } } 2. Text element with cornerRadius was missing. struct TWidgetEntryView : View {     var entry: Provider.Entry     var body: some View {         Text("Some Text")             .cornerRadius(3)     } } View with same code is fine in main app canvas. How to fix that? Thank you for any help.
2
0
515
Oct ’20