Skip to content

Commit

Permalink
ignore macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
Tieda Wei committed May 12, 2022
1 parent f3a6a7a commit 4e074d4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion Sources/BottomSheet/BottomSheet.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import SwiftUI

#if !os(macOS)
public struct BottomSheet<Content: View>: View {

private var dragToDismissThreshold: CGFloat { height * 0.2 }
Expand Down Expand Up @@ -124,4 +125,4 @@ public struct BottomSheet<Content: View>: View {
)
}
}

#endif
3 changes: 2 additions & 1 deletion Sources/BottomSheet/RoundedCorner.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import SwiftUI

#if !os(macOS)
extension View {
func cornerRadius(_ radius: CGFloat, corners: UIRectCorner) -> some View {
clipShape(RoundedCorner(radius: radius, corners: corners))
Expand All @@ -23,4 +24,4 @@ struct RoundedCorner: Shape {
return Path(path.cgPath)
}
}

#endif
3 changes: 2 additions & 1 deletion Sources/BottomSheet/ViewExtension.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import SwiftUI

#if !os(macOS)
public extension View {
func bottomSheet<Content: View>(
isPresented: Binding<Bool>,
Expand Down Expand Up @@ -67,4 +68,4 @@ public extension View {
}
}
}

#endif

0 comments on commit 4e074d4

Please sign in to comment.