             addSublayer(circleLayer)
         }
     }
-    
+
     fileprivate var previousBounds: CGRect?
-    override func layoutSublayers() {
+    override open func layoutSublayers() {
         if let previousBounds = previousBounds, previousBounds.equalTo(bounds) {
             return
         }
-        
+
         updateStatus()
         previousBounds = bounds
     }
     
-    
-    enum Status {
-        case idle
-        case hover
-        case loading
-    }
-    var status: Status = .idle {
+    open var status: Status = .idle {
         didSet {
             if oldValue != status {
                 updateStatus()
             }
         }
     }
-    
+
     fileprivate func setupCircleLayersForNonLoadingStatus(_ opacity: Float) {
         for i in 0 ..< 3 {
             let circleLayer = circleLayers[i]

            break
        }
    }
    
    fileprivate func transformWithAngle(_ angle: CGFloat) -> NSValue {
        return NSValue(caTransform3D: CATransform3DMakeRotation(angle, 0, 0, 1))
    }
}

import Cocoa

open class LoadingIndicatorLayer: CALayer {
    public enum Status {
        case idle
        case hover
        case loading
    }
    
    fileprivate var circleLayers = [CAShapeLayer]()

    required public init?(coder aDecoder: NSCoder) {
        fatalError()
    }

    override init(layer: Any) {
        super.init(layer: layer)
    }

    public override init() {
        super.init()

        for _ in 0 ..< 3 {
            let circleLayer = CAShapeLayer()
            circleLayer.lineWidth = 10
