Skip to content

Commit 19909d1

Browse files
committed
Replace most shadow cases to posShadow when applicable.
1 parent 6fdf296 commit 19909d1

File tree

4 files changed

+4
-8
lines changed

4 files changed

+4
-8
lines changed

WooCommerce/Classes/POS/Presentation/ItemListView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ private extension ItemListView {
116116
.fixedSize(horizontal: false, vertical: true)
117117
.background(Color.posSurfaceBright)
118118
.cornerRadius(Constants.bannerCornerRadius)
119-
.shadow(color: Color.black.opacity(0.08), radius: 4, y: 2)
119+
.posShadow(.medium)
120120
.accessibilityAddTraits(.isButton)
121121
.onTapGesture {
122122
showSimpleProductsModal = true

WooCommerce/Classes/POS/Presentation/Reusable Views/POSConnectivityView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ struct POSConnectivityView: View {
4040
.frame(minHeight: Constants.height)
4141
.background(Color.posSecondaryContainer)
4242
.cornerRadius(Constants.cornerRadius)
43-
.shadow(color: Color.posShadow.opacity(0.2), radius: 8, x: 0, y: 2)
43+
.posShadow(.medium)
4444
.frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .top)
4545
}
4646

WooCommerce/Classes/POS/Presentation/Reusable Views/POSItemCardBorderStylesModifier.swift

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ struct POSItemCardBorderStylesModifier: ViewModifier {
88
.stroke(Color.posShadow, lineWidth: Constants.nilOutline)
99
}
1010
.clipShape(RoundedRectangle(cornerRadius: Constants.cardCornerRadius))
11-
.shadow(color: Color.posShadow.opacity(0.04), radius: 12, x: 0, y: 8)
12-
.shadow(color: Color.posShadow.opacity(0.08), radius: 4, x: 0, y: 2)
11+
.posShadow(.medium)
1312
}
1413
}
1514

WooCommerce/Classes/POS/Presentation/Reusable Views/POSModalViewModifier.swift

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,7 @@ struct POSRootModalViewModifier: ViewModifier {
2727
modalManager.getContent()
2828
.background(Color.posSurfaceBright)
2929
.cornerRadius(POSCornerRadiusStyle.extraLarge.value)
30-
.shadow(color: Color.posShadow.opacity(0.02), radius: 43, x: 0, y: 50) // 0px 50px 43px 0px #00000005
31-
.shadow(color: Color.posShadow.opacity(0.04), radius: 36, x: 0, y: 30) // 0px 30px 36px 0px #0000000A
32-
.shadow(color: Color.posShadow.opacity(0.07), radius: 27, x: 0, y: 15) // 0px 15px 27px 0px #00000012
33-
.shadow(color: Color.posShadow.opacity(0.08), radius: 15, x: 0, y: 5) // 0px 5px 15px 0px #00000014
30+
.posShadow(.large)
3431
.padding()
3532
}
3633
.zIndex(1)

0 commit comments

Comments
 (0)