Skip to content

Commit 08d0856

Browse files
committed
Cleanup in RNSConvert
1 parent 11a99eb commit 08d0856

1 file changed

Lines changed: 44 additions & 47 deletions

File tree

ios/RNSConvert.mm

Lines changed: 44 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -195,53 +195,50 @@ + (RNSSearchBarPlacement)RNSScreenSearchBarPlacementFromCppEquivalent:(react::RN
195195
+ (RNSBlurEffectStyle)RNSBlurEffectStyleFromCppEquivalent:(react::RNSScreenStackHeaderConfigBlurEffect)blurEffect
196196
{
197197
using enum react::RNSScreenStackHeaderConfigBlurEffect;
198-
#if !TARGET_OS_TV && defined(__IPHONE_OS_VERSION_MAX_ALLOWED) && defined(__IPHONE_13_0) && \
199-
__IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_13_0
200-
if (@available(iOS 13.0, *)) {
201-
switch (blurEffect) {
202-
case None:
203-
return RNSBlurEffectStyleNone;
204-
case ExtraLight:
205-
return RNSBlurEffectStyleExtraLight;
206-
case Light:
207-
return RNSBlurEffectStyleLight;
208-
case Dark:
209-
return RNSBlurEffectStyleDark;
210-
case Regular:
211-
return RNSBlurEffectStyleRegular;
212-
case Prominent:
213-
return RNSBlurEffectStyleProminent;
214-
case SystemUltraThinMaterial:
215-
return RNSBlurEffectStyleSystemUltraThinMaterial;
216-
case SystemThinMaterial:
217-
return RNSBlurEffectStyleSystemThinMaterial;
218-
case SystemMaterial:
219-
return RNSBlurEffectStyleSystemMaterial;
220-
case SystemThickMaterial:
221-
return RNSBlurEffectStyleSystemThickMaterial;
222-
case SystemChromeMaterial:
223-
return RNSBlurEffectStyleSystemChromeMaterial;
224-
case SystemUltraThinMaterialLight:
225-
return RNSBlurEffectStyleSystemUltraThinMaterialLight;
226-
case SystemThinMaterialLight:
227-
return RNSBlurEffectStyleSystemThinMaterialLight;
228-
case SystemMaterialLight:
229-
return RNSBlurEffectStyleSystemMaterialLight;
230-
case SystemThickMaterialLight:
231-
return RNSBlurEffectStyleSystemThickMaterialLight;
232-
case SystemChromeMaterialLight:
233-
return RNSBlurEffectStyleSystemChromeMaterialLight;
234-
case SystemUltraThinMaterialDark:
235-
return RNSBlurEffectStyleSystemUltraThinMaterialDark;
236-
case SystemThinMaterialDark:
237-
return RNSBlurEffectStyleSystemThinMaterialDark;
238-
case SystemMaterialDark:
239-
return RNSBlurEffectStyleSystemMaterialDark;
240-
case SystemThickMaterialDark:
241-
return RNSBlurEffectStyleSystemThickMaterialDark;
242-
case SystemChromeMaterialDark:
243-
return RNSBlurEffectStyleSystemChromeMaterialDark;
244-
}
198+
#if !TARGET_OS_TV
199+
switch (blurEffect) {
200+
case None:
201+
return RNSBlurEffectStyleNone;
202+
case ExtraLight:
203+
return RNSBlurEffectStyleExtraLight;
204+
case Light:
205+
return RNSBlurEffectStyleLight;
206+
case Dark:
207+
return RNSBlurEffectStyleDark;
208+
case Regular:
209+
return RNSBlurEffectStyleRegular;
210+
case Prominent:
211+
return RNSBlurEffectStyleProminent;
212+
case SystemUltraThinMaterial:
213+
return RNSBlurEffectStyleSystemUltraThinMaterial;
214+
case SystemThinMaterial:
215+
return RNSBlurEffectStyleSystemThinMaterial;
216+
case SystemMaterial:
217+
return RNSBlurEffectStyleSystemMaterial;
218+
case SystemThickMaterial:
219+
return RNSBlurEffectStyleSystemThickMaterial;
220+
case SystemChromeMaterial:
221+
return RNSBlurEffectStyleSystemChromeMaterial;
222+
case SystemUltraThinMaterialLight:
223+
return RNSBlurEffectStyleSystemUltraThinMaterialLight;
224+
case SystemThinMaterialLight:
225+
return RNSBlurEffectStyleSystemThinMaterialLight;
226+
case SystemMaterialLight:
227+
return RNSBlurEffectStyleSystemMaterialLight;
228+
case SystemThickMaterialLight:
229+
return RNSBlurEffectStyleSystemThickMaterialLight;
230+
case SystemChromeMaterialLight:
231+
return RNSBlurEffectStyleSystemChromeMaterialLight;
232+
case SystemUltraThinMaterialDark:
233+
return RNSBlurEffectStyleSystemUltraThinMaterialDark;
234+
case SystemThinMaterialDark:
235+
return RNSBlurEffectStyleSystemThinMaterialDark;
236+
case SystemMaterialDark:
237+
return RNSBlurEffectStyleSystemMaterialDark;
238+
case SystemThickMaterialDark:
239+
return RNSBlurEffectStyleSystemThickMaterialDark;
240+
case SystemChromeMaterialDark:
241+
return RNSBlurEffectStyleSystemChromeMaterialDark;
245242
}
246243
#endif
247244

0 commit comments

Comments
 (0)