//
//  SpeakEleProgressListCell.swift
//  SpeakEasyLearnEnglish
//
//  Created by edy on 2025/7/22.
//

import UIKit

class SpeakEleProgressListCell: UITableViewCell {

    static let id = "SpeakEleProgressListCell"
    
    @IBOutlet var SpeakProgressListBtns: [UIButton]!
    
    override func awakeFromNib() {
        super.awakeFromNib()
        SpeakProgressListBtns.forEach { btn in
            btn.setBackgroundImage(UIColor.init(hex: 0x000000,alpha: 0.2).generate(), for: .highlighted)
        }
    }

    @IBAction func SpeakListBtnTaps(_ sender: UIButton) {
        var idx = 0
        for i in SpeakProgressListBtns {
            if sender == i {
                guard let call = callblack else { return }
                call(idx)
                break
            }
            idx += 1
        }
    }
    
}
