import ComponentLibrary
import Foundation
import SwiftUI

struct LyricsLineView: View {
    let lineText: String
    let fontScale: CGFloat

    init(lineText: String, fontScale: CGFloat) {
        self.lineText = lineText
        self.fontScale = fontScale
    }

    var body: some View {
        HStack {
            Text(attributedString(
                for: lineText,
                typography: TypographyV1.headline3.neueMontrealMedium().size { originalFontSize in
                    originalFontSize * fontScale
                },
                foregroundColor: .SemanticV1.textOnDark,
                emphasizedColor: .SemanticV1.textOnDark,
                emphasizedTypography: TypographyV1.caption3
            ))
            .shadow(color: .black.opacity(0.5), radius: 8, x: 0, y: 0)
            Spacer()
        }
    }
}
