Device
Device copied to clipboard
BUG: Device.Size: iPad mini 6th not handled
You have support for .iPadMini6 in the function, getVersion(code: String). But, you don't properly support in size(). It defaults to unknown. You need to add a case for the enum Size for 8.3 inches for the iPad mini 6th gen.
Additionally, the screenHeight switch in your size function needs a case for '1133' for the iPad mini 6th gen.
static public func size() -> Size {
let w: Double = Double(UIScreen.main.bounds.width)
let h: Double = Double(UIScreen.main.bounds.height)
let screenHeight: Double = max(w, h)
switch screenHeight {
...
// case: 1133 need to be handled.
}
}