hunk.code_window:     "@expo/vector-icons": "^13.0.0",
       "@react-navigation/bottom-tabs": "^6.0.5",
       "@react-navigation/native": "^6.0.2",
       "@react-navigation/native-stack": "^6.1.0",
       "expo": "~45.0.0-beta.4",
       "expo-asset": "~8.5.0",
       "expo-constants": "~13.1.0",
       "expo-font": "~10.1.0",
       "expo-linking": "~3.1.0",
       "expo-splash-screen": "~0.15.0",
       "expo-status-bar": "~1.3.0",
       "expo-system-ui": "~1.2.0",
       "expo-web-browser": "~10.2.0",
       "react": "18.0.0",
       "react-dom": "18.0.0",
       "react-native": "0.69.1",
       "react-native-safe-area-context": "4.3.1",
  
hunk.labels: keep keep keep keep replace replace replace replace replace replace replace replace replace replace replace replace keep
hunk.after_edit:     "expo": "~46.0.0-alpha.0",
       "expo-asset": "~8.6.0",
       "expo-constants": "~13.2.0",
       "expo-font": "~10.2.0",
       "expo-linking": "~3.2.0",
       "expo-splash-screen": "~0.16.0",
       "expo-status-bar": "~1.4.0",
       "expo-system-ui": "~1.3.0",
       "expo-web-browser": "~11.0.0",
       "react": "17.0.2",
       "react-dom": "17.0.2",
       "react-native": "0.68.2",
  
