updated button

Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
Matt Bruce 2023-07-20 19:36:36 -05:00
parent 69482c2c7a
commit c44beb5e32
2 changed files with 9 additions and 2 deletions

View File

@ -48,6 +48,7 @@ public class PickerSelectorView<EnumType: RawRepresentable>: UIStackView, Picker
instance.size = .small
instance.use = .secondary
instance.text = "Select"
instance.width = 150
}
public var text: String = "" {
@ -73,9 +74,15 @@ public class PickerSelectorView<EnumType: RawRepresentable>: UIStackView, Picker
self.alignment = .fill
text = title
label.text = title
let buttonWrapper = View()
buttonWrapper.addSubview(button)
button.pinTop()
button.pinBottom()
button.pinTrailing()
button.pinLeadingGreaterThanOrEqualTo(anchor: buttonWrapper.leadingAnchor)
updateSelectedIndex()
addArrangedSubview(label)
addArrangedSubview(.makeWrapper(for: button, isTrailing: false))
addArrangedSubview(buttonWrapper)
button.onClick = { [weak self] _ in
self?.picker?.delegate = self
self?.picker?.dataSource = self

View File

@ -58,7 +58,7 @@ class TileContainerViewController: BaseViewController<TileContainer> {
override func allTextFields() -> [TextField]? { [widthTextField, heightTextField] }
override func setupForm(){
super.setupForm()
formStackView.addArrangedSubview(Label().with{
formStackView.addArrangedSubview(Label().with {
$0.textStyle = .boldBodyLarge
$0.text = "This object does NOT reflect normal \"surface\" changes, all properties are maually set"
})