//
//  TestUI1Controller.swift

//
//  Created by Leon on 2025/7/12.
//

import UIKit
import SnapKit
import Kingfisher
import APNGKit

class TestUI1Controller: CLBaseViewController {

    lazy var view1 = UIView()
    
    override func viewDidLoad() {
        super.viewDidLoad()

        view.addSubview(view1)
        view1.snp.makeConstraints { make in
            make.leading.equalToSuperview().offset(24)
            make.top.equalToSuperview().offset(100)
            make.size.equalTo(CGSize(width: 100, height: 40))
        }
        view1.backgroundColor = .c.cwvn
            //.cl.cph
        
        do{
            let indicatorView = {
                let v = APNGImageView()
                
                v.contentMode = .scaleAspectFit
                view.addSubview(v)
                v.snp.makeConstraints { make in
                    make.center.equalToSuperview()
                    make.size.equalTo(CGSize(width: 96, height: 96))
                }
                
                if let url = Bundle.main.url(forResource: "generating", withExtension: "png") {
                    let image = try? APNGImage(fileURL: url)
                    v.image = image
                }
                
    
                
                return v
            }()
        }
    }
    

}
