docs: improve forms cards

This commit is contained in:
Benjamin Canac
2023-05-14 15:04:56 +02:00
parent 37f1a1b5ad
commit c47f5e6a68
4 changed files with 16 additions and 16 deletions

View File

@@ -1,12 +1,12 @@
<script setup>
const open = ref(false)
const isOpen = ref(false)
</script>
<template>
<div>
<UButton label="Open" @click="open = true" />
<UButton label="Open" @click="isOpen = true" />
<USlideover v-model="open">
<USlideover v-model="isOpen">
<div class="p-4 h-full">
<Placeholder class="w-full h-full" />
</div>

View File

@@ -26,6 +26,8 @@ props:
### Placeholder
Use the `placeholder` prop to set a placeholder text.
::component-card
---
baseProps:
@@ -59,15 +61,14 @@ Use the `leading` and `trailing` props to set the icon position or the `leadingI
---
baseProps:
name: 'input'
placeholder: 'Search...'
props:
icon: 'i-heroicons-magnifying-glass-20-solid'
appearance: 'white'
size: 'sm'
trailing: false
placeholder: 'Search...'
excludedProps:
- icon
- placeholder
---
::

View File

@@ -13,7 +13,7 @@ baseProps:
### Size
Use the `size` prop to change the size of the Input.
Use the `size` prop to change the size of the Textarea.
::component-card
---
@@ -26,6 +26,8 @@ props:
### Placeholder
Use the `placeholder` prop to set a placeholder text.
::component-card
---
baseProps:
@@ -37,7 +39,7 @@ props:
### Appearance
Use the `appearance` prop to change the style of the Input.
Use the `appearance` prop to change the style of the Textarea.
::component-card
---
@@ -51,18 +53,16 @@ props:
### Disabled
Use the `disabled` prop to disable the Input.
Use the `disabled` prop to disable the Textarea.
::component-card
---
baseProps:
name: 'input'
props:
placeholder: 'Search...'
props:
appearance: 'white'
disabled: true
excludedProps:
- placeholder
---
::

View File

@@ -38,6 +38,8 @@ props:
### Placeholder
Use the `placeholder` prop to set a placeholder text.
::component-card
---
baseProps:
@@ -83,14 +85,13 @@ baseProps:
- 'United States'
- 'Canada'
- 'Mexico'
placeholder: 'Search...'
props:
icon: 'i-heroicons-magnifying-glass-20-solid'
appearance: 'white'
size: 'sm'
placeholder: 'Search...'
excludedProps:
- icon
- placeholder
---
::
@@ -106,12 +107,10 @@ baseProps:
- 'United States'
- 'Canada'
- 'Mexico'
props:
placeholder: 'Search...'
props:
appearance: 'white'
disabled: true
excludedProps:
- placeholder
---
::