Skip to content

Commit

Permalink
Merge pull request Esri#966 from Esri/zach/fixFloatingPanelOnVisionOS
Browse files Browse the repository at this point in the history
Update corner radius for floating panel on visionOS
  • Loading branch information
zkline101 authored Nov 12, 2024
2 parents eab0ab4 + 0e1632d commit fff325a
Showing 1 changed file with 10 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ struct FloatingPanel<Content>: View where Content: View {
.clipShape(
RoundedCorners(
corners: isPortraitOrientation ? [.topLeft, .topRight] : .allCorners,
radius: 10
radius: .cornerRadius
)
)
.shadow(radius: 10)
Expand Down Expand Up @@ -223,6 +223,15 @@ private extension CGFloat {
static let handleFrameHeight: CGFloat = 30

static let minHeight: CGFloat = 66

/// The corner radius of the floating panel.
static let cornerRadius: CGFloat = {
#if os(visionOS)
32
#else
10
#endif
}()
}

private extension Color {
Expand Down

0 comments on commit fff325a

Please sign in to comment.