Skip to content

Commit 050b512

Browse files
committed
Update non-DS colors in POSConnectivityView and remove Color+Inverted extension with testing in preview.
1 parent dba7af8 commit 050b512

File tree

3 files changed

+9
-22
lines changed

3 files changed

+9
-22
lines changed

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

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,19 +28,19 @@ struct POSConnectivityView: View {
2828
@ViewBuilder private var noConnectionBanner: some View {
2929
HStack(spacing: Constants.spacing) {
3030
Image(systemName: "wifi.exclamationmark")
31-
.foregroundColor(Color(.text.inverted))
31+
.foregroundColor(Color.posOnSecondaryContainer)
3232
.font(.posBodySmallBold)
3333

3434
Text(Localization.title)
35-
.foregroundColor(Color(.text.inverted))
35+
.foregroundColor(Color.posOnSecondaryContainer)
3636
.font(.posBodySmallBold)
3737
}
3838
.padding(.vertical, Constants.verticalPadding)
3939
.padding(.horizontal, Constants.horizontalPadding)
4040
.frame(minHeight: Constants.height)
41-
.background(Color(.systemGray6.inverted))
41+
.background(Color.posSecondaryContainer)
4242
.cornerRadius(Constants.cornerRadius)
43-
.shadow(color: Color.black.opacity(0.2), radius: 8, x: 0, y: 2)
43+
.shadow(color: Color.posShadow.opacity(0.2), radius: 8, x: 0, y: 2)
4444
.frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .top)
4545
}
4646

@@ -67,3 +67,8 @@ private extension POSConnectivityView {
6767
)
6868
}
6969
}
70+
71+
#Preview {
72+
// To enable preview, set `isVisible` to `true` and comment out `onAppear` block.
73+
POSConnectivityView()
74+
}

WooCommerce/Classes/POS/Utils/Color+Inverted.swift

Lines changed: 0 additions & 14 deletions
This file was deleted.

WooCommerce/WooCommerce.xcodeproj/project.pbxproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
/* End PBXAggregateTarget section */
2222

2323
/* Begin PBXBuildFile section */
24-
010C9A8F2C75C2BF00EBA228 /* Color+Inverted.swift in Sources */ = {isa = PBXBuildFile; fileRef = 010C9A8E2C75C2BF00EBA228 /* Color+Inverted.swift */; };
2524
011D396F2D09FCD200DB1445 /* CardPresentModalLocationRequired.swift in Sources */ = {isa = PBXBuildFile; fileRef = 011D396E2D09FCCB00DB1445 /* CardPresentModalLocationRequired.swift */; };
2625
011D39712D0A324200DB1445 /* LocationServiceTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 011D39702D0A324100DB1445 /* LocationServiceTests.swift */; };
2726
011D7A332CEC877A0007C187 /* CardPresentModalNonRetryableErrorEmailSent.swift in Sources */ = {isa = PBXBuildFile; fileRef = 011D7A322CEC87770007C187 /* CardPresentModalNonRetryableErrorEmailSent.swift */; };
@@ -3226,7 +3225,6 @@
32263225
/* End PBXCopyFilesBuildPhase section */
32273226

32283227
/* Begin PBXFileReference section */
3229-
010C9A8E2C75C2BF00EBA228 /* Color+Inverted.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Color+Inverted.swift"; sourceTree = "<group>"; };
32303228
011D396E2D09FCCB00DB1445 /* CardPresentModalLocationRequired.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CardPresentModalLocationRequired.swift; sourceTree = "<group>"; };
32313229
011D39702D0A324100DB1445 /* LocationServiceTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LocationServiceTests.swift; sourceTree = "<group>"; };
32323230
011D7A322CEC87770007C187 /* CardPresentModalNonRetryableErrorEmailSent.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CardPresentModalNonRetryableErrorEmailSent.swift; sourceTree = "<group>"; };
@@ -7158,7 +7156,6 @@
71587156
68E4E8B42C0EF39D00CFA0C3 /* PreviewHelpers.swift */,
71597157
DA4104392C247B6900E8456A /* PointOfSalePreviewOrderController.swift */,
71607158
01664F9D2C50E685007CB5DD /* POSFontStyle.swift */,
7161-
010C9A8E2C75C2BF00EBA228 /* Color+Inverted.swift */,
71627159
01FB19572C6E901800A44FF0 /* DynamicHStack.swift */,
71637160
68625DE52D4134D50042B231 /* DynamicVStack.swift */,
71647161
02055B132D5DAB6400E51059 /* POSCornerRadiusStyle.swift */,
@@ -16078,7 +16075,6 @@
1607816075
AEC12B7A2758D55900845F97 /* OrderStatusList.swift in Sources */,
1607916076
0230535B2374FB6800487A64 /* AztecSourceCodeFormatBarCommand.swift in Sources */,
1608016077
DE49C7922BBFB8C500A45AEB /* ErrorTopBanner.swift in Sources */,
16081-
010C9A8F2C75C2BF00EBA228 /* Color+Inverted.swift in Sources */,
1608216078
DE3650682B5128CE001569A7 /* BlazeTargetLocationPickerViewModel.swift in Sources */,
1608316079
B958640C2A66847B002C4C6E /* CouponListView.swift in Sources */,
1608416080
DEDA8DBE2B19952B0076BF0F /* ThemeSettingViewModel.swift in Sources */,

0 commit comments

Comments
 (0)