Spaces:
Sleeping
Sleeping
Commit
Β·
64defdf
1
Parent(s):
8069551
import
Browse files- app/(logout)/unauthorized/page.tsx +1 -1
- components/LoginButton.tsx +2 -2
- components/ThemeToggle.tsx +2 -2
- components/UserMenu.tsx +2 -2
- components/chat/ButtonScrollToBottom.tsx +2 -2
- components/chat/ChatMessage.tsx +1 -1
- components/chat/ChatMessageActions.tsx +2 -2
- components/chat/ChatPanel.tsx +2 -2
- components/chat/PromptForm.tsx +2 -2
- components/header.tsx +2 -2
- components/ui/{button.tsx β Buttons.tsx} +0 -0
- components/ui/{icons.tsx β Icon.tsx} +0 -0
- components/ui/codeblock.tsx +2 -2
app/(logout)/unauthorized/page.tsx
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
import { auth } from '@/auth';
|
2 |
import { redirect } from 'next/navigation';
|
3 |
-
import { Button } from '@/components/ui/
|
4 |
import Link from 'next/link';
|
5 |
|
6 |
export default async function Unauthorized() {
|
|
|
1 |
import { auth } from '@/auth';
|
2 |
import { redirect } from 'next/navigation';
|
3 |
+
import { Button } from '@/components/ui/Buttons';
|
4 |
import Link from 'next/link';
|
5 |
|
6 |
export default async function Unauthorized() {
|
components/LoginButton.tsx
CHANGED
@@ -4,8 +4,8 @@ import * as React from 'react';
|
|
4 |
import { signIn } from 'next-auth/react';
|
5 |
|
6 |
import { cn } from '@/lib/utils';
|
7 |
-
import { Button, type ButtonProps } from '@/components/ui/
|
8 |
-
import { IconGitHub, IconSpinner, IconGoogle } from '@/components/ui/
|
9 |
|
10 |
interface LoginButtonProps extends ButtonProps {
|
11 |
oauth: 'github' | 'google';
|
|
|
4 |
import { signIn } from 'next-auth/react';
|
5 |
|
6 |
import { cn } from '@/lib/utils';
|
7 |
+
import { Button, type ButtonProps } from '@/components/ui/Buttons';
|
8 |
+
import { IconGitHub, IconSpinner, IconGoogle } from '@/components/ui/Icon';
|
9 |
|
10 |
interface LoginButtonProps extends ButtonProps {
|
11 |
oauth: 'github' | 'google';
|
components/ThemeToggle.tsx
CHANGED
@@ -3,8 +3,8 @@
|
|
3 |
import * as React from 'react';
|
4 |
import { useTheme } from 'next-themes';
|
5 |
|
6 |
-
import { Button } from '@/components/ui/
|
7 |
-
import { IconMoon, IconSun } from '@/components/ui/
|
8 |
|
9 |
export function ThemeToggle() {
|
10 |
const { setTheme, theme } = useTheme();
|
|
|
3 |
import * as React from 'react';
|
4 |
import { useTheme } from 'next-themes';
|
5 |
|
6 |
+
import { Button } from '@/components/ui/Buttons';
|
7 |
+
import { IconMoon, IconSun } from '@/components/ui/Icon';
|
8 |
|
9 |
export function ThemeToggle() {
|
10 |
const { setTheme, theme } = useTheme();
|
components/UserMenu.tsx
CHANGED
@@ -4,7 +4,7 @@ import Image from 'next/image';
|
|
4 |
import { type Session } from 'next-auth';
|
5 |
import { signOut } from 'next-auth/react';
|
6 |
|
7 |
-
import { Button } from '@/components/ui/
|
8 |
import {
|
9 |
DropdownMenu,
|
10 |
DropdownMenuContent,
|
@@ -12,7 +12,7 @@ import {
|
|
12 |
DropdownMenuSeparator,
|
13 |
DropdownMenuTrigger,
|
14 |
} from '@/components/ui/DropdownMenu';
|
15 |
-
import { IconExternalLink } from '@/components/ui/
|
16 |
|
17 |
export interface UserMenuProps {
|
18 |
user: Session['user'];
|
|
|
4 |
import { type Session } from 'next-auth';
|
5 |
import { signOut } from 'next-auth/react';
|
6 |
|
7 |
+
import { Button } from '@/components/ui/Buttons';
|
8 |
import {
|
9 |
DropdownMenu,
|
10 |
DropdownMenuContent,
|
|
|
12 |
DropdownMenuSeparator,
|
13 |
DropdownMenuTrigger,
|
14 |
} from '@/components/ui/DropdownMenu';
|
15 |
+
import { IconExternalLink } from '@/components/ui/Icon';
|
16 |
|
17 |
export interface UserMenuProps {
|
18 |
user: Session['user'];
|
components/chat/ButtonScrollToBottom.tsx
CHANGED
@@ -4,8 +4,8 @@ import * as React from 'react';
|
|
4 |
|
5 |
import { cn } from '@/lib/utils';
|
6 |
import { useAtBottom } from '@/lib/hooks/useAtBottom';
|
7 |
-
import { Button, type ButtonProps } from '@/components/ui/
|
8 |
-
import { IconArrowDown } from '@/components/ui/
|
9 |
|
10 |
export function ButtonScrollToBottom({ className, ...props }: ButtonProps) {
|
11 |
const isAtBottom = useAtBottom();
|
|
|
4 |
|
5 |
import { cn } from '@/lib/utils';
|
6 |
import { useAtBottom } from '@/lib/hooks/useAtBottom';
|
7 |
+
import { Button, type ButtonProps } from '@/components/ui/Buttons';
|
8 |
+
import { IconArrowDown } from '@/components/ui/Icon';
|
9 |
|
10 |
export function ButtonScrollToBottom({ className, ...props }: ButtonProps) {
|
11 |
const isAtBottom = useAtBottom();
|
components/chat/ChatMessage.tsx
CHANGED
@@ -7,7 +7,7 @@ import remarkMath from 'remark-math';
|
|
7 |
import { cn } from '@/lib/utils';
|
8 |
import { CodeBlock } from '@/components/ui/CodeBlock';
|
9 |
import { MemoizedReactMarkdown } from '@/components/chat/MemoizedReactMarkdown';
|
10 |
-
import { IconOpenAI, IconUser } from '@/components/ui/
|
11 |
import { ChatMessageActions } from '@/components/chat/ChatMessageActions';
|
12 |
import { MessageWithSelectedDataset } from '../../lib/types';
|
13 |
|
|
|
7 |
import { cn } from '@/lib/utils';
|
8 |
import { CodeBlock } from '@/components/ui/CodeBlock';
|
9 |
import { MemoizedReactMarkdown } from '@/components/chat/MemoizedReactMarkdown';
|
10 |
+
import { IconOpenAI, IconUser } from '@/components/ui/Icon';
|
11 |
import { ChatMessageActions } from '@/components/chat/ChatMessageActions';
|
12 |
import { MessageWithSelectedDataset } from '../../lib/types';
|
13 |
|
components/chat/ChatMessageActions.tsx
CHANGED
@@ -2,8 +2,8 @@
|
|
2 |
|
3 |
import { type Message } from 'ai';
|
4 |
|
5 |
-
import { Button } from '@/components/ui/
|
6 |
-
import { IconCheck, IconCopy } from '@/components/ui/
|
7 |
import { useCopyToClipboard } from '@/lib/hooks/useCopyToClipboard';
|
8 |
import { cn } from '@/lib/utils';
|
9 |
import { MessageWithSelectedDataset } from '../../lib/types';
|
|
|
2 |
|
3 |
import { type Message } from 'ai';
|
4 |
|
5 |
+
import { Button } from '@/components/ui/Buttons';
|
6 |
+
import { IconCheck, IconCopy } from '@/components/ui/Icon';
|
7 |
import { useCopyToClipboard } from '@/lib/hooks/useCopyToClipboard';
|
8 |
import { cn } from '@/lib/utils';
|
9 |
import { MessageWithSelectedDataset } from '../../lib/types';
|
components/chat/ChatPanel.tsx
CHANGED
@@ -1,10 +1,10 @@
|
|
1 |
import * as React from 'react';
|
2 |
import { type UseChatHelpers } from 'ai/react';
|
3 |
|
4 |
-
import { Button } from '@/components/ui/
|
5 |
import { PromptForm } from '@/components/chat/PromptForm';
|
6 |
import { ButtonScrollToBottom } from '@/components/chat/ButtonScrollToBottom';
|
7 |
-
import { IconRefresh, IconShare, IconStop } from '@/components/ui/
|
8 |
import { MessageWithSelectedDataset } from '../../lib/types';
|
9 |
|
10 |
export interface ChatPanelProps
|
|
|
1 |
import * as React from 'react';
|
2 |
import { type UseChatHelpers } from 'ai/react';
|
3 |
|
4 |
+
import { Button } from '@/components/ui/Buttons';
|
5 |
import { PromptForm } from '@/components/chat/PromptForm';
|
6 |
import { ButtonScrollToBottom } from '@/components/chat/ButtonScrollToBottom';
|
7 |
+
import { IconRefresh, IconShare, IconStop } from '@/components/ui/Icon';
|
8 |
import { MessageWithSelectedDataset } from '../../lib/types';
|
9 |
|
10 |
export interface ChatPanelProps
|
components/chat/PromptForm.tsx
CHANGED
@@ -3,13 +3,13 @@ import Textarea from 'react-textarea-autosize';
|
|
3 |
import { UseChatHelpers } from 'ai/react';
|
4 |
import { useEnterSubmit } from '@/lib/hooks/useEnterSubmit';
|
5 |
import { cn } from '@/lib/utils';
|
6 |
-
import { Button, buttonVariants } from '@/components/ui/
|
7 |
import {
|
8 |
Tooltip,
|
9 |
TooltipContent,
|
10 |
TooltipTrigger,
|
11 |
} from '@/components/ui/Tooltip';
|
12 |
-
import { IconArrowElbow, IconPlus } from '@/components/ui/
|
13 |
import { useRouter } from 'next/navigation';
|
14 |
|
15 |
export interface PromptProps
|
|
|
3 |
import { UseChatHelpers } from 'ai/react';
|
4 |
import { useEnterSubmit } from '@/lib/hooks/useEnterSubmit';
|
5 |
import { cn } from '@/lib/utils';
|
6 |
+
import { Button, buttonVariants } from '@/components/ui/Buttons';
|
7 |
import {
|
8 |
Tooltip,
|
9 |
TooltipContent,
|
10 |
TooltipTrigger,
|
11 |
} from '@/components/ui/Tooltip';
|
12 |
+
import { IconArrowElbow, IconPlus } from '@/components/ui/Icon';
|
13 |
import { useRouter } from 'next/navigation';
|
14 |
|
15 |
export interface PromptProps
|
components/header.tsx
CHANGED
@@ -2,9 +2,9 @@ import * as React from 'react';
|
|
2 |
import Link from 'next/link';
|
3 |
|
4 |
import { auth } from '@/auth';
|
5 |
-
import { Button } from '@/components/ui/
|
6 |
import { UserMenu } from '@/components/UserMenu';
|
7 |
-
import { IconSeparator } from './ui/
|
8 |
|
9 |
export async function Header() {
|
10 |
const session = await auth();
|
|
|
2 |
import Link from 'next/link';
|
3 |
|
4 |
import { auth } from '@/auth';
|
5 |
+
import { Button } from '@/components/ui/Buttons';
|
6 |
import { UserMenu } from '@/components/UserMenu';
|
7 |
+
import { IconSeparator } from './ui/Icon';
|
8 |
|
9 |
export async function Header() {
|
10 |
const session = await auth();
|
components/ui/{button.tsx β Buttons.tsx}
RENAMED
File without changes
|
components/ui/{icons.tsx β Icon.tsx}
RENAMED
File without changes
|
components/ui/codeblock.tsx
CHANGED
@@ -8,8 +8,8 @@ import { Prism as SyntaxHighlighter } from 'react-syntax-highlighter';
|
|
8 |
import { coldarkDark } from 'react-syntax-highlighter/dist/cjs/styles/prism';
|
9 |
|
10 |
import { useCopyToClipboard } from '@/lib/hooks/useCopyToClipboard';
|
11 |
-
import { IconCheck, IconCopy, IconDownload } from '@/components/ui/
|
12 |
-
import { Button } from '@/components/ui/
|
13 |
|
14 |
interface Props {
|
15 |
language: string;
|
|
|
8 |
import { coldarkDark } from 'react-syntax-highlighter/dist/cjs/styles/prism';
|
9 |
|
10 |
import { useCopyToClipboard } from '@/lib/hooks/useCopyToClipboard';
|
11 |
+
import { IconCheck, IconCopy, IconDownload } from '@/components/ui/Icon';
|
12 |
+
import { Button } from '@/components/ui/Buttons';
|
13 |
|
14 |
interface Props {
|
15 |
language: string;
|