nathantannar4 / InputBarAccessoryView

A simple and easily customizable InputAccessoryView for making powerful input bars with autocomplete and attachments
MIT License
1.17k stars 229 forks source link

Doc/Implementation Inconsistent #203

Open mredig opened 3 years ago

mredig commented 3 years ago

The inline docs for InputStackView state

A UIStackView that's intended for holding InputItems

Important Notes

  1. Default alignment is .fill
  2. Default distribution is .fill
  3. The distribution property needs to be based on its arranged subviews intrinsicContentSize so it is not recommended to change it

but the setup function sets the alignment to .bottom

    open func setup() {
        translatesAutoresizingMaskIntoConstraints = false
        distribution = .fill
        alignment = .bottom
    }

I'm uncertain as to which was intended.

Kaspik commented 3 years ago

I think the doc is not up to date. Would you mind updating it in a PR?

The code itself lives there for some time and is probably... working as expected.