arrow changes implemented
This commit is contained in:
parent
5f125524be
commit
c51dcfc574
@ -16,14 +16,15 @@ import Foundation
|
||||
public let eyebrowHeadlineBodyLink = EyebrowHeadlineBodyLink(frame: .zero)
|
||||
public let rightLabel = Label.commonLabelB2(true)
|
||||
public let arrow = Arrow(frame: .zero)
|
||||
|
||||
|
||||
let arrowAndrightLabelStack: Stack<StackModel>
|
||||
|
||||
// MARK: - Initializers
|
||||
public override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
|
||||
arrowAndrightLabelStack = Stack<StackModel>.createStack(with: [(view: arrow, model: StackItemModel(horizontalAlignment: .fill)),
|
||||
(view: rightLabel, model: StackItemModel(horizontalAlignment: .leading))],
|
||||
axis: .horizontal, spacing: 4)
|
||||
stack = Stack<StackModel>.createStack(with: [(view: eyebrowHeadlineBodyLink, model: StackItemModel(horizontalAlignment: .leading)),
|
||||
(view: rightLabel, model: StackItemModel(horizontalAlignment:.fill)),
|
||||
(view: arrow, model: StackItemModel(horizontalAlignment:.fill))],
|
||||
(view: arrowAndrightLabelStack, model: StackItemModel(verticalAlignment: .top))],
|
||||
axis: .horizontal)
|
||||
super.init(style: style, reuseIdentifier: reuseIdentifier)
|
||||
}
|
||||
@ -37,8 +38,11 @@ import Foundation
|
||||
//-----------------------------------------------------
|
||||
override open func setupView() {
|
||||
super.setupView()
|
||||
arrow.pinHeightAndWidth()
|
||||
addMolecule(stack)
|
||||
stack.restack()
|
||||
arrowAndrightLabelStack.restack()
|
||||
|
||||
}
|
||||
|
||||
open override func set(with model: MoleculeModelProtocol, _ delegateObject: MVMCoreUIDelegateObject?, _ additionalData: [AnyHashable : Any]?) {
|
||||
@ -52,4 +56,8 @@ import Foundation
|
||||
open override class func estimatedHeight(with model: MoleculeModelProtocol, _ delegateObject: MVMCoreUIDelegateObject?) -> CGFloat? {
|
||||
return 120
|
||||
}
|
||||
open override func reset() {
|
||||
super.reset()
|
||||
rightLabel.styleB2(true)
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user