# Buttons, inputs and other kinds

The attribute that names a kind of container also holds its main value:

| Write | You get |
|---|---|
| `button: "Save"` | a button with that label |
| `input: "Your name"` | a text field; the words show while it is empty. Read what was typed as `name.text` |
| `search: "Search songs"` | a search field |
| `icon: heart` | an icon; its size and colour come from `text_style` |
| `link: "https://…"` | opens the page when tapped |
| `arrange: column, scroll` | a list that scrolls |

```vi
greeting = "Type your name and press Enter"

main form:
  space_inside: 24
  space_between: 12
  children:
    name_box:
      input: "Your name"
      on_change: greeting = "Hello, {name_box.text}…"
      on_submit: greeting = "Hello, {name_box.text}!"
    message:
      text: greeting
      text_style: 18
    row:
      arrange: row, center
      space_between: 8
      children:
        star:
          icon: star
          text_style: 28, amber[500]
        more:
          link: "https://example.com"
          text: "Read more"
```
