Components
- Accordion
- Alert
- Alert Dialog
- Aspect Ratio
- Attachment
- Avatar
- Badge
- Breadcrumb
- Bubble
- Button
- Button Group
- Calendar
- Card
- Carousel
- Chart
- Checkbox
- Collapsible
- Combobox
- Command
- Context Menu
- Data Table
- Date Picker
- Dialog
- Direction
- Drawer
- Dropdown Menu
- Empty
- Field
- Hover Card
- Input
- Input Group
- Input OTP
- Item
- Kbd
- Label
- Marker
- Message
- Message Scroller
- Native Select
- Pagination
- Popover
- Progress
- Questionnaire
- Radio Group
- Resizable
- Scroll Area
- Select
- Separator
- Sheet
- Sidebar
- Skeleton
- Slider
- Sonner
- Spinner
- Switch
- Table
- Tabs
- Textarea
- Toast
- Toggle
- Toggle Group
- Tooltip
- Typography
Sections
@shadcn/react
@shadcn/helpers
Utilities
DirectionProvider コンポーネントは、アプリケーションのテキスト方向 (ltr または rtl) を設定するために使用されます。これは、アラビア語、ヘブライ語、ペルシア語などの右から左に記述する言語をサポートするために不可欠です。
RTL モードでのコンポーネントのプレビューを次に示します。言語を切り替えるには、言語セレクターを使用します。さらに例を参照するには、コンポーネント ページの RTL セクションを探してください。
تسجيل الدخول إلى حسابك
أدخل بريدك الإلكتروني أدناه لتسجيل الدخول إلى حسابك
インストール#
pnpm dlx shadcn@latest add direction
使い方#
import { DirectionProvider } from "@/components/ui/direction"<html dir="rtl">
<body>
<DirectionProvider direction="rtl">
{/* Your app content */}
</DirectionProvider>
</body>
</html>useDirection#
useDirection フックは、アプリケーションの現在の方向を取得するために使用されます。
import { useDirection } from "@/components/ui/direction"
function MyComponent() {
const direction = useDirection()
return <div>Current direction: {direction}</div>
}shadcn/uiアプリをVercelにデプロイ
OpenAI、Sonos、Adobeなどに採用されています。
Vercelは、アプリや機能を大規模にデプロイするためのツールと インフラを提供します。
Vercelにデプロイ