Created
November 9, 2022 16:57
-
-
Save BetterProgramming/a871651f0151c07856b76b4c472e64da to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct DailyQuote_ComplicationsEntryView : View { | |
@Environment(\.widgetFamily) var widgetFamily | |
var entry: Provider.Entry | |
var body: some View { | |
switch widgetFamily { | |
case .accessoryCorner: | |
ComplicationCorner() | |
case .accessoryCircular: | |
ComplicationCircular() | |
case .accessoryInline: | |
ComplicationInline() | |
case .accessoryRectangular: | |
ComplicationRectangular() | |
@unknown default: | |
//mandatory as there are more widget families as in lockscreen widgets etc | |
Text("Not an implemented widget yet") | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment