iOS/Sources/Extensions/Widgets/Common/WidgetContentMargin.swift

13 lines
306 B
Swift

import Foundation
import SwiftUI
extension WidgetConfiguration {
func contentMarginsDisabledIfAvailable() -> some WidgetConfiguration {
if #available(iOSApplicationExtension 17.0, *) {
return self.contentMarginsDisabled()
} else {
return self
}
}
}