hunk.file_path: templates/expo-template-tabs/package.json
hunk.type: replace
file: // Copyright 2019-present 650 Industries. All rights reserved.
  
  #import <Foundation/Foundation.h>
  #import <ABI45_0_0EXScreenOrientation/ABI45_0_0EXScreenOrientationUtilities.h>
  
  #import <sys/utsname.h>
  
  @implementation ABI45_0_0EXScreenOrientationUtilities
  
  # pragma mark - helpers
  
  + (BOOL)isIPad
  {
    return [[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad;
  }
  
  + (BOOL)doesDeviceSupportOrientationMask:(UIInterfaceOrientationMask)orientationMask
  {
    if ((UIInterfaceOrientationMaskPortraitUpsideDown & orientationMask) // UIInterfaceOrientationMaskPortraitUpsideDown is part of orientationMask
        && [self doesDeviceHaveNotch])
    {
      // device does not support UIInterfaceOrientationMaskPortraitUpsideDown and it was requested via orientationMask
      return false;
    }
    
    return true;
  }
  
  // https://medium.com/@cafielo/how-to-detect-notch-screen-in-swift-56271827625d
  + (BOOL)doesDeviceHaveNotch {
    static BOOL bottomSafeAreaInsetIsPositive = false;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
       dispatch_sync(dispatch_get_main_queue(), ^{
        bottomSafeAreaInsetIsPositive = ([[[UIApplication sharedApplication] delegate] window].safeAreaInsets.bottom ?: 0.0) > 0.0;
      });
    });
      
    return bottomSafeAreaInsetIsPositive;
  }
  
  + (UIInterfaceOrientationMask)maskFromOrientation:(UIInterfaceOrientation)orientation
  {
    return 1 << orientation;
  }
  
  + (UIInterfaceOrientation)interfaceOrientationFromDeviceOrientation:(UIDeviceOrientation)deviceOrientation
  {
     switch (deviceOrientation) {
       case UIDeviceOrientationPortrait:
         return UIInterfaceOrientationPortrait;
       case UIDeviceOrientationPortraitUpsideDown:
         return UIInterfaceOrientationPortraitUpsideDown;
       // UIDevice and UIInterface landscape orientations are switched
       case UIDeviceOrientationLandscapeLeft:
         return UIInterfaceOrientationLandscapeRight;
       case UIDeviceOrientationLandscapeRight:
         return UIInterfaceOrientationLandscapeLeft;
       default:
         return UIInterfaceOrientationUnknown;
     }
  }
  
  + (BOOL)doesOrientationMask:(UIInterfaceOrientationMask)orientationMask containOrientation:(UIInterfaceOrientation)orientation
  {
    // This is how the mask is created from the orientation
    UIInterfaceOrientationMask maskFromOrientation = [self maskFromOrientation:orientation];
    return (maskFromOrientation & orientationMask);
  }
  
  + (UIInterfaceOrientation)defaultOrientationForOrientationMask:(UIInterfaceOrientationMask)orientationMask
  {
    if (UIInterfaceOrientationMaskPortrait & orientationMask) {
      return UIInterfaceOrientationPortrait;
    } else if (UIInterfaceOrientationMaskLandscapeLeft & orientationMask) {
      return UIInterfaceOrientationLandscapeLeft;
    } else if (UIInterfaceOrientationMaskLandscapeRight & orientationMask) {
      return UIInterfaceOrientationLandscapeRight;
    } else if (UIInterfaceOrientationMaskPortraitUpsideDown & orientationMask) {
      return UIInterfaceOrientationPortraitUpsideDown;
    }
    return UIInterfaceOrientationUnknown;
  }
  
  + (NSMutableDictionary *)inverted:(NSDictionary *)dictionary
  {
    NSMutableDictionary *invertedDictionary = [NSMutableDictionary new];
    [dictionary enumerateKeysAndObjectsUsingBlock:^(id key, id value, BOOL *stop) {
        invertedDictionary[value] = key;
    }];
    return invertedDictionary;
  }
  
  # pragma mark - import/export
  
  + (NSDictionary *)orientationLockMap
  {
    static NSDictionary *orientationLockMap = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
      orientationLockMap = @{
        @0 : @(UIInterfaceOrientationMaskAllButUpsideDown),
        @1 : @(UIInterfaceOrientationMaskAll),
        @2 : @(UIInterfaceOrientationMaskPortrait | UIInterfaceOrientationMaskPortraitUpsideDown),
        @3 : @(UIInterfaceOrientationMaskPortrait),
        @4 : @(UIInterfaceOrientationMaskPortraitUpsideDown),
        @5 : @(UIInterfaceOrientationMaskLandscape),
        @6 : @(UIInterfaceOrientationMaskLandscapeLeft),
        @7 : @(UIInterfaceOrientationMaskLandscapeRight),
      };
    });
    
    return orientationLockMap;
  }
  
  + (NSDictionary *)orientationMap
  {
    static NSDictionary *orientationMap = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
      orientationMap = @{
        @(UIInterfaceOrientationPortrait)           : @1,
        @(UIInterfaceOrientationPortraitUpsideDown) : @2,
        @(UIInterfaceOrientationLandscapeLeft)      : @3,
        @(UIInterfaceOrientationLandscapeRight)     : @4,
      };
    });
    
    return orientationMap;
  }
  
  + (UIInterfaceOrientationMask)importOrientationLock:(NSNumber *)orientationLock
  {
    return [[self orientationLockMap][orientationLock] integerValue] ?: 0;
  }
  
  + (NSNumber *)exportOrientationLock:(UIInterfaceOrientationMask)orientationMask
  {
    static NSMutableDictionary *exportOrientationLockMap = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
      exportOrientationLockMap = [self inverted:[ABI45_0_0EXScreenOrientationUtilities orientationLockMap]];
      exportOrientationLockMap[@(UIInterfaceOrientationMaskAllButUpsideDown)] = @0; // UIInterfaceOrientationMaskAllButUpsideDown is default value
    });
    
    NSNumber *exportedOrientation = exportOrientationLockMap[@(orientationMask)];
    if (!exportedOrientation) {
      if (orientationMask & UIInterfaceOrientationMaskAll) {
        return @(8);
      }
      return @(9);
    }
    
    return exportedOrientation;
  }
  
  + (NSNumber *)exportOrientation:(UIInterfaceOrientation)orientation
  {
    return [self orientationMap][@(orientation)] ?: @(UIInterfaceOrientationUnknown);
  }
  
  + (UIInterfaceOrientation)importOrientation:(NSNumber *)orientation
  {
    static NSDictionary *exportOrientationMap = nil;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
      exportOrientationMap = [self inverted:[self orientationMap]];
    });
    return [exportOrientationMap[orientation] intValue] ?: UIInterfaceOrientationUnknown;
  }
  
  @end
  