mirror of
https://github.com/StanGirard/quivr.git
synced 2024-08-17 09:00:33 +03:00
feat: update import links
This commit is contained in:
parent
2651c1bd0b
commit
8233f88ec4
@ -6,11 +6,11 @@ import { cn } from "@/lib/utils";
|
||||
|
||||
import { useBrainListItem } from "./hooks/useBrainListItem";
|
||||
|
||||
interface ChatsListItemProps {
|
||||
interface BrainsListItemProps {
|
||||
brain: MinimalBrainForUser;
|
||||
}
|
||||
|
||||
export const BrainListItem = ({ brain }: ChatsListItemProps): JSX.Element => {
|
||||
export const BrainListItem = ({ brain }: BrainsListItemProps): JSX.Element => {
|
||||
const { selected } = useBrainListItem(brain);
|
||||
|
||||
return (
|
||||
@ -21,7 +21,8 @@ export const BrainListItem = ({ brain }: ChatsListItemProps): JSX.Element => {
|
||||
? "bg-gray-100 dark:bg-gray-800 text-primary dark:text-white"
|
||||
: ""
|
||||
)}
|
||||
data-testid="chats-list-item"
|
||||
data-testid="brains
|
||||
-list-item"
|
||||
>
|
||||
<Link
|
||||
className="flex flex-col flex-1 min-w-0 p-4"
|
||||
|
@ -0,0 +1 @@
|
||||
export * from './BrainListItem'
|
@ -0,0 +1 @@
|
||||
export * from './BrainSearchBar';
|
@ -5,8 +5,8 @@ import { MdChevronRight } from "react-icons/md";
|
||||
import { AddBrainModal } from "@/lib/components/AddBrainModal";
|
||||
import { cn } from "@/lib/utils";
|
||||
|
||||
import { BrainListItem } from "./BrainListItem/BrainListItem";
|
||||
import { BrainSearchBar } from "./BrainSearchBar/BrainSearchBar";
|
||||
import { BrainListItem } from "./BrainListItem";
|
||||
import { BrainSearchBar } from "./BrainSearchBar";
|
||||
import { useBrainsList } from "../hooks/useBrainsList";
|
||||
|
||||
export const BrainsList = (): JSX.Element => {
|
||||
@ -37,7 +37,7 @@ export const BrainsList = (): JSX.Element => {
|
||||
: "10px 10px 16px rgba(0, 0, 0, 0.5)",
|
||||
}}
|
||||
className={cn("overflow-hidden flex flex-col flex-1")}
|
||||
data-testid="chats-list"
|
||||
data-testid="brains-list"
|
||||
>
|
||||
<div className="flex flex-col flex-1">
|
||||
<BrainSearchBar
|
||||
@ -45,7 +45,7 @@ export const BrainsList = (): JSX.Element => {
|
||||
setSearchQuery={setSearchQuery}
|
||||
/>
|
||||
<div
|
||||
data-testid="chats-list-items"
|
||||
data-testid="brains-list-items"
|
||||
className="flex-1 overflow-auto scrollbar h-full"
|
||||
>
|
||||
{brains.map((brain) => (
|
||||
@ -62,7 +62,7 @@ export const BrainsList = (): JSX.Element => {
|
||||
setOpen(!open);
|
||||
}}
|
||||
className="absolute left-full top-16 text-3xl bg-black dark:bg-white text-white dark:text-black rounded-r-full p-3 pl-1"
|
||||
data-testid="chats-list-toggle"
|
||||
data-testid="brains-list-toggle"
|
||||
>
|
||||
<motion.div
|
||||
whileTap={{ scale: 0.9 }}
|
||||
|
@ -0,0 +1,3 @@
|
||||
export * from "./BrainListItem";
|
||||
export * from "./BrainSearchBar";
|
||||
export * from "./BrainsList";
|
@ -2,7 +2,7 @@
|
||||
|
||||
const BrainsManagement = (): JSX.Element => {
|
||||
return (
|
||||
<main className="flex flex-col w-full pt-10" data-testid="chat-page">
|
||||
<main className="flex flex-col w-full pt-10" data-testid="brain-page">
|
||||
<p>Coming soon</p>
|
||||
</main>
|
||||
);
|
||||
|
@ -4,7 +4,7 @@ import { ReactNode } from "react";
|
||||
import { useSupabase } from "@/lib/context/SupabaseProvider";
|
||||
import { redirectToLogin } from "@/lib/router/redirectToLogin";
|
||||
|
||||
import { BrainsList } from "./[brainId]/components/BrainsList";
|
||||
import { BrainsList } from "./[brainId]/components";
|
||||
|
||||
interface LayoutProps {
|
||||
children?: ReactNode;
|
||||
|
@ -1,2 +1,2 @@
|
||||
export * from "../../../../../../AddBrainModal";
|
||||
export * from "@/lib/components/AddBrainModal";
|
||||
export * from "./BrainActions";
|
||||
|
Loading…
Reference in New Issue
Block a user