mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-29 03:10:42 +01:00
docs: add input group section
This commit is contained in:
@@ -99,7 +99,7 @@ Use the `loadingIcon` prop to set a different icon or change it globally in `ui.
|
|||||||
---
|
---
|
||||||
baseProps:
|
baseProps:
|
||||||
name: 'input'
|
name: 'input'
|
||||||
placeholder: 'Search'
|
placeholder: 'Searching...'
|
||||||
props:
|
props:
|
||||||
loading: true
|
loading: true
|
||||||
icon: 'i-heroicons-magnifying-glass-20-solid'
|
icon: 'i-heroicons-magnifying-glass-20-solid'
|
||||||
@@ -110,6 +110,30 @@ excludedProps:
|
|||||||
|
|
||||||
### Group
|
### Group
|
||||||
|
|
||||||
|
You can use the `InputGroup` component to add a label and additional informations to a form element.
|
||||||
|
|
||||||
|
::component-card{slug="InputGroup"}
|
||||||
|
---
|
||||||
|
baseProps:
|
||||||
|
name: 'group'
|
||||||
|
props:
|
||||||
|
label: 'Email'
|
||||||
|
help: "We'll only use this for spam."
|
||||||
|
hint: 'Required'
|
||||||
|
required: true
|
||||||
|
code: >-
|
||||||
|
|
||||||
|
<UInput placeholder="you@example.com" icon="i-heroicons-envelope" />
|
||||||
|
---
|
||||||
|
|
||||||
|
#default
|
||||||
|
:u-input{name="group" placeholder="you@example.com" icon="i-heroicons-envelope"}
|
||||||
|
::
|
||||||
|
|
||||||
|
::alert{icon="i-heroicons-light-bulb"}
|
||||||
|
This also works with `Textarea`, `Select` and `SelectMenu` components.
|
||||||
|
::
|
||||||
|
|
||||||
## Props
|
## Props
|
||||||
|
|
||||||
:component-props
|
:component-props
|
||||||
|
|||||||
Reference in New Issue
Block a user