diff --git a/CHANGELOG.md b/CHANGELOG.md index 3f76e43..bfaa60a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,34 @@ # Changelog +## Version 5.5.0 + +Releasedate: 2024-09-12 + +```ruby +pod 'DeviceKit', '~> 5.5' +``` + +### New September 2024 devices + +This version adds support for the devices announced at the September 2024 Apple Event: ([#417](https://github.com/devicekit/DeviceKit/pull/417)) + +| Device | Case value | +| --- | --- | +| iPhone 16 | `Device.iPhone16` | +| iPhone 16 Plus | `Device.iPhone16Plus` | +| iPhone 16 Pro | `Device.iPhone16Pro` | +| iPhone 16 Pro Max | `Device.iPhone16ProMax` | +| Apple Watch Series 10 | `Device.appleWatchSeries10_42mm`, `Device.appleWatchSeries10_46mm` | + +### Fixes + +- Fix incorrect PPI for iPhone 14 Plus and iPhone 15 Plus. ([#418](https://github.com/devicekit/DeviceKit/pull/418)) + +### Contributors + +Thanks to all the contributers of this release! +- [arindamxd](https://github.com/arindamxd) + ## Version 5.4.0 Releasedate: 2024-05-30 diff --git a/DeviceKit.podspec b/DeviceKit.podspec index edc23cb..01d87c8 100644 --- a/DeviceKit.podspec +++ b/DeviceKit.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'DeviceKit' - s.version = '5.4.0' + s.version = '5.5.0' s.summary = 'DeviceKit is a ยต-framework that provides a value-type replacement of UIDevice.' s.description = <<-DESC diff --git a/DeviceKit.xcodeproj/project.pbxproj b/DeviceKit.xcodeproj/project.pbxproj index 1993605..9548e38 100644 --- a/DeviceKit.xcodeproj/project.pbxproj +++ b/DeviceKit.xcodeproj/project.pbxproj @@ -384,7 +384,7 @@ "@executable_path/Frameworks", "@loader_path/Frameworks", ); - MARKETING_VERSION = 5.4.0; + MARKETING_VERSION = 5.5.0; MERGEABLE_LIBRARY = YES; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_BUNDLE_IDENTIFIER = me.dennisweissmann.DeviceKit; @@ -444,7 +444,7 @@ "@executable_path/Frameworks", "@loader_path/Frameworks", ); - MARKETING_VERSION = 5.4.0; + MARKETING_VERSION = 5.5.0; MERGEABLE_LIBRARY = YES; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_BUNDLE_IDENTIFIER = me.dennisweissmann.DeviceKit; diff --git a/README.md b/README.md index 2e134a6..0e8cf26 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ `DeviceKit` is a value-type replacement of [`UIDevice`](https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIDevice_Class/). -## Current version 5.4.0 +## Current version 5.5.0 See our detailed [changelog](CHANGELOG.md) for the latest features, improvements and bug fixes. ## Features diff --git a/Source/Device.generated.swift b/Source/Device.generated.swift index 7920a39..21541dd 100644 --- a/Source/Device.generated.swift +++ b/Source/Device.generated.swift @@ -202,22 +202,38 @@ public enum Device { /// /// ![Image](https://support.apple.com/library/APPLE/APPLECARE_ALLGEOS/SP875/sp875-sp876-iphone14-pro-promax_2x.png) case iPhone14ProMax - /// Device is an [iPhone 15]() + /// Device is an [iPhone 15](https://support.apple.com/en-us/111831) /// /// ![Image]() case iPhone15 - /// Device is an [iPhone 15 Plus]() + /// Device is an [iPhone 15 Plus](https://support.apple.com/en-us/111830) /// /// ![Image]() case iPhone15Plus - /// Device is an [iPhone 15 Pro]() + /// Device is an [iPhone 15 Pro](https://support.apple.com/en-us/111829) /// /// ![Image]() case iPhone15Pro - /// Device is an [iPhone 15 Pro Max]() + /// Device is an [iPhone 15 Pro Max](https://support.apple.com/en-us/111828) /// /// ![Image]() case iPhone15ProMax + /// Device is an [iPhone 16]() + /// + /// ![Image]() + case iPhone16 + /// Device is an [iPhone 16 Plus]() + /// + /// ![Image]() + case iPhone16Plus + /// Device is an [iPhone 16 Pro]() + /// + /// ![Image]() + case iPhone16Pro + /// Device is an [iPhone 16 Pro Max]() + /// + /// ![Image]() + case iPhone16ProMax /// Device is an [iPad 2](https://support.apple.com/kb/SP622) /// /// ![Image](https://support.apple.com/library/APPLE/APPLECARE_ALLGEOS/SP622/SP622_01-ipad2-mul.png) @@ -488,6 +504,14 @@ public enum Device { /// /// ![Image]() case appleWatchUltra2 + /// Device is an [Apple Watch Series 10]() + /// + /// ![Image]() + case appleWatchSeries10_42mm + /// Device is an [Apple Watch Series 10]() + /// + /// ![Image]() + case appleWatchSeries10_46mm #endif /// Device is [Simulator](https://developer.apple.com/library/ios/documentation/IDEs/Conceptual/iOS_Simulator_Guide/Introduction/Introduction.html) @@ -568,6 +592,10 @@ public enum Device { case "iPhone15,5": return iPhone15Plus case "iPhone16,1": return iPhone15Pro case "iPhone16,2": return iPhone15ProMax + case "iPhone17,3": return iPhone16 + case "iPhone17,4": return iPhone16Plus + case "iPhone17,1": return iPhone16Pro + case "iPhone17,2": return iPhone16ProMax case "iPad2,1", "iPad2,2", "iPad2,3", "iPad2,4": return iPad2 case "iPad3,1", "iPad3,2", "iPad3,3": return iPad3 case "iPad3,4", "iPad3,5", "iPad3,6": return iPad4 @@ -645,6 +673,8 @@ public enum Device { case "Watch7,3": return appleWatchSeries9_41mm case "Watch7,4": return appleWatchSeries9_45mm case "Watch7,5": return appleWatchUltra2 + case "Watch7,8", "Watch7,10": return appleWatchSeries10_42mm + case "Watch7,9", "Watch7,11": return appleWatchSeries10_46mm case "i386", "x86_64", "arm64": return simulator(mapToDevice(identifier: ProcessInfo().environment["SIMULATOR_MODEL_IDENTIFIER"] ?? "watchOS")) default: return unknown(identifier) } @@ -718,6 +748,10 @@ public enum Device { case .iPhone15Plus: return 6.7 case .iPhone15Pro: return 6.1 case .iPhone15ProMax: return 6.7 + case .iPhone16: return 6.1 + case .iPhone16Plus: return 6.7 + case .iPhone16Pro: return 6.3 + case .iPhone16ProMax: return 6.9 case .iPad2: return 9.7 case .iPad3: return 9.7 case .iPad4: return 9.7 @@ -786,6 +820,8 @@ public enum Device { case .appleWatchSeries9_41mm: return 1.9 case .appleWatchSeries9_45mm: return 2.0 case .appleWatchUltra2: return 2.2 + case .appleWatchSeries10_42mm: return 1.9 + case .appleWatchSeries10_46mm: return 2.0 case .simulator(let model): return model.diagonal case .unknown: return -1 } @@ -839,6 +875,10 @@ public enum Device { case .iPhone15Plus: return (width: 9, height: 19.5) case .iPhone15Pro: return (width: 9, height: 19.5) case .iPhone15ProMax: return (width: 9, height: 19.5) + case .iPhone16: return (width: 9, height: 19.5) + case .iPhone16Plus: return (width: 9, height: 19.5) + case .iPhone16Pro: return (width: 9, height: 19.5) + case .iPhone16ProMax: return (width: 9, height: 19.5) case .iPad2: return (width: 3, height: 4) case .iPad3: return (width: 3, height: 4) case .iPad4: return (width: 3, height: 4) @@ -907,6 +947,8 @@ public enum Device { case .appleWatchSeries9_41mm: return (width: 4, height: 5) case .appleWatchSeries9_45mm: return (width: 4, height: 5) case .appleWatchUltra2: return (width: 4, height: 5) + case .appleWatchSeries10_42mm: return (width: 374, height: 446) + case .appleWatchSeries10_46mm: return (width: 416, height: 496) case .simulator(let model): return model.screenRatio case .unknown: return (width: -1, height: -1) } @@ -925,7 +967,7 @@ public enum Device { /// All iPhones public static var allPhones: [Device] { - return [.iPhone4, .iPhone4s, .iPhone5, .iPhone5c, .iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax] + return [.iPhone4, .iPhone4s, .iPhone5, .iPhone5c, .iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax] } /// All iPads @@ -936,17 +978,17 @@ public enum Device { /// All X-Series Devices @available(*, deprecated, renamed: "allDevicesWithSensorHousing") public static var allXSeriesDevices: [Device] { - return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax] + return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax] } /// All Plus and Max-Sized Devices public static var allPlusSizedDevices: [Device] { - return [.iPhone6Plus, .iPhone6sPlus, .iPhone7Plus, .iPhone8Plus, .iPhoneXSMax, .iPhone11ProMax, .iPhone12ProMax, .iPhone13ProMax, .iPhone14Plus, .iPhone14ProMax, .iPhone15Plus, .iPhone15ProMax] + return [.iPhone6Plus, .iPhone6sPlus, .iPhone7Plus, .iPhone8Plus, .iPhoneXSMax, .iPhone11ProMax, .iPhone12ProMax, .iPhone13ProMax, .iPhone14Plus, .iPhone14ProMax, .iPhone15Plus, .iPhone15ProMax, .iPhone16Plus, .iPhone16ProMax] } /// All Pro Devices public static var allProDevices: [Device] { - return [.iPhone11Pro, .iPhone11ProMax, .iPhone12Pro, .iPhone12ProMax, .iPhone13Pro, .iPhone13ProMax, .iPhone14Pro, .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhone11Pro, .iPhone11ProMax, .iPhone12Pro, .iPhone12ProMax, .iPhone13Pro, .iPhone13ProMax, .iPhone14Pro, .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, .iPhone16Pro, .iPhone16ProMax, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// All mini Devices @@ -1032,12 +1074,12 @@ public enum Device { /// All Face ID Capable Devices public static var allFaceIDCapableDevices: [Device] { - return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// All Devices with Touch ID or Face ID public static var allBiometricAuthenticationCapableDevices: [Device] { - return [.iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPadAir2, .iPad5, .iPad6, .iPadAir3, .iPad7, .iPad8, .iPad9, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini3, .iPadMini4, .iPadMini5, .iPadMini6, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPadAir2, .iPad5, .iPad6, .iPadAir3, .iPad7, .iPad8, .iPad9, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini3, .iPadMini4, .iPadMini5, .iPadMini6, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// Returns whether or not the device has Touch ID @@ -1057,7 +1099,7 @@ public enum Device { /// All devices that feature a sensor housing in the screen public static var allDevicesWithSensorHousing: [Device] { - return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax] + return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax] } /// All simulator devices that feature a sensor housing in the screen @@ -1072,7 +1114,7 @@ public enum Device { /// All devices that feature a screen with rounded corners. public static var allDevicesWithRoundedDisplayCorners: [Device] { - return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini6, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini6, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// Returns whether or not the device has a screen with rounded corners. @@ -1082,7 +1124,7 @@ public enum Device { /// All devices that have the Dynamic Island. public static var allDevicesWithDynamicIsland: [Device] { - return [.iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax] + return [.iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax] } /// Returns whether or not the device has the Dynamic Island. @@ -1102,7 +1144,7 @@ public enum Device { /// All devices that support wireless charging. public static var allDevicesWithWirelessChargingSupport: [Device] { - return [.iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax] + return [.iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax] } /// Returns whether or not the device supports wireless charging. @@ -1112,7 +1154,7 @@ public enum Device { /// All devices that support 5G. public static var allDevicesWith5gSupport: [Device] { - return [.iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPad10, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini6, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPad10, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini6, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// Returns whether or not the device has 5G support. @@ -1122,7 +1164,7 @@ public enum Device { /// All devices that have a LiDAR sensor. public static var allDevicesWithALidarSensor: [Device] { - return [.iPhone12Pro, .iPhone12ProMax, .iPhone13Pro, .iPhone13ProMax, .iPhone14Pro, .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhone12Pro, .iPhone12ProMax, .iPhone13Pro, .iPhone13ProMax, .iPhone14Pro, .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, .iPhone16Pro, .iPhone16ProMax, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// Returns whether or not the device has a LiDAR sensor. @@ -1132,7 +1174,7 @@ public enum Device { /// All devices that have a USB-C connectivity. public static var allDevicesWithUSBCConnectivity: [Device] { - return [.iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini6, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini6, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// Returns whether or not the device has a USB-C power supply. @@ -1152,7 +1194,7 @@ public enum Device { #elseif os(watchOS) /// All Watches public static var allWatches: [Device] { - return [.appleWatchSeries0_38mm, .appleWatchSeries0_42mm, .appleWatchSeries1_38mm, .appleWatchSeries1_42mm, .appleWatchSeries2_38mm, .appleWatchSeries2_42mm, .appleWatchSeries3_38mm, .appleWatchSeries3_42mm, .appleWatchSeries4_40mm, .appleWatchSeries4_44mm, .appleWatchSeries5_40mm, .appleWatchSeries5_44mm, .appleWatchSeries6_40mm, .appleWatchSeries6_44mm, .appleWatchSE_40mm, .appleWatchSE_44mm, .appleWatchSeries7_41mm, .appleWatchSeries7_45mm, .appleWatchSeries8_41mm, .appleWatchSeries8_45mm, .appleWatchSE2_40mm, .appleWatchSE2_44mm, .appleWatchUltra, .appleWatchSeries9_41mm, .appleWatchSeries9_45mm, .appleWatchUltra2] + return [.appleWatchSeries0_38mm, .appleWatchSeries0_42mm, .appleWatchSeries1_38mm, .appleWatchSeries1_42mm, .appleWatchSeries2_38mm, .appleWatchSeries2_42mm, .appleWatchSeries3_38mm, .appleWatchSeries3_42mm, .appleWatchSeries4_40mm, .appleWatchSeries4_44mm, .appleWatchSeries5_40mm, .appleWatchSeries5_44mm, .appleWatchSeries6_40mm, .appleWatchSeries6_44mm, .appleWatchSE_40mm, .appleWatchSE_44mm, .appleWatchSeries7_41mm, .appleWatchSeries7_45mm, .appleWatchSeries8_41mm, .appleWatchSeries8_45mm, .appleWatchSE2_40mm, .appleWatchSE2_44mm, .appleWatchUltra, .appleWatchSeries9_41mm, .appleWatchSeries9_45mm, .appleWatchUltra2, .appleWatchSeries10_42mm, .appleWatchSeries10_46mm] } /// All simulator Watches @@ -1362,6 +1404,10 @@ public enum Device { case .iPhone15Plus: return 476 case .iPhone15Pro: return 460 case .iPhone15ProMax: return 460 + case .iPhone16: return 460 + case .iPhone16Plus: return 476 + case .iPhone16Pro: return 460 + case .iPhone16ProMax: return 460 case .iPad2: return 132 case .iPad3: return 264 case .iPad4: return 264 @@ -1430,6 +1476,8 @@ public enum Device { case .appleWatchSeries9_41mm: return 326 case .appleWatchSeries9_45mm: return 326 case .appleWatchUltra2: return 338 + case .appleWatchSeries10_42mm: return 326 + case .appleWatchSeries10_46mm: return 326 case .simulator(let model): return model.ppi case .unknown: return nil } @@ -1515,6 +1563,10 @@ extension Device: CustomStringConvertible { case .iPhone15Plus: return "iPhone 15 Plus" case .iPhone15Pro: return "iPhone 15 Pro" case .iPhone15ProMax: return "iPhone 15 Pro Max" + case .iPhone16: return "iPhone 16" + case .iPhone16Plus: return "iPhone 16 Plus" + case .iPhone16Pro: return "iPhone 16 Pro" + case .iPhone16ProMax: return "iPhone 16 Pro Max" case .iPad2: return "iPad 2" case .iPad3: return "iPad (3rd generation)" case .iPad4: return "iPad (4th generation)" @@ -1583,6 +1635,8 @@ extension Device: CustomStringConvertible { case .appleWatchSeries9_41mm: return "Apple Watch Series 9 41mm" case .appleWatchSeries9_45mm: return "Apple Watch Series 9 45mm" case .appleWatchUltra2: return "Apple Watch Ultra2" + case .appleWatchSeries10_42mm: return "Apple Watch Series 10 42mm" + case .appleWatchSeries10_46mm: return "Apple Watch Series 10 46mm" case .simulator(let model): return "Simulator (\(model.description))" case .unknown(let identifier): return identifier } @@ -1655,6 +1709,10 @@ extension Device: CustomStringConvertible { case .iPhone15Plus: return "iPhone 15 Plus" case .iPhone15Pro: return "iPhone 15 Pro" case .iPhone15ProMax: return "iPhone 15 Pro Max" + case .iPhone16: return "iPhone 16" + case .iPhone16Plus: return "iPhone 16 Plus" + case .iPhone16Pro: return "iPhone 16 Pro" + case .iPhone16ProMax: return "iPhone 16 Pro Max" case .iPad2: return "iPad 2" case .iPad3: return "iPad (3rd generation)" case .iPad4: return "iPad (4th generation)" @@ -1723,6 +1781,8 @@ extension Device: CustomStringConvertible { case .appleWatchSeries9_41mm: return "Apple Watch Series 9 41mm" case .appleWatchSeries9_45mm: return "Apple Watch Series 9 45mm" case .appleWatchUltra2: return "Apple Watch Ultra2" + case .appleWatchSeries10_42mm: return "Apple Watch Series 10 42mm" + case .appleWatchSeries10_46mm: return "Apple Watch Series 10 46mm" case .simulator(let model): return "Simulator (\(model.safeDescription))" case .unknown(let identifier): return identifier } @@ -2120,6 +2180,8 @@ extension Device { case .iPhone14Plus: return [.wide, .ultraWide] case .iPhone15: return [.wide, .ultraWide] case .iPhone15Plus: return [.wide, .ultraWide] + case .iPhone16: return [.wide, .ultraWide] + case .iPhone16Plus: return [.wide, .ultraWide] case .iPadPro11Inch2: return [.wide, .ultraWide] case .iPadPro12Inch4: return [.wide, .ultraWide] case .iPadPro11Inch3: return [.wide, .ultraWide] @@ -2136,13 +2198,15 @@ extension Device { case .iPhone14ProMax: return [.wide, .telephoto, .ultraWide] case .iPhone15Pro: return [.wide, .telephoto, .ultraWide] case .iPhone15ProMax: return [.wide, .telephoto, .ultraWide] + case .iPhone16Pro: return [.wide, .telephoto, .ultraWide] + case .iPhone16ProMax: return [.wide, .telephoto, .ultraWide] default: return [] } } /// All devices that feature a camera public static var allDevicesWithCamera: [Device] { - return [.iPodTouch5, .iPodTouch6, .iPodTouch7, .iPhone4, .iPhone4s, .iPhone5, .iPhone5c, .iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPad2, .iPad3, .iPad4, .iPadAir, .iPadAir2, .iPad5, .iPad6, .iPadAir3, .iPad7, .iPad8, .iPad9, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini, .iPadMini2, .iPadMini3, .iPadMini4, .iPadMini5, .iPadMini6, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPodTouch5, .iPodTouch6, .iPodTouch7, .iPhone4, .iPhone4s, .iPhone5, .iPhone5c, .iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPad2, .iPad3, .iPad4, .iPadAir, .iPadAir2, .iPad5, .iPad6, .iPadAir3, .iPad7, .iPad8, .iPad9, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini, .iPadMini2, .iPadMini3, .iPadMini4, .iPadMini5, .iPadMini6, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// All devices that feature a normal camera @@ -2153,17 +2217,17 @@ extension Device { /// All devices that feature a wide camera public static var allDevicesWithWideCamera: [Device] { - return [.iPodTouch5, .iPodTouch6, .iPodTouch7, .iPhone4, .iPhone4s, .iPhone5, .iPhone5c, .iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPad2, .iPad3, .iPad4, .iPadAir, .iPadAir2, .iPad5, .iPad6, .iPadAir3, .iPad7, .iPad8, .iPad9, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini, .iPadMini2, .iPadMini3, .iPadMini4, .iPadMini5, .iPadMini6, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] + return [.iPodTouch5, .iPodTouch6, .iPodTouch7, .iPhone4, .iPhone4s, .iPhone5, .iPhone5c, .iPhone5s, .iPhone6, .iPhone6Plus, .iPhone6s, .iPhone6sPlus, .iPhone7, .iPhone7Plus, .iPhoneSE, .iPhone8, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhoneXR, .iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhoneSE2, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhoneSE3, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPad2, .iPad3, .iPad4, .iPadAir, .iPadAir2, .iPad5, .iPad6, .iPadAir3, .iPad7, .iPad8, .iPad9, .iPad10, .iPadAir4, .iPadAir5, .iPadAir11M2, .iPadAir13M2, .iPadMini, .iPadMini2, .iPadMini3, .iPadMini4, .iPadMini5, .iPadMini6, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, .iPadPro10Inch, .iPadPro11Inch, .iPadPro12Inch3, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6, .iPadPro11M4, .iPadPro13M4] } /// All devices that feature a telephoto camera public static var allDevicesWithTelephotoCamera: [Device] { - return [.iPhone7Plus, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhone11Pro, .iPhone11ProMax, .iPhone12Pro, .iPhone12ProMax, .iPhone13Pro, .iPhone13ProMax, .iPhone14Pro, .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax] + return [.iPhone7Plus, .iPhone8Plus, .iPhoneX, .iPhoneXS, .iPhoneXSMax, .iPhone11Pro, .iPhone11ProMax, .iPhone12Pro, .iPhone12ProMax, .iPhone13Pro, .iPhone13ProMax, .iPhone14Pro, .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, .iPhone16Pro, .iPhone16ProMax] } /// All devices that feature an ultra wide camera public static var allDevicesWithUltraWideCamera: [Device] { - return [.iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6] + return [.iPhone11, .iPhone11Pro, .iPhone11ProMax, .iPhone12, .iPhone12Mini, .iPhone12Pro, .iPhone12ProMax, .iPhone13, .iPhone13Mini, .iPhone13Pro, .iPhone13ProMax, .iPhone14, .iPhone14Plus, .iPhone14Pro, .iPhone14ProMax, .iPhone15, .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, .iPhone16, .iPhone16Plus, .iPhone16Pro, .iPhone16ProMax, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, .iPadPro12Inch5, .iPadPro11Inch4, .iPadPro12Inch6] } /// Returns whether or not the current device has a camera @@ -2254,6 +2318,8 @@ extension Device { case a15Bionic case a16Bionic case a17Pro + case a18 + case a18Pro case m1 case m2 case m3 @@ -2269,6 +2335,7 @@ extension Device { case s7 case s8 case s9 + case s10 #endif case unknown } @@ -2319,6 +2386,10 @@ extension Device { case .iPhone15Plus: return .a16Bionic case .iPhone15Pro: return .a17Pro case .iPhone15ProMax: return .a17Pro + case .iPhone16: return .a18 + case .iPhone16Plus: return .a18 + case .iPhone16Pro: return .a18Pro + case .iPhone16ProMax: return .a18Pro case .iPad2: return .a5 case .iPad3: return .a5X case .iPad4: return .a6X @@ -2387,6 +2458,8 @@ extension Device { case .appleWatchSeries9_41mm: return .s9 case .appleWatchSeries9_45mm: return .s9 case .appleWatchUltra2: return .s9 + case .appleWatchSeries10_42mm: return .s10 + case .appleWatchSeries10_46mm: return .s10 case .simulator(let model): return model.cpu case .unknown: return .unknown } @@ -2435,6 +2508,8 @@ extension Device.CPU: CustomStringConvertible { case .a15Bionic: return "A15 Bionic" case .a16Bionic: return "A16 Bionic" case .a17Pro: return "A17 Pro" + case .a18: return "A18" + case .a18Pro: return "A18 Pro" case .m1: return "M1" case .m2: return "M2" case .m3: return "M3" @@ -2453,6 +2528,7 @@ extension Device.CPU: CustomStringConvertible { case .s7: return "S7" case .s8: return "S8" case .s9: return "S9" + case .s10: return "S10" case .unknown: return "unknown" } #elseif os(visionOS) diff --git a/Source/Device.swift.gyb b/Source/Device.swift.gyb index 392310d..4b6f5f8 100644 --- a/Source/Device.swift.gyb +++ b/Source/Device.swift.gyb @@ -82,11 +82,14 @@ iPhones = [ Device("iPhone14Plus", "Device is an [iPhone 14 Plus](https://support.apple.com/kb/SP874)", "https://support.apple.com/library/APPLE/APPLECARE_ALLGEOS/SP873/iphone-14_1_2x.png", ["iPhone14,8"], 6.7, (9, 19.5), "iPhone 14 Plus", "iPhone 14 Plus", 476, True, False, False, True, False, True, True, True, True, False, 0, False, 13, False, "a15Bionic", False, True), Device("iPhone14Pro", "Device is an [iPhone 14 Pro](https://support.apple.com/kb/SP875)", "https://support.apple.com/library/APPLE/APPLECARE_ALLGEOS/SP875/sp875-sp876-iphone14-pro-promax_2x.png", ["iPhone15,2"], 6.1, (9, 19.5), "iPhone 14 Pro", "iPhone 14 Pro", 460, False, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a16Bionic", False, True), Device("iPhone14ProMax", "Device is an [iPhone 14 Pro Max](https://support.apple.com/kb/SP876)", "https://support.apple.com/library/APPLE/APPLECARE_ALLGEOS/SP875/sp875-sp876-iphone14-pro-promax_2x.png", ["iPhone15,3"], 6.7, (9, 19.5), "iPhone 14 Pro Max", "iPhone 14 Pro Max", 458, True, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a16Bionic", False, True), - Device("iPhone15", "Device is an [iPhone 15]()", "", ["iPhone15,4"], 6.1, (9, 19.5), "iPhone 15", "iPhone 15", 460, False, False, False, True, False, True, True, True, True, True, 0, False, 13, False, "a16Bionic", True, True), - Device("iPhone15Plus", "Device is an [iPhone 15 Plus]()", "", ["iPhone15,5"], 6.7, (9, 19.5), "iPhone 15 Plus", "iPhone 15 Plus", 476, True, False, False, True, False, True, True, True, True, True, 0, False, 13, False, "a16Bionic", True, True), - Device("iPhone15Pro", "Device is an [iPhone 15 Pro]()", "", ["iPhone16,1"], 6.1, (9, 19.5), "iPhone 15 Pro", "iPhone 15 Pro", 460, False, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a17Pro", True, True), - Device("iPhone15ProMax", "Device is an [iPhone 15 Pro Max]()", "", ["iPhone16,2"], 6.7, (9, 19.5), "iPhone 15 Pro Max", "iPhone 15 Pro Max", 460, True, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a17Pro", True, True), - + Device("iPhone15", "Device is an [iPhone 15](https://support.apple.com/en-us/111831)", "", ["iPhone15,4"], 6.1, (9, 19.5), "iPhone 15", "iPhone 15", 460, False, False, False, True, False, True, True, True, True, True, 0, False, 13, False, "a16Bionic", True, True), + Device("iPhone15Plus", "Device is an [iPhone 15 Plus](https://support.apple.com/en-us/111830)", "", ["iPhone15,5"], 6.7, (9, 19.5), "iPhone 15 Plus", "iPhone 15 Plus", 476, True, False, False, True, False, True, True, True, True, True, 0, False, 13, False, "a16Bionic", True, True), + Device("iPhone15Pro", "Device is an [iPhone 15 Pro](https://support.apple.com/en-us/111829)", "", ["iPhone16,1"], 6.1, (9, 19.5), "iPhone 15 Pro", "iPhone 15 Pro", 460, False, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a17Pro", True, True), + Device("iPhone15ProMax", "Device is an [iPhone 15 Pro Max](https://support.apple.com/en-us/111828)", "", ["iPhone16,2"], 6.7, (9, 19.5), "iPhone 15 Pro Max", "iPhone 15 Pro Max", 460, True, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a17Pro", True, True), + Device("iPhone16", "Device is an [iPhone 16]()", "", ["iPhone17,3"], 6.1, (9, 19.5), "iPhone 16", "iPhone 16", 460, False, False, False, True, False, True, True, True, True, True, 0, False, 13, False, "a18", True, True), + Device("iPhone16Plus", "Device is an [iPhone 16 Plus]()", "", ["iPhone17,4"], 6.7, (9, 19.5), "iPhone 16 Plus", "iPhone 16 Plus", 476, True, False, False, True, False, True, True, True, True, True, 0, False, 13, False, "a18", True, True), + Device("iPhone16Pro", "Device is an [iPhone 16 Pro]()", "", ["iPhone17,1"], 6.3, (9, 19.5), "iPhone 16 Pro", "iPhone 16 Pro", 460, False, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a18Pro", True, True), + Device("iPhone16ProMax", "Device is an [iPhone 16 Pro Max]()", "", ["iPhone17,2"], 6.9, (9, 19.5), "iPhone 16 Pro Max", "iPhone 16 Pro Max", 460, True, False, True, True, False, True, True, True, True, True, 0, False, 123, True, "a18Pro", True, True), ] iPads = [ @@ -297,6 +300,17 @@ watches = [ "", ["Watch7,5"], 2.2, (4,5), "Apple Watch Ultra2", "Apple Watch Ultra2", 338, False, False, False, False, False, False, False, True, False, False, 0, False, 0, False, "s9", False, False), + Device( + "appleWatchSeries10_42mm", + "Device is an [Apple Watch Series 10]()", + "", + ["Watch7,8", "Watch7,10"], 1.9, (374,446), "Apple Watch Series 10 42mm", "Apple Watch Series 10 42mm", 326, False, False, False, False, False, False, False, True, False, False, 0, False, 0, False, "s10", False, False), + + Device( + "appleWatchSeries10_46mm", + "Device is an [Apple Watch Series 10]()", + "", + ["Watch7,9", "Watch7,11"], 2.0, (416,496), "Apple Watch Series 10 46mm", "Apple Watch Series 10 46mm", 326, False, False, False, False, False, False, False, True, False, False, 0, False, 0, False, "s10", False, False), ] @@ -1475,6 +1489,8 @@ iOS_cpus = [ CPU("a15Bionic", "A15 Bionic"), CPU("a16Bionic", "A16 Bionic"), CPU("a17Pro" , "A17 Pro"), + CPU("a18" , "A18"), + CPU("a18Pro" , "A18 Pro"), CPU("m1", "M1"), CPU("m2", "M2"), CPU("m3", "M3"), @@ -1492,6 +1508,7 @@ watchOS_cpus = [ CPU("s7", "S7"), CPU("s8", "S8"), CPU("s9", "S9"), + CPU("s10", "S10"), ] }% diff --git a/Tests/Tests.swift b/Tests/Tests.swift index dc0a9b9..49ff394 100644 --- a/Tests/Tests.swift +++ b/Tests/Tests.swift @@ -455,7 +455,9 @@ class DeviceKitTests: XCTestCase { .iPhone14Plus, .iPhone14ProMax, .iPhone15Plus, - .iPhone15ProMax + .iPhone15ProMax, + .iPhone16Plus, + .iPhone16ProMax, ]) } @@ -471,6 +473,8 @@ class DeviceKitTests: XCTestCase { .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, + .iPhone16Pro, + .iPhone16ProMax, .iPadPro9Inch, .iPadPro12Inch, .iPadPro12Inch2, @@ -511,7 +515,11 @@ class DeviceKitTests: XCTestCase { .iPhone15, .iPhone15Plus, .iPhone15Pro, - .iPhone15ProMax + .iPhone15ProMax, + .iPhone16, + .iPhone16Plus, + .iPhone16Pro, + .iPhone16ProMax, ] for device in Device.allRealDevices { XCTAssertTrue(device.hasDynamicIsland == device.isOneOf(dynamicIslandDevices), "testHasDynamicIsland failed for \(device.description)") @@ -537,6 +545,10 @@ class DeviceKitTests: XCTestCase { .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, + .iPhone16, + .iPhone16Plus, + .iPhone16Pro, + .iPhone16ProMax, .iPad10, .iPadAir5, .iPadAir11M2, @@ -624,6 +636,8 @@ class DeviceKitTests: XCTestCase { .iPhone14ProMax, .iPhone15Pro, .iPhone15ProMax, + .iPhone16Pro, + .iPhone16ProMax, .iPadPro11Inch2, .iPadPro12Inch4, .iPadPro11Inch3, @@ -644,6 +658,10 @@ class DeviceKitTests: XCTestCase { .iPhone15Plus, .iPhone15Pro, .iPhone15ProMax, + .iPhone16, + .iPhone16Plus, + .iPhone16Pro, + .iPhone16ProMax, .iPad10, .iPadAir4, .iPadAir5,