   private static var cachedImages = [String: UIImage]()
   private var cacheKey: String {
     var attributes = [String: String]()
-    attributes["color"] = String(self.color.hashValue)
+    attributes["colors"] = String(self.colors.description.hashValue)
+    attributes["colorLocations"] = String(self.colorLocations.description.hashValue)
+    attributes["colorStartPoint"] = String(String(describing: self.colorStartPoint).hashValue)
+    attributes["colorEndPoint"] = String(String(describing: self.colorEndPoint).hashValue)
     attributes["borderColor"] = String(self.borderColor.hashValue)
     attributes["borderWidth"] = String(self.borderWidth.hashValue)
     attributes["borderAlignment"] = String(self.borderAlignment.hashValue)

    case resizable
  }

  fileprivate var color = UIColor.clear
  fileprivate var borderColor = UIColor.black
  fileprivate var borderWidth: CGFloat = 0
  fileprivate var borderAlignment: BorderAlignment = .inside
  fileprivate var cornerRadiusTopLeft: CGFloat = 0
  fileprivate var cornerRadiusTopRight: CGFloat = 0
  fileprivate var cornerRadiusBottomLeft: CGFloat = 0
  fileprivate var cornerRadiusBottomRight: CGFloat = 0
  fileprivate var size: Size = .resizable



    )

    let image = UIImage.with(size: imageSize) { context in
      let path: UIBezierPath

      if self.cornerRadiusTopLeft == self.cornerRadiusTopRight &&
