mirror of
https://github.com/supabase/supabase.git
synced 2026-10-11 20:35:07 +03:00
fix imports
This commit is contained in:
1 parent
63d03111e5
commit
5b869bc1e4
6 files changed
+43
-40
No files matched your search
@@ -1,6 +1,6 @@
|
||||
import { Alert, AlertDescription, AlertTitle } from '@ui/components/shadcn/ui/alert'
|
||||
import { AlertCircle, Terminal, AlertTriangle, Info } from 'lucide-react'
|
||||
import { Meta } from '@storybook/react'
|
||||
import { Alert, AlertDescription, AlertTitle } from '@ui/components/shadcn/ui/alert'
|
||||
import { AlertCircle, Info } from 'lucide-react'
|
||||
|
||||
const meta: Meta<typeof Alert> = {
|
||||
title: 'shadcn/Alert',
|
||||
@@ -11,31 +11,27 @@ export const Default = () => (
|
||||
<Alert>
|
||||
<Info strokeWidth={2} />
|
||||
<AlertTitle>Heads up!</AlertTitle>
|
||||
<AlertDescription>You can add components to your app using the cli.</AlertDescription>
|
||||
<AlertDescription>You can add components to your app using the cli.</AlertDescription>
|
||||
</Alert>
|
||||
)
|
||||
|
||||
Default.storyName = 'Default'
|
||||
|
||||
export const Destructive = () => (
|
||||
<Alert variant="destructive">
|
||||
<Alert variant="destructive">
|
||||
<AlertCircle className="h-4 w-4" />
|
||||
<AlertTitle>Error</AlertTitle>
|
||||
<AlertDescription>
|
||||
Your session has expired. Please log in again.
|
||||
</AlertDescription>
|
||||
<AlertDescription>Your session has expired. Please log in again.</AlertDescription>
|
||||
</Alert>
|
||||
)
|
||||
|
||||
Destructive.storyName = 'Destructive'
|
||||
|
||||
export const Warning = () => (
|
||||
<Alert variant="warning">
|
||||
<Alert variant="warning">
|
||||
<AlertCircle className="h-4 w-4" />
|
||||
<AlertTitle>Error</AlertTitle>
|
||||
<AlertDescription>
|
||||
Your session has expired. Please log in again.
|
||||
</AlertDescription>
|
||||
<AlertDescription>Your session has expired. Please log in again.</AlertDescription>
|
||||
</Alert>
|
||||
)
|
||||
|
||||
|
||||
@@ -31,8 +31,8 @@ import {
|
||||
DropdownMenuSubTrigger,
|
||||
DropdownMenuTrigger,
|
||||
} from '@ui/components/shadcn/ui/dropdown-menu'
|
||||
import { Popover, PopoverContent, PopoverTrigger } from '@ui/components/shadcn/popover'
|
||||
import { toast } from '@ui/components/shadcn/use-toast'
|
||||
import { Popover, PopoverContent, PopoverTrigger } from '@ui/components/shadcn/ui/popover'
|
||||
import { toast } from '@ui/components/shadcn/ui/use-toast'
|
||||
import { cn } from '@ui/lib/utils'
|
||||
import {
|
||||
ArrowUpCircle,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React from 'react'
|
||||
import type { Meta, StoryObj } from '@storybook/react'
|
||||
import { Button } from '@ui/components/shadcn/button'
|
||||
import { Button } from '@ui/components/shadcn/ui/button'
|
||||
import {
|
||||
DropdownMenu,
|
||||
DropdownMenuCheckboxItem,
|
||||
@@ -12,7 +12,7 @@ import {
|
||||
DropdownMenuRadioGroup,
|
||||
DropdownMenuRadioItem,
|
||||
DropdownMenuSeparator,
|
||||
DropdownMenuRightSlot,
|
||||
DropdownMenuShortcut,
|
||||
DropdownMenuSub,
|
||||
DropdownMenuSubContent,
|
||||
DropdownMenuSubTrigger,
|
||||
@@ -135,19 +135,19 @@ export const Default: Story = {
|
||||
<DropdownMenuGroup>
|
||||
<DropdownMenuItem>
|
||||
<span>Profile</span>
|
||||
<DropdownMenuRightSlot>⇧⌘P</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⇧⌘P</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Billing</span>
|
||||
<DropdownMenuRightSlot>⌘B</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘B</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Settings</span>
|
||||
<DropdownMenuRightSlot>⌘S</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘S</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Keyboard shortcuts</span>
|
||||
<DropdownMenuRightSlot>⌘K</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘K</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
</DropdownMenuGroup>
|
||||
<DropdownMenuSeparator />
|
||||
@@ -182,7 +182,7 @@ export const Default: Story = {
|
||||
<DropdownMenuItem>
|
||||
<Plus className="mr-2 h-4 w-4 text-foreground-light" />
|
||||
<span>New Team</span>
|
||||
<DropdownMenuRightSlot>⌘+T</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘+T</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
</DropdownMenuGroup>
|
||||
<DropdownMenuSeparator />
|
||||
@@ -202,7 +202,7 @@ export const Default: Story = {
|
||||
<DropdownMenuItem>
|
||||
<LogOut className="mr-2 h-4 w-4 text-foreground-light" />
|
||||
<span>Log out</span>
|
||||
<DropdownMenuRightSlot>⇧⌘Q</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⇧⌘Q</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
</DropdownMenuContent>
|
||||
</DropdownMenu>
|
||||
@@ -223,19 +223,19 @@ export const AlignStart: Story = {
|
||||
<DropdownMenuGroup>
|
||||
<DropdownMenuItem>
|
||||
<span>Profile</span>
|
||||
<DropdownMenuRightSlot>⇧⌘P</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⇧⌘P</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Billing</span>
|
||||
<DropdownMenuRightSlot>⌘B</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘B</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Settings</span>
|
||||
<DropdownMenuRightSlot>⌘S</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘S</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Keyboard shortcuts</span>
|
||||
<DropdownMenuRightSlot>⌘K</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘K</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
</DropdownMenuGroup>
|
||||
</DropdownMenuContent>
|
||||
@@ -257,19 +257,19 @@ export const AlignEnd: Story = {
|
||||
<DropdownMenuGroup>
|
||||
<DropdownMenuItem>
|
||||
<span>Profile</span>
|
||||
<DropdownMenuRightSlot>⇧⌘P</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⇧⌘P</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Billing</span>
|
||||
<DropdownMenuRightSlot>⌘B</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘B</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Settings</span>
|
||||
<DropdownMenuRightSlot>⌘S</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘S</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem>
|
||||
<span>Keyboard shortcuts</span>
|
||||
<DropdownMenuRightSlot>⌘K</DropdownMenuRightSlot>
|
||||
<DropdownMenuShortcut>⌘K</DropdownMenuShortcut>
|
||||
</DropdownMenuItem>
|
||||
</DropdownMenuGroup>
|
||||
</DropdownMenuContent>
|
||||
|
||||
@@ -9,10 +9,16 @@ import { format } from 'date-fns'
|
||||
import { CalendarIcon } from 'lucide-react'
|
||||
import { useForm } from 'react-hook-form'
|
||||
import * as z from 'zod'
|
||||
import { Calendar } from '../calendar'
|
||||
import { Popover, PopoverContent, PopoverTrigger } from '../popover'
|
||||
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '../select'
|
||||
import { toast } from '../use-toast'
|
||||
import { Calendar } from '@ui/components/shadcn/ui/calendar'
|
||||
import { Popover, PopoverContent, PopoverTrigger } from '@ui/components/shadcn/ui//popover'
|
||||
import {
|
||||
Select,
|
||||
SelectContent,
|
||||
SelectItem,
|
||||
SelectTrigger,
|
||||
SelectValue,
|
||||
} from '@ui/components/shadcn/ui//select'
|
||||
import { toast } from '@ui/components/shadcn/ui/use-toast'
|
||||
import {
|
||||
Form,
|
||||
FormControl,
|
||||
|
||||
@@ -24,7 +24,7 @@ import { toast } from '@ui/components/shadcn/ui/use-toast'
|
||||
// import Link from 'next/link'
|
||||
import { useForm } from 'react-hook-form'
|
||||
import * as z from 'zod'
|
||||
import { SelectSeparator } from '../select'
|
||||
import { SelectSeparator } from '@ui/components/shadcn/ui/select'
|
||||
|
||||
const meta: Meta = {
|
||||
title: 'shadcn/Select',
|
||||
|
||||
@@ -12,6 +12,7 @@ const dropdownMenuVariants = cva('', {
|
||||
variants: {
|
||||
content: {
|
||||
true: `
|
||||
min-w-[8rem]
|
||||
overflow-hidden
|
||||
z-40
|
||||
bg-overlay
|
||||
@@ -114,7 +115,7 @@ const dropdownMenuVariants = cva('', {
|
||||
flex items-center space-x-0 pl-8 pr-4
|
||||
`,
|
||||
},
|
||||
right_slot: {
|
||||
shortcut: {
|
||||
true: `
|
||||
text-lighter
|
||||
group-focus:text-light
|
||||
@@ -276,15 +277,15 @@ const DropdownMenuSeparator = React.forwardRef<
|
||||
))
|
||||
DropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName
|
||||
|
||||
const DropdownMenuRightSlot = ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => (
|
||||
const DropdownMenuShortcut = ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => (
|
||||
<span
|
||||
data-component="right_slot"
|
||||
className={cn(dropdownMenuVariants({ right_slot: true }), className)}
|
||||
data-component="shortcut"
|
||||
className={cn(dropdownMenuVariants({ shortcut: true }), className)}
|
||||
{...props}
|
||||
/>
|
||||
)
|
||||
|
||||
DropdownMenuRightSlot.displayName = 'DropdownMenuRightSlot'
|
||||
DropdownMenuShortcut.displayName = 'DropdownMenuShortcut'
|
||||
|
||||
export {
|
||||
DropdownMenu,
|
||||
@@ -295,7 +296,7 @@ export {
|
||||
DropdownMenuRadioItem,
|
||||
DropdownMenuLabel,
|
||||
DropdownMenuSeparator,
|
||||
DropdownMenuRightSlot,
|
||||
DropdownMenuShortcut,
|
||||
DropdownMenuGroup,
|
||||
DropdownMenuPortal,
|
||||
DropdownMenuSub,
|
||||
|
||||
Reference in new issue
Block a user