fixed notification issues
Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
parent
5ff8d2f06e
commit
01a177f643
@ -221,15 +221,24 @@ open class Notification: View {
|
|||||||
/// Called once when a view is initialized and is used to Setup additional UI or other constants and configurations.
|
/// Called once when a view is initialized and is used to Setup additional UI or other constants and configurations.
|
||||||
open override func setup() {
|
open override func setup() {
|
||||||
super.setup()
|
super.setup()
|
||||||
addSubview(mainStackView)
|
|
||||||
mainStackView.pinToSuperView(.init(top: edgeSpacing, left: edgeSpacing, bottom: edgeSpacing, right: edgeSpacing))
|
|
||||||
|
|
||||||
|
let layoutGuide = UILayoutGuide()
|
||||||
|
addLayoutGuide(layoutGuide)
|
||||||
|
layoutGuide
|
||||||
|
.pinTop(0)
|
||||||
|
.pinLeading(0)
|
||||||
|
.pinTrailing(0, .defaultHigh)
|
||||||
|
.pinBottom(0, .defaultHigh)
|
||||||
|
|
||||||
|
addSubview(mainStackView)
|
||||||
|
mainStackView.pin(layoutGuide, with: .init(top: edgeSpacing, left: edgeSpacing, bottom: edgeSpacing, right: edgeSpacing))
|
||||||
|
|
||||||
NSLayoutConstraint.activate([
|
NSLayoutConstraint.activate([
|
||||||
heightAnchor.constraint(greaterThanOrEqualToConstant: minViewHeight),
|
layoutGuide.heightAnchor.constraint(greaterThanOrEqualToConstant: minViewHeight),
|
||||||
mainStackView.heightAnchor.constraint(greaterThanOrEqualToConstant: minContentHeight),
|
mainStackView.heightAnchor.constraint(greaterThanOrEqualToConstant: minContentHeight),
|
||||||
widthAnchor.constraint(greaterThanOrEqualToConstant: minViewWidth)
|
layoutGuide.widthAnchor.constraint(greaterThanOrEqualToConstant: minViewWidth)
|
||||||
])
|
])
|
||||||
maxWidthConstraint = widthAnchor.constraint(lessThanOrEqualToConstant: maxViewWidth)
|
maxWidthConstraint = layoutGuide.widthAnchor.constraint(lessThanOrEqualToConstant: maxViewWidth)
|
||||||
|
|
||||||
labelButtonView.addArrangedSubview(labelsView)
|
labelButtonView.addArrangedSubview(labelsView)
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user