Generate a Feedback gesture with some UIImpactFeedbackStyle
import EBTools
.
.
EBToolsUI.feedback(style: .light)Convert RGB values and returns UIColor, alpha value is optional and 1.0 by default
import EBTools
.
.
let uiColor = EBToolsUI.rgbToColor(r: 0, g: 0, b:0, alpha: 1.0) Get the top and bottom anchor constraint to SafeAfea no matter if the device has notch or not
let myView = UIView()
// remember to set this to false to use AutoLayout
myView.translatesAutoresizingMaskIntoConstraints = false
.
.
myView.topAnchor.constraint(equalTo: self.view.getTopAnchor()).isActive = true
myView.bottomAnchor.constraint(equalTo: self.view.getBottomAnchor()).isActive = true