chore: add images, docs item
|
|
@ -128,12 +128,10 @@ export const docsConfig: DocsConfig = {
|
||||||
title: 'Auto Form',
|
title: 'Auto Form',
|
||||||
href: '/docs/components/auto-form',
|
href: '/docs/components/auto-form',
|
||||||
items: [],
|
items: [],
|
||||||
label: 'New',
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Charts',
|
title: 'Charts',
|
||||||
href: '/docs/charts',
|
href: '/docs/charts',
|
||||||
label: 'New Alpha',
|
|
||||||
items: [],
|
items: [],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|
@ -141,6 +139,11 @@ export const docsConfig: DocsConfig = {
|
||||||
{
|
{
|
||||||
title: 'Components',
|
title: 'Components',
|
||||||
items: [
|
items: [
|
||||||
|
{
|
||||||
|
title: 'Sidebar',
|
||||||
|
href: '/docs/components/sidebar',
|
||||||
|
label: 'New',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
title: 'Accordion',
|
title: 'Accordion',
|
||||||
href: '/docs/components/accordion',
|
href: '/docs/components/accordion',
|
||||||
|
|
@ -178,7 +181,6 @@ export const docsConfig: DocsConfig = {
|
||||||
title: 'Calendar',
|
title: 'Calendar',
|
||||||
href: '/docs/components/calendar',
|
href: '/docs/components/calendar',
|
||||||
items: [],
|
items: [],
|
||||||
label: 'Updated',
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Card',
|
title: 'Card',
|
||||||
|
|
@ -217,7 +219,6 @@ export const docsConfig: DocsConfig = {
|
||||||
title: 'Date Picker',
|
title: 'Date Picker',
|
||||||
href: '/docs/components/date-picker',
|
href: '/docs/components/date-picker',
|
||||||
items: [],
|
items: [],
|
||||||
label: 'Updated',
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Dialog',
|
title: 'Dialog',
|
||||||
|
|
@ -259,7 +260,6 @@ export const docsConfig: DocsConfig = {
|
||||||
{
|
{
|
||||||
title: 'Number Field',
|
title: 'Number Field',
|
||||||
href: '/docs/components/number-field',
|
href: '/docs/components/number-field',
|
||||||
label: 'New Alpha',
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Pagination',
|
title: 'Pagination',
|
||||||
|
|
@ -324,7 +324,6 @@ export const docsConfig: DocsConfig = {
|
||||||
{
|
{
|
||||||
title: 'Stepper',
|
title: 'Stepper',
|
||||||
href: '/docs/components/stepper',
|
href: '/docs/components/stepper',
|
||||||
label: 'New',
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: 'Switch',
|
title: 'Switch',
|
||||||
|
|
|
||||||
73
apps/www/src/content/docs/components/sidebar.md
Normal file
|
|
@ -0,0 +1,73 @@
|
||||||
|
---
|
||||||
|
title: Sheet
|
||||||
|
description: Extends the Dialog component to display content that complements the main content of the screen.
|
||||||
|
source: apps/www/src/lib/registry/default/ui/sheet
|
||||||
|
primitive: https://www.radix-vue.com/components/dialog.html
|
||||||
|
---
|
||||||
|
|
||||||
|
<ComponentPreview name="SheetDemo" />
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npx shadcn-vue@latest add sheet
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
```vue
|
||||||
|
<script setup lang="ts">
|
||||||
|
import {
|
||||||
|
Sheet,
|
||||||
|
SheetContent,
|
||||||
|
SheetDescription,
|
||||||
|
SheetHeader,
|
||||||
|
SheetTitle,
|
||||||
|
SheetTrigger,
|
||||||
|
} from '@/components/ui/sheet'
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<Sheet>
|
||||||
|
<SheetTrigger>Open</SheetTrigger>
|
||||||
|
<SheetContent>
|
||||||
|
<SheetHeader>
|
||||||
|
<SheetTitle>Are you absolutely sure?</SheetTitle>
|
||||||
|
<SheetDescription>
|
||||||
|
This action cannot be undone. This will permanently delete your account
|
||||||
|
and remove your data from our servers.
|
||||||
|
</SheetDescription>
|
||||||
|
</SheetHeader>
|
||||||
|
</SheetContent>
|
||||||
|
</Sheet>
|
||||||
|
</template>
|
||||||
|
```
|
||||||
|
|
||||||
|
## Examples
|
||||||
|
|
||||||
|
### Side
|
||||||
|
|
||||||
|
Use the `side` property to `<SheetContent />` to indicate the edge of the screen where the component will appear. The values can be `top`, `right`, `bottom` or `left`.
|
||||||
|
|
||||||
|
<ComponentPreview name="SheetSideDemo" />
|
||||||
|
|
||||||
|
### Size
|
||||||
|
|
||||||
|
You can adjust the size of the sheet using CSS classes:
|
||||||
|
|
||||||
|
```vue:line-numbers {4}
|
||||||
|
<template>
|
||||||
|
<Sheet>
|
||||||
|
<SheetTrigger>Open</SheetTrigger>
|
||||||
|
<SheetContent class="w-[400px] sm:w-[540px]">
|
||||||
|
<SheetHeader>
|
||||||
|
<SheetTitle>Are you absolutely sure?</SheetTitle>
|
||||||
|
<SheetDescription>
|
||||||
|
This action cannot be undone. This will permanently delete your account
|
||||||
|
and remove your data from our servers.
|
||||||
|
</SheetDescription>
|
||||||
|
</SheetHeader>
|
||||||
|
</SheetContent>
|
||||||
|
</Sheet>
|
||||||
|
</template>
|
||||||
|
```
|
||||||
|
|
@ -12,7 +12,7 @@ const props = defineProps<{
|
||||||
<li
|
<li
|
||||||
role="presentation"
|
role="presentation"
|
||||||
aria-hidden="true"
|
aria-hidden="true"
|
||||||
:class="cn('[&>svg]:size-3.5', props.class)"
|
:class="cn('[&>svg]:w-3.5 [&>svg]:h-3.5', props.class)"
|
||||||
>
|
>
|
||||||
<slot>
|
<slot>
|
||||||
<ChevronRight />
|
<ChevronRight />
|
||||||
|
|
|
||||||
|
After Width: | Height: | Size: 49 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-controlled.png
Normal file
|
After Width: | Height: | Size: 49 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-dark.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-footer-dark.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-footer.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 36 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-group-action.png
Normal file
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 29 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-group-dark.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-group.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-header-dark.png
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-header.png
Normal file
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 46 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-menu-action.png
Normal file
|
After Width: | Height: | Size: 46 KiB |
|
After Width: | Height: | Size: 48 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-menu-badge.png
Normal file
|
After Width: | Height: | Size: 48 KiB |
|
After Width: | Height: | Size: 47 KiB |
|
After Width: | Height: | Size: 47 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-menu-dark.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-menu-sub-dark.png
Normal file
|
After Width: | Height: | Size: 127 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-menu-sub.png
Normal file
|
After Width: | Height: | Size: 127 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-menu.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-rsc-dark.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar-rsc.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
apps/www/src/public/images/blocks/demo-sidebar.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
apps/www/src/public/images/blocks/login-01-dark.png
Normal file
|
After Width: | Height: | Size: 70 KiB |
BIN
apps/www/src/public/images/blocks/login-01.png
Normal file
|
After Width: | Height: | Size: 70 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-01-dark.png
Normal file
|
After Width: | Height: | Size: 128 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-01.png
Normal file
|
After Width: | Height: | Size: 126 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-02-dark.png
Normal file
|
After Width: | Height: | Size: 136 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-02.png
Normal file
|
After Width: | Height: | Size: 133 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-03-dark.png
Normal file
|
After Width: | Height: | Size: 138 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-03.png
Normal file
|
After Width: | Height: | Size: 137 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-04-dark.png
Normal file
|
After Width: | Height: | Size: 136 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-04.png
Normal file
|
After Width: | Height: | Size: 136 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-05-dark.png
Normal file
|
After Width: | Height: | Size: 110 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-05.png
Normal file
|
After Width: | Height: | Size: 109 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-06-dark.png
Normal file
|
After Width: | Height: | Size: 88 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-06.png
Normal file
|
After Width: | Height: | Size: 88 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-07-dark.png
Normal file
|
After Width: | Height: | Size: 103 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-07.png
Normal file
|
After Width: | Height: | Size: 103 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-08-dark.png
Normal file
|
After Width: | Height: | Size: 112 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-08.png
Normal file
|
After Width: | Height: | Size: 112 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-09-dark.png
Normal file
|
After Width: | Height: | Size: 235 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-09.png
Normal file
|
After Width: | Height: | Size: 231 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-10-dark.png
Normal file
|
After Width: | Height: | Size: 238 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-10.png
Normal file
|
After Width: | Height: | Size: 239 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-11-dark.png
Normal file
|
After Width: | Height: | Size: 101 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-11.png
Normal file
|
After Width: | Height: | Size: 100 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-12-dark.png
Normal file
|
After Width: | Height: | Size: 108 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-12.png
Normal file
|
After Width: | Height: | Size: 98 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-13-dark.png
Normal file
|
After Width: | Height: | Size: 93 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-13.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-14-dark.png
Normal file
|
After Width: | Height: | Size: 140 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-14.png
Normal file
|
After Width: | Height: | Size: 139 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-15-dark.png
Normal file
|
After Width: | Height: | Size: 254 KiB |
BIN
apps/www/src/public/images/blocks/sidebar-15.png
Normal file
|
After Width: | Height: | Size: 245 KiB |
BIN
apps/www/src/public/images/sidebar-menu-dark.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
apps/www/src/public/images/sidebar-menu.png
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
apps/www/src/public/images/sidebar-structure-dark.png
Normal file
|
After Width: | Height: | Size: 40 KiB |
BIN
apps/www/src/public/images/sidebar-structure.png
Normal file
|
After Width: | Height: | Size: 40 KiB |