//
//  GMFaceButton.swift
//  Gengmei
//
//  Created by Locus on 2019/9/18.
//  Copyright © 2019 更美互动信息科技有限公司. All rights reserved.
//

import Foundation

class GMFaceButton: GMButton {
    var faceImageView : GMImageView!
    var faceLabel : GMLabel!
    
    override func setup() {
        faceImageView = GMImageView.init()
        faceImageView.layer.cornerRadius = 4
        faceImageView.layer.masksToBounds = true
        faceImageView.contentMode = .scaleAspectFill
        self.addSubview(faceImageView)
        faceImageView.snp.makeConstraints { (make) in
            make.size.equalTo(CGSize.init(width: 35, height: 35))
            make.centerX.top.equalToSuperview()
        }
        
        faceLabel = GMLabel.init(textColor: UIColor.auxiliaryTextDark, fontSize: 11)
        faceLabel.textAlignment = .center
        self.addSubview(faceLabel)
        faceLabel.snp.makeConstraints { (make) in
            make.centerX.bottom.equalToSuperview()
            make.size.equalTo(CGSize.init(width: 44, height: 11))
        }
    }
}
