Updating default button style
This commit is contained in:
parent
9c3d211a81
commit
89bc6c72ab
@ -85,6 +85,7 @@ open class ButtonModel: ButtonModelProtocol, MoleculeModelProtocol, FormGroupWat
|
||||
public init(with title: String, action: ActionModelProtocol) {
|
||||
self.title = title
|
||||
self.action = action
|
||||
setFacade(by: style ?? .primary)
|
||||
}
|
||||
|
||||
public init(secondaryButtonWith title: String, action: ActionModelProtocol) {
|
||||
@ -218,6 +219,8 @@ open class ButtonModel: ButtonModelProtocol, MoleculeModelProtocol, FormGroupWat
|
||||
if let style = try typeContainer.decodeIfPresent(Styler.Button.Style.self, forKey: .style) {
|
||||
self.style = style
|
||||
setFacade(by: style)
|
||||
} else {
|
||||
setFacade(by: .primary)
|
||||
}
|
||||
|
||||
if let size = try typeContainer.decodeIfPresent(Styler.Button.Size.self, forKey: .size) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user