diff --git a/VDS/Components/Notification/Notification.swift b/VDS/Components/Notification/Notification.swift index aea2be6d..f0a4d58b 100644 --- a/VDS/Components/Notification/Notification.swift +++ b/VDS/Components/Notification/Notification.swift @@ -101,9 +101,9 @@ public class Notification: View { } //Text - open var titleText: String = "" { didSet{didChange()}} + open var title: String = "" { didSet{didChange()}} - open var subTitleText: String? { didSet{didChange()}} + open var subTitle: String? { didSet{didChange()}} //Buttons open var primaryButtonModel: ButtonModel? { didSet{didChange()}} @@ -195,6 +195,8 @@ public class Notification: View { mainStackView.heightAnchor.constraint(greaterThanOrEqualToConstant: minContentHeight) ]) + labelButtonView.addArrangedSubview(labelsView) + mainStackView.addArrangedSubview(typeIcon) mainStackView.addArrangedSubview(labelButtonView) mainStackView.addArrangedSubview(closeButton) @@ -240,15 +242,15 @@ public class Notification: View { titleLabel.surface = surface subTitleLabel.surface = surface - if !titleText.isEmpty { - titleLabel.text = titleText + if !title.isEmpty { + titleLabel.text = title labelsView.addArrangedSubview(titleLabel) } else { titleLabel.removeFromSuperview() } - if let subTitleText { - subTitleLabel.text = subTitleText + if let subTitle { + subTitleLabel.text = subTitle labelsView.addArrangedSubview(subTitleLabel) } else { subTitleLabel.removeFromSuperview()