Skip to content

Commit 29391ee

Browse files
committed
Fix naming
1 parent 5bd4ba4 commit 29391ee

File tree

7 files changed

+21
-19
lines changed

7 files changed

+21
-19
lines changed

Flipper/Packages/UI/Sources/Common/Alerts/FeaturePauseSyncFAlert.swift renamed to Flipper/Packages/UI/Sources/Common/Alerts/PauseSyncAlert.swift

+9-7
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import SwiftUI
22

3-
struct FeaturePauseSyncAlert: View {
3+
struct PauseSyncAlert: View {
44
@Binding var isPresented: Bool
55
var onAction: () -> Void
66

@@ -10,12 +10,14 @@ struct FeaturePauseSyncAlert: View {
1010
Text("Pause Synchronization?")
1111
.font(.system(size: 14, weight: .bold))
1212

13-
Text("This feature can't be used during device synchronization."
14-
+ " Wait for sync to finish or pause it.")
15-
.font(.system(size: 14, weight: .medium))
16-
.multilineTextAlignment(.center)
17-
.foregroundColor(.black40)
18-
.padding(.horizontal, 12)
13+
Text(
14+
"This feature can't be used during device " +
15+
"synchronization. Wait for sync to finish or pause it."
16+
)
17+
.font(.system(size: 14, weight: .medium))
18+
.multilineTextAlignment(.center)
19+
.foregroundColor(.black40)
20+
.padding(.horizontal, 12)
1921
}
2022
.padding(.top, 25)
2123

Flipper/Packages/UI/Sources/Common/Alerts/Update/PauseSync.swift renamed to Flipper/Packages/UI/Sources/Common/Alerts/Update/PauseSyncToUpdate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import Core
22
import SwiftUI
33

4-
struct PauseSyncAlert: View {
4+
struct PauseSyncToUpdateAlert: View {
55
@Binding var isPresented: Bool
66
let installedVersion: Update.Version
77
let availableVersion: Update.Version

Flipper/Packages/UI/Sources/Device/UpdateCard/DeviceUpdateCard.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ struct DeviceUpdateCard: View {
126126
LowBatteryAlert(isPresented: $showCharge)
127127
}
128128
.alert(isPresented: $showPauseSync) {
129-
PauseSyncAlert(
129+
PauseSyncToUpdateAlert(
130130
isPresented: $showPauseSync,
131131
installedVersion: updateModel.installed!,
132132
availableVersion: updateModel.available!

Flipper/Packages/UI/Sources/Hub/InfraredLibrary/InfraredLibraryCard.swift

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@ import Core
22
import SwiftUI
33

44
struct InfraredLibraryCard: View {
5-
65
var body: some View {
76
HubCard(
87
icon: "infrared",
98
title: "Infrared",
109
image: "InfraredRemoteLibrary",
1110
subtitle: "Remotes Library",
12-
description: "Find remotes for your devices from a "
13-
+ "wide range of brands and models"
11+
description:
12+
"Find remotes for your devices from a " +
13+
"wide range of brands and models"
1414
) {
1515
Badge()
1616
}
@@ -62,7 +62,7 @@ struct InfraredLibraryCardButton: View {
6262
NotSupportedFeatureAlert(isPresented: $showFlipperNotSupported)
6363
}
6464
.alert(isPresented: $showFlipperSyncing) {
65-
FeaturePauseSyncAlert(isPresented: $showFlipperSyncing) {
65+
PauseSyncAlert(isPresented: $showFlipperSyncing) {
6666
synchronization.cancelSync()
6767
onTap()
6868
recordInfraredLibraryOpened()

Flipper/Packages/UI/Sources/InAppNotifications/InAppNotifications.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ struct InAppNotifications {
2222
}
2323

2424
struct InfraredLibrary {
25-
var showFoundRemote = false
25+
var showRemoteFound = false
2626
}
2727
}
2828

Flipper/Packages/UI/Sources/Infrared/Layout/InfraredFoundRemoteBanner.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import SwiftUI
22

33
extension InfraredView {
4-
struct FoundRemoteBanner: View {
4+
struct RemoteFoundBanner: View {
55
var body: some View {
66
Banner(
77
image: "Done",

Flipper/Packages/UI/Sources/Infrared/Layout/InfraredPagesLayout.swift

+4-4
Original file line numberDiff line numberDiff line change
@@ -118,9 +118,9 @@ extension InfraredView {
118118
}
119119
}
120120
.notification(
121-
isPresented: notifications.infraredLibrary.showFoundRemote
121+
isPresented: notifications.infraredLibrary.showRemoteFound
122122
) {
123-
FoundRemoteBanner()
123+
RemoteFoundBanner()
124124
}
125125
.alert(isPresented: $isFlipperBusyAlertPresented) {
126126
FlipperIsBusyAlert(
@@ -166,7 +166,7 @@ extension InfraredView {
166166
}
167167

168168
private func processLoadFile() async {
169-
notifications.infraredLibrary.showFoundRemote = true
169+
notifications.infraredLibrary.showRemoteFound = true
170170
viewState = .loadLayoyt
171171
do {
172172
let layout = try await infraredModel.loadLayout(file)
@@ -202,7 +202,7 @@ extension InfraredView {
202202

203203
private func retry() {
204204
Task {
205-
notifications.infraredLibrary.showFoundRemote = false
205+
notifications.infraredLibrary.showRemoteFound = false
206206
await processLoadFile()
207207
}
208208
}

0 commit comments

Comments
 (0)