diff --git a/apps/desktop/src/session/components/outer-header/folder/index.tsx b/apps/desktop/src/session/components/outer-header/folder/index.tsx
index 3044e91b17..ff40f0638d 100644
--- a/apps/desktop/src/session/components/outer-header/folder/index.tsx
+++ b/apps/desktop/src/session/components/outer-header/folder/index.tsx
@@ -5,17 +5,18 @@ import {
BreadcrumbItem,
BreadcrumbLink,
BreadcrumbList,
- BreadcrumbPage,
BreadcrumbSeparator,
} from "@hypr/ui/components/ui/breadcrumb";
import { Button } from "@hypr/ui/components/ui/button";
-
-import { SearchableFolderDropdown } from "./searchable-dropdown";
+import {
+ Tooltip,
+ TooltipContent,
+ TooltipTrigger,
+} from "@hypr/ui/components/ui/tooltip";
import { useBillingAccess } from "~/auth/billing";
import { FolderBreadcrumb } from "~/shared/ui/folder-breadcrumb";
import * as main from "~/store/tinybase/store/main";
-import { useSessionTitle } from "~/store/zustand/live-title";
import { useTabs } from "~/store/zustand/tabs";
export function FolderChain({ sessionId }: { sessionId: string }) {
@@ -26,78 +27,57 @@ export function FolderChain({ sessionId }: { sessionId: string }) {
"folder_id",
main.STORE_ID,
);
- const storeTitle = main.UI.useCell(
- "sessions",
- sessionId,
- "title",
- main.STORE_ID,
- ) as string | undefined;
- const title = useSessionTitle(sessionId, storeTitle);
- const handleChangeTitle = main.UI.useSetPartialRowCallback(
- "sessions",
- sessionId,
- (title: string) => ({ title }),
- [],
- main.STORE_ID,
- );
-
- if (!isPro) {
- return (
-
-
-
-
-
-
-
-
-
- );
+ if (!folderId) {
+ return ;
}
return (
-
- {folderId && }
- {!folderId ? (
-
- ) : (
-
- )}
+
+
+
);
}
-function RenderIfRootExist({
+function UnassignedFolderBreadcrumb() {
+ return (
+
+
+
+
+
+
+ Unassigned
+
+
+ Coming soon
+
+
+
+ );
+}
+
+function RenderFolderBreadcrumb({
folderId,
- title,
- handleChangeTitle,
+ isPro,
}: {
folderId: string;
- title: string;
- handleChangeTitle: (title: string) => void;
+ isPro: boolean;
}) {
const openNew = useTabs((state) => state.openNew);
return (
- <>
-
- index > 0 ? : null
- }
- renderCrumb={({ id, name }) => (
-
+
+ index > 0 ? : null
+ }
+ renderCrumb={({ id, name }) => (
+
+ {isPro ? (
-
- )}
- />
-
-
-
-
-
-
- >
- );
-}
-
-function RenderIfRootNotExist({
- title,
- handleChangeTitle,
- sessionId,
-}: {
- title: string;
- handleChangeTitle: (title: string) => void;
- sessionId: string;
-}) {
- return (
- <>
-
-
- Select folder
-
- }
- />
-
-
-
-
-
-
-
- >
- );
-}
-
-function TitleInput({
- title,
- handleChangeTitle,
-}: {
- title: string;
- handleChangeTitle: (title: string) => void;
-}) {
- return (
- handleChangeTitle(e.target.value)}
+ ) : (
+ {name}
+ )}
+
+ )}
/>
);
}