Progress bar molecule changes
This commit is contained in:
parent
93ba680bb8
commit
d56335d103
@ -14,8 +14,7 @@ import Foundation
|
|||||||
let rightLabel = Label(frame: .zero)
|
let rightLabel = Label(frame: .zero)
|
||||||
let leftLabelWidthConstant : CGFloat = 151.0
|
let leftLabelWidthConstant : CGFloat = 151.0
|
||||||
let rightLabelWidthConstant : CGFloat = 84.0
|
let rightLabelWidthConstant : CGFloat = 84.0
|
||||||
let progressBarTrailingConstant : CGFloat = -92.0
|
let progressBarTrailingConstant : CGFloat = -100.0
|
||||||
let progressBarLeadingConstant : CGFloat = 195.0
|
|
||||||
// MARK: - MVMCoreViewProtocol
|
// MARK: - MVMCoreViewProtocol
|
||||||
open override func updateView(_ size: CGFloat) {
|
open override func updateView(_ size: CGFloat) {
|
||||||
super.updateView(size)
|
super.updateView(size)
|
||||||
@ -43,7 +42,7 @@ import Foundation
|
|||||||
leftLabel.widthAnchor.constraint(lessThanOrEqualToConstant: leftLabelWidthConstant)
|
leftLabel.widthAnchor.constraint(lessThanOrEqualToConstant: leftLabelWidthConstant)
|
||||||
])
|
])
|
||||||
|
|
||||||
let rightLabelTrailing = rightLabel.trailingAnchor.constraint(equalTo: container.trailingAnchor, constant:-PaddingHorizontalBetweenRelatedItems)
|
let rightLabelTrailing = rightLabel.trailingAnchor.constraint(equalTo: container.trailingAnchor, constant:0)
|
||||||
NSLayoutConstraint.activate([
|
NSLayoutConstraint.activate([
|
||||||
rightLabelTrailing,
|
rightLabelTrailing,
|
||||||
rightLabel.leadingAnchor.constraint(greaterThanOrEqualTo : progressBar.trailingAnchor),
|
rightLabel.leadingAnchor.constraint(greaterThanOrEqualTo : progressBar.trailingAnchor),
|
||||||
|
|||||||
@ -36,6 +36,8 @@ public class LabelsWithCircleProgressBarModel:MoleculeModelProtocol {
|
|||||||
leftLabel = try typeContainer.decode(LabelModel.self, forKey: .leftLabel)
|
leftLabel = try typeContainer.decode(LabelModel.self, forKey: .leftLabel)
|
||||||
rightLabel = try typeContainer.decode(LabelModel.self, forKey: .rightLabel)
|
rightLabel = try typeContainer.decode(LabelModel.self, forKey: .rightLabel)
|
||||||
progressBar = try typeContainer.decode(CircleProgressModel.self, forKey: .progressBar)
|
progressBar = try typeContainer.decode(CircleProgressModel.self, forKey: .progressBar)
|
||||||
|
progressBar.size = .small;
|
||||||
|
progressBar.style = .unlimited;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user