diff --git a/Sources/UIKitComponents/CatalogButton.swift b/Sources/UIKitComponents/CatalogButton.swift index 561dce7..40c6f90 100644 --- a/Sources/UIKitComponents/CatalogButton.swift +++ b/Sources/UIKitComponents/CatalogButton.swift @@ -10,20 +10,22 @@ import SwiftUI public struct CatalogButton: View { let title: String + let disactive: Bool let action: () -> () - public init(title: String, action: @escaping () -> Void) { + public init(title: String, disactive: Bool, action: @escaping () -> Void) { self.title = title + self.disactive = disactive self.action = action } public var body: some View { - CustomMainButtonView(title: title, size: .chips, disactive: true) {action()} + CustomMainButtonView(title: title, size: .chips, disactive: disactive) {action()} } } #Preview { - CatalogButton(title: "Женщинам") { + CatalogButton(title: "Женщинам", disactive: true) { } }