add feature flag for read now button

This commit is contained in:
Satindar Dhillon 2022-05-18 09:13:26 -07:00
parent 2d4ec9d45d
commit 65640d7b04
2 changed files with 3 additions and 2 deletions

View file

@ -10,6 +10,7 @@ public enum FeatureFlag {
public static let showAccountDeletion = false
public static let enableSnoozeFromShareExtension = false
public static let enableRemindersFromShareExtension = false
public static let enableReadNow = false
public static let enablePushNotifications = false
public static let enableShareButton = false
public static let enableSnooze = false

View file

@ -203,14 +203,14 @@ public struct ShareExtensionChildView: View {
.padding(.horizontal)
HStack {
if case ShareExtensionStatus.success = status {
if case ShareExtensionStatus.success = status, FeatureFlag.enableReadNow {
Button(
action: { readNowButtonAction() },
label: { Text("Read Now").frame(maxWidth: .infinity) }
)
.buttonStyle(RoundedRectButtonStyle())
}
if case ShareExtensionStatus.processing = status {
if case ShareExtensionStatus.processing = status, FeatureFlag.enableReadNow {
Button(action: {}, label: { ProgressView().frame(maxWidth: .infinity) })
.buttonStyle(RoundedRectButtonStyle())
}