From 8e2b1be352bc60c9a51828e24e7cf64f08af63d8 Mon Sep 17 00:00:00 2001 From: Alexander Romanov Date: Sat, 2 Sep 2023 23:18:38 +0300 Subject: [PATCH] Fix info icon #patch --- .../SettingsKit/Views/SettingsView.swift | 2 +- .../SoundsAndVibrationsSettingsView.swift | 16 ++++++++++++++-- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/Sources/OversizeKit/SettingsKit/Views/SettingsView.swift b/Sources/OversizeKit/SettingsKit/Views/SettingsView.swift index 8ae9d10..d187adb 100644 --- a/Sources/OversizeKit/SettingsKit/Views/SettingsView.swift +++ b/Sources/OversizeKit/SettingsKit/Views/SettingsView.swift @@ -337,7 +337,7 @@ import SwiftUI var infoIcon: Image { switch iconStyle { case .line: - return Image.Base.info + return Image.Base.Info.circle case .fill: return Image.Base.Info.Circle.fill case .twoTone: diff --git a/Sources/OversizeKit/SettingsKit/Views/SoundAndVibration/SoundsAndVibrationsSettingsView.swift b/Sources/OversizeKit/SettingsKit/Views/SoundAndVibration/SoundsAndVibrationsSettingsView.swift index 2d3124a..031d1fb 100644 --- a/Sources/OversizeKit/SettingsKit/Views/SoundAndVibration/SoundsAndVibrationsSettingsView.swift +++ b/Sources/OversizeKit/SettingsKit/Views/SoundAndVibration/SoundsAndVibrationsSettingsView.swift @@ -13,6 +13,7 @@ import SwiftUI #if os(iOS) public struct SoundsAndVibrationsSettingsView: View { @Environment(\.verticalSizeClass) private var verticalSizeClass + @Environment(\.iconStyle) var iconStyle: IconStyle @Environment(\.isPortrait) var isPortrait @Environment(\.presentationMode) var presentationMode @State var offset = CGPoint(x: 0, y: 0) @@ -21,7 +22,7 @@ import SwiftUI public var body: some View { PageView(title) { iOSSettings - .surfaceContentRowInsets() + .surfaceContentRowMargins() } .leadingBar { if !isPortrait, verticalSizeClass == .regular { @@ -69,12 +70,23 @@ import SwiftUI if FeatureFlags.app.vibration.valueOrFalse { Switch(isOn: $settingsService.vibrationEnabled) { Row(L10n.Settings.vibration) { - IconDeprecated(.radio) + vibrationIcon } } } } } } + + var vibrationIcon: Image { + switch iconStyle { + case .line: + return Image.Mobile.vibration + case .fill: + return Image.Mobile.Vibration.fill + case .twoTone: + return Image.Mobile.Vibration.twoTone + } + } } #endif