File tree 2 files changed +12
-4
lines changed
Packages/Features/Sources
2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ public struct GlowingRoundedRectangle: ViewModifier {
17
17
endPoint: . bottomTrailing) ,
18
18
lineWidth: 1 )
19
19
}
20
- . clipShape ( RoundedRectangle ( cornerRadius: cornerRadius) )
20
+ . clipShape ( . rect ( cornerRadius: cornerRadius) )
21
21
. shadow ( color: . indigo. opacity ( 0.3 ) , radius: 2 )
22
22
}
23
23
}
Original file line number Diff line number Diff line change @@ -68,7 +68,6 @@ struct PostRowImagesView: View {
68
68
. resizable ( )
69
69
. scaledToFill ( )
70
70
. aspectRatio ( contentMode: index == images. images. indices. first ? . fit : . fill)
71
- . clipped ( )
72
71
} else {
73
72
RoundedRectangle ( cornerRadius: 8 )
74
73
. fill ( . thinMaterial)
@@ -77,8 +76,17 @@ struct PostRowImagesView: View {
77
76
. processors ( [ . resize( size: . init( width: finalWidth, height: finalHeight) ) ] )
78
77
. frame ( width: finalWidth, height: finalHeight)
79
78
. matchedTransitionSource ( id: image. fullSizeImageURL, in: namespace)
80
- . glowingRoundedRectangle ( )
81
- . shadow ( color: images. images. count > 1 ? . black. opacity ( 0.3 ) : . clear, radius: 3 )
79
+ . clipShape ( . rect( cornerRadius: 8 ) )
80
+ . overlay {
81
+ RoundedRectangle ( cornerRadius: 8 )
82
+ . stroke (
83
+ LinearGradient (
84
+ colors: [ . shadowPrimary. opacity ( 0.3 ) , . indigo. opacity ( 0.5 ) ] ,
85
+ startPoint: . topLeading,
86
+ endPoint: . bottomTrailing) ,
87
+ lineWidth: 1 )
88
+ }
89
+ . shadow ( color: . indigo. opacity ( 0.3 ) , radius: 3 )
82
90
. onAppear {
83
91
if index == images. images. indices. first {
84
92
self . firstImageSize = CGSize ( width: displayWidth, height: displayHeight)
You can’t perform that action at this time.
0 commit comments