Added help buttons and icons to image menu
This commit is contained in:
parent
6c3956987d
commit
84c1320c82
2 changed files with 47 additions and 17 deletions
|
|
@ -18,7 +18,7 @@ import useFlowStore from "../../stores/flowStore";
|
||||||
import useFlowsManagerStore from "../../stores/flowsManagerStore";
|
import useFlowsManagerStore from "../../stores/flowsManagerStore";
|
||||||
import { useLocationStore } from "../../stores/locationStore";
|
import { useLocationStore } from "../../stores/locationStore";
|
||||||
import { useStoreStore } from "../../stores/storeStore";
|
import { useStoreStore } from "../../stores/storeStore";
|
||||||
import IconComponent from "../genericIconComponent";
|
import IconComponent, { ForwardedIconComponent } from "../genericIconComponent";
|
||||||
import { Button } from "../ui/button";
|
import { Button } from "../ui/button";
|
||||||
import {
|
import {
|
||||||
DropdownMenu,
|
DropdownMenu,
|
||||||
|
|
@ -214,7 +214,7 @@ export default function Header(): JSX.Element {
|
||||||
/>
|
/>
|
||||||
</Button>
|
</Button>
|
||||||
</DropdownMenuTrigger>
|
</DropdownMenuTrigger>
|
||||||
<DropdownMenuContent>
|
<DropdownMenuContent className="mr-1 mt-1 min-w-40">
|
||||||
{!autoLogin && (
|
{!autoLogin && (
|
||||||
<>
|
<>
|
||||||
<DropdownMenuLabel>
|
<DropdownMenuLabel>
|
||||||
|
|
@ -239,33 +239,61 @@ export default function Header(): JSX.Element {
|
||||||
)}
|
)}
|
||||||
<DropdownMenuLabel>General</DropdownMenuLabel>
|
<DropdownMenuLabel>General</DropdownMenuLabel>
|
||||||
<DropdownMenuItem
|
<DropdownMenuItem
|
||||||
className="cursor-pointer"
|
className="cursor-pointer gap-2"
|
||||||
onClick={() => navigate("/settings")}
|
onClick={() => navigate("/settings")}
|
||||||
>
|
>
|
||||||
|
<ForwardedIconComponent name="Settings" className="w-4" />
|
||||||
Settings
|
Settings
|
||||||
</DropdownMenuItem>
|
</DropdownMenuItem>
|
||||||
{!autoLogin && (
|
{!autoLogin && (
|
||||||
<>
|
<>
|
||||||
<DropdownMenuSeparator />
|
|
||||||
<DropdownMenuLabel>My Account</DropdownMenuLabel>
|
|
||||||
{isAdmin && (
|
{isAdmin && (
|
||||||
<DropdownMenuItem
|
<DropdownMenuItem
|
||||||
className="cursor-pointer"
|
className="cursor-pointer gap-2"
|
||||||
onClick={() => navigate("/admin")}
|
onClick={() => navigate("/admin")}
|
||||||
>
|
>
|
||||||
|
<ForwardedIconComponent name="Shield" className="w-4" />
|
||||||
Admin Page
|
Admin Page
|
||||||
</DropdownMenuItem>
|
</DropdownMenuItem>
|
||||||
)}
|
)}
|
||||||
<DropdownMenuItem
|
|
||||||
className="cursor-pointer"
|
|
||||||
onClick={() => {
|
|
||||||
logout();
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Sign Out
|
|
||||||
</DropdownMenuItem>
|
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
|
<DropdownMenuSeparator />
|
||||||
|
<DropdownMenuLabel>Help</DropdownMenuLabel>
|
||||||
|
<DropdownMenuItem
|
||||||
|
className="cursor-pointer gap-2"
|
||||||
|
onClick={() =>
|
||||||
|
window.open("https://pre-release.langflow.org/", "_blank")
|
||||||
|
}
|
||||||
|
>
|
||||||
|
<ForwardedIconComponent name="FileText" className="w-4" />
|
||||||
|
Docs
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DropdownMenuItem
|
||||||
|
className="cursor-pointer gap-2"
|
||||||
|
onClick={() =>
|
||||||
|
window.open(
|
||||||
|
"https://github.com/langflow-ai/langflow/discussions",
|
||||||
|
"_blank",
|
||||||
|
)
|
||||||
|
}
|
||||||
|
>
|
||||||
|
<ForwardedIconComponent
|
||||||
|
name="MessagesSquare"
|
||||||
|
className="w-4"
|
||||||
|
/>
|
||||||
|
Discussions
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DropdownMenuSeparator />
|
||||||
|
<DropdownMenuItem
|
||||||
|
className="cursor-pointer gap-2"
|
||||||
|
onClick={() => {
|
||||||
|
logout();
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<ForwardedIconComponent name="LogOut" className="w-4" />
|
||||||
|
Log Out
|
||||||
|
</DropdownMenuItem>
|
||||||
</DropdownMenuContent>
|
</DropdownMenuContent>
|
||||||
</DropdownMenu>
|
</DropdownMenu>
|
||||||
</>
|
</>
|
||||||
|
|
|
||||||
|
|
@ -81,6 +81,7 @@ import {
|
||||||
Loader2,
|
Loader2,
|
||||||
Lock,
|
Lock,
|
||||||
LogIn,
|
LogIn,
|
||||||
|
LogOut,
|
||||||
LucideSend,
|
LucideSend,
|
||||||
Maximize2,
|
Maximize2,
|
||||||
Menu,
|
Menu,
|
||||||
|
|
@ -197,16 +198,16 @@ import { ShareIcon } from "../icons/Share";
|
||||||
import { Share2Icon } from "../icons/Share2";
|
import { Share2Icon } from "../icons/Share2";
|
||||||
import SvgSlackIcon from "../icons/Slack/SlackIcon";
|
import SvgSlackIcon from "../icons/Slack/SlackIcon";
|
||||||
import { Streamlit } from "../icons/Streamlit";
|
import { Streamlit } from "../icons/Streamlit";
|
||||||
|
import { UpstashSvgIcon } from "../icons/Upstash";
|
||||||
import { VectaraIcon } from "../icons/VectaraIcon";
|
import { VectaraIcon } from "../icons/VectaraIcon";
|
||||||
import { VertexAIIcon } from "../icons/VertexAI";
|
import { VertexAIIcon } from "../icons/VertexAI";
|
||||||
import { WeaviateIcon } from "../icons/Weaviate";
|
import { WeaviateIcon } from "../icons/Weaviate";
|
||||||
import SvgWikipedia from "../icons/Wikipedia/Wikipedia";
|
import SvgWikipedia from "../icons/Wikipedia/Wikipedia";
|
||||||
import SvgWolfram from "../icons/Wolfram/Wolfram";
|
import SvgWolfram from "../icons/Wolfram/Wolfram";
|
||||||
import { HackerNewsIcon } from "../icons/hackerNews";
|
import { HackerNewsIcon } from "../icons/hackerNews";
|
||||||
|
import { MistralIcon } from "../icons/mistral";
|
||||||
import { SupabaseIcon } from "../icons/supabase";
|
import { SupabaseIcon } from "../icons/supabase";
|
||||||
import { iconsType } from "../types/components";
|
import { iconsType } from "../types/components";
|
||||||
import { MistralIcon } from "../icons/mistral";
|
|
||||||
import { UpstashSvgIcon } from "../icons/Upstash";
|
|
||||||
|
|
||||||
export const gradients = [
|
export const gradients = [
|
||||||
"bg-gradient-to-br from-gray-800 via-rose-700 to-violet-900",
|
"bg-gradient-to-br from-gray-800 via-rose-700 to-violet-900",
|
||||||
|
|
@ -511,6 +512,7 @@ export const nodeIconsLucide: iconsType = {
|
||||||
Ungroup,
|
Ungroup,
|
||||||
BookMarked,
|
BookMarked,
|
||||||
Minus,
|
Minus,
|
||||||
|
LogOut,
|
||||||
Square,
|
Square,
|
||||||
Minimize2,
|
Minimize2,
|
||||||
Maximize2,
|
Maximize2,
|
||||||
|
|
@ -555,7 +557,7 @@ export const nodeIconsLucide: iconsType = {
|
||||||
PaperclipIcon,
|
PaperclipIcon,
|
||||||
Settings,
|
Settings,
|
||||||
Streamlit,
|
Streamlit,
|
||||||
MistralAI:MistralIcon,
|
MistralAI: MistralIcon,
|
||||||
Upstash: UpstashSvgIcon,
|
Upstash: UpstashSvgIcon,
|
||||||
PGVector: CpuIcon,
|
PGVector: CpuIcon,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue