Skip to content

Commit

Permalink
fix(HighlightedCard): nake init with parameters: `(title:subtitle:rig…
Browse files Browse the repository at this point in the history
…htImage:actionButtonStyle:)` configures the correct styles.
  • Loading branch information
jmbrocal committed Feb 10, 2021
1 parent b6a2921 commit 31f2bf6
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions Mistica/Source/Components/HighlightedCard/HighlightedCard.swift
Original file line number Diff line number Diff line change
Expand Up @@ -140,15 +140,18 @@ public class HighlightedCard: UIView {
}
}

public convenience init(title: String? = nil,
subtitle: String? = nil,
rightImage: UIImage? = nil,
actionButtonStyle: ButtonStyle = .primary) {
self.init(frame: .zero)
public init(title: String? = nil,
subtitle: String? = nil,
rightImage: UIImage? = nil,
actionButtonStyle: ButtonStyle = .primary) {
super.init(frame: .zero)

self.title = title
self.subtitle = subtitle
self.rightImage = rightImage
self.actionButtonStyle = actionButtonStyle

commonInit()
}

override public init(frame: CGRect) {
Expand Down

0 comments on commit 31f2bf6

Please sign in to comment.