|
|
|
|
@@ -1150,130 +1150,130 @@ $$anchor2,spread_props({"data-slot":"tooltip-trigger",class:"cursor-pointer"},()
|
|
|
|
|
$$anchor3,spread_props({"data-slot":"tooltip-content",get sideOffset(){return sideOffset()},get side(){return side()},get class(){return get$3(contentClass)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor4,$$slotProps)=>{var fragment_1=root_2$1e(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);{const child2=($$anchor5,$$arg0)=>{let props=()=>$$arg0?.().props;var div=root_3$Z();attribute_effect(
|
|
|
|
|
div,$0=>({class:$0,...props()}),[()=>cn$1("z-50 size-2.5 rotate-45 rounded-[2px] bg-primary","data-[side=top]:translate-x-1/2 data-[side=top]:translate-y-[calc(-50%_+_2px)]","data-[side=bottom]:-translate-x-1/2 data-[side=bottom]:-translate-y-[calc(-50%_+_1px)]","data-[side=right]:translate-x-[calc(50%_+_2px)] data-[side=right]:translate-y-1/2","data-[side=left]:-translate-y-[calc(50%_-_3px)]",$$props.arrowClasses)]),append($$anchor5,div)};component(node_2,()=>Tooltip_arrow,($$anchor5,TooltipPrimitive_Arrow)=>{
|
|
|
|
|
TooltipPrimitive_Arrow($$anchor5,{child:child2,$$slots:{child:!0}})})}append($$anchor4,fragment_1)},$$slots:{default:!0}}))}),append($$anchor2,fragment)};let ref2=prop($$props,"ref",15,null),sideOffset=prop($$props,"sideOffset",3,0),side=prop($$props,"side",3,"top"),noPortal=prop($$props,"noPortal",3,!1),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","sideOffset","side","children","arrowClasses","noPortal"]);const contentClass=user_derived(()=>cn$1("z-50 w-fit origin\
|
|
|
|
|
-(--bits-tooltip-content-transform-origin) animate-in rounded-md bg-primary px-3 py-1.5 text-xs text-balance text-primary-foreground fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",$$props.class));var fragment_2=comment$2(),node_3=first_child(fragment_2);{var consequent=$$anchor2=>{
|
|
|
|
|
tooltipContent($$anchor2)},alternate=$$anchor2=>{var fragment_4=comment$2(),node_4=first_child(fragment_4);component(node_4,()=>Portal$2,($$anchor3,TooltipPrimitive_Portal)=>{TooltipPrimitive_Portal($$anchor3,{children:($$anchor4,$$slotProps)=>{tooltipContent($$anchor4)},$$slots:{default:!0}})}),append($$anchor2,fragment_4)};if_block(node_3,$$render=>{noPortal()?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment_2),pop()}const Root$5=Tooltip,Provider=Tooltip_provider;var AttachmentType=(AttachmentType2=>(AttachmentType2.
|
|
|
|
|
AUDIO="AUDIO",AttachmentType2.IMAGE="IMAGE",AttachmentType2.MCP_PROMPT="MCP_PROMPT",AttachmentType2.MCP_RESOURCE="MCP_RESOURCE",AttachmentType2.PDF="PDF",AttachmentType2.TEXT="TEXT",AttachmentType2.LEGACY_CONTEXT="context",AttachmentType2))(AttachmentType||{}),AttachmentMenuItemId=(AttachmentMenuItemId2=>(AttachmentMenuItemId2.IMAGES="images",AttachmentMenuItemId2.AUDIO="audio",AttachmentMenuItemId2.TEXT="text",AttachmentMenuItemId2.PDF="pdf",AttachmentMenuItemId2.SYSTEM_MESSAGE="system-message",
|
|
|
|
|
AttachmentMenuItemId2.MCP_PROMPT="mcp-prompt",AttachmentMenuItemId2.MCP_RESOURCES="mcp-resources",AttachmentMenuItemId2))(AttachmentMenuItemId||{}),AttachmentItemEnabledWhen=(AttachmentItemEnabledWhen2=>(AttachmentItemEnabledWhen2.ALWAYS="always",AttachmentItemEnabledWhen2.HAS_VISION_MODALITY="hasVisionModality",AttachmentItemEnabledWhen2.HAS_AUDIO_MODALITY="hasAudioModality",AttachmentItemEnabledWhen2))(AttachmentItemEnabledWhen||{}),AttachmentAction=(AttachmentAction2=>(AttachmentAction2.FILE_UPLOAD=
|
|
|
|
|
"onFileUpload",AttachmentAction2.SYSTEM_PROMPT_CLICK="onSystemPromptClick",AttachmentAction2.MCP_PROMPT_CLICK="onMcpPromptClick",AttachmentAction2.MCP_RESOURCES_CLICK="onMcpResourcesClick",AttachmentAction2))(AttachmentAction||{}),AttachmentItemVisibleWhen=(AttachmentItemVisibleWhen2=>(AttachmentItemVisibleWhen2.HAS_MCP_PROMPTS_SUPPORT="hasMcpPromptsSupport",AttachmentItemVisibleWhen2.HAS_MCP_RESOURCES_SUPPORT="hasMcpResourcesSupport",AttachmentItemVisibleWhen2))(AttachmentItemVisibleWhen||{}),ToolCallType=(ToolCallType2=>(ToolCallType2.
|
|
|
|
|
FUNCTION="function",ToolCallType2))(ToolCallType||{}),AgenticSectionType=(AgenticSectionType2=>(AgenticSectionType2.TEXT="text",AgenticSectionType2.TOOL_CALL="tool_call",AgenticSectionType2.TOOL_CALL_PENDING="tool_call_pending",AgenticSectionType2.TOOL_CALL_STREAMING="tool_call_streaming",AgenticSectionType2.REASONING="reasoning",AgenticSectionType2.REASONING_PENDING="reasoning_pending",AgenticSectionType2))(AgenticSectionType||{}),ChatMessageStatsView=(ChatMessageStatsView2=>(ChatMessageStatsView2.
|
|
|
|
|
GENERATION="generation",ChatMessageStatsView2.READING="reading",ChatMessageStatsView2.TOOLS="tools",ChatMessageStatsView2.SUMMARY="summary",ChatMessageStatsView2))(ChatMessageStatsView||{}),ReasoningFormat=(ReasoningFormat2=>(ReasoningFormat2.NONE="none",ReasoningFormat2.AUTO="auto",ReasoningFormat2))(ReasoningFormat||{}),MessageRole=(MessageRole2=>(MessageRole2.USER="user",MessageRole2.ASSISTANT="assistant",MessageRole2.SYSTEM="system",MessageRole2.TOOL="tool",MessageRole2))(MessageRole||{}),MessageType=(MessageType2=>(MessageType2.
|
|
|
|
|
ROOT="root",MessageType2.TEXT="text",MessageType2.THINK="think",MessageType2.SYSTEM="system",MessageType2))(MessageType||{}),ContentPartType=(ContentPartType2=>(ContentPartType2.TEXT="text",ContentPartType2.IMAGE_URL="image_url",ContentPartType2.INPUT_AUDIO="input_audio",ContentPartType2))(ContentPartType||{}),ErrorDialogType=(ErrorDialogType2=>(ErrorDialogType2.TIMEOUT="timeout",ErrorDialogType2.SERVER="server",ErrorDialogType2))(ErrorDialogType||{}),ConversationSelectionMode=(ConversationSelectionMode2=>(ConversationSelectionMode2.
|
|
|
|
|
EXPORT="export",ConversationSelectionMode2.IMPORT="import",ConversationSelectionMode2))(ConversationSelectionMode||{}),PdfViewMode=(PdfViewMode2=>(PdfViewMode2.TEXT="text",PdfViewMode2.PAGES="pages",PdfViewMode2))(PdfViewMode||{}),FileTypeCategory=(FileTypeCategory2=>(FileTypeCategory2.IMAGE="image",FileTypeCategory2.AUDIO="audio",FileTypeCategory2.PDF="pdf",FileTypeCategory2.TEXT="text",FileTypeCategory2))(FileTypeCategory||{}),SpecialFileType=(SpecialFileType2=>(SpecialFileType2.MCP_PROMPT="mc\
|
|
|
|
|
p-prompt",SpecialFileType2))(SpecialFileType||{}),FileTypeImage=(FileTypeImage2=>(FileTypeImage2.JPEG="jpeg",FileTypeImage2.PNG="png",FileTypeImage2.GIF="gif",FileTypeImage2.WEBP="webp",FileTypeImage2.SVG="svg",FileTypeImage2))(FileTypeImage||{}),FileTypeAudio=(FileTypeAudio2=>(FileTypeAudio2.MP3="mp3",FileTypeAudio2.WAV="wav",FileTypeAudio2.WEBM="webm",FileTypeAudio2))(FileTypeAudio||{}),FileTypePdf=(FileTypePdf2=>(FileTypePdf2.PDF="pdf",FileTypePdf2))(FileTypePdf||{}),FileTypeText=(FileTypeText2=>(FileTypeText2.
|
|
|
|
|
PLAIN_TEXT="plainText",FileTypeText2.MARKDOWN="md",FileTypeText2.ASCIIDOC="asciidoc",FileTypeText2.JAVASCRIPT="js",FileTypeText2.TYPESCRIPT="ts",FileTypeText2.JSX="jsx",FileTypeText2.TSX="tsx",FileTypeText2.CSS="css",FileTypeText2.HTML="html",FileTypeText2.JSON="json",FileTypeText2.XML="xml",FileTypeText2.YAML="yaml",FileTypeText2.CSV="csv",FileTypeText2.LOG="log",FileTypeText2.PYTHON="python",FileTypeText2.JAVA="java",FileTypeText2.CPP="cpp",FileTypeText2.PHP="php",FileTypeText2.RUBY="ruby",FileTypeText2.
|
|
|
|
|
GO="go",FileTypeText2.RUST="rust",FileTypeText2.SHELL="shell",FileTypeText2.SQL="sql",FileTypeText2.R="r",FileTypeText2.SCALA="scala",FileTypeText2.KOTLIN="kotlin",FileTypeText2.SWIFT="swift",FileTypeText2.DART="dart",FileTypeText2.VUE="vue",FileTypeText2.SVELTE="svelte",FileTypeText2.LATEX="latex",FileTypeText2.BIBTEX="bibtex",FileTypeText2.CUDA="cuda",FileTypeText2.VULKAN="vulkan",FileTypeText2.HASKELL="haskell",FileTypeText2.CSHARP="csharp",FileTypeText2.PROPERTIES="properties",FileTypeText2))(
|
|
|
|
|
FileTypeText||{}),FileExtensionImage=(FileExtensionImage2=>(FileExtensionImage2.JPG=".jpg",FileExtensionImage2.JPEG=".jpeg",FileExtensionImage2.PNG=".png",FileExtensionImage2.GIF=".gif",FileExtensionImage2.WEBP=".webp",FileExtensionImage2.SVG=".svg",FileExtensionImage2))(FileExtensionImage||{}),FileExtensionAudio=(FileExtensionAudio2=>(FileExtensionAudio2.MP3=".mp3",FileExtensionAudio2.WAV=".wav",FileExtensionAudio2))(FileExtensionAudio||{}),FileExtensionPdf=(FileExtensionPdf2=>(FileExtensionPdf2.
|
|
|
|
|
PDF=".pdf",FileExtensionPdf2))(FileExtensionPdf||{}),FileExtensionText=(FileExtensionText2=>(FileExtensionText2.TXT=".txt",FileExtensionText2.MD=".md",FileExtensionText2.ADOC=".adoc",FileExtensionText2.JS=".js",FileExtensionText2.TS=".ts",FileExtensionText2.JSX=".jsx",FileExtensionText2.TSX=".tsx",FileExtensionText2.CSS=".css",FileExtensionText2.HTML=".html",FileExtensionText2.HTM=".htm",FileExtensionText2.JSON=".json",FileExtensionText2.XML=".xml",FileExtensionText2.YAML=".yaml",FileExtensionText2.
|
|
|
|
|
YML=".yml",FileExtensionText2.CSV=".csv",FileExtensionText2.LOG=".log",FileExtensionText2.PY=".py",FileExtensionText2.JAVA=".java",FileExtensionText2.CPP=".cpp",FileExtensionText2.C=".c",FileExtensionText2.H=".h",FileExtensionText2.PHP=".php",FileExtensionText2.RB=".rb",FileExtensionText2.GO=".go",FileExtensionText2.RS=".rs",FileExtensionText2.SH=".sh",FileExtensionText2.BAT=".bat",FileExtensionText2.SQL=".sql",FileExtensionText2.R=".r",FileExtensionText2.SCALA=".scala",FileExtensionText2.KT=".k\
|
|
|
|
|
t",FileExtensionText2.SWIFT=".swift",FileExtensionText2.DART=".dart",FileExtensionText2.VUE=".vue",FileExtensionText2.SVELTE=".svelte",FileExtensionText2.TEX=".tex",FileExtensionText2.BIB=".bib",FileExtensionText2.CU=".cu",FileExtensionText2.CUH=".cuh",FileExtensionText2.COMP=".comp",FileExtensionText2.HPP=".hpp",FileExtensionText2.HS=".hs",FileExtensionText2.PROPERTIES=".properties",FileExtensionText2.CS=".cs",FileExtensionText2))(FileExtensionText||{}),MimeTypePrefix=(MimeTypePrefix2=>(MimeTypePrefix2.
|
|
|
|
|
IMAGE="image/",MimeTypePrefix2.TEXT="text",MimeTypePrefix2))(MimeTypePrefix||{}),MimeTypeIncludes=(MimeTypeIncludes2=>(MimeTypeIncludes2.JSON="json",MimeTypeIncludes2.JAVASCRIPT="javascript",MimeTypeIncludes2.TYPESCRIPT="typescript",MimeTypeIncludes2))(MimeTypeIncludes||{}),UriPattern=(UriPattern2=>(UriPattern2.DATABASE_KEYWORD="database",UriPattern2.DATABASE_SCHEME="db://",UriPattern2))(UriPattern||{}),MimeTypeApplication=(MimeTypeApplication2=>(MimeTypeApplication2.PDF="application/pdf",MimeTypeApplication2.
|
|
|
|
|
OCTET_STREAM="application/octet-stream",MimeTypeApplication2))(MimeTypeApplication||{}),MimeTypeAudio=(MimeTypeAudio2=>(MimeTypeAudio2.MP3_MPEG="audio/mpeg",MimeTypeAudio2.MP3="audio/mp3",MimeTypeAudio2.MP4="audio/mp4",MimeTypeAudio2.WAV="audio/wav",MimeTypeAudio2.WEBM="audio/webm",MimeTypeAudio2.WEBM_OPUS="audio/webm;codecs=opus",MimeTypeAudio2))(MimeTypeAudio||{}),MimeTypeImage=(MimeTypeImage2=>(MimeTypeImage2.JPEG="image/jpeg",MimeTypeImage2.JPG="image/jpg",MimeTypeImage2.PNG="image/png",MimeTypeImage2.
|
|
|
|
|
GIF="image/gif",MimeTypeImage2.WEBP="image/webp",MimeTypeImage2.SVG="image/svg+xml",MimeTypeImage2.ICO="image/x-icon",MimeTypeImage2.ICO_MICROSOFT="image/vnd.microsoft.icon",MimeTypeImage2))(MimeTypeImage||{}),MimeTypeText=(MimeTypeText2=>(MimeTypeText2.PLAIN="text/plain",MimeTypeText2.MARKDOWN="text/markdown",MimeTypeText2.ASCIIDOC="text/asciidoc",MimeTypeText2.JAVASCRIPT="text/javascript",MimeTypeText2.JAVASCRIPT_APP="application/javascript",MimeTypeText2.TYPESCRIPT="text/typescript",MimeTypeText2.
|
|
|
|
|
JSX="text/jsx",MimeTypeText2.TSX="text/tsx",MimeTypeText2.CSS="text/css",MimeTypeText2.HTML="text/html",MimeTypeText2.JSON="application/json",MimeTypeText2.XML_TEXT="text/xml",MimeTypeText2.XML_APP="application/xml",MimeTypeText2.YAML_TEXT="text/yaml",MimeTypeText2.YAML_APP="application/yaml",MimeTypeText2.CSV="text/csv",MimeTypeText2.PYTHON="text/x-python",MimeTypeText2.JAVA="text/x-java-source",MimeTypeText2.CPP_HDR="text/x-c++hdr",MimeTypeText2.CPP_SRC="text/x-c++src",MimeTypeText2.CSHARP="te\
|
|
|
|
|
xt/x-csharp",MimeTypeText2.HASKELL="text/x-haskell",MimeTypeText2.C_SRC="text/x-csrc",MimeTypeText2.C_HDR="text/x-chdr",MimeTypeText2.PHP="text/x-php",MimeTypeText2.RUBY="text/x-ruby",MimeTypeText2.GO="text/x-go",MimeTypeText2.RUST="text/x-rust",MimeTypeText2.SHELL="text/x-shellscript",MimeTypeText2.BAT="application/x-bat",MimeTypeText2.SQL="text/x-sql",MimeTypeText2.R="text/x-r",MimeTypeText2.SCALA="text/x-scala",MimeTypeText2.KOTLIN="text/x-kotlin",MimeTypeText2.SWIFT="text/x-swift",MimeTypeText2.
|
|
|
|
|
DART="text/x-dart",MimeTypeText2.VUE="text/x-vue",MimeTypeText2.SVELTE="text/x-svelte",MimeTypeText2.TEX="text/x-tex",MimeTypeText2.TEX_APP="application/x-tex",MimeTypeText2.LATEX="application/x-latex",MimeTypeText2.BIBTEX="text/x-bibtex",MimeTypeText2.CUDA="text/x-cuda",MimeTypeText2.PROPERTIES="text/properties",MimeTypeText2))(MimeTypeText||{}),MCPConnectionPhase=(MCPConnectionPhase2=>(MCPConnectionPhase2.IDLE="idle",MCPConnectionPhase2.TRANSPORT_CREATING="transport_creating",MCPConnectionPhase2.
|
|
|
|
|
TRANSPORT_READY="transport_ready",MCPConnectionPhase2.INITIALIZING="initializing",MCPConnectionPhase2.CAPABILITIES_EXCHANGED="capabilities_exchanged",MCPConnectionPhase2.LISTING_TOOLS="listing_tools",MCPConnectionPhase2.CONNECTED="connected",MCPConnectionPhase2.ERROR="error",MCPConnectionPhase2.DISCONNECTED="disconnected",MCPConnectionPhase2))(MCPConnectionPhase||{}),MCPLogLevel=(MCPLogLevel2=>(MCPLogLevel2.INFO="info",MCPLogLevel2.WARN="warn",MCPLogLevel2.ERROR="error",MCPLogLevel2))(MCPLogLevel||
|
|
|
|
|
{}),MCPTransportType=(MCPTransportType2=>(MCPTransportType2.WEBSOCKET="websocket",MCPTransportType2.STREAMABLE_HTTP="streamable_http",MCPTransportType2.SSE="sse",MCPTransportType2))(MCPTransportType||{}),HealthCheckStatus=(HealthCheckStatus2=>(HealthCheckStatus2.IDLE="idle",HealthCheckStatus2.CONNECTING="connecting",HealthCheckStatus2.SUCCESS="success",HealthCheckStatus2.ERROR="error",HealthCheckStatus2))(HealthCheckStatus||{}),MCPContentType=(MCPContentType2=>(MCPContentType2.TEXT="text",MCPContentType2.
|
|
|
|
|
IMAGE="image",MCPContentType2.RESOURCE="resource",MCPContentType2))(MCPContentType||{}),JsonSchemaType=(JsonSchemaType2=>(JsonSchemaType2.OBJECT="object",JsonSchemaType2))(JsonSchemaType||{}),MCPRefType=(MCPRefType2=>(MCPRefType2.PROMPT="ref/prompt",MCPRefType2.RESOURCE="ref/resource",MCPRefType2))(MCPRefType||{}),ModelModality=(ModelModality2=>(ModelModality2.TEXT="TEXT",ModelModality2.AUDIO="AUDIO",ModelModality2.VISION="VISION",ModelModality2))(ModelModality||{}),ServerRole=(ServerRole2=>(ServerRole2.
|
|
|
|
|
MODEL="model",ServerRole2.ROUTER="router",ServerRole2))(ServerRole||{}),ServerModelStatus=(ServerModelStatus2=>(ServerModelStatus2.UNLOADED="unloaded",ServerModelStatus2.LOADING="loading",ServerModelStatus2.LOADED="loaded",ServerModelStatus2.SLEEPING="sleeping",ServerModelStatus2.FAILED="failed",ServerModelStatus2))(ServerModelStatus||{}),ParameterSource=(ParameterSource2=>(ParameterSource2.DEFAULT="default",ParameterSource2.CUSTOM="custom",ParameterSource2))(ParameterSource||{}),SyncableParameterType=(SyncableParameterType2=>(SyncableParameterType2.
|
|
|
|
|
NUMBER="number",SyncableParameterType2.STRING="string",SyncableParameterType2.BOOLEAN="boolean",SyncableParameterType2))(SyncableParameterType||{}),SettingsFieldType=(SettingsFieldType2=>(SettingsFieldType2.INPUT="input",SettingsFieldType2.TEXTAREA="textarea",SettingsFieldType2.CHECKBOX="checkbox",SettingsFieldType2.SELECT="select",SettingsFieldType2))(SettingsFieldType||{}),ColorMode=(ColorMode2=>(ColorMode2.LIGHT="light",ColorMode2.DARK="dark",ColorMode2.SYSTEM="system",ColorMode2))(ColorMode||
|
|
|
|
|
{}),TooltipSide=(TooltipSide2=>(TooltipSide2.TOP="top",TooltipSide2.RIGHT="right",TooltipSide2.BOTTOM="bottom",TooltipSide2.LEFT="left",TooltipSide2))(TooltipSide||{}),McpPromptVariant=(McpPromptVariant2=>(McpPromptVariant2.MESSAGE="message",McpPromptVariant2.ATTACHMENT="attachment",McpPromptVariant2))(McpPromptVariant||{}),UrlProtocol=(UrlProtocol2=>(UrlProtocol2.DATA="data:",UrlProtocol2.HTTP="http:",UrlProtocol2.HTTPS="https:",UrlProtocol2.WEBSOCKET="ws:",UrlProtocol2.WEBSOCKET_SECURE="wss:",
|
|
|
|
|
UrlProtocol2))(UrlProtocol||{}),HtmlInputType=(HtmlInputType2=>(HtmlInputType2.FILE="file",HtmlInputType2))(HtmlInputType||{}),KeyboardKey=(KeyboardKey2=>(KeyboardKey2.ENTER="Enter",KeyboardKey2.ESCAPE="Escape",KeyboardKey2.ARROW_UP="ArrowUp",KeyboardKey2.ARROW_DOWN="ArrowDown",KeyboardKey2.ARROW_LEFT="ArrowLeft",KeyboardKey2.ARROW_RIGHT="ArrowRight",KeyboardKey2.TAB="Tab",KeyboardKey2.D_LOWER="d",KeyboardKey2.D_UPPER="D",KeyboardKey2.E_UPPER="E",KeyboardKey2.K_LOWER="k",KeyboardKey2.O_LOWER="o",
|
|
|
|
|
KeyboardKey2.O_UPPER="O",KeyboardKey2.SPACE=" ",KeyboardKey2))(KeyboardKey||{}),ToolSource=(ToolSource2=>(ToolSource2.BUILTIN="builtin",ToolSource2.MCP="mcp",ToolSource2.CUSTOM="custom",ToolSource2))(ToolSource||{}),ToolPermissionDecision=(ToolPermissionDecision2=>(ToolPermissionDecision2.ALWAYS="always",ToolPermissionDecision2.ALWAYS_SERVER="always_server",ToolPermissionDecision2.ONCE="once",ToolPermissionDecision2.DENY="deny",ToolPermissionDecision2))(ToolPermissionDecision||{}),ToolResponseField=(ToolResponseField2=>(ToolResponseField2.
|
|
|
|
|
PLAIN_TEXT="plain_text_response",ToolResponseField2.ERROR="error",ToolResponseField2))(ToolResponseField||{}),root_5$w=from_html("<p> </p>"),root_1$17=from_html("<!> <!>",1);function ActionIcon($$anchor,$$props){push$1($$props,!0);let variant=prop($$props,"variant",3,"ghost"),size2=prop($$props,"size",3,"sm"),className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),iconSize=prop($$props,"iconSize",3,"h-3 w-3"),tooltipSide=prop($$props,"tooltipSide",19,()=>TooltipSide.TOP),stopPropagationOnClick=prop(
|
|
|
|
|
$$props,"stopPropagationOnClick",3,!1);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Root$5,($$anchor2,Tooltip_Root)=>{Tooltip_Root($$anchor2,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$17(),node_1=first_child(fragment_1);component(node_1,()=>Tooltip_trigger,($$anchor4,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor4,{children:($$anchor5,$$slotProps2)=>{{let $0=user_derived(()=>$$props.ariaLabel||$$props.tooltip);Button($$anchor5,{get variant(){return variant()},
|
|
|
|
|
get size(){return size2()},get disabled(){return disabled()},onclick:e=>{stopPropagationOnClick()&&e.stopPropagation(),$$props.onclick?.(e)},get class(){return`h-6 w-6 p-0 ${className()??""} flex hover:bg-transparent data-[state=open]:bg-transparent!`},get"aria-label"(){return get$3($0)},children:($$anchor6,$$slotProps3)=>{var fragment_3=comment$2(),node_2=first_child(fragment_3);{var consequent=$$anchor7=>{const IconComponent=user_derived(()=>$$props.icon);var fragment_4=comment$2(),node_3=first_child(
|
|
|
|
|
fragment_4);component(node_3,()=>get$3(IconComponent),($$anchor8,IconComponent_1)=>{IconComponent_1($$anchor8,{get class(){return iconSize()}})}),append($$anchor7,fragment_4)};if_block(node_2,$$render=>{$$props.icon&&$$render(consequent)})}append($$anchor6,fragment_3)},$$slots:{default:!0}})}},$$slots:{default:!0}})});var node_4=sibling(node_1,2);component(node_4,()=>Tooltip_content,($$anchor4,Tooltip_Content)=>{Tooltip_Content($$anchor4,{get side(){return tooltipSide()},children:($$anchor5,$$slotProps2)=>{
|
|
|
|
|
var p2=root_5$w(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,$$props.tooltip)),append($$anchor5,p2)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment),pop()}const defaultAttributes={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"};var root$1T=from_svg("<svg><!><!></svg>");function Icon($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);const color=prop($$props,"color",3,"currentColor"),size2=prop($$props,"size",3,24),strokeWidth=prop($$props,"strokeWidth",3,2),absoluteStrokeWidth=prop($$props,"absoluteStrokeWidth",3,!1),iconNode=prop($$props,"iconNode",19,()=>[]),props=rest_props($$props,["$$slots","$$events","$$legacy","name","color","size","strokeWidth","absoluteStrokeWidth","iconNode","children"]);var svg2=root$1T();attribute_effect(svg2,$0=>({...defaultAttributes,...props,width:size2(),height:size2(),stroke:color(),
|
|
|
|
|
"stroke-width":$0,class:["lucide-icon lucide",$$props.name&&`lucide-${$$props.name}`,$$props.class]}),[()=>absoluteStrokeWidth()?Number(strokeWidth())*24/Number(size2()):strokeWidth()]);var node2=child(svg2);each(node2,17,iconNode,index$2,($$anchor2,$$item)=>{var $$array=user_derived(()=>to_array(get$3($$item),2));let tag=()=>get$3($$array)[0],attrs=()=>get$3($$array)[1];var fragment=comment$2(),node_1=first_child(fragment);element$4(node_1,tag,!0,($$element,$$anchor3)=>{attribute_effect($$element,
|
|
|
|
|
()=>({...attrs()}))}),append($$anchor2,fragment)});var node_2=sibling(node2);snippet(node_2,()=>$$props.children??noop$3),reset(svg2),append($$anchor,svg2),pop()}function Arrow_big_up($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M9 18v-6H5l7-7 7 7h-4v6H9z"}]];Icon($$anchor,spread_props({name:"arrow-big-up"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(
|
|
|
|
|
fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Arrow_right($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M5 12h14"}],["path",{d:"m12 5 7 7-7 7"}]];Icon($$anchor,spread_props({name:"arrow-right"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,
|
|
|
|
|
()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Arrow_up($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m5 12 7-7 7 7"}],["path",{d:"M12 19V5"}]];Icon($$anchor,spread_props({name:"arrow-up"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),
|
|
|
|
|
append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Book_open_text($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 7v14"}],["path",{d:"M16 12h2"}],["path",{d:"M16 8h2"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z"}],["path",{d:"M6 12h2"}],["path",{d:"M6 8h2"}]];Icon($$anchor,spread_props({name:"bo\
|
|
|
|
|
ok-open-text"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Braces($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1"}],["path",{d:"M16 21h1a2 2 0 0 \
|
|
|
|
|
0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1"}]];Icon($$anchor,spread_props({name:"braces"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Brain($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 5a3 3 0 1 \
|
|
|
|
|
0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516"}],["path",{d:"M19.967 17.484A4 4 0 0\
|
|
|
|
|
1 18 18"}]];Icon($$anchor,spread_props({name:"brain"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Check($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M20 6 9 17l-5-5"}]];Icon($$anchor,spread_props({name:"check"},
|
|
|
|
|
()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_down($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m6 9 6 6 6-6"}]];Icon($$anchor,spread_props({name:"chevron-down"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_left($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m15 18-6-6 6-6"}]];Icon($$anchor,spread_props({name:"chevron-left"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(
|
|
|
|
|
fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_up($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m18 15-6-6-6 6"}]];Icon($$anchor,spread_props({name:"chevron-up"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??
|
|
|
|
|
noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_right($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m9 18 6-6-6-6"}]];Icon($$anchor,spread_props({name:"chevron-right"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{
|
|
|
|
|
default:!0}})),pop()}function Chevrons_up_down($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m7 15 5 5 5-5"}],["path",{d:"m7 9 5-5 5 5"}]];Icon($$anchor,spread_props({name:"chevrons-up-down"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),
|
|
|
|
|
pop()}function Circle_alert($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16"}]];Icon($$anchor,spread_props({name:"circle-alert"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append(
|
|
|
|
|
$$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Circle_check_big($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335"}],["path",{d:"m9 11 3 3L22 4"}]];Icon($$anchor,spread_props({name:"circle-check-big"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),
|
|
|
|
|
append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Circle_x($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"m15 9-6 6"}],["path",{d:"m9 9 6 6"}]];Icon($$anchor,spread_props({name:"circle-x"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),
|
|
|
|
|
append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Clock($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["polyline",{points:"12 6 12 12 16 14"}]];Icon($$anchor,spread_props({name:"clock"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,
|
|
|
|
|
fragment_1)},$$slots:{default:!0}})),pop()}function Code($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m16 18 6-6-6-6"}],["path",{d:"m8 6-6 6 6 6"}]];Icon($$anchor,spread_props({name:"code"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),
|
|
|
|
|
pop()}function Copy($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"}]];Icon($$anchor,spread_props({name:"copy"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,
|
|
|
|
|
fragment_1)},$$slots:{default:!0}})),pop()}function Database($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5"}],["path",{d:"M3 12A9 3 0 0 0 21 12"}]];Icon($$anchor,spread_props({name:"database"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Download($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 15V3"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}],["path",{d:"m7 10 5 5 5-5"}]];Icon($$anchor,spread_props({name:"download"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);
|
|
|
|
|
snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Ellipsis($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"1"}],["circle",{cx:"19",cy:"12",r:"1"}],["circle",{cx:"5",cy:"12",r:"1"}]];Icon($$anchor,spread_props({name:"ellipsis"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(
|
|
|
|
|
fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function External_link($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 3h6v6"}],["path",{d:"M10 14 21 3"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"}]];Icon($$anchor,spread_props({name:"external-link"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Eye($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"}],["circle",{cx:"12",cy:"12",r:"3"}]];Icon($$anchor,spread_props({name:"eye"},()=>props,{get iconNode(){
|
|
|
|
|
return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function File_text($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}],["path",{d:"M10 9H8"}],["path",{d:"M16\
|
|
|
|
|
13H8"}],["path",{d:"M16 17H8"}]];Icon($$anchor,spread_props({name:"file-text"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function File_x($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2\
|
|
|
|
|
2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}],["path",{d:"m14.5 12.5-5 5"}],["path",{d:"m9.5 12.5 5 5"}]];Icon($$anchor,spread_props({name:"file-x"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function File$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots",
|
|
|
|
|
"$$events","$$legacy"]);const iconNode=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}]];Icon($$anchor,spread_props({name:"file"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Flask_conical($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2"}],["path",{d:"M6.453 15h11.094"}],["path",{d:"M8.5 2h7"}]];Icon($$anchor,spread_props({name:"flask-conical"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{
|
|
|
|
|
default:!0}})),pop()}function Folder_open($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"}]];Icon($$anchor,spread_props({name:"folder-open"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Funnel($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z"}]];Icon($$anchor,spread_props({name:"funnel"},()=>props,{get iconNode(){return iconNode},
|
|
|
|
|
children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Gauge($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m12 14 4-4"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0"}]];Icon($$anchor,spread_props({name:"gauge"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Git_branch($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["line",{x1:"6",x2:"6",y1:"3",y2:"15"}],["circle",{cx:"18",cy:"6",r:"3"}],["circle",{cx:"6",cy:"18",r:"3"}],["path",{d:"M18 9a9 9 0 0 1-9 9"}]];Icon($$anchor,spread_props({name:"git-branch"},()=>props,{
|
|
|
|
|
get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Globe($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"}],["path",{d:"M2 12h20"}]];Icon($$anchor,spread_props(
|
|
|
|
|
{name:"globe"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Heart_off($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["line",{x1:"2",y1:"2",x2:"22",y2:"22"}],["path",{d:"M16.5 16.5 12 21l-7-7c-1.5-1.45-3-3.2-3-5.5a5.5 5.5 0 0 1\
|
|
|
|
|
2.14-4.35"}],["path",{d:"M8.76 3.1c1.15.22 2.13.78 3.24 1.9 1.5-1.5 2.74-2 4.5-2A5.5 5.5 0 0 1 22 8.5c0 2.12-1.3 3.78-2.67 5.17"}]];Icon($$anchor,spread_props({name:"heart-off"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Heart($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,[
|
|
|
|
|
"$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z"}]];Icon($$anchor,spread_props({name:"heart"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Image$1($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2"}],["circle",{cx:"9",cy:"9",r:"2"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21"}]];Icon($$anchor,spread_props({name:"image"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},
|
|
|
|
|
$$slots:{default:!0}})),pop()}function Info$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 16v-4"}],["path",{d:"M12 8h.01"}]];Icon($$anchor,spread_props({name:"info"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},
|
|
|
|
|
$$slots:{default:!0}})),pop()}function Key($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4"}],["path",{d:"m21 2-9.6 9.6"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5"}]];Icon($$anchor,spread_props({name:"key"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Layers($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 \
|
|
|
|
|
0 0 22 17"}]];Icon($$anchor,spread_props({name:"layers"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function List_checks($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m3 17 2 2 4-4"}],["path",{d:"m3 7 2 2 4-4"}],["path",{
|
|
|
|
|
d:"M13 6h8"}],["path",{d:"M13 12h8"}],["path",{d:"M13 18h8"}]];Icon($$anchor,spread_props({name:"list-checks"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function List_restart($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"\
|
|
|
|
|
M21 6H3"}],["path",{d:"M7 12H3"}],["path",{d:"M7 18H3"}],["path",{d:"M12 18a5 5 0 0 0 9-3 4.5 4.5 0 0 0-4.5-4.5c-1.33 0-2.54.54-3.41 1.41L11 14"}],["path",{d:"M11 10v4h4"}]];Icon($$anchor,spread_props({name:"list-restart"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Loader_circle($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56"}]];Icon($$anchor,spread_props({name:"loader-circle"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Message_square($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"}]];Icon($$anchor,spread_props({name:"message-square"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Mic($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,
|
|
|
|
|
["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z"}],["path",{d:"M19 10v2a7 7 0 0 1-14 0v-2"}],["line",{x1:"12",x2:"12",y1:"19",y2:"22"}]];Icon($$anchor,spread_props({name:"mic"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Minus($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M5 12h14"}]];Icon($$anchor,spread_props({name:"minus"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Monitor($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","\
|
|
|
|
|
$$events","$$legacy"]);const iconNode=[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21"}]];Icon($$anchor,spread_props({name:"monitor"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Moon($$anchor,$$props){push$1(
|
|
|
|
|
$$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z"}]];Icon($$anchor,spread_props({name:"moon"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Music($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,
|
|
|
|
|
["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M9 18V5l12-2v13"}],["circle",{cx:"6",cy:"18",r:"3"}],["circle",{cx:"18",cy:"16",r:"3"}]];Icon($$anchor,spread_props({name:"music"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Package($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z"}],["path",{d:"M12 22V12"}],["polyline",{points:"3.29 7 12 12 20.71 7"}],["path",{d:"m7.5 4.27 9 5.15"}]];Icon($$anchor,spread_props({name:"package"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Panel_left_close($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M9 3v18"}],["path",{d:"m16 15-3-3 3-3"}]];Icon($$anchor,spread_props({name:"panel-left-close"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(
|
|
|
|
|
fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Panel_left($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M9 3v18"}]];Icon($$anchor,spread_props({name:"panel-left"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(
|
|
|
|
|
fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Pencil_ruler($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M13 7 8.7 2.7a2.41 2.41 0 0 0-3.4 0L2.7 5.3a2.41 2.41 0 0 0 0 3.4L7 13"}],["path",{d:"m8 6 2-2"}],["path",{d:"m18 16 2-2"}],["path",{d:"m17 11 4.3 4.3c.94.94.94 2.46 0 3.4l-2.6 2.6c-.94.94-2.46.94-3.4 0L11 17"}],["path",{d:"M21.174 6\
|
|
|
|
|
.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"}],["path",{d:"m15 5 4 4"}]];Icon($$anchor,spread_props({name:"pencil-ruler"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Pencil($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"}],["path",{d:"m15 5 4 4"}]];Icon($$anchor,spread_props({name:"pencil"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),
|
|
|
|
|
pop()}function Plus($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M5 12h14"}],["path",{d:"M12 5v14"}]];Icon($$anchor,spread_props({name:"plus"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Power_off($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M18.36 6.64A9 9 0 0 1 20.77 15"}],["path",{d:"M6.16 6.16a9 9 0 1 0 12.68 12.68"}],["path",{d:"M12 2v4"}],["path",{d:"m2 2 20 20"}]];Icon($$anchor,spread_props({name:"power-off"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{
|
|
|
|
|
default:!0}})),pop()}function Power($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 2v10"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04"}]];Icon($$anchor,spread_props({name:"power"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}
|
|
|
|
|
function Radio($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M4.9 19.1C1 15.2 1 8.8 4.9 4.9"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5"}],["circle",{cx:"12",cy:"12",r:"2"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19"}]];Icon($$anchor,spread_props({name:"radio"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Refresh_cw($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8"}],["path",{d:"M21 3v5h-5"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16"}],["path",{d:"M8 16H3v5"}]];Icon($$anchor,spread_props({name:"refresh-cw"},
|
|
|
|
|
()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Rotate_ccw($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}],["path",{d:"M3 3v5h5"}]];Icon($$anchor,spread_props({name:"\
|
|
|
|
|
rotate-ccw"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Rotate_cw($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8"}],["path",{d:"M21 3v5h-5"}]];Icon($$anchor,spread_props(
|
|
|
|
|
{name:"rotate-cw"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Search($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m21 21-4.34-4.34"}],["circle",{cx:"11",cy:"11",r:"8"}]];Icon($$anchor,spread_props({name:"search"},
|
|
|
|
|
()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Server($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2"}],["line",{
|
|
|
|
|
x1:"6",x2:"6.01",y1:"6",y2:"6"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18"}]];Icon($$anchor,spread_props({name:"server"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Settings$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["p\
|
|
|
|
|
ath",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0\
|
|
|
|
|
-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"}],["circle",{cx:"12",cy:"12",r:"3"}]];Icon($$anchor,spread_props({name:"settings"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Shield_question($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots",
|
|
|
|
|
"$$events","$$legacy"]);const iconNode=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z"}],["path",{d:"M9.1 9a3 3 0 0 1 5.82 1c0 2-3 3-3 3"}],["path",{d:"M12 17h.01"}]];Icon($$anchor,spread_props({name:"shield-question"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Sliders_vertical($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["line",{x1:"4",x2:"4",y1:"21",y2:"14"}],["line",{x1:"4",x2:"4",y1:"10",y2:"3"}],["line",{x1:"12",x2:"12",y1:"21",y2:"12"}],["line",{x1:"12",x2:"12",y1:"8",y2:"3"}],["line",{x1:"20",x2:"20",y1:"21",y2:"16"}],["line",{x1:"20",x2:"20",y1:"12",y2:"3"}],["line",{x1:"2",x2:"6",y1:"14",
|
|
|
|
|
y2:"14"}],["line",{x1:"10",x2:"14",y1:"8",y2:"8"}],["line",{x1:"18",x2:"22",y1:"16",y2:"16"}]];Icon($$anchor,spread_props({name:"sliders-vertical"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Sparkles($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$lega\
|
|
|
|
|
cy"]);const iconNode=[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z"}],["path",{d:"M20 3v4"}],["path",{d:"M22 5h-4"}],["path",{d:"M4 17v2"}],["path",{d:"M5 18H3"}]];Icon($$anchor,spread_props({name:"sparkles"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Square_pen($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.8\
|
|
|
|
|
52z"}]];Icon($$anchor,spread_props({name:"square-pen"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Square($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}]];Icon($$anchor,spread_props(
|
|
|
|
|
{name:"square"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Sun($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"4"}],["path",{d:"M12 2v2"}],["path",{d:"M12 20v2"}],["path",{d:"m4.93 4.93 1.41 1.41"}],
|
|
|
|
|
["path",{d:"m17.66 17.66 1.41 1.41"}],["path",{d:"M2 12h2"}],["path",{d:"M20 12h2"}],["path",{d:"m6.34 17.66-1.41 1.41"}],["path",{d:"m19.07 4.93-1.41 1.41"}]];Icon($$anchor,spread_props({name:"sun"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Timer_off($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M10 2h4"}],["path",{d:"M4.6 11a8 8 0 0 0 1.7 8.7 8 8 0 0 0 8.7 1.7"}],["path",{d:"M7.4 7.4a8 8 0 0 1 10.3 1 8 8 0 0 1 .9 10.2"}],["path",{d:"m2 2 20 20"}],["path",{d:"M12 12v-2"}]];Icon($$anchor,spread_props({name:"timer-off"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},
|
|
|
|
|
$$slots:{default:!0}})),pop()}function Trash_2($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M3 6h18"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17"}]];Icon($$anchor,spread_props({name:"trash-2"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Triangle_alert($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"}],["path",{d:"M12 9v4"}],["path",{d:"M12 17h.01"}]];Icon($$anchor,spread_props({name:"triangle-alert"},()=>props,{get iconNode(){return iconNode},
|
|
|
|
|
children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Upload($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 3v12"}],["path",{d:"m17 8-5-5-5 5"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}]];Icon($$anchor,spread_props({name:"upload"},()=>props,{get iconNode(){
|
|
|
|
|
return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Whole_word($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"7",cy:"12",r:"3"}],["path",{d:"M10 9v6"}],["circle",{cx:"17",cy:"12",r:"3"}],["path",{d:"M14 7v8"}],["path",{d:"M22 17v1c0 .5-.5 1-1 1H\
|
|
|
|
|
3c-.5 0-1-.5-1-1v-1"}]];Icon($$anchor,spread_props({name:"whole-word"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Wrench($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1\
|
|
|
|
|
.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z"}]];Icon($$anchor,spread_props({name:"wrench"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function X($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$lega\
|
|
|
|
|
cy"]);const iconNode=[["path",{d:"M18 6 6 18"}],["path",{d:"m6 6 12 12"}]];Icon($$anchor,spread_props({name:"x"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Zap($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M4 14a\
|
|
|
|
|
1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z"}]];Icon($$anchor,spread_props({name:"zap"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}const ATTACHMENT_SAVED_REGEX=/\[Attachment saved: ([^\]]+)\]/,NEWLINE_SEPARATOR=`\
|
|
|
|
|
|
|
|
|
|
-(--bits-tooltip-content-transform-origin) animate-in rounded-md bg-primary px-3 py-1.5 text-xs text-balance text-primary-foreground fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=closed]:fill-mode-forwards",$$props.class));var fragment_2=comment$2(),node_3=first_child(
|
|
|
|
|
fragment_2);{var consequent=$$anchor2=>{tooltipContent($$anchor2)},alternate=$$anchor2=>{var fragment_4=comment$2(),node_4=first_child(fragment_4);component(node_4,()=>Portal$2,($$anchor3,TooltipPrimitive_Portal)=>{TooltipPrimitive_Portal($$anchor3,{children:($$anchor4,$$slotProps)=>{tooltipContent($$anchor4)},$$slots:{default:!0}})}),append($$anchor2,fragment_4)};if_block(node_3,$$render=>{noPortal()?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment_2),pop()}const Root$5=Tooltip,
|
|
|
|
|
Provider=Tooltip_provider;var AttachmentType=(AttachmentType2=>(AttachmentType2.AUDIO="AUDIO",AttachmentType2.IMAGE="IMAGE",AttachmentType2.MCP_PROMPT="MCP_PROMPT",AttachmentType2.MCP_RESOURCE="MCP_RESOURCE",AttachmentType2.PDF="PDF",AttachmentType2.TEXT="TEXT",AttachmentType2.LEGACY_CONTEXT="context",AttachmentType2))(AttachmentType||{}),AttachmentMenuItemId=(AttachmentMenuItemId2=>(AttachmentMenuItemId2.IMAGES="images",AttachmentMenuItemId2.AUDIO="audio",AttachmentMenuItemId2.TEXT="text",AttachmentMenuItemId2.
|
|
|
|
|
PDF="pdf",AttachmentMenuItemId2.SYSTEM_MESSAGE="system-message",AttachmentMenuItemId2.MCP_PROMPT="mcp-prompt",AttachmentMenuItemId2.MCP_RESOURCES="mcp-resources",AttachmentMenuItemId2))(AttachmentMenuItemId||{}),AttachmentItemEnabledWhen=(AttachmentItemEnabledWhen2=>(AttachmentItemEnabledWhen2.ALWAYS="always",AttachmentItemEnabledWhen2.HAS_VISION_MODALITY="hasVisionModality",AttachmentItemEnabledWhen2.HAS_AUDIO_MODALITY="hasAudioModality",AttachmentItemEnabledWhen2))(AttachmentItemEnabledWhen||{}),
|
|
|
|
|
AttachmentAction=(AttachmentAction2=>(AttachmentAction2.FILE_UPLOAD="onFileUpload",AttachmentAction2.SYSTEM_PROMPT_CLICK="onSystemPromptClick",AttachmentAction2.MCP_PROMPT_CLICK="onMcpPromptClick",AttachmentAction2.MCP_RESOURCES_CLICK="onMcpResourcesClick",AttachmentAction2))(AttachmentAction||{}),AttachmentItemVisibleWhen=(AttachmentItemVisibleWhen2=>(AttachmentItemVisibleWhen2.HAS_MCP_PROMPTS_SUPPORT="hasMcpPromptsSupport",AttachmentItemVisibleWhen2.HAS_MCP_RESOURCES_SUPPORT="hasMcpResourcesSu\
|
|
|
|
|
pport",AttachmentItemVisibleWhen2))(AttachmentItemVisibleWhen||{}),ToolCallType=(ToolCallType2=>(ToolCallType2.FUNCTION="function",ToolCallType2))(ToolCallType||{}),AgenticSectionType=(AgenticSectionType2=>(AgenticSectionType2.TEXT="text",AgenticSectionType2.TOOL_CALL="tool_call",AgenticSectionType2.TOOL_CALL_PENDING="tool_call_pending",AgenticSectionType2.TOOL_CALL_STREAMING="tool_call_streaming",AgenticSectionType2.REASONING="reasoning",AgenticSectionType2.REASONING_PENDING="reasoning_pending",
|
|
|
|
|
AgenticSectionType2))(AgenticSectionType||{}),ChatMessageStatsView=(ChatMessageStatsView2=>(ChatMessageStatsView2.GENERATION="generation",ChatMessageStatsView2.READING="reading",ChatMessageStatsView2.TOOLS="tools",ChatMessageStatsView2.SUMMARY="summary",ChatMessageStatsView2))(ChatMessageStatsView||{}),ReasoningFormat=(ReasoningFormat2=>(ReasoningFormat2.NONE="none",ReasoningFormat2.AUTO="auto",ReasoningFormat2))(ReasoningFormat||{}),MessageRole=(MessageRole2=>(MessageRole2.USER="user",MessageRole2.
|
|
|
|
|
ASSISTANT="assistant",MessageRole2.SYSTEM="system",MessageRole2.TOOL="tool",MessageRole2))(MessageRole||{}),MessageType=(MessageType2=>(MessageType2.ROOT="root",MessageType2.TEXT="text",MessageType2.THINK="think",MessageType2.SYSTEM="system",MessageType2))(MessageType||{}),ContentPartType=(ContentPartType2=>(ContentPartType2.TEXT="text",ContentPartType2.IMAGE_URL="image_url",ContentPartType2.INPUT_AUDIO="input_audio",ContentPartType2))(ContentPartType||{}),ErrorDialogType=(ErrorDialogType2=>(ErrorDialogType2.
|
|
|
|
|
TIMEOUT="timeout",ErrorDialogType2.SERVER="server",ErrorDialogType2))(ErrorDialogType||{}),ConversationSelectionMode=(ConversationSelectionMode2=>(ConversationSelectionMode2.EXPORT="export",ConversationSelectionMode2.IMPORT="import",ConversationSelectionMode2))(ConversationSelectionMode||{}),PdfViewMode=(PdfViewMode2=>(PdfViewMode2.TEXT="text",PdfViewMode2.PAGES="pages",PdfViewMode2))(PdfViewMode||{}),FileTypeCategory=(FileTypeCategory2=>(FileTypeCategory2.IMAGE="image",FileTypeCategory2.AUDIO="\
|
|
|
|
|
audio",FileTypeCategory2.PDF="pdf",FileTypeCategory2.TEXT="text",FileTypeCategory2))(FileTypeCategory||{}),SpecialFileType=(SpecialFileType2=>(SpecialFileType2.MCP_PROMPT="mcp-prompt",SpecialFileType2))(SpecialFileType||{}),FileTypeImage=(FileTypeImage2=>(FileTypeImage2.JPEG="jpeg",FileTypeImage2.PNG="png",FileTypeImage2.GIF="gif",FileTypeImage2.WEBP="webp",FileTypeImage2.SVG="svg",FileTypeImage2))(FileTypeImage||{}),FileTypeAudio=(FileTypeAudio2=>(FileTypeAudio2.MP3="mp3",FileTypeAudio2.WAV="wa\
|
|
|
|
|
v",FileTypeAudio2.WEBM="webm",FileTypeAudio2))(FileTypeAudio||{}),FileTypePdf=(FileTypePdf2=>(FileTypePdf2.PDF="pdf",FileTypePdf2))(FileTypePdf||{}),FileTypeText=(FileTypeText2=>(FileTypeText2.PLAIN_TEXT="plainText",FileTypeText2.MARKDOWN="md",FileTypeText2.ASCIIDOC="asciidoc",FileTypeText2.JAVASCRIPT="js",FileTypeText2.TYPESCRIPT="ts",FileTypeText2.JSX="jsx",FileTypeText2.TSX="tsx",FileTypeText2.CSS="css",FileTypeText2.HTML="html",FileTypeText2.JSON="json",FileTypeText2.XML="xml",FileTypeText2.
|
|
|
|
|
YAML="yaml",FileTypeText2.CSV="csv",FileTypeText2.LOG="log",FileTypeText2.PYTHON="python",FileTypeText2.JAVA="java",FileTypeText2.CPP="cpp",FileTypeText2.PHP="php",FileTypeText2.RUBY="ruby",FileTypeText2.GO="go",FileTypeText2.RUST="rust",FileTypeText2.SHELL="shell",FileTypeText2.SQL="sql",FileTypeText2.R="r",FileTypeText2.SCALA="scala",FileTypeText2.KOTLIN="kotlin",FileTypeText2.SWIFT="swift",FileTypeText2.DART="dart",FileTypeText2.VUE="vue",FileTypeText2.SVELTE="svelte",FileTypeText2.LATEX="lat\
|
|
|
|
|
ex",FileTypeText2.BIBTEX="bibtex",FileTypeText2.CUDA="cuda",FileTypeText2.VULKAN="vulkan",FileTypeText2.HASKELL="haskell",FileTypeText2.CSHARP="csharp",FileTypeText2.PROPERTIES="properties",FileTypeText2))(FileTypeText||{}),FileExtensionImage=(FileExtensionImage2=>(FileExtensionImage2.JPG=".jpg",FileExtensionImage2.JPEG=".jpeg",FileExtensionImage2.PNG=".png",FileExtensionImage2.GIF=".gif",FileExtensionImage2.WEBP=".webp",FileExtensionImage2.SVG=".svg",FileExtensionImage2))(FileExtensionImage||{}),
|
|
|
|
|
FileExtensionAudio=(FileExtensionAudio2=>(FileExtensionAudio2.MP3=".mp3",FileExtensionAudio2.WAV=".wav",FileExtensionAudio2))(FileExtensionAudio||{}),FileExtensionPdf=(FileExtensionPdf2=>(FileExtensionPdf2.PDF=".pdf",FileExtensionPdf2))(FileExtensionPdf||{}),FileExtensionText=(FileExtensionText2=>(FileExtensionText2.TXT=".txt",FileExtensionText2.MD=".md",FileExtensionText2.ADOC=".adoc",FileExtensionText2.JS=".js",FileExtensionText2.TS=".ts",FileExtensionText2.JSX=".jsx",FileExtensionText2.TSX=".\
|
|
|
|
|
tsx",FileExtensionText2.CSS=".css",FileExtensionText2.HTML=".html",FileExtensionText2.HTM=".htm",FileExtensionText2.JSON=".json",FileExtensionText2.XML=".xml",FileExtensionText2.YAML=".yaml",FileExtensionText2.YML=".yml",FileExtensionText2.CSV=".csv",FileExtensionText2.LOG=".log",FileExtensionText2.PY=".py",FileExtensionText2.JAVA=".java",FileExtensionText2.CPP=".cpp",FileExtensionText2.C=".c",FileExtensionText2.H=".h",FileExtensionText2.PHP=".php",FileExtensionText2.RB=".rb",FileExtensionText2.
|
|
|
|
|
GO=".go",FileExtensionText2.RS=".rs",FileExtensionText2.SH=".sh",FileExtensionText2.BAT=".bat",FileExtensionText2.SQL=".sql",FileExtensionText2.R=".r",FileExtensionText2.SCALA=".scala",FileExtensionText2.KT=".kt",FileExtensionText2.SWIFT=".swift",FileExtensionText2.DART=".dart",FileExtensionText2.VUE=".vue",FileExtensionText2.SVELTE=".svelte",FileExtensionText2.TEX=".tex",FileExtensionText2.BIB=".bib",FileExtensionText2.CU=".cu",FileExtensionText2.CUH=".cuh",FileExtensionText2.COMP=".comp",FileExtensionText2.
|
|
|
|
|
HPP=".hpp",FileExtensionText2.HS=".hs",FileExtensionText2.PROPERTIES=".properties",FileExtensionText2.CS=".cs",FileExtensionText2))(FileExtensionText||{}),MimeTypePrefix=(MimeTypePrefix2=>(MimeTypePrefix2.IMAGE="image/",MimeTypePrefix2.TEXT="text",MimeTypePrefix2))(MimeTypePrefix||{}),MimeTypeIncludes=(MimeTypeIncludes2=>(MimeTypeIncludes2.JSON="json",MimeTypeIncludes2.JAVASCRIPT="javascript",MimeTypeIncludes2.TYPESCRIPT="typescript",MimeTypeIncludes2))(MimeTypeIncludes||{}),UriPattern=(UriPattern2=>(UriPattern2.
|
|
|
|
|
DATABASE_KEYWORD="database",UriPattern2.DATABASE_SCHEME="db://",UriPattern2))(UriPattern||{}),MimeTypeApplication=(MimeTypeApplication2=>(MimeTypeApplication2.PDF="application/pdf",MimeTypeApplication2.OCTET_STREAM="application/octet-stream",MimeTypeApplication2))(MimeTypeApplication||{}),MimeTypeAudio=(MimeTypeAudio2=>(MimeTypeAudio2.MP3_MPEG="audio/mpeg",MimeTypeAudio2.MP3="audio/mp3",MimeTypeAudio2.MP4="audio/mp4",MimeTypeAudio2.WAV="audio/wav",MimeTypeAudio2.WEBM="audio/webm",MimeTypeAudio2.
|
|
|
|
|
WEBM_OPUS="audio/webm;codecs=opus",MimeTypeAudio2))(MimeTypeAudio||{}),MimeTypeImage=(MimeTypeImage2=>(MimeTypeImage2.JPEG="image/jpeg",MimeTypeImage2.JPG="image/jpg",MimeTypeImage2.PNG="image/png",MimeTypeImage2.GIF="image/gif",MimeTypeImage2.WEBP="image/webp",MimeTypeImage2.SVG="image/svg+xml",MimeTypeImage2.ICO="image/x-icon",MimeTypeImage2.ICO_MICROSOFT="image/vnd.microsoft.icon",MimeTypeImage2))(MimeTypeImage||{}),MimeTypeText=(MimeTypeText2=>(MimeTypeText2.PLAIN="text/plain",MimeTypeText2.
|
|
|
|
|
MARKDOWN="text/markdown",MimeTypeText2.ASCIIDOC="text/asciidoc",MimeTypeText2.JAVASCRIPT="text/javascript",MimeTypeText2.JAVASCRIPT_APP="application/javascript",MimeTypeText2.TYPESCRIPT="text/typescript",MimeTypeText2.JSX="text/jsx",MimeTypeText2.TSX="text/tsx",MimeTypeText2.CSS="text/css",MimeTypeText2.HTML="text/html",MimeTypeText2.JSON="application/json",MimeTypeText2.XML_TEXT="text/xml",MimeTypeText2.XML_APP="application/xml",MimeTypeText2.YAML_TEXT="text/yaml",MimeTypeText2.YAML_APP="applic\
|
|
|
|
|
ation/yaml",MimeTypeText2.CSV="text/csv",MimeTypeText2.PYTHON="text/x-python",MimeTypeText2.JAVA="text/x-java-source",MimeTypeText2.CPP_HDR="text/x-c++hdr",MimeTypeText2.CPP_SRC="text/x-c++src",MimeTypeText2.CSHARP="text/x-csharp",MimeTypeText2.HASKELL="text/x-haskell",MimeTypeText2.C_SRC="text/x-csrc",MimeTypeText2.C_HDR="text/x-chdr",MimeTypeText2.PHP="text/x-php",MimeTypeText2.RUBY="text/x-ruby",MimeTypeText2.GO="text/x-go",MimeTypeText2.RUST="text/x-rust",MimeTypeText2.SHELL="text/x-shellscr\
|
|
|
|
|
ipt",MimeTypeText2.BAT="application/x-bat",MimeTypeText2.SQL="text/x-sql",MimeTypeText2.R="text/x-r",MimeTypeText2.SCALA="text/x-scala",MimeTypeText2.KOTLIN="text/x-kotlin",MimeTypeText2.SWIFT="text/x-swift",MimeTypeText2.DART="text/x-dart",MimeTypeText2.VUE="text/x-vue",MimeTypeText2.SVELTE="text/x-svelte",MimeTypeText2.TEX="text/x-tex",MimeTypeText2.TEX_APP="application/x-tex",MimeTypeText2.LATEX="application/x-latex",MimeTypeText2.BIBTEX="text/x-bibtex",MimeTypeText2.CUDA="text/x-cuda",MimeTypeText2.
|
|
|
|
|
PROPERTIES="text/properties",MimeTypeText2))(MimeTypeText||{}),MCPConnectionPhase=(MCPConnectionPhase2=>(MCPConnectionPhase2.IDLE="idle",MCPConnectionPhase2.TRANSPORT_CREATING="transport_creating",MCPConnectionPhase2.TRANSPORT_READY="transport_ready",MCPConnectionPhase2.INITIALIZING="initializing",MCPConnectionPhase2.CAPABILITIES_EXCHANGED="capabilities_exchanged",MCPConnectionPhase2.LISTING_TOOLS="listing_tools",MCPConnectionPhase2.CONNECTED="connected",MCPConnectionPhase2.ERROR="error",MCPConnectionPhase2.
|
|
|
|
|
DISCONNECTED="disconnected",MCPConnectionPhase2))(MCPConnectionPhase||{}),MCPLogLevel=(MCPLogLevel2=>(MCPLogLevel2.INFO="info",MCPLogLevel2.WARN="warn",MCPLogLevel2.ERROR="error",MCPLogLevel2))(MCPLogLevel||{}),MCPTransportType=(MCPTransportType2=>(MCPTransportType2.WEBSOCKET="websocket",MCPTransportType2.STREAMABLE_HTTP="streamable_http",MCPTransportType2.SSE="sse",MCPTransportType2))(MCPTransportType||{}),HealthCheckStatus=(HealthCheckStatus2=>(HealthCheckStatus2.IDLE="idle",HealthCheckStatus2.
|
|
|
|
|
CONNECTING="connecting",HealthCheckStatus2.SUCCESS="success",HealthCheckStatus2.ERROR="error",HealthCheckStatus2))(HealthCheckStatus||{}),MCPContentType=(MCPContentType2=>(MCPContentType2.TEXT="text",MCPContentType2.IMAGE="image",MCPContentType2.RESOURCE="resource",MCPContentType2))(MCPContentType||{}),JsonSchemaType=(JsonSchemaType2=>(JsonSchemaType2.OBJECT="object",JsonSchemaType2))(JsonSchemaType||{}),MCPRefType=(MCPRefType2=>(MCPRefType2.PROMPT="ref/prompt",MCPRefType2.RESOURCE="ref/resource",
|
|
|
|
|
MCPRefType2))(MCPRefType||{}),ModelModality=(ModelModality2=>(ModelModality2.TEXT="TEXT",ModelModality2.AUDIO="AUDIO",ModelModality2.VISION="VISION",ModelModality2))(ModelModality||{}),ServerRole=(ServerRole2=>(ServerRole2.MODEL="model",ServerRole2.ROUTER="router",ServerRole2))(ServerRole||{}),ServerModelStatus=(ServerModelStatus2=>(ServerModelStatus2.UNLOADED="unloaded",ServerModelStatus2.LOADING="loading",ServerModelStatus2.LOADED="loaded",ServerModelStatus2.SLEEPING="sleeping",ServerModelStatus2.
|
|
|
|
|
FAILED="failed",ServerModelStatus2))(ServerModelStatus||{}),ParameterSource=(ParameterSource2=>(ParameterSource2.DEFAULT="default",ParameterSource2.CUSTOM="custom",ParameterSource2))(ParameterSource||{}),SyncableParameterType=(SyncableParameterType2=>(SyncableParameterType2.NUMBER="number",SyncableParameterType2.STRING="string",SyncableParameterType2.BOOLEAN="boolean",SyncableParameterType2))(SyncableParameterType||{}),SettingsFieldType=(SettingsFieldType2=>(SettingsFieldType2.INPUT="input",SettingsFieldType2.
|
|
|
|
|
TEXTAREA="textarea",SettingsFieldType2.CHECKBOX="checkbox",SettingsFieldType2.SELECT="select",SettingsFieldType2))(SettingsFieldType||{}),ColorMode=(ColorMode2=>(ColorMode2.LIGHT="light",ColorMode2.DARK="dark",ColorMode2.SYSTEM="system",ColorMode2))(ColorMode||{}),TooltipSide=(TooltipSide2=>(TooltipSide2.TOP="top",TooltipSide2.RIGHT="right",TooltipSide2.BOTTOM="bottom",TooltipSide2.LEFT="left",TooltipSide2))(TooltipSide||{}),McpPromptVariant=(McpPromptVariant2=>(McpPromptVariant2.MESSAGE="messag\
|
|
|
|
|
e",McpPromptVariant2.ATTACHMENT="attachment",McpPromptVariant2))(McpPromptVariant||{}),UrlProtocol=(UrlProtocol2=>(UrlProtocol2.DATA="data:",UrlProtocol2.HTTP="http:",UrlProtocol2.HTTPS="https:",UrlProtocol2.WEBSOCKET="ws:",UrlProtocol2.WEBSOCKET_SECURE="wss:",UrlProtocol2))(UrlProtocol||{}),HtmlInputType=(HtmlInputType2=>(HtmlInputType2.FILE="file",HtmlInputType2))(HtmlInputType||{}),KeyboardKey=(KeyboardKey2=>(KeyboardKey2.ENTER="Enter",KeyboardKey2.ESCAPE="Escape",KeyboardKey2.ARROW_UP="Arrow\
|
|
|
|
|
Up",KeyboardKey2.ARROW_DOWN="ArrowDown",KeyboardKey2.ARROW_LEFT="ArrowLeft",KeyboardKey2.ARROW_RIGHT="ArrowRight",KeyboardKey2.TAB="Tab",KeyboardKey2.D_LOWER="d",KeyboardKey2.D_UPPER="D",KeyboardKey2.E_UPPER="E",KeyboardKey2.K_LOWER="k",KeyboardKey2.O_LOWER="o",KeyboardKey2.O_UPPER="O",KeyboardKey2.SPACE=" ",KeyboardKey2))(KeyboardKey||{}),ToolSource=(ToolSource2=>(ToolSource2.BUILTIN="builtin",ToolSource2.MCP="mcp",ToolSource2.CUSTOM="custom",ToolSource2))(ToolSource||{}),ToolPermissionDecision=(ToolPermissionDecision2=>(ToolPermissionDecision2.
|
|
|
|
|
ALWAYS="always",ToolPermissionDecision2.ALWAYS_SERVER="always_server",ToolPermissionDecision2.ONCE="once",ToolPermissionDecision2.DENY="deny",ToolPermissionDecision2))(ToolPermissionDecision||{}),ToolResponseField=(ToolResponseField2=>(ToolResponseField2.PLAIN_TEXT="plain_text_response",ToolResponseField2.ERROR="error",ToolResponseField2))(ToolResponseField||{}),root_5$w=from_html("<p> </p>"),root_1$17=from_html("<!> <!>",1);function ActionIcon($$anchor,$$props){push$1($$props,!0);let variant=prop(
|
|
|
|
|
$$props,"variant",3,"ghost"),size2=prop($$props,"size",3,"sm"),className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),iconSize=prop($$props,"iconSize",3,"h-3 w-3"),tooltipSide=prop($$props,"tooltipSide",19,()=>TooltipSide.TOP),stopPropagationOnClick=prop($$props,"stopPropagationOnClick",3,!1);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Root$5,($$anchor2,Tooltip_Root)=>{Tooltip_Root($$anchor2,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$17(),
|
|
|
|
|
node_1=first_child(fragment_1);component(node_1,()=>Tooltip_trigger,($$anchor4,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor4,{children:($$anchor5,$$slotProps2)=>{{let $0=user_derived(()=>$$props.ariaLabel||$$props.tooltip);Button($$anchor5,{get variant(){return variant()},get size(){return size2()},get disabled(){return disabled()},onclick:e=>{stopPropagationOnClick()&&e.stopPropagation(),$$props.onclick?.(e)},get class(){return`h-6 w-6 p-0 ${className()??""} flex hover:bg-transparent data-[state\
|
|
|
|
|
=open]:bg-transparent!`},get"aria-label"(){return get$3($0)},children:($$anchor6,$$slotProps3)=>{var fragment_3=comment$2(),node_2=first_child(fragment_3);{var consequent=$$anchor7=>{const IconComponent=user_derived(()=>$$props.icon);var fragment_4=comment$2(),node_3=first_child(fragment_4);component(node_3,()=>get$3(IconComponent),($$anchor8,IconComponent_1)=>{IconComponent_1($$anchor8,{get class(){return iconSize()}})}),append($$anchor7,fragment_4)};if_block(node_2,$$render=>{$$props.icon&&$$render(
|
|
|
|
|
consequent)})}append($$anchor6,fragment_3)},$$slots:{default:!0}})}},$$slots:{default:!0}})});var node_4=sibling(node_1,2);component(node_4,()=>Tooltip_content,($$anchor4,Tooltip_Content)=>{Tooltip_Content($$anchor4,{get side(){return tooltipSide()},children:($$anchor5,$$slotProps2)=>{var p2=root_5$w(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,$$props.tooltip)),append($$anchor5,p2)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,
|
|
|
|
|
fragment),pop()}const defaultAttributes={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"};var root$1T=from_svg("<svg><!><!></svg>");function Icon($$anchor,$$props){push$1($$props,!0);const color=prop($$props,"color",3,"currentColor"),size2=prop($$props,"size",3,24),strokeWidth=prop($$props,"strokeWidth",3,2),absoluteStrokeWidth=prop($$props,"absoluteStrokeWidth",3,!1),iconNode=prop(
|
|
|
|
|
$$props,"iconNode",19,()=>[]),props=rest_props($$props,["$$slots","$$events","$$legacy","name","color","size","strokeWidth","absoluteStrokeWidth","iconNode","children"]);var svg2=root$1T();attribute_effect(svg2,$0=>({...defaultAttributes,...props,width:size2(),height:size2(),stroke:color(),"stroke-width":$0,class:["lucide-icon lucide",$$props.name&&`lucide-${$$props.name}`,$$props.class]}),[()=>absoluteStrokeWidth()?Number(strokeWidth())*24/Number(size2()):strokeWidth()]);var node2=child(svg2);each(
|
|
|
|
|
node2,17,iconNode,index$2,($$anchor2,$$item)=>{var $$array=user_derived(()=>to_array(get$3($$item),2));let tag=()=>get$3($$array)[0],attrs=()=>get$3($$array)[1];var fragment=comment$2(),node_1=first_child(fragment);element$4(node_1,tag,!0,($$element,$$anchor3)=>{attribute_effect($$element,()=>({...attrs()}))}),append($$anchor2,fragment)});var node_2=sibling(node2);snippet(node_2,()=>$$props.children??noop$3),reset(svg2),append($$anchor,svg2),pop()}function Arrow_big_up($$anchor,$$props){push$1($$props,
|
|
|
|
|
!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M9 18v-6H5l7-7 7 7h-4v6H9z"}]];Icon($$anchor,spread_props({name:"arrow-big-up"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Arrow_right($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,
|
|
|
|
|
["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M5 12h14"}],["path",{d:"m12 5 7 7-7 7"}]];Icon($$anchor,spread_props({name:"arrow-right"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Arrow_up($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$\
|
|
|
|
|
$legacy"]);const iconNode=[["path",{d:"m5 12 7-7 7 7"}],["path",{d:"M12 19V5"}]];Icon($$anchor,spread_props({name:"arrow-up"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Book_open_text($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["path",{d:"M12 7v14"}],["path",{d:"M16 12h2"}],["path",{d:"M16 8h2"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z"}],["path",{d:"M6 12h2"}],["path",{d:"M6 8h2"}]];Icon($$anchor,spread_props({name:"book-open-text"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append(
|
|
|
|
|
$$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Braces($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1"}],["path",{d:"M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1"}]];Icon($$anchor,spread_props({name:"braces"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Brain($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3\
|
|
|
|
|
-4 4.5 4.5 0 0 1-3 4"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18"}]];Icon($$anchor,spread_props({name:"brain"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Check($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M20 6 9 17l-5-5"}]];Icon($$anchor,spread_props({name:"check"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{
|
|
|
|
|
default:!0}})),pop()}function Chevron_down($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m6 9 6 6 6-6"}]];Icon($$anchor,spread_props({name:"chevron-down"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_left($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m15 18-6-6 6-6"}]];Icon($$anchor,spread_props({name:"chevron-left"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_up($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,
|
|
|
|
|
["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m18 15-6-6-6 6"}]];Icon($$anchor,spread_props({name:"chevron-up"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevron_right($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["path",{d:"m9 18 6-6-6-6"}]];Icon($$anchor,spread_props({name:"chevron-right"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Chevrons_up_down($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m7 15 5 5 5-5"}],["path",{
|
|
|
|
|
d:"m7 9 5-5 5 5"}]];Icon($$anchor,spread_props({name:"chevrons-up-down"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Circle_alert($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["line",{x1:"\
|
|
|
|
|
12",x2:"12",y1:"8",y2:"12"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16"}]];Icon($$anchor,spread_props({name:"circle-alert"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Circle_check_big($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["path",{d:"M21.801 10A10 10 0 1 1 17 3.335"}],["path",{d:"m9 11 3 3L22 4"}]];Icon($$anchor,spread_props({name:"circle-check-big"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Circle_x($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"m15 9-6 6"}],["path",{d:"m9 9 6 6"}]];Icon($$anchor,spread_props({name:"circle-x"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Clock($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["circle",{cx:"12",cy:"12",r:"10"}],["polyline",{points:"12 6 12 12 16 14"}]];Icon($$anchor,spread_props({name:"clock"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Code($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"\
|
|
|
|
|
m16 18 6-6-6-6"}],["path",{d:"m8 6-6 6 6 6"}]];Icon($$anchor,spread_props({name:"code"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Copy($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"14",height:"14",x:"8",y:"8",
|
|
|
|
|
rx:"2",ry:"2"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2"}]];Icon($$anchor,spread_props({name:"copy"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Database($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5"}],["path",{d:"M3 12A9 3 0 0 0 21 12"}]];Icon($$anchor,spread_props({name:"database"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Download($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots",
|
|
|
|
|
"$$events","$$legacy"]);const iconNode=[["path",{d:"M12 15V3"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}],["path",{d:"m7 10 5 5 5-5"}]];Icon($$anchor,spread_props({name:"download"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Ellipsis($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"1"}],["circle",{cx:"19",cy:"12",r:"1"}],["circle",{cx:"5",cy:"12",r:"1"}]];Icon($$anchor,spread_props({name:"ellipsis"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function External_link($$anchor,$$props){push$1($$props,
|
|
|
|
|
!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 3h6v6"}],["path",{d:"M10 14 21 3"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"}]];Icon($$anchor,spread_props({name:"external-link"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Eye($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"}],["circle",{cx:"12",cy:"12",r:"3"}]];Icon($$anchor,spread_props({name:"eye"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},
|
|
|
|
|
$$slots:{default:!0}})),pop()}function File_text($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}],["path",{d:"M10 9H8"}],["path",{d:"M16 13H8"}],["path",{d:"M16 17H8"}]];Icon($$anchor,spread_props({name:"file-text"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function File_x($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}],["path",{d:"m14.5 12.5-5 5"}],["path",{d:"m9.5 12.5 5 5"}]];Icon($$anchor,spread_props({name:"file-x"},()=>props,{get iconNode(){
|
|
|
|
|
return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function File$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4"}]];Icon($$anchor,spread_props({name:"file"},
|
|
|
|
|
()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Flask_conical($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2"}],["\
|
|
|
|
|
path",{d:"M6.453 15h11.094"}],["path",{d:"M8.5 2h7"}]];Icon($$anchor,spread_props({name:"flask-conical"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Folder_open($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m6 14 \
|
|
|
|
|
1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2"}]];Icon($$anchor,spread_props({name:"folder-open"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Funnel($$anchor,$$props){push$1(
|
|
|
|
|
$$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z"}]];Icon($$anchor,spread_props({name:"funnel"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},
|
|
|
|
|
$$slots:{default:!0}})),pop()}function Gauge($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m12 14 4-4"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0"}]];Icon($$anchor,spread_props({name:"gauge"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),
|
|
|
|
|
pop()}function Git_branch($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["line",{x1:"6",x2:"6",y1:"3",y2:"15"}],["circle",{cx:"18",cy:"6",r:"3"}],["circle",{cx:"6",cy:"18",r:"3"}],["path",{d:"M18 9a9 9 0 0 1-9 9"}]];Icon($$anchor,spread_props({name:"git-branch"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??
|
|
|
|
|
noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Globe($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20"}],["path",{d:"M2 12h20"}]];Icon($$anchor,spread_props({name:"globe"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);
|
|
|
|
|
snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Heart_off($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["line",{x1:"2",y1:"2",x2:"22",y2:"22"}],["path",{d:"M16.5 16.5 12 21l-7-7c-1.5-1.45-3-3.2-3-5.5a5.5 5.5 0 0 1 2.14-4.35"}],["path",{d:"M8.76 3.1c1.15.22 2.13.78 3.24 1.9 1.5-1.5 2.74-2 4.5-2A5.5 5.5 0 0 1 22 8.5c0 2.12-1.3 3.78-2.67 5.17"}]];Icon($$anchor,spread_props(
|
|
|
|
|
{name:"heart-off"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Heart($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5\
|
|
|
|
|
0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z"}]];Icon($$anchor,spread_props({name:"heart"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Image$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",
|
|
|
|
|
rx:"2",ry:"2"}],["circle",{cx:"9",cy:"9",r:"2"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21"}]];Icon($$anchor,spread_props({name:"image"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Info$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legac\
|
|
|
|
|
y"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"10"}],["path",{d:"M12 16v-4"}],["path",{d:"M12 8h.01"}]];Icon($$anchor,spread_props({name:"info"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Key($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);
|
|
|
|
|
const iconNode=[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4"}],["path",{d:"m21 2-9.6 9.6"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5"}]];Icon($$anchor,spread_props({name:"key"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Layers($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17"}]];Icon($$anchor,spread_props({name:"layers"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function List_checks($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m3 17 2 2 4-4"}],["path",{d:"m3 7 2 2 4-4"}],["path",{d:"M13 6h8"}],["path",{d:"M13 12h8"}],["path",{d:"M13 18h8"}]];Icon($$anchor,spread_props({name:"list-checks"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function List_restart($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 6H3"}],["path",{d:"M7 12H3"}],["path",{d:"M7 18H3"}],["path",{d:"M12 18a5 5 0 0 0 9-3 4.5 4.5 0 0 0-4.5-4.5c-1.33 0-2.54.54-3.41 1.41L11 14"}],["path",{d:"M11 10v4h4"}]];Icon($$anchor,
|
|
|
|
|
spread_props({name:"list-restart"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Loader_circle($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56"}]];Icon($$anchor,spread_props({name:"loader-c\
|
|
|
|
|
ircle"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Message_square($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"}]];Icon($$anchor,spread_props({name:"\
|
|
|
|
|
message-square"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Mic($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z"}],["path",{d:"M19 10v2a7 7 0 0 1-14 0v-2"}],["li\
|
|
|
|
|
ne",{x1:"12",x2:"12",y1:"19",y2:"22"}]];Icon($$anchor,spread_props({name:"mic"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Minus($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M5 12h14"}]];Icon($$anchor,spread_props(
|
|
|
|
|
{name:"minus"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Monitor($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21"}],["line",{x1:"12",
|
|
|
|
|
x2:"12",y1:"17",y2:"21"}]];Icon($$anchor,spread_props({name:"monitor"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Moon($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z"}]];Icon($$anchor,
|
|
|
|
|
spread_props({name:"moon"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Music($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M9 18V5l12-2v13"}],["circle",{cx:"6",cy:"18",r:"3"}],["circle",{cx:"18",cy:"16",r:"3"}]];Icon(
|
|
|
|
|
$$anchor,spread_props({name:"music"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Package($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-\
|
|
|
|
|
2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z"}],["path",{d:"M12 22V12"}],["polyline",{points:"3.29 7 12 12 20.71 7"}],["path",{d:"m7.5 4.27 9 5.15"}]];Icon($$anchor,spread_props({name:"package"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Panel_left_close($$anchor,$$props){push$1($$props,!0);let props=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M9 3v18"}],["path",{d:"m16 15-3-3 3-3"}]];Icon($$anchor,spread_props({name:"panel-left-close"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Panel_left($$anchor,$$props){push$1(
|
|
|
|
|
$$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}],["path",{d:"M9 3v18"}]];Icon($$anchor,spread_props({name:"panel-left"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Pencil_ruler($$anchor,$$props){push$1(
|
|
|
|
|
$$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M13 7 8.7 2.7a2.41 2.41 0 0 0-3.4 0L2.7 5.3a2.41 2.41 0 0 0 0 3.4L7 13"}],["path",{d:"m8 6 2-2"}],["path",{d:"m18 16 2-2"}],["path",{d:"m17 11 4.3 4.3c.94.94.94 2.46 0 3.4l-2.6 2.6c-.94.94-2.46.94-3.4 0L11 17"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"}],["path",{d:"m15 5 4 4"}]];Icon($$anchor,
|
|
|
|
|
spread_props({name:"pencil-ruler"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Pencil($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.\
|
|
|
|
|
5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z"}],["path",{d:"m15 5 4 4"}]];Icon($$anchor,spread_props({name:"pencil"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Plus($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"\
|
|
|
|
|
M5 12h14"}],["path",{d:"M12 5v14"}]];Icon($$anchor,spread_props({name:"plus"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Power_off($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M18.36 6.64A9 9 0 0 1 20.77 15"}],[
|
|
|
|
|
"path",{d:"M6.16 6.16a9 9 0 1 0 12.68 12.68"}],["path",{d:"M12 2v4"}],["path",{d:"m2 2 20 20"}]];Icon($$anchor,spread_props({name:"power-off"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Power($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[
|
|
|
|
|
["path",{d:"M12 2v10"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04"}]];Icon($$anchor,spread_props({name:"power"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Radio($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M4.9 1\
|
|
|
|
|
9.1C1 15.2 1 8.8 4.9 4.9"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5"}],["circle",{cx:"12",cy:"12",r:"2"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19"}]];Icon($$anchor,spread_props({name:"radio"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Refresh_cw($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8"}],["path",{d:"M21 3v5h-5"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16"}],["path",{d:"M8 16H3v5"}]];Icon($$anchor,spread_props({name:"refresh-cw"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??
|
|
|
|
|
noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Rotate_ccw($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}],["path",{d:"M3 3v5h5"}]];Icon($$anchor,spread_props({name:"rotate-ccw"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Rotate_cw($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8"}],["path",{d:"M21 3v5h-5"}]];Icon($$anchor,spread_props({name:"rotate-cw"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,
|
|
|
|
|
()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Search($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m21 21-4.34-4.34"}],["circle",{cx:"11",cy:"11",r:"8"}]];Icon($$anchor,spread_props({name:"search"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??
|
|
|
|
|
noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Server($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18"}]];Icon($$anchor,spread_props({name:"server"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Settings$1($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73\
|
|
|
|
|
2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"}],["circle",{cx:"12",cy:"12",r:"3"}]];Icon($$anchor,spread_props({name:"settings"},()=>props,{get iconNode(){return iconNode},
|
|
|
|
|
children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Shield_question($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 \
|
|
|
|
|
1 0 0 1 1 1z"}],["path",{d:"M9.1 9a3 3 0 0 1 5.82 1c0 2-3 3-3 3"}],["path",{d:"M12 17h.01"}]];Icon($$anchor,spread_props({name:"shield-question"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Sliders_vertical($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","\
|
|
|
|
|
$$legacy"]);const iconNode=[["line",{x1:"4",x2:"4",y1:"21",y2:"14"}],["line",{x1:"4",x2:"4",y1:"10",y2:"3"}],["line",{x1:"12",x2:"12",y1:"21",y2:"12"}],["line",{x1:"12",x2:"12",y1:"8",y2:"3"}],["line",{x1:"20",x2:"20",y1:"21",y2:"16"}],["line",{x1:"20",x2:"20",y1:"12",y2:"3"}],["line",{x1:"2",x2:"6",y1:"14",y2:"14"}],["line",{x1:"10",x2:"14",y1:"8",y2:"8"}],["line",{x1:"18",x2:"22",y1:"16",y2:"16"}]];Icon($$anchor,spread_props({name:"sliders-vertical"},()=>props,{get iconNode(){return iconNode},
|
|
|
|
|
children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Sparkles($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6\
|
|
|
|
|
.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z"}],["path",{d:"M20 3v4"}],["path",{d:"M22 5h-4"}],["path",{d:"M4 17v2"}],["path",{d:"M5 18H3"}]];Icon($$anchor,spread_props({name:"sparkles"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Square_pen($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z"}]];Icon($$anchor,spread_props({name:"square-pen"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,
|
|
|
|
|
()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Square($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2"}]];Icon($$anchor,spread_props({name:"square"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append(
|
|
|
|
|
$$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Sun($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"12",cy:"12",r:"4"}],["path",{d:"M12 2v2"}],["path",{d:"M12 20v2"}],["path",{d:"m4.93 4.93 1.41 1.41"}],["path",{d:"m17.66 17.66 1.41 1.41"}],["path",{d:"M2 12h2"}],["path",{d:"M20 12h2"}],["path",{d:"m6.34 17.66-1.41 1.41"}],["path",{d:"m19.07 4.93-1.41 1.41"}]];Icon($$anchor,spread_props({name:"sun"},
|
|
|
|
|
()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Timer_off($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M10 2h4"}],["path",{d:"M4.6 11a8 8 0 0 0 1.7 8.7 8 8 0 0 0 8.7 1.7"}],["path",{d:"M7.4 7.4a8 8 0 0 1 10.3 1 8 8 0\
|
|
|
|
|
0 1 .9 10.2"}],["path",{d:"m2 2 20 20"}],["path",{d:"M12 12v-2"}]];Icon($$anchor,spread_props({name:"timer-off"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Trash_2($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M\
|
|
|
|
|
3 6h18"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17"}]];Icon($$anchor,spread_props({name:"trash-2"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Triangle_alert($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"}],["path",{d:"M12 9v4"}],["path",{d:"M12 17h.01"}]];Icon($$anchor,spread_props({name:"triangle-alert"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{
|
|
|
|
|
default:!0}})),pop()}function Upload($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M12 3v12"}],["path",{d:"m17 8-5-5-5 5"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"}]];Icon($$anchor,spread_props({name:"upload"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,
|
|
|
|
|
fragment_1)},$$slots:{default:!0}})),pop()}function Whole_word($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["circle",{cx:"7",cy:"12",r:"3"}],["path",{d:"M10 9v6"}],["circle",{cx:"17",cy:"12",r:"3"}],["path",{d:"M14 7v8"}],["path",{d:"M22 17v1c0 .5-.5 1-1 1H3c-.5 0-1-.5-1-1v-1"}]];Icon($$anchor,spread_props({name:"whole-word"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),
|
|
|
|
|
node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Wrench($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z"}]];Icon($$anchor,spread_props({name:"wrench"},()=>props,{get iconNode(){
|
|
|
|
|
return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function X($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M18 6 6 18"}],["path",{d:"m6 6 12 12"}]];Icon($$anchor,spread_props({name:"x"},()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Zap($$anchor,$$props){push$1($$props,!0);let props=rest_props($$props,["$$slots","$$events","$$legacy"]);const iconNode=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z"}]];Icon($$anchor,spread_props({name:"zap"},
|
|
|
|
|
()=>props,{get iconNode(){return iconNode},children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);snippet(node2,()=>$$props.children??noop$3),append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}const ATTACHMENT_SAVED_REGEX=/\[Attachment saved: ([^\]]+)\]/,NEWLINE_SEPARATOR=`
|
|
|
|
|
`,LLM_ERROR_BLOCK_START=`
|
|
|
|
|
|
|
|
|
|
\`\`\`
|
|
|
|
|
@@ -5163,98 +5163,98 @@ lastIndexOf(".");if(dotIdx!==MODEL_ID_NOT_FOUND&&!result.quantization){const aft
|
|
|
|
|
test(secondLast)?(result.quantization=`${secondLast}-${last}`,segments.splice(segments.length-2,2)):(result.quantization=last,segments.pop()))}let paramsIdx=MODEL_ID_NOT_FOUND,activatedParamsIdx=MODEL_ID_NOT_FOUND;for(let i=0;i<segments.length;i++){const seg=segments[i];paramsIdx===MODEL_ID_NOT_FOUND&&MODEL_PARAMS_RE.test(seg)?(paramsIdx=i,result.params=seg.toUpperCase()):paramsIdx!==MODEL_ID_NOT_FOUND&&MODEL_ACTIVATED_PARAMS_RE.test(seg)&&(activatedParamsIdx=i,result.activatedParams=seg.toUpperCase())}
|
|
|
|
|
const pivotIdx=paramsIdx!==MODEL_ID_NOT_FOUND?paramsIdx:segments.length;return result.modelName=segments.slice(0,pivotIdx).join(MODEL_ID_SEGMENT_SEPARATOR)||null,paramsIdx!==MODEL_ID_NOT_FOUND&&(result.tags=segments.slice(paramsIdx+1).filter((_,relIdx)=>{const absIdx=paramsIdx+1+relIdx;return absIdx===activatedParamsIdx?!1:!MODEL_IGNORED_SEGMENTS.has(segments[absIdx].toUpperCase())})),result}}class ModelsStore{#models=state$1(proxy([]));get models(){return get$3(this.#models)}set models(value){set$1(
|
|
|
|
|
this.#models,value,!0)}#routerModels=state$1(proxy([]));get routerModels(){return get$3(this.#routerModels)}set routerModels(value){set$1(this.#routerModels,value,!0)}#loading=state$1(!1);get loading(){return get$3(this.#loading)}set loading(value){set$1(this.#loading,value,!0)}#updating=state$1(!1);get updating(){return get$3(this.#updating)}set updating(value){set$1(this.#updating,value,!0)}#error=state$1(null);get error(){return get$3(this.#error)}set error(value){set$1(this.#error,value,!0)}#selectedModelId=state$1(
|
|
|
|
|
null);get selectedModelId(){return get$3(this.#selectedModelId)}set selectedModelId(value){set$1(this.#selectedModelId,value,!0)}#selectedModelName=state$1(null);get selectedModelName(){return get$3(this.#selectedModelName)}set selectedModelName(value){set$1(this.#selectedModelName,value,!0)}#modelUsage=state$1(proxy(new Map));get modelUsage(){return get$3(this.#modelUsage)}set modelUsage(value){set$1(this.#modelUsage,value,!0)}modelLoadingStates=new SvelteMap;#favoriteModelIds=state$1(proxy(this.
|
|
|
|
|
loadFavoritesFromStorage()));get favoriteModelIds(){return get$3(this.#favoriteModelIds)}set favoriteModelIds(value){set$1(this.#favoriteModelIds,value,!0)}modelPropsCache=new TTLCache({ttlMs:MODEL_PROPS_CACHE_TTL_MS,maxEntries:MODEL_PROPS_CACHE_MAX_ENTRIES});#modelPropsFetching=state$1(proxy(new Set));get modelPropsFetching(){return get$3(this.#modelPropsFetching)}set modelPropsFetching(value){set$1(this.#modelPropsFetching,value,!0)}#propsCacheVersion=state$1(0);get propsCacheVersion(){return get$3(
|
|
|
|
|
this.#propsCacheVersion)}set propsCacheVersion(value){set$1(this.#propsCacheVersion,value,!0)}get selectedModel(){return this.selectedModelId?this.models.find(model=>model.id===this.selectedModelId)??null:null}get loadedModelIds(){return this.routerModels.filter(m=>m.status.value===ServerModelStatus.LOADED||m.status.value===ServerModelStatus.SLEEPING).map(m=>m.id)}get loadingModelIds(){return Array.from(this.modelLoadingStates.entries()).filter(([,loading])=>loading).map(([id2])=>id2)}get singleModelName(){
|
|
|
|
|
null);get selectedModelId(){return get$3(this.#selectedModelId)}set selectedModelId(value){set$1(this.#selectedModelId,value,!0)}#selectedModelName=state$1(null);get selectedModelName(){return get$3(this.#selectedModelName)}set selectedModelName(value){set$1(this.#selectedModelName,value,!0)}inflightFetch=null;#modelUsage=state$1(proxy(new Map));get modelUsage(){return get$3(this.#modelUsage)}set modelUsage(value){set$1(this.#modelUsage,value,!0)}modelLoadingStates=new SvelteMap;#favoriteModelIds=state$1(
|
|
|
|
|
proxy(this.loadFavoritesFromStorage()));get favoriteModelIds(){return get$3(this.#favoriteModelIds)}set favoriteModelIds(value){set$1(this.#favoriteModelIds,value,!0)}modelPropsCache=new TTLCache({ttlMs:MODEL_PROPS_CACHE_TTL_MS,maxEntries:MODEL_PROPS_CACHE_MAX_ENTRIES});#modelPropsFetching=state$1(proxy(new Set));get modelPropsFetching(){return get$3(this.#modelPropsFetching)}set modelPropsFetching(value){set$1(this.#modelPropsFetching,value,!0)}#propsCacheVersion=state$1(0);get propsCacheVersion(){
|
|
|
|
|
return get$3(this.#propsCacheVersion)}set propsCacheVersion(value){set$1(this.#propsCacheVersion,value,!0)}get selectedModel(){return this.selectedModelId?this.models.find(model=>model.id===this.selectedModelId)??null:null}get loadedModelIds(){return this.routerModels.filter(m=>m.status.value===ServerModelStatus.LOADED||m.status.value===ServerModelStatus.SLEEPING).map(m=>m.id)}get loadingModelIds(){return Array.from(this.modelLoadingStates.entries()).filter(([,loading])=>loading).map(([id2])=>id2)}get singleModelName(){
|
|
|
|
|
if(serverStore.isRouterMode)return null;const props=serverStore.props;return props?.model_alias?props.model_alias:props?.model_path&&props.model_path.split(/(\\|\/)/).pop()||null}getModelModalities(modelId){const model=this.models.find(m=>m.model===modelId||m.id===modelId);if(model?.modalities)return model.modalities;const props=this.modelPropsCache.get(modelId);return props?.modalities?{vision:props.modalities.vision??!1,audio:props.modalities.audio??!1}:null}modelSupportsVision(modelId){return this.
|
|
|
|
|
getModelModalities(modelId)?.vision??!1}modelSupportsAudio(modelId){return this.getModelModalities(modelId)?.audio??!1}getModelModalitiesArray(modelId){const modalities=this.getModelModalities(modelId);if(!modalities)return[];const result=[];return modalities.vision&&result.push(ModelModality.VISION),modalities.audio&&result.push(ModelModality.AUDIO),result}getModelProps(modelId){return this.modelPropsCache.get(modelId)}getModelContextSize(modelId){const nCtx=this.getModelProps(modelId)?.default_generation_settings?.
|
|
|
|
|
n_ctx;return typeof nCtx=="number"?nCtx:null}get selectedModelContextSize(){return this.selectedModelName?this.getModelContextSize(this.selectedModelName):null}isModelPropsFetching(modelId){return this.modelPropsFetching.has(modelId)}isModelLoaded(modelId){const model=this.routerModels.find(m=>m.id===modelId);return model?.status.value===ServerModelStatus.LOADED||model?.status.value===ServerModelStatus.SLEEPING||!1}isModelOperationInProgress(modelId){return this.modelLoadingStates.get(modelId)??
|
|
|
|
|
!1}getModelStatus(modelId){return this.routerModels.find(m=>m.id===modelId)?.status.value??null}getModelUsage(modelId){return this.modelUsage.get(modelId)??new SvelteSet}isModelInUse(modelId){const usage=this.modelUsage.get(modelId);return usage!==void 0&&usage.size>0}async fetch(force=!1){if(!this.loading&&!(this.models.length>0&&!force)){this.loading=!0,this.error=null;try{serverStore.props||await serverStore.fetch();const response=await ModelsService.list(),models=response.data.map((item,index2)=>{
|
|
|
|
|
const details=response.models?.[index2],rawCapabilities=Array.isArray(details?.capabilities)?details?.capabilities:[],displayNameSource=details?.name&&details.name.trim().length>0?details.name:item.id,displayName=this.toDisplayName(displayNameSource),modelId=details?.model||item.id;return{id:item.id,name:displayName,model:modelId,description:details?.description,capabilities:rawCapabilities.filter(value=>!!value),details:details?.details,meta:item.meta??null,parsedId:ModelsService.parseModelId(modelId),
|
|
|
|
|
aliases:item.aliases??[],tags:item.tags??[]}});this.models=models;const serverProps2=serverStore.props;if(serverStore.isModelMode&&this.models.length>0&&serverProps2?.modalities){const modalities={vision:serverProps2.modalities.vision??!1,audio:serverProps2.modalities.audio??!1};this.modelPropsCache.set(this.models[0].model,serverProps2),this.models=this.models.map((model,index2)=>index2===0?{...model,modalities}:model)}}catch(error2){throw this.models=[],this.error=error2 instanceof Error?error2.
|
|
|
|
|
message:"Failed to load models",error2}finally{this.loading=!1}}}async fetchRouterModels(){try{const response=await ModelsService.listRouter();this.routerModels=response.data,await this.fetchModalitiesForLoadedModels();const o=this.models.filter(option2=>this.getModelProps(option2.model)?.webui!==!1);o.length===1&&this.isModelLoaded(o[0].model)&&this.selectModelById(o[0].id)}catch(error2){console.warn("Failed to fetch router models:",error2),this.routerModels=[]}}async fetchModelProps(modelId){const cached2=this.
|
|
|
|
|
modelPropsCache.get(modelId);if(cached2)return cached2;if(serverStore.isRouterMode&&!this.isModelLoaded(modelId)||this.modelPropsFetching.has(modelId))return null;this.modelPropsFetching.add(modelId);try{const props=await PropsService.fetchForModel(modelId);return this.modelPropsCache.set(modelId,props),props}catch(error2){return console.warn(`Failed to fetch props for model ${modelId}:`,error2),null}finally{this.modelPropsFetching.delete(modelId)}}async fetchModalitiesForLoadedModels(){const loadedModelIds2=this.
|
|
|
|
|
loadedModelIds;if(loadedModelIds2.length===0)return;const propsPromises=loadedModelIds2.map(modelId=>this.fetchModelProps(modelId));try{const results=await Promise.all(propsPromises);this.models=this.models.map(model=>{const modelIndex=loadedModelIds2.indexOf(model.model);if(modelIndex===-1)return model;const props=results[modelIndex];if(!props?.modalities)return model;const modalities={vision:props.modalities.vision??!1,audio:props.modalities.audio??!1};return{...model,modalities}}),this.propsCacheVersion++}catch(error2){
|
|
|
|
|
console.warn("Failed to fetch modalities for loaded models:",error2)}}async updateModelModalities(modelId){try{const props=await this.fetchModelProps(modelId);if(!props?.modalities)return;const modalities={vision:props.modalities.vision??!1,audio:props.modalities.audio??!1};this.models=this.models.map(model=>model.model===modelId?{...model,modalities}:model),this.propsCacheVersion++}catch(error2){console.warn(`Failed to update modalities for model ${modelId}:`,error2)}}async selectModelById(modelId){
|
|
|
|
|
if(!modelId||this.updating||this.selectedModelId===modelId)return;const option2=this.models.find(model=>model.id===modelId);if(!option2)throw new Error("Selected model is not available");this.updating=!0,this.error=null;try{this.selectedModelId=option2.id,this.selectedModelName=option2.model}finally{this.updating=!1}}selectModelByName(modelName){const option2=this.models.find(model=>model.model===modelName);option2&&(this.selectedModelId=option2.id,this.selectedModelName=option2.model)}clearSelection(){
|
|
|
|
|
this.selectedModelId=null,this.selectedModelName=null}findModelByName(modelName){return this.models.find(model=>model.model===modelName)??null}findModelById(modelId){return this.models.find(model=>model.id===modelId)??null}hasModel(modelName){return this.models.some(model=>model.model===modelName)}static STATUS_POLL_INTERVAL=500;async pollForModelStatus(modelId,expectedStatus){let attempt=0;for(;;){await this.fetchRouterModels();const currentStatus=this.getModelStatus(modelId);if(currentStatus===
|
|
|
|
|
expectedStatus)return;if(currentStatus===ServerModelStatus.FAILED)throw new Error(`Model failed to ${expectedStatus===ServerModelStatus.LOADED?"load":"unload"}`);if(expectedStatus===ServerModelStatus.LOADED&¤tStatus===ServerModelStatus.UNLOADED&&attempt>2)throw new Error("Model was unloaded unexpectedly during loading");attempt++,await new Promise(resolve2=>setTimeout(resolve2,ModelsStore.STATUS_POLL_INTERVAL))}}async loadModel(modelId){if(!this.isModelLoaded(modelId)&&!this.modelLoadingStates.
|
|
|
|
|
get(modelId)){this.modelLoadingStates.set(modelId,!0),this.error=null;try{await ModelsService.load(modelId),await this.pollForModelStatus(modelId,ServerModelStatus.LOADED),await this.updateModelModalities(modelId),toast.success(`Model loaded: ${this.toDisplayName(modelId)}`)}catch(error2){throw this.error=error2 instanceof Error?error2.message:"Failed to load model",toast.error(`Failed to load model: ${this.toDisplayName(modelId)}`),error2}finally{this.modelLoadingStates.set(modelId,!1)}}}async unloadModel(modelId){
|
|
|
|
|
if(this.isModelLoaded(modelId)&&!this.modelLoadingStates.get(modelId)){this.modelLoadingStates.set(modelId,!0),this.error=null;try{await ModelsService.unload(modelId),await this.pollForModelStatus(modelId,ServerModelStatus.UNLOADED),toast.info(`Model unloaded: ${this.toDisplayName(modelId)}`)}catch(error2){throw this.error=error2 instanceof Error?error2.message:"Failed to unload model",toast.error(`Failed to unload model: ${this.toDisplayName(modelId)}`),error2}finally{this.modelLoadingStates.set(
|
|
|
|
|
modelId,!1)}}}async ensureModelLoaded(modelId){this.isModelLoaded(modelId)||await this.loadModel(modelId)}isFavorite(modelId){return this.favoriteModelIds.has(modelId)}toggleFavorite(modelId){const next2=new SvelteSet(this.favoriteModelIds);next2.has(modelId)?next2.delete(modelId):next2.add(modelId),this.favoriteModelIds=next2;try{localStorage.setItem(FAVORITE_MODELS_LOCALSTORAGE_KEY,JSON.stringify([...next2]))}catch{toast.error("Failed to save favorite models to local storage")}}loadFavoritesFromStorage(){
|
|
|
|
|
try{const raw2=localStorage.getItem(FAVORITE_MODELS_LOCALSTORAGE_KEY);return raw2?new Set(JSON.parse(raw2)):new Set}catch{return toast.error("Failed to load favorite models from local storage"),new Set}}toDisplayName(id2){const candidate=id2.split(/\\|\//).pop();return candidate&&candidate.trim().length>0?candidate:id2}clear(){this.models=[],this.routerModels=[],this.loading=!1,this.updating=!1,this.error=null,this.selectedModelId=null,this.selectedModelName=null,this.modelUsage.clear(),this.modelLoadingStates.
|
|
|
|
|
clear(),this.modelPropsCache.clear(),this.modelPropsFetching.clear()}pruneExpiredCache(){return this.modelPropsCache.prune()}}const modelsStore=new ModelsStore,modelOptions=()=>modelsStore.models,routerModels=()=>modelsStore.routerModels,modelsLoading=()=>modelsStore.loading,modelsUpdating=()=>modelsStore.updating,selectedModelId=()=>modelsStore.selectedModelId,selectedModelName=()=>modelsStore.selectedModelName,singleModelName=()=>modelsStore.singleModelName,selectedModelContextSize=()=>modelsStore.
|
|
|
|
|
selectedModelContextSize;var root_1$$=from_html("<!> <!>",1),root$1F=from_html('<div><div class="relative flex min-h-0 flex-1 items-center justify-center overflow-hidden"><!> <div class="flex h-full w-full flex-col items-center justify-start overflow-auto py-4"><!> <!></div></div></div>');function ChatAttachmentsPreview($$anchor,$$props){push$1($$props,!0);let uploadedFiles=prop($$props,"uploadedFiles",19,()=>[]),attachments=prop($$props,"attachments",19,()=>[]),className=prop($$props,"class",3,
|
|
|
|
|
""),previewFocusIndex=prop($$props,"previewFocusIndex",3,0),allItems=user_derived(()=>getAttachmentDisplayItems({uploadedFiles:uploadedFiles(),attachments:attachments()}).filter(item=>!isMcpPrompt(item)&&!isMcpResource(item)).map(item=>({...item,isImage:isImageFile(item.attachment,item.uploadedFile),isAudio:isAudioFile(item.attachment,item.uploadedFile)}))),currentIndex=state$1(0);user_effect(()=>{previewFocusIndex()>=0&&previewFocusIndex()<get$3(allItems).length&&set$1(currentIndex,previewFocusIndex())}),
|
|
|
|
|
user_effect(()=>{const handler=e=>{e.detail<0?set$1(currentIndex,get$3(currentIndex)>0?get$3(currentIndex)-1:get$3(allItems).length-1,!0):set$1(currentIndex,get$3(currentIndex)<get$3(allItems).length-1?get$3(currentIndex)+1:0,!0)};return document.addEventListener("chat-attachments-nav",handler),()=>document.removeEventListener("chat-attachments-nav",handler)}),user_effect(()=>{const index2=get$3(currentIndex);setTimeout(()=>{document.querySelector(`[data-thumbnail-index="${index2}"]`)?.scrollIntoView(
|
|
|
|
|
{behavior:"smooth",inline:"center",block:"nearest"})},0)});let currentItem=user_derived(()=>get$3(allItems)[get$3(currentIndex)]??null),displayName=user_derived(()=>get$3(currentItem)?.name||get$3(currentItem)?.uploadedFile?.name||get$3(currentItem)?.attachment?.name||"Unknown File"),isAudio=user_derived(()=>get$3(currentItem)?isAudioFile(get$3(currentItem).attachment,get$3(currentItem).uploadedFile):!1),isImage2=user_derived(()=>get$3(currentItem)?isImageFile(get$3(currentItem).attachment,get$3(
|
|
|
|
|
currentItem).uploadedFile):!1),isPdf=user_derived(()=>get$3(currentItem)?isPdfFile$1(get$3(currentItem).attachment,get$3(currentItem).uploadedFile):!1),isText=user_derived(()=>get$3(currentItem)?isTextFile(get$3(currentItem).attachment,get$3(currentItem).uploadedFile):!1),displayPreview=user_derived(()=>get$3(currentItem)?.uploadedFile?.preview||(get$3(isImage2)&&get$3(currentItem)?.attachment&&"base64Url"in get$3(currentItem).attachment?get$3(currentItem).attachment.base64Url:get$3(currentItem)?.
|
|
|
|
|
preview)),displayTextContent=user_derived(()=>get$3(currentItem)?.uploadedFile?.textContent||(get$3(currentItem)?.attachment&&"content"in get$3(currentItem).attachment?get$3(currentItem).attachment.content:get$3(currentItem)?.textContent)),language2=user_derived(()=>getLanguageFromFilename(get$3(displayName))),fileSize=user_derived(()=>get$3(currentItem)?.size?formatFileSize(get$3(currentItem).size):""),hasVisionModality=user_derived(()=>get$3(currentItem)&&$$props.activeModelId?modelsStore.modelSupportsVision(
|
|
|
|
|
$$props.activeModelId):!1),audioSrc=user_derived(()=>get$3(isAudio)&&get$3(currentItem)?get$3(currentItem).uploadedFile?.preview??(get$3(currentItem).attachment&&"mimeType"in get$3(currentItem).attachment&&"base64Data"in get$3(currentItem).attachment?createBase64DataUrl(get$3(currentItem).attachment.mimeType,get$3(currentItem).attachment.base64Data):null):null);function prev2(){set$1(currentIndex,get$3(currentIndex)>0?get$3(currentIndex)-1:get$3(allItems).length-1,!0)}function next2(){set$1(currentIndex,
|
|
|
|
|
get$3(currentIndex)<get$3(allItems).length-1?get$3(currentIndex)+1:0,!0)}function onNavigate(index2){set$1(currentIndex,index2,!0)}var $$exports={prev:prev2,next:next2},div=root$1F(),div_1=child(div),node2=child(div_1);{let $0=user_derived(()=>get$3(allItems).length>1);ChatAttachmentsPreviewNavButtons(node2,{onPrev:prev2,onNext:next2,get show(){return get$3($0)}})}var div_2=sibling(node2,2),node_1=child(div_2);{var consequent=$$anchor2=>{var fragment=root_1$$(),node_2=first_child(fragment);ChatAttachmentsPreviewFileInfo(
|
|
|
|
|
node_2,{get displayName(){return get$3(displayName)},get fileSize(){return get$3(fileSize)}});var node_3=sibling(node_2,2);ChatAttachmentsPreviewCurrentItem(node_3,{get currentItem(){return get$3(currentItem)},get isImage(){return get$3(isImage2)},get isAudio(){return get$3(isAudio)},get isPdf(){return get$3(isPdf)},get isText(){return get$3(isText)},get displayPreview(){return get$3(displayPreview)},get displayTextContent(){return get$3(displayTextContent)},get audioSrc(){return get$3(audioSrc)},
|
|
|
|
|
get language(){return get$3(language2)},get hasVisionModality(){return get$3(hasVisionModality)},get activeModelId(){return $$props.activeModelId}}),append($$anchor2,fragment)};if_block(node_1,$$render=>{get$3(currentItem)&&$$render(consequent)})}var node_4=sibling(node_1,2);return ChatAttachmentsPreviewThumbnailStrip(node_4,{get items(){return get$3(allItems)},get currentIndex(){return get$3(currentIndex)},onNavigate}),reset(div_2),reset(div_1),reset(div),template_effect(()=>set_class(div,1,`${className()??
|
|
|
|
|
""} flex flex-col text-white`)),append($$anchor,div),pop($$exports)}var root_1$_=from_html("<!> <!>",1);function ChatAttachmentsPreviewNavButtons($$anchor,$$props){var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var fragment_1=root_1$_(),node_1=first_child(fragment_1);Button(node_1,{variant:"secondary",size:"icon",class:"absolute top-1/2 left-4 z-10 h-8 w-8 -translate-y-1/2 rounded-full bg-background/5 p-0 text-white!",get onclick(){return $$props.onPrev},"aria-l\
|
|
|
|
|
abel":"Previous",children:($$anchor3,$$slotProps)=>{Chevron_left($$anchor3,{class:"size-4"})},$$slots:{default:!0}});var node_2=sibling(node_1,2);Button(node_2,{variant:"secondary",size:"icon",class:"absolute top-1/2 right-4 z-10 h-8 w-8 -translate-y-1/2 rounded-full bg-background/5 p-0 text-white!",get onclick(){return $$props.onNext},"aria-label":"Next",children:($$anchor3,$$slotProps)=>{Chevron_right($$anchor3,{class:"size-4"})},$$slots:{default:!0}}),append($$anchor2,fragment_1)};if_block(node2,
|
|
|
|
|
$$render=>{$$props.show&&$$render(consequent)})}append($$anchor,fragment)}var root_1$Z=from_html('<p class="text-xs text-white/60"> </p>'),root$1E=from_html('<div class="sticky top-0 z-[20] mb-4 rounded-lg bg-black/5 px-4 py-2 text-center backdrop-blur-md"><p class="font-medium text-white"> </p> <!></div>');function ChatAttachmentsPreviewFileInfo($$anchor,$$props){var div=root$1E(),p2=child(div),text2=child(p2,!0);reset(p2);var node2=sibling(p2,2);{var consequent=$$anchor2=>{var p_1=root_1$Z(),text_1=child(
|
|
|
|
|
p_1,!0);reset(p_1),template_effect(()=>set_text(text_1,$$props.fileSize)),append($$anchor2,p_1)};if_block(node2,$$render=>{$$props.fileSize&&$$render(consequent)})}reset(div),template_effect(()=>set_text(text2,$$props.displayName)),append($$anchor,div)}var root_1$Y=from_html('<div data-slot="checkbox-indicator" class="text-current transition-none"><!></div>');function Checkbox($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),checked=prop($$props,"checked",15,!1),indeterminate=prop(
|
|
|
|
|
$$props,"indeterminate",15,!1),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","checked","indeterminate","class"]);var fragment=comment$2(),node2=first_child(fragment);{const children=($$anchor2,$$arg0)=>{let checked2=()=>$$arg0?.().checked,indeterminate2=()=>$$arg0?.().indeterminate;var div=root_1$Y(),node_1=child(div);{var consequent=$$anchor3=>{Check($$anchor3,{class:"size-3.5"})},consequent_1=$$anchor3=>{Minus($$anchor3,{class:"size-3.5"})};if_block(node_1,$$render=>{checked2()?
|
|
|
|
|
$$render(consequent):indeterminate2()&&$$render(consequent_1,1)})}reset(div),append($$anchor2,div)};let $0=user_derived(()=>cn$1("peer flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input shadow-xs transition-shadow outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[state=checked]:border-primary data-[state=ch\
|
|
|
|
|
ecked]:bg-primary data-[state=checked]:text-primary-foreground dark:bg-input/30 dark:aria-invalid:ring-destructive/40 dark:data-[state=checked]:bg-primary",$$props.class));component(node2,()=>Checkbox$1,($$anchor2,CheckboxPrimitive_Root)=>{CheckboxPrimitive_Root($$anchor2,spread_props({"data-slot":"checkbox",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},get checked(){return checked()},set checked($$value){checked($$value)},get indeterminate(){
|
|
|
|
|
return indeterminate()},set indeterminate($$value){indeterminate($$value)},children,$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}var root_1$X=from_html("<input/>"),root_2$15=from_html("<input/>");function Input($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),value=prop($$props,"value",15),files=prop($$props,"files",15),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","value","type","files","class"]);var fragment=comment$2(),node2=first_child(
|
|
|
|
|
fragment);{var consequent=$$anchor2=>{var input=root_1$X();attribute_effect(input,$0=>({"data-slot":"input",class:$0,type:"file",...restProps}),[()=>cn$1("flex h-9 w-full min-w-0 rounded-md border border-input bg-transparent px-3 pt-1.5 text-sm font-medium shadow-xs ring-offset-background transition-[color,box-shadow] outline-none selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30","\
|
|
|
|
|
focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40",$$props.class)],void 0,void 0,void 0,!0),bind_this(input,$$value=>ref2($$value),()=>ref2()),bind_files(input,files),bind_value(input,value),append($$anchor2,input)},alternate=$$anchor2=>{var input_1=root_2$15();attribute_effect(input_1,$0=>({"data-slot":"input",class:$0,style:"backdrop-filter: blur(0.5rem);",type:$$props.
|
|
|
|
|
type,...restProps}),[()=>cn$1("flex h-9 w-full min-w-0 rounded-md border border-input bg-background px-3 py-1 text-base shadow-xs ring-offset-background transition-[color,box-shadow] outline-none selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","aria-invalid:border-destructive aria-invalid:ring-destruc\
|
|
|
|
|
tive/20 dark:aria-invalid:ring-destructive/40",$$props.class)],void 0,void 0,void 0,!0),bind_this(input_1,$$value=>ref2($$value),()=>ref2()),bind_value(input_1,value),append($$anchor2,input_1)};if_block(node2,$$render=>{$$props.type==="file"?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment),pop()}var root_1$W=from_html('<button type="button" class="absolute top-1/2 right-3 -translate-y-1/2 transform cursor-pointer text-muted-foreground transition-colors hover:text-foregroun\
|
|
|
|
|
d"><!></button>'),root$1D=from_html("<div><!> <!> <!></div>");function SearchInput($$anchor,$$props){push$1($$props,!0);let value=prop($$props,"value",15,""),placeholder=prop($$props,"placeholder",3,"Search..."),ref2=prop($$props,"ref",15,null),isCancelAlwaysVisible=prop($$props,"isCancelAlwaysVisible",3,!1),showClearButton=user_derived(()=>isCancelAlwaysVisible()||!!value()||!!$$props.onClose);function handleInput(event2){const target2=event2.target;value(target2.value),$$props.onInput?.(target2.
|
|
|
|
|
value)}function handleClear(){value()?(value(""),$$props.onInput?.(""),ref2()?.focus()):$$props.onClose?.()}var div=root$1D(),node2=child(div);Search(node2,{class:"absolute top-1/2 left-3 z-10 h-4 w-4 -translate-y-1/2 transform text-muted-foreground"});var node_1=sibling(node2,2);{let $0=user_derived(()=>get$3(showClearButton)?"pr-9":"");Input(node_1,{get id(){return $$props.id},get class(){return`pl-9 ${get$3($0)??""}`},oninput:handleInput,get onkeydown(){return $$props.onKeyDown},get placeholder(){
|
|
|
|
|
return placeholder()},type:"search",get value(){return value()},set value($$value){value($$value)},get ref(){return ref2()},set ref($$value){ref2($$value)}})}var node_2=sibling(node_1,2);{var consequent=$$anchor2=>{var button=root_1$W(),node_3=child(button);X(node_3,{class:"h-4 w-4"}),reset(button),template_effect(()=>set_attribute(button,"aria-label",value()?"Clear search":"Close")),delegated("click",button,handleClear),append($$anchor2,button)};if_block(node_2,$$render=>{get$3(showClearButton)&&
|
|
|
|
|
$$render(consequent)})}reset(div),template_effect(()=>set_class(div,1,`relative ${$$props.class??""}`)),append($$anchor,div),pop()}delegate(["click"]);var root_1$V=from_html("<!> <!>",1);function Scroll_area_scrollbar($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),orientation=prop($$props,"orientation",3,"vertical"),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","orientation","children"]);var fragment=comment$2(),node2=first_child(fragment);
|
|
|
|
|
{let $0=user_derived(()=>cn$1("flex touch-none p-px transition-colors select-none",orientation()==="vertical"&&"h-full w-2.5 border-l border-l-transparent",orientation()==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent",$$props.class));component(node2,()=>Scroll_area_scrollbar$1,($$anchor2,ScrollAreaPrimitive_Scrollbar)=>{ScrollAreaPrimitive_Scrollbar($$anchor2,spread_props({"data-slot":"scroll-area-scrollbar",get orientation(){return orientation()},get class(){return get$3($0)}},()=>restProps,
|
|
|
|
|
{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$V(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);component(node_2,()=>Scroll_area_thumb,($$anchor4,ScrollAreaPrimitive_Thumb)=>{ScrollAreaPrimitive_Thumb($$anchor4,{"data-slot":"scroll-area-thumb",class:"relative flex-1 rounded-full bg-border"})}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),
|
|
|
|
|
pop()}var root_1$U=from_html("<!> <!> <!> <!>",1);function Scroll_area($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),orientation=prop($$props,"orientation",3,"vertical"),scrollbarXClasses=prop($$props,"scrollbarXClasses",3,""),scrollbarYClasses=prop($$props,"scrollbarYClasses",3,""),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","orientation","scrollbarXClasses","scrollbarYClasses","children"]);var fragment=comment$2(),node2=first_child(fragment);
|
|
|
|
|
{let $0=user_derived(()=>cn$1("relative",$$props.class));component(node2,()=>Scroll_area$1,($$anchor2,ScrollAreaPrimitive_Root)=>{ScrollAreaPrimitive_Root($$anchor2,spread_props({"data-slot":"scroll-area",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$U(),node_1=first_child(fragment_1);component(node_1,()=>Scroll_area_viewport,($$anchor4,ScrollAreaPrimitive_Viewport)=>{ScrollAreaPrimitive_Viewport(
|
|
|
|
|
$$anchor4,{"data-slot":"scroll-area-viewport",class:"size-full rounded-[inherit] ring-ring/10 outline-ring/50 transition-[color,box-shadow] focus-visible:ring-4 focus-visible:outline-1 dark:ring-ring/20 dark:outline-ring/40",children:($$anchor5,$$slotProps2)=>{var fragment_2=comment$2(),node_2=first_child(fragment_2);snippet(node_2,()=>$$props.children??noop$3),append($$anchor5,fragment_2)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);{var consequent=$$anchor4=>{Scroll_area_scrollbar($$anchor4,
|
|
|
|
|
{orientation:"vertical",get class(){return scrollbarYClasses()}})};if_block(node_3,$$render=>{(orientation()==="vertical"||orientation()==="both")&&$$render(consequent)})}var node_4=sibling(node_3,2);{var consequent_1=$$anchor4=>{Scroll_area_scrollbar($$anchor4,{orientation:"horizontal",get class(){return scrollbarXClasses()}})};if_block(node_4,$$render=>{(orientation()==="horizontal"||orientation()==="both")&&$$render(consequent_1)})}var node_5=sibling(node_4,2);component(node_5,()=>Scroll_area_corner,
|
|
|
|
|
($$anchor4,ScrollAreaPrimitive_Corner)=>{ScrollAreaPrimitive_Corner($$anchor4,{})}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}var root_3$W=from_html('<tr><td colspan="3" class="p-8 text-center text-sm text-muted-foreground"><!></td></tr>'),root_7$s=from_html('<tr class="cursor-pointer border-b transition-colors hover:bg-muted/50"><td class="p-3"><!></td><td class="p-3 text-sm"><div class="max-w-[17rem] truncate"> </div></td><td class="p-3 text-sm tex\
|
|
|
|
|
t-muted-foreground"> </td></tr>'),root_2$14=from_html('<table class="w-full"><thead class="sticky top-0 z-10 bg-muted"><tr class="border-b"><th class="w-12 p-3 text-left"><!></th><th class="p-3 text-left text-sm font-medium">Conversation Name</th><th class="w-32 p-3 text-left text-sm font-medium">Messages</th></tr></thead><tbody><!></tbody></table>'),root$1C=from_html('<div class="space-y-4"><!> <div class="flex items-center justify-between text-sm text-muted-foreground"><span> <!></span></div> \
|
|
|
|
|
<div class="overflow-hidden rounded-md border"><!></div> <div class="flex justify-end gap-2"><!> <!></div></div>');function ConversationSelection($$anchor,$$props){push$1($$props,!0);let messageCountMap=prop($$props,"messageCountMap",19,()=>new Map),searchQuery=state$1(""),selectedIds=state$1(getInitialSelectedIds()),lastClickedId=state$1(null);function getInitialSelectedIds(){return new SvelteSet($$props.conversations.map(c2=>c2.id))}let filteredConversations=user_derived(()=>$$props.conversations.
|
|
|
|
|
filter(conv=>(conv.name||"Untitled conversation").toLowerCase().includes(get$3(searchQuery).toLowerCase()))),allSelected=user_derived(()=>get$3(filteredConversations).length>0&&get$3(filteredConversations).every(conv=>get$3(selectedIds).has(conv.id))),someSelected=user_derived(()=>get$3(filteredConversations).some(conv=>get$3(selectedIds).has(conv.id))&&!get$3(allSelected));function toggleConversation(id2,shiftKey=!1){const newSet=new SvelteSet(get$3(selectedIds));if(shiftKey&&get$3(lastClickedId)!==
|
|
|
|
|
null){const lastIndex=get$3(filteredConversations).findIndex(c2=>c2.id===get$3(lastClickedId)),currentIndex=get$3(filteredConversations).findIndex(c2=>c2.id===id2);if(lastIndex!==-1&¤tIndex!==-1){const start2=Math.min(lastIndex,currentIndex),end=Math.max(lastIndex,currentIndex),shouldSelect=!newSet.has(id2);for(let i=start2;i<=end;i++)shouldSelect?newSet.add(get$3(filteredConversations)[i].id):newSet.delete(get$3(filteredConversations)[i].id);set$1(selectedIds,newSet);return}}newSet.has(id2)?
|
|
|
|
|
newSet.delete(id2):newSet.add(id2),set$1(selectedIds,newSet),set$1(lastClickedId,id2,!0)}function toggleAll(){if(get$3(allSelected)){const newSet=new SvelteSet(get$3(selectedIds));get$3(filteredConversations).forEach(conv=>newSet.delete(conv.id)),set$1(selectedIds,newSet)}else{const newSet=new SvelteSet(get$3(selectedIds));get$3(filteredConversations).forEach(conv=>newSet.add(conv.id)),set$1(selectedIds,newSet)}}function handleConfirm(){const selected=$$props.conversations.filter(conv=>get$3(selectedIds).
|
|
|
|
|
has(conv.id));$$props.onConfirm(selected)}function handleCancel(){set$1(selectedIds,getInitialSelectedIds()),set$1(searchQuery,""),set$1(lastClickedId,null),$$props.onCancel()}function reset$1(){set$1(selectedIds,getInitialSelectedIds()),set$1(searchQuery,""),set$1(lastClickedId,null)}var $$exports={reset:reset$1},div=root$1C(),node2=child(div);SearchInput(node2,{placeholder:"Search conversations...",get value(){return get$3(searchQuery)},set value($$value){set$1(searchQuery,$$value,!0)}});var div_1=sibling(
|
|
|
|
|
node2,2),span=child(div_1),text2=child(span),node_1=sibling(text2);{var consequent=$$anchor2=>{var text_1=text$8();template_effect(()=>set_text(text_1,`(${get$3(filteredConversations).length??""} shown)`)),append($$anchor2,text_1)};if_block(node_1,$$render=>{get$3(searchQuery)&&$$render(consequent)})}reset(span),reset(div_1);var div_2=sibling(div_1,2),node_2=child(div_2);Scroll_area(node_2,{class:"h-[400px]",children:($$anchor2,$$slotProps)=>{var table2=root_2$14(),thead2=child(table2),tr2=child(
|
|
|
|
|
thead2),th=child(tr2),node_3=child(th);Checkbox(node_3,{get checked(){return get$3(allSelected)},get indeterminate(){return get$3(someSelected)},onCheckedChange:toggleAll}),reset(th),next$1(2),reset(tr2),reset(thead2);var tbody2=sibling(thead2),node_4=child(tbody2);{var consequent_2=$$anchor3=>{var tr_1=root_3$W(),td=child(tr_1),node_5=child(td);{var consequent_1=$$anchor4=>{var text_2=text$8();template_effect(()=>set_text(text_2,`No conversations found matching "${get$3(searchQuery)??""}"`)),append(
|
|
|
|
|
$$anchor4,text_2)},alternate=$$anchor4=>{var text_3=text$8("No conversations available");append($$anchor4,text_3)};if_block(node_5,$$render=>{get$3(searchQuery)?$$render(consequent_1):$$render(alternate,-1)})}reset(td),reset(tr_1),append($$anchor3,tr_1)},alternate_1=$$anchor3=>{var fragment_2=comment$2(),node_6=first_child(fragment_2);each(node_6,17,()=>get$3(filteredConversations),conv=>conv.id,($$anchor4,conv)=>{var tr_2=root_7$s(),td_1=child(tr_2),node_7=child(td_1);{let $0=user_derived(()=>get$3(
|
|
|
|
|
selectedIds).has(get$3(conv).id));Checkbox(node_7,{get checked(){return get$3($0)},onclick:event2=>{event2.preventDefault(),event2.stopPropagation(),toggleConversation(get$3(conv).id,event2.shiftKey)}})}reset(td_1);var td_2=sibling(td_1),div_3=child(td_2),text_4=child(div_3,!0);reset(div_3),reset(td_2);var td_3=sibling(td_2),text_5=child(td_3,!0);reset(td_3),reset(tr_2),template_effect($0=>{set_attribute(div_3,"title",get$3(conv).name||"Untitled conversation"),set_text(text_4,get$3(conv).name||"\
|
|
|
|
|
Untitled conversation"),set_text(text_5,$0)},[()=>messageCountMap().get(get$3(conv).id)??0]),delegated("click",tr_2,event2=>toggleConversation(get$3(conv).id,event2.shiftKey)),append($$anchor4,tr_2)}),append($$anchor3,fragment_2)};if_block(node_4,$$render=>{get$3(filteredConversations).length===0?$$render(consequent_2):$$render(alternate_1,-1)})}reset(tbody2),reset(table2),append($$anchor2,table2)},$$slots:{default:!0}}),reset(div_2);var div_4=sibling(div_2,2),node_8=child(div_4);Button(node_8,{
|
|
|
|
|
variant:"outline",onclick:handleCancel,children:($$anchor2,$$slotProps)=>{next$1();var text_6=text$8("Cancel");append($$anchor2,text_6)},$$slots:{default:!0}});var node_9=sibling(node_8,2);{let $0=user_derived(()=>get$3(selectedIds).size===0);Button(node_9,{onclick:handleConfirm,get disabled(){return get$3($0)},children:($$anchor2,$$slotProps)=>{next$1();var text_7=text$8();template_effect(()=>set_text(text_7,`${$$props.mode==="export"?"Export":"Import"} (${get$3(selectedIds).size??""})`)),append(
|
|
|
|
|
$$anchor2,text_7)},$$slots:{default:!0}})}return reset(div_4),reset(div),template_effect(()=>set_text(text2,`${get$3(selectedIds).size??""} of ${$$props.conversations.length??""} selected `)),append($$anchor,div),pop($$exports)}delegate(["click"]);var root$1B=from_html('<div><button aria-label="Scroll left"><!></button> <div><!></div> <button aria-label="Scroll right"><!></button></div>');function HorizontalScrollCarousel($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,
|
|
|
|
|
""),gapSize=prop($$props,"gapSize",3,"3"),canScrollLeft=state$1(!1),canScrollRight=state$1(!1),scrollContainer=state$1(void 0);function scrollLeft(event2){event2?.stopPropagation(),event2?.preventDefault(),get$3(scrollContainer)&&get$3(scrollContainer).scrollBy({left:get$3(scrollContainer).clientWidth*-.67,behavior:"smooth"})}function scrollRight(event2){event2?.stopPropagation(),event2?.preventDefault(),get$3(scrollContainer)&&get$3(scrollContainer).scrollBy({left:get$3(scrollContainer).clientWidth*
|
|
|
|
|
.67,behavior:"smooth"})}function updateScrollButtons(){if(!get$3(scrollContainer))return;const{scrollLeft:scrollLeft2,scrollWidth,clientWidth}=get$3(scrollContainer);set$1(canScrollLeft,scrollLeft2>0),set$1(canScrollRight,scrollLeft2<scrollWidth-clientWidth-1);const isScrollable=scrollWidth>clientWidth;$$props.onScrollableChange?.(isScrollable)}function resetScroll(){get$3(scrollContainer)&&(get$3(scrollContainer).scrollLeft=0,setTimeout(()=>{updateScrollButtons()},0))}user_effect(()=>{get$3(scrollContainer)&&
|
|
|
|
|
setTimeout(()=>{updateScrollButtons()},0)});var $$exports={resetScroll},div=root$1B(),button=child(div),node2=child(button);Chevron_left(node2,{class:"h-4 w-4"}),reset(button);var div_1=sibling(button,2),node_1=child(div_1);snippet(node_1,()=>$$props.children??noop$3),reset(div_1),bind_this(div_1,$$value=>set$1(scrollContainer,$$value),()=>get$3(scrollContainer));var button_1=sibling(div_1,2),node_2=child(button_1);return Chevron_right(node_2,{class:"h-4 w-4"}),reset(button_1),reset(div),template_effect(
|
|
|
|
|
()=>{set_class(div,1,`relative ${className()??""}`),set_class(button,1,`absolute top-1/2 left-4 z-10 flex h-6 w-6 -translate-y-1/2 items-center justify-center rounded-full bg-background/25 shadow-md backdrop-blur-xs transition-opacity hover:bg-background/45 ${get$3(canScrollLeft)?"opacity-100":"pointer-events-none opacity-0"}`),set_class(div_1,1,`scrollbar-hide flex items-start gap-${gapSize()??""} overflow-x-auto`),set_class(button_1,1,`absolute top-1/2 right-4 z-10 flex h-6 w-6 -translate-y-1/\
|
|
|
|
|
2 items-center justify-center rounded-full bg-background/25 shadow-md backdrop-blur-xs transition-opacity hover:bg-background/45 ${get$3(canScrollRight)?"opacity-100":"pointer-events-none opacity-0"}`)}),delegated("click",button,scrollLeft),event("scroll",div_1,updateScrollButtons),delegated("click",button_1,scrollRight),append($$anchor,div),pop($$exports)}delegate(["click"]);var root_3$V=from_html('<span class="block truncate"> </span>'),root_4$B=from_html("<p> </p>"),root_2$13=from_html("<!> <\
|
|
|
|
|
!>",1),root_5$v=from_html("<span> </span>");function TruncatedText($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),showTooltip=prop($$props,"showTooltip",3,!0),textElement=state$1(void 0),isTruncated=state$1(!1);function checkTruncation(){get$3(textElement)&&set$1(isTruncated,get$3(textElement).scrollWidth>get$3(textElement).clientWidth)}user_effect(()=>{if(get$3(textElement)){checkTruncation();const observer=new ResizeObserver(checkTruncation);return observer.observe(
|
|
|
|
|
get$3(textElement)),()=>observer.disconnect()}});var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);component(node_1,()=>Root$5,($$anchor3,Tooltip_Root)=>{Tooltip_Root($$anchor3,{children:($$anchor4,$$slotProps)=>{var fragment_2=root_2$13(),node_2=first_child(fragment_2);component(node_2,()=>Tooltip_trigger,($$anchor5,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor5,{get class(){return`${className()??""} min-w-0`},
|
|
|
|
|
children:($$anchor6,$$slotProps2)=>{var span=root_3$V(),text_1=child(span,!0);reset(span),bind_this(span,$$value=>set$1(textElement,$$value),()=>get$3(textElement)),template_effect(()=>set_text(text_1,$$props.text)),append($$anchor6,span)},$$slots:{default:!0}})});var node_3=sibling(node_2,2);component(node_3,()=>Tooltip_content,($$anchor5,Tooltip_Content)=>{Tooltip_Content($$anchor5,{class:"z-[9999]",children:($$anchor6,$$slotProps2)=>{var p2=root_4$B(),text_2=child(p2,!0);reset(p2),template_effect(
|
|
|
|
|
()=>set_text(text_2,$$props.text)),append($$anchor6,p2)},$$slots:{default:!0}})}),append($$anchor4,fragment_2)},$$slots:{default:!0}})}),append($$anchor2,fragment_1)},alternate=$$anchor2=>{var span_1=root_5$v(),text_3=child(span_1,!0);reset(span_1),bind_this(span_1,$$value=>set$1(textElement,$$value),()=>get$3(textElement)),template_effect(()=>{set_class(span_1,1,`${className()??""} block min-w-0 truncate`),set_text(text_3,$$props.text)}),append($$anchor2,span_1)};if_block(node2,$$render=>{get$3(
|
|
|
|
|
isTruncated)&&showTooltip()?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment),pop()}var root_3$U=from_html("<span>⌘</span>"),root_5$u=from_html("<span></span>"),root_1$T=from_html("<!> <!>",1),root$1A=from_html("<kbd></kbd>");function KeyboardShortcutInfo($$anchor,$$props){push$1($$props,!0);let variant=prop($$props,"variant",3,"default"),className=prop($$props,"class",3,""),variantClasses=user_derived(()=>variant()==="destructive"?"text-destructive":"text-muted-foregroun\
|
|
|
|
|
d");var kbd=root$1A();each(kbd,21,()=>$$props.keys,index$2,($$anchor2,key2,index2)=>{var fragment=root_1$T(),node2=first_child(fragment);{var consequent=$$anchor3=>{{let $0=user_derived(()=>variant()==="destructive"?"text-destructive":"");Arrow_big_up($$anchor3,{get class(){return`h-1 w-1 ${get$3($0)??""} -mr-1`}})}},consequent_1=$$anchor3=>{var span=root_3$U();template_effect(()=>set_class(span,1,clsx(variant()==="destructive"?"text-destructive":""))),append($$anchor3,span)},alternate=$$anchor3=>{
|
|
|
|
|
var text2=text$8();template_effect($0=>set_text(text2,$0),[()=>get$3(key2).toUpperCase()]),append($$anchor3,text2)};if_block(node2,$$render=>{get$3(key2)==="shift"?$$render(consequent):get$3(key2)==="cmd"?$$render(consequent_1,1):$$render(alternate,-1)})}var node_1=sibling(node2,2);{var consequent_2=$$anchor3=>{var span_1=root_5$u();append($$anchor3,span_1)};if_block(node_1,$$render=>{index2<$$props.keys.length-1&&$$render(consequent_2)})}append($$anchor2,fragment)}),reset(kbd),template_effect(()=>set_class(
|
|
|
|
|
kbd,1,`px-1 pointer-events-none inline-flex select-none items-center gap-0.5 font-sans text-md font-medium opacity-0 transition-opacity -my-1 ${get$3(variantClasses)??""} ${className()??""}`)),append($$anchor,kbd),pop()}var root$1z=from_html('<div class="code-block-actions"><!> <!></div>');function CodeBlockActions($$anchor,$$props){push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1);const showPreview=user_derived(()=>$$props.language?.toLowerCase()===FileTypeText.HTML);var div=root$1z(),
|
|
|
|
|
node2=child(div);{let $0=user_derived(()=>!disabled()),$1=user_derived(()=>disabled()?"Code incomplete":"Copy code");ActionIconCopyToClipboard(node2,{get text(){return $$props.code},get canCopy(){return get$3($0)},get ariaLabel(){return get$3($1)}})}var node_1=sibling(node2,2);{var consequent=$$anchor2=>{{let $0=user_derived(()=>disabled()?"Code incomplete":"Preview code");ActionIcon($$anchor2,{get icon(){return Eye},get tooltip(){return get$3($0)},get disabled(){return disabled()},onclick:()=>$$props.
|
|
|
|
|
onPreview($$props.code,$$props.language)})}};if_block(node_1,$$render=>{get$3(showPreview)&&$$render(consequent)})}reset(div),append($$anchor,div),pop()}var root_4$A=from_html('<img class="h-12 w-12 object-cover"/>'),root_5$t=from_html('<div class="bg-foreground-muted/50 flex h-12 w-12 flex-col items-center justify-center gap-0.5 py-1"><!> <span class="font-mono text-[9px] text-white/60"> </span></div>'),root_3$T=from_html("<button><!></button>"),root_1$S=from_html('<div class="sticky bottom-0 z\
|
|
|
|
|
-10 mt-4 flex-shrink-0"><!></div>');function ChatAttachmentsPreviewThumbnailStrip($$anchor,$$props){push$1($$props,!0);function getFileExtension(name){const parts=name.split(".");return parts.length>1?parts.pop()?.toUpperCase()??"":""}var fragment=comment$2(),node2=first_child(fragment);{var consequent_2=$$anchor2=>{var div=root_1$S(),node_1=child(div);HorizontalScrollCarousel(node_1,{class:"max-w-full",children:($$anchor3,$$slotProps)=>{var fragment_1=comment$2(),node_2=first_child(fragment_1);
|
|
|
|
|
each(node_2,19,()=>$$props.items,item=>item.id,($$anchor4,item,index2)=>{var button=root_3$T(),node_3=child(button);{var consequent=$$anchor5=>{var img=root_4$A();template_effect(()=>{set_attribute(img,"src",get$3(item).preview),set_attribute(img,"alt",get$3(item).name)}),append($$anchor5,img)},alternate_1=$$anchor5=>{var div_1=root_5$t(),node_4=child(div_1);{var consequent_1=$$anchor6=>{Music($$anchor6,{class:"h-4 w-4 text-white/70"})},alternate=$$anchor6=>{File_text($$anchor6,{class:"h-4 w-4 t\
|
|
|
|
|
ext-white/70"})};if_block(node_4,$$render=>{get$3(item).isAudio?$$render(consequent_1):$$render(alternate,-1)})}var span=sibling(node_4,2),text2=child(span,!0);reset(span),reset(div_1),template_effect($0=>set_text(text2,$0),[()=>getFileExtension(get$3(item).name)]),append($$anchor5,div_1)};if_block(node_3,$$render=>{get$3(item).isImage&&get$3(item).preview?$$render(consequent):$$render(alternate_1,-1)})}reset(button),template_effect(()=>{set_attribute(button,"data-thumbnail-index",get$3(index2)),
|
|
|
|
|
set_class(button,1,clsx(["relative flex-shrink-0 cursor-pointer overflow-hidden rounded border-2 bg-black/80 backdrop-blur-sm transition-all hover:opacity-90",get$3(index2)===$$props.currentIndex?"border-white":"border-transparent opacity-60","[&:not(:first-child)]:last:mr-4 [&:not(:last-child)]:first:ml-4"])),set_attribute(button,"aria-label",`Go to ${get$3(item).name}`)}),delegated("click",button,()=>$$props.onNavigate(get$3(index2))),append($$anchor4,button)}),append($$anchor3,fragment_1)},$$slots:{
|
|
|
|
|
default:!0}}),reset(div),append($$anchor2,div)};if_block(node2,$$render=>{$$props.items.length>1&&$$render(consequent_2)})}append($$anchor,fragment),pop()}delegate(["click"]);const alertVariants=tv({base:"relative grid w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",variants:{variant:{default:"bg-card text-card-foreground",destructive:"\
|
|
|
|
|
text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current"}},defaultVariants:{variant:"default"}});var root$1y=from_html("<div><!></div>");function Alert($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),variant=prop($$props,"variant",3,"default"),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","variant","children"]);var div=root$1y();attribute_effect(div,$0=>({"data-slot":"alert",class:$0,...restProps,role:"\
|
|
|
|
|
alert"}),[()=>cn$1(alertVariants({variant:variant()}),$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root$1x=from_html("<div><!></div>");function Alert_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$1x();attribute_effect(div,$0=>({"d\
|
|
|
|
|
ata-slot":"alert-description",class:$0,...restProps}),[()=>cn$1("col-start-2 grid justify-items-start gap-1 text-sm text-muted-foreground [&_p]:leading-relaxed",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root$1w=from_html("<div><!></div>");function Alert_title($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$sl\
|
|
|
|
|
ots","$$events","$$legacy","ref","class","children"]);var div=root$1w();attribute_effect(div,$0=>({"data-slot":"alert-title",class:$0,...restProps}),[()=>cn$1("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}class AudioRecorder{mediaRecorder=null;audioChunks=[];stream=null;recordingState=!1;async startRecording(){try{
|
|
|
|
|
this.stream=await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0}}),this.initializeRecorder(this.stream),this.audioChunks=[],this.mediaRecorder.start(100),this.recordingState=!0}catch(error2){throw console.error("Failed to start recording:",error2),new Error("Failed to access microphone. Please check permissions.")}}async stopRecording(){return new Promise((resolve2,reject)=>{const recorder=this.mediaRecorder,chunks=this.audioChunks,stream=this.
|
|
|
|
|
!1}getModelStatus(modelId){return this.routerModels.find(m=>m.id===modelId)?.status.value??null}getModelUsage(modelId){return this.modelUsage.get(modelId)??new SvelteSet}isModelInUse(modelId){const usage=this.modelUsage.get(modelId);return usage!==void 0&&usage.size>0}async fetch(force=!1){if(this.inflightFetch)return this.inflightFetch;if(!(this.models.length>0&&!force)){this.inflightFetch=this.runFetch();try{await this.inflightFetch}finally{this.inflightFetch=null}}}async runFetch(){this.loading=
|
|
|
|
|
!0,this.error=null;try{serverStore.props||await serverStore.fetch();const response=await ModelsService.list(),models=response.data.map((item,index2)=>{const details=response.models?.[index2],rawCapabilities=Array.isArray(details?.capabilities)?details?.capabilities:[],displayNameSource=details?.name&&details.name.trim().length>0?details.name:item.id,displayName=this.toDisplayName(displayNameSource),modelId=details?.model||item.id;return{id:item.id,name:displayName,model:modelId,description:details?.
|
|
|
|
|
description,capabilities:rawCapabilities.filter(value=>!!value),details:details?.details,meta:item.meta??null,parsedId:ModelsService.parseModelId(modelId),aliases:item.aliases??[],tags:item.tags??[]}});this.models=models;const serverProps2=serverStore.props;if(serverStore.isModelMode&&this.models.length>0&&serverProps2?.modalities){const modalities={vision:serverProps2.modalities.vision??!1,audio:serverProps2.modalities.audio??!1};this.modelPropsCache.set(this.models[0].model,serverProps2),this.
|
|
|
|
|
models=this.models.map((model,index2)=>index2===0?{...model,modalities}:model)}}catch(error2){throw this.models=[],this.error=error2 instanceof Error?error2.message:"Failed to load models",error2}finally{this.loading=!1}}async fetchRouterModels(){try{const response=await ModelsService.listRouter();this.routerModels=response.data,await this.fetchModalitiesForLoadedModels();const o=this.models.filter(option2=>this.getModelProps(option2.model)?.webui!==!1);o.length===1&&this.isModelLoaded(o[0].model)&&
|
|
|
|
|
this.selectModelById(o[0].id)}catch(error2){console.warn("Failed to fetch router models:",error2),this.routerModels=[]}}async fetchModelProps(modelId){const cached2=this.modelPropsCache.get(modelId);if(cached2)return cached2;if(serverStore.isRouterMode&&!this.isModelLoaded(modelId)||this.modelPropsFetching.has(modelId))return null;this.modelPropsFetching.add(modelId);try{const props=await PropsService.fetchForModel(modelId);return this.modelPropsCache.set(modelId,props),props}catch(error2){return console.
|
|
|
|
|
warn(`Failed to fetch props for model ${modelId}:`,error2),null}finally{this.modelPropsFetching.delete(modelId)}}async fetchModalitiesForLoadedModels(){const loadedModelIds2=this.loadedModelIds;if(loadedModelIds2.length===0)return;const propsPromises=loadedModelIds2.map(modelId=>this.fetchModelProps(modelId));try{const results=await Promise.all(propsPromises);this.models=this.models.map(model=>{const modelIndex=loadedModelIds2.indexOf(model.model);if(modelIndex===-1)return model;const props=results[modelIndex];
|
|
|
|
|
if(!props?.modalities)return model;const modalities={vision:props.modalities.vision??!1,audio:props.modalities.audio??!1};return{...model,modalities}}),this.propsCacheVersion++}catch(error2){console.warn("Failed to fetch modalities for loaded models:",error2)}}async updateModelModalities(modelId){try{const props=await this.fetchModelProps(modelId);if(!props?.modalities)return;const modalities={vision:props.modalities.vision??!1,audio:props.modalities.audio??!1};this.models=this.models.map(model=>model.
|
|
|
|
|
model===modelId?{...model,modalities}:model),this.propsCacheVersion++}catch(error2){console.warn(`Failed to update modalities for model ${modelId}:`,error2)}}async selectModelById(modelId){if(!modelId||this.updating||this.selectedModelId===modelId)return;const option2=this.models.find(model=>model.id===modelId);if(!option2)throw new Error("Selected model is not available");this.updating=!0,this.error=null;try{this.selectedModelId=option2.id,this.selectedModelName=option2.model}finally{this.updating=
|
|
|
|
|
!1}}selectModelByName(modelName){const option2=this.models.find(model=>model.model===modelName);option2&&(this.selectedModelId=option2.id,this.selectedModelName=option2.model)}clearSelection(){this.selectedModelId=null,this.selectedModelName=null}findModelByName(modelName){return this.models.find(model=>model.model===modelName)??null}findModelById(modelId){return this.models.find(model=>model.id===modelId)??null}hasModel(modelName){return this.models.some(model=>model.model===modelName)}static STATUS_POLL_INTERVAL=500;async pollForModelStatus(modelId,expectedStatus){
|
|
|
|
|
let attempt=0;for(;;){await this.fetchRouterModels();const currentStatus=this.getModelStatus(modelId);if(currentStatus===expectedStatus)return;if(currentStatus===ServerModelStatus.FAILED)throw new Error(`Model failed to ${expectedStatus===ServerModelStatus.LOADED?"load":"unload"}`);if(expectedStatus===ServerModelStatus.LOADED&¤tStatus===ServerModelStatus.UNLOADED&&attempt>2)throw new Error("Model was unloaded unexpectedly during loading");attempt++,await new Promise(resolve2=>setTimeout(resolve2,
|
|
|
|
|
ModelsStore.STATUS_POLL_INTERVAL))}}async loadModel(modelId){if(!this.isModelLoaded(modelId)&&!this.modelLoadingStates.get(modelId)){this.modelLoadingStates.set(modelId,!0),this.error=null;try{await ModelsService.load(modelId),await this.pollForModelStatus(modelId,ServerModelStatus.LOADED),await this.updateModelModalities(modelId),toast.success(`Model loaded: ${this.toDisplayName(modelId)}`)}catch(error2){throw this.error=error2 instanceof Error?error2.message:"Failed to load model",toast.error(
|
|
|
|
|
`Failed to load model: ${this.toDisplayName(modelId)}`),error2}finally{this.modelLoadingStates.set(modelId,!1)}}}async unloadModel(modelId){if(this.isModelLoaded(modelId)&&!this.modelLoadingStates.get(modelId)){this.modelLoadingStates.set(modelId,!0),this.error=null;try{await ModelsService.unload(modelId),await this.pollForModelStatus(modelId,ServerModelStatus.UNLOADED),toast.info(`Model unloaded: ${this.toDisplayName(modelId)}`)}catch(error2){throw this.error=error2 instanceof Error?error2.message:
|
|
|
|
|
"Failed to unload model",toast.error(`Failed to unload model: ${this.toDisplayName(modelId)}`),error2}finally{this.modelLoadingStates.set(modelId,!1)}}}async ensureModelLoaded(modelId){this.isModelLoaded(modelId)||await this.loadModel(modelId)}isFavorite(modelId){return this.favoriteModelIds.has(modelId)}toggleFavorite(modelId){const next2=new SvelteSet(this.favoriteModelIds);next2.has(modelId)?next2.delete(modelId):next2.add(modelId),this.favoriteModelIds=next2;try{localStorage.setItem(FAVORITE_MODELS_LOCALSTORAGE_KEY,
|
|
|
|
|
JSON.stringify([...next2]))}catch{toast.error("Failed to save favorite models to local storage")}}loadFavoritesFromStorage(){try{const raw2=localStorage.getItem(FAVORITE_MODELS_LOCALSTORAGE_KEY);return raw2?new Set(JSON.parse(raw2)):new Set}catch{return toast.error("Failed to load favorite models from local storage"),new Set}}toDisplayName(id2){const candidate=id2.split(/\\|\//).pop();return candidate&&candidate.trim().length>0?candidate:id2}clear(){this.models=[],this.routerModels=[],this.loading=
|
|
|
|
|
!1,this.updating=!1,this.error=null,this.selectedModelId=null,this.selectedModelName=null,this.modelUsage.clear(),this.modelLoadingStates.clear(),this.modelPropsCache.clear(),this.modelPropsFetching.clear()}pruneExpiredCache(){return this.modelPropsCache.prune()}}const modelsStore=new ModelsStore,modelOptions=()=>modelsStore.models,routerModels=()=>modelsStore.routerModels,modelsLoading=()=>modelsStore.loading,modelsUpdating=()=>modelsStore.updating,selectedModelId=()=>modelsStore.selectedModelId,
|
|
|
|
|
selectedModelName=()=>modelsStore.selectedModelName,singleModelName=()=>modelsStore.singleModelName,selectedModelContextSize=()=>modelsStore.selectedModelContextSize;var root_1$$=from_html("<!> <!>",1),root$1F=from_html('<div><div class="relative flex min-h-0 flex-1 items-center justify-center overflow-hidden"><!> <div class="flex h-full w-full flex-col items-center justify-start overflow-auto py-4"><!> <!></div></div></div>');function ChatAttachmentsPreview($$anchor,$$props){push$1($$props,!0);
|
|
|
|
|
let uploadedFiles=prop($$props,"uploadedFiles",19,()=>[]),attachments=prop($$props,"attachments",19,()=>[]),className=prop($$props,"class",3,""),previewFocusIndex=prop($$props,"previewFocusIndex",3,0),allItems=user_derived(()=>getAttachmentDisplayItems({uploadedFiles:uploadedFiles(),attachments:attachments()}).filter(item=>!isMcpPrompt(item)&&!isMcpResource(item)).map(item=>({...item,isImage:isImageFile(item.attachment,item.uploadedFile),isAudio:isAudioFile(item.attachment,item.uploadedFile)}))),
|
|
|
|
|
currentIndex=state$1(0);user_effect(()=>{previewFocusIndex()>=0&&previewFocusIndex()<get$3(allItems).length&&set$1(currentIndex,previewFocusIndex())}),user_effect(()=>{const handler=e=>{e.detail<0?set$1(currentIndex,get$3(currentIndex)>0?get$3(currentIndex)-1:get$3(allItems).length-1,!0):set$1(currentIndex,get$3(currentIndex)<get$3(allItems).length-1?get$3(currentIndex)+1:0,!0)};return document.addEventListener("chat-attachments-nav",handler),()=>document.removeEventListener("chat-attachments-na\
|
|
|
|
|
v",handler)}),user_effect(()=>{const index2=get$3(currentIndex);setTimeout(()=>{document.querySelector(`[data-thumbnail-index="${index2}"]`)?.scrollIntoView({behavior:"smooth",inline:"center",block:"nearest"})},0)});let currentItem=user_derived(()=>get$3(allItems)[get$3(currentIndex)]??null),displayName=user_derived(()=>get$3(currentItem)?.name||get$3(currentItem)?.uploadedFile?.name||get$3(currentItem)?.attachment?.name||"Unknown File"),isAudio=user_derived(()=>get$3(currentItem)?isAudioFile(get$3(
|
|
|
|
|
currentItem).attachment,get$3(currentItem).uploadedFile):!1),isImage2=user_derived(()=>get$3(currentItem)?isImageFile(get$3(currentItem).attachment,get$3(currentItem).uploadedFile):!1),isPdf=user_derived(()=>get$3(currentItem)?isPdfFile$1(get$3(currentItem).attachment,get$3(currentItem).uploadedFile):!1),isText=user_derived(()=>get$3(currentItem)?isTextFile(get$3(currentItem).attachment,get$3(currentItem).uploadedFile):!1),displayPreview=user_derived(()=>get$3(currentItem)?.uploadedFile?.preview||
|
|
|
|
|
(get$3(isImage2)&&get$3(currentItem)?.attachment&&"base64Url"in get$3(currentItem).attachment?get$3(currentItem).attachment.base64Url:get$3(currentItem)?.preview)),displayTextContent=user_derived(()=>get$3(currentItem)?.uploadedFile?.textContent||(get$3(currentItem)?.attachment&&"content"in get$3(currentItem).attachment?get$3(currentItem).attachment.content:get$3(currentItem)?.textContent)),language2=user_derived(()=>getLanguageFromFilename(get$3(displayName))),fileSize=user_derived(()=>get$3(currentItem)?.
|
|
|
|
|
size?formatFileSize(get$3(currentItem).size):""),hasVisionModality=user_derived(()=>get$3(currentItem)&&$$props.activeModelId?modelsStore.modelSupportsVision($$props.activeModelId):!1),audioSrc=user_derived(()=>get$3(isAudio)&&get$3(currentItem)?get$3(currentItem).uploadedFile?.preview??(get$3(currentItem).attachment&&"mimeType"in get$3(currentItem).attachment&&"base64Data"in get$3(currentItem).attachment?createBase64DataUrl(get$3(currentItem).attachment.mimeType,get$3(currentItem).attachment.base64Data):
|
|
|
|
|
null):null);function prev2(){set$1(currentIndex,get$3(currentIndex)>0?get$3(currentIndex)-1:get$3(allItems).length-1,!0)}function next2(){set$1(currentIndex,get$3(currentIndex)<get$3(allItems).length-1?get$3(currentIndex)+1:0,!0)}function onNavigate(index2){set$1(currentIndex,index2,!0)}var $$exports={prev:prev2,next:next2},div=root$1F(),div_1=child(div),node2=child(div_1);{let $0=user_derived(()=>get$3(allItems).length>1);ChatAttachmentsPreviewNavButtons(node2,{onPrev:prev2,onNext:next2,get show(){
|
|
|
|
|
return get$3($0)}})}var div_2=sibling(node2,2),node_1=child(div_2);{var consequent=$$anchor2=>{var fragment=root_1$$(),node_2=first_child(fragment);ChatAttachmentsPreviewFileInfo(node_2,{get displayName(){return get$3(displayName)},get fileSize(){return get$3(fileSize)}});var node_3=sibling(node_2,2);ChatAttachmentsPreviewCurrentItem(node_3,{get currentItem(){return get$3(currentItem)},get isImage(){return get$3(isImage2)},get isAudio(){return get$3(isAudio)},get isPdf(){return get$3(isPdf)},get isText(){
|
|
|
|
|
return get$3(isText)},get displayPreview(){return get$3(displayPreview)},get displayTextContent(){return get$3(displayTextContent)},get audioSrc(){return get$3(audioSrc)},get language(){return get$3(language2)},get hasVisionModality(){return get$3(hasVisionModality)},get activeModelId(){return $$props.activeModelId}}),append($$anchor2,fragment)};if_block(node_1,$$render=>{get$3(currentItem)&&$$render(consequent)})}var node_4=sibling(node_1,2);return ChatAttachmentsPreviewThumbnailStrip(node_4,{get items(){
|
|
|
|
|
return get$3(allItems)},get currentIndex(){return get$3(currentIndex)},onNavigate}),reset(div_2),reset(div_1),reset(div),template_effect(()=>set_class(div,1,`${className()??""} flex flex-col text-white`)),append($$anchor,div),pop($$exports)}var root_1$_=from_html("<!> <!>",1);function ChatAttachmentsPreviewNavButtons($$anchor,$$props){var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var fragment_1=root_1$_(),node_1=first_child(fragment_1);Button(node_1,{variant:"s\
|
|
|
|
|
econdary",size:"icon",class:"absolute top-1/2 left-4 z-10 h-8 w-8 -translate-y-1/2 rounded-full bg-background/5 p-0 text-white!",get onclick(){return $$props.onPrev},"aria-label":"Previous",children:($$anchor3,$$slotProps)=>{Chevron_left($$anchor3,{class:"size-4"})},$$slots:{default:!0}});var node_2=sibling(node_1,2);Button(node_2,{variant:"secondary",size:"icon",class:"absolute top-1/2 right-4 z-10 h-8 w-8 -translate-y-1/2 rounded-full bg-background/5 p-0 text-white!",get onclick(){return $$props.
|
|
|
|
|
onNext},"aria-label":"Next",children:($$anchor3,$$slotProps)=>{Chevron_right($$anchor3,{class:"size-4"})},$$slots:{default:!0}}),append($$anchor2,fragment_1)};if_block(node2,$$render=>{$$props.show&&$$render(consequent)})}append($$anchor,fragment)}var root_1$Z=from_html('<p class="text-xs text-white/60"> </p>'),root$1E=from_html('<div class="sticky top-0 z-[20] mb-4 rounded-lg bg-black/5 px-4 py-2 text-center backdrop-blur-md"><p class="font-medium text-white"> </p> <!></div>');function ChatAttachmentsPreviewFileInfo($$anchor,$$props){
|
|
|
|
|
var div=root$1E(),p2=child(div),text2=child(p2,!0);reset(p2);var node2=sibling(p2,2);{var consequent=$$anchor2=>{var p_1=root_1$Z(),text_1=child(p_1,!0);reset(p_1),template_effect(()=>set_text(text_1,$$props.fileSize)),append($$anchor2,p_1)};if_block(node2,$$render=>{$$props.fileSize&&$$render(consequent)})}reset(div),template_effect(()=>set_text(text2,$$props.displayName)),append($$anchor,div)}var root_1$Y=from_html('<div data-slot="checkbox-indicator" class="text-current transition-none"><!></\
|
|
|
|
|
div>');function Checkbox($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),checked=prop($$props,"checked",15,!1),indeterminate=prop($$props,"indeterminate",15,!1),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","checked","indeterminate","class"]);var fragment=comment$2(),node2=first_child(fragment);{const children=($$anchor2,$$arg0)=>{let checked2=()=>$$arg0?.().checked,indeterminate2=()=>$$arg0?.().indeterminate;var div=root_1$Y(),node_1=child(div);{var consequent=$$anchor3=>{
|
|
|
|
|
Check($$anchor3,{class:"size-3.5"})},consequent_1=$$anchor3=>{Minus($$anchor3,{class:"size-3.5"})};if_block(node_1,$$render=>{checked2()?$$render(consequent):indeterminate2()&&$$render(consequent_1,1)})}reset(div),append($$anchor2,div)};let $0=user_derived(()=>cn$1("peer flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input shadow-xs transition-shadow outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowe\
|
|
|
|
|
d disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[state=checked]:border-primary data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:bg-input/30 dark:aria-invalid:ring-destructive/40 dark:data-[state=checked]:bg-primary",$$props.class));component(node2,()=>Checkbox$1,($$anchor2,CheckboxPrimitive_Root)=>{CheckboxPrimitive_Root($$anchor2,spread_props({"data-slot":"checkbox",get class(){return get$3($0)}},()=>restProps,{get ref(){
|
|
|
|
|
return ref2()},set ref($$value){ref2($$value)},get checked(){return checked()},set checked($$value){checked($$value)},get indeterminate(){return indeterminate()},set indeterminate($$value){indeterminate($$value)},children,$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}var root_1$X=from_html("<input/>"),root_2$15=from_html("<input/>");function Input($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),value=prop($$props,"value",15),files=prop($$props,"files",15),restProps=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy","ref","value","type","files","class"]);var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var input=root_1$X();attribute_effect(input,$0=>({"data-slot":"input",class:$0,type:"file",...restProps}),[()=>cn$1("flex h-9 w-full min-w-0 rounded-md border border-input bg-transparent px-3 pt-1.5 text-sm font-medium shadow-xs ring-offset-background transition-[color,box-shadow] outline-none selection:bg-primary selection:text-primary-\
|
|
|
|
|
foreground placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40",$$props.class)],void 0,void 0,void 0,!0),bind_this(input,$$value=>ref2($$value),()=>ref2()),bind_files(input,files),bind_value(input,value),append($$anchor2,input)},alternate=$$anchor2=>{var input_1=root_2$15();
|
|
|
|
|
attribute_effect(input_1,$0=>({"data-slot":"input",class:$0,style:"backdrop-filter: blur(0.5rem);",type:$$props.type,...restProps}),[()=>cn$1("flex h-9 w-full min-w-0 rounded-md border border-input bg-background px-3 py-1 text-base shadow-xs ring-offset-background transition-[color,box-shadow] outline-none selection:bg-primary selection:text-primary-foreground placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30","focus-visible:border-ring\
|
|
|
|
|
focus-visible:ring-[3px] focus-visible:ring-ring/50","aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40",$$props.class)],void 0,void 0,void 0,!0),bind_this(input_1,$$value=>ref2($$value),()=>ref2()),bind_value(input_1,value),append($$anchor2,input_1)};if_block(node2,$$render=>{$$props.type==="file"?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment),pop()}var root_1$W=from_html('<button type="button" class="absolute top-1/\
|
|
|
|
|
2 right-3 -translate-y-1/2 transform cursor-pointer text-muted-foreground transition-colors hover:text-foreground"><!></button>'),root$1D=from_html("<div><!> <!> <!></div>");function SearchInput($$anchor,$$props){push$1($$props,!0);let value=prop($$props,"value",15,""),placeholder=prop($$props,"placeholder",3,"Search..."),ref2=prop($$props,"ref",15,null),isCancelAlwaysVisible=prop($$props,"isCancelAlwaysVisible",3,!1),showClearButton=user_derived(()=>isCancelAlwaysVisible()||!!value()||!!$$props.
|
|
|
|
|
onClose);function handleInput(event2){const target2=event2.target;value(target2.value),$$props.onInput?.(target2.value)}function handleClear(){value()?(value(""),$$props.onInput?.(""),ref2()?.focus()):$$props.onClose?.()}var div=root$1D(),node2=child(div);Search(node2,{class:"absolute top-1/2 left-3 z-10 h-4 w-4 -translate-y-1/2 transform text-muted-foreground"});var node_1=sibling(node2,2);{let $0=user_derived(()=>get$3(showClearButton)?"pr-9":"");Input(node_1,{get id(){return $$props.id},get class(){
|
|
|
|
|
return`pl-9 ${get$3($0)??""}`},oninput:handleInput,get onkeydown(){return $$props.onKeyDown},get placeholder(){return placeholder()},type:"search",get value(){return value()},set value($$value){value($$value)},get ref(){return ref2()},set ref($$value){ref2($$value)}})}var node_2=sibling(node_1,2);{var consequent=$$anchor2=>{var button=root_1$W(),node_3=child(button);X(node_3,{class:"h-4 w-4"}),reset(button),template_effect(()=>set_attribute(button,"aria-label",value()?"Clear search":"Close")),delegated(
|
|
|
|
|
"click",button,handleClear),append($$anchor2,button)};if_block(node_2,$$render=>{get$3(showClearButton)&&$$render(consequent)})}reset(div),template_effect(()=>set_class(div,1,`relative ${$$props.class??""}`)),append($$anchor,div),pop()}delegate(["click"]);var root_1$V=from_html("<!> <!>",1);function Scroll_area_scrollbar($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),orientation=prop($$props,"orientation",3,"vertical"),restProps=rest_props($$props,["$$slots","$$events",
|
|
|
|
|
"$$legacy","ref","class","orientation","children"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("flex touch-none p-px transition-colors select-none",orientation()==="vertical"&&"h-full w-2.5 border-l border-l-transparent",orientation()==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent",$$props.class));component(node2,()=>Scroll_area_scrollbar$1,($$anchor2,ScrollAreaPrimitive_Scrollbar)=>{ScrollAreaPrimitive_Scrollbar($$anchor2,spread_props({"dat\
|
|
|
|
|
a-slot":"scroll-area-scrollbar",get orientation(){return orientation()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$V(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);component(node_2,()=>Scroll_area_thumb,($$anchor4,ScrollAreaPrimitive_Thumb)=>{ScrollAreaPrimitive_Thumb($$anchor4,{"data-slot":"scroll-area-thumb",class:"rela\
|
|
|
|
|
tive flex-1 rounded-full bg-border"})}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}var root_1$U=from_html("<!> <!> <!> <!>",1);function Scroll_area($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),orientation=prop($$props,"orientation",3,"vertical"),scrollbarXClasses=prop($$props,"scrollbarXClasses",3,""),scrollbarYClasses=prop($$props,"scrollbarYClasses",3,""),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref",
|
|
|
|
|
"class","orientation","scrollbarXClasses","scrollbarYClasses","children"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("relative",$$props.class));component(node2,()=>Scroll_area$1,($$anchor2,ScrollAreaPrimitive_Root)=>{ScrollAreaPrimitive_Root($$anchor2,spread_props({"data-slot":"scroll-area",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$U(),node_1=first_child(
|
|
|
|
|
fragment_1);component(node_1,()=>Scroll_area_viewport,($$anchor4,ScrollAreaPrimitive_Viewport)=>{ScrollAreaPrimitive_Viewport($$anchor4,{"data-slot":"scroll-area-viewport",class:"size-full rounded-[inherit] ring-ring/10 outline-ring/50 transition-[color,box-shadow] focus-visible:ring-4 focus-visible:outline-1 dark:ring-ring/20 dark:outline-ring/40",children:($$anchor5,$$slotProps2)=>{var fragment_2=comment$2(),node_2=first_child(fragment_2);snippet(node_2,()=>$$props.children??noop$3),append($$anchor5,
|
|
|
|
|
fragment_2)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);{var consequent=$$anchor4=>{Scroll_area_scrollbar($$anchor4,{orientation:"vertical",get class(){return scrollbarYClasses()}})};if_block(node_3,$$render=>{(orientation()==="vertical"||orientation()==="both")&&$$render(consequent)})}var node_4=sibling(node_3,2);{var consequent_1=$$anchor4=>{Scroll_area_scrollbar($$anchor4,{orientation:"horizontal",get class(){return scrollbarXClasses()}})};if_block(node_4,$$render=>{(orientation()===
|
|
|
|
|
"horizontal"||orientation()==="both")&&$$render(consequent_1)})}var node_5=sibling(node_4,2);component(node_5,()=>Scroll_area_corner,($$anchor4,ScrollAreaPrimitive_Corner)=>{ScrollAreaPrimitive_Corner($$anchor4,{})}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}var root_3$W=from_html('<tr><td colspan="3" class="p-8 text-center text-sm text-muted-foreground"><!></td></tr>'),root_7$s=from_html('<tr class="cursor-pointer border-b transition-colors hover:bg\
|
|
|
|
|
-muted/50"><td class="p-3"><!></td><td class="p-3 text-sm"><div class="max-w-[17rem] truncate"> </div></td><td class="p-3 text-sm text-muted-foreground"> </td></tr>'),root_2$14=from_html('<table class="w-full"><thead class="sticky top-0 z-10 bg-muted"><tr class="border-b"><th class="w-12 p-3 text-left"><!></th><th class="p-3 text-left text-sm font-medium">Conversation Name</th><th class="w-32 p-3 text-left text-sm font-medium">Messages</th></tr></thead><tbody><!></tbody></table>'),root$1C=from_html(
|
|
|
|
|
'<div class="space-y-4"><!> <div class="flex items-center justify-between text-sm text-muted-foreground"><span> <!></span></div> <div class="overflow-hidden rounded-md border"><!></div> <div class="flex justify-end gap-2"><!> <!></div></div>');function ConversationSelection($$anchor,$$props){push$1($$props,!0);let messageCountMap=prop($$props,"messageCountMap",19,()=>new Map),searchQuery=state$1(""),selectedIds=state$1(getInitialSelectedIds()),lastClickedId=state$1(null);function getInitialSelectedIds(){
|
|
|
|
|
return new SvelteSet($$props.conversations.map(c2=>c2.id))}let filteredConversations=user_derived(()=>$$props.conversations.filter(conv=>(conv.name||"Untitled conversation").toLowerCase().includes(get$3(searchQuery).toLowerCase()))),allSelected=user_derived(()=>get$3(filteredConversations).length>0&&get$3(filteredConversations).every(conv=>get$3(selectedIds).has(conv.id))),someSelected=user_derived(()=>get$3(filteredConversations).some(conv=>get$3(selectedIds).has(conv.id))&&!get$3(allSelected));
|
|
|
|
|
function toggleConversation(id2,shiftKey=!1){const newSet=new SvelteSet(get$3(selectedIds));if(shiftKey&&get$3(lastClickedId)!==null){const lastIndex=get$3(filteredConversations).findIndex(c2=>c2.id===get$3(lastClickedId)),currentIndex=get$3(filteredConversations).findIndex(c2=>c2.id===id2);if(lastIndex!==-1&¤tIndex!==-1){const start2=Math.min(lastIndex,currentIndex),end=Math.max(lastIndex,currentIndex),shouldSelect=!newSet.has(id2);for(let i=start2;i<=end;i++)shouldSelect?newSet.add(get$3(
|
|
|
|
|
filteredConversations)[i].id):newSet.delete(get$3(filteredConversations)[i].id);set$1(selectedIds,newSet);return}}newSet.has(id2)?newSet.delete(id2):newSet.add(id2),set$1(selectedIds,newSet),set$1(lastClickedId,id2,!0)}function toggleAll(){if(get$3(allSelected)){const newSet=new SvelteSet(get$3(selectedIds));get$3(filteredConversations).forEach(conv=>newSet.delete(conv.id)),set$1(selectedIds,newSet)}else{const newSet=new SvelteSet(get$3(selectedIds));get$3(filteredConversations).forEach(conv=>newSet.
|
|
|
|
|
add(conv.id)),set$1(selectedIds,newSet)}}function handleConfirm(){const selected=$$props.conversations.filter(conv=>get$3(selectedIds).has(conv.id));$$props.onConfirm(selected)}function handleCancel(){set$1(selectedIds,getInitialSelectedIds()),set$1(searchQuery,""),set$1(lastClickedId,null),$$props.onCancel()}function reset$1(){set$1(selectedIds,getInitialSelectedIds()),set$1(searchQuery,""),set$1(lastClickedId,null)}var $$exports={reset:reset$1},div=root$1C(),node2=child(div);SearchInput(node2,
|
|
|
|
|
{placeholder:"Search conversations...",get value(){return get$3(searchQuery)},set value($$value){set$1(searchQuery,$$value,!0)}});var div_1=sibling(node2,2),span=child(div_1),text2=child(span),node_1=sibling(text2);{var consequent=$$anchor2=>{var text_1=text$8();template_effect(()=>set_text(text_1,`(${get$3(filteredConversations).length??""} shown)`)),append($$anchor2,text_1)};if_block(node_1,$$render=>{get$3(searchQuery)&&$$render(consequent)})}reset(span),reset(div_1);var div_2=sibling(div_1,2),
|
|
|
|
|
node_2=child(div_2);Scroll_area(node_2,{class:"h-[400px]",children:($$anchor2,$$slotProps)=>{var table2=root_2$14(),thead2=child(table2),tr2=child(thead2),th=child(tr2),node_3=child(th);Checkbox(node_3,{get checked(){return get$3(allSelected)},get indeterminate(){return get$3(someSelected)},onCheckedChange:toggleAll}),reset(th),next$1(2),reset(tr2),reset(thead2);var tbody2=sibling(thead2),node_4=child(tbody2);{var consequent_2=$$anchor3=>{var tr_1=root_3$W(),td=child(tr_1),node_5=child(td);{var consequent_1=$$anchor4=>{
|
|
|
|
|
var text_2=text$8();template_effect(()=>set_text(text_2,`No conversations found matching "${get$3(searchQuery)??""}"`)),append($$anchor4,text_2)},alternate=$$anchor4=>{var text_3=text$8("No conversations available");append($$anchor4,text_3)};if_block(node_5,$$render=>{get$3(searchQuery)?$$render(consequent_1):$$render(alternate,-1)})}reset(td),reset(tr_1),append($$anchor3,tr_1)},alternate_1=$$anchor3=>{var fragment_2=comment$2(),node_6=first_child(fragment_2);each(node_6,17,()=>get$3(filteredConversations),
|
|
|
|
|
conv=>conv.id,($$anchor4,conv)=>{var tr_2=root_7$s(),td_1=child(tr_2),node_7=child(td_1);{let $0=user_derived(()=>get$3(selectedIds).has(get$3(conv).id));Checkbox(node_7,{get checked(){return get$3($0)},onclick:event2=>{event2.preventDefault(),event2.stopPropagation(),toggleConversation(get$3(conv).id,event2.shiftKey)}})}reset(td_1);var td_2=sibling(td_1),div_3=child(td_2),text_4=child(div_3,!0);reset(div_3),reset(td_2);var td_3=sibling(td_2),text_5=child(td_3,!0);reset(td_3),reset(tr_2),template_effect(
|
|
|
|
|
$0=>{set_attribute(div_3,"title",get$3(conv).name||"Untitled conversation"),set_text(text_4,get$3(conv).name||"Untitled conversation"),set_text(text_5,$0)},[()=>messageCountMap().get(get$3(conv).id)??0]),delegated("click",tr_2,event2=>toggleConversation(get$3(conv).id,event2.shiftKey)),append($$anchor4,tr_2)}),append($$anchor3,fragment_2)};if_block(node_4,$$render=>{get$3(filteredConversations).length===0?$$render(consequent_2):$$render(alternate_1,-1)})}reset(tbody2),reset(table2),append($$anchor2,
|
|
|
|
|
table2)},$$slots:{default:!0}}),reset(div_2);var div_4=sibling(div_2,2),node_8=child(div_4);Button(node_8,{variant:"outline",onclick:handleCancel,children:($$anchor2,$$slotProps)=>{next$1();var text_6=text$8("Cancel");append($$anchor2,text_6)},$$slots:{default:!0}});var node_9=sibling(node_8,2);{let $0=user_derived(()=>get$3(selectedIds).size===0);Button(node_9,{onclick:handleConfirm,get disabled(){return get$3($0)},children:($$anchor2,$$slotProps)=>{next$1();var text_7=text$8();template_effect(
|
|
|
|
|
()=>set_text(text_7,`${$$props.mode==="export"?"Export":"Import"} (${get$3(selectedIds).size??""})`)),append($$anchor2,text_7)},$$slots:{default:!0}})}return reset(div_4),reset(div),template_effect(()=>set_text(text2,`${get$3(selectedIds).size??""} of ${$$props.conversations.length??""} selected `)),append($$anchor,div),pop($$exports)}delegate(["click"]);var root$1B=from_html('<div><button aria-label="Scroll left"><!></button> <div><!></div> <button aria-label="Scroll right"><!></button></div>');
|
|
|
|
|
function HorizontalScrollCarousel($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),gapSize=prop($$props,"gapSize",3,"3"),canScrollLeft=state$1(!1),canScrollRight=state$1(!1),scrollContainer=state$1(void 0);function scrollLeft(event2){event2?.stopPropagation(),event2?.preventDefault(),get$3(scrollContainer)&&get$3(scrollContainer).scrollBy({left:get$3(scrollContainer).clientWidth*-.67,behavior:"smooth"})}function scrollRight(event2){event2?.stopPropagation(),event2?.preventDefault(),
|
|
|
|
|
get$3(scrollContainer)&&get$3(scrollContainer).scrollBy({left:get$3(scrollContainer).clientWidth*.67,behavior:"smooth"})}function updateScrollButtons(){if(!get$3(scrollContainer))return;const{scrollLeft:scrollLeft2,scrollWidth,clientWidth}=get$3(scrollContainer);set$1(canScrollLeft,scrollLeft2>0),set$1(canScrollRight,scrollLeft2<scrollWidth-clientWidth-1);const isScrollable=scrollWidth>clientWidth;$$props.onScrollableChange?.(isScrollable)}function resetScroll(){get$3(scrollContainer)&&(get$3(scrollContainer).
|
|
|
|
|
scrollLeft=0,setTimeout(()=>{updateScrollButtons()},0))}user_effect(()=>{get$3(scrollContainer)&&setTimeout(()=>{updateScrollButtons()},0)});var $$exports={resetScroll},div=root$1B(),button=child(div),node2=child(button);Chevron_left(node2,{class:"h-4 w-4"}),reset(button);var div_1=sibling(button,2),node_1=child(div_1);snippet(node_1,()=>$$props.children??noop$3),reset(div_1),bind_this(div_1,$$value=>set$1(scrollContainer,$$value),()=>get$3(scrollContainer));var button_1=sibling(div_1,2),node_2=child(
|
|
|
|
|
button_1);return Chevron_right(node_2,{class:"h-4 w-4"}),reset(button_1),reset(div),template_effect(()=>{set_class(div,1,`relative ${className()??""}`),set_class(button,1,`absolute top-1/2 left-4 z-10 flex h-6 w-6 -translate-y-1/2 items-center justify-center rounded-full bg-background/25 shadow-md backdrop-blur-xs transition-opacity hover:bg-background/45 ${get$3(canScrollLeft)?"opacity-100":"pointer-events-none opacity-0"}`),set_class(div_1,1,`scrollbar-hide flex items-start gap-${gapSize()??""}\
|
|
|
|
|
overflow-x-auto`),set_class(button_1,1,`absolute top-1/2 right-4 z-10 flex h-6 w-6 -translate-y-1/2 items-center justify-center rounded-full bg-background/25 shadow-md backdrop-blur-xs transition-opacity hover:bg-background/45 ${get$3(canScrollRight)?"opacity-100":"pointer-events-none opacity-0"}`)}),delegated("click",button,scrollLeft),event("scroll",div_1,updateScrollButtons),delegated("click",button_1,scrollRight),append($$anchor,div),pop($$exports)}delegate(["click"]);var root_3$V=from_html(
|
|
|
|
|
'<span class="block truncate"> </span>'),root_4$B=from_html("<p> </p>"),root_2$13=from_html("<!> <!>",1),root_5$v=from_html("<span> </span>");function TruncatedText($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),showTooltip=prop($$props,"showTooltip",3,!0),textElement=state$1(void 0),isTruncated=state$1(!1);function checkTruncation(){get$3(textElement)&&set$1(isTruncated,get$3(textElement).scrollWidth>get$3(textElement).clientWidth)}user_effect(()=>{if(get$3(textElement)){
|
|
|
|
|
checkTruncation();const observer=new ResizeObserver(checkTruncation);return observer.observe(get$3(textElement)),()=>observer.disconnect()}});var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);component(node_1,()=>Root$5,($$anchor3,Tooltip_Root)=>{Tooltip_Root($$anchor3,{children:($$anchor4,$$slotProps)=>{var fragment_2=root_2$13(),node_2=first_child(fragment_2);component(node_2,()=>Tooltip_trigger,($$anchor5,Tooltip_Trigger)=>{
|
|
|
|
|
Tooltip_Trigger($$anchor5,{get class(){return`${className()??""} min-w-0`},children:($$anchor6,$$slotProps2)=>{var span=root_3$V(),text_1=child(span,!0);reset(span),bind_this(span,$$value=>set$1(textElement,$$value),()=>get$3(textElement)),template_effect(()=>set_text(text_1,$$props.text)),append($$anchor6,span)},$$slots:{default:!0}})});var node_3=sibling(node_2,2);component(node_3,()=>Tooltip_content,($$anchor5,Tooltip_Content)=>{Tooltip_Content($$anchor5,{class:"z-[9999]",children:($$anchor6,$$slotProps2)=>{
|
|
|
|
|
var p2=root_4$B(),text_2=child(p2,!0);reset(p2),template_effect(()=>set_text(text_2,$$props.text)),append($$anchor6,p2)},$$slots:{default:!0}})}),append($$anchor4,fragment_2)},$$slots:{default:!0}})}),append($$anchor2,fragment_1)},alternate=$$anchor2=>{var span_1=root_5$v(),text_3=child(span_1,!0);reset(span_1),bind_this(span_1,$$value=>set$1(textElement,$$value),()=>get$3(textElement)),template_effect(()=>{set_class(span_1,1,`${className()??""} block min-w-0 truncate`),set_text(text_3,$$props.text)}),
|
|
|
|
|
append($$anchor2,span_1)};if_block(node2,$$render=>{get$3(isTruncated)&&showTooltip()?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment),pop()}var root_3$U=from_html("<span>⌘</span>"),root_5$u=from_html("<span></span>"),root_1$T=from_html("<!> <!>",1),root$1A=from_html("<kbd></kbd>");function KeyboardShortcutInfo($$anchor,$$props){push$1($$props,!0);let variant=prop($$props,"variant",3,"default"),className=prop($$props,"class",3,""),variantClasses=user_derived(()=>variant()===
|
|
|
|
|
"destructive"?"text-destructive":"text-muted-foreground");var kbd=root$1A();each(kbd,21,()=>$$props.keys,index$2,($$anchor2,key2,index2)=>{var fragment=root_1$T(),node2=first_child(fragment);{var consequent=$$anchor3=>{{let $0=user_derived(()=>variant()==="destructive"?"text-destructive":"");Arrow_big_up($$anchor3,{get class(){return`h-1 w-1 ${get$3($0)??""} -mr-1`}})}},consequent_1=$$anchor3=>{var span=root_3$U();template_effect(()=>set_class(span,1,clsx(variant()==="destructive"?"text-destruct\
|
|
|
|
|
ive":""))),append($$anchor3,span)},alternate=$$anchor3=>{var text2=text$8();template_effect($0=>set_text(text2,$0),[()=>get$3(key2).toUpperCase()]),append($$anchor3,text2)};if_block(node2,$$render=>{get$3(key2)==="shift"?$$render(consequent):get$3(key2)==="cmd"?$$render(consequent_1,1):$$render(alternate,-1)})}var node_1=sibling(node2,2);{var consequent_2=$$anchor3=>{var span_1=root_5$u();append($$anchor3,span_1)};if_block(node_1,$$render=>{index2<$$props.keys.length-1&&$$render(consequent_2)})}
|
|
|
|
|
append($$anchor2,fragment)}),reset(kbd),template_effect(()=>set_class(kbd,1,`px-1 pointer-events-none inline-flex select-none items-center gap-0.5 font-sans text-md font-medium opacity-0 transition-opacity -my-1 ${get$3(variantClasses)??""} ${className()??""}`)),append($$anchor,kbd),pop()}var root$1z=from_html('<div class="code-block-actions"><!> <!></div>');function CodeBlockActions($$anchor,$$props){push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1);const showPreview=user_derived(()=>$$props.
|
|
|
|
|
language?.toLowerCase()===FileTypeText.HTML);var div=root$1z(),node2=child(div);{let $0=user_derived(()=>!disabled()),$1=user_derived(()=>disabled()?"Code incomplete":"Copy code");ActionIconCopyToClipboard(node2,{get text(){return $$props.code},get canCopy(){return get$3($0)},get ariaLabel(){return get$3($1)}})}var node_1=sibling(node2,2);{var consequent=$$anchor2=>{{let $0=user_derived(()=>disabled()?"Code incomplete":"Preview code");ActionIcon($$anchor2,{get icon(){return Eye},get tooltip(){return get$3(
|
|
|
|
|
$0)},get disabled(){return disabled()},onclick:()=>$$props.onPreview($$props.code,$$props.language)})}};if_block(node_1,$$render=>{get$3(showPreview)&&$$render(consequent)})}reset(div),append($$anchor,div),pop()}var root_4$A=from_html('<img class="h-12 w-12 object-cover"/>'),root_5$t=from_html('<div class="bg-foreground-muted/50 flex h-12 w-12 flex-col items-center justify-center gap-0.5 py-1"><!> <span class="font-mono text-[9px] text-white/60"> </span></div>'),root_3$T=from_html("<button><!></\
|
|
|
|
|
button>"),root_1$S=from_html('<div class="sticky bottom-0 z-10 mt-4 flex-shrink-0"><!></div>');function ChatAttachmentsPreviewThumbnailStrip($$anchor,$$props){push$1($$props,!0);function getFileExtension(name){const parts=name.split(".");return parts.length>1?parts.pop()?.toUpperCase()??"":""}var fragment=comment$2(),node2=first_child(fragment);{var consequent_2=$$anchor2=>{var div=root_1$S(),node_1=child(div);HorizontalScrollCarousel(node_1,{class:"max-w-full",children:($$anchor3,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node_2=first_child(fragment_1);each(node_2,19,()=>$$props.items,item=>item.id,($$anchor4,item,index2)=>{var button=root_3$T(),node_3=child(button);{var consequent=$$anchor5=>{var img=root_4$A();template_effect(()=>{set_attribute(img,"src",get$3(item).preview),set_attribute(img,"alt",get$3(item).name)}),append($$anchor5,img)},alternate_1=$$anchor5=>{var div_1=root_5$t(),node_4=child(div_1);{var consequent_1=$$anchor6=>{Music($$anchor6,{class:"h-4 w-4 text-white/70"})},alternate=$$anchor6=>{
|
|
|
|
|
File_text($$anchor6,{class:"h-4 w-4 text-white/70"})};if_block(node_4,$$render=>{get$3(item).isAudio?$$render(consequent_1):$$render(alternate,-1)})}var span=sibling(node_4,2),text2=child(span,!0);reset(span),reset(div_1),template_effect($0=>set_text(text2,$0),[()=>getFileExtension(get$3(item).name)]),append($$anchor5,div_1)};if_block(node_3,$$render=>{get$3(item).isImage&&get$3(item).preview?$$render(consequent):$$render(alternate_1,-1)})}reset(button),template_effect(()=>{set_attribute(button,
|
|
|
|
|
"data-thumbnail-index",get$3(index2)),set_class(button,1,clsx(["relative flex-shrink-0 cursor-pointer overflow-hidden rounded border-2 bg-black/80 backdrop-blur-sm transition-all hover:opacity-90",get$3(index2)===$$props.currentIndex?"border-white":"border-transparent opacity-60","[&:not(:first-child)]:last:mr-4 [&:not(:last-child)]:first:ml-4"])),set_attribute(button,"aria-label",`Go to ${get$3(item).name}`)}),delegated("click",button,()=>$$props.onNavigate(get$3(index2))),append($$anchor4,button)}),
|
|
|
|
|
append($$anchor3,fragment_1)},$$slots:{default:!0}}),reset(div),append($$anchor2,div)};if_block(node2,$$render=>{$$props.items.length>1&&$$render(consequent_2)})}append($$anchor,fragment),pop()}delegate(["click"]);const alertVariants=tv({base:"relative grid w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",variants:{variant:{default:"b\
|
|
|
|
|
g-card text-card-foreground",destructive:"text-destructive bg-card *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current"}},defaultVariants:{variant:"default"}});var root$1y=from_html("<div><!></div>");function Alert($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),variant=prop($$props,"variant",3,"default"),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","variant","children"]);var div=root$1y();attribute_effect(div,$0=>({"d\
|
|
|
|
|
ata-slot":"alert",class:$0,...restProps,role:"alert"}),[()=>cn$1(alertVariants({variant:variant()}),$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root$1x=from_html("<div><!></div>");function Alert_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$1x();
|
|
|
|
|
attribute_effect(div,$0=>({"data-slot":"alert-description",class:$0,...restProps}),[()=>cn$1("col-start-2 grid justify-items-start gap-1 text-sm text-muted-foreground [&_p]:leading-relaxed",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root$1w=from_html("<div><!></div>");function Alert_title($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$1w();attribute_effect(div,$0=>({"data-slot":"alert-title",class:$0,...restProps}),[()=>cn$1("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}class AudioRecorder{mediaRecorder=null;audioChunks=[];stream=null;recordingState=!1;async startRecording(){
|
|
|
|
|
try{this.stream=await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0}}),this.initializeRecorder(this.stream),this.audioChunks=[],this.mediaRecorder.start(100),this.recordingState=!0}catch(error2){throw console.error("Failed to start recording:",error2),new Error("Failed to access microphone. Please check permissions.")}}async stopRecording(){return new Promise((resolve2,reject)=>{const recorder=this.mediaRecorder,chunks=this.audioChunks,stream=this.
|
|
|
|
|
stream;if(!recorder||recorder.state==="inactive"){reject(new Error("No active recording to stop"));return}this.mediaRecorder=null,this.audioChunks=[],this.stream=null,this.recordingState=!1,recorder.onstop=()=>{const audioBlob=new Blob(chunks,{type:recorder.mimeType||MimeTypeAudio.WAV});if(stream)for(const track2 of stream.getTracks())track2.stop();resolve2(audioBlob)},recorder.onerror=event2=>{if(console.error("Recording error:",event2),stream)for(const track2 of stream.getTracks())track2.stop();
|
|
|
|
|
reject(new Error("Recording failed"))},recorder.stop()})}isRecording(){return this.recordingState}cancelRecording(){const recorder=this.mediaRecorder,stream=this.stream;if(this.mediaRecorder=null,this.audioChunks=[],this.stream=null,this.recordingState=!1,recorder&&recorder.state!=="inactive"&&(recorder.onstop=null,recorder.onerror=null,recorder.stop()),stream)for(const track2 of stream.getTracks())track2.stop()}initializeRecorder(stream){const options={};MediaRecorder.isTypeSupported(MimeTypeAudio.
|
|
|
|
|
WAV)?options.mimeType=MimeTypeAudio.WAV:MediaRecorder.isTypeSupported(MimeTypeAudio.WEBM_OPUS)?options.mimeType=MimeTypeAudio.WEBM_OPUS:MediaRecorder.isTypeSupported(MimeTypeAudio.WEBM)?options.mimeType=MimeTypeAudio.WEBM:MediaRecorder.isTypeSupported(MimeTypeAudio.MP4)?options.mimeType=MimeTypeAudio.MP4:console.warn("No preferred audio format supported, using default"),this.mediaRecorder=new MediaRecorder(stream,options),this.mediaRecorder.ondataavailable=event2=>{event2.data.size>0&&this.audioChunks.
|
|
|
|
|
@@ -6533,126 +6533,127 @@ return showModelSelector()},get uploadedFiles(){return uploadedFiles()},onFileUp
|
|
|
|
|
node_6,{get preSelectedUri(){return get$3(preSelectedResourceUri)},onAttach:resource=>{mcpStore.attachResource(resource.uri)},onOpenChange:newOpen=>{newOpen||set$1(preSelectedResourceUri,void 0)},get open(){return get$3(isResourceDialogOpen)},set open($$value){set$1(isResourceDialogOpen,$$value,!0)}}),template_effect(()=>{set_class(form,1,`relative ${className()??""}`),set_class(div,1,`${INPUT_CLASSES??""} overflow-hidden rounded-3xl backdrop-blur-md ${disabled()?"cursor-not-allowed opacity-60":
|
|
|
|
|
""}`)}),event("submit",form,event2=>{event2.preventDefault(),!(!get$3(canSubmit)||disabled()||get$3(hasLoadingAttachments))&&$$props.onSubmit?.()}),event("paste",div_1,handlePaste),append($$anchor,fragment),pop($$exports)}function Dropdown_menu_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),sideOffset=prop($$props,"sideOffset",3,4),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","sideOffset","portalProps","class"]);var fragment=comment$2(),node2=first_child(
|
|
|
|
|
fragment);component(node2,()=>Portal$2,($$anchor2,DropdownMenuPrimitive_Portal)=>{DropdownMenuPrimitive_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);{let $0=user_derived(()=>cn$1("z-50 max-h-(--bits-dropdown-menu-content-available-height) min-w-[8rem] origin-(--bits-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border border-border bg-popover p-1.5 text-po\
|
|
|
|
|
pover-foreground shadow-md outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 dark:border-border/20",$$props.class));component(node_1,()=>Dropdown_menu_content$1,($$anchor4,DropdownMenuPrimitive_Content)=>{
|
|
|
|
|
DropdownMenuPrimitive_Content($$anchor4,spread_props({"data-slot":"dropdown-menu-content",get sideOffset(){return sideOffset()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}function Dropdown_menu_item($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),variant=prop($$props,"variant",3,"default"),restProps=rest_props($$props,[
|
|
|
|
|
"$$slots","$$events","$$legacy","ref","class","inset","variant"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("relative flex cursor-pointer items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-highlighted:bg-accent data-highlighted:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 data-[variant=destructive]:text-destructive data-[variant=destructive]:data-highlighted:bg-destr\
|
|
|
|
|
uctive/10 data-[variant=destructive]:data-highlighted:text-destructive dark:data-[variant=destructive]:data-highlighted:bg-destructive/20 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground data-[variant=destructive]:*:[svg]:!text-destructive",$$props.class));component(node2,()=>Menu_item,($$anchor2,DropdownMenuPrimitive_Item)=>{DropdownMenuPrimitive_Item($$anchor2,spread_props({"data-slot":"dropdown-menu-item",get"\
|
|
|
|
|
data-inset"(){return $$props.inset},get"data-variant"(){return variant()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Dropdown_menu_separator($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("-mx-1 my-1 h-px b\
|
|
|
|
|
g-border/20",$$props.class));component(node2,()=>Menu_separator,($$anchor2,DropdownMenuPrimitive_Separator)=>{DropdownMenuPrimitive_Separator($$anchor2,spread_props({"data-slot":"dropdown-menu-separator",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Dropdown_menu_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events",
|
|
|
|
|
"$$legacy","ref"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Menu_trigger,($$anchor2,DropdownMenuPrimitive_Trigger)=>{DropdownMenuPrimitive_Trigger($$anchor2,spread_props({"data-slot":"dropdown-menu-trigger"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))}),append($$anchor,fragment),pop()}function Dropdown_menu_sub_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$\
|
|
|
|
|
$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("z-50 max-h-(--bits-dropdown-menu-content-available-height) min-w-[8rem] origin-(--bits-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border border-border bg-popover p-1.5 text-popover-foreground shadow-md outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[\
|
|
|
|
|
side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 dark:border-border/20",$$props.class));component(node2,()=>Menu_sub_content,($$anchor2,DropdownMenuPrimitive_SubContent)=>{DropdownMenuPrimitive_SubContent($$anchor2,spread_props({"data-slot":"dropdown-menu-sub-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},
|
|
|
|
|
set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_1$N=from_html("<!> <!>",1);function Dropdown_menu_sub_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","inset","children"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-hig\
|
|
|
|
|
hlighted:bg-accent data-highlighted:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground",$$props.class));component(node2,()=>Menu_sub_trigger,($$anchor2,DropdownMenuPrimitive_SubTrigger)=>{DropdownMenuPrimitive_SubTrigger($$anchor2,spread_props(
|
|
|
|
|
{"data-slot":"dropdown-menu-sub-trigger",get"data-inset"(){return $$props.inset},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$N(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);Chevron_right(node_2,{class:"ml-auto size-4"}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}const Sub=Menu_sub,
|
|
|
|
|
Root$4=Menu;function useAttachmentMenu(getFlags,getCallbacks,close2){const modalityFlags=user_derived(getFlags),callbacks=user_derived(()=>{const cbs=getCallbacks(),wrap2=fn=>()=>{close2(),fn?.()};return{[AttachmentAction.FILE_UPLOAD]:wrap2(cbs.onFileUpload),[AttachmentAction.SYSTEM_PROMPT_CLICK]:wrap2(cbs.onSystemPromptClick),[AttachmentAction.MCP_PROMPT_CLICK]:wrap2(cbs.onMcpPromptClick),[AttachmentAction.MCP_RESOURCES_CLICK]:wrap2(cbs.onMcpResourcesClick)}});function isItemEnabled(enabledWhen){
|
|
|
|
|
return!enabledWhen||enabledWhen==="always"?!0:!!get$3(modalityFlags)[enabledWhen]}function isItemVisible(visibleWhen){return visibleWhen?!!get$3(modalityFlags)[visibleWhen]:!0}function getSystemMessageTooltip(){return page$1.params.id?"Inject custom system message at the beginning of the conversation":"Add custom system message for a new conversation"}return{get callbacks(){return get$3(callbacks)},isItemEnabled,isItemVisible,getSystemMessageTooltip}}var root_6$t=from_html("<!> <span> </span>",1),
|
|
|
|
|
root_10$e=from_html("<!> <span> </span>",1),root_11$e=from_html("<p> </p>"),root_8$q=from_html("<!> <!>",1),root_16$5=from_html("<!> <span> </span>",1),root_17$8=from_html("<p>PDFs will be converted to text. Image-based PDFs may not work properly.</p>"),root_13$b=from_html("<!> <!>",1),root_22$1=from_html("<!> <span> </span>",1),root_23$5=from_html("<p> </p>"),root_20$4=from_html("<!> <!>",1),root_26$1=from_html("<!> <span> </span>",1),root_3$R=from_html("<!> <!> <!> <!> <!> <!> <!>",1),root_1$M=from_html(
|
|
|
|
|
"<!> <!>",1),root$1r=from_html("<div><!></div>");function ChatFormActionAddDropdown($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),hasVisionModality=prop($$props,"hasVisionModality",3,!1),hasMcpPromptsSupport=prop($$props,"hasMcpPromptsSupport",3,!1),hasMcpResourcesSupport=prop($$props,"hasMcpResourcesSupport",3,!1),dropdownOpen=state$1(!1);function handleMcpSettingsClick(){
|
|
|
|
|
set$1(dropdownOpen,!1),$$props.onMcpSettingsClick?.()}const attachmentMenu=useAttachmentMenu(()=>({hasVisionModality:hasVisionModality(),hasAudioModality:hasAudioModality(),hasMcpPromptsSupport:hasMcpPromptsSupport(),hasMcpResourcesSupport:hasMcpResourcesSupport()}),()=>({onFileUpload:$$props.onFileUpload,onSystemPromptClick:$$props.onSystemPromptClick,onMcpPromptClick:$$props.onMcpPromptClick,onMcpResourcesClick:$$props.onMcpResourcesClick}),()=>{set$1(dropdownOpen,!1)});var div=root$1r(),node2=child(
|
|
|
|
|
div);component(node2,()=>Root$4,($$anchor2,DropdownMenu_Root)=>{DropdownMenu_Root($$anchor2,{get open(){return get$3(dropdownOpen)},set open($$value){set$1(dropdownOpen,$$value,!0)},children:($$anchor3,$$slotProps)=>{var fragment=root_1$M(),node_1=first_child(fragment);component(node_1,()=>Dropdown_menu_trigger,($$anchor4,DropdownMenu_Trigger)=>{DropdownMenu_Trigger($$anchor4,{name:"Attach files",get disabled(){return disabled()},children:($$anchor5,$$slotProps2)=>{var fragment_1=comment$2(),node_2=first_child(
|
|
|
|
|
fragment_1);snippet(node_2,()=>$$props.trigger,()=>({disabled:disabled()})),append($$anchor5,fragment_1)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Dropdown_menu_content,($$anchor4,DropdownMenu_Content)=>{DropdownMenu_Content($$anchor4,{align:"start",class:"w-48",children:($$anchor5,$$slotProps2)=>{var fragment_2=root_3$R(),node_4=first_child(fragment_2);each(node_4,17,()=>ATTACHMENT_FILE_ITEMS,item=>item.id,($$anchor6,item)=>{const enabled=user_derived(()=>attachmentMenu.
|
|
|
|
|
isItemEnabled(get$3(item).enabledWhen));var fragment_3=comment$2(),node_5=first_child(fragment_3);{var consequent=$$anchor7=>{var fragment_4=comment$2(),node_6=first_child(fragment_4);{let $0=user_derived(()=>get$3(item).class??"");component(node_6,()=>Dropdown_menu_item,($$anchor8,DropdownMenu_Item)=>{DropdownMenu_Item($$anchor8,{get class(){return`${get$3($0)??""} flex cursor-pointer items-center gap-2`},onclick:()=>attachmentMenu.callbacks[get$3(item).action](),children:($$anchor9,$$slotProps3)=>{
|
|
|
|
|
var fragment_5=root_6$t(),node_7=first_child(fragment_5);component(node_7,()=>get$3(item).icon,($$anchor10,item_icon)=>{item_icon($$anchor10,{class:"h-4 w-4"})});var span=sibling(node_7,2),text2=child(span,!0);reset(span),template_effect(()=>set_text(text2,get$3(item).label)),append($$anchor9,fragment_5)},$$slots:{default:!0}})})}append($$anchor7,fragment_4)},consequent_1=$$anchor7=>{var fragment_6=comment$2(),node_8=first_child(fragment_6);component(node_8,()=>Root$5,($$anchor8,Tooltip_Root)=>{
|
|
|
|
|
Tooltip_Root($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_7=root_8$q(),node_9=first_child(fragment_7);component(node_9,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor10,{class:"w-full",children:($$anchor11,$$slotProps4)=>{var fragment_8=comment$2(),node_10=first_child(fragment_8);{let $0=user_derived(()=>get$3(item).class??"");component(node_10,()=>Dropdown_menu_item,($$anchor12,DropdownMenu_Item_1)=>{DropdownMenu_Item_1(
|
|
|
|
|
$$anchor12,{get class(){return`${get$3($0)??""} flex cursor-pointer items-center gap-2`},disabled:!0,children:($$anchor13,$$slotProps5)=>{var fragment_9=root_10$e(),node_11=first_child(fragment_9);component(node_11,()=>get$3(item).icon,($$anchor14,item_icon_1)=>{item_icon_1($$anchor14,{class:"h-4 w-4"})});var span_1=sibling(node_11,2),text_1=child(span_1,!0);reset(span_1),template_effect(()=>set_text(text_1,get$3(item).label)),append($$anchor13,fragment_9)},$$slots:{default:!0}})})}append($$anchor11,
|
|
|
|
|
fragment_8)},$$slots:{default:!0}})});var node_12=sibling(node_9,2);component(node_12,()=>Tooltip_content,($$anchor10,Tooltip_Content)=>{Tooltip_Content($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p2=root_11$e(),text_2=child(p2,!0);reset(p2),template_effect(()=>set_text(text_2,get$3(item).disabledTooltip)),append($$anchor11,p2)},$$slots:{default:!0}})}),append($$anchor9,fragment_7)},$$slots:{default:!0}})}),append($$anchor7,fragment_6)};if_block(node_5,$$render=>{get$3(enabled)?
|
|
|
|
|
$$render(consequent):get$3(item).disabledTooltip&&$$render(consequent_1,1)})}append($$anchor6,fragment_3)});var node_13=sibling(node_4,2);{var consequent_3=$$anchor6=>{var fragment_10=comment$2(),node_14=first_child(fragment_10);component(node_14,()=>Root$5,($$anchor7,Tooltip_Root_1)=>{Tooltip_Root_1($$anchor7,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor8,$$slotProps3)=>{var fragment_11=root_13$b(),node_15=first_child(fragment_11);component(node_15,()=>Tooltip_trigger,($$anchor9,Tooltip_Trigger_1)=>{
|
|
|
|
|
Tooltip_Trigger_1($$anchor9,{class:"w-full",children:($$anchor10,$$slotProps4)=>{var fragment_12=comment$2(),node_16=first_child(fragment_12);component(node_16,()=>Dropdown_menu_item,($$anchor11,DropdownMenu_Item_2)=>{DropdownMenu_Item_2($$anchor11,{class:"flex cursor-pointer items-center gap-2",get onclick(){return attachmentMenu.callbacks.onFileUpload},children:($$anchor12,$$slotProps5)=>{const pdfItem=user_derived(()=>ATTACHMENT_FILE_ITEMS.find(i=>i.id===AttachmentMenuItemId.PDF));var fragment_13=comment$2(),
|
|
|
|
|
node_17=first_child(fragment_13);{var consequent_2=$$anchor13=>{var fragment_14=root_16$5(),node_18=first_child(fragment_14);component(node_18,()=>get$3(pdfItem).icon,($$anchor14,pdfItem_icon)=>{pdfItem_icon($$anchor14,{class:"h-4 w-4"})});var span_2=sibling(node_18,2),text_3=child(span_2,!0);reset(span_2),template_effect(()=>set_text(text_3,get$3(pdfItem).label)),append($$anchor13,fragment_14)};if_block(node_17,$$render=>{get$3(pdfItem)&&$$render(consequent_2)})}append($$anchor12,fragment_13)},
|
|
|
|
|
$$slots:{default:!0}})}),append($$anchor10,fragment_12)},$$slots:{default:!0}})});var node_19=sibling(node_15,2);component(node_19,()=>Tooltip_content,($$anchor9,Tooltip_Content_1)=>{Tooltip_Content_1($$anchor9,{side:"right",children:($$anchor10,$$slotProps4)=>{var p_1=root_17$8();append($$anchor10,p_1)},$$slots:{default:!0}})}),append($$anchor8,fragment_11)},$$slots:{default:!0}})}),append($$anchor6,fragment_10)},d2=user_derived(()=>!attachmentMenu.isItemEnabled("hasVisionModality"));if_block(node_13,
|
|
|
|
|
$$render=>{get$3(d2)&&$$render(consequent_3)})}var node_20=sibling(node_13,2);component(node_20,()=>Dropdown_menu_separator,($$anchor6,DropdownMenu_Separator)=>{DropdownMenu_Separator($$anchor6,{})});var node_21=sibling(node_20,2);each(node_21,17,()=>ATTACHMENT_EXTRA_ITEMS,item=>item.id,($$anchor6,item)=>{var fragment_15=comment$2(),node_22=first_child(fragment_15);{var consequent_4=$$anchor7=>{var fragment_16=comment$2(),node_23=first_child(fragment_16);component(node_23,()=>Root$5,($$anchor8,Tooltip_Root_2)=>{
|
|
|
|
|
Tooltip_Root_2($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_17=root_20$4(),node_24=first_child(fragment_17);component(node_24,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger_2)=>{Tooltip_Trigger_2($$anchor10,{class:"w-full",children:($$anchor11,$$slotProps4)=>{var fragment_18=comment$2(),node_25=first_child(fragment_18);component(node_25,()=>Dropdown_menu_item,($$anchor12,DropdownMenu_Item_3)=>{DropdownMenu_Item_3($$anchor12,{class:"\
|
|
|
|
|
flex cursor-pointer items-center gap-2",onclick:()=>attachmentMenu.callbacks[get$3(item).action](),children:($$anchor13,$$slotProps5)=>{var fragment_19=root_22$1(),node_26=first_child(fragment_19);component(node_26,()=>get$3(item).icon,($$anchor14,item_icon_2)=>{item_icon_2($$anchor14,{class:"h-4 w-4"})});var span_3=sibling(node_26,2),text_4=child(span_3,!0);reset(span_3),template_effect(()=>set_text(text_4,get$3(item).label)),append($$anchor13,fragment_19)},$$slots:{default:!0}})}),append($$anchor11,
|
|
|
|
|
fragment_18)},$$slots:{default:!0}})});var node_27=sibling(node_24,2);component(node_27,()=>Tooltip_content,($$anchor10,Tooltip_Content_2)=>{Tooltip_Content_2($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p_2=root_23$5(),text_5=child(p_2,!0);reset(p_2),template_effect($0=>set_text(text_5,$0),[()=>attachmentMenu.getSystemMessageTooltip()]),append($$anchor11,p_2)},$$slots:{default:!0}})}),append($$anchor9,fragment_17)},$$slots:{default:!0}})}),append($$anchor7,fragment_16)};if_block(
|
|
|
|
|
node_22,$$render=>{get$3(item).id===AttachmentMenuItemId.SYSTEM_MESSAGE&&$$render(consequent_4)})}append($$anchor6,fragment_15)});var node_28=sibling(node_21,2);ChatFormActionAddToolsSubmenu(node_28,{});var node_29=sibling(node_28,2);ChatFormActionAddMcpServersSubmenu(node_29,{onMcpSettingsClick:handleMcpSettingsClick});var node_30=sibling(node_29,2);each(node_30,17,()=>ATTACHMENT_MCP_ITEMS,item=>item.id,($$anchor6,item)=>{var fragment_20=comment$2(),node_31=first_child(fragment_20);{var consequent_5=$$anchor7=>{
|
|
|
|
|
var fragment_21=comment$2(),node_32=first_child(fragment_21);component(node_32,()=>Dropdown_menu_item,($$anchor8,DropdownMenu_Item_4)=>{DropdownMenu_Item_4($$anchor8,{class:"flex cursor-pointer items-center gap-2",onclick:()=>attachmentMenu.callbacks[get$3(item).action](),children:($$anchor9,$$slotProps3)=>{var fragment_22=root_26$1(),node_33=first_child(fragment_22);component(node_33,()=>get$3(item).icon,($$anchor10,item_icon_3)=>{item_icon_3($$anchor10,{class:"h-4 w-4"})});var span_4=sibling(node_33,
|
|
|
|
|
2),text_6=child(span_4,!0);reset(span_4),template_effect(()=>set_text(text_6,get$3(item).label)),append($$anchor9,fragment_22)},$$slots:{default:!0}})}),append($$anchor7,fragment_21)},d_12=user_derived(()=>attachmentMenu.isItemVisible(get$3(item).visibleWhen));if_block(node_31,$$render=>{get$3(d_12)&&$$render(consequent_5)})}append($$anchor6,fragment_20)}),append($$anchor5,fragment_2)},$$slots:{default:!0}})}),append($$anchor3,fragment)},$$slots:{default:!0}})}),reset(div),template_effect(()=>set_class(
|
|
|
|
|
div,1,`flex items-center gap-1 ${className()??""}`)),append($$anchor,div),pop()}function Sheet_overlay($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0",$$props.class));
|
|
|
|
|
component(node2,()=>Dialog_overlay$1,($$anchor2,SheetPrimitive_Overlay)=>{SheetPrimitive_Overlay($$anchor2,spread_props({"data-slot":"sheet-overlay",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const sheetVariants=tv({base:`border-border/30 dark:border-border/20 data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-sm transition ease-in-out data-[state=close\
|
|
|
|
|
d]:duration-300 data-[state=open]:duration-500 ${PANEL_CLASSES}`,variants:{side:{top:"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",bottom:"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",left:"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",right:"data-[state=closed]:slide-out-to-right data-[\
|
|
|
|
|
state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm"}},defaultVariants:{side:"right"}});var root_3$Q=from_html('<!> <span class="sr-only">Close</span>',1),root_2$10=from_html("<!> <!>",1),root_1$L=from_html("<!> <!>",1);function Sheet_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),side=prop($$props,"side",3,"right"),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","side","portalProps","children"]);var fragment=comment$2(),
|
|
|
|
|
node2=first_child(fragment);component(node2,()=>Portal$2,($$anchor2,SheetPrimitive_Portal)=>{SheetPrimitive_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$L(),node_1=first_child(fragment_1);Sheet_overlay(node_1,{});var node_2=sibling(node_1,2);{let $0=user_derived(()=>cn$1(sheetVariants({side:side()}),$$props.class));component(node_2,()=>Dialog_content$1,($$anchor4,SheetPrimitive_Content)=>{SheetPrimitive_Content($$anchor4,spread_props(
|
|
|
|
|
{"data-slot":"sheet-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$10(),node_3=first_child(fragment_2);snippet(node_3,()=>$$props.children??noop$3);var node_4=sibling(node_3,2);component(node_4,()=>Dialog_close,($$anchor6,SheetPrimitive_Close)=>{SheetPrimitive_Close($$anchor6,{class:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover\
|
|
|
|
|
:opacity-100 focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:outline-hidden disabled:pointer-events-none",children:($$anchor7,$$slotProps3)=>{var fragment_3=root_3$Q(),node_5=first_child(fragment_3);X(node_5,{class:"size-4"}),next$1(2),append($$anchor7,fragment_3)},$$slots:{default:!0}})}),append($$anchor5,fragment_2)},$$slots:{default:!0}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}var root$1q=from_html("<di\
|
|
|
|
|
v><!></div>");function Sheet_header($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$1q();attribute_effect(div,$0=>({"data-slot":"sheet-header",class:$0,...restProps}),[()=>cn$1("flex flex-col gap-1.5 p-4",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}
|
|
|
|
|
function Sheet_title($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("font-semibold text-foreground",$$props.class));component(node2,()=>Dialog_title$1,($$anchor2,SheetPrimitive_Title)=>{SheetPrimitive_Title($$anchor2,spread_props({"data-slot":"sheet-title",get class(){return get$3($0)}},()=>restProps,{get ref(){
|
|
|
|
|
return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Sheet_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-sm text-muted-foreground",$$props.class));component(node2,()=>Dialog_description$1,($$anchor2,SheetPrimitive_Description)=>{SheetPrimitive_Description(
|
|
|
|
|
$$anchor2,spread_props({"data-slot":"sheet-description",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const Root$3=Dialog;var root_3$P=from_html("<!> <!>",1),root_7$r=from_html('<button type="button"><!> <span> </span></button>'),root_10$d=from_html('<button type="button" disabled=""><!> <span> </span></button>'),root_11$d=from_html("<p> </p>"),root_9$k=from_html("<!> <!>",1),root_15$9=from_html('<butto\
|
|
|
|
|
n type="button"><!> <span> </span></button>'),root_16$4=from_html("<p>PDFs will be converted to text. Image-based PDFs may not work properly.</p>"),root_14$6=from_html("<!> <!>",1),root_20$3=from_html('<button type="button"><!> <span> </span></button>'),root_21$4=from_html("<p> </p>"),root_19$9=from_html("<!> <!>",1),root_23$4=from_html('<button type="button"><!> <span> </span></button>'),root_2$$=from_html('<!> <div class="flex flex-col gap-1 px-1.5 pb-2"><!> <!> <!> <div class="my-2 border-t">\
|
|
|
|
|
</div> <a href="#/settings/mcp" class="flex items-center gap-3 px-3 py-2"><!> <span class="text-sm">MCP Servers</span></a> <a href="#/settings/chat/tools" class="flex items-center gap-3 px-3 py-2"><!> <span class="text-sm">Tools</span></a> <!></div>',1),root_1$K=from_html("<!> <!>",1),root$1p=from_html("<div><!></div>");function ChatFormActionAddSheet($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,
|
|
|
|
|
"hasAudioModality",3,!1),hasVisionModality=prop($$props,"hasVisionModality",3,!1),hasMcpPromptsSupport=prop($$props,"hasMcpPromptsSupport",3,!1),hasMcpResourcesSupport=prop($$props,"hasMcpResourcesSupport",3,!1),sheetOpen=state$1(!1);const attachmentMenu=useAttachmentMenu(()=>({hasVisionModality:hasVisionModality(),hasAudioModality:hasAudioModality(),hasMcpPromptsSupport:hasMcpPromptsSupport(),hasMcpResourcesSupport:hasMcpResourcesSupport()}),()=>({onFileUpload:$$props.onFileUpload,onSystemPromptClick:$$props.
|
|
|
|
|
onSystemPromptClick,onMcpPromptClick:$$props.onMcpPromptClick,onMcpResourcesClick:$$props.onMcpResourcesClick}),()=>{set$1(sheetOpen,!1)}),sheetItemClass="flex w-full items-center gap-3 rounded-md px-3 py-2.5 text-left text-sm transition-colors hover:bg-accent active:bg-accent disabled:cursor-not-allowed disabled:opacity-50";var div=root$1p(),node2=child(div);component(node2,()=>Root$3,($$anchor2,Sheet_Root)=>{Sheet_Root($$anchor2,{get open(){return get$3(sheetOpen)},set open($$value){set$1(sheetOpen,
|
|
|
|
|
$$value,!0)},children:($$anchor3,$$slotProps)=>{var fragment=root_1$K(),node_1=first_child(fragment);snippet(node_1,()=>$$props.trigger,()=>({disabled:disabled(),onclick:()=>set$1(sheetOpen,!0)}));var node_2=sibling(node_1,2);component(node_2,()=>Sheet_content,($$anchor4,Sheet_Content)=>{Sheet_Content($$anchor4,{side:"bottom",class:"max-h-[85vh] gap-0 overflow-y-auto",children:($$anchor5,$$slotProps2)=>{var fragment_1=root_2$$(),node_3=first_child(fragment_1);component(node_3,()=>Sheet_header,($$anchor6,Sheet_Header)=>{
|
|
|
|
|
Sheet_Header($$anchor6,{children:($$anchor7,$$slotProps3)=>{var fragment_2=root_3$P(),node_4=first_child(fragment_2);component(node_4,()=>Sheet_title,($$anchor8,Sheet_Title)=>{Sheet_Title($$anchor8,{children:($$anchor9,$$slotProps4)=>{next$1();var text2=text$8("Add to chat");append($$anchor9,text2)},$$slots:{default:!0}})});var node_5=sibling(node_4,2);component(node_5,()=>Sheet_description,($$anchor8,Sheet_Description)=>{Sheet_Description($$anchor8,{class:"sr-only",children:($$anchor9,$$slotProps4)=>{
|
|
|
|
|
next$1();var text_1=text$8("Add files, system prompt or configure MCP servers");append($$anchor9,text_1)},$$slots:{default:!0}})}),append($$anchor7,fragment_2)},$$slots:{default:!0}})});var div_1=sibling(node_3,2),node_6=child(div_1);each(node_6,17,()=>ATTACHMENT_FILE_ITEMS,item=>item.id,($$anchor6,item)=>{const enabled=user_derived(()=>attachmentMenu.isItemEnabled(get$3(item).enabledWhen));var fragment_3=comment$2(),node_7=first_child(fragment_3);{var consequent=$$anchor7=>{var button=root_7$r();
|
|
|
|
|
set_class(button,1,clsx(sheetItemClass));var node_8=child(button);component(node_8,()=>get$3(item).icon,($$anchor8,item_icon)=>{item_icon($$anchor8,{class:"h-4 w-4 shrink-0"})});var span=sibling(node_8,2),text_2=child(span,!0);reset(span),reset(button),template_effect(()=>set_text(text_2,get$3(item).label)),delegated("click",button,()=>attachmentMenu.callbacks[get$3(item).action]()),append($$anchor7,button)},consequent_1=$$anchor7=>{var fragment_4=comment$2(),node_9=first_child(fragment_4);component(
|
|
|
|
|
node_9,()=>Root$5,($$anchor8,Tooltip_Root)=>{Tooltip_Root($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_5=root_9$k(),node_10=first_child(fragment_5);component(node_10,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor10,{children:($$anchor11,$$slotProps4)=>{var button_1=root_10$d();set_class(button_1,1,clsx(sheetItemClass));var node_11=child(button_1);component(node_11,()=>get$3(item).icon,($$anchor12,item_icon_1)=>{
|
|
|
|
|
item_icon_1($$anchor12,{class:"h-4 w-4 shrink-0"})});var span_1=sibling(node_11,2),text_3=child(span_1,!0);reset(span_1),reset(button_1),template_effect(()=>set_text(text_3,get$3(item).label)),append($$anchor11,button_1)},$$slots:{default:!0}})});var node_12=sibling(node_10,2);component(node_12,()=>Tooltip_content,($$anchor10,Tooltip_Content)=>{Tooltip_Content($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p2=root_11$d(),text_4=child(p2,!0);reset(p2),template_effect(()=>set_text(
|
|
|
|
|
text_4,get$3(item).disabledTooltip)),append($$anchor11,p2)},$$slots:{default:!0}})}),append($$anchor9,fragment_5)},$$slots:{default:!0}})}),append($$anchor7,fragment_4)};if_block(node_7,$$render=>{get$3(enabled)?$$render(consequent):get$3(item).disabledTooltip&&$$render(consequent_1,1)})}append($$anchor6,fragment_3)});var node_13=sibling(node_6,2);{var consequent_3=$$anchor6=>{const pdfItem=user_derived(()=>ATTACHMENT_FILE_ITEMS.find(i=>i.id===AttachmentMenuItemId.PDF));var fragment_6=comment$2(),
|
|
|
|
|
node_14=first_child(fragment_6);{var consequent_2=$$anchor7=>{var fragment_7=comment$2(),node_15=first_child(fragment_7);component(node_15,()=>Root$5,($$anchor8,Tooltip_Root_1)=>{Tooltip_Root_1($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_8=root_14$6(),node_16=first_child(fragment_8);component(node_16,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger_1)=>{Tooltip_Trigger_1($$anchor10,{children:($$anchor11,$$slotProps4)=>{var button_2=root_15$9();
|
|
|
|
|
set_class(button_2,1,clsx(sheetItemClass));var node_17=child(button_2);component(node_17,()=>get$3(pdfItem).icon,($$anchor12,pdfItem_icon)=>{pdfItem_icon($$anchor12,{class:"h-4 w-4 shrink-0"})});var span_2=sibling(node_17,2),text_5=child(span_2,!0);reset(span_2),reset(button_2),template_effect(()=>set_text(text_5,get$3(pdfItem).label)),delegated("click",button_2,()=>attachmentMenu.callbacks[get$3(pdfItem).action]()),append($$anchor11,button_2)},$$slots:{default:!0}})});var node_18=sibling(node_16,
|
|
|
|
|
2);component(node_18,()=>Tooltip_content,($$anchor10,Tooltip_Content_1)=>{Tooltip_Content_1($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p_1=root_16$4();append($$anchor11,p_1)},$$slots:{default:!0}})}),append($$anchor9,fragment_8)},$$slots:{default:!0}})}),append($$anchor7,fragment_7)};if_block(node_14,$$render=>{get$3(pdfItem)&&$$render(consequent_2)})}append($$anchor6,fragment_6)},d2=user_derived(()=>!attachmentMenu.isItemEnabled("hasVisionModality"));if_block(node_13,$$render=>{
|
|
|
|
|
get$3(d2)&&$$render(consequent_3)})}var node_19=sibling(node_13,2);each(node_19,17,()=>ATTACHMENT_EXTRA_ITEMS,item=>item.id,($$anchor6,item)=>{var fragment_9=comment$2(),node_20=first_child(fragment_9);{var consequent_4=$$anchor7=>{var fragment_10=comment$2(),node_21=first_child(fragment_10);component(node_21,()=>Root$5,($$anchor8,Tooltip_Root_2)=>{Tooltip_Root_2($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_11=root_19$9(),node_22=first_child(
|
|
|
|
|
fragment_11);component(node_22,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger_2)=>{Tooltip_Trigger_2($$anchor10,{children:($$anchor11,$$slotProps4)=>{var button_3=root_20$3();set_class(button_3,1,clsx(sheetItemClass));var node_23=child(button_3);component(node_23,()=>get$3(item).icon,($$anchor12,item_icon_2)=>{item_icon_2($$anchor12,{class:"h-4 w-4 shrink-0"})});var span_3=sibling(node_23,2),text_6=child(span_3,!0);reset(span_3),reset(button_3),template_effect(()=>set_text(text_6,get$3(item).label)),
|
|
|
|
|
delegated("click",button_3,()=>attachmentMenu.callbacks[get$3(item).action]()),append($$anchor11,button_3)},$$slots:{default:!0}})});var node_24=sibling(node_22,2);component(node_24,()=>Tooltip_content,($$anchor10,Tooltip_Content_2)=>{Tooltip_Content_2($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p_2=root_21$4(),text_7=child(p_2,!0);reset(p_2),template_effect($0=>set_text(text_7,$0),[()=>attachmentMenu.getSystemMessageTooltip()]),append($$anchor11,p_2)},$$slots:{default:!0}})}),
|
|
|
|
|
append($$anchor9,fragment_11)},$$slots:{default:!0}})}),append($$anchor7,fragment_10)};if_block(node_20,$$render=>{get$3(item).id===AttachmentMenuItemId.SYSTEM_MESSAGE&&$$render(consequent_4)})}append($$anchor6,fragment_9)});var a=sibling(node_19,4),node_25=child(a);McpLogo(node_25,{class:"inline h-4 w-4"}),next$1(2),reset(a);var a_1=sibling(a,2),node_26=child(a_1);Pencil_ruler(node_26,{class:"inline h-4 w-4"}),next$1(2),reset(a_1);var node_27=sibling(a_1,2);each(node_27,17,()=>ATTACHMENT_MCP_ITEMS,
|
|
|
|
|
item=>item.id,($$anchor6,item)=>{var fragment_12=comment$2(),node_28=first_child(fragment_12);{var consequent_5=$$anchor7=>{var button_4=root_23$4();set_class(button_4,1,clsx(sheetItemClass));var node_29=child(button_4);component(node_29,()=>get$3(item).icon,($$anchor8,item_icon_3)=>{item_icon_3($$anchor8,{class:"h-4 w-4 shrink-0"})});var span_4=sibling(node_29,2),text_8=child(span_4,!0);reset(span_4),reset(button_4),template_effect(()=>set_text(text_8,get$3(item).label)),delegated("click",button_4,
|
|
|
|
|
()=>attachmentMenu.callbacks[get$3(item).action]()),append($$anchor7,button_4)},d_12=user_derived(()=>attachmentMenu.isItemVisible(get$3(item).visibleWhen));if_block(node_28,$$render=>{get$3(d_12)&&$$render(consequent_5)})}append($$anchor6,fragment_12)}),reset(div_1),append($$anchor5,fragment_1)},$$slots:{default:!0}})}),append($$anchor3,fragment)},$$slots:{default:!0}})}),reset(div),template_effect(()=>set_class(div,1,`flex items-center gap-1 ${className()??""}`)),append($$anchor,div),pop()}delegate(
|
|
|
|
|
["click"]);var root_3$O=from_html('<span class="sr-only"> </span> <!>',1),root_4$z=from_html("<p> </p>"),root_1$J=from_html("<!> <!>",1);function ChatFormActionAddButton($$anchor,$$props){let disabled=prop($$props,"disabled",3,!1);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Root$5,($$anchor2,Tooltip_Root)=>{Tooltip_Root($$anchor2,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$J(),node_1=first_child(fragment_1);component(node_1,()=>Tooltip_trigger,($$anchor4,Tooltip_Trigger)=>{
|
|
|
|
|
Tooltip_Trigger($$anchor4,{class:"w-full",children:($$anchor5,$$slotProps2)=>{Button($$anchor5,{class:"file-upload-button h-8 w-8 rounded-full p-0",get disabled(){return disabled()},get onclick(){return $$props.onclick},variant:"secondary",type:"button",children:($$anchor6,$$slotProps3)=>{var fragment_3=root_3$O(),span=first_child(fragment_3),text2=child(span,!0);reset(span);var node_2=sibling(span,2);Plus(node_2,{class:"h-4 w-4"}),template_effect(()=>set_text(text2,ATTACHMENT_TOOLTIP_TEXT)),append(
|
|
|
|
|
$$anchor6,fragment_3)},$$slots:{default:!0}})},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Tooltip_content,($$anchor4,Tooltip_Content)=>{Tooltip_Content($$anchor4,{children:($$anchor5,$$slotProps2)=>{var p2=root_4$z(),text_1=child(p2,!0);reset(p2),template_effect(()=>set_text(text_1,ATTACHMENT_TOOLTIP_TEXT)),append($$anchor5,p2)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment)}function ChatFormActionsAdd($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),hasMcpPromptsSupport=prop($$props,"hasMcpPromptsSupport",3,!1),hasMcpResourcesSupport=prop($$props,"hasMcpResourcesSupport",3,!1),hasVisionModality=prop($$props,"hasVisionModality",3,!1);const isMobile=new IsMobile;var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{ChatFormActionAddSheet($$anchor2,{get disabled(){return disabled()},get hasAudioModality(){
|
|
|
|
|
return hasAudioModality()},get hasVisionModality(){return hasVisionModality()},get hasMcpPromptsSupport(){return hasMcpPromptsSupport()},get hasMcpResourcesSupport(){return hasMcpResourcesSupport()},get onFileUpload(){return $$props.onFileUpload},get onMcpPromptClick(){return $$props.onMcpPromptClick},get onMcpResourcesClick(){return $$props.onMcpResourcesClick},trigger:($$anchor3,$$arg0)=>{let disabled2=()=>$$arg0?.().disabled,onclick=()=>$$arg0?.().onclick;ChatFormActionAddButton($$anchor3,{get disabled(){
|
|
|
|
|
return disabled2()},get onclick(){return onclick()}})},$$slots:{trigger:!0}})},alternate=$$anchor2=>{ChatFormActionAddDropdown($$anchor2,{get disabled(){return disabled()},get hasAudioModality(){return hasAudioModality()},get hasVisionModality(){return hasVisionModality()},get hasMcpPromptsSupport(){return hasMcpPromptsSupport()},get hasMcpResourcesSupport(){return hasMcpResourcesSupport()},get onFileUpload(){return $$props.onFileUpload},get onMcpPromptClick(){return $$props.onMcpPromptClick},get onMcpResourcesClick(){
|
|
|
|
|
return $$props.onMcpResourcesClick},get onMcpSettingsClick(){return $$props.onMcpSettingsClick},get onSystemPromptClick(){return $$props.onSystemPromptClick},trigger:$$anchor3=>{ChatFormActionAddButton($$anchor3,{get disabled(){return disabled()}})},$$slots:{trigger:!0}})};if_block(node2,$$render=>{isMobile.current?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment),pop()}var root_3$N=from_html('<span class="sr-only"> </span> <!>',1),root_7$q=from_html("<p>Current model does \
|
|
|
|
|
not support audio</p>"),root_1$I=from_html("<!> <!>",1),root$1o=from_html("<div><!></div>");function ChatFormActionRecord($$anchor,$$props){let className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),isLoading2=prop($$props,"isLoading",3,!1),isRecording=prop($$props,"isRecording",3,!1);var div=root$1o(),node2=child(div);component(node2,()=>Root$5,($$anchor2,Tooltip_Root)=>{Tooltip_Root($$anchor2,{children:($$anchor3,$$slotProps)=>{
|
|
|
|
|
var fragment=root_1$I(),node_1=first_child(fragment);component(node_1,()=>Tooltip_trigger,($$anchor4,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor4,{children:($$anchor5,$$slotProps2)=>{{let $0=user_derived(()=>isRecording()?"animate-pulse bg-red-500 text-white hover:bg-red-600":""),$1=user_derived(()=>disabled()||isLoading2()||!hasAudioModality());Button($$anchor5,{get class(){return`h-8 w-8 rounded-full p-0 ${get$3($0)??""}`},get disabled(){return get$3($1)},get onclick(){return $$props.onMicClick},
|
|
|
|
|
type:"button",children:($$anchor6,$$slotProps3)=>{var fragment_2=root_3$N(),span=first_child(fragment_2),text2=child(span,!0);reset(span);var node_2=sibling(span,2);{var consequent=$$anchor7=>{Square($$anchor7,{class:"h-4 w-4 animate-pulse fill-white"})},alternate=$$anchor7=>{Mic($$anchor7,{class:"h-4 w-4"})};if_block(node_2,$$render=>{isRecording()?$$render(consequent):$$render(alternate,-1)})}template_effect(()=>set_text(text2,isRecording()?"Stop recording":"Start recording")),append($$anchor6,
|
|
|
|
|
fragment_2)},$$slots:{default:!0}})}},$$slots:{default:!0}})});var node_3=sibling(node_1,2);{var consequent_1=$$anchor4=>{var fragment_5=comment$2(),node_4=first_child(fragment_5);component(node_4,()=>Tooltip_content,($$anchor5,Tooltip_Content)=>{Tooltip_Content($$anchor5,{children:($$anchor6,$$slotProps2)=>{var p2=root_7$q();append($$anchor6,p2)},$$slots:{default:!0}})}),append($$anchor4,fragment_5)};if_block(node_3,$$render=>{hasAudioModality()||$$render(consequent_1)})}append($$anchor3,fragment)},
|
|
|
|
|
$$slots:{default:!0}})}),reset(div),template_effect(()=>set_class(div,1,`flex items-center gap-1 ${className()??""}`)),append($$anchor,div)}var root_1$H=from_html('<div class="mr-auto flex items-center gap-2"><!></div>'),root_4$y=from_html('<span class="sr-only">Stop</span> <!>',1),root$1n=from_html('<div style="container-type: inline-size"><!> <!> <!></div>');function ChatFormActions($$anchor,$$props){push$1($$props,!0);let canSend=prop($$props,"canSend",3,!1),canSubmit=prop($$props,"canSubmit",
|
|
|
|
|
3,!1),className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),isLoading2=prop($$props,"isLoading",3,!1),isRecording=prop($$props,"isRecording",3,!1),showAddButton=prop($$props,"showAddButton",3,!0),showModelSelector=prop($$props,"showModelSelector",3,!0),uploadedFiles=prop($$props,"uploadedFiles",19,()=>[]),currentConfig=user_derived(config$1),hasMcpPromptsSupport=user_derived(()=>{const perChatOverrides=conversationsStore.getAllMcpServerOverrides();return mcpStore.hasPromptsCapability(
|
|
|
|
|
perChatOverrides)}),hasMcpResourcesSupport=user_derived(()=>{const perChatOverrides=conversationsStore.getAllMcpServerOverrides();return mcpStore.hasResourcesCapability(perChatOverrides)}),hasAudioModality=state$1(!1),hasVisionModality=state$1(!1),hasModelSelected=state$1(!1),isSelectedModelInCache=state$1(!0),submitTooltip=state$1(""),hasAudioAttachments=user_derived(()=>uploadedFiles().some(file=>getFileTypeCategory(file.type)===FileTypeCategory.AUDIO)),shouldShowRecordButton=user_derived(()=>get$3(
|
|
|
|
|
hasAudioModality)&&!canSubmit()&&!get$3(hasAudioAttachments)&&get$3(currentConfig).autoMicOnEmpty),selectorModelRef=state$1(void 0);function openModelSelector(){get$3(selectorModelRef)?.open()}var $$exports={openModelSelector},div=root$1n(),node2=child(div);{var consequent=$$anchor2=>{var div_1=root_1$H(),node_1=child(div_1);ChatFormActionsAdd(node_1,{get disabled(){return disabled()},get hasAudioModality(){return get$3(hasAudioModality)},get hasVisionModality(){return get$3(hasVisionModality)},
|
|
|
|
|
get hasMcpPromptsSupport(){return get$3(hasMcpPromptsSupport)},get hasMcpResourcesSupport(){return get$3(hasMcpResourcesSupport)},get onFileUpload(){return $$props.onFileUpload},get onSystemPromptClick(){return $$props.onSystemPromptClick},get onMcpPromptClick(){return $$props.onMcpPromptClick},get onMcpResourcesClick(){return $$props.onMcpResourcesClick},onMcpSettingsClick:()=>goto("#/settings/mcp")}),reset(div_1),append($$anchor2,div_1)};if_block(node2,$$render=>{showAddButton()&&$$render(consequent)})}
|
|
|
|
|
var node_2=sibling(node2,2);{var consequent_1=$$anchor2=>{bind_this(ChatFormActionModels($$anchor2,{get disabled(){return disabled()},forceForegroundText:!0,useGlobalSelection:!0,get hasAudioModality(){return get$3(hasAudioModality)},set hasAudioModality($$value){set$1(hasAudioModality,$$value,!0)},get hasVisionModality(){return get$3(hasVisionModality)},set hasVisionModality($$value){set$1(hasVisionModality,$$value,!0)},get hasModelSelected(){return get$3(hasModelSelected)},set hasModelSelected($$value){
|
|
|
|
|
set$1(hasModelSelected,$$value,!0)},get isSelectedModelInCache(){return get$3(isSelectedModelInCache)},set isSelectedModelInCache($$value){set$1(isSelectedModelInCache,$$value,!0)},get submitTooltip(){return get$3(submitTooltip)},set submitTooltip($$value){set$1(submitTooltip,$$value,!0)}}),$$value=>set$1(selectorModelRef,$$value,!0),()=>get$3(selectorModelRef))};if_block(node_2,$$render=>{showModelSelector()&&$$render(consequent_1)})}var node_3=sibling(node_2,2);{var consequent_2=$$anchor2=>{Button(
|
|
|
|
|
$$anchor2,{type:"button",variant:"secondary",get onclick(){return $$props.onStop},class:"group h-8 w-8 rounded-full p-0 hover:bg-destructive/10!",children:($$anchor3,$$slotProps)=>{var fragment_2=root_4$y(),node_4=sibling(first_child(fragment_2),2);Square(node_4,{class:"h-8 w-8 fill-muted-foreground stroke-muted-foreground group-hover:fill-destructive group-hover:stroke-destructive hover:fill-destructive hover:stroke-destructive"}),append($$anchor3,fragment_2)},$$slots:{default:!0}})},consequent_3=$$anchor2=>{
|
|
|
|
|
ChatFormActionRecord($$anchor2,{get disabled(){return disabled()},get hasAudioModality(){return get$3(hasAudioModality)},get isLoading(){return isLoading2()},get isRecording(){return isRecording()},get onMicClick(){return $$props.onMicClick}})},alternate=$$anchor2=>{{let $0=user_derived(()=>canSend()&&(showModelSelector()?get$3(hasModelSelected)&&get$3(isSelectedModelInCache):!0)),$1=user_derived(()=>showModelSelector()&&get$3(hasModelSelected)&&!get$3(isSelectedModelInCache));ChatFormActionSubmit(
|
|
|
|
|
$$anchor2,{get canSend(){return get$3($0)},get disabled(){return disabled()},get tooltipLabel(){return get$3(submitTooltip)},get showErrorState(){return get$3($1)}})}};if_block(node_3,$$render=>{isLoading2()&&!canSubmit()?$$render(consequent_2):get$3(shouldShowRecordButton)?$$render(consequent_3,1):$$render(alternate,-1)})}return reset(div),template_effect(()=>set_class(div,1,`flex w-full items-center gap-3 ${className()??""} ${showAddButton()?"":"justify-end"}`)),append($$anchor,div),pop($$exports)}
|
|
|
|
|
var root_2$_=from_html('<span class="sr-only">Send</span> <!>',1),root_6$s=from_html("<p> </p>"),root_4$x=from_html("<!> <!>",1);function ChatFormActionSubmit($$anchor,$$props){const submitButton=($$anchor2,$$arg0)=>{let props=derived_safe_equal(()=>fallback($$arg0?.(),()=>({}),!0));{let $0=user_derived(()=>["h-8 w-8 rounded-full p-0",showErrorState()&&"bg-red-400/10 text-red-400 hover:bg-red-400/20 hover:text-red-400 disabled:opacity-100"]);Button($$anchor2,spread_props({type:"submit",get disabled(){
|
|
|
|
|
return get$3(isDisabled)},get class(){return get$3($0)}},()=>get$3(props),{children:($$anchor3,$$slotProps)=>{var fragment_1=root_2$_(),node2=sibling(first_child(fragment_1),2);Arrow_up(node2,{class:"h-12 w-12"}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))}};let canSend=prop($$props,"canSend",3,!1),disabled=prop($$props,"disabled",3,!1),showErrorState=prop($$props,"showErrorState",3,!1),isDisabled=user_derived(()=>!canSend()||disabled());var fragment_2=comment$2(),node_1=first_child(fragment_2);
|
|
|
|
|
{var consequent=$$anchor2=>{var fragment_3=comment$2(),node_2=first_child(fragment_3);component(node_2,()=>Root$5,($$anchor3,Tooltip_Root)=>{Tooltip_Root($$anchor3,{children:($$anchor4,$$slotProps)=>{var fragment_4=root_4$x(),node_3=first_child(fragment_4);component(node_3,()=>Tooltip_trigger,($$anchor5,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor5,{children:($$anchor6,$$slotProps2)=>{submitButton($$anchor6)},$$slots:{default:!0}})});var node_4=sibling(node_3,2);component(node_4,()=>Tooltip_content,
|
|
|
|
|
($$anchor5,Tooltip_Content)=>{Tooltip_Content($$anchor5,{children:($$anchor6,$$slotProps2)=>{var p2=root_6$s(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,$$props.tooltipLabel)),append($$anchor6,p2)},$$slots:{default:!0}})}),append($$anchor4,fragment_4)},$$slots:{default:!0}})}),append($$anchor2,fragment_3)},alternate=$$anchor2=>{submitButton($$anchor2)};if_block(node_1,$$render=>{$$props.tooltipLabel?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment_2)}function ChatFormActionModels($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1),forceForegroundText=prop($$props,"forceForegroundText",3,!1),hasAudioModality=prop($$props,"hasAudioModality",15,!1),hasVisionModality=prop($$props,"hasVisionModality",15,!1),hasModelSelected=prop($$props,"hasModelSelected",15,!1),isSelectedModelInCache=prop($$props,"isSelectedModelInCache",15,!0),submitTooltip=prop($$props,"submitTooltip",15,""),useGlobalSelection=prop($$props,"useGlobalSelection",3,!1),isRouter=user_derived(isRouterMode),
|
|
|
|
|
isOffline=user_derived(()=>!!serverError()),conversationModel=user_derived(()=>chatStore.getConversationModel(activeMessages())),lastSyncedConversationModel=null;user_effect(()=>{if(get$3(conversationModel)&&get$3(conversationModel)!==lastSyncedConversationModel)lastSyncedConversationModel=get$3(conversationModel),modelsStore.selectModelByName(get$3(conversationModel));else if(get$3(isRouter)&&!modelsStore.selectedModelId&&modelsStore.loadedModelIds.length>0){lastSyncedConversationModel=null;const first=modelOptions().
|
|
|
|
|
find(m=>modelsStore.loadedModelIds.includes(m.model));first&&modelsStore.selectModelById(first.id)}});let activeModelId=user_derived(()=>{const options=modelOptions();if(!get$3(isRouter))return options.length>0?options[0].model:null;const selectedId=selectedModelId();if(selectedId){const model=options.find(m=>m.id===selectedId);if(model)return model.model}if(get$3(conversationModel)){const model=options.find(m=>m.model===get$3(conversationModel));if(model)return model.model}return null}),modelPropsVersion=state$1(
|
|
|
|
|
0);user_effect(()=>{get$3(activeModelId)&&(modelsStore.getModelProps(get$3(activeModelId))||modelsStore.fetchModelProps(get$3(activeModelId)).then(()=>{update$1(modelPropsVersion)}))}),user_effect(()=>{hasAudioModality(get$3(activeModelId)?modelsStore.modelSupportsAudio(get$3(activeModelId)):!1)}),user_effect(()=>{get$3(modelPropsVersion),hasVisionModality(get$3(activeModelId)?modelsStore.modelSupportsVision(get$3(activeModelId)):!1)}),user_effect(()=>{hasModelSelected(!get$3(isRouter)||!!get$3(
|
|
|
|
|
conversationModel)||!!selectedModelId())}),user_effect(()=>{if(!get$3(isRouter))isSelectedModelInCache(!0);else if(get$3(conversationModel))isSelectedModelInCache(modelOptions().some(option2=>option2.model===get$3(conversationModel)));else{const currentModelId=selectedModelId();isSelectedModelInCache(currentModelId?modelOptions().some(option2=>option2.id===currentModelId):!1)}}),user_effect(()=>{hasModelSelected()?isSelectedModelInCache()?submitTooltip(""):submitTooltip("Selected model is not av\
|
|
|
|
|
ailable, please select another"):submitTooltip("Please select a model first")});let selectorModelRef=state$1(void 0),isMobile=new IsMobile;function open2(){get$3(selectorModelRef)?.open()}var $$exports={open:open2},fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{{let $0=user_derived(()=>disabled()||get$3(isOffline));bind_this(ModelsSelectorSheet($$anchor2,{get disabled(){return get$3($0)},get currentModel(){return $$props.currentModel},get forceForegroundText(){return forceForegroundText()},
|
|
|
|
|
get useGlobalSelection(){return useGlobalSelection()}}),$$value=>set$1(selectorModelRef,$$value,!0),()=>get$3(selectorModelRef))}},alternate=$$anchor2=>{{let $0=user_derived(()=>disabled()||get$3(isOffline));bind_this(ModelsSelectorDropdown($$anchor2,{get disabled(){return get$3($0)},get currentModel(){return $$props.currentModel},get forceForegroundText(){return forceForegroundText()},get useGlobalSelection(){return useGlobalSelection()}}),$$value=>set$1(selectorModelRef,$$value,!0),()=>get$3(selectorModelRef))}};
|
|
|
|
|
if_block(node2,$$render=>{isMobile.current?$$render(consequent):$$render(alternate,-1)})}return append($$anchor,fragment),pop($$exports)}function Collapsible($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),open2=prop($$props,"open",15,!1),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","open"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible$1,($$anchor2,CollapsiblePrimitive_Root)=>{CollapsiblePrimitive_Root($$anchor2,
|
|
|
|
|
spread_props({"data-slot":"collapsible"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},get open(){return open2()},set open($$value){open2($$value)}}))}),append($$anchor,fragment),pop()}function Collapsible_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible_trigger$1,($$anchor2,CollapsiblePrimitive_Trigger)=>{
|
|
|
|
|
CollapsiblePrimitive_Trigger($$anchor2,spread_props({"data-slot":"collapsible-trigger"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))}),append($$anchor,fragment),pop()}function Collapsible_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible_content$1,($$anchor2,CollapsiblePrimitive_Content)=>{
|
|
|
|
|
CollapsiblePrimitive_Content($$anchor2,spread_props({"data-slot":"collapsible-content"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))}),append($$anchor,fragment),pop()}function useToolsPanel(){const expandedGroups=new SvelteSet,groups=user_derived(()=>toolsStore.toolGroups),activeGroups=user_derived(()=>get$3(groups).filter(g=>g.source!==ToolSource.MCP||!g.serverId||conversationsStore.isMcpServerEnabledForChat(g.serverId))),totalToolCount=user_derived(()=>get$3(activeGroups).
|
|
|
|
|
reduce((n,g)=>n+g.tools.length,0)),noToolsInfoMessage=user_derived(()=>toolsStore.loading||toolsStore.toolGroups.length>0?null:toolsStore.isToolsEndpointUnreachable?"To enable Built-In Tools you need to run llama-server with --tools all or --tools <name> flag. To see MCP Tools you need to add / enable MCP Server(s).":toolsStore.error?null:"To enable Built-In Tools you need to run llama-server with --tools all or --tools <name> flag. To see MCP Tools you need to add / enable MCP Server(s).");function getGroupCheckedState(group){
|
|
|
|
|
return{checked:toolsStore.isGroupFullyEnabled(group),indeterminate:toolsStore.isGroupPartiallyEnabled(group)}}function getEnabledToolCount(group){return group.tools.filter(tool=>toolsStore.isToolEnabled(tool.function.name)).length}function getFavicon(group){if(group.source!==ToolSource.MCP)return null;for(const server of mcpStore.getServersSorted())if(mcpStore.getServerLabel(server)===group.label)return mcpStore.getServerFavicon(server.id);return null}function isGroupDisabled(group){return group.
|
|
|
|
|
source===ToolSource.MCP&&!!group.serverId&&!conversationsStore.isMcpServerEnabledForChat(group.serverId)}function toggleGroupExpanded(label){expandedGroups.has(label)?expandedGroups.delete(label):expandedGroups.add(label)}function handleOpen(){toolsStore.builtinTools.length===0&&!toolsStore.loading&&toolsStore.fetchBuiltinTools(),mcpStore.runHealthChecksForServers(mcpStore.getServersSorted().filter(s2=>s2.enabled))}return{expandedGroups,get groups(){return get$3(groups)},get activeGroups(){return get$3(
|
|
|
|
|
activeGroups)},get totalToolCount(){return get$3(totalToolCount)},get noToolsInfoMessage(){return get$3(noToolsInfoMessage)},getGroupCheckedState,getEnabledToolCount,getFavicon,isGroupDisabled,toggleGroupExpanded,handleOpen}}var root_2$Z=from_html("<!> <span>Tools</span>",1),root_5$s=from_html('<div class="px-3 py-4 text-center text-sm text-muted-foreground"><!> Loading tools...</div>'),root_6$r=from_html('<div class="grid gap-2.5 px-3 py-4 text-sm text-muted-foreground"><span class="flex gap-2"\
|
|
|
|
|
><!> <span>Run llama-server with <code>--tools</code> flag to enable <strong>Built-in Tools</strong>.</span></span> <span class="flex gap-2"><!> <span> <strong>MCP Tools</strong>.</span></span></div>'),root_7$p=from_html('<div class="px-3 py-4 text-center text-sm text-muted-foreground">Failed to load tools</div>'),root_8$p=from_html('<div class="flex gap-2 px-3 py-4 text-sm text-muted-foreground"><!> <span> </span></div>'),root_9$j=from_html('<div class="px-3 py-4 text-center text-sm text-muted-\
|
|
|
|
|
foreground">No tools available</div>'),root_16$3=from_html('<img alt="" class="h-4 w-4 shrink-0 rounded-sm"/>'),root_13$a=from_html('<!> <span class="inline-flex min-w-0 items-center gap-1.5 font-medium"><!> <span class="truncate"> </span></span> <span class="ml-auto shrink-0 text-xs text-muted-foreground"> </span>',1),root_19$8=from_html("<p> </p>"),root_17$7=from_html("<!> <!>",1),root_21$3=from_html('<button type="button" class="flex w-full items-center gap-2 rounded px-2 py-1.5 text-left tex\
|
|
|
|
|
t-sm transition-colors hover:bg-muted/50"><!> <span class="min-w-0 flex-1 truncate font-mono text-[12px]"> </span></button>'),root_20$2=from_html('<div class="ml-4 flex flex-col gap-0.5 border-l border-border/50 pl-2"></div>'),root_12$8=from_html('<div class="flex items-center gap-1"><!> <!></div> <!>',1),root_10$c=from_html('<div class="max-h-80 overflow-y-auto p-2 pr-1"></div>'),root_1$G=from_html("<!> <!>",1);function ChatFormActionAddToolsSubmenu($$anchor,$$props){push$1($$props,!0);const toolsPanel=useToolsPanel(),
|
|
|
|
|
hasMcpServersAvailable=user_derived(()=>mcpStore.getServersSorted().length>0);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Sub,($$anchor2,DropdownMenu_Sub)=>{DropdownMenu_Sub($$anchor2,{onOpenChange:open2=>open2&&toolsPanel.handleOpen(),children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$G(),node_1=first_child(fragment_1);component(node_1,()=>Dropdown_menu_sub_trigger,($$anchor4,DropdownMenu_SubTrigger)=>{DropdownMenu_SubTrigger($$anchor4,{class:"flex cursor-poin\
|
|
|
|
|
ter items-center gap-2",children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$Z(),node_2=first_child(fragment_2);Pencil_ruler(node_2,{class:"h-4 w-4"}),next$1(2),append($$anchor5,fragment_2)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Dropdown_menu_sub_content,($$anchor4,DropdownMenu_SubContent)=>{DropdownMenu_SubContent($$anchor4,{class:"w-72 p-0",children:($$anchor5,$$slotProps2)=>{var fragment_3=comment$2(),node_4=first_child(fragment_3);{var consequent_4=$$anchor6=>{
|
|
|
|
|
var fragment_4=comment$2(),node_5=first_child(fragment_4);{var consequent=$$anchor7=>{var div=root_5$s(),node_6=child(div);Loader_circle(node_6,{class:"mx-auto mb-1 h-4 w-4 animate-spin"}),next$1(),reset(div),append($$anchor7,div)},consequent_1=$$anchor7=>{var div_1=root_6$r(),span=child(div_1),node_7=child(span);Info$1(node_7,{class:"mt-0.5 h-4 w-4 shrink-0"}),next$1(2),reset(span);var span_1=sibling(span,2),node_8=child(span_1);Info$1(node_8,{class:"mt-0.5 h-4 w-4 shrink-0"});var span_2=sibling(
|
|
|
|
|
node_8,2),text2=child(span_2);next$1(2),reset(span_2),reset(span_1),reset(div_1),template_effect(()=>set_text(text2,`${get$3(hasMcpServersAvailable)?"Enable":"Add"} MCP Server(s) to access `)),append($$anchor7,div_1)},consequent_2=$$anchor7=>{var div_2=root_7$p();append($$anchor7,div_2)},consequent_3=$$anchor7=>{var div_3=root_8$p(),node_9=child(div_3);Info$1(node_9,{class:"mt-0.5 h-4 w-4 shrink-0"});var span_3=sibling(node_9,2),text_1=child(span_3,!0);reset(span_3),reset(div_3),template_effect(
|
|
|
|
|
()=>set_text(text_1,toolsPanel.noToolsInfoMessage)),append($$anchor7,div_3)},alternate=$$anchor7=>{var div_4=root_9$j();append($$anchor7,div_4)};if_block(node_5,$$render=>{toolsStore.loading?$$render(consequent):toolsStore.isToolsEndpointUnreachable?$$render(consequent_1,1):toolsStore.error?$$render(consequent_2,2):toolsPanel.noToolsInfoMessage?$$render(consequent_3,3):$$render(alternate,-1)})}append($$anchor6,fragment_4)},alternate_2=$$anchor6=>{var div_5=root_10$c();each(div_5,21,()=>toolsPanel.
|
|
|
|
|
activeGroups,group=>group.label,($$anchor7,group)=>{const isExpanded=user_derived(()=>toolsPanel.expandedGroups.has(get$3(group).label)),computed_const=user_derived(()=>{const{checked,indeterminate}=toolsPanel.getGroupCheckedState(get$3(group));return{checked,indeterminate}}),favicon=user_derived(()=>toolsPanel.getFavicon(get$3(group)));var fragment_5=comment$2(),node_10=first_child(fragment_5);component(node_10,()=>Collapsible,($$anchor8,Collapsible_Root)=>{Collapsible_Root($$anchor8,{get open(){
|
|
|
|
|
return get$3(isExpanded)},onOpenChange:()=>toolsPanel.toggleGroupExpanded(get$3(group).label),children:($$anchor9,$$slotProps3)=>{var fragment_6=root_12$8(),div_6=first_child(fragment_6),node_11=child(div_6);component(node_11,()=>Collapsible_trigger,($$anchor10,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor10,{class:"flex min-w-0 flex-1 items-center gap-2 rounded px-2 py-1.5 text-sm hover:bg-muted/50",children:($$anchor11,$$slotProps4)=>{var fragment_7=root_13$a(),node_12=first_child(fragment_7);
|
|
|
|
|
{var consequent_5=$$anchor12=>{Chevron_down($$anchor12,{class:"h-3.5 w-3.5 shrink-0"})},alternate_1=$$anchor12=>{Chevron_right($$anchor12,{class:"h-3.5 w-3.5 shrink-0"})};if_block(node_12,$$render=>{get$3(isExpanded)?$$render(consequent_5):$$render(alternate_1,-1)})}var span_4=sibling(node_12,2),node_13=child(span_4);{var consequent_6=$$anchor12=>{var img=root_16$3();template_effect(()=>set_attribute(img,"src",get$3(favicon))),event("error",img,e=>{e.currentTarget.style.display="none"}),replay_events(
|
|
|
|
|
img),append($$anchor12,img)};if_block(node_13,$$render=>{get$3(favicon)&&$$render(consequent_6)})}var span_5=sibling(node_13,2),text_2=child(span_5,!0);reset(span_5),reset(span_4);var span_6=sibling(span_4,2),text_3=child(span_6);reset(span_6),template_effect($0=>{set_text(text_2,get$3(group).label),set_text(text_3,`${$0??""}/${get$3(group).tools.length??""}`)},[()=>toolsPanel.getEnabledToolCount(get$3(group))]),append($$anchor11,fragment_7)},$$slots:{default:!0}})});var node_14=sibling(node_11,
|
|
|
|
|
2);component(node_14,()=>Root$5,($$anchor10,Tooltip_Root)=>{Tooltip_Root($$anchor10,{children:($$anchor11,$$slotProps4)=>{var fragment_10=root_17$7(),node_15=first_child(fragment_10);component(node_15,()=>Tooltip_trigger,($$anchor12,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor12,{children:($$anchor13,$$slotProps5)=>{Checkbox($$anchor13,{get checked(){return get$3(computed_const).checked},get indeterminate(){return get$3(computed_const).indeterminate},onCheckedChange:()=>toolsStore.toggleGroup(get$3(
|
|
|
|
|
group)),class:"mr-2 h-4 w-4 shrink-0"})},$$slots:{default:!0}})});var node_16=sibling(node_15,2);component(node_16,()=>Tooltip_content,($$anchor12,Tooltip_Content)=>{Tooltip_Content($$anchor12,{side:"right",children:($$anchor13,$$slotProps5)=>{var p2=root_19$8(),text_4=child(p2);reset(p2),template_effect(()=>set_text(text_4,`${get$3(computed_const).checked?"Disable":"Enable"}
|
|
|
|
|
pover-foreground shadow-md outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 dark:border-border/20",$$props.class));component(node_1,()=>Dropdown_menu_content$1,
|
|
|
|
|
($$anchor4,DropdownMenuPrimitive_Content)=>{DropdownMenuPrimitive_Content($$anchor4,spread_props({"data-slot":"dropdown-menu-content",get sideOffset(){return sideOffset()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}function Dropdown_menu_item($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),variant=prop($$props,"variant",
|
|
|
|
|
3,"default"),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","inset","variant"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("relative flex cursor-pointer items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-highlighted:bg-accent data-highlighted:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 data-[variant=destructive]:text-destructive data-[var\
|
|
|
|
|
iant=destructive]:data-highlighted:bg-destructive/10 data-[variant=destructive]:data-highlighted:text-destructive dark:data-[variant=destructive]:data-highlighted:bg-destructive/20 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground data-[variant=destructive]:*:[svg]:!text-destructive",$$props.class));component(node2,()=>Menu_item,($$anchor2,DropdownMenuPrimitive_Item)=>{DropdownMenuPrimitive_Item($$anchor2,spread_props(
|
|
|
|
|
{"data-slot":"dropdown-menu-item",get"data-inset"(){return $$props.inset},get"data-variant"(){return variant()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Dropdown_menu_separator($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(
|
|
|
|
|
()=>cn$1("-mx-1 my-1 h-px bg-border/20",$$props.class));component(node2,()=>Menu_separator,($$anchor2,DropdownMenuPrimitive_Separator)=>{DropdownMenuPrimitive_Separator($$anchor2,spread_props({"data-slot":"dropdown-menu-separator",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Dropdown_menu_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,
|
|
|
|
|
["$$slots","$$events","$$legacy","ref"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Menu_trigger,($$anchor2,DropdownMenuPrimitive_Trigger)=>{DropdownMenuPrimitive_Trigger($$anchor2,spread_props({"data-slot":"dropdown-menu-trigger"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))}),append($$anchor,fragment),pop()}function Dropdown_menu_sub_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("z-50 max-h-(--bits-dropdown-menu-content-available-height) min-w-[8rem] origin-(--bits-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border border-border bg-popover p-1.5 text-popover-foreground shadow-md outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-\
|
|
|
|
|
in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 dark:border-border/20",$$props.class));component(node2,()=>Menu_sub_content,($$anchor2,DropdownMenuPrimitive_SubContent)=>{DropdownMenuPrimitive_SubContent($$anchor2,spread_props({"data-slot":"dropdown-menu-sub-content",get class(){
|
|
|
|
|
return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_1$N=from_html("<!> <!>",1);function Dropdown_menu_sub_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","inset","children"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("flex cursor-default items-center gap-2 rounded\
|
|
|
|
|
-sm px-2 py-1.5 text-sm outline-hidden select-none data-highlighted:bg-accent data-highlighted:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground",$$props.class));component(node2,()=>Menu_sub_trigger,($$anchor2,DropdownMenuPrimitive_SubTrigger)=>{
|
|
|
|
|
DropdownMenuPrimitive_SubTrigger($$anchor2,spread_props({"data-slot":"dropdown-menu-sub-trigger",get"data-inset"(){return $$props.inset},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$N(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);Chevron_right(node_2,{class:"ml-auto size-4"}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}
|
|
|
|
|
append($$anchor,fragment),pop()}const Sub=Menu_sub,Root$4=Menu;function useAttachmentMenu(getFlags,getCallbacks,close2){const modalityFlags=user_derived(getFlags),callbacks=user_derived(()=>{const cbs=getCallbacks(),wrap2=fn=>()=>{close2(),fn?.()};return{[AttachmentAction.FILE_UPLOAD]:wrap2(cbs.onFileUpload),[AttachmentAction.SYSTEM_PROMPT_CLICK]:wrap2(cbs.onSystemPromptClick),[AttachmentAction.MCP_PROMPT_CLICK]:wrap2(cbs.onMcpPromptClick),[AttachmentAction.MCP_RESOURCES_CLICK]:wrap2(cbs.onMcpResourcesClick)}});
|
|
|
|
|
function isItemEnabled(enabledWhen){return!enabledWhen||enabledWhen==="always"?!0:!!get$3(modalityFlags)[enabledWhen]}function isItemVisible(visibleWhen){return visibleWhen?!!get$3(modalityFlags)[visibleWhen]:!0}function getSystemMessageTooltip(){return page$1.params.id?"Inject custom system message at the beginning of the conversation":"Add custom system message for a new conversation"}return{get callbacks(){return get$3(callbacks)},isItemEnabled,isItemVisible,getSystemMessageTooltip}}var root_6$t=from_html(
|
|
|
|
|
"<!> <span> </span>",1),root_10$e=from_html("<!> <span> </span>",1),root_11$e=from_html("<p> </p>"),root_8$q=from_html("<!> <!>",1),root_16$5=from_html("<!> <span> </span>",1),root_17$8=from_html("<p>PDFs will be converted to text. Image-based PDFs may not work properly.</p>"),root_13$b=from_html("<!> <!>",1),root_22$1=from_html("<!> <span> </span>",1),root_23$5=from_html("<p> </p>"),root_20$4=from_html("<!> <!>",1),root_26$1=from_html("<!> <span> </span>",1),root_3$R=from_html("<!> <!> <!> <!> \
|
|
|
|
|
<!> <!> <!>",1),root_1$M=from_html("<!> <!>",1),root$1r=from_html("<div><!></div>");function ChatFormActionAddDropdown($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),hasVisionModality=prop($$props,"hasVisionModality",3,!1),hasMcpPromptsSupport=prop($$props,"hasMcpPromptsSupport",3,!1),hasMcpResourcesSupport=prop($$props,"hasMcpResourcesSupport",3,!1),dropdownOpen=state$1(!1);
|
|
|
|
|
function handleMcpSettingsClick(){set$1(dropdownOpen,!1),$$props.onMcpSettingsClick?.()}const attachmentMenu=useAttachmentMenu(()=>({hasVisionModality:hasVisionModality(),hasAudioModality:hasAudioModality(),hasMcpPromptsSupport:hasMcpPromptsSupport(),hasMcpResourcesSupport:hasMcpResourcesSupport()}),()=>({onFileUpload:$$props.onFileUpload,onSystemPromptClick:$$props.onSystemPromptClick,onMcpPromptClick:$$props.onMcpPromptClick,onMcpResourcesClick:$$props.onMcpResourcesClick}),()=>{set$1(dropdownOpen,
|
|
|
|
|
!1)});var div=root$1r(),node2=child(div);component(node2,()=>Root$4,($$anchor2,DropdownMenu_Root)=>{DropdownMenu_Root($$anchor2,{get open(){return get$3(dropdownOpen)},set open($$value){set$1(dropdownOpen,$$value,!0)},children:($$anchor3,$$slotProps)=>{var fragment=root_1$M(),node_1=first_child(fragment);component(node_1,()=>Dropdown_menu_trigger,($$anchor4,DropdownMenu_Trigger)=>{DropdownMenu_Trigger($$anchor4,{name:"Attach files",get disabled(){return disabled()},children:($$anchor5,$$slotProps2)=>{
|
|
|
|
|
var fragment_1=comment$2(),node_2=first_child(fragment_1);snippet(node_2,()=>$$props.trigger,()=>({disabled:disabled()})),append($$anchor5,fragment_1)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Dropdown_menu_content,($$anchor4,DropdownMenu_Content)=>{DropdownMenu_Content($$anchor4,{align:"start",class:"w-48",children:($$anchor5,$$slotProps2)=>{var fragment_2=root_3$R(),node_4=first_child(fragment_2);each(node_4,17,()=>ATTACHMENT_FILE_ITEMS,item=>item.id,($$anchor6,item)=>{
|
|
|
|
|
const enabled=user_derived(()=>attachmentMenu.isItemEnabled(get$3(item).enabledWhen));var fragment_3=comment$2(),node_5=first_child(fragment_3);{var consequent=$$anchor7=>{var fragment_4=comment$2(),node_6=first_child(fragment_4);{let $0=user_derived(()=>get$3(item).class??"");component(node_6,()=>Dropdown_menu_item,($$anchor8,DropdownMenu_Item)=>{DropdownMenu_Item($$anchor8,{get class(){return`${get$3($0)??""} flex cursor-pointer items-center gap-2`},onclick:()=>attachmentMenu.callbacks[get$3(item).
|
|
|
|
|
action](),children:($$anchor9,$$slotProps3)=>{var fragment_5=root_6$t(),node_7=first_child(fragment_5);component(node_7,()=>get$3(item).icon,($$anchor10,item_icon)=>{item_icon($$anchor10,{class:"h-4 w-4"})});var span=sibling(node_7,2),text2=child(span,!0);reset(span),template_effect(()=>set_text(text2,get$3(item).label)),append($$anchor9,fragment_5)},$$slots:{default:!0}})})}append($$anchor7,fragment_4)},consequent_1=$$anchor7=>{var fragment_6=comment$2(),node_8=first_child(fragment_6);component(
|
|
|
|
|
node_8,()=>Root$5,($$anchor8,Tooltip_Root)=>{Tooltip_Root($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_7=root_8$q(),node_9=first_child(fragment_7);component(node_9,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor10,{class:"w-full",children:($$anchor11,$$slotProps4)=>{var fragment_8=comment$2(),node_10=first_child(fragment_8);{let $0=user_derived(()=>get$3(item).class??"");component(node_10,()=>Dropdown_menu_item,
|
|
|
|
|
($$anchor12,DropdownMenu_Item_1)=>{DropdownMenu_Item_1($$anchor12,{get class(){return`${get$3($0)??""} flex cursor-pointer items-center gap-2`},disabled:!0,children:($$anchor13,$$slotProps5)=>{var fragment_9=root_10$e(),node_11=first_child(fragment_9);component(node_11,()=>get$3(item).icon,($$anchor14,item_icon_1)=>{item_icon_1($$anchor14,{class:"h-4 w-4"})});var span_1=sibling(node_11,2),text_1=child(span_1,!0);reset(span_1),template_effect(()=>set_text(text_1,get$3(item).label)),append($$anchor13,
|
|
|
|
|
fragment_9)},$$slots:{default:!0}})})}append($$anchor11,fragment_8)},$$slots:{default:!0}})});var node_12=sibling(node_9,2);component(node_12,()=>Tooltip_content,($$anchor10,Tooltip_Content)=>{Tooltip_Content($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p2=root_11$e(),text_2=child(p2,!0);reset(p2),template_effect(()=>set_text(text_2,get$3(item).disabledTooltip)),append($$anchor11,p2)},$$slots:{default:!0}})}),append($$anchor9,fragment_7)},$$slots:{default:!0}})}),append($$anchor7,
|
|
|
|
|
fragment_6)};if_block(node_5,$$render=>{get$3(enabled)?$$render(consequent):get$3(item).disabledTooltip&&$$render(consequent_1,1)})}append($$anchor6,fragment_3)});var node_13=sibling(node_4,2);{var consequent_3=$$anchor6=>{var fragment_10=comment$2(),node_14=first_child(fragment_10);component(node_14,()=>Root$5,($$anchor7,Tooltip_Root_1)=>{Tooltip_Root_1($$anchor7,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor8,$$slotProps3)=>{var fragment_11=root_13$b(),node_15=first_child(
|
|
|
|
|
fragment_11);component(node_15,()=>Tooltip_trigger,($$anchor9,Tooltip_Trigger_1)=>{Tooltip_Trigger_1($$anchor9,{class:"w-full",children:($$anchor10,$$slotProps4)=>{var fragment_12=comment$2(),node_16=first_child(fragment_12);component(node_16,()=>Dropdown_menu_item,($$anchor11,DropdownMenu_Item_2)=>{DropdownMenu_Item_2($$anchor11,{class:"flex cursor-pointer items-center gap-2",get onclick(){return attachmentMenu.callbacks.onFileUpload},children:($$anchor12,$$slotProps5)=>{const pdfItem=user_derived(
|
|
|
|
|
()=>ATTACHMENT_FILE_ITEMS.find(i=>i.id===AttachmentMenuItemId.PDF));var fragment_13=comment$2(),node_17=first_child(fragment_13);{var consequent_2=$$anchor13=>{var fragment_14=root_16$5(),node_18=first_child(fragment_14);component(node_18,()=>get$3(pdfItem).icon,($$anchor14,pdfItem_icon)=>{pdfItem_icon($$anchor14,{class:"h-4 w-4"})});var span_2=sibling(node_18,2),text_3=child(span_2,!0);reset(span_2),template_effect(()=>set_text(text_3,get$3(pdfItem).label)),append($$anchor13,fragment_14)};if_block(
|
|
|
|
|
node_17,$$render=>{get$3(pdfItem)&&$$render(consequent_2)})}append($$anchor12,fragment_13)},$$slots:{default:!0}})}),append($$anchor10,fragment_12)},$$slots:{default:!0}})});var node_19=sibling(node_15,2);component(node_19,()=>Tooltip_content,($$anchor9,Tooltip_Content_1)=>{Tooltip_Content_1($$anchor9,{side:"right",children:($$anchor10,$$slotProps4)=>{var p_1=root_17$8();append($$anchor10,p_1)},$$slots:{default:!0}})}),append($$anchor8,fragment_11)},$$slots:{default:!0}})}),append($$anchor6,fragment_10)},
|
|
|
|
|
d2=user_derived(()=>!attachmentMenu.isItemEnabled("hasVisionModality"));if_block(node_13,$$render=>{get$3(d2)&&$$render(consequent_3)})}var node_20=sibling(node_13,2);component(node_20,()=>Dropdown_menu_separator,($$anchor6,DropdownMenu_Separator)=>{DropdownMenu_Separator($$anchor6,{})});var node_21=sibling(node_20,2);each(node_21,17,()=>ATTACHMENT_EXTRA_ITEMS,item=>item.id,($$anchor6,item)=>{var fragment_15=comment$2(),node_22=first_child(fragment_15);{var consequent_4=$$anchor7=>{var fragment_16=comment$2(),
|
|
|
|
|
node_23=first_child(fragment_16);component(node_23,()=>Root$5,($$anchor8,Tooltip_Root_2)=>{Tooltip_Root_2($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_17=root_20$4(),node_24=first_child(fragment_17);component(node_24,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger_2)=>{Tooltip_Trigger_2($$anchor10,{class:"w-full",children:($$anchor11,$$slotProps4)=>{var fragment_18=comment$2(),node_25=first_child(fragment_18);component(node_25,()=>Dropdown_menu_item,
|
|
|
|
|
($$anchor12,DropdownMenu_Item_3)=>{DropdownMenu_Item_3($$anchor12,{class:"flex cursor-pointer items-center gap-2",onclick:()=>attachmentMenu.callbacks[get$3(item).action](),children:($$anchor13,$$slotProps5)=>{var fragment_19=root_22$1(),node_26=first_child(fragment_19);component(node_26,()=>get$3(item).icon,($$anchor14,item_icon_2)=>{item_icon_2($$anchor14,{class:"h-4 w-4"})});var span_3=sibling(node_26,2),text_4=child(span_3,!0);reset(span_3),template_effect(()=>set_text(text_4,get$3(item).label)),
|
|
|
|
|
append($$anchor13,fragment_19)},$$slots:{default:!0}})}),append($$anchor11,fragment_18)},$$slots:{default:!0}})});var node_27=sibling(node_24,2);component(node_27,()=>Tooltip_content,($$anchor10,Tooltip_Content_2)=>{Tooltip_Content_2($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p_2=root_23$5(),text_5=child(p_2,!0);reset(p_2),template_effect($0=>set_text(text_5,$0),[()=>attachmentMenu.getSystemMessageTooltip()]),append($$anchor11,p_2)},$$slots:{default:!0}})}),append($$anchor9,
|
|
|
|
|
fragment_17)},$$slots:{default:!0}})}),append($$anchor7,fragment_16)};if_block(node_22,$$render=>{get$3(item).id===AttachmentMenuItemId.SYSTEM_MESSAGE&&$$render(consequent_4)})}append($$anchor6,fragment_15)});var node_28=sibling(node_21,2);ChatFormActionAddToolsSubmenu(node_28,{});var node_29=sibling(node_28,2);ChatFormActionAddMcpServersSubmenu(node_29,{onMcpSettingsClick:handleMcpSettingsClick});var node_30=sibling(node_29,2);each(node_30,17,()=>ATTACHMENT_MCP_ITEMS,item=>item.id,($$anchor6,item)=>{
|
|
|
|
|
var fragment_20=comment$2(),node_31=first_child(fragment_20);{var consequent_5=$$anchor7=>{var fragment_21=comment$2(),node_32=first_child(fragment_21);component(node_32,()=>Dropdown_menu_item,($$anchor8,DropdownMenu_Item_4)=>{DropdownMenu_Item_4($$anchor8,{class:"flex cursor-pointer items-center gap-2",onclick:()=>attachmentMenu.callbacks[get$3(item).action](),children:($$anchor9,$$slotProps3)=>{var fragment_22=root_26$1(),node_33=first_child(fragment_22);component(node_33,()=>get$3(item).icon,
|
|
|
|
|
($$anchor10,item_icon_3)=>{item_icon_3($$anchor10,{class:"h-4 w-4"})});var span_4=sibling(node_33,2),text_6=child(span_4,!0);reset(span_4),template_effect(()=>set_text(text_6,get$3(item).label)),append($$anchor9,fragment_22)},$$slots:{default:!0}})}),append($$anchor7,fragment_21)},d_12=user_derived(()=>attachmentMenu.isItemVisible(get$3(item).visibleWhen));if_block(node_31,$$render=>{get$3(d_12)&&$$render(consequent_5)})}append($$anchor6,fragment_20)}),append($$anchor5,fragment_2)},$$slots:{default:!0}})}),
|
|
|
|
|
append($$anchor3,fragment)},$$slots:{default:!0}})}),reset(div),template_effect(()=>set_class(div,1,`flex items-center gap-1 ${className()??""}`)),append($$anchor,div),pop()}function Sheet_overlay($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data\
|
|
|
|
|
-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=open]:animate-in data-[state=open]:fade-in-0",$$props.class));component(node2,()=>Dialog_overlay$1,($$anchor2,SheetPrimitive_Overlay)=>{SheetPrimitive_Overlay($$anchor2,spread_props({"data-slot":"sheet-overlay",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const sheetVariants=tv({base:`border-border/30 dark:border-border/20 da\
|
|
|
|
|
ta-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fill-mode-forwards fixed z-50 flex flex-col gap-4 shadow-sm transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 ${PANEL_CLASSES}`,variants:{side:{top:"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",bottom:"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",left:"\
|
|
|
|
|
data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",right:"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm"}},defaultVariants:{side:"right"}});var root_3$Q=from_html('<!> <span class="sr-only">Close</span>',1),root_2$10=from_html("<!> <!>",1),root_1$L=from_html("<!> <!>",1);function Sheet_content($$anchor,$$props){push$1($$props,!0);let ref2=prop(
|
|
|
|
|
$$props,"ref",15,null),side=prop($$props,"side",3,"right"),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","side","portalProps","children"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$2,($$anchor2,SheetPrimitive_Portal)=>{SheetPrimitive_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$L(),node_1=first_child(fragment_1);Sheet_overlay(node_1,{});var node_2=sibling(node_1,
|
|
|
|
|
2);{let $0=user_derived(()=>cn$1(sheetVariants({side:side()}),$$props.class));component(node_2,()=>Dialog_content$1,($$anchor4,SheetPrimitive_Content)=>{SheetPrimitive_Content($$anchor4,spread_props({"data-slot":"sheet-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$10(),node_3=first_child(fragment_2);snippet(node_3,()=>$$props.children??noop$3);var node_4=sibling(node_3,2);component(
|
|
|
|
|
node_4,()=>Dialog_close,($$anchor6,SheetPrimitive_Close)=>{SheetPrimitive_Close($$anchor6,{class:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:outline-hidden disabled:pointer-events-none",children:($$anchor7,$$slotProps3)=>{var fragment_3=root_3$Q(),node_5=first_child(fragment_3);X(node_5,{class:"size-4"}),next$1(2),append($$anchor7,fragment_3)},$$slots:{
|
|
|
|
|
default:!0}})}),append($$anchor5,fragment_2)},$$slots:{default:!0}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}var root$1q=from_html("<div><!></div>");function Sheet_header($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$1q();attribute_effect(div,$0=>({"data-slot":"sheet-header",class:$0,...restProps}),[()=>cn$1("flex fle\
|
|
|
|
|
x-col gap-1.5 p-4",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}function Sheet_title($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("font-semibold text-foreground",$$props.class));component(
|
|
|
|
|
node2,()=>Dialog_title$1,($$anchor2,SheetPrimitive_Title)=>{SheetPrimitive_Title($$anchor2,spread_props({"data-slot":"sheet-title",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Sheet_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);
|
|
|
|
|
{let $0=user_derived(()=>cn$1("text-sm text-muted-foreground",$$props.class));component(node2,()=>Dialog_description$1,($$anchor2,SheetPrimitive_Description)=>{SheetPrimitive_Description($$anchor2,spread_props({"data-slot":"sheet-description",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const Root$3=Dialog;var root_3$P=from_html("<!> <!>",1),root_7$r=from_html('<button type="button"><!> <span> </span><\
|
|
|
|
|
/button>'),root_10$d=from_html('<button type="button" disabled=""><!> <span> </span></button>'),root_11$d=from_html("<p> </p>"),root_9$k=from_html("<!> <!>",1),root_15$9=from_html('<button type="button"><!> <span> </span></button>'),root_16$4=from_html("<p>PDFs will be converted to text. Image-based PDFs may not work properly.</p>"),root_14$6=from_html("<!> <!>",1),root_20$3=from_html('<button type="button"><!> <span> </span></button>'),root_21$4=from_html("<p> </p>"),root_19$9=from_html("<!> <!\
|
|
|
|
|
>",1),root_23$4=from_html('<button type="button"><!> <span> </span></button>'),root_2$$=from_html('<!> <div class="flex flex-col gap-1 px-1.5 pb-2"><!> <!> <!> <div class="my-2 border-t"></div> <a href="#/settings/mcp" class="flex items-center gap-3 px-3 py-2"><!> <span class="text-sm">MCP Servers</span></a> <a href="#/settings/chat/tools" class="flex items-center gap-3 px-3 py-2"><!> <span class="text-sm">Tools</span></a> <!></div>',1),root_1$K=from_html("<!> <!>",1),root$1p=from_html("<div><!>\
|
|
|
|
|
</div>");function ChatFormActionAddSheet($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),hasVisionModality=prop($$props,"hasVisionModality",3,!1),hasMcpPromptsSupport=prop($$props,"hasMcpPromptsSupport",3,!1),hasMcpResourcesSupport=prop($$props,"hasMcpResourcesSupport",3,!1),sheetOpen=state$1(!1);const attachmentMenu=useAttachmentMenu(()=>({hasVisionModality:hasVisionModality(),
|
|
|
|
|
hasAudioModality:hasAudioModality(),hasMcpPromptsSupport:hasMcpPromptsSupport(),hasMcpResourcesSupport:hasMcpResourcesSupport()}),()=>({onFileUpload:$$props.onFileUpload,onSystemPromptClick:$$props.onSystemPromptClick,onMcpPromptClick:$$props.onMcpPromptClick,onMcpResourcesClick:$$props.onMcpResourcesClick}),()=>{set$1(sheetOpen,!1)}),sheetItemClass="flex w-full items-center gap-3 rounded-md px-3 py-2.5 text-left text-sm transition-colors hover:bg-accent active:bg-accent disabled:cursor-not-allo\
|
|
|
|
|
wed disabled:opacity-50";var div=root$1p(),node2=child(div);component(node2,()=>Root$3,($$anchor2,Sheet_Root)=>{Sheet_Root($$anchor2,{get open(){return get$3(sheetOpen)},set open($$value){set$1(sheetOpen,$$value,!0)},children:($$anchor3,$$slotProps)=>{var fragment=root_1$K(),node_1=first_child(fragment);snippet(node_1,()=>$$props.trigger,()=>({disabled:disabled(),onclick:()=>set$1(sheetOpen,!0)}));var node_2=sibling(node_1,2);component(node_2,()=>Sheet_content,($$anchor4,Sheet_Content)=>{Sheet_Content(
|
|
|
|
|
$$anchor4,{side:"bottom",class:"max-h-[85vh] gap-0 overflow-y-auto",children:($$anchor5,$$slotProps2)=>{var fragment_1=root_2$$(),node_3=first_child(fragment_1);component(node_3,()=>Sheet_header,($$anchor6,Sheet_Header)=>{Sheet_Header($$anchor6,{children:($$anchor7,$$slotProps3)=>{var fragment_2=root_3$P(),node_4=first_child(fragment_2);component(node_4,()=>Sheet_title,($$anchor8,Sheet_Title)=>{Sheet_Title($$anchor8,{children:($$anchor9,$$slotProps4)=>{next$1();var text2=text$8("Add to chat");append(
|
|
|
|
|
$$anchor9,text2)},$$slots:{default:!0}})});var node_5=sibling(node_4,2);component(node_5,()=>Sheet_description,($$anchor8,Sheet_Description)=>{Sheet_Description($$anchor8,{class:"sr-only",children:($$anchor9,$$slotProps4)=>{next$1();var text_1=text$8("Add files, system prompt or configure MCP servers");append($$anchor9,text_1)},$$slots:{default:!0}})}),append($$anchor7,fragment_2)},$$slots:{default:!0}})});var div_1=sibling(node_3,2),node_6=child(div_1);each(node_6,17,()=>ATTACHMENT_FILE_ITEMS,item=>item.
|
|
|
|
|
id,($$anchor6,item)=>{const enabled=user_derived(()=>attachmentMenu.isItemEnabled(get$3(item).enabledWhen));var fragment_3=comment$2(),node_7=first_child(fragment_3);{var consequent=$$anchor7=>{var button=root_7$r();set_class(button,1,clsx(sheetItemClass));var node_8=child(button);component(node_8,()=>get$3(item).icon,($$anchor8,item_icon)=>{item_icon($$anchor8,{class:"h-4 w-4 shrink-0"})});var span=sibling(node_8,2),text_2=child(span,!0);reset(span),reset(button),template_effect(()=>set_text(text_2,
|
|
|
|
|
get$3(item).label)),delegated("click",button,()=>attachmentMenu.callbacks[get$3(item).action]()),append($$anchor7,button)},consequent_1=$$anchor7=>{var fragment_4=comment$2(),node_9=first_child(fragment_4);component(node_9,()=>Root$5,($$anchor8,Tooltip_Root)=>{Tooltip_Root($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_5=root_9$k(),node_10=first_child(fragment_5);component(node_10,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger)=>{Tooltip_Trigger(
|
|
|
|
|
$$anchor10,{children:($$anchor11,$$slotProps4)=>{var button_1=root_10$d();set_class(button_1,1,clsx(sheetItemClass));var node_11=child(button_1);component(node_11,()=>get$3(item).icon,($$anchor12,item_icon_1)=>{item_icon_1($$anchor12,{class:"h-4 w-4 shrink-0"})});var span_1=sibling(node_11,2),text_3=child(span_1,!0);reset(span_1),reset(button_1),template_effect(()=>set_text(text_3,get$3(item).label)),append($$anchor11,button_1)},$$slots:{default:!0}})});var node_12=sibling(node_10,2);component(node_12,
|
|
|
|
|
()=>Tooltip_content,($$anchor10,Tooltip_Content)=>{Tooltip_Content($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p2=root_11$d(),text_4=child(p2,!0);reset(p2),template_effect(()=>set_text(text_4,get$3(item).disabledTooltip)),append($$anchor11,p2)},$$slots:{default:!0}})}),append($$anchor9,fragment_5)},$$slots:{default:!0}})}),append($$anchor7,fragment_4)};if_block(node_7,$$render=>{get$3(enabled)?$$render(consequent):get$3(item).disabledTooltip&&$$render(consequent_1,1)})}append(
|
|
|
|
|
$$anchor6,fragment_3)});var node_13=sibling(node_6,2);{var consequent_3=$$anchor6=>{const pdfItem=user_derived(()=>ATTACHMENT_FILE_ITEMS.find(i=>i.id===AttachmentMenuItemId.PDF));var fragment_6=comment$2(),node_14=first_child(fragment_6);{var consequent_2=$$anchor7=>{var fragment_7=comment$2(),node_15=first_child(fragment_7);component(node_15,()=>Root$5,($$anchor8,Tooltip_Root_1)=>{Tooltip_Root_1($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_8=root_14$6(),
|
|
|
|
|
node_16=first_child(fragment_8);component(node_16,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger_1)=>{Tooltip_Trigger_1($$anchor10,{children:($$anchor11,$$slotProps4)=>{var button_2=root_15$9();set_class(button_2,1,clsx(sheetItemClass));var node_17=child(button_2);component(node_17,()=>get$3(pdfItem).icon,($$anchor12,pdfItem_icon)=>{pdfItem_icon($$anchor12,{class:"h-4 w-4 shrink-0"})});var span_2=sibling(node_17,2),text_5=child(span_2,!0);reset(span_2),reset(button_2),template_effect(()=>set_text(
|
|
|
|
|
text_5,get$3(pdfItem).label)),delegated("click",button_2,()=>attachmentMenu.callbacks[get$3(pdfItem).action]()),append($$anchor11,button_2)},$$slots:{default:!0}})});var node_18=sibling(node_16,2);component(node_18,()=>Tooltip_content,($$anchor10,Tooltip_Content_1)=>{Tooltip_Content_1($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{var p_1=root_16$4();append($$anchor11,p_1)},$$slots:{default:!0}})}),append($$anchor9,fragment_8)},$$slots:{default:!0}})}),append($$anchor7,fragment_7)};
|
|
|
|
|
if_block(node_14,$$render=>{get$3(pdfItem)&&$$render(consequent_2)})}append($$anchor6,fragment_6)},d2=user_derived(()=>!attachmentMenu.isItemEnabled("hasVisionModality"));if_block(node_13,$$render=>{get$3(d2)&&$$render(consequent_3)})}var node_19=sibling(node_13,2);each(node_19,17,()=>ATTACHMENT_EXTRA_ITEMS,item=>item.id,($$anchor6,item)=>{var fragment_9=comment$2(),node_20=first_child(fragment_9);{var consequent_4=$$anchor7=>{var fragment_10=comment$2(),node_21=first_child(fragment_10);component(
|
|
|
|
|
node_21,()=>Root$5,($$anchor8,Tooltip_Root_2)=>{Tooltip_Root_2($$anchor8,{get delayDuration(){return TOOLTIP_DELAY_DURATION},children:($$anchor9,$$slotProps3)=>{var fragment_11=root_19$9(),node_22=first_child(fragment_11);component(node_22,()=>Tooltip_trigger,($$anchor10,Tooltip_Trigger_2)=>{Tooltip_Trigger_2($$anchor10,{children:($$anchor11,$$slotProps4)=>{var button_3=root_20$3();set_class(button_3,1,clsx(sheetItemClass));var node_23=child(button_3);component(node_23,()=>get$3(item).icon,($$anchor12,item_icon_2)=>{
|
|
|
|
|
item_icon_2($$anchor12,{class:"h-4 w-4 shrink-0"})});var span_3=sibling(node_23,2),text_6=child(span_3,!0);reset(span_3),reset(button_3),template_effect(()=>set_text(text_6,get$3(item).label)),delegated("click",button_3,()=>attachmentMenu.callbacks[get$3(item).action]()),append($$anchor11,button_3)},$$slots:{default:!0}})});var node_24=sibling(node_22,2);component(node_24,()=>Tooltip_content,($$anchor10,Tooltip_Content_2)=>{Tooltip_Content_2($$anchor10,{side:"right",children:($$anchor11,$$slotProps4)=>{
|
|
|
|
|
var p_2=root_21$4(),text_7=child(p_2,!0);reset(p_2),template_effect($0=>set_text(text_7,$0),[()=>attachmentMenu.getSystemMessageTooltip()]),append($$anchor11,p_2)},$$slots:{default:!0}})}),append($$anchor9,fragment_11)},$$slots:{default:!0}})}),append($$anchor7,fragment_10)};if_block(node_20,$$render=>{get$3(item).id===AttachmentMenuItemId.SYSTEM_MESSAGE&&$$render(consequent_4)})}append($$anchor6,fragment_9)});var a=sibling(node_19,4),node_25=child(a);McpLogo(node_25,{class:"inline h-4 w-4"}),next$1(
|
|
|
|
|
2),reset(a);var a_1=sibling(a,2),node_26=child(a_1);Pencil_ruler(node_26,{class:"inline h-4 w-4"}),next$1(2),reset(a_1);var node_27=sibling(a_1,2);each(node_27,17,()=>ATTACHMENT_MCP_ITEMS,item=>item.id,($$anchor6,item)=>{var fragment_12=comment$2(),node_28=first_child(fragment_12);{var consequent_5=$$anchor7=>{var button_4=root_23$4();set_class(button_4,1,clsx(sheetItemClass));var node_29=child(button_4);component(node_29,()=>get$3(item).icon,($$anchor8,item_icon_3)=>{item_icon_3($$anchor8,{class:"\
|
|
|
|
|
h-4 w-4 shrink-0"})});var span_4=sibling(node_29,2),text_8=child(span_4,!0);reset(span_4),reset(button_4),template_effect(()=>set_text(text_8,get$3(item).label)),delegated("click",button_4,()=>attachmentMenu.callbacks[get$3(item).action]()),append($$anchor7,button_4)},d_12=user_derived(()=>attachmentMenu.isItemVisible(get$3(item).visibleWhen));if_block(node_28,$$render=>{get$3(d_12)&&$$render(consequent_5)})}append($$anchor6,fragment_12)}),reset(div_1),append($$anchor5,fragment_1)},$$slots:{default:!0}})}),
|
|
|
|
|
append($$anchor3,fragment)},$$slots:{default:!0}})}),reset(div),template_effect(()=>set_class(div,1,`flex items-center gap-1 ${className()??""}`)),append($$anchor,div),pop()}delegate(["click"]);var root_3$O=from_html('<span class="sr-only"> </span> <!>',1),root_4$z=from_html("<p> </p>"),root_1$J=from_html("<!> <!>",1);function ChatFormActionAddButton($$anchor,$$props){let disabled=prop($$props,"disabled",3,!1);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Root$5,($$anchor2,Tooltip_Root)=>{
|
|
|
|
|
Tooltip_Root($$anchor2,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$J(),node_1=first_child(fragment_1);component(node_1,()=>Tooltip_trigger,($$anchor4,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor4,{class:"w-full",children:($$anchor5,$$slotProps2)=>{Button($$anchor5,{class:"file-upload-button h-8 w-8 rounded-full p-0",get disabled(){return disabled()},get onclick(){return $$props.onclick},variant:"secondary",type:"button",children:($$anchor6,$$slotProps3)=>{var fragment_3=root_3$O(),span=first_child(
|
|
|
|
|
fragment_3),text2=child(span,!0);reset(span);var node_2=sibling(span,2);Plus(node_2,{class:"h-4 w-4"}),template_effect(()=>set_text(text2,ATTACHMENT_TOOLTIP_TEXT)),append($$anchor6,fragment_3)},$$slots:{default:!0}})},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Tooltip_content,($$anchor4,Tooltip_Content)=>{Tooltip_Content($$anchor4,{children:($$anchor5,$$slotProps2)=>{var p2=root_4$z(),text_1=child(p2,!0);reset(p2),template_effect(()=>set_text(text_1,ATTACHMENT_TOOLTIP_TEXT)),
|
|
|
|
|
append($$anchor5,p2)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment)}function ChatFormActionsAdd($$anchor,$$props){push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),hasMcpPromptsSupport=prop($$props,"hasMcpPromptsSupport",3,!1),hasMcpResourcesSupport=prop($$props,"hasMcpResourcesSupport",3,!1),hasVisionModality=prop($$props,"hasVisionModality",3,!1);const isMobile=new IsMobile;
|
|
|
|
|
var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{ChatFormActionAddSheet($$anchor2,{get disabled(){return disabled()},get hasAudioModality(){return hasAudioModality()},get hasVisionModality(){return hasVisionModality()},get hasMcpPromptsSupport(){return hasMcpPromptsSupport()},get hasMcpResourcesSupport(){return hasMcpResourcesSupport()},get onFileUpload(){return $$props.onFileUpload},get onMcpPromptClick(){return $$props.onMcpPromptClick},get onMcpResourcesClick(){
|
|
|
|
|
return $$props.onMcpResourcesClick},trigger:($$anchor3,$$arg0)=>{let disabled2=()=>$$arg0?.().disabled,onclick=()=>$$arg0?.().onclick;ChatFormActionAddButton($$anchor3,{get disabled(){return disabled2()},get onclick(){return onclick()}})},$$slots:{trigger:!0}})},alternate=$$anchor2=>{ChatFormActionAddDropdown($$anchor2,{get disabled(){return disabled()},get hasAudioModality(){return hasAudioModality()},get hasVisionModality(){return hasVisionModality()},get hasMcpPromptsSupport(){return hasMcpPromptsSupport()},
|
|
|
|
|
get hasMcpResourcesSupport(){return hasMcpResourcesSupport()},get onFileUpload(){return $$props.onFileUpload},get onMcpPromptClick(){return $$props.onMcpPromptClick},get onMcpResourcesClick(){return $$props.onMcpResourcesClick},get onMcpSettingsClick(){return $$props.onMcpSettingsClick},get onSystemPromptClick(){return $$props.onSystemPromptClick},trigger:$$anchor3=>{ChatFormActionAddButton($$anchor3,{get disabled(){return disabled()}})},$$slots:{trigger:!0}})};if_block(node2,$$render=>{isMobile.
|
|
|
|
|
current?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment),pop()}var root_3$N=from_html('<span class="sr-only"> </span> <!>',1),root_7$q=from_html("<p>Current model does not support audio</p>"),root_1$I=from_html("<!> <!>",1),root$1o=from_html("<div><!></div>");function ChatFormActionRecord($$anchor,$$props){let className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),hasAudioModality=prop($$props,"hasAudioModality",3,!1),isLoading2=prop($$props,"isLoading",
|
|
|
|
|
3,!1),isRecording=prop($$props,"isRecording",3,!1);var div=root$1o(),node2=child(div);component(node2,()=>Root$5,($$anchor2,Tooltip_Root)=>{Tooltip_Root($$anchor2,{children:($$anchor3,$$slotProps)=>{var fragment=root_1$I(),node_1=first_child(fragment);component(node_1,()=>Tooltip_trigger,($$anchor4,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor4,{children:($$anchor5,$$slotProps2)=>{{let $0=user_derived(()=>isRecording()?"animate-pulse bg-red-500 text-white hover:bg-red-600":""),$1=user_derived(()=>disabled()||
|
|
|
|
|
isLoading2()||!hasAudioModality());Button($$anchor5,{get class(){return`h-8 w-8 rounded-full p-0 ${get$3($0)??""}`},get disabled(){return get$3($1)},get onclick(){return $$props.onMicClick},type:"button",children:($$anchor6,$$slotProps3)=>{var fragment_2=root_3$N(),span=first_child(fragment_2),text2=child(span,!0);reset(span);var node_2=sibling(span,2);{var consequent=$$anchor7=>{Square($$anchor7,{class:"h-4 w-4 animate-pulse fill-white"})},alternate=$$anchor7=>{Mic($$anchor7,{class:"h-4 w-4"})};
|
|
|
|
|
if_block(node_2,$$render=>{isRecording()?$$render(consequent):$$render(alternate,-1)})}template_effect(()=>set_text(text2,isRecording()?"Stop recording":"Start recording")),append($$anchor6,fragment_2)},$$slots:{default:!0}})}},$$slots:{default:!0}})});var node_3=sibling(node_1,2);{var consequent_1=$$anchor4=>{var fragment_5=comment$2(),node_4=first_child(fragment_5);component(node_4,()=>Tooltip_content,($$anchor5,Tooltip_Content)=>{Tooltip_Content($$anchor5,{children:($$anchor6,$$slotProps2)=>{
|
|
|
|
|
var p2=root_7$q();append($$anchor6,p2)},$$slots:{default:!0}})}),append($$anchor4,fragment_5)};if_block(node_3,$$render=>{hasAudioModality()||$$render(consequent_1)})}append($$anchor3,fragment)},$$slots:{default:!0}})}),reset(div),template_effect(()=>set_class(div,1,`flex items-center gap-1 ${className()??""}`)),append($$anchor,div)}var root_1$H=from_html('<div class="mr-auto flex items-center gap-2"><!></div>'),root_4$y=from_html('<span class="sr-only">Stop</span> <!>',1),root$1n=from_html('<di\
|
|
|
|
|
v style="container-type: inline-size"><!> <!> <!></div>');function ChatFormActions($$anchor,$$props){push$1($$props,!0);let canSend=prop($$props,"canSend",3,!1),canSubmit=prop($$props,"canSubmit",3,!1),className=prop($$props,"class",3,""),disabled=prop($$props,"disabled",3,!1),isLoading2=prop($$props,"isLoading",3,!1),isRecording=prop($$props,"isRecording",3,!1),showAddButton=prop($$props,"showAddButton",3,!0),showModelSelector=prop($$props,"showModelSelector",3,!0),uploadedFiles=prop($$props,"u\
|
|
|
|
|
ploadedFiles",19,()=>[]),currentConfig=user_derived(config$1),hasMcpPromptsSupport=user_derived(()=>{const perChatOverrides=conversationsStore.getAllMcpServerOverrides();return mcpStore.hasPromptsCapability(perChatOverrides)}),hasMcpResourcesSupport=user_derived(()=>{const perChatOverrides=conversationsStore.getAllMcpServerOverrides();return mcpStore.hasResourcesCapability(perChatOverrides)}),hasAudioModality=state$1(!1),hasVisionModality=state$1(!1),hasModelSelected=state$1(!1),isSelectedModelInCache=state$1(
|
|
|
|
|
!0),submitTooltip=state$1(""),hasAudioAttachments=user_derived(()=>uploadedFiles().some(file=>getFileTypeCategory(file.type)===FileTypeCategory.AUDIO)),shouldShowRecordButton=user_derived(()=>get$3(hasAudioModality)&&!canSubmit()&&!get$3(hasAudioAttachments)&&get$3(currentConfig).autoMicOnEmpty),selectorModelRef=state$1(void 0);function openModelSelector(){get$3(selectorModelRef)?.open()}var $$exports={openModelSelector},div=root$1n(),node2=child(div);{var consequent=$$anchor2=>{var div_1=root_1$H(),
|
|
|
|
|
node_1=child(div_1);ChatFormActionsAdd(node_1,{get disabled(){return disabled()},get hasAudioModality(){return get$3(hasAudioModality)},get hasVisionModality(){return get$3(hasVisionModality)},get hasMcpPromptsSupport(){return get$3(hasMcpPromptsSupport)},get hasMcpResourcesSupport(){return get$3(hasMcpResourcesSupport)},get onFileUpload(){return $$props.onFileUpload},get onSystemPromptClick(){return $$props.onSystemPromptClick},get onMcpPromptClick(){return $$props.onMcpPromptClick},get onMcpResourcesClick(){
|
|
|
|
|
return $$props.onMcpResourcesClick},onMcpSettingsClick:()=>goto("#/settings/mcp")}),reset(div_1),append($$anchor2,div_1)};if_block(node2,$$render=>{showAddButton()&&$$render(consequent)})}var node_2=sibling(node2,2);{var consequent_1=$$anchor2=>{bind_this(ChatFormActionModels($$anchor2,{get disabled(){return disabled()},forceForegroundText:!0,useGlobalSelection:!0,get hasAudioModality(){return get$3(hasAudioModality)},set hasAudioModality($$value){set$1(hasAudioModality,$$value,!0)},get hasVisionModality(){
|
|
|
|
|
return get$3(hasVisionModality)},set hasVisionModality($$value){set$1(hasVisionModality,$$value,!0)},get hasModelSelected(){return get$3(hasModelSelected)},set hasModelSelected($$value){set$1(hasModelSelected,$$value,!0)},get isSelectedModelInCache(){return get$3(isSelectedModelInCache)},set isSelectedModelInCache($$value){set$1(isSelectedModelInCache,$$value,!0)},get submitTooltip(){return get$3(submitTooltip)},set submitTooltip($$value){set$1(submitTooltip,$$value,!0)}}),$$value=>set$1(selectorModelRef,
|
|
|
|
|
$$value,!0),()=>get$3(selectorModelRef))};if_block(node_2,$$render=>{showModelSelector()&&$$render(consequent_1)})}var node_3=sibling(node_2,2);{var consequent_2=$$anchor2=>{Button($$anchor2,{type:"button",variant:"secondary",get onclick(){return $$props.onStop},class:"group h-8 w-8 rounded-full p-0 hover:bg-destructive/10!",children:($$anchor3,$$slotProps)=>{var fragment_2=root_4$y(),node_4=sibling(first_child(fragment_2),2);Square(node_4,{class:"h-8 w-8 fill-muted-foreground stroke-muted-foreg\
|
|
|
|
|
round group-hover:fill-destructive group-hover:stroke-destructive hover:fill-destructive hover:stroke-destructive"}),append($$anchor3,fragment_2)},$$slots:{default:!0}})},consequent_3=$$anchor2=>{ChatFormActionRecord($$anchor2,{get disabled(){return disabled()},get hasAudioModality(){return get$3(hasAudioModality)},get isLoading(){return isLoading2()},get isRecording(){return isRecording()},get onMicClick(){return $$props.onMicClick}})},alternate=$$anchor2=>{{let $0=user_derived(()=>canSend()&&(showModelSelector()?
|
|
|
|
|
get$3(hasModelSelected)&&get$3(isSelectedModelInCache):!0)),$1=user_derived(()=>showModelSelector()&&get$3(hasModelSelected)&&!get$3(isSelectedModelInCache));ChatFormActionSubmit($$anchor2,{get canSend(){return get$3($0)},get disabled(){return disabled()},get tooltipLabel(){return get$3(submitTooltip)},get showErrorState(){return get$3($1)}})}};if_block(node_3,$$render=>{isLoading2()&&!canSubmit()?$$render(consequent_2):get$3(shouldShowRecordButton)?$$render(consequent_3,1):$$render(alternate,-1)})}
|
|
|
|
|
return reset(div),template_effect(()=>set_class(div,1,`flex w-full items-center gap-3 ${className()??""} ${showAddButton()?"":"justify-end"}`)),append($$anchor,div),pop($$exports)}var root_2$_=from_html('<span class="sr-only">Send</span> <!>',1),root_6$s=from_html("<p> </p>"),root_4$x=from_html("<!> <!>",1);function ChatFormActionSubmit($$anchor,$$props){const submitButton=($$anchor2,$$arg0)=>{let props=derived_safe_equal(()=>fallback($$arg0?.(),()=>({}),!0));{let $0=user_derived(()=>["h-8 w-8 r\
|
|
|
|
|
ounded-full p-0",showErrorState()&&"bg-red-400/10 text-red-400 hover:bg-red-400/20 hover:text-red-400 disabled:opacity-100"]);Button($$anchor2,spread_props({type:"submit",get disabled(){return get$3(isDisabled)},get class(){return get$3($0)}},()=>get$3(props),{children:($$anchor3,$$slotProps)=>{var fragment_1=root_2$_(),node2=sibling(first_child(fragment_1),2);Arrow_up(node2,{class:"h-12 w-12"}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))}};let canSend=prop($$props,"canSend",3,!1),disabled=prop(
|
|
|
|
|
$$props,"disabled",3,!1),showErrorState=prop($$props,"showErrorState",3,!1),isDisabled=user_derived(()=>!canSend()||disabled());var fragment_2=comment$2(),node_1=first_child(fragment_2);{var consequent=$$anchor2=>{var fragment_3=comment$2(),node_2=first_child(fragment_3);component(node_2,()=>Root$5,($$anchor3,Tooltip_Root)=>{Tooltip_Root($$anchor3,{children:($$anchor4,$$slotProps)=>{var fragment_4=root_4$x(),node_3=first_child(fragment_4);component(node_3,()=>Tooltip_trigger,($$anchor5,Tooltip_Trigger)=>{
|
|
|
|
|
Tooltip_Trigger($$anchor5,{children:($$anchor6,$$slotProps2)=>{submitButton($$anchor6)},$$slots:{default:!0}})});var node_4=sibling(node_3,2);component(node_4,()=>Tooltip_content,($$anchor5,Tooltip_Content)=>{Tooltip_Content($$anchor5,{children:($$anchor6,$$slotProps2)=>{var p2=root_6$s(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,$$props.tooltipLabel)),append($$anchor6,p2)},$$slots:{default:!0}})}),append($$anchor4,fragment_4)},$$slots:{default:!0}})}),append($$anchor2,fragment_3)},
|
|
|
|
|
alternate=$$anchor2=>{submitButton($$anchor2)};if_block(node_1,$$render=>{$$props.tooltipLabel?$$render(consequent):$$render(alternate,-1)})}append($$anchor,fragment_2)}function ChatFormActionModels($$anchor,$$props){push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1),forceForegroundText=prop($$props,"forceForegroundText",3,!1),hasAudioModality=prop($$props,"hasAudioModality",15,!1),hasVisionModality=prop($$props,"hasVisionModality",15,!1),hasModelSelected=prop($$props,"hasModelSelecte\
|
|
|
|
|
d",15,!1),isSelectedModelInCache=prop($$props,"isSelectedModelInCache",15,!0),submitTooltip=prop($$props,"submitTooltip",15,""),useGlobalSelection=prop($$props,"useGlobalSelection",3,!1),isRouter=user_derived(isRouterMode),isOffline=user_derived(()=>!!serverError()),conversationModel=user_derived(()=>chatStore.getConversationModel(activeMessages())),lastSyncedConversationModel=null;user_effect(()=>{if(get$3(conversationModel)&&get$3(conversationModel)!==lastSyncedConversationModel)lastSyncedConversationModel=
|
|
|
|
|
get$3(conversationModel),modelsStore.selectModelByName(get$3(conversationModel));else if(get$3(isRouter)&&!modelsStore.selectedModelId&&modelsStore.loadedModelIds.length>0){lastSyncedConversationModel=null;const first=modelOptions().find(m=>modelsStore.loadedModelIds.includes(m.model));first&&modelsStore.selectModelById(first.id)}});let activeModelId=user_derived(()=>{const options=modelOptions();if(!get$3(isRouter))return options.length>0?options[0].model:null;const selectedId=selectedModelId();
|
|
|
|
|
if(selectedId){const model=options.find(m=>m.id===selectedId);if(model)return model.model}if(get$3(conversationModel)){const model=options.find(m=>m.model===get$3(conversationModel));if(model)return model.model}return null}),modelPropsVersion=state$1(0);user_effect(()=>{get$3(activeModelId)&&(modelsStore.getModelProps(get$3(activeModelId))||modelsStore.fetchModelProps(get$3(activeModelId)).then(()=>{update$1(modelPropsVersion)}))}),user_effect(()=>{hasAudioModality(get$3(activeModelId)?modelsStore.
|
|
|
|
|
modelSupportsAudio(get$3(activeModelId)):!1)}),user_effect(()=>{get$3(modelPropsVersion),hasVisionModality(get$3(activeModelId)?modelsStore.modelSupportsVision(get$3(activeModelId)):!1)}),user_effect(()=>{hasModelSelected(!get$3(isRouter)||!!get$3(conversationModel)||!!selectedModelId())}),user_effect(()=>{if(!get$3(isRouter))isSelectedModelInCache(!0);else if(get$3(conversationModel))isSelectedModelInCache(modelOptions().some(option2=>option2.model===get$3(conversationModel)));else{const currentModelId=selectedModelId();
|
|
|
|
|
isSelectedModelInCache(currentModelId?modelOptions().some(option2=>option2.id===currentModelId):!1)}}),user_effect(()=>{hasModelSelected()?isSelectedModelInCache()?submitTooltip(""):submitTooltip("Selected model is not available, please select another"):submitTooltip("Please select a model first")});let selectorModelRef=state$1(void 0),isMobile=new IsMobile;function open2(){get$3(selectorModelRef)?.open()}var $$exports={open:open2},fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{
|
|
|
|
|
{let $0=user_derived(()=>disabled()||get$3(isOffline));bind_this(ModelsSelectorSheet($$anchor2,{get disabled(){return get$3($0)},get currentModel(){return $$props.currentModel},get forceForegroundText(){return forceForegroundText()},get useGlobalSelection(){return useGlobalSelection()}}),$$value=>set$1(selectorModelRef,$$value,!0),()=>get$3(selectorModelRef))}},alternate=$$anchor2=>{{let $0=user_derived(()=>disabled()||get$3(isOffline));bind_this(ModelsSelectorDropdown($$anchor2,{get disabled(){
|
|
|
|
|
return get$3($0)},get currentModel(){return $$props.currentModel},get forceForegroundText(){return forceForegroundText()},get useGlobalSelection(){return useGlobalSelection()}}),$$value=>set$1(selectorModelRef,$$value,!0),()=>get$3(selectorModelRef))}};if_block(node2,$$render=>{isMobile.current?$$render(consequent):$$render(alternate,-1)})}return append($$anchor,fragment),pop($$exports)}function Collapsible($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),open2=prop($$props,
|
|
|
|
|
"open",15,!1),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","open"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible$1,($$anchor2,CollapsiblePrimitive_Root)=>{CollapsiblePrimitive_Root($$anchor2,spread_props({"data-slot":"collapsible"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},get open(){return open2()},set open($$value){open2($$value)}}))}),append($$anchor,fragment),pop()}function Collapsible_trigger($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible_trigger$1,($$anchor2,CollapsiblePrimitive_Trigger)=>{CollapsiblePrimitive_Trigger($$anchor2,spread_props({"data-slot":"collapsible-trigger"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))}),append($$anchor,fragment),pop()}function Collapsible_content($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible_content$1,($$anchor2,CollapsiblePrimitive_Content)=>{CollapsiblePrimitive_Content($$anchor2,spread_props({"data-slot":"collapsible-content"},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))}),append($$anchor,fragment),pop()}function useToolsPanel(){const expandedGroups=new SvelteSet,
|
|
|
|
|
groups=user_derived(()=>toolsStore.toolGroups),activeGroups=user_derived(()=>get$3(groups).filter(g=>g.source!==ToolSource.MCP||!g.serverId||conversationsStore.isMcpServerEnabledForChat(g.serverId))),totalToolCount=user_derived(()=>get$3(activeGroups).reduce((n,g)=>n+g.tools.length,0)),noToolsInfoMessage=user_derived(()=>toolsStore.loading||toolsStore.toolGroups.length>0?null:toolsStore.isToolsEndpointUnreachable?"To enable Built-In Tools you need to run llama-server with --tools all or --tools \
|
|
|
|
|
<name> flag. To see MCP Tools you need to add / enable MCP Server(s).":toolsStore.error?null:"To enable Built-In Tools you need to run llama-server with --tools all or --tools <name> flag. To see MCP Tools you need to add / enable MCP Server(s).");function getGroupCheckedState(group){return{checked:toolsStore.isGroupFullyEnabled(group),indeterminate:toolsStore.isGroupPartiallyEnabled(group)}}function getEnabledToolCount(group){return group.tools.filter(tool=>toolsStore.isToolEnabled(tool.function.
|
|
|
|
|
name)).length}function getFavicon(group){if(group.source!==ToolSource.MCP)return null;for(const server of mcpStore.getServersSorted())if(mcpStore.getServerLabel(server)===group.label)return mcpStore.getServerFavicon(server.id);return null}function isGroupDisabled(group){return group.source===ToolSource.MCP&&!!group.serverId&&!conversationsStore.isMcpServerEnabledForChat(group.serverId)}function toggleGroupExpanded(label){expandedGroups.has(label)?expandedGroups.delete(label):expandedGroups.add(label)}
|
|
|
|
|
function handleOpen(){toolsStore.builtinTools.length===0&&!toolsStore.loading&&toolsStore.fetchBuiltinTools(),mcpStore.runHealthChecksForServers(mcpStore.getServersSorted().filter(s2=>s2.enabled))}return{expandedGroups,get groups(){return get$3(groups)},get activeGroups(){return get$3(activeGroups)},get totalToolCount(){return get$3(totalToolCount)},get noToolsInfoMessage(){return get$3(noToolsInfoMessage)},getGroupCheckedState,getEnabledToolCount,getFavicon,isGroupDisabled,toggleGroupExpanded,handleOpen}}
|
|
|
|
|
var root_2$Z=from_html("<!> <span>Tools</span>",1),root_5$s=from_html('<div class="px-3 py-4 text-center text-sm text-muted-foreground"><!> Loading tools...</div>'),root_6$r=from_html('<div class="grid gap-2.5 px-3 py-4 text-sm text-muted-foreground"><span class="flex gap-2"><!> <span>Run llama-server with <code>--tools</code> flag to enable <strong>Built-in Tools</strong>.</span></span> <span class="flex gap-2"><!> <span> <strong>MCP Tools</strong>.</span></span></div>'),root_7$p=from_html('<di\
|
|
|
|
|
v class="px-3 py-4 text-center text-sm text-muted-foreground">Failed to load tools</div>'),root_8$p=from_html('<div class="flex gap-2 px-3 py-4 text-sm text-muted-foreground"><!> <span> </span></div>'),root_9$j=from_html('<div class="px-3 py-4 text-center text-sm text-muted-foreground">No tools available</div>'),root_16$3=from_html('<img alt="" class="h-4 w-4 shrink-0 rounded-sm"/>'),root_13$a=from_html('<!> <span class="inline-flex min-w-0 items-center gap-1.5 font-medium"><!> <span class="trun\
|
|
|
|
|
cate"> </span></span> <span class="ml-auto shrink-0 text-xs text-muted-foreground"> </span>',1),root_19$8=from_html("<p> </p>"),root_17$7=from_html("<!> <!>",1),root_21$3=from_html('<button type="button" class="flex w-full items-center gap-2 rounded px-2 py-1.5 text-left text-sm transition-colors hover:bg-muted/50"><!> <span class="min-w-0 flex-1 truncate font-mono text-[12px]"> </span></button>'),root_20$2=from_html('<div class="ml-4 flex flex-col gap-0.5 border-l border-border/50 pl-2"></div>'),
|
|
|
|
|
root_12$8=from_html('<div class="flex items-center gap-1"><!> <!></div> <!>',1),root_10$c=from_html('<div class="max-h-80 overflow-y-auto p-2 pr-1"></div>'),root_1$G=from_html("<!> <!>",1);function ChatFormActionAddToolsSubmenu($$anchor,$$props){push$1($$props,!0);const toolsPanel=useToolsPanel(),hasMcpServersAvailable=user_derived(()=>mcpStore.getServersSorted().length>0);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Sub,($$anchor2,DropdownMenu_Sub)=>{DropdownMenu_Sub(
|
|
|
|
|
$$anchor2,{onOpenChange:open2=>open2&&toolsPanel.handleOpen(),children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$G(),node_1=first_child(fragment_1);component(node_1,()=>Dropdown_menu_sub_trigger,($$anchor4,DropdownMenu_SubTrigger)=>{DropdownMenu_SubTrigger($$anchor4,{class:"flex cursor-pointer items-center gap-2",children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$Z(),node_2=first_child(fragment_2);Pencil_ruler(node_2,{class:"h-4 w-4"}),next$1(2),append($$anchor5,fragment_2)},$$slots:{
|
|
|
|
|
default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Dropdown_menu_sub_content,($$anchor4,DropdownMenu_SubContent)=>{DropdownMenu_SubContent($$anchor4,{class:"w-72 p-0",children:($$anchor5,$$slotProps2)=>{var fragment_3=comment$2(),node_4=first_child(fragment_3);{var consequent_4=$$anchor6=>{var fragment_4=comment$2(),node_5=first_child(fragment_4);{var consequent=$$anchor7=>{var div=root_5$s(),node_6=child(div);Loader_circle(node_6,{class:"mx-auto mb-1 h-4 w-4 animate-spin"}),next$1(),
|
|
|
|
|
reset(div),append($$anchor7,div)},consequent_1=$$anchor7=>{var div_1=root_6$r(),span=child(div_1),node_7=child(span);Info$1(node_7,{class:"mt-0.5 h-4 w-4 shrink-0"}),next$1(2),reset(span);var span_1=sibling(span,2),node_8=child(span_1);Info$1(node_8,{class:"mt-0.5 h-4 w-4 shrink-0"});var span_2=sibling(node_8,2),text2=child(span_2);next$1(2),reset(span_2),reset(span_1),reset(div_1),template_effect(()=>set_text(text2,`${get$3(hasMcpServersAvailable)?"Enable":"Add"} MCP Server(s) to access `)),append(
|
|
|
|
|
$$anchor7,div_1)},consequent_2=$$anchor7=>{var div_2=root_7$p();append($$anchor7,div_2)},consequent_3=$$anchor7=>{var div_3=root_8$p(),node_9=child(div_3);Info$1(node_9,{class:"mt-0.5 h-4 w-4 shrink-0"});var span_3=sibling(node_9,2),text_1=child(span_3,!0);reset(span_3),reset(div_3),template_effect(()=>set_text(text_1,toolsPanel.noToolsInfoMessage)),append($$anchor7,div_3)},alternate=$$anchor7=>{var div_4=root_9$j();append($$anchor7,div_4)};if_block(node_5,$$render=>{toolsStore.loading?$$render(
|
|
|
|
|
consequent):toolsStore.isToolsEndpointUnreachable?$$render(consequent_1,1):toolsStore.error?$$render(consequent_2,2):toolsPanel.noToolsInfoMessage?$$render(consequent_3,3):$$render(alternate,-1)})}append($$anchor6,fragment_4)},alternate_2=$$anchor6=>{var div_5=root_10$c();each(div_5,21,()=>toolsPanel.activeGroups,group=>group.label,($$anchor7,group)=>{const isExpanded=user_derived(()=>toolsPanel.expandedGroups.has(get$3(group).label)),computed_const=user_derived(()=>{const{checked,indeterminate}=toolsPanel.
|
|
|
|
|
getGroupCheckedState(get$3(group));return{checked,indeterminate}}),favicon=user_derived(()=>toolsPanel.getFavicon(get$3(group)));var fragment_5=comment$2(),node_10=first_child(fragment_5);component(node_10,()=>Collapsible,($$anchor8,Collapsible_Root)=>{Collapsible_Root($$anchor8,{get open(){return get$3(isExpanded)},onOpenChange:()=>toolsPanel.toggleGroupExpanded(get$3(group).label),children:($$anchor9,$$slotProps3)=>{var fragment_6=root_12$8(),div_6=first_child(fragment_6),node_11=child(div_6);
|
|
|
|
|
component(node_11,()=>Collapsible_trigger,($$anchor10,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor10,{class:"flex min-w-0 flex-1 items-center gap-2 rounded px-2 py-1.5 text-sm hover:bg-muted/50",children:($$anchor11,$$slotProps4)=>{var fragment_7=root_13$a(),node_12=first_child(fragment_7);{var consequent_5=$$anchor12=>{Chevron_down($$anchor12,{class:"h-3.5 w-3.5 shrink-0"})},alternate_1=$$anchor12=>{Chevron_right($$anchor12,{class:"h-3.5 w-3.5 shrink-0"})};if_block(node_12,$$render=>{get$3(
|
|
|
|
|
isExpanded)?$$render(consequent_5):$$render(alternate_1,-1)})}var span_4=sibling(node_12,2),node_13=child(span_4);{var consequent_6=$$anchor12=>{var img=root_16$3();template_effect(()=>set_attribute(img,"src",get$3(favicon))),event("error",img,e=>{e.currentTarget.style.display="none"}),replay_events(img),append($$anchor12,img)};if_block(node_13,$$render=>{get$3(favicon)&&$$render(consequent_6)})}var span_5=sibling(node_13,2),text_2=child(span_5,!0);reset(span_5),reset(span_4);var span_6=sibling(
|
|
|
|
|
span_4,2),text_3=child(span_6);reset(span_6),template_effect($0=>{set_text(text_2,get$3(group).label),set_text(text_3,`${$0??""}/${get$3(group).tools.length??""}`)},[()=>toolsPanel.getEnabledToolCount(get$3(group))]),append($$anchor11,fragment_7)},$$slots:{default:!0}})});var node_14=sibling(node_11,2);component(node_14,()=>Root$5,($$anchor10,Tooltip_Root)=>{Tooltip_Root($$anchor10,{children:($$anchor11,$$slotProps4)=>{var fragment_10=root_17$7(),node_15=first_child(fragment_10);component(node_15,
|
|
|
|
|
()=>Tooltip_trigger,($$anchor12,Tooltip_Trigger)=>{Tooltip_Trigger($$anchor12,{children:($$anchor13,$$slotProps5)=>{Checkbox($$anchor13,{get checked(){return get$3(computed_const).checked},get indeterminate(){return get$3(computed_const).indeterminate},onCheckedChange:()=>toolsStore.toggleGroup(get$3(group)),class:"mr-2 h-4 w-4 shrink-0"})},$$slots:{default:!0}})});var node_16=sibling(node_15,2);component(node_16,()=>Tooltip_content,($$anchor12,Tooltip_Content)=>{Tooltip_Content($$anchor12,{side:"\
|
|
|
|
|
right",children:($$anchor13,$$slotProps5)=>{var p2=root_19$8(),text_4=child(p2);reset(p2),template_effect(()=>set_text(text_4,`${get$3(computed_const).checked?"Disable":"Enable"}
|
|
|
|
|
${get$3(group).tools.length??""} tool${get$3(group).tools.length!==1?"s":""}`)),append($$anchor13,p2)},$$slots:{default:!0}})}),append($$anchor11,fragment_10)},$$slots:{default:!0}})}),reset(div_6);var node_17=sibling(div_6,2);component(node_17,()=>Collapsible_content,($$anchor10,Collapsible_Content)=>{Collapsible_Content($$anchor10,{children:($$anchor11,$$slotProps4)=>{var div_7=root_20$2();each(div_7,21,()=>get$3(group).tools,tool=>tool.function.name,($$anchor12,tool)=>{var button=root_21$3(),
|
|
|
|
|
node_18=child(button);{let $0=user_derived(()=>toolsStore.isToolEnabled(get$3(tool).function.name));Checkbox(node_18,{get checked(){return get$3($0)},onCheckedChange:()=>toolsStore.toggleTool(get$3(tool).function.name),class:"h-4 w-4 shrink-0"})}var span_7=sibling(node_18,2),text_5=child(span_7,!0);reset(span_7),reset(button),template_effect(()=>set_text(text_5,get$3(tool).function.name)),delegated("click",button,()=>toolsStore.toggleTool(get$3(tool).function.name)),append($$anchor12,button)}),reset(
|
|
|
|
|
div_7),append($$anchor11,div_7)},$$slots:{default:!0}})}),append($$anchor9,fragment_6)},$$slots:{default:!0}})}),append($$anchor7,fragment_5)}),reset(div_5),append($$anchor6,div_5)};if_block(node_4,$$render=>{toolsPanel.totalToolCount===0?$$render(consequent_4):$$render(alternate_2,-1)})}append($$anchor5,fragment_3)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment),pop()}delegate(["click"]);function Switch($$anchor,$$props){push$1($$props,
|
|
|
|
|
@@ -6717,20 +6718,20 @@ Button(node_2,{type:"button",size:"sm",get onclick(){return $$props.onCancel},va
|
|
|
|
|
this,$$args)}),append($$anchor,form),pop()}function Popover($$anchor,$$props){push$1($$props,!0);let open2=prop($$props,"open",15,!1),restProps=rest_props($$props,["$$slots","$$events","$$legacy","open"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Popover$1,($$anchor2,PopoverPrimitive_Root)=>{PopoverPrimitive_Root($$anchor2,spread_props(()=>restProps,{get open(){return open2()},set open($$value){open2($$value)}}))}),append($$anchor,fragment),pop()}function Popover_portal($$anchor,$$props){
|
|
|
|
|
let restProps=rest_props($$props,["$$slots","$$events","$$legacy"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$2,($$anchor2,PopoverPrimitive_Portal)=>{PopoverPrimitive_Portal($$anchor2,spread_props(()=>restProps))}),append($$anchor,fragment)}function Popover_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),sideOffset=prop($$props,"sideOffset",3,4),align=prop($$props,"align",3,"center"),collisionPadding=prop($$props,"collisionP\
|
|
|
|
|
adding",3,8),avoidCollisions=prop($$props,"avoidCollisions",3,!0),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","sideOffset","side","align","collisionPadding","avoidCollisions","portalProps"]);Popover_portal($$anchor,spread_props(()=>$$props.portalProps,{children:($$anchor2,$$slotProps)=>{var fragment_1=comment$2(),node2=first_child(fragment_1);{let $0=user_derived(()=>cn$1("z-50 w-72 origin-(--bits-popover-content-transform-origin) rounded-md border bg-popover p-4 \
|
|
|
|
|
text-popover-foreground shadow-md outline-hidden data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-end-2 data-[side=right]:slide-in-from-start-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",$$props.class));component(node2,()=>Popover_content$1,($$anchor3,PopoverPrimitive_Content)=>{PopoverPrimitive_Content(
|
|
|
|
|
$$anchor3,spread_props({"data-slot":"popover-content",get sideOffset(){return sideOffset()},get side(){return $$props.side},get align(){return align()},get collisionPadding(){return collisionPadding()},get avoidCollisions(){return avoidCollisions()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Popover_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,
|
|
|
|
|
"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("",$$props.class));component(node2,()=>Popover_trigger$1,($$anchor2,PopoverPrimitive_Trigger)=>{PopoverPrimitive_Trigger($$anchor2,spread_props({"data-slot":"popover-trigger",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_2$U=from_html(
|
|
|
|
|
'<span class="sr-only"> </span>'),root_1$D=from_html("<!> <!>",1);function ChatFormPickerPopover($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),isOpen=prop($$props,"isOpen",15,!1),srLabel=prop($$props,"srLabel",3,"Open picker");var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Popover,($$anchor2,Popover_Root)=>{Popover_Root($$anchor2,{onOpenChange:open2=>{open2||$$props.onClose?.()},get open(){return isOpen()},set open($$value){isOpen($$value)},
|
|
|
|
|
children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$D(),node_1=first_child(fragment_1);component(node_1,()=>Popover_trigger,($$anchor4,Popover_Trigger)=>{Popover_Trigger($$anchor4,{class:"pointer-events-none absolute inset-0 opacity-0",tabindex:-1,"aria-hidden":"true",children:($$anchor5,$$slotProps2)=>{var span=root_2$U(),text2=child(span,!0);reset(span),template_effect(()=>set_text(text2,srLabel())),append($$anchor5,span)},$$slots:{default:!0}})});var node_2=sibling(node_1,2);component(node_2,
|
|
|
|
|
()=>Popover_content,($$anchor4,Popover_Content)=>{Popover_Content($$anchor4,{side:"top",align:"start",sideOffset:12,get class(){return`w-[var(--bits-popover-anchor-width)] max-w-none rounded-xl border-border/50 p-0 shadow-xl ${className()??""}`},get onkeydown(){return $$props.onKeydown},onOpenAutoFocus:event2=>event2.preventDefault(),children:($$anchor5,$$slotProps2)=>{var fragment_2=comment$2(),node_3=first_child(fragment_2);snippet(node_3,()=>$$props.children),append($$anchor5,fragment_2)},$$slots:{
|
|
|
|
|
default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment),pop()}var root_2$T=from_html('<div class="absolute top-0 right-0 left-0 z-10 p-2 pb-0"><!></div>'),root_5$q=from_html('<div class="py-6 text-center text-sm text-muted-foreground"> </div>'),root_1$C=from_html("<!> <div><!></div> <!>",1);function ChatFormPickerList($$anchor,$$props){push$1($$props,!0);let searchQuery=prop($$props,"searchQuery",15),searchPlaceholder=prop($$props,"searchPlaceholder",3,"S\
|
|
|
|
|
earch..."),emptyMessage=prop($$props,"emptyMessage",3,"No items available"),listContainer=state$1(null);user_effect(()=>{if(get$3(listContainer)&&$$props.selectedIndex>=0&&$$props.selectedIndex<$$props.items.length){const selectedElement=get$3(listContainer).querySelector(`[data-picker-index="${$$props.selectedIndex}"]`);selectedElement&&selectedElement.scrollIntoView({behavior:"smooth",block:"center",inline:"nearest"})}}),Scroll_area($$anchor,{children:($$anchor2,$$slotProps)=>{var fragment_1=root_1$C(),
|
|
|
|
|
node2=first_child(fragment_1);{var consequent=$$anchor3=>{var div=root_2$T(),node_1=child(div);SearchInput(node_1,{get placeholder(){return searchPlaceholder()},get value(){return searchQuery()},set value($$value){searchQuery($$value)}}),reset(div),append($$anchor3,div)};if_block(node2,$$render=>{$$props.showSearchInput&&$$render(consequent)})}var div_1=sibling(node2,2),node_2=child(div_1);{var consequent_2=$$anchor3=>{var fragment_2=comment$2(),node_3=first_child(fragment_2);{var consequent_1=$$anchor4=>{
|
|
|
|
|
var fragment_3=comment$2(),node_4=first_child(fragment_3);snippet(node_4,()=>$$props.skeleton),append($$anchor4,fragment_3)};if_block(node_3,$$render=>{$$props.skeleton&&$$render(consequent_1)})}append($$anchor3,fragment_2)},consequent_3=$$anchor3=>{var div_2=root_5$q(),text2=child(div_2,!0);reset(div_2),template_effect(()=>set_text(text2,emptyMessage())),append($$anchor3,div_2)},alternate=$$anchor3=>{var fragment_4=comment$2(),node_5=first_child(fragment_4);each(node_5,19,()=>$$props.items,(itemData,index2)=>$$props.
|
|
|
|
|
itemKey(itemData,index2),($$anchor4,itemData,index2)=>{var fragment_5=comment$2(),node_6=first_child(fragment_5);snippet(node_6,()=>$$props.item,()=>get$3(itemData),()=>get$3(index2),()=>get$3(index2)===$$props.selectedIndex),append($$anchor4,fragment_5)}),append($$anchor3,fragment_4)};if_block(node_2,$$render=>{$$props.isLoading?$$render(consequent_2):$$props.items.length===0?$$render(consequent_3,1):$$render(alternate,-1)})}reset(div_1),bind_this(div_1,$$value=>set$1(listContainer,$$value),()=>get$3(
|
|
|
|
|
listContainer));var node_7=sibling(div_1,2);{var consequent_4=$$anchor3=>{var fragment_6=comment$2(),node_8=first_child(fragment_6);snippet(node_8,()=>$$props.footer),append($$anchor3,fragment_6)};if_block(node_7,$$render=>{$$props.footer&&$$render(consequent_4)})}template_effect(()=>set_class(div_1,1,clsx([`${CHAT_FORM_POPOVER_MAX_HEIGHT} p-2`,$$props.showSearchInput&&"pt-13"]))),append($$anchor2,fragment_1)},$$slots:{default:!0}}),pop()}var root$1i=from_html('<button type="button"><!></button>');
|
|
|
|
|
function ChatFormPickerListItem($$anchor,$$props){let isSelected=prop($$props,"isSelected",3,!1);var button=root$1i(),node2=child(button);snippet(node2,()=>$$props.children),reset(button),template_effect(()=>{set_attribute(button,"data-picker-index",$$props.dataIndex),set_class(button,1,`flex w-full cursor-pointer items-start gap-3 rounded-lg px-3 py-2 text-left hover:bg-accent/50 ${isSelected()?"bg-accent/50":""}`)}),delegated("click",button,function(...$$args){$$props.onclick?.apply(this,$$args)}),
|
|
|
|
|
append($$anchor,button)}delegate(["click"]);var root_1$B=from_html('<img alt="" class="h-3 w-3 shrink-0 rounded-sm"/>'),root_3$K=from_html('<p class="mt-0.5 truncate text-sm text-muted-foreground"> </p>'),root$1h=from_html('<div class="min-w-0 flex-1"><div class="mb-0.5 flex items-center gap-1.5 text-xs text-muted-foreground"><!> <span> </span></div> <div class="flex items-center gap-2"><span class="font-medium"> </span> <!></div> <!> <!></div>');function ChatFormPickerItemHeader($$anchor,$$props){
|
|
|
|
|
text-popover-foreground shadow-md outline-hidden data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-end-2 data-[side=right]:slide-in-from-start-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",$$props.class));component(node2,()=>Popover_content$1,($$anchor3,PopoverPrimitive_Content)=>{
|
|
|
|
|
PopoverPrimitive_Content($$anchor3,spread_props({"data-slot":"popover-content",get sideOffset(){return sideOffset()},get side(){return $$props.side},get align(){return align()},get collisionPadding(){return collisionPadding()},get avoidCollisions(){return avoidCollisions()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor2,fragment_1)},$$slots:{default:!0}})),pop()}function Popover_trigger($$anchor,$$props){push$1($$props,
|
|
|
|
|
!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("",$$props.class));component(node2,()=>Popover_trigger$1,($$anchor2,PopoverPrimitive_Trigger)=>{PopoverPrimitive_Trigger($$anchor2,spread_props({"data-slot":"popover-trigger",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,
|
|
|
|
|
fragment),pop()}var root_2$U=from_html('<span class="sr-only"> </span>'),root_1$D=from_html("<!> <!>",1);function ChatFormPickerPopover($$anchor,$$props){push$1($$props,!0);let className=prop($$props,"class",3,""),isOpen=prop($$props,"isOpen",15,!1),srLabel=prop($$props,"srLabel",3,"Open picker");var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Popover,($$anchor2,Popover_Root)=>{Popover_Root($$anchor2,{onOpenChange:open2=>{open2||$$props.onClose?.()},get open(){return isOpen()},
|
|
|
|
|
set open($$value){isOpen($$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$D(),node_1=first_child(fragment_1);component(node_1,()=>Popover_trigger,($$anchor4,Popover_Trigger)=>{Popover_Trigger($$anchor4,{class:"pointer-events-none absolute inset-0 opacity-0",tabindex:-1,"aria-hidden":"true",children:($$anchor5,$$slotProps2)=>{var span=root_2$U(),text2=child(span,!0);reset(span),template_effect(()=>set_text(text2,srLabel())),append($$anchor5,span)},$$slots:{default:!0}})});var node_2=sibling(
|
|
|
|
|
node_1,2);component(node_2,()=>Popover_content,($$anchor4,Popover_Content)=>{Popover_Content($$anchor4,{side:"top",align:"start",sideOffset:12,get class(){return`w-[var(--bits-popover-anchor-width)] max-w-none rounded-xl border-border/50 p-0 shadow-xl ${className()??""}`},get onkeydown(){return $$props.onKeydown},onOpenAutoFocus:event2=>event2.preventDefault(),children:($$anchor5,$$slotProps2)=>{var fragment_2=comment$2(),node_3=first_child(fragment_2);snippet(node_3,()=>$$props.children),append(
|
|
|
|
|
$$anchor5,fragment_2)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment),pop()}var root_2$T=from_html('<div class="absolute top-0 right-0 left-0 z-10 p-2 pb-0"><!></div>'),root_5$q=from_html('<div class="py-6 text-center text-sm text-muted-foreground"> </div>'),root_1$C=from_html("<!> <div><!></div> <!>",1);function ChatFormPickerList($$anchor,$$props){push$1($$props,!0);let searchQuery=prop($$props,"searchQuery",15),searchPlaceholder=prop(
|
|
|
|
|
$$props,"searchPlaceholder",3,"Search..."),emptyMessage=prop($$props,"emptyMessage",3,"No items available"),listContainer=state$1(null);user_effect(()=>{if(get$3(listContainer)&&$$props.selectedIndex>=0&&$$props.selectedIndex<$$props.items.length){const selectedElement=get$3(listContainer).querySelector(`[data-picker-index="${$$props.selectedIndex}"]`);selectedElement&&selectedElement.scrollIntoView({behavior:"smooth",block:"center",inline:"nearest"})}}),Scroll_area($$anchor,{children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
var fragment_1=root_1$C(),node2=first_child(fragment_1);{var consequent=$$anchor3=>{var div=root_2$T(),node_1=child(div);SearchInput(node_1,{get placeholder(){return searchPlaceholder()},get value(){return searchQuery()},set value($$value){searchQuery($$value)}}),reset(div),append($$anchor3,div)};if_block(node2,$$render=>{$$props.showSearchInput&&$$render(consequent)})}var div_1=sibling(node2,2),node_2=child(div_1);{var consequent_2=$$anchor3=>{var fragment_2=comment$2(),node_3=first_child(fragment_2);
|
|
|
|
|
{var consequent_1=$$anchor4=>{var fragment_3=comment$2(),node_4=first_child(fragment_3);snippet(node_4,()=>$$props.skeleton),append($$anchor4,fragment_3)};if_block(node_3,$$render=>{$$props.skeleton&&$$render(consequent_1)})}append($$anchor3,fragment_2)},consequent_3=$$anchor3=>{var div_2=root_5$q(),text2=child(div_2,!0);reset(div_2),template_effect(()=>set_text(text2,emptyMessage())),append($$anchor3,div_2)},alternate=$$anchor3=>{var fragment_4=comment$2(),node_5=first_child(fragment_4);each(node_5,
|
|
|
|
|
19,()=>$$props.items,(itemData,index2)=>$$props.itemKey(itemData,index2),($$anchor4,itemData,index2)=>{var fragment_5=comment$2(),node_6=first_child(fragment_5);snippet(node_6,()=>$$props.item,()=>get$3(itemData),()=>get$3(index2),()=>get$3(index2)===$$props.selectedIndex),append($$anchor4,fragment_5)}),append($$anchor3,fragment_4)};if_block(node_2,$$render=>{$$props.isLoading?$$render(consequent_2):$$props.items.length===0?$$render(consequent_3,1):$$render(alternate,-1)})}reset(div_1),bind_this(
|
|
|
|
|
div_1,$$value=>set$1(listContainer,$$value),()=>get$3(listContainer));var node_7=sibling(div_1,2);{var consequent_4=$$anchor3=>{var fragment_6=comment$2(),node_8=first_child(fragment_6);snippet(node_8,()=>$$props.footer),append($$anchor3,fragment_6)};if_block(node_7,$$render=>{$$props.footer&&$$render(consequent_4)})}template_effect(()=>set_class(div_1,1,clsx([`${CHAT_FORM_POPOVER_MAX_HEIGHT} p-2`,$$props.showSearchInput&&"pt-13"]))),append($$anchor2,fragment_1)},$$slots:{default:!0}}),pop()}var root$1i=from_html(
|
|
|
|
|
'<button type="button"><!></button>');function ChatFormPickerListItem($$anchor,$$props){let isSelected=prop($$props,"isSelected",3,!1);var button=root$1i(),node2=child(button);snippet(node2,()=>$$props.children),reset(button),template_effect(()=>{set_attribute(button,"data-picker-index",$$props.dataIndex),set_class(button,1,`flex w-full cursor-pointer items-start gap-3 rounded-lg px-3 py-2 text-left hover:bg-accent/50 ${isSelected()?"bg-accent/50":""}`)}),delegated("click",button,function(...$$args){
|
|
|
|
|
$$props.onclick?.apply(this,$$args)}),append($$anchor,button)}delegate(["click"]);var root_1$B=from_html('<img alt="" class="h-3 w-3 shrink-0 rounded-sm"/>'),root_3$K=from_html('<p class="mt-0.5 truncate text-sm text-muted-foreground"> </p>'),root$1h=from_html('<div class="min-w-0 flex-1"><div class="mb-0.5 flex items-center gap-1.5 text-xs text-muted-foreground"><!> <span> </span></div> <div class="flex items-center gap-2"><span class="font-medium"> </span> <!></div> <!> <!></div>');function ChatFormPickerItemHeader($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let faviconUrl=user_derived(()=>$$props.server?mcpStore.getServerFavicon($$props.server.id):null);var div=root$1h(),div_1=child(div),node2=child(div_1);{var consequent=$$anchor2=>{var img=root_1$B();template_effect(()=>set_attribute(img,"src",get$3(faviconUrl))),event("error",img,e=>{e.currentTarget.style.display="none"}),replay_events(img),append($$anchor2,img)};if_block(node2,$$render=>{get$3(faviconUrl)&&$$render(consequent)})}var span=sibling(node2,2),text2=child(span,!0);
|
|
|
|
|
reset(span),reset(div_1);var div_2=sibling(div_1,2),span_1=child(div_2),text_1=child(span_1,!0);reset(span_1);var node_1=sibling(span_1,2);{var consequent_1=$$anchor2=>{var fragment=comment$2(),node_2=first_child(fragment);snippet(node_2,()=>$$props.titleExtra),append($$anchor2,fragment)};if_block(node_1,$$render=>{$$props.titleExtra&&$$render(consequent_1)})}reset(div_2);var node_3=sibling(div_2,2);{var consequent_2=$$anchor2=>{var p2=root_3$K(),text_2=child(p2,!0);reset(p2),template_effect(()=>set_text(
|
|
|
|
|
text_2,$$props.description)),append($$anchor2,p2)};if_block(node_3,$$render=>{$$props.description&&$$render(consequent_2)})}var node_4=sibling(node_3,2);{var consequent_3=$$anchor2=>{var fragment_1=comment$2(),node_5=first_child(fragment_1);snippet(node_5,()=>$$props.subtitle),append($$anchor2,fragment_1)};if_block(node_4,$$render=>{$$props.subtitle&&$$render(consequent_3)})}reset(div),template_effect(()=>{set_text(text2,$$props.serverLabel),set_text(text_1,$$props.title)}),append($$anchor,div),
|
|
|
|
|
@@ -10492,86 +10493,86 @@ Collapsible_Content($$anchor5,{children:($$anchor6,$$slotProps3)=>{var div_2=roo
|
|
|
|
|
$$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-lg leading-none font-semibold",$$props.class));component(node2,()=>Dialog_title$1,($$anchor2,DialogPrimitive_Title)=>{DialogPrimitive_Title($$anchor2,spread_props({"data-slot":"dialog-title",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,
|
|
|
|
|
fragment),pop()}var root$P=from_html("<div><!></div>");function Dialog_footer($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$P();attribute_effect(div,$0=>({"data-slot":"dialog-footer",class:$0,...restProps}),[()=>cn$1("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(
|
|
|
|
|
div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root$O=from_html("<div><!></div>");function Dialog_header($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$O();attribute_effect(div,$0=>({"data-slot":"dialog-header",class:$0,...restProps}),[()=>cn$1("flex flex-col gap-2 text-center sm:text-left",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.
|
|
|
|
|
children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}function Dialog_overlay($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=\
|
|
|
|
|
open]:fade-in-0",$$props.class));component(node2,()=>Dialog_overlay$1,($$anchor2,DialogPrimitive_Overlay)=>{DialogPrimitive_Overlay($$anchor2,spread_props({"data-slot":"dialog-overlay",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_4$n=from_html('<!> <span class="sr-only">Close</span>',1),root_2$G=from_html("<!> <!>",1),root_1$q=from_html("<!> <!>",1);function Dialog_content($$anchor,$$props){push$1(
|
|
|
|
|
$$props,!0);let ref2=prop($$props,"ref",15,null),showCloseButton=prop($$props,"showCloseButton",3,!0),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","portalProps","children","showCloseButton"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$1,($$anchor2,Dialog_Portal)=>{Dialog_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$q(),node_1=first_child(fragment_1);component(node_1,
|
|
|
|
|
()=>Dialog_overlay,($$anchor4,Dialog_Overlay)=>{Dialog_Overlay($$anchor4,{})});var node_2=sibling(node_1,2);{let $0=user_derived(()=>cn$1("fixed top-[50%] left-[50%] z-50 grid max-h-[100dvh] w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 overflow-y-auto rounded-lg border border-border/30 bg-background p-6 shadow-lg duration-200 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:\
|
|
|
|
|
fade-in-0 data-[state=open]:zoom-in-95 sm:max-w-lg md:max-h-[100vh]",$$props.class));component(node_2,()=>Dialog_content$1,($$anchor4,DialogPrimitive_Content)=>{DialogPrimitive_Content($$anchor4,spread_props({"data-slot":"dialog-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$G(),node_3=first_child(fragment_2);snippet(node_3,()=>$$props.children??noop$3);var node_4=sibling(node_3,
|
|
|
|
|
2);{var consequent=$$anchor6=>{var fragment_3=comment$2(),node_5=first_child(fragment_3);component(node_5,()=>Dialog_close,($$anchor7,DialogPrimitive_Close)=>{DialogPrimitive_Close($$anchor7,{class:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",children:($$anchor8,$$slotProps3)=>{
|
|
|
|
|
var fragment_4=root_4$n(),node_6=first_child(fragment_4);X(node_6,{}),next$1(2),append($$anchor8,fragment_4)},$$slots:{default:!0}})}),append($$anchor6,fragment_3)};if_block(node_4,$$render=>{showCloseButton()&&$$render(consequent)})}append($$anchor5,fragment_2)},$$slots:{default:!0}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}function Dialog_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-sm text-muted-foreground",$$props.class));component(node2,()=>Dialog_description$1,($$anchor2,DialogPrimitive_Description)=>{DialogPrimitive_Description($$anchor2,spread_props({"data-slot":"dialog-description",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const Root$2=Dialog,
|
|
|
|
|
Portal$1=Portal$2;var root_1$p=from_html("<!> Add New Server",1),root_2$F=from_html('<div class="rounded-md border border-dashed p-4 text-sm text-muted-foreground">No MCP Servers configured yet. Add one to enable agentic features.</div>'),root_3$z=from_html('<div class="grid gap-3" style="grid-template-columns: repeat(auto-fill, minmax(min(32rem, calc(100dvw - 2rem)), 1fr));"></div>'),root$N=from_html('<div class="h-full max-h-[100dvh] overflow-y-auto"><div class="flex items-center gap-2 p-4 md:\
|
|
|
|
|
absolute md:top-8 md:left-8 md:px-0 md:py-2"><!> <h1 class="text-xl font-semibold md:text-2xl">MCP Servers</h1></div> <div class="sticky top-0 z-10 mt-4 flex items-start gap-4 p-4 md:justify-end md:px-8"><!></div> <!> <div><!> <!></div></div>');function SettingsMcpServers($$anchor,$$props){push$1($$props,!0);let servers=user_derived(()=>mcpStore.getServersSorted()),initialLoadComplete=state$1(!1),isAddingServer=state$1(!1);onMount$1(()=>{if(page$1.url.searchParams.has("add")){set$1(isAddingServer,
|
|
|
|
|
!0);const newUrl=new URL(page$1.url);newUrl.searchParams.delete("add"),replaceState(newUrl,{})}}),user_effect(()=>{if(get$3(initialLoadComplete))return;get$3(servers).length>0&&get$3(servers).every(server=>{const state2=mcpStore.getHealthCheckState(server.id);return state2.status===HealthCheckStatus.SUCCESS||state2.status===HealthCheckStatus.ERROR})&&set$1(initialLoadComplete,!0)});var div=root$N(),div_1=child(div),node2=child(div_1);McpLogo(node2,{class:"h-5 w-5 md:h-6 md:w-6"}),next$1(2),reset(
|
|
|
|
|
div_1);var div_2=sibling(div_1,2),node_1=child(div_2);Button(node_1,{variant:"outline",size:"sm",class:"shrink-0",onclick:()=>set$1(isAddingServer,!0),children:($$anchor2,$$slotProps)=>{var fragment=root_1$p(),node_2=first_child(fragment);Plus(node_2,{class:"h-4 w-4"}),next$1(),append($$anchor2,fragment)},$$slots:{default:!0}}),reset(div_2);var node_3=sibling(div_2,2);DialogMcpServerAddNew(node_3,{get open(){return get$3(isAddingServer)},set open($$value){set$1(isAddingServer,$$value,!0)}});var div_3=sibling(
|
|
|
|
|
node_3,2),node_4=child(div_3);{var consequent=$$anchor2=>{var div_4=root_2$F();append($$anchor2,div_4)};if_block(node_4,$$render=>{get$3(servers).length===0&&!get$3(isAddingServer)&&$$render(consequent)})}var node_5=sibling(node_4,2);{var consequent_2=$$anchor2=>{var div_5=root_3$z();each(div_5,21,()=>get$3(servers),server=>server.id,($$anchor3,server)=>{var fragment_1=comment$2(),node_6=first_child(fragment_1);{var consequent_1=$$anchor4=>{McpServerCardSkeleton($$anchor4)},alternate=$$anchor4=>{
|
|
|
|
|
{let $0=user_derived(()=>conversationsStore.isMcpServerEnabledForChat(get$3(server).id));McpServerCard($$anchor4,{get server(){return get$3(server)},get enabled(){return get$3($0)},onToggle:async()=>{const wasEnabled=conversationsStore.isMcpServerEnabledForChat(get$3(server).id);await conversationsStore.toggleMcpServerForChat(get$3(server).id),wasEnabled||toolsStore.enableAllToolsForServer(get$3(server).id)},onUpdate:updates=>mcpStore.updateServer(get$3(server).id,updates),onDelete:()=>mcpStore.
|
|
|
|
|
removeServer(get$3(server).id)})}};if_block(node_6,$$render=>{get$3(initialLoadComplete)?$$render(alternate,-1):$$render(consequent_1)})}append($$anchor3,fragment_1)}),reset(div_5),append($$anchor2,div_5)};if_block(node_5,$$render=>{get$3(servers).length>0&&$$render(consequent_2)})}reset(div_3),reset(div),template_effect(()=>set_class(div_3,1,`grid gap-5 md:space-y-4 ${$$props.class??""}`)),transition(1,div,()=>fade,()=>({duration:150})),append($$anchor,div),pop()}delegate(["click"]);var root_3$y=from_html(
|
|
|
|
|
"<!> Tools",1),root_5$h=from_html("<!> Resources",1),root_7$g=from_html("<!> Prompts",1),root_9$c=from_html("<!> Logging",1),root_11$7=from_html("<!> Completions",1),root_13$5=from_html("<!> Tasks",1),root_1$o=from_html("<!> <!> <!> <!> <!> <!>",1);function McpCapabilitiesBadges($$anchor,$$props){push$1($$props,!0);var fragment=comment$2(),node2=first_child(fragment);{var consequent_6=$$anchor2=>{var fragment_1=root_1$o(),node_1=first_child(fragment_1);{var consequent=$$anchor3=>{Badge($$anchor3,
|
|
|
|
|
{variant:"outline",class:"h-5 gap-1 bg-green-50 px-1.5 text-[10px] dark:bg-green-950",children:($$anchor4,$$slotProps)=>{var fragment_3=root_3$y(),node_2=first_child(fragment_3);Wrench(node_2,{class:"h-3 w-3 text-green-600 dark:text-green-400"}),next$1(),append($$anchor4,fragment_3)},$$slots:{default:!0}})};if_block(node_1,$$render=>{$$props.capabilities.server.tools&&$$render(consequent)})}var node_3=sibling(node_1,2);{var consequent_1=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 g\
|
|
|
|
|
ap-1 bg-blue-50 px-1.5 text-[10px] dark:bg-blue-950",children:($$anchor4,$$slotProps)=>{var fragment_5=root_5$h(),node_4=first_child(fragment_5);Database(node_4,{class:"h-3 w-3 text-blue-600 dark:text-blue-400"}),next$1(),append($$anchor4,fragment_5)},$$slots:{default:!0}})};if_block(node_3,$$render=>{$$props.capabilities.server.resources&&$$render(consequent_1)})}var node_5=sibling(node_3,2);{var consequent_2=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-purple-50 px-1.5 te\
|
|
|
|
|
xt-[10px] dark:bg-purple-950",children:($$anchor4,$$slotProps)=>{var fragment_7=root_7$g(),node_6=first_child(fragment_7);Message_square(node_6,{class:"h-3 w-3 text-purple-600 dark:text-purple-400"}),next$1(),append($$anchor4,fragment_7)},$$slots:{default:!0}})};if_block(node_5,$$render=>{$$props.capabilities.server.prompts&&$$render(consequent_2)})}var node_7=sibling(node_5,2);{var consequent_3=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-orange-50 px-1.5 text-[10px] dark:\
|
|
|
|
|
bg-orange-950",children:($$anchor4,$$slotProps)=>{var fragment_9=root_9$c(),node_8=first_child(fragment_9);File_text(node_8,{class:"h-3 w-3 text-orange-600 dark:text-orange-400"}),next$1(),append($$anchor4,fragment_9)},$$slots:{default:!0}})};if_block(node_7,$$render=>{$$props.capabilities.server.logging&&$$render(consequent_3)})}var node_9=sibling(node_7,2);{var consequent_4=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-cyan-50 px-1.5 text-[10px] dark:bg-cyan-950",children:($$anchor4,$$slotProps)=>{
|
|
|
|
|
var fragment_11=root_11$7(),node_10=first_child(fragment_11);Sparkles(node_10,{class:"h-3 w-3 text-cyan-600 dark:text-cyan-400"}),next$1(),append($$anchor4,fragment_11)},$$slots:{default:!0}})};if_block(node_9,$$render=>{$$props.capabilities.server.completions&&$$render(consequent_4)})}var node_11=sibling(node_9,2);{var consequent_5=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-pink-50 px-1.5 text-[10px] dark:bg-pink-950",children:($$anchor4,$$slotProps)=>{var fragment_13=root_13$5(),
|
|
|
|
|
node_12=first_child(fragment_13);List_checks(node_12,{class:"h-3 w-3 text-pink-600 dark:text-pink-400"}),next$1(),append($$anchor4,fragment_13)},$$slots:{default:!0}})};if_block(node_11,$$render=>{$$props.capabilities.server.tasks&&$$render(consequent_5)})}append($$anchor2,fragment_1)};if_block(node2,$$render=>{$$props.capabilities&&$$render(consequent_6)})}append($$anchor,fragment),pop()}var root_6$j=from_html('<span class="ml-1"> </span>'),root_3$x=from_html("<!> <span> </span> <!>",1),root_9$b=from_html(
|
|
|
|
|
'<details class="ml-11"><summary class="cursor-pointer text-[10px] text-muted-foreground">details</summary> <pre class="mt-1 overflow-x-auto rounded bg-background/70 p-2 text-[10px] break-all whitespace-pre-wrap text-foreground/80"> </pre></details>'),root_8$h=from_html('<div><span class="shrink-0 text-muted-foreground"> </span> <!> <span class="break-all"> </span></div> <!>',1),root_7$f=from_html('<div class="max-h-64 space-y-0.5 overflow-y-auto rounded bg-muted/50 p-2 font-mono text-[10px]"></\
|
|
|
|
|
div>'),root_2$E=from_html('<div class="space-y-2"><!></div> <!>',1);function McpConnectionLogs($$anchor,$$props){push$1($$props,!0);let defaultExpanded=prop($$props,"defaultExpanded",3,!1),isExpanded=user_derived(defaultExpanded);function formatLogDetails(details){if(details==null)return"";try{return JSON.stringify(details,null,2)}catch{return String(details)}}var fragment=comment$2(),node2=first_child(fragment);{var consequent_3=$$anchor2=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);
|
|
|
|
|
component(node_1,()=>Collapsible,($$anchor3,Collapsible_Root)=>{Collapsible_Root($$anchor3,{get class(){return $$props.class},get open(){return get$3(isExpanded)},set open($$value){set$1(isExpanded,$$value)},children:($$anchor4,$$slotProps)=>{var fragment_2=root_2$E(),div=first_child(fragment_2),node_2=child(div);component(node_2,()=>Collapsible_trigger,($$anchor5,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor5,{class:"flex w-full items-center gap-1 text-xs text-muted-foreground hover:text-\
|
|
|
|
|
foreground",children:($$anchor6,$$slotProps2)=>{var fragment_3=root_3$x(),node_3=first_child(fragment_3);{var consequent=$$anchor7=>{Chevron_down($$anchor7,{class:"h-3.5 w-3.5"})},alternate=$$anchor7=>{Chevron_right($$anchor7,{class:"h-3.5 w-3.5"})};if_block(node_3,$$render=>{get$3(isExpanded)?$$render(consequent):$$render(alternate,-1)})}var span=sibling(node_3,2),text2=child(span);reset(span);var node_4=sibling(span,2);{var consequent_1=$$anchor7=>{var span_1=root_6$j(),text_1=child(span_1);reset(
|
|
|
|
|
span_1),template_effect(()=>set_text(text_1,`· Connected in ${$$props.connectionTimeMs??""}ms`)),append($$anchor7,span_1)};if_block(node_4,$$render=>{$$props.connectionTimeMs!==void 0&&$$render(consequent_1)})}template_effect(()=>set_text(text2,`Connection Log (${$$props.logs.length??""})`)),append($$anchor6,fragment_3)},$$slots:{default:!0}})}),reset(div);var node_5=sibling(div,2);component(node_5,()=>Collapsible_content,($$anchor5,Collapsible_Content)=>{Collapsible_Content($$anchor5,{class:"m\
|
|
|
|
|
t-2",children:($$anchor6,$$slotProps2)=>{var div_1=root_7$f();each(div_1,21,()=>$$props.logs,log=>log.timestamp.getTime()+log.message,($$anchor7,log)=>{const IconComponent=user_derived(()=>getMcpLogLevelIcon(get$3(log).level));var fragment_6=root_8$h(),div_2=first_child(fragment_6),span_2=child(div_2),text_2=child(span_2,!0);reset(span_2);var node_6=sibling(span_2,2);component(node_6,()=>get$3(IconComponent),($$anchor8,IconComponent_1)=>{IconComponent_1($$anchor8,{class:"mt-0.5 h-3 w-3 shrink-0"})});
|
|
|
|
|
var span_3=sibling(node_6,2),text_3=child(span_3,!0);reset(span_3),reset(div_2);var node_7=sibling(div_2,2);{var consequent_2=$$anchor8=>{var details_1=root_9$b(),pre=sibling(child(details_1),2),text_4=child(pre,!0);reset(pre),reset(details_1),template_effect($0=>set_text(text_4,$0),[()=>formatLogDetails(get$3(log).details)]),append($$anchor8,details_1)};if_block(node_7,$$render=>{get$3(log).details!==void 0&&$$render(consequent_2)})}template_effect(($0,$1)=>{set_class(div_2,1,$0),set_text(text_2,
|
|
|
|
|
$1),set_text(text_3,get$3(log).message)},[()=>clsx(["flex items-start gap-1.5",getMcpLogLevelClass(get$3(log).level)]),()=>formatTime(get$3(log).timestamp)]),append($$anchor7,fragment_6)}),reset(div_1),append($$anchor6,div_1)},$$slots:{default:!0}})}),append($$anchor4,fragment_2)},$$slots:{default:!0}})}),append($$anchor2,fragment_1)};if_block(node2,$$render=>{$$props.logs.length>0&&$$render(consequent_3)})}append($$anchor,fragment),pop()}var root_1$n=from_html('<p class="mt-1.5 text-xs text-des\
|
|
|
|
|
tructive"> </p>'),root_3$w=from_html('<span class="inline-flex gap-0.75 text-xs text-muted-foreground/60">(Run <pre>llama-server</pre> with <pre>--webui-mcp-proxy</pre> flag)</span>'),root_2$D=from_html('<label><!> <span><span class="text-xs text-muted-foreground">Use llama-server proxy</span> <br/> <!></span></label>'),root$M=from_html('<div class="grid gap-3"><div><label class="mb-2 block text-xs font-medium">Server URL <span class="text-destructive">*</span></label> <!> <!> <!></div> <!></div\
|
|
|
|
|
>');function McpServerForm($$anchor,$$props){push$1($$props,!0);let useProxy=prop($$props,"useProxy",3,!1),urlError=prop($$props,"urlError",3,null),id2=prop($$props,"id",3,"server"),isWebSocket=user_derived(()=>$$props.url.toLowerCase().startsWith(UrlProtocol.WEBSOCKET)||$$props.url.toLowerCase().startsWith(UrlProtocol.WEBSOCKET_SECURE)),headerPairs=user_derived(()=>parseHeadersToArray($$props.headers));function updateHeaderPairs(newPairs){set$1(headerPairs,newPairs),$$props.onHeadersChange(serializeHeaders(
|
|
|
|
|
newPairs))}var div=root$M(),div_1=child(div),label=child(div_1),node2=sibling(label,2);{let $0=user_derived(()=>urlError()?"border-destructive":"");Input(node2,{get id(){return`server-url-${id2()??""}`},type:"url",get placeholder(){return MCP_SERVER_URL_PLACEHOLDER},get value(){return $$props.url},oninput:e=>$$props.onUrlChange(e.currentTarget.value),get class(){return get$3($0)}})}var node_1=sibling(node2,2);{var consequent=$$anchor2=>{var p2=root_1$n(),text2=child(p2,!0);reset(p2),template_effect(
|
|
|
|
|
()=>set_text(text2,urlError())),append($$anchor2,p2)};if_block(node_1,$$render=>{urlError()&&$$render(consequent)})}var node_2=sibling(node_1,2);{var consequent_2=$$anchor2=>{var label_1=root_2$D(),node_3=child(label_1);{let $0=user_derived(()=>!mcpStore.isProxyAvailable);Switch(node_3,{class:"mt-1",get id(){return`use-proxy-${id2()??""}`},get checked(){return useProxy()},get disabled(){return get$3($0)},onCheckedChange:checked=>$$props.onUseProxyChange?.(checked)})}var span=sibling(node_3,2),node_4=sibling(
|
|
|
|
|
child(span),4);{var consequent_1=$$anchor3=>{var span_1=root_3$w();append($$anchor3,span_1)};if_block(node_4,$$render=>{mcpStore.isProxyAvailable||$$render(consequent_1)})}reset(span),reset(label_1),template_effect(()=>set_class(label_1,1,clsx(["mt-3 flex items-start gap-2",mcpStore.isProxyAvailable&&"cursor-pointer",!mcpStore.isProxyAvailable&&"opacity-80"]))),append($$anchor2,label_1)};if_block(node_2,$$render=>{!get$3(isWebSocket)&&$$props.onUseProxyChange&&$$render(consequent_2)})}reset(div_1);
|
|
|
|
|
var node_5=sibling(div_1,2);KeyValuePairs(node_5,{class:"mt-2",get pairs(){return get$3(headerPairs)},onPairsChange:updateHeaderPairs,keyPlaceholder:"Header name",valuePlaceholder:"Value",addButtonLabel:"Add",emptyMessage:"No custom headers configured.",sectionLabel:"Custom Headers",sectionLabelOptional:!0}),reset(div),template_effect(()=>set_attribute(label,"for",`server-url-${id2()??""}`)),append($$anchor,div),pop()}var root$L=from_html("<div></div>");function Skeleton($$anchor,$$props){push$1(
|
|
|
|
|
$$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var div=root$L();attribute_effect(div,$0=>({"data-slot":"skeleton",class:$0,...restProps}),[()=>cn$1("animate-pulse rounded-md bg-accent",$$props.class)]),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root_4$m=from_html('<p class="text-xs text-destructive"> </p>'),root_5$g=from_html('<p class="line-clamp-2 text-xs text-muted-foreground">\
|
|
|
|
|
</p>'),root_6$i=from_html('<div class="space-y-2"><div class="flex items-center gap-2"><!> <!></div> <div class="flex flex-wrap gap-1.5"><!> <!> <!></div></div> <div class="space-y-1.5"><div class="flex items-center gap-2"><!> <!></div></div>',1),root_7$e=from_html("<!> <!> <!>",1),root_12$6=from_html('<div class="flex flex-wrap items-center gap-1"><span class="text-[10px] text-muted-foreground"> </span></div>'),root_3$v=from_html('<!> <!> <!> <div class="grid gap-3"><!></div> <div class="flex \
|
|
|
|
|
justify-between gap-4"><!> <!></div>',1),root$K=from_html("<!> <!>",1);function McpServerCard($$anchor,$$props){push$1($$props,!0);let healthState=user_derived(()=>mcpStore.getHealthCheckState($$props.server.id)),displayName=user_derived(()=>mcpStore.getServerLabel($$props.server)),faviconUrl=user_derived(()=>mcpStore.getServerFavicon($$props.server.id)),isIdle=user_derived(()=>get$3(healthState).status===HealthCheckStatus.IDLE),isHealthChecking=user_derived(()=>get$3(healthState).status===HealthCheckStatus.
|
|
|
|
|
CONNECTING),isConnected=user_derived(()=>get$3(healthState).status===HealthCheckStatus.SUCCESS),isError=user_derived(()=>get$3(healthState).status===HealthCheckStatus.ERROR),showSkeleton=user_derived(()=>get$3(isIdle)||get$3(isHealthChecking)),errorMessage=user_derived(()=>get$3(healthState).status===HealthCheckStatus.ERROR?get$3(healthState).message:void 0),tools=user_derived(()=>get$3(healthState).status===HealthCheckStatus.SUCCESS?get$3(healthState).tools:[]),connectionLogs=user_derived(()=>get$3(
|
|
|
|
|
healthState).status===HealthCheckStatus.CONNECTING||get$3(healthState).status===HealthCheckStatus.SUCCESS||get$3(healthState).status===HealthCheckStatus.ERROR?get$3(healthState).logs:[]),successState=user_derived(()=>get$3(healthState).status===HealthCheckStatus.SUCCESS?get$3(healthState):null),serverInfo=user_derived(()=>get$3(successState)?.serverInfo),capabilities=user_derived(()=>get$3(successState)?.capabilities),transportType=user_derived(()=>get$3(successState)?.transportType),protocolVersion=user_derived(
|
|
|
|
|
()=>get$3(successState)?.protocolVersion),connectionTimeMs=user_derived(()=>get$3(successState)?.connectionTimeMs),instructions=user_derived(()=>get$3(successState)?.instructions),isEditing2=user_derived(()=>!$$props.server.url.trim()),showDeleteDialog=state$1(!1),editFormRef=state$1(null);function handleHealthCheck(){mcpStore.runHealthCheck($$props.server)}async function startEditing(){set$1(isEditing2,!0),await tick(),get$3(editFormRef)?.setInitialValues($$props.server.url,$$props.server.headers||
|
|
|
|
|
"",$$props.server.useProxy||!1)}function cancelEditing(){$$props.server.url.trim()?set$1(isEditing2,!1):$$props.onDelete()}function saveEditing(url2,headers,useProxy){$$props.onUpdate({url:url2,headers:headers||void 0,useProxy}),set$1(isEditing2,!1),$$props.server.enabled&&url2&&setTimeout(()=>mcpStore.runHealthCheck({...$$props.server,url:url2,useProxy}),100)}function handleDeleteClick(){set$1(showDeleteDialog,!0)}var fragment=root$K(),node2=first_child(fragment);component(node2,()=>Card,($$anchor2,Card_Root)=>{
|
|
|
|
|
Card_Root($$anchor2,{class:"!gap-3 bg-muted/30 p-4",children:($$anchor3,$$slotProps)=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);{var consequent=$$anchor4=>{bind_this(McpServerCardEditForm($$anchor4,{get serverId(){return $$props.server.id},get serverUrl(){return $$props.server.url},get serverUseProxy(){return $$props.server.useProxy},onSave:saveEditing,onCancel:cancelEditing}),$$value=>set$1(editFormRef,$$value,!0),()=>get$3(editFormRef))},alternate_1=$$anchor4=>{var fragment_3=root_3$v(),
|
|
|
|
|
node_2=first_child(fragment_3);{let $0=user_derived(()=>$$props.enabled??$$props.server.enabled);McpServerCardHeader(node_2,{get displayName(){return get$3(displayName)},get faviconUrl(){return get$3(faviconUrl)},get enabled(){return get$3($0)},get disabled(){return get$3(isError)},get onToggle(){return $$props.onToggle},get serverInfo(){return get$3(serverInfo)},get capabilities(){return get$3(capabilities)},get transportType(){return get$3(transportType)}})}var node_3=sibling(node_2,2);{var consequent_1=$$anchor5=>{
|
|
|
|
|
var p2=root_4$m(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,get$3(errorMessage))),append($$anchor5,p2)};if_block(node_3,$$render=>{get$3(isError)&&get$3(errorMessage)&&$$render(consequent_1)})}var node_4=sibling(node_3,2);{var consequent_2=$$anchor5=>{var p_1=root_5$g(),text_1=child(p_1,!0);reset(p_1),template_effect(()=>set_text(text_1,get$3(serverInfo).description)),append($$anchor5,p_1)};if_block(node_4,$$render=>{get$3(isConnected)&&get$3(serverInfo)?.description&&$$render(
|
|
|
|
|
consequent_2)})}var div=sibling(node_4,2),node_5=child(div);{var consequent_3=$$anchor5=>{var fragment_4=root_6$i(),div_1=first_child(fragment_4),div_2=child(div_1),node_6=child(div_2);Skeleton(node_6,{class:"h-4 w-4 rounded"});var node_7=sibling(node_6,2);Skeleton(node_7,{class:"h-3 w-24"}),reset(div_2);var div_3=sibling(div_2,2),node_8=child(div_3);Skeleton(node_8,{class:"h-5 w-16 rounded-full"});var node_9=sibling(node_8,2);Skeleton(node_9,{class:"h-5 w-20 rounded-full"});var node_10=sibling(
|
|
|
|
|
node_9,2);Skeleton(node_10,{class:"h-5 w-14 rounded-full"}),reset(div_3),reset(div_1);var div_4=sibling(div_1,2),div_5=child(div_4),node_11=child(div_5);Skeleton(node_11,{class:"h-4 w-4 rounded"});var node_12=sibling(node_11,2);Skeleton(node_12,{class:"h-3 w-32"}),reset(div_5),reset(div_4),append($$anchor5,fragment_4)},alternate=$$anchor5=>{var fragment_5=root_7$e(),node_13=first_child(fragment_5);{var consequent_4=$$anchor6=>{McpServerInfo($$anchor6,{get instructions(){return get$3(instructions)}})};
|
|
|
|
|
if_block(node_13,$$render=>{get$3(isConnected)&&get$3(instructions)&&$$render(consequent_4)})}var node_14=sibling(node_13,2);{var consequent_5=$$anchor6=>{McpServerCardToolsList($$anchor6,{get tools(){return get$3(tools)}})};if_block(node_14,$$render=>{get$3(tools).length>0&&$$render(consequent_5)})}var node_15=sibling(node_14,2);{var consequent_6=$$anchor6=>{McpConnectionLogs($$anchor6,{get logs(){return get$3(connectionLogs)},get connectionTimeMs(){return get$3(connectionTimeMs)}})};if_block(node_15,
|
|
|
|
|
$$render=>{get$3(connectionLogs).length>0&&$$render(consequent_6)})}append($$anchor5,fragment_5)};if_block(node_5,$$render=>{get$3(showSkeleton)?$$render(consequent_3):$$render(alternate,-1)})}reset(div);var div_6=sibling(div,2),node_16=child(div_6);{var consequent_7=$$anchor5=>{Skeleton($$anchor5,{class:"h-3 w-28"})},consequent_8=$$anchor5=>{var div_7=root_12$6(),span=child(div_7),text_2=child(span);reset(span),reset(div_7),template_effect(()=>set_text(text_2,`Protocol version: ${get$3(protocolVersion)??
|
|
|
|
|
""}`)),append($$anchor5,div_7)};if_block(node_16,$$render=>{get$3(showSkeleton)?$$render(consequent_7):get$3(protocolVersion)&&$$render(consequent_8,1)})}var node_17=sibling(node_16,2);McpServerCardActions(node_17,{get isHealthChecking(){return get$3(isHealthChecking)},onEdit:startEditing,onRefresh:handleHealthCheck,onDelete:handleDeleteClick}),reset(div_6),append($$anchor4,fragment_3)};if_block(node_1,$$render=>{get$3(isEditing2)?$$render(consequent):$$render(alternate_1,-1)})}append($$anchor3,
|
|
|
|
|
fragment_1)},$$slots:{default:!0}})});var node_18=sibling(node2,2);McpServerCardDeleteDialog(node_18,{get displayName(){return get$3(displayName)},onOpenChange:open2=>set$1(showDeleteDialog,open2,!0),get onConfirm(){return $$props.onDelete},get open(){return get$3(showDeleteDialog)},set open($$value){set$1(showDeleteDialog,$$value,!0)}}),append($$anchor,fragment),pop()}var root_3$u=from_html("<!> ",1),root_1$m=from_html('<div class="flex flex-wrap items-center gap-1.5"><!> <!></div>'),root$J=from_html(
|
|
|
|
|
'<div class="space-y-3"><div class="flex items-start justify-between gap-3"><div class="flex min-w-0 flex-col gap-3"><div class="inline-flex items-center gap-2"><!></div> <!></div> <div class="flex shrink-0 items-center pl-2"><!></div></div></div>');function McpServerCardHeader($$anchor,$$props){push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1);var div=root$J(),div_1=child(div),div_2=child(div_1),div_3=child(div_2),node2=child(div_3);McpServerIdentity(node2,{get displayName(){return $$props.
|
|
|
|
|
displayName},get faviconUrl(){return $$props.faviconUrl},get serverInfo(){return $$props.serverInfo},iconClass:"h-5 w-5",iconRounded:"rounded",nameClass:"leading-6 font-medium"}),reset(div_3);var node_1=sibling(div_3,2);{var consequent_3=$$anchor2=>{var div_4=root_1$m(),node_2=child(div_4);{var consequent_1=$$anchor3=>{const TransportIcon=user_derived(()=>MCP_TRANSPORT_ICONS[$$props.transportType]);Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 px-1.5 text-[10px]",children:($$anchor4,$$slotProps)=>{
|
|
|
|
|
var fragment_1=root_3$u(),node_3=first_child(fragment_1);{var consequent=$$anchor5=>{var fragment_2=comment$2(),node_4=first_child(fragment_2);component(node_4,()=>get$3(TransportIcon),($$anchor6,TransportIcon_1)=>{TransportIcon_1($$anchor6,{class:"h-3 w-3"})}),append($$anchor5,fragment_2)};if_block(node_3,$$render=>{get$3(TransportIcon)&&$$render(consequent)})}var text2=sibling(node_3);template_effect(()=>set_text(text2,` ${(MCP_TRANSPORT_LABELS[$$props.transportType]||$$props.transportType)??""}`)),
|
|
|
|
|
append($$anchor4,fragment_1)},$$slots:{default:!0}})};if_block(node_2,$$render=>{$$props.transportType&&$$render(consequent_1)})}var node_5=sibling(node_2,2);{var consequent_2=$$anchor3=>{McpCapabilitiesBadges($$anchor3,{get capabilities(){return $$props.capabilities}})};if_block(node_5,$$render=>{$$props.capabilities&&$$render(consequent_2)})}reset(div_4),append($$anchor2,div_4)};if_block(node_1,$$render=>{($$props.capabilities||$$props.transportType)&&$$render(consequent_3)})}reset(div_2);var div_5=sibling(
|
|
|
|
|
div_2,2),node_6=child(div_5);Switch(node_6,{get checked(){return $$props.enabled},get disabled(){return disabled()},get onCheckedChange(){return $$props.onToggle}}),reset(div_5),reset(div_1),reset(div),append($$anchor,div),pop()}var root$I=from_html('<div class="flex shrink-0 items-center gap-1"><!> <!> <!></div>');function McpServerCardActions($$anchor,$$props){var div=root$I(),node2=child(div);Button(node2,{variant:"ghost",size:"icon",class:"h-7 w-7",get onclick(){return $$props.onEdit},"aria-\
|
|
|
|
|
label":"Edit",children:($$anchor2,$$slotProps)=>{Pencil($$anchor2,{class:"h-3.5 w-3.5"})},$$slots:{default:!0}});var node_1=sibling(node2,2);Button(node_1,{variant:"ghost",size:"icon",class:"h-7 w-7",get onclick(){return $$props.onRefresh},get disabled(){return $$props.isHealthChecking},"aria-label":"Refresh",children:($$anchor2,$$slotProps)=>{Refresh_cw($$anchor2,{class:"h-3.5 w-3.5"})},$$slots:{default:!0}});var node_2=sibling(node_1,2);Button(node_2,{variant:"ghost",size:"icon",class:"hover:t\
|
|
|
|
|
ext-destructive-foreground h-7 w-7 text-destructive hover:bg-destructive/10",get onclick(){return $$props.onDelete},"aria-label":"Delete",children:($$anchor2,$$slotProps)=>{Trash_2($$anchor2,{class:"h-3.5 w-3.5"})},$$slots:{default:!0}}),reset(div),append($$anchor,div)}var root_2$C=from_html("<!> <span> </span>",1),root_8$g=from_html('<p class="mt-1 text-xs text-muted-foreground"> </p>'),root_6$h=from_html("<div><!> <!></div>"),root_5$f=from_html('<div class="max-h-64 space-y-3 overflow-y-auto">\
|
|
|
|
|
</div>'),root_1$l=from_html("<!> <!>",1);function McpServerCardToolsList($$anchor,$$props){push$1($$props,!0);let isExpanded=state$1(!1),toolsCount=user_derived(()=>$$props.tools.length);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible,($$anchor2,Collapsible_Root)=>{Collapsible_Root($$anchor2,{get open(){return get$3(isExpanded)},set open($$value){set$1(isExpanded,$$value,!0)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$l(),node_1=first_child(fragment_1);
|
|
|
|
|
component(node_1,()=>Collapsible_trigger,($$anchor4,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor4,{class:"flex w-full items-center gap-1 text-xs text-muted-foreground hover:text-foreground",children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$C(),node_2=first_child(fragment_2);{var consequent=$$anchor6=>{Chevron_down($$anchor6,{class:"h-3.5 w-3.5"})},alternate=$$anchor6=>{Chevron_right($$anchor6,{class:"h-3.5 w-3.5"})};if_block(node_2,$$render=>{get$3(isExpanded)?$$render(consequent):
|
|
|
|
|
$$render(alternate,-1)})}var span=sibling(node_2,2),text2=child(span);reset(span),template_effect(()=>set_text(text2,`${get$3(toolsCount)??""} tools available · Show details`)),append($$anchor5,fragment_2)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Collapsible_content,($$anchor4,Collapsible_Content)=>{Collapsible_Content($$anchor4,{class:"mt-2",children:($$anchor5,$$slotProps2)=>{var div=root_5$f();each(div,21,()=>$$props.tools,tool=>tool.name,($$anchor6,tool)=>{
|
|
|
|
|
var div_1=root_6$h(),node_4=child(div_1);Badge(node_4,{variant:"secondary",children:($$anchor7,$$slotProps3)=>{next$1();var text_1=text$8();template_effect(()=>set_text(text_1,get$3(tool).name)),append($$anchor7,text_1)},$$slots:{default:!0}});var node_5=sibling(node_4,2);{var consequent_1=$$anchor7=>{var p2=root_8$g(),text_2=child(p2,!0);reset(p2),template_effect(()=>set_text(text_2,get$3(tool).description)),append($$anchor7,p2)};if_block(node_5,$$render=>{get$3(tool).description&&$$render(consequent_1)})}
|
|
|
|
|
reset(div_1),append($$anchor6,div_1)}),reset(div),append($$anchor5,div)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment),pop()}var root$H=from_html('<div class="space-y-4"><p class="font-medium">Configure Server</p> <!> <div class="flex items-center justify-end gap-2"><!> <!></div></div>');function McpServerCardEditForm($$anchor,$$props){push$1($$props,!0);let serverUseProxy=prop($$props,"serverUseProxy",3,!1),editUrl=user_derived(()=>$$props.
|
|
|
|
|
serverUrl),editHeaders=state$1(""),editUseProxy=user_derived(serverUseProxy),urlError=user_derived(()=>{if(!get$3(editUrl).trim())return"URL is required";try{return new URL(get$3(editUrl)),null}catch{return"Invalid URL format"}}),canSave=user_derived(()=>!get$3(urlError));function handleSave(){get$3(canSave)&&$$props.onSave(get$3(editUrl).trim(),get$3(editHeaders).trim(),get$3(editUseProxy))}function setInitialValues(url2,headers,useProxy){set$1(editUrl,url2),set$1(editHeaders,headers,!0),set$1(
|
|
|
|
|
editUseProxy,useProxy)}var $$exports={setInitialValues},div=root$H(),node2=sibling(child(div),2);{let $0=user_derived(()=>get$3(editUrl)?get$3(urlError):null);McpServerForm(node2,{get url(){return get$3(editUrl)},get headers(){return get$3(editHeaders)},get useProxy(){return get$3(editUseProxy)},onUrlChange:v=>set$1(editUrl,v),onHeadersChange:v=>set$1(editHeaders,v,!0),onUseProxyChange:v=>set$1(editUseProxy,v),get urlError(){return get$3($0)},get id(){return $$props.serverId}})}var div_1=sibling(
|
|
|
|
|
node2,2),node_1=child(div_1);Button(node_1,{variant:"secondary",size:"sm",get onclick(){return $$props.onCancel},children:($$anchor2,$$slotProps)=>{next$1();var text2=text$8("Cancel");append($$anchor2,text2)},$$slots:{default:!0}});var node_2=sibling(node_1,2);{let $0=user_derived(()=>!get$3(canSave));Button(node_2,{size:"sm",onclick:handleSave,get disabled(){return get$3($0)},children:($$anchor2,$$slotProps)=>{next$1();var text_1=text$8();template_effect($02=>set_text(text_1,$02),[()=>$$props.serverUrl.
|
|
|
|
|
trim()?"Update":"Add"]),append($$anchor2,text_1)},$$slots:{default:!0}})}return reset(div_1),reset(div),append($$anchor,div),pop($$exports)}function Alert_dialog_title($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-lg font-semibold",$$props.class));component(node2,()=>Dialog_title$1,($$anchor2,AlertDialogPrimitive_Title)=>{
|
|
|
|
|
AlertDialogPrimitive_Title($$anchor2,spread_props({"data-slot":"alert-dialog-title",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Alert_dialog_action($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1(buttonVariants(),
|
|
|
|
|
$$props.class));component(node2,()=>Alert_dialog_action$1,($$anchor2,AlertDialogPrimitive_Action)=>{AlertDialogPrimitive_Action($$anchor2,spread_props({"data-slot":"alert-dialog-action",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Alert_dialog_cancel($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","cl\
|
|
|
|
|
ass"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1(buttonVariants({variant:"outline"}),$$props.class));component(node2,()=>Alert_dialog_cancel$1,($$anchor2,AlertDialogPrimitive_Cancel)=>{AlertDialogPrimitive_Cancel($$anchor2,spread_props({"data-slot":"alert-dialog-cancel",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root$G=from_html("<div><!></div>");function Alert_dialog_footer($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$G();attribute_effect(div,$0=>({"data-slot":"alert-dialog-footer",class:$0,...restProps}),[()=>cn$1("mt-6 flex flex-row gap-2 sm:mt-0 sm:justify-end [&>*]:flex-1 sm:[&>*]:flex-none",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),
|
|
|
|
|
pop()}var root$F=from_html("<div><!></div>");function Alert_dialog_header($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$F();attribute_effect(div,$0=>({"data-slot":"alert-dialog-header",class:$0,...restProps}),[()=>cn$1("flex flex-col gap-2 text-center sm:text-left",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,
|
|
|
|
|
$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}function Alert_dialog_overlay($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0",$$props.class));component(
|
|
|
|
|
node2,()=>Dialog_overlay$1,($$anchor2,AlertDialogPrimitive_Overlay)=>{AlertDialogPrimitive_Overlay($$anchor2,spread_props({"data-slot":"alert-dialog-overlay",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_1$k=from_html("<!> <!>",1);function Alert_dialog_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy",
|
|
|
|
|
"ref","class","portalProps"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$2,($$anchor2,AlertDialogPrimitive_Portal)=>{AlertDialogPrimitive_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$k(),node_1=first_child(fragment_1);Alert_dialog_overlay(node_1,{});var node_2=sibling(node_1,2);{let $0=user_derived(()=>cn$1("fixed z-[999999] grid w-full gap-4 border bg-background p-6 shadow-lg duration-200","r\
|
|
|
|
|
ight-0 bottom-0 left-0 max-h-[100dvh] translate-x-0 translate-y-0 overflow-y-auto rounded-t-lg","data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:slide-out-to-bottom-full","data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:slide-in-from-bottom-full","sm:top-[50%] sm:right-auto sm:bottom-auto sm:left-[50%] sm:max-h-[100vh] sm:max-w-lg sm:translate-x-[-50%] sm:translate-y-[-50%] sm:rounded-lg","sm:data-[state=closed]:slide-out-to-bottom-0 \
|
|
|
|
|
sm:data-[state=closed]:zoom-out-95","sm:data-[state=open]:slide-in-from-bottom-0 sm:data-[state=open]:zoom-in-95",$$props.class));component(node_2,()=>Alert_dialog_content$1,($$anchor4,AlertDialogPrimitive_Content)=>{AlertDialogPrimitive_Content($$anchor4,spread_props({"data-slot":"alert-dialog-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}
|
|
|
|
|
function Alert_dialog_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-sm text-muted-foreground",$$props.class));component(node2,()=>Dialog_description$1,($$anchor2,AlertDialogPrimitive_Description)=>{AlertDialogPrimitive_Description($$anchor2,spread_props({"data-slot":"alert-dialog-description",
|
|
|
|
|
get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const Root$1=Alert_dialog,Portal=Portal$2;var root_5$e=from_html(`Are you sure you want to delete <strong> </strong>? This action cannot be
|
|
|
|
|
children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}function Dialog_overlay($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards da\
|
|
|
|
|
ta-[state=open]:animate-in data-[state=open]:fade-in-0",$$props.class));component(node2,()=>Dialog_overlay$1,($$anchor2,DialogPrimitive_Overlay)=>{DialogPrimitive_Overlay($$anchor2,spread_props({"data-slot":"dialog-overlay",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_4$n=from_html('<!> <span class="sr-only">Close</span>',1),root_2$G=from_html("<!> <!>",1),root_1$q=from_html("<!> <!>",1);function Dialog_content($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let ref2=prop($$props,"ref",15,null),showCloseButton=prop($$props,"showCloseButton",3,!0),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","portalProps","children","showCloseButton"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$1,($$anchor2,Dialog_Portal)=>{Dialog_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$q(),node_1=first_child(fragment_1);component(
|
|
|
|
|
node_1,()=>Dialog_overlay,($$anchor4,Dialog_Overlay)=>{Dialog_Overlay($$anchor4,{})});var node_2=sibling(node_1,2);{let $0=user_derived(()=>cn$1("fixed top-[50%] left-[50%] z-50 grid max-h-[100dvh] w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 overflow-y-auto rounded-lg border border-border/30 bg-background p-6 shadow-lg duration-200 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=closed]:zoom-out-95 d\
|
|
|
|
|
ata-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 sm:max-w-lg md:max-h-[100vh]",$$props.class));component(node_2,()=>Dialog_content$1,($$anchor4,DialogPrimitive_Content)=>{DialogPrimitive_Content($$anchor4,spread_props({"data-slot":"dialog-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$G(),node_3=first_child(fragment_2);snippet(node_3,()=>$$props.
|
|
|
|
|
children??noop$3);var node_4=sibling(node_3,2);{var consequent=$$anchor6=>{var fragment_3=comment$2(),node_5=first_child(fragment_3);component(node_5,()=>Dialog_close,($$anchor7,DialogPrimitive_Close)=>{DialogPrimitive_Close($$anchor7,{class:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:n\
|
|
|
|
|
ot([class*='size-'])]:size-4",children:($$anchor8,$$slotProps3)=>{var fragment_4=root_4$n(),node_6=first_child(fragment_4);X(node_6,{}),next$1(2),append($$anchor8,fragment_4)},$$slots:{default:!0}})}),append($$anchor6,fragment_3)};if_block(node_4,$$render=>{showCloseButton()&&$$render(consequent)})}append($$anchor5,fragment_2)},$$slots:{default:!0}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}function Dialog_description($$anchor,$$props){push$1($$props,
|
|
|
|
|
!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-sm text-muted-foreground",$$props.class));component(node2,()=>Dialog_description$1,($$anchor2,DialogPrimitive_Description)=>{DialogPrimitive_Description($$anchor2,spread_props({"data-slot":"dialog-description",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){
|
|
|
|
|
ref2($$value)}}))})}append($$anchor,fragment),pop()}const Root$2=Dialog,Portal$1=Portal$2;var root_1$p=from_html("<!> Add New Server",1),root_2$F=from_html('<div class="rounded-md border border-dashed p-4 text-sm text-muted-foreground">No MCP Servers configured yet. Add one to enable agentic features.</div>'),root_3$z=from_html('<div class="grid gap-3" style="grid-template-columns: repeat(auto-fill, minmax(min(32rem, calc(100dvw - 2rem)), 1fr));"></div>'),root$N=from_html('<div class="h-full max\
|
|
|
|
|
-h-[100dvh] overflow-y-auto"><div class="flex items-center gap-2 p-4 md:absolute md:top-8 md:left-8 md:px-0 md:py-2"><!> <h1 class="text-xl font-semibold md:text-2xl">MCP Servers</h1></div> <div class="sticky top-0 z-10 mt-4 flex items-start gap-4 p-4 md:justify-end md:px-8"><!></div> <!> <div><!> <!></div></div>');function SettingsMcpServers($$anchor,$$props){push$1($$props,!0);let servers=user_derived(()=>mcpStore.getServersSorted()),initialLoadComplete=state$1(!1),isAddingServer=state$1(!1);onMount$1(
|
|
|
|
|
()=>{if(page$1.url.searchParams.has("add")){set$1(isAddingServer,!0);const newUrl=new URL(page$1.url);newUrl.searchParams.delete("add"),replaceState(newUrl,{})}}),user_effect(()=>{if(get$3(initialLoadComplete))return;get$3(servers).length>0&&get$3(servers).every(server=>{const state2=mcpStore.getHealthCheckState(server.id);return state2.status===HealthCheckStatus.SUCCESS||state2.status===HealthCheckStatus.ERROR})&&set$1(initialLoadComplete,!0)});var div=root$N(),div_1=child(div),node2=child(div_1);
|
|
|
|
|
McpLogo(node2,{class:"h-5 w-5 md:h-6 md:w-6"}),next$1(2),reset(div_1);var div_2=sibling(div_1,2),node_1=child(div_2);Button(node_1,{variant:"outline",size:"sm",class:"shrink-0",onclick:()=>set$1(isAddingServer,!0),children:($$anchor2,$$slotProps)=>{var fragment=root_1$p(),node_2=first_child(fragment);Plus(node_2,{class:"h-4 w-4"}),next$1(),append($$anchor2,fragment)},$$slots:{default:!0}}),reset(div_2);var node_3=sibling(div_2,2);DialogMcpServerAddNew(node_3,{get open(){return get$3(isAddingServer)},
|
|
|
|
|
set open($$value){set$1(isAddingServer,$$value,!0)}});var div_3=sibling(node_3,2),node_4=child(div_3);{var consequent=$$anchor2=>{var div_4=root_2$F();append($$anchor2,div_4)};if_block(node_4,$$render=>{get$3(servers).length===0&&!get$3(isAddingServer)&&$$render(consequent)})}var node_5=sibling(node_4,2);{var consequent_2=$$anchor2=>{var div_5=root_3$z();each(div_5,21,()=>get$3(servers),server=>server.id,($$anchor3,server)=>{var fragment_1=comment$2(),node_6=first_child(fragment_1);{var consequent_1=$$anchor4=>{
|
|
|
|
|
McpServerCardSkeleton($$anchor4)},alternate=$$anchor4=>{{let $0=user_derived(()=>conversationsStore.isMcpServerEnabledForChat(get$3(server).id));McpServerCard($$anchor4,{get server(){return get$3(server)},get enabled(){return get$3($0)},onToggle:async()=>{const wasEnabled=conversationsStore.isMcpServerEnabledForChat(get$3(server).id);await conversationsStore.toggleMcpServerForChat(get$3(server).id),wasEnabled||toolsStore.enableAllToolsForServer(get$3(server).id)},onUpdate:updates=>mcpStore.updateServer(
|
|
|
|
|
get$3(server).id,updates),onDelete:()=>mcpStore.removeServer(get$3(server).id)})}};if_block(node_6,$$render=>{get$3(initialLoadComplete)?$$render(alternate,-1):$$render(consequent_1)})}append($$anchor3,fragment_1)}),reset(div_5),append($$anchor2,div_5)};if_block(node_5,$$render=>{get$3(servers).length>0&&$$render(consequent_2)})}reset(div_3),reset(div),template_effect(()=>set_class(div_3,1,`grid gap-5 md:space-y-4 ${$$props.class??""}`)),transition(1,div,()=>fade,()=>({duration:150})),append($$anchor,
|
|
|
|
|
div),pop()}delegate(["click"]);var root_3$y=from_html("<!> Tools",1),root_5$h=from_html("<!> Resources",1),root_7$g=from_html("<!> Prompts",1),root_9$c=from_html("<!> Logging",1),root_11$7=from_html("<!> Completions",1),root_13$5=from_html("<!> Tasks",1),root_1$o=from_html("<!> <!> <!> <!> <!> <!>",1);function McpCapabilitiesBadges($$anchor,$$props){push$1($$props,!0);var fragment=comment$2(),node2=first_child(fragment);{var consequent_6=$$anchor2=>{var fragment_1=root_1$o(),node_1=first_child(fragment_1);
|
|
|
|
|
{var consequent=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-green-50 px-1.5 text-[10px] dark:bg-green-950",children:($$anchor4,$$slotProps)=>{var fragment_3=root_3$y(),node_2=first_child(fragment_3);Wrench(node_2,{class:"h-3 w-3 text-green-600 dark:text-green-400"}),next$1(),append($$anchor4,fragment_3)},$$slots:{default:!0}})};if_block(node_1,$$render=>{$$props.capabilities.server.tools&&$$render(consequent)})}var node_3=sibling(node_1,2);{var consequent_1=$$anchor3=>{Badge(
|
|
|
|
|
$$anchor3,{variant:"outline",class:"h-5 gap-1 bg-blue-50 px-1.5 text-[10px] dark:bg-blue-950",children:($$anchor4,$$slotProps)=>{var fragment_5=root_5$h(),node_4=first_child(fragment_5);Database(node_4,{class:"h-3 w-3 text-blue-600 dark:text-blue-400"}),next$1(),append($$anchor4,fragment_5)},$$slots:{default:!0}})};if_block(node_3,$$render=>{$$props.capabilities.server.resources&&$$render(consequent_1)})}var node_5=sibling(node_3,2);{var consequent_2=$$anchor3=>{Badge($$anchor3,{variant:"outline",
|
|
|
|
|
class:"h-5 gap-1 bg-purple-50 px-1.5 text-[10px] dark:bg-purple-950",children:($$anchor4,$$slotProps)=>{var fragment_7=root_7$g(),node_6=first_child(fragment_7);Message_square(node_6,{class:"h-3 w-3 text-purple-600 dark:text-purple-400"}),next$1(),append($$anchor4,fragment_7)},$$slots:{default:!0}})};if_block(node_5,$$render=>{$$props.capabilities.server.prompts&&$$render(consequent_2)})}var node_7=sibling(node_5,2);{var consequent_3=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-\
|
|
|
|
|
1 bg-orange-50 px-1.5 text-[10px] dark:bg-orange-950",children:($$anchor4,$$slotProps)=>{var fragment_9=root_9$c(),node_8=first_child(fragment_9);File_text(node_8,{class:"h-3 w-3 text-orange-600 dark:text-orange-400"}),next$1(),append($$anchor4,fragment_9)},$$slots:{default:!0}})};if_block(node_7,$$render=>{$$props.capabilities.server.logging&&$$render(consequent_3)})}var node_9=sibling(node_7,2);{var consequent_4=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-cyan-50 px-1.5 \
|
|
|
|
|
text-[10px] dark:bg-cyan-950",children:($$anchor4,$$slotProps)=>{var fragment_11=root_11$7(),node_10=first_child(fragment_11);Sparkles(node_10,{class:"h-3 w-3 text-cyan-600 dark:text-cyan-400"}),next$1(),append($$anchor4,fragment_11)},$$slots:{default:!0}})};if_block(node_9,$$render=>{$$props.capabilities.server.completions&&$$render(consequent_4)})}var node_11=sibling(node_9,2);{var consequent_5=$$anchor3=>{Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 bg-pink-50 px-1.5 text-[10px] dark:b\
|
|
|
|
|
g-pink-950",children:($$anchor4,$$slotProps)=>{var fragment_13=root_13$5(),node_12=first_child(fragment_13);List_checks(node_12,{class:"h-3 w-3 text-pink-600 dark:text-pink-400"}),next$1(),append($$anchor4,fragment_13)},$$slots:{default:!0}})};if_block(node_11,$$render=>{$$props.capabilities.server.tasks&&$$render(consequent_5)})}append($$anchor2,fragment_1)};if_block(node2,$$render=>{$$props.capabilities&&$$render(consequent_6)})}append($$anchor,fragment),pop()}var root_6$j=from_html('<span cla\
|
|
|
|
|
ss="ml-1"> </span>'),root_3$x=from_html("<!> <span> </span> <!>",1),root_9$b=from_html('<details class="ml-11"><summary class="cursor-pointer text-[10px] text-muted-foreground">details</summary> <pre class="mt-1 overflow-x-auto rounded bg-background/70 p-2 text-[10px] break-all whitespace-pre-wrap text-foreground/80"> </pre></details>'),root_8$h=from_html('<div><span class="shrink-0 text-muted-foreground"> </span> <!> <span class="break-all"> </span></div> <!>',1),root_7$f=from_html('<div class=\
|
|
|
|
|
"max-h-64 space-y-0.5 overflow-y-auto rounded bg-muted/50 p-2 font-mono text-[10px]"></div>'),root_2$E=from_html('<div class="space-y-2"><!></div> <!>',1);function McpConnectionLogs($$anchor,$$props){push$1($$props,!0);let defaultExpanded=prop($$props,"defaultExpanded",3,!1),isExpanded=user_derived(defaultExpanded);function formatLogDetails(details){if(details==null)return"";try{return JSON.stringify(details,null,2)}catch{return String(details)}}var fragment=comment$2(),node2=first_child(fragment);
|
|
|
|
|
{var consequent_3=$$anchor2=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);component(node_1,()=>Collapsible,($$anchor3,Collapsible_Root)=>{Collapsible_Root($$anchor3,{get class(){return $$props.class},get open(){return get$3(isExpanded)},set open($$value){set$1(isExpanded,$$value)},children:($$anchor4,$$slotProps)=>{var fragment_2=root_2$E(),div=first_child(fragment_2),node_2=child(div);component(node_2,()=>Collapsible_trigger,($$anchor5,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor5,
|
|
|
|
|
{class:"flex w-full items-center gap-1 text-xs text-muted-foreground hover:text-foreground",children:($$anchor6,$$slotProps2)=>{var fragment_3=root_3$x(),node_3=first_child(fragment_3);{var consequent=$$anchor7=>{Chevron_down($$anchor7,{class:"h-3.5 w-3.5"})},alternate=$$anchor7=>{Chevron_right($$anchor7,{class:"h-3.5 w-3.5"})};if_block(node_3,$$render=>{get$3(isExpanded)?$$render(consequent):$$render(alternate,-1)})}var span=sibling(node_3,2),text2=child(span);reset(span);var node_4=sibling(span,
|
|
|
|
|
2);{var consequent_1=$$anchor7=>{var span_1=root_6$j(),text_1=child(span_1);reset(span_1),template_effect(()=>set_text(text_1,`· Connected in ${$$props.connectionTimeMs??""}ms`)),append($$anchor7,span_1)};if_block(node_4,$$render=>{$$props.connectionTimeMs!==void 0&&$$render(consequent_1)})}template_effect(()=>set_text(text2,`Connection Log (${$$props.logs.length??""})`)),append($$anchor6,fragment_3)},$$slots:{default:!0}})}),reset(div);var node_5=sibling(div,2);component(node_5,()=>Collapsible_content,
|
|
|
|
|
($$anchor5,Collapsible_Content)=>{Collapsible_Content($$anchor5,{class:"mt-2",children:($$anchor6,$$slotProps2)=>{var div_1=root_7$f();each(div_1,21,()=>$$props.logs,log=>log.timestamp.getTime()+log.message,($$anchor7,log)=>{const IconComponent=user_derived(()=>getMcpLogLevelIcon(get$3(log).level));var fragment_6=root_8$h(),div_2=first_child(fragment_6),span_2=child(div_2),text_2=child(span_2,!0);reset(span_2);var node_6=sibling(span_2,2);component(node_6,()=>get$3(IconComponent),($$anchor8,IconComponent_1)=>{
|
|
|
|
|
IconComponent_1($$anchor8,{class:"mt-0.5 h-3 w-3 shrink-0"})});var span_3=sibling(node_6,2),text_3=child(span_3,!0);reset(span_3),reset(div_2);var node_7=sibling(div_2,2);{var consequent_2=$$anchor8=>{var details_1=root_9$b(),pre=sibling(child(details_1),2),text_4=child(pre,!0);reset(pre),reset(details_1),template_effect($0=>set_text(text_4,$0),[()=>formatLogDetails(get$3(log).details)]),append($$anchor8,details_1)};if_block(node_7,$$render=>{get$3(log).details!==void 0&&$$render(consequent_2)})}
|
|
|
|
|
template_effect(($0,$1)=>{set_class(div_2,1,$0),set_text(text_2,$1),set_text(text_3,get$3(log).message)},[()=>clsx(["flex items-start gap-1.5",getMcpLogLevelClass(get$3(log).level)]),()=>formatTime(get$3(log).timestamp)]),append($$anchor7,fragment_6)}),reset(div_1),append($$anchor6,div_1)},$$slots:{default:!0}})}),append($$anchor4,fragment_2)},$$slots:{default:!0}})}),append($$anchor2,fragment_1)};if_block(node2,$$render=>{$$props.logs.length>0&&$$render(consequent_3)})}append($$anchor,fragment),
|
|
|
|
|
pop()}var root_1$n=from_html('<p class="mt-1.5 text-xs text-destructive"> </p>'),root_3$w=from_html('<span class="inline-flex gap-0.75 text-xs text-muted-foreground/60">(Run <pre>llama-server</pre> with <pre>--webui-mcp-proxy</pre> flag)</span>'),root_2$D=from_html('<label><!> <span><span class="text-xs text-muted-foreground">Use llama-server proxy</span> <br/> <!></span></label>'),root$M=from_html('<div class="grid gap-3"><div><label class="mb-2 block text-xs font-medium">Server URL <span class\
|
|
|
|
|
="text-destructive">*</span></label> <!> <!> <!></div> <!></div>');function McpServerForm($$anchor,$$props){push$1($$props,!0);let useProxy=prop($$props,"useProxy",3,!1),urlError=prop($$props,"urlError",3,null),id2=prop($$props,"id",3,"server"),isWebSocket=user_derived(()=>$$props.url.toLowerCase().startsWith(UrlProtocol.WEBSOCKET)||$$props.url.toLowerCase().startsWith(UrlProtocol.WEBSOCKET_SECURE)),headerPairs=user_derived(()=>parseHeadersToArray($$props.headers));function updateHeaderPairs(newPairs){
|
|
|
|
|
set$1(headerPairs,newPairs),$$props.onHeadersChange(serializeHeaders(newPairs))}var div=root$M(),div_1=child(div),label=child(div_1),node2=sibling(label,2);{let $0=user_derived(()=>urlError()?"border-destructive":"");Input(node2,{get id(){return`server-url-${id2()??""}`},type:"url",get placeholder(){return MCP_SERVER_URL_PLACEHOLDER},get value(){return $$props.url},oninput:e=>$$props.onUrlChange(e.currentTarget.value),get class(){return get$3($0)}})}var node_1=sibling(node2,2);{var consequent=$$anchor2=>{
|
|
|
|
|
var p2=root_1$n(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,urlError())),append($$anchor2,p2)};if_block(node_1,$$render=>{urlError()&&$$render(consequent)})}var node_2=sibling(node_1,2);{var consequent_2=$$anchor2=>{var label_1=root_2$D(),node_3=child(label_1);{let $0=user_derived(()=>!mcpStore.isProxyAvailable);Switch(node_3,{class:"mt-1",get id(){return`use-proxy-${id2()??""}`},get checked(){return useProxy()},get disabled(){return get$3($0)},onCheckedChange:checked=>$$props.
|
|
|
|
|
onUseProxyChange?.(checked)})}var span=sibling(node_3,2),node_4=sibling(child(span),4);{var consequent_1=$$anchor3=>{var span_1=root_3$w();append($$anchor3,span_1)};if_block(node_4,$$render=>{mcpStore.isProxyAvailable||$$render(consequent_1)})}reset(span),reset(label_1),template_effect(()=>set_class(label_1,1,clsx(["mt-3 flex items-start gap-2",mcpStore.isProxyAvailable&&"cursor-pointer",!mcpStore.isProxyAvailable&&"opacity-80"]))),append($$anchor2,label_1)};if_block(node_2,$$render=>{!get$3(isWebSocket)&&
|
|
|
|
|
$$props.onUseProxyChange&&$$render(consequent_2)})}reset(div_1);var node_5=sibling(div_1,2);KeyValuePairs(node_5,{class:"mt-2",get pairs(){return get$3(headerPairs)},onPairsChange:updateHeaderPairs,keyPlaceholder:"Header name",valuePlaceholder:"Value",addButtonLabel:"Add",emptyMessage:"No custom headers configured.",sectionLabel:"Custom Headers",sectionLabelOptional:!0}),reset(div),template_effect(()=>set_attribute(label,"for",`server-url-${id2()??""}`)),append($$anchor,div),pop()}var root$L=from_html(
|
|
|
|
|
"<div></div>");function Skeleton($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var div=root$L();attribute_effect(div,$0=>({"data-slot":"skeleton",class:$0,...restProps}),[()=>cn$1("animate-pulse rounded-md bg-accent",$$props.class)]),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root_4$m=from_html('<p class="text-xs text-destructive"> </p>'),root_5$g=from_html(
|
|
|
|
|
'<p class="line-clamp-2 text-xs text-muted-foreground"> </p>'),root_6$i=from_html('<div class="space-y-2"><div class="flex items-center gap-2"><!> <!></div> <div class="flex flex-wrap gap-1.5"><!> <!> <!></div></div> <div class="space-y-1.5"><div class="flex items-center gap-2"><!> <!></div></div>',1),root_7$e=from_html("<!> <!> <!>",1),root_12$6=from_html('<div class="flex flex-wrap items-center gap-1"><span class="text-[10px] text-muted-foreground"> </span></div>'),root_3$v=from_html('<!> <!> \
|
|
|
|
|
<!> <div class="grid gap-3"><!></div> <div class="flex justify-between gap-4"><!> <!></div>',1),root$K=from_html("<!> <!>",1);function McpServerCard($$anchor,$$props){push$1($$props,!0);let healthState=user_derived(()=>mcpStore.getHealthCheckState($$props.server.id)),displayName=user_derived(()=>mcpStore.getServerLabel($$props.server)),faviconUrl=user_derived(()=>mcpStore.getServerFavicon($$props.server.id)),isIdle=user_derived(()=>get$3(healthState).status===HealthCheckStatus.IDLE),isHealthChecking=user_derived(
|
|
|
|
|
()=>get$3(healthState).status===HealthCheckStatus.CONNECTING),isConnected=user_derived(()=>get$3(healthState).status===HealthCheckStatus.SUCCESS),isError=user_derived(()=>get$3(healthState).status===HealthCheckStatus.ERROR),showSkeleton=user_derived(()=>get$3(isIdle)||get$3(isHealthChecking)),errorMessage=user_derived(()=>get$3(healthState).status===HealthCheckStatus.ERROR?get$3(healthState).message:void 0),tools=user_derived(()=>get$3(healthState).status===HealthCheckStatus.SUCCESS?get$3(healthState).
|
|
|
|
|
tools:[]),connectionLogs=user_derived(()=>get$3(healthState).status===HealthCheckStatus.CONNECTING||get$3(healthState).status===HealthCheckStatus.SUCCESS||get$3(healthState).status===HealthCheckStatus.ERROR?get$3(healthState).logs:[]),successState=user_derived(()=>get$3(healthState).status===HealthCheckStatus.SUCCESS?get$3(healthState):null),serverInfo=user_derived(()=>get$3(successState)?.serverInfo),capabilities=user_derived(()=>get$3(successState)?.capabilities),transportType=user_derived(()=>get$3(
|
|
|
|
|
successState)?.transportType),protocolVersion=user_derived(()=>get$3(successState)?.protocolVersion),connectionTimeMs=user_derived(()=>get$3(successState)?.connectionTimeMs),instructions=user_derived(()=>get$3(successState)?.instructions),isEditing2=user_derived(()=>!$$props.server.url.trim()),showDeleteDialog=state$1(!1),editFormRef=state$1(null);function handleHealthCheck(){mcpStore.runHealthCheck($$props.server)}async function startEditing(){set$1(isEditing2,!0),await tick(),get$3(editFormRef)?.
|
|
|
|
|
setInitialValues($$props.server.url,$$props.server.headers||"",$$props.server.useProxy||!1)}function cancelEditing(){$$props.server.url.trim()?set$1(isEditing2,!1):$$props.onDelete()}function saveEditing(url2,headers,useProxy){$$props.onUpdate({url:url2,headers:headers||void 0,useProxy}),set$1(isEditing2,!1),$$props.server.enabled&&url2&&setTimeout(()=>mcpStore.runHealthCheck({...$$props.server,url:url2,useProxy}),100)}function handleDeleteClick(){set$1(showDeleteDialog,!0)}var fragment=root$K(),
|
|
|
|
|
node2=first_child(fragment);component(node2,()=>Card,($$anchor2,Card_Root)=>{Card_Root($$anchor2,{class:"!gap-3 bg-muted/30 p-4",children:($$anchor3,$$slotProps)=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);{var consequent=$$anchor4=>{bind_this(McpServerCardEditForm($$anchor4,{get serverId(){return $$props.server.id},get serverUrl(){return $$props.server.url},get serverUseProxy(){return $$props.server.useProxy},onSave:saveEditing,onCancel:cancelEditing}),$$value=>set$1(editFormRef,
|
|
|
|
|
$$value,!0),()=>get$3(editFormRef))},alternate_1=$$anchor4=>{var fragment_3=root_3$v(),node_2=first_child(fragment_3);{let $0=user_derived(()=>$$props.enabled??$$props.server.enabled);McpServerCardHeader(node_2,{get displayName(){return get$3(displayName)},get faviconUrl(){return get$3(faviconUrl)},get enabled(){return get$3($0)},get disabled(){return get$3(isError)},get onToggle(){return $$props.onToggle},get serverInfo(){return get$3(serverInfo)},get capabilities(){return get$3(capabilities)},
|
|
|
|
|
get transportType(){return get$3(transportType)}})}var node_3=sibling(node_2,2);{var consequent_1=$$anchor5=>{var p2=root_4$m(),text2=child(p2,!0);reset(p2),template_effect(()=>set_text(text2,get$3(errorMessage))),append($$anchor5,p2)};if_block(node_3,$$render=>{get$3(isError)&&get$3(errorMessage)&&$$render(consequent_1)})}var node_4=sibling(node_3,2);{var consequent_2=$$anchor5=>{var p_1=root_5$g(),text_1=child(p_1,!0);reset(p_1),template_effect(()=>set_text(text_1,get$3(serverInfo).description)),
|
|
|
|
|
append($$anchor5,p_1)};if_block(node_4,$$render=>{get$3(isConnected)&&get$3(serverInfo)?.description&&$$render(consequent_2)})}var div=sibling(node_4,2),node_5=child(div);{var consequent_3=$$anchor5=>{var fragment_4=root_6$i(),div_1=first_child(fragment_4),div_2=child(div_1),node_6=child(div_2);Skeleton(node_6,{class:"h-4 w-4 rounded"});var node_7=sibling(node_6,2);Skeleton(node_7,{class:"h-3 w-24"}),reset(div_2);var div_3=sibling(div_2,2),node_8=child(div_3);Skeleton(node_8,{class:"h-5 w-16 rou\
|
|
|
|
|
nded-full"});var node_9=sibling(node_8,2);Skeleton(node_9,{class:"h-5 w-20 rounded-full"});var node_10=sibling(node_9,2);Skeleton(node_10,{class:"h-5 w-14 rounded-full"}),reset(div_3),reset(div_1);var div_4=sibling(div_1,2),div_5=child(div_4),node_11=child(div_5);Skeleton(node_11,{class:"h-4 w-4 rounded"});var node_12=sibling(node_11,2);Skeleton(node_12,{class:"h-3 w-32"}),reset(div_5),reset(div_4),append($$anchor5,fragment_4)},alternate=$$anchor5=>{var fragment_5=root_7$e(),node_13=first_child(
|
|
|
|
|
fragment_5);{var consequent_4=$$anchor6=>{McpServerInfo($$anchor6,{get instructions(){return get$3(instructions)}})};if_block(node_13,$$render=>{get$3(isConnected)&&get$3(instructions)&&$$render(consequent_4)})}var node_14=sibling(node_13,2);{var consequent_5=$$anchor6=>{McpServerCardToolsList($$anchor6,{get tools(){return get$3(tools)}})};if_block(node_14,$$render=>{get$3(tools).length>0&&$$render(consequent_5)})}var node_15=sibling(node_14,2);{var consequent_6=$$anchor6=>{McpConnectionLogs($$anchor6,
|
|
|
|
|
{get logs(){return get$3(connectionLogs)},get connectionTimeMs(){return get$3(connectionTimeMs)}})};if_block(node_15,$$render=>{get$3(connectionLogs).length>0&&$$render(consequent_6)})}append($$anchor5,fragment_5)};if_block(node_5,$$render=>{get$3(showSkeleton)?$$render(consequent_3):$$render(alternate,-1)})}reset(div);var div_6=sibling(div,2),node_16=child(div_6);{var consequent_7=$$anchor5=>{Skeleton($$anchor5,{class:"h-3 w-28"})},consequent_8=$$anchor5=>{var div_7=root_12$6(),span=child(div_7),
|
|
|
|
|
text_2=child(span);reset(span),reset(div_7),template_effect(()=>set_text(text_2,`Protocol version: ${get$3(protocolVersion)??""}`)),append($$anchor5,div_7)};if_block(node_16,$$render=>{get$3(showSkeleton)?$$render(consequent_7):get$3(protocolVersion)&&$$render(consequent_8,1)})}var node_17=sibling(node_16,2);McpServerCardActions(node_17,{get isHealthChecking(){return get$3(isHealthChecking)},onEdit:startEditing,onRefresh:handleHealthCheck,onDelete:handleDeleteClick}),reset(div_6),append($$anchor4,
|
|
|
|
|
fragment_3)};if_block(node_1,$$render=>{get$3(isEditing2)?$$render(consequent):$$render(alternate_1,-1)})}append($$anchor3,fragment_1)},$$slots:{default:!0}})});var node_18=sibling(node2,2);McpServerCardDeleteDialog(node_18,{get displayName(){return get$3(displayName)},onOpenChange:open2=>set$1(showDeleteDialog,open2,!0),get onConfirm(){return $$props.onDelete},get open(){return get$3(showDeleteDialog)},set open($$value){set$1(showDeleteDialog,$$value,!0)}}),append($$anchor,fragment),pop()}var root_3$u=from_html(
|
|
|
|
|
"<!> ",1),root_1$m=from_html('<div class="flex flex-wrap items-center gap-1.5"><!> <!></div>'),root$J=from_html('<div class="space-y-3"><div class="flex items-start justify-between gap-3"><div class="flex min-w-0 flex-col gap-3"><div class="inline-flex items-center gap-2"><!></div> <!></div> <div class="flex shrink-0 items-center pl-2"><!></div></div></div>');function McpServerCardHeader($$anchor,$$props){push$1($$props,!0);let disabled=prop($$props,"disabled",3,!1);var div=root$J(),div_1=child(
|
|
|
|
|
div),div_2=child(div_1),div_3=child(div_2),node2=child(div_3);McpServerIdentity(node2,{get displayName(){return $$props.displayName},get faviconUrl(){return $$props.faviconUrl},get serverInfo(){return $$props.serverInfo},iconClass:"h-5 w-5",iconRounded:"rounded",nameClass:"leading-6 font-medium"}),reset(div_3);var node_1=sibling(div_3,2);{var consequent_3=$$anchor2=>{var div_4=root_1$m(),node_2=child(div_4);{var consequent_1=$$anchor3=>{const TransportIcon=user_derived(()=>MCP_TRANSPORT_ICONS[$$props.
|
|
|
|
|
transportType]);Badge($$anchor3,{variant:"outline",class:"h-5 gap-1 px-1.5 text-[10px]",children:($$anchor4,$$slotProps)=>{var fragment_1=root_3$u(),node_3=first_child(fragment_1);{var consequent=$$anchor5=>{var fragment_2=comment$2(),node_4=first_child(fragment_2);component(node_4,()=>get$3(TransportIcon),($$anchor6,TransportIcon_1)=>{TransportIcon_1($$anchor6,{class:"h-3 w-3"})}),append($$anchor5,fragment_2)};if_block(node_3,$$render=>{get$3(TransportIcon)&&$$render(consequent)})}var text2=sibling(
|
|
|
|
|
node_3);template_effect(()=>set_text(text2,` ${(MCP_TRANSPORT_LABELS[$$props.transportType]||$$props.transportType)??""}`)),append($$anchor4,fragment_1)},$$slots:{default:!0}})};if_block(node_2,$$render=>{$$props.transportType&&$$render(consequent_1)})}var node_5=sibling(node_2,2);{var consequent_2=$$anchor3=>{McpCapabilitiesBadges($$anchor3,{get capabilities(){return $$props.capabilities}})};if_block(node_5,$$render=>{$$props.capabilities&&$$render(consequent_2)})}reset(div_4),append($$anchor2,
|
|
|
|
|
div_4)};if_block(node_1,$$render=>{($$props.capabilities||$$props.transportType)&&$$render(consequent_3)})}reset(div_2);var div_5=sibling(div_2,2),node_6=child(div_5);Switch(node_6,{get checked(){return $$props.enabled},get disabled(){return disabled()},get onCheckedChange(){return $$props.onToggle}}),reset(div_5),reset(div_1),reset(div),append($$anchor,div),pop()}var root$I=from_html('<div class="flex shrink-0 items-center gap-1"><!> <!> <!></div>');function McpServerCardActions($$anchor,$$props){
|
|
|
|
|
var div=root$I(),node2=child(div);Button(node2,{variant:"ghost",size:"icon",class:"h-7 w-7",get onclick(){return $$props.onEdit},"aria-label":"Edit",children:($$anchor2,$$slotProps)=>{Pencil($$anchor2,{class:"h-3.5 w-3.5"})},$$slots:{default:!0}});var node_1=sibling(node2,2);Button(node_1,{variant:"ghost",size:"icon",class:"h-7 w-7",get onclick(){return $$props.onRefresh},get disabled(){return $$props.isHealthChecking},"aria-label":"Refresh",children:($$anchor2,$$slotProps)=>{Refresh_cw($$anchor2,
|
|
|
|
|
{class:"h-3.5 w-3.5"})},$$slots:{default:!0}});var node_2=sibling(node_1,2);Button(node_2,{variant:"ghost",size:"icon",class:"hover:text-destructive-foreground h-7 w-7 text-destructive hover:bg-destructive/10",get onclick(){return $$props.onDelete},"aria-label":"Delete",children:($$anchor2,$$slotProps)=>{Trash_2($$anchor2,{class:"h-3.5 w-3.5"})},$$slots:{default:!0}}),reset(div),append($$anchor,div)}var root_2$C=from_html("<!> <span> </span>",1),root_8$g=from_html('<p class="mt-1 text-xs text-mu\
|
|
|
|
|
ted-foreground"> </p>'),root_6$h=from_html("<div><!> <!></div>"),root_5$f=from_html('<div class="max-h-64 space-y-3 overflow-y-auto"></div>'),root_1$l=from_html("<!> <!>",1);function McpServerCardToolsList($$anchor,$$props){push$1($$props,!0);let isExpanded=state$1(!1),toolsCount=user_derived(()=>$$props.tools.length);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Collapsible,($$anchor2,Collapsible_Root)=>{Collapsible_Root($$anchor2,{get open(){return get$3(isExpanded)},
|
|
|
|
|
set open($$value){set$1(isExpanded,$$value,!0)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$l(),node_1=first_child(fragment_1);component(node_1,()=>Collapsible_trigger,($$anchor4,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor4,{class:"flex w-full items-center gap-1 text-xs text-muted-foreground hover:text-foreground",children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$C(),node_2=first_child(fragment_2);{var consequent=$$anchor6=>{Chevron_down($$anchor6,{class:"h-3.5 w-3.5"})},
|
|
|
|
|
alternate=$$anchor6=>{Chevron_right($$anchor6,{class:"h-3.5 w-3.5"})};if_block(node_2,$$render=>{get$3(isExpanded)?$$render(consequent):$$render(alternate,-1)})}var span=sibling(node_2,2),text2=child(span);reset(span),template_effect(()=>set_text(text2,`${get$3(toolsCount)??""} tools available · Show details`)),append($$anchor5,fragment_2)},$$slots:{default:!0}})});var node_3=sibling(node_1,2);component(node_3,()=>Collapsible_content,($$anchor4,Collapsible_Content)=>{Collapsible_Content($$anchor4,
|
|
|
|
|
{class:"mt-2",children:($$anchor5,$$slotProps2)=>{var div=root_5$f();each(div,21,()=>$$props.tools,tool=>tool.name,($$anchor6,tool)=>{var div_1=root_6$h(),node_4=child(div_1);Badge(node_4,{variant:"secondary",children:($$anchor7,$$slotProps3)=>{next$1();var text_1=text$8();template_effect(()=>set_text(text_1,get$3(tool).name)),append($$anchor7,text_1)},$$slots:{default:!0}});var node_5=sibling(node_4,2);{var consequent_1=$$anchor7=>{var p2=root_8$g(),text_2=child(p2,!0);reset(p2),template_effect(
|
|
|
|
|
()=>set_text(text_2,get$3(tool).description)),append($$anchor7,p2)};if_block(node_5,$$render=>{get$3(tool).description&&$$render(consequent_1)})}reset(div_1),append($$anchor6,div_1)}),reset(div),append($$anchor5,div)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)},$$slots:{default:!0}})}),append($$anchor,fragment),pop()}var root$H=from_html('<div class="space-y-4"><p class="font-medium">Configure Server</p> <!> <div class="flex items-center justify-end gap-2"><!> <!></div></div>');function McpServerCardEditForm($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let serverUseProxy=prop($$props,"serverUseProxy",3,!1),editUrl=user_derived(()=>$$props.serverUrl),editHeaders=state$1(""),editUseProxy=user_derived(serverUseProxy),urlError=user_derived(()=>{if(!get$3(editUrl).trim())return"URL is required";try{return new URL(get$3(editUrl)),null}catch{return"Invalid URL format"}}),canSave=user_derived(()=>!get$3(urlError));function handleSave(){get$3(canSave)&&$$props.onSave(get$3(editUrl).trim(),get$3(editHeaders).trim(),get$3(editUseProxy))}
|
|
|
|
|
function setInitialValues(url2,headers,useProxy){set$1(editUrl,url2),set$1(editHeaders,headers,!0),set$1(editUseProxy,useProxy)}var $$exports={setInitialValues},div=root$H(),node2=sibling(child(div),2);{let $0=user_derived(()=>get$3(editUrl)?get$3(urlError):null);McpServerForm(node2,{get url(){return get$3(editUrl)},get headers(){return get$3(editHeaders)},get useProxy(){return get$3(editUseProxy)},onUrlChange:v=>set$1(editUrl,v),onHeadersChange:v=>set$1(editHeaders,v,!0),onUseProxyChange:v=>set$1(
|
|
|
|
|
editUseProxy,v),get urlError(){return get$3($0)},get id(){return $$props.serverId}})}var div_1=sibling(node2,2),node_1=child(div_1);Button(node_1,{variant:"secondary",size:"sm",get onclick(){return $$props.onCancel},children:($$anchor2,$$slotProps)=>{next$1();var text2=text$8("Cancel");append($$anchor2,text2)},$$slots:{default:!0}});var node_2=sibling(node_1,2);{let $0=user_derived(()=>!get$3(canSave));Button(node_2,{size:"sm",onclick:handleSave,get disabled(){return get$3($0)},children:($$anchor2,$$slotProps)=>{
|
|
|
|
|
next$1();var text_1=text$8();template_effect($02=>set_text(text_1,$02),[()=>$$props.serverUrl.trim()?"Update":"Add"]),append($$anchor2,text_1)},$$slots:{default:!0}})}return reset(div_1),reset(div),append($$anchor,div),pop($$exports)}function Alert_dialog_title($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("te\
|
|
|
|
|
xt-lg font-semibold",$$props.class));component(node2,()=>Dialog_title$1,($$anchor2,AlertDialogPrimitive_Title)=>{AlertDialogPrimitive_Title($$anchor2,spread_props({"data-slot":"alert-dialog-title",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Alert_dialog_action($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy",
|
|
|
|
|
"ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1(buttonVariants(),$$props.class));component(node2,()=>Alert_dialog_action$1,($$anchor2,AlertDialogPrimitive_Action)=>{AlertDialogPrimitive_Action($$anchor2,spread_props({"data-slot":"alert-dialog-action",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}function Alert_dialog_cancel($$anchor,$$props){push$1($$props,
|
|
|
|
|
!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1(buttonVariants({variant:"outline"}),$$props.class));component(node2,()=>Alert_dialog_cancel$1,($$anchor2,AlertDialogPrimitive_Cancel)=>{AlertDialogPrimitive_Cancel($$anchor2,spread_props({"data-slot":"alert-dialog-cancel",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){
|
|
|
|
|
ref2($$value)}}))})}append($$anchor,fragment),pop()}var root$G=from_html("<div><!></div>");function Alert_dialog_footer($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$G();attribute_effect(div,$0=>({"data-slot":"alert-dialog-footer",class:$0,...restProps}),[()=>cn$1("mt-6 flex flex-row gap-2 sm:mt-0 sm:justify-end [&>*]:flex-1 sm:[&>*]:flex-none",$$props.class)]);var node2=child(
|
|
|
|
|
div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}var root$F=from_html("<div><!></div>");function Alert_dialog_header($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","children"]);var div=root$F();attribute_effect(div,$0=>({"data-slot":"alert-dialog-header",class:$0,...restProps}),[()=>cn$1("flex flex-col gap-2 \
|
|
|
|
|
text-center sm:text-left",$$props.class)]);var node2=child(div);snippet(node2,()=>$$props.children??noop$3),reset(div),bind_this(div,$$value=>ref2($$value),()=>ref2()),append($$anchor,div),pop()}function Alert_dialog_overlay($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("fixed inset-0 z-50 bg-black/50 data-[st\
|
|
|
|
|
ate=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=open]:animate-in data-[state=open]:fade-in-0",$$props.class));component(node2,()=>Dialog_overlay$1,($$anchor2,AlertDialogPrimitive_Overlay)=>{AlertDialogPrimitive_Overlay($$anchor2,spread_props({"data-slot":"alert-dialog-overlay",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}var root_1$k=from_html("\
|
|
|
|
|
<!> <!>",1);function Alert_dialog_content($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class","portalProps"]);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$2,($$anchor2,AlertDialogPrimitive_Portal)=>{AlertDialogPrimitive_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$k(),node_1=first_child(fragment_1);
|
|
|
|
|
Alert_dialog_overlay(node_1,{});var node_2=sibling(node_1,2);{let $0=user_derived(()=>cn$1("fixed z-[999999] grid w-full gap-4 border bg-background p-6 shadow-lg duration-200","right-0 bottom-0 left-0 max-h-[100dvh] translate-x-0 translate-y-0 overflow-y-auto rounded-t-lg","data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:fill-mode-forwards data-[state=closed]:slide-out-to-bottom-full","data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:s\
|
|
|
|
|
lide-in-from-bottom-full","sm:top-[50%] sm:right-auto sm:bottom-auto sm:left-[50%] sm:max-h-[100vh] sm:max-w-lg sm:translate-x-[-50%] sm:translate-y-[-50%] sm:rounded-lg","sm:data-[state=closed]:slide-out-to-bottom-0 sm:data-[state=closed]:zoom-out-95","sm:data-[state=open]:slide-in-from-bottom-0 sm:data-[state=open]:zoom-in-95",$$props.class));component(node_2,()=>Alert_dialog_content$1,($$anchor4,AlertDialogPrimitive_Content)=>{AlertDialogPrimitive_Content($$anchor4,spread_props({"data-slot":"\
|
|
|
|
|
alert-dialog-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}function Alert_dialog_description($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","class"]);var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1("text-sm text\
|
|
|
|
|
-muted-foreground",$$props.class));component(node2,()=>Dialog_description$1,($$anchor2,AlertDialogPrimitive_Description)=>{AlertDialogPrimitive_Description($$anchor2,spread_props({"data-slot":"alert-dialog-description",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)}}))})}append($$anchor,fragment),pop()}const Root$1=Alert_dialog,Portal=Portal$2;var root_5$e=from_html(`Are you sure you want to delete <strong> </strong>? This action cannot be
|
|
|
|
|
undone.`,1),root_3$t=from_html("<!> <!>",1),root_6$g=from_html("<!> <!>",1),root_2$B=from_html("<!> <!>",1);function McpServerCardDeleteDialog($$anchor,$$props){push$1($$props,!0);let open2=prop($$props,"open",15);var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Root$1,($$anchor2,AlertDialog_Root)=>{AlertDialog_Root($$anchor2,{get onOpenChange(){return $$props.onOpenChange},get open(){return open2()},set open($$value){open2($$value)},children:($$anchor3,$$slotProps)=>{
|
|
|
|
|
var fragment_1=comment$2(),node_1=first_child(fragment_1);component(node_1,()=>Alert_dialog_content,($$anchor4,AlertDialog_Content)=>{AlertDialog_Content($$anchor4,{children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$B(),node_2=first_child(fragment_2);component(node_2,()=>Alert_dialog_header,($$anchor6,AlertDialog_Header)=>{AlertDialog_Header($$anchor6,{children:($$anchor7,$$slotProps3)=>{var fragment_3=root_3$t(),node_3=first_child(fragment_3);component(node_3,()=>Alert_dialog_title,($$anchor8,AlertDialog_Title)=>{
|
|
|
|
|
AlertDialog_Title($$anchor8,{children:($$anchor9,$$slotProps4)=>{next$1();var text2=text$8("Delete Server");append($$anchor9,text2)},$$slots:{default:!0}})});var node_4=sibling(node_3,2);component(node_4,()=>Alert_dialog_description,($$anchor8,AlertDialog_Description)=>{AlertDialog_Description($$anchor8,{children:($$anchor9,$$slotProps4)=>{next$1();var fragment_4=root_5$e(),strong2=sibling(first_child(fragment_4)),text_1=child(strong2,!0);reset(strong2),next$1(),template_effect(()=>set_text(text_1,
|
|
|
|
|
@@ -10843,53 +10844,54 @@ $$slots:{default:!0}}))})}append($$anchor,fragment),pop()}var root_2$i=from_html
|
|
|
|
|
"touchmove",blockOutsideTouchMove,listenerOptions)}}),user_effect(()=>{const element2=ref2();if(cleanupInternalListeners?.(),!element2)return;const stopWheelPropagation=event2=>{event2.stopPropagation()},stopTouchPropagation=event2=>{event2.stopPropagation()};element2.addEventListener("wheel",stopWheelPropagation),element2.addEventListener("touchmove",stopTouchPropagation),cleanupInternalListeners=()=>{element2.removeEventListener("wheel",stopWheelPropagation),element2.removeEventListener("touch\
|
|
|
|
|
move",stopTouchPropagation)}}),onDestroy(()=>{cleanupInternalListeners?.()});var fragment=comment$2(),node2=first_child(fragment);component(node2,()=>Portal$2,($$anchor2,SelectPrimitive_Portal)=>{SelectPrimitive_Portal($$anchor2,spread_props(()=>$$props.portalProps,{children:($$anchor3,$$slotProps)=>{var fragment_1=comment$2(),node_1=first_child(fragment_1);{let $0=user_derived(()=>cn$1("relative z-[var(--layer-popover,1000000)] max-h-(--bits-select-content-available-height) min-w-[8rem] origin-\
|
|
|
|
|
(--bits-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border bg-popover text-popover-foreground shadow-md data-[side=bottom]:translate-y-1 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:-translate-x-1 data-[side=left]:slide-in-from-right-2 data-[side=right]:translate-x-1 data-[side=right]:slide-in-from-left-2 data-[side=top]:-translate-y-1 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=clo\
|
|
|
|
|
sed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",$$props.class));component(node_1,()=>Select_content$1,($$anchor4,SelectPrimitive_Content)=>{SelectPrimitive_Content($$anchor4,spread_props({get sideOffset(){return sideOffset()},"data-slot":"select-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$i(),node_2=first_child(fragment_2);
|
|
|
|
|
Select_scroll_up_button(node_2,{});var node_3=sibling(node_2,2);{let $02=user_derived(()=>cn$1("h-(--bits-select-anchor-height) w-full min-w-(--bits-select-anchor-width) scroll-my-1 p-1"));component(node_3,()=>Select_viewport,($$anchor6,SelectPrimitive_Viewport)=>{SelectPrimitive_Viewport($$anchor6,{get class(){return get$3($02)},children:($$anchor7,$$slotProps3)=>{var fragment_3=comment$2(),node_4=first_child(fragment_3);snippet(node_4,()=>$$props.children??noop$3),append($$anchor7,fragment_3)},
|
|
|
|
|
$$slots:{default:!0}})})}var node_5=sibling(node_3,2);Select_scroll_down_button(node_5,{}),append($$anchor5,fragment_2)},$$slots:{default:!0}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}var root_1$c=from_html("<!> <!>",1);function Select_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),size2=prop($$props,"size",3,"default"),variant=prop($$props,"variant",3,"default"),restProps=rest_props($$props,["$$slots","$$event\
|
|
|
|
|
s","$$legacy","ref","class","children","size","variant"]);const baseClasses=user_derived(()=>variant()==="plain"?"group inline-flex w-full items-center justify-end gap-2 whitespace-nowrap px-0 py-0 text-sm font-medium text-muted-foreground transition-colors focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50 data-[placeholder]:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 [&_svg]:pointer-events-none [&_svg\
|
|
|
|
|
]:shrink-0 [&_svg:not([class*='size-'])]:size-3 [&_svg:not([class*='text-'])]:text-muted-foreground":"flex w-fit items-center justify-between gap-2 rounded-md border border-input bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none select-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 data-[placehol\
|
|
|
|
|
der]:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground"),chevronClasses=user_derived(()=>variant()==="plain"?"size-3 opacity-60 \
|
|
|
|
|
transition-transform group-data-[state=open]:-rotate-180":"size-4 opacity-50");var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1(get$3(baseClasses),$$props.class));component(node2,()=>Select_trigger$1,($$anchor2,SelectPrimitive_Trigger)=>{SelectPrimitive_Trigger($$anchor2,spread_props({"data-slot":"select-trigger",get"data-size"(){return size2()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor3,$$slotProps)=>{
|
|
|
|
|
var fragment_1=root_1$c(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);Chevron_down(node_2,{get class(){return get$3(chevronClasses)}}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}const Root=Select;var root$p=from_html("<textarea></textarea>");function Textarea($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),value=prop($$props,"value",15),restProps=rest_props($$props,
|
|
|
|
|
["$$slots","$$events","$$legacy","ref","value","class"]);var textarea=root$p();remove_textarea_child(textarea),attribute_effect(textarea,$0=>({"data-slot":"textarea",class:$0,...restProps}),[()=>cn$1("flex field-sizing-content min-h-16 w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowe\
|
|
|
|
|
d disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:aria-invalid:ring-destructive/40",$$props.class)]),bind_this(textarea,$$value=>ref2($$value),()=>ref2()),bind_value(textarea,value),append($$anchor,textarea),pop()}var root_1$b=from_html("<!> Custom",1);function SettingsChatParameterSourceIndicator($$anchor,$$props){let className=prop($$props,"class",3,"");Badge($$anchor,{variant:"secondary",get class(){return`h-5 bg-orange-100\
|
|
|
|
|
px-1.5 py-0.5 text-xs text-orange-800 dark:bg-orange-900 dark:text-orange-200 ${className()??""}`},children:($$anchor2,$$slotProps)=>{var fragment_1=root_1$b(),node2=first_child(fragment_1);Wrench(node2,{class:"mr-1 h-3 w-3"}),next$1(),append($$anchor2,fragment_1)},$$slots:{default:!0}})}var root_3$b=from_html(" <!>",1),root_6$8=from_html('<button type="button" class="absolute top-1/2 right-2 inline-flex h-5 w-5 -translate-y-1/2 items-center justify-center rounded transition-colors hover:bg-mut\
|
|
|
|
|
ed" aria-label="Reset to default" title="Reset to default"><!></button>'),root_7$7=from_html('<p class="mt-1 text-xs text-muted-foreground"></p>'),root_2$h=from_html('<div class="flex items-center gap-2"><!> <!></div> <div class="relative w-full"><!> <!></div> <!>',1),root_9$5=from_html(" <!>",1),root_11$3=from_html('<p class="mt-1 text-xs text-muted-foreground"> </p>'),root_12$2=from_html('<div class="mt-3 flex items-center gap-2"><!> <!></div>'),root_8$8=from_html("<!> <!> <!> <!>",1),root_15$2=from_html(
|
|
|
|
|
" <!>",1),root_19$2=from_html('<div class="flex items-center gap-2"><!> </div>'),root_21$1=from_html('<button type="button" class="absolute top-1/2 right-8 inline-flex h-5 w-5 -translate-y-1/2 items-center justify-center rounded transition-colors hover:bg-muted" aria-label="Reset to default" title="Reset to default"><!></button>'),root_25$1=from_html('<div class="flex items-center gap-2"><!> </div>'),root_18$1=from_html('<div class="relative w-full md:w-auto"><!> <!></div> <!>',1),root_27=from_html(
|
|
|
|
|
'<p class="mt-1 text-xs text-muted-foreground"> </p>'),root_14$1=from_html('<div class="flex items-center gap-2"><!> <!></div> <!> <!>',1),root_30=from_html('<p class="text-xs text-muted-foreground"> </p>'),root_28=from_html('<div class="flex items-start space-x-3"><!> <div class="space-y-1"><label class="flex cursor-pointer items-center gap-1.5 pt-1 pb-0.5 text-sm leading-none font-medium"> <!></label> <!></div></div>'),root_1$a=from_html('<div class="space-y-2"><!></div>');function SettingsChatFields($$anchor,$$props){
|
|
|
|
|
push$1($$props,!0);let sp=user_derived(()=>{if(serverStore.isRouterMode){const m=selectedModelName();if(m)return modelsStore.getModelProps(m)?.default_generation_settings?.params??{}}return serverStore.defaultParams??{}});var fragment=comment$2(),node2=first_child(fragment);each(node2,17,()=>$$props.fields,field=>field.key,($$anchor2,field)=>{var div=root_1$a(),node_1=child(div);{var consequent_4=$$anchor3=>{const currentValue=user_derived(()=>String($$props.localConfig[get$3(field).key]??"")),serverDefault=user_derived(
|
|
|
|
|
()=>get$3(sp)[get$3(field).key]),isCustomRealTime=user_derived(()=>(()=>{if(get$3(serverDefault)==null||get$3(currentValue)==="")return!1;const numericInput=parseFloat(get$3(currentValue)),normalizedInput=isNaN(numericInput)?get$3(currentValue):Math.round(numericInput*1e6)/1e6,normalizedDefault=typeof get$3(serverDefault)=="number"?Math.round(get$3(serverDefault)*1e6)/1e6:get$3(serverDefault);return normalizedInput!==normalizedDefault})());var fragment_1=root_2$h(),div_1=first_child(fragment_1),
|
|
|
|
|
node_2=child(div_1);Label(node_2,{get for(){return get$3(field).key},class:"flex items-center gap-1.5 text-sm font-medium",children:($$anchor4,$$slotProps)=>{next$1();var fragment_2=root_3$b(),text2=first_child(fragment_2),node_3=sibling(text2);{var consequent=$$anchor5=>{Flask_conical($$anchor5,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_3,$$render=>{get$3(field).isExperimental&&$$render(consequent)})}template_effect(()=>set_text(text2,`${get$3(field).label??""} `)),append($$anchor4,
|
|
|
|
|
fragment_2)},$$slots:{default:!0}});var node_4=sibling(node_2,2);{var consequent_1=$$anchor4=>{SettingsChatParameterSourceIndicator($$anchor4,{})};if_block(node_4,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_1)})}reset(div_1);var div_2=sibling(div_1,2),node_5=child(div_2);{let $0=user_derived(()=>get$3(sp)[get$3(field).key]!=null?`Default: ${normalizeFloatingPoint(get$3(sp)[get$3(field).key])}`:""),$1=user_derived(()=>get$3(isCustomRealTime)?"pr-8":"");Input(node_5,{get id(){return get$3(
|
|
|
|
|
field).key},get value(){return get$3(currentValue)},oninput:e=>{$$props.onConfigChange(get$3(field).key,e.currentTarget.value)},get placeholder(){return get$3($0)},get class(){return`w-full ${get$3($1)??""}`}})}var node_6=sibling(node_5,2);{var consequent_2=$$anchor4=>{var button=root_6$8(),node_7=child(button);Rotate_ccw(node_7,{class:"h-3 w-3"}),reset(button),delegated("click",button,()=>{settingsStore.resetParameterToServerDefault(get$3(field).key),$$props.onConfigChange(get$3(field).key,"")}),
|
|
|
|
|
append($$anchor4,button)};if_block(node_6,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_2)})}reset(div_2);var node_8=sibling(div_2,2);{var consequent_3=$$anchor4=>{var p_1=root_7$7();html$6(p_1,()=>get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key],!0),reset(p_1),append($$anchor4,p_1)};if_block(node_8,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_3)})}append($$anchor3,fragment_1)},consequent_8=$$anchor3=>{var fragment_5=root_8$8(),node_9=first_child(
|
|
|
|
|
fragment_5);Label(node_9,{get for(){return get$3(field).key},class:"block flex items-center gap-1.5 text-sm font-medium",children:($$anchor4,$$slotProps)=>{next$1();var fragment_6=root_9$5(),text_1=first_child(fragment_6),node_10=sibling(text_1);{var consequent_5=$$anchor5=>{Flask_conical($$anchor5,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_10,$$render=>{get$3(field).isExperimental&&$$render(consequent_5)})}template_effect(()=>set_text(text_1,`${get$3(field).label??""} `)),append(
|
|
|
|
|
$$anchor4,fragment_6)},$$slots:{default:!0}});var node_11=sibling(node_9,2);{let $0=user_derived(()=>String($$props.localConfig[get$3(field).key]??""));Textarea(node_11,{get id(){return get$3(field).key},get value(){return get$3($0)},onchange:e=>$$props.onConfigChange(get$3(field).key,e.currentTarget.value),placeholder:"",class:"min-h-[10rem] w-full md:max-w-3xl"})}var node_12=sibling(node_11,2);{var consequent_6=$$anchor4=>{var p_2=root_11$3(),text_2=child(p_2,!0);reset(p_2),template_effect(()=>set_text(
|
|
|
|
|
text_2,get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])),append($$anchor4,p_2)};if_block(node_12,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_6)})}var node_13=sibling(node_12,2);{var consequent_7=$$anchor4=>{var div_3=root_12$2(),node_14=child(div_3);{let $0=user_derived(()=>!!($$props.localConfig.showSystemMessage??!0));Checkbox(node_14,{id:"showSystemMessage",get checked(){return get$3($0)},onCheckedChange:checked=>$$props.onConfigChange("\
|
|
|
|
|
showSystemMessage",!!checked)})}var node_15=sibling(node_14,2);Label(node_15,{for:"showSystemMessage",class:"cursor-pointer text-sm font-normal",children:($$anchor5,$$slotProps)=>{next$1();var text_3=text$8("Show system message in conversations");append($$anchor5,text_3)},$$slots:{default:!0}}),reset(div_3),append($$anchor4,div_3)};if_block(node_13,$$render=>{get$3(field).key===SETTINGS_KEYS.SYSTEM_MESSAGE&&$$render(consequent_7)})}append($$anchor3,fragment_5)},consequent_16=$$anchor3=>{const selectedOption=user_derived(
|
|
|
|
|
()=>get$3(field).options?.find(opt=>opt.value===$$props.localConfig[get$3(field).key])),currentValue=user_derived(()=>$$props.localConfig[get$3(field).key]),serverDefault=user_derived(()=>get$3(sp)[get$3(field).key]),isCustomRealTime=user_derived(()=>get$3(serverDefault)==null||get$3(currentValue)===""||get$3(currentValue)===void 0?!1:get$3(currentValue)!==get$3(serverDefault));var fragment_8=root_14$1(),div_4=first_child(fragment_8),node_16=child(div_4);Label(node_16,{get for(){return get$3(field).
|
|
|
|
|
key},class:"flex items-center gap-1.5 text-sm font-medium",children:($$anchor4,$$slotProps)=>{next$1();var fragment_9=root_15$2(),text_4=first_child(fragment_9),node_17=sibling(text_4);{var consequent_9=$$anchor5=>{Flask_conical($$anchor5,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_17,$$render=>{get$3(field).isExperimental&&$$render(consequent_9)})}template_effect(()=>set_text(text_4,`${get$3(field).label??""} `)),append($$anchor4,fragment_9)},$$slots:{default:!0}});var node_18=sibling(
|
|
|
|
|
node_16,2);{var consequent_10=$$anchor4=>{SettingsChatParameterSourceIndicator($$anchor4,{})};if_block(node_18,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_10)})}reset(div_4);var node_19=sibling(div_4,2);component(node_19,()=>Root,($$anchor4,Select_Root)=>{Select_Root($$anchor4,{type:"single",get value(){return get$3(currentValue)},onValueChange:value=>{get$3(field).key===SETTINGS_KEYS.THEME&&value&&$$props.onThemeChange?$$props.onThemeChange(value):$$props.onConfigChange(get$3(field).
|
|
|
|
|
key,value)},children:($$anchor5,$$slotProps)=>{var fragment_12=root_18$1(),div_5=first_child(fragment_12),node_20=child(div_5);component(node_20,()=>Select_trigger,($$anchor6,Select_Trigger)=>{Select_Trigger($$anchor6,{class:"w-full",children:($$anchor7,$$slotProps2)=>{var div_6=root_19$2(),node_21=child(div_6);{var consequent_11=$$anchor8=>{const IconComponent=user_derived(()=>get$3(selectedOption).icon);var fragment_13=comment$2(),node_22=first_child(fragment_13);component(node_22,()=>get$3(IconComponent),
|
|
|
|
|
($$anchor9,IconComponent_1)=>{IconComponent_1($$anchor9,{class:"h-4 w-4"})}),append($$anchor8,fragment_13)};if_block(node_21,$$render=>{get$3(selectedOption)?.icon&&$$render(consequent_11)})}var text_5=sibling(node_21);reset(div_6),template_effect($0=>set_text(text_5,` ${$0??""}`),[()=>get$3(selectedOption)?.label||`Select ${get$3(field).label.toLowerCase()}`]),append($$anchor7,div_6)},$$slots:{default:!0}})});var node_23=sibling(node_20,2);{var consequent_12=$$anchor6=>{var button_1=root_21$1(),
|
|
|
|
|
node_24=child(button_1);Rotate_ccw(node_24,{class:"h-3 w-3"}),reset(button_1),delegated("click",button_1,()=>{settingsStore.resetParameterToServerDefault(get$3(field).key),$$props.onConfigChange(get$3(field).key,"")}),append($$anchor6,button_1)};if_block(node_23,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_12)})}reset(div_5);var node_25=sibling(div_5,2);component(node_25,()=>Select_content,($$anchor6,Select_Content)=>{Select_Content($$anchor6,{children:($$anchor7,$$slotProps2)=>{var fragment_14=comment$2(),
|
|
|
|
|
node_26=first_child(fragment_14);{var consequent_14=$$anchor8=>{var fragment_15=comment$2(),node_27=first_child(fragment_15);each(node_27,17,()=>get$3(field).options,option2=>option2.value,($$anchor9,option2)=>{var fragment_16=comment$2(),node_28=first_child(fragment_16);component(node_28,()=>Select_item,($$anchor10,Select_Item)=>{Select_Item($$anchor10,{get value(){return get$3(option2).value},get label(){return get$3(option2).label},children:($$anchor11,$$slotProps3)=>{var div_7=root_25$1(),node_29=child(
|
|
|
|
|
div_7);{var consequent_13=$$anchor12=>{const IconComponent=user_derived(()=>get$3(option2).icon);var fragment_17=comment$2(),node_30=first_child(fragment_17);component(node_30,()=>get$3(IconComponent),($$anchor13,IconComponent_2)=>{IconComponent_2($$anchor13,{class:"h-4 w-4"})}),append($$anchor12,fragment_17)};if_block(node_29,$$render=>{get$3(option2).icon&&$$render(consequent_13)})}var text_6=sibling(node_29);reset(div_7),template_effect(()=>set_text(text_6,` ${get$3(option2).label??""}`)),append(
|
|
|
|
|
$$anchor11,div_7)},$$slots:{default:!0}})}),append($$anchor9,fragment_16)}),append($$anchor8,fragment_15)};if_block(node_26,$$render=>{get$3(field).options&&$$render(consequent_14)})}append($$anchor7,fragment_14)},$$slots:{default:!0}})}),append($$anchor5,fragment_12)},$$slots:{default:!0}})});var node_31=sibling(node_19,2);{var consequent_15=$$anchor4=>{var p_3=root_27(),text_7=child(p_3,!0);reset(p_3),template_effect(()=>set_text(text_7,get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])),
|
|
|
|
|
append($$anchor4,p_3)};if_block(node_31,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_15)})}append($$anchor3,fragment_8)},consequent_19=$$anchor3=>{var div_8=root_28(),node_32=child(div_8);{let $0=user_derived(()=>!!$$props.localConfig[get$3(field).key]);Checkbox(node_32,{get id(){return get$3(field).key},get checked(){return get$3($0)},onCheckedChange:checked=>$$props.onConfigChange(get$3(field).key,checked),class:"mt-1"})}var div_9=sibling(node_32,2),
|
|
|
|
|
label=child(div_9),text_8=child(label),node_33=sibling(text_8);{var consequent_17=$$anchor4=>{Flask_conical($$anchor4,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_33,$$render=>{get$3(field).isExperimental&&$$render(consequent_17)})}reset(label);var node_34=sibling(label,2);{var consequent_18=$$anchor4=>{var p_4=root_30(),text_9=child(p_4,!0);reset(p_4),template_effect(()=>set_text(text_9,get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])),append($$anchor4,p_4)};if_block(node_34,
|
|
|
|
|
$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_18)})}reset(div_9),reset(div_8),template_effect(()=>{set_attribute(label,"for",get$3(field).key),set_text(text_8,`${get$3(field).label??""} `)}),append($$anchor3,div_8)};if_block(node_1,$$render=>{get$3(field).type===SettingsFieldType.INPUT?$$render(consequent_4):get$3(field).type===SettingsFieldType.TEXTAREA?$$render(consequent_8,1):get$3(field).type===SettingsFieldType.SELECT?$$render(consequent_16,2):get$3(
|
|
|
|
|
field).type===SettingsFieldType.CHECKBOX&&$$render(consequent_19,3)})}reset(div),append($$anchor2,div)}),append($$anchor,fragment),pop()}delegate(["click"]);var root_1$9=from_html('<div class="py-8 text-center text-sm text-muted-foreground">No tools available</div>'),root_5$7=from_html('<!> <span class="inline-flex min-w-0 items-center gap-1.5 font-medium"><!></span> <span class="ml-auto shrink-0 text-xs text-muted-foreground"> </span>',1),root_9$4=from_html('<div class="flex items-center gap-2 \
|
|
|
|
|
rounded px-2 py-1.5 text-sm hover:bg-muted/50"><!> <div class="flex w-16 shrink-0 justify-center"><!></div> <div class="flex w-20 shrink-0 justify-center"><!></div></div>'),root_8$7=from_html('<div class="ml-4 border-l border-border/50 pl-2"><div class="flex items-center gap-2 px-2 py-1 text-xs text-muted-foreground"><span class="min-w-0 flex-1">Tool</span> <span class="w-16 shrink-0 text-center">Enabled</span> <span class="w-20 shrink-0 text-center">Always allow</span></div> <!></div>'),root_4$8=from_html(
|
|
|
|
|
"<!> <!>",1),root_2$g=from_html('<div class="space-y-2"></div>');function SettingsChatToolsTab($$anchor,$$props){push$1($$props,!0);let expandedGroups=new SvelteSet,groups=user_derived(()=>toolsStore.toolGroups);function toggleExpanded(label){expandedGroups.has(label)?expandedGroups.delete(label):expandedGroups.add(label)}var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var div=root_1$9();append($$anchor2,div)},alternate_1=$$anchor2=>{var div_1=root_2$g();each(div_1,
|
|
|
|
|
21,()=>get$3(groups),group=>group.label,($$anchor3,group)=>{const isExpanded=user_derived(()=>expandedGroups.has(get$3(group).label));var fragment_1=comment$2(),node_1=first_child(fragment_1);component(node_1,()=>Collapsible,($$anchor4,Collapsible_Root)=>{Collapsible_Root($$anchor4,{get open(){return get$3(isExpanded)},onOpenChange:()=>toggleExpanded(get$3(group).label),children:($$anchor5,$$slotProps)=>{var fragment_2=root_4$8(),node_2=first_child(fragment_2);component(node_2,()=>Collapsible_trigger,
|
|
|
|
|
($$anchor6,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor6,{class:"flex w-full items-center gap-2 rounded-lg px-3 py-2 text-sm hover:bg-muted/50",children:($$anchor7,$$slotProps2)=>{const faviconUrl=user_derived(()=>get$3(group).serverId?mcpStore.getServerFavicon(get$3(group).serverId):null);var fragment_3=root_5$7(),node_3=first_child(fragment_3);{var consequent_1=$$anchor8=>{Chevron_down($$anchor8,{class:"h-3.5 w-3.5 shrink-0"})},alternate=$$anchor8=>{Chevron_right($$anchor8,{class:"h-3.5\
|
|
|
|
|
w-3.5 shrink-0"})};if_block(node_3,$$render=>{get$3(isExpanded)?$$render(consequent_1):$$render(alternate,-1)})}var span=sibling(node_3,2),node_4=child(span);McpServerIdentity(node_4,{iconClass:"h-4 w-4",iconRounded:"rounded-sm",showVersion:!1,get displayName(){return get$3(group).label},get faviconUrl(){return get$3(faviconUrl)}}),reset(span);var span_1=sibling(span,2),text2=child(span_1);reset(span_1),template_effect(()=>set_text(text2,`${get$3(group).tools.length??""} tool${get$3(group).tools.
|
|
|
|
|
length!==1?"s":""}`)),append($$anchor7,fragment_3)},$$slots:{default:!0}})});var node_5=sibling(node_2,2);component(node_5,()=>Collapsible_content,($$anchor6,Collapsible_Content)=>{Collapsible_Content($$anchor6,{children:($$anchor7,$$slotProps2)=>{var div_2=root_8$7(),node_6=sibling(child(div_2),2);each(node_6,17,()=>get$3(group).tools,tool=>tool.function.name,($$anchor8,tool)=>{const toolName=user_derived(()=>get$3(tool).function.name),isEnabled=user_derived(()=>toolsStore.isToolEnabled(get$3(toolName))),
|
|
|
|
|
permissionKey=user_derived(()=>toolsStore.getPermissionKey(get$3(toolName))),isAlwaysAllowed=user_derived(()=>get$3(permissionKey)?permissionsStore.hasTool(get$3(permissionKey)):!1);var div_3=root_9$4(),node_7=child(div_3);TruncatedText(node_7,{get text(){return get$3(toolName)},class:"flex-1",showTooltip:!0});var div_4=sibling(node_7,2),node_8=child(div_4);Checkbox(node_8,{get checked(){return get$3(isEnabled)},onCheckedChange:()=>toolsStore.toggleTool(get$3(toolName)),class:"h-4 w-4"}),reset(div_4);
|
|
|
|
|
var div_5=sibling(div_4,2),node_9=child(div_5);Checkbox(node_9,{get checked(){return get$3(isAlwaysAllowed)},onCheckedChange:()=>{get$3(isAlwaysAllowed)?permissionsStore.revokeTool(get$3(permissionKey)):permissionsStore.allowTool(get$3(permissionKey))},class:"h-4 w-4"}),reset(div_5),reset(div_3),append($$anchor8,div_3)}),reset(div_2),append($$anchor7,div_2)},$$slots:{default:!0}})}),append($$anchor5,fragment_2)},$$slots:{default:!0}})}),append($$anchor3,fragment_1)}),reset(div_1),append($$anchor2,
|
|
|
|
|
div_1)};if_block(node2,$$render=>{get$3(groups).length===0?$$render(consequent):$$render(alternate_1,-1)})}append($$anchor,fragment),pop()}const summaryList=($$anchor,show=noop$3,verb=noop$3,items2=noop$3)=>{var fragment=comment$2(),node2=first_child(fragment);{var consequent_1=$$anchor2=>{var div=root_2$f(),h5=child(div),text_1=child(h5);reset(h5);var ul=sibling(h5,2),node_1=child(ul);each(node_1,17,()=>items2().slice(0,10),conv=>conv.id,($$anchor3,conv)=>{var li2=root_3$a(),text_2=child(li2);reset(
|
|
|
|
|
li2),template_effect(()=>set_text(text_2,`• ${(get$3(conv).name||"Untitled conversation")??""}`)),append($$anchor3,li2)});var node_2=sibling(node_1,2);{var consequent=$$anchor3=>{var li_1=root_4$7(),text_3=child(li_1);reset(li_1),template_effect(()=>set_text(text_3,`... and ${items2().length-10} more`)),append($$anchor3,li_1)};if_block(node_2,$$render=>{items2().length>10&&$$render(consequent)})}reset(ul),reset(div),template_effect(()=>set_text(text_1,`${verb()??""}
|
|
|
|
|
sed]:fill-mode-forwards data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95",$$props.class));component(node_1,()=>Select_content$1,($$anchor4,SelectPrimitive_Content)=>{SelectPrimitive_Content($$anchor4,spread_props({get sideOffset(){return sideOffset()},"data-slot":"select-content",get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2($$value)},children:($$anchor5,$$slotProps2)=>{var fragment_2=root_2$i(),
|
|
|
|
|
node_2=first_child(fragment_2);Select_scroll_up_button(node_2,{});var node_3=sibling(node_2,2);{let $02=user_derived(()=>cn$1("h-(--bits-select-anchor-height) w-full min-w-(--bits-select-anchor-width) scroll-my-1 p-1"));component(node_3,()=>Select_viewport,($$anchor6,SelectPrimitive_Viewport)=>{SelectPrimitive_Viewport($$anchor6,{get class(){return get$3($02)},children:($$anchor7,$$slotProps3)=>{var fragment_3=comment$2(),node_4=first_child(fragment_3);snippet(node_4,()=>$$props.children??noop$3),
|
|
|
|
|
append($$anchor7,fragment_3)},$$slots:{default:!0}})})}var node_5=sibling(node_3,2);Select_scroll_down_button(node_5,{}),append($$anchor5,fragment_2)},$$slots:{default:!0}}))})}append($$anchor3,fragment_1)},$$slots:{default:!0}}))}),append($$anchor,fragment),pop()}var root_1$c=from_html("<!> <!>",1);function Select_trigger($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),size2=prop($$props,"size",3,"default"),variant=prop($$props,"variant",3,"default"),restProps=rest_props(
|
|
|
|
|
$$props,["$$slots","$$events","$$legacy","ref","class","children","size","variant"]);const baseClasses=user_derived(()=>variant()==="plain"?"group inline-flex w-full items-center justify-end gap-2 whitespace-nowrap px-0 py-0 text-sm font-medium text-muted-foreground transition-colors focus-visible:outline-none focus-visible:ring-0 focus-visible:ring-offset-0 disabled:cursor-not-allowed disabled:opacity-50 data-[placeholder]:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 [&_svg]\
|
|
|
|
|
:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-3 [&_svg:not([class*='text-'])]:text-muted-foreground":"flex w-fit items-center justify-between gap-2 rounded-md border border-input bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none select-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-de\
|
|
|
|
|
structive/20 data-[placeholder]:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 [&_svg:not([class*='text-'])]:text-muted-foreground"),chevronClasses=user_derived(()=>variant()===
|
|
|
|
|
"plain"?"size-3 opacity-60 transition-transform group-data-[state=open]:-rotate-180":"size-4 opacity-50");var fragment=comment$2(),node2=first_child(fragment);{let $0=user_derived(()=>cn$1(get$3(baseClasses),$$props.class));component(node2,()=>Select_trigger$1,($$anchor2,SelectPrimitive_Trigger)=>{SelectPrimitive_Trigger($$anchor2,spread_props({"data-slot":"select-trigger",get"data-size"(){return size2()},get class(){return get$3($0)}},()=>restProps,{get ref(){return ref2()},set ref($$value){ref2(
|
|
|
|
|
$$value)},children:($$anchor3,$$slotProps)=>{var fragment_1=root_1$c(),node_1=first_child(fragment_1);snippet(node_1,()=>$$props.children??noop$3);var node_2=sibling(node_1,2);Chevron_down(node_2,{get class(){return get$3(chevronClasses)}}),append($$anchor3,fragment_1)},$$slots:{default:!0}}))})}append($$anchor,fragment),pop()}const Root=Select;var root$p=from_html("<textarea></textarea>");function Textarea($$anchor,$$props){push$1($$props,!0);let ref2=prop($$props,"ref",15,null),value=prop($$props,
|
|
|
|
|
"value",15),restProps=rest_props($$props,["$$slots","$$events","$$legacy","ref","value","class"]);var textarea=root$p();remove_textarea_child(textarea),attribute_effect(textarea,$0=>({"data-slot":"textarea",class:$0,...restProps}),[()=>cn$1("flex field-sizing-content min-h-16 w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visibl\
|
|
|
|
|
e:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:aria-invalid:ring-destructive/40",$$props.class)]),bind_this(textarea,$$value=>ref2($$value),()=>ref2()),bind_value(textarea,value),append($$anchor,textarea),pop()}var root_1$b=from_html("<!> Custom",1);function SettingsChatParameterSourceIndicator($$anchor,$$props){let className=prop($$props,"class",3,"");Badge($$anchor,{variant:"second\
|
|
|
|
|
ary",get class(){return`h-5 bg-orange-100 px-1.5 py-0.5 text-xs text-orange-800 dark:bg-orange-900 dark:text-orange-200 ${className()??""}`},children:($$anchor2,$$slotProps)=>{var fragment_1=root_1$b(),node2=first_child(fragment_1);Wrench(node2,{class:"mr-1 h-3 w-3"}),next$1(),append($$anchor2,fragment_1)},$$slots:{default:!0}})}var root_3$b=from_html(" <!>",1),root_6$8=from_html('<button type="button" class="absolute top-1/2 right-2 inline-flex h-5 w-5 -translate-y-1/2 items-center justify-cent\
|
|
|
|
|
er rounded transition-colors hover:bg-muted" aria-label="Reset to default" title="Reset to default"><!></button>'),root_7$7=from_html('<p class="mt-1 text-xs text-muted-foreground"></p>'),root_2$h=from_html('<div class="flex items-center gap-2"><!> <!></div> <div class="relative w-full"><!> <!></div> <!>',1),root_9$5=from_html(" <!>",1),root_11$3=from_html('<p class="mt-1 text-xs text-muted-foreground"> </p>'),root_12$2=from_html('<div class="mt-3 flex items-center gap-2"><!> <!></div>'),root_8$8=from_html(
|
|
|
|
|
"<!> <!> <!> <!>",1),root_15$2=from_html(" <!>",1),root_19$2=from_html('<div class="flex items-center gap-2"><!> </div>'),root_21$1=from_html('<button type="button" class="absolute top-1/2 right-8 inline-flex h-5 w-5 -translate-y-1/2 items-center justify-center rounded transition-colors hover:bg-muted" aria-label="Reset to default" title="Reset to default"><!></button>'),root_25$1=from_html('<div class="flex items-center gap-2"><!> </div>'),root_18$1=from_html('<div class="relative w-full md:w-a\
|
|
|
|
|
uto"><!> <!></div> <!>',1),root_27=from_html('<p class="mt-1 text-xs text-muted-foreground"> </p>'),root_14$1=from_html('<div class="flex items-center gap-2"><!> <!></div> <!> <!>',1),root_30=from_html('<p class="text-xs text-muted-foreground"> </p>'),root_28=from_html('<div class="flex items-start space-x-3"><!> <div class="space-y-1"><label class="flex cursor-pointer items-center gap-1.5 pt-1 pb-0.5 text-sm leading-none font-medium"> <!></label> <!></div></div>'),root_1$a=from_html('<div class\
|
|
|
|
|
="space-y-2"><!></div>');function SettingsChatFields($$anchor,$$props){push$1($$props,!0);let sp=user_derived(()=>{if(serverStore.isRouterMode){const m=selectedModelName();if(m)return modelsStore.getModelProps(m)?.default_generation_settings?.params??{}}return serverStore.defaultParams??{}});var fragment=comment$2(),node2=first_child(fragment);each(node2,17,()=>$$props.fields,field=>field.key,($$anchor2,field)=>{var div=root_1$a(),node_1=child(div);{var consequent_4=$$anchor3=>{const currentValue=user_derived(
|
|
|
|
|
()=>String($$props.localConfig[get$3(field).key]??"")),serverDefault=user_derived(()=>get$3(sp)[get$3(field).key]),isCustomRealTime=user_derived(()=>(()=>{if(get$3(serverDefault)==null||get$3(currentValue)==="")return!1;const numericInput=parseFloat(get$3(currentValue)),normalizedInput=isNaN(numericInput)?get$3(currentValue):Math.round(numericInput*1e6)/1e6,normalizedDefault=typeof get$3(serverDefault)=="number"?Math.round(get$3(serverDefault)*1e6)/1e6:get$3(serverDefault);return normalizedInput!==
|
|
|
|
|
normalizedDefault})());var fragment_1=root_2$h(),div_1=first_child(fragment_1),node_2=child(div_1);Label(node_2,{get for(){return get$3(field).key},class:"flex items-center gap-1.5 text-sm font-medium",children:($$anchor4,$$slotProps)=>{next$1();var fragment_2=root_3$b(),text2=first_child(fragment_2),node_3=sibling(text2);{var consequent=$$anchor5=>{Flask_conical($$anchor5,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_3,$$render=>{get$3(field).isExperimental&&$$render(consequent)})}
|
|
|
|
|
template_effect(()=>set_text(text2,`${get$3(field).label??""} `)),append($$anchor4,fragment_2)},$$slots:{default:!0}});var node_4=sibling(node_2,2);{var consequent_1=$$anchor4=>{SettingsChatParameterSourceIndicator($$anchor4,{})};if_block(node_4,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_1)})}reset(div_1);var div_2=sibling(div_1,2),node_5=child(div_2);{let $0=user_derived(()=>get$3(sp)[get$3(field).key]!=null?`Default: ${normalizeFloatingPoint(get$3(sp)[get$3(field).key])}`:""),$1=user_derived(
|
|
|
|
|
()=>get$3(isCustomRealTime)?"pr-8":"");Input(node_5,{get id(){return get$3(field).key},get value(){return get$3(currentValue)},oninput:e=>{$$props.onConfigChange(get$3(field).key,e.currentTarget.value)},get placeholder(){return get$3($0)},get class(){return`w-full ${get$3($1)??""}`}})}var node_6=sibling(node_5,2);{var consequent_2=$$anchor4=>{var button=root_6$8(),node_7=child(button);Rotate_ccw(node_7,{class:"h-3 w-3"}),reset(button),delegated("click",button,()=>{settingsStore.resetParameterToServerDefault(
|
|
|
|
|
get$3(field).key),$$props.onConfigChange(get$3(field).key,"")}),append($$anchor4,button)};if_block(node_6,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_2)})}reset(div_2);var node_8=sibling(div_2,2);{var consequent_3=$$anchor4=>{var p_1=root_7$7();html$6(p_1,()=>get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key],!0),reset(p_1),append($$anchor4,p_1)};if_block(node_8,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_3)})}append($$anchor3,fragment_1)},
|
|
|
|
|
consequent_8=$$anchor3=>{var fragment_5=root_8$8(),node_9=first_child(fragment_5);Label(node_9,{get for(){return get$3(field).key},class:"block flex items-center gap-1.5 text-sm font-medium",children:($$anchor4,$$slotProps)=>{next$1();var fragment_6=root_9$5(),text_1=first_child(fragment_6),node_10=sibling(text_1);{var consequent_5=$$anchor5=>{Flask_conical($$anchor5,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_10,$$render=>{get$3(field).isExperimental&&$$render(consequent_5)})}template_effect(
|
|
|
|
|
()=>set_text(text_1,`${get$3(field).label??""} `)),append($$anchor4,fragment_6)},$$slots:{default:!0}});var node_11=sibling(node_9,2);{let $0=user_derived(()=>String($$props.localConfig[get$3(field).key]??""));Textarea(node_11,{get id(){return get$3(field).key},get value(){return get$3($0)},onchange:e=>$$props.onConfigChange(get$3(field).key,e.currentTarget.value),placeholder:"",class:"min-h-[10rem] w-full md:max-w-3xl"})}var node_12=sibling(node_11,2);{var consequent_6=$$anchor4=>{var p_2=root_11$3(),
|
|
|
|
|
text_2=child(p_2,!0);reset(p_2),template_effect(()=>set_text(text_2,get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])),append($$anchor4,p_2)};if_block(node_12,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_6)})}var node_13=sibling(node_12,2);{var consequent_7=$$anchor4=>{var div_3=root_12$2(),node_14=child(div_3);{let $0=user_derived(()=>!!($$props.localConfig.showSystemMessage??!0));Checkbox(node_14,{id:"showSystemMessage",get checked(){return get$3(
|
|
|
|
|
$0)},onCheckedChange:checked=>$$props.onConfigChange("showSystemMessage",!!checked)})}var node_15=sibling(node_14,2);Label(node_15,{for:"showSystemMessage",class:"cursor-pointer text-sm font-normal",children:($$anchor5,$$slotProps)=>{next$1();var text_3=text$8("Show system message in conversations");append($$anchor5,text_3)},$$slots:{default:!0}}),reset(div_3),append($$anchor4,div_3)};if_block(node_13,$$render=>{get$3(field).key===SETTINGS_KEYS.SYSTEM_MESSAGE&&$$render(consequent_7)})}append($$anchor3,
|
|
|
|
|
fragment_5)},consequent_16=$$anchor3=>{const selectedOption=user_derived(()=>get$3(field).options?.find(opt=>opt.value===$$props.localConfig[get$3(field).key])),currentValue=user_derived(()=>$$props.localConfig[get$3(field).key]),serverDefault=user_derived(()=>get$3(sp)[get$3(field).key]),isCustomRealTime=user_derived(()=>get$3(serverDefault)==null||get$3(currentValue)===""||get$3(currentValue)===void 0?!1:get$3(currentValue)!==get$3(serverDefault));var fragment_8=root_14$1(),div_4=first_child(fragment_8),
|
|
|
|
|
node_16=child(div_4);Label(node_16,{get for(){return get$3(field).key},class:"flex items-center gap-1.5 text-sm font-medium",children:($$anchor4,$$slotProps)=>{next$1();var fragment_9=root_15$2(),text_4=first_child(fragment_9),node_17=sibling(text_4);{var consequent_9=$$anchor5=>{Flask_conical($$anchor5,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_17,$$render=>{get$3(field).isExperimental&&$$render(consequent_9)})}template_effect(()=>set_text(text_4,`${get$3(field).label??""} `)),
|
|
|
|
|
append($$anchor4,fragment_9)},$$slots:{default:!0}});var node_18=sibling(node_16,2);{var consequent_10=$$anchor4=>{SettingsChatParameterSourceIndicator($$anchor4,{})};if_block(node_18,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_10)})}reset(div_4);var node_19=sibling(div_4,2);component(node_19,()=>Root,($$anchor4,Select_Root)=>{Select_Root($$anchor4,{type:"single",get value(){return get$3(currentValue)},onValueChange:value=>{get$3(field).key===SETTINGS_KEYS.THEME&&value&&$$props.onThemeChange?
|
|
|
|
|
$$props.onThemeChange(value):$$props.onConfigChange(get$3(field).key,value)},children:($$anchor5,$$slotProps)=>{var fragment_12=root_18$1(),div_5=first_child(fragment_12),node_20=child(div_5);component(node_20,()=>Select_trigger,($$anchor6,Select_Trigger)=>{Select_Trigger($$anchor6,{class:"w-full",children:($$anchor7,$$slotProps2)=>{var div_6=root_19$2(),node_21=child(div_6);{var consequent_11=$$anchor8=>{const IconComponent=user_derived(()=>get$3(selectedOption).icon);var fragment_13=comment$2(),
|
|
|
|
|
node_22=first_child(fragment_13);component(node_22,()=>get$3(IconComponent),($$anchor9,IconComponent_1)=>{IconComponent_1($$anchor9,{class:"h-4 w-4"})}),append($$anchor8,fragment_13)};if_block(node_21,$$render=>{get$3(selectedOption)?.icon&&$$render(consequent_11)})}var text_5=sibling(node_21);reset(div_6),template_effect($0=>set_text(text_5,` ${$0??""}`),[()=>get$3(selectedOption)?.label||`Select ${get$3(field).label.toLowerCase()}`]),append($$anchor7,div_6)},$$slots:{default:!0}})});var node_23=sibling(
|
|
|
|
|
node_20,2);{var consequent_12=$$anchor6=>{var button_1=root_21$1(),node_24=child(button_1);Rotate_ccw(node_24,{class:"h-3 w-3"}),reset(button_1),delegated("click",button_1,()=>{settingsStore.resetParameterToServerDefault(get$3(field).key),$$props.onConfigChange(get$3(field).key,"")}),append($$anchor6,button_1)};if_block(node_23,$$render=>{get$3(isCustomRealTime)&&$$render(consequent_12)})}reset(div_5);var node_25=sibling(div_5,2);component(node_25,()=>Select_content,($$anchor6,Select_Content)=>{
|
|
|
|
|
Select_Content($$anchor6,{children:($$anchor7,$$slotProps2)=>{var fragment_14=comment$2(),node_26=first_child(fragment_14);{var consequent_14=$$anchor8=>{var fragment_15=comment$2(),node_27=first_child(fragment_15);each(node_27,17,()=>get$3(field).options,option2=>option2.value,($$anchor9,option2)=>{var fragment_16=comment$2(),node_28=first_child(fragment_16);component(node_28,()=>Select_item,($$anchor10,Select_Item)=>{Select_Item($$anchor10,{get value(){return get$3(option2).value},get label(){
|
|
|
|
|
return get$3(option2).label},children:($$anchor11,$$slotProps3)=>{var div_7=root_25$1(),node_29=child(div_7);{var consequent_13=$$anchor12=>{const IconComponent=user_derived(()=>get$3(option2).icon);var fragment_17=comment$2(),node_30=first_child(fragment_17);component(node_30,()=>get$3(IconComponent),($$anchor13,IconComponent_2)=>{IconComponent_2($$anchor13,{class:"h-4 w-4"})}),append($$anchor12,fragment_17)};if_block(node_29,$$render=>{get$3(option2).icon&&$$render(consequent_13)})}var text_6=sibling(
|
|
|
|
|
node_29);reset(div_7),template_effect(()=>set_text(text_6,` ${get$3(option2).label??""}`)),append($$anchor11,div_7)},$$slots:{default:!0}})}),append($$anchor9,fragment_16)}),append($$anchor8,fragment_15)};if_block(node_26,$$render=>{get$3(field).options&&$$render(consequent_14)})}append($$anchor7,fragment_14)},$$slots:{default:!0}})}),append($$anchor5,fragment_12)},$$slots:{default:!0}})});var node_31=sibling(node_19,2);{var consequent_15=$$anchor4=>{var p_3=root_27(),text_7=child(p_3,!0);reset(
|
|
|
|
|
p_3),template_effect(()=>set_text(text_7,get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])),append($$anchor4,p_3)};if_block(node_31,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_15)})}append($$anchor3,fragment_8)},consequent_19=$$anchor3=>{var div_8=root_28(),node_32=child(div_8);{let $0=user_derived(()=>!!$$props.localConfig[get$3(field).key]);Checkbox(node_32,{get id(){return get$3(field).key},get checked(){return get$3($0)},onCheckedChange:checked=>$$props.
|
|
|
|
|
onConfigChange(get$3(field).key,checked),class:"mt-1"})}var div_9=sibling(node_32,2),label=child(div_9),text_8=child(label),node_33=sibling(text_8);{var consequent_17=$$anchor4=>{Flask_conical($$anchor4,{class:"h-3.5 w-3.5 text-muted-foreground"})};if_block(node_33,$$render=>{get$3(field).isExperimental&&$$render(consequent_17)})}reset(label);var node_34=sibling(label,2);{var consequent_18=$$anchor4=>{var p_4=root_30(),text_9=child(p_4,!0);reset(p_4),template_effect(()=>set_text(text_9,get$3(field).
|
|
|
|
|
help||SETTING_CONFIG_INFO[get$3(field).key])),append($$anchor4,p_4)};if_block(node_34,$$render=>{(get$3(field).help||SETTING_CONFIG_INFO[get$3(field).key])&&$$render(consequent_18)})}reset(div_9),reset(div_8),template_effect(()=>{set_attribute(label,"for",get$3(field).key),set_text(text_8,`${get$3(field).label??""} `)}),append($$anchor3,div_8)};if_block(node_1,$$render=>{get$3(field).type===SettingsFieldType.INPUT?$$render(consequent_4):get$3(field).type===SettingsFieldType.TEXTAREA?$$render(consequent_8,
|
|
|
|
|
1):get$3(field).type===SettingsFieldType.SELECT?$$render(consequent_16,2):get$3(field).type===SettingsFieldType.CHECKBOX&&$$render(consequent_19,3)})}reset(div),append($$anchor2,div)}),append($$anchor,fragment),pop()}delegate(["click"]);var root_1$9=from_html('<div class="py-8 text-center text-sm text-muted-foreground">No tools available</div>'),root_5$7=from_html('<!> <span class="inline-flex min-w-0 items-center gap-1.5 font-medium"><!></span> <span class="ml-auto shrink-0 text-xs text-muted-f\
|
|
|
|
|
oreground"> </span>',1),root_9$4=from_html('<div class="flex items-center gap-2 rounded px-2 py-1.5 text-sm hover:bg-muted/50"><!> <div class="flex w-16 shrink-0 justify-center"><!></div> <div class="flex w-20 shrink-0 justify-center"><!></div></div>'),root_8$7=from_html('<div class="ml-4 border-l border-border/50 pl-2"><div class="flex items-center gap-2 px-2 py-1 text-xs text-muted-foreground"><span class="min-w-0 flex-1">Tool</span> <span class="w-16 shrink-0 text-center">Enabled</span> <span\
|
|
|
|
|
class="w-20 shrink-0 text-center">Always allow</span></div> <!></div>'),root_4$8=from_html("<!> <!>",1),root_2$g=from_html('<div class="space-y-2"></div>');function SettingsChatToolsTab($$anchor,$$props){push$1($$props,!0);let expandedGroups=new SvelteSet,groups=user_derived(()=>toolsStore.toolGroups);function toggleExpanded(label){expandedGroups.has(label)?expandedGroups.delete(label):expandedGroups.add(label)}var fragment=comment$2(),node2=first_child(fragment);{var consequent=$$anchor2=>{var div=root_1$9();
|
|
|
|
|
append($$anchor2,div)},alternate_1=$$anchor2=>{var div_1=root_2$g();each(div_1,21,()=>get$3(groups),group=>group.label,($$anchor3,group)=>{const isExpanded=user_derived(()=>expandedGroups.has(get$3(group).label));var fragment_1=comment$2(),node_1=first_child(fragment_1);component(node_1,()=>Collapsible,($$anchor4,Collapsible_Root)=>{Collapsible_Root($$anchor4,{get open(){return get$3(isExpanded)},onOpenChange:()=>toggleExpanded(get$3(group).label),children:($$anchor5,$$slotProps)=>{var fragment_2=root_4$8(),
|
|
|
|
|
node_2=first_child(fragment_2);component(node_2,()=>Collapsible_trigger,($$anchor6,Collapsible_Trigger)=>{Collapsible_Trigger($$anchor6,{class:"flex w-full items-center gap-2 rounded-lg px-3 py-2 text-sm hover:bg-muted/50",children:($$anchor7,$$slotProps2)=>{const faviconUrl=user_derived(()=>get$3(group).serverId?mcpStore.getServerFavicon(get$3(group).serverId):null);var fragment_3=root_5$7(),node_3=first_child(fragment_3);{var consequent_1=$$anchor8=>{Chevron_down($$anchor8,{class:"h-3.5 w-3.5 \
|
|
|
|
|
shrink-0"})},alternate=$$anchor8=>{Chevron_right($$anchor8,{class:"h-3.5 w-3.5 shrink-0"})};if_block(node_3,$$render=>{get$3(isExpanded)?$$render(consequent_1):$$render(alternate,-1)})}var span=sibling(node_3,2),node_4=child(span);McpServerIdentity(node_4,{iconClass:"h-4 w-4",iconRounded:"rounded-sm",showVersion:!1,get displayName(){return get$3(group).label},get faviconUrl(){return get$3(faviconUrl)}}),reset(span);var span_1=sibling(span,2),text2=child(span_1);reset(span_1),template_effect(()=>set_text(
|
|
|
|
|
text2,`${get$3(group).tools.length??""} tool${get$3(group).tools.length!==1?"s":""}`)),append($$anchor7,fragment_3)},$$slots:{default:!0}})});var node_5=sibling(node_2,2);component(node_5,()=>Collapsible_content,($$anchor6,Collapsible_Content)=>{Collapsible_Content($$anchor6,{children:($$anchor7,$$slotProps2)=>{var div_2=root_8$7(),node_6=sibling(child(div_2),2);each(node_6,17,()=>get$3(group).tools,tool=>tool.function.name,($$anchor8,tool)=>{const toolName=user_derived(()=>get$3(tool).function.
|
|
|
|
|
name),isEnabled=user_derived(()=>toolsStore.isToolEnabled(get$3(toolName))),permissionKey=user_derived(()=>toolsStore.getPermissionKey(get$3(toolName))),isAlwaysAllowed=user_derived(()=>get$3(permissionKey)?permissionsStore.hasTool(get$3(permissionKey)):!1);var div_3=root_9$4(),node_7=child(div_3);TruncatedText(node_7,{get text(){return get$3(toolName)},class:"flex-1",showTooltip:!0});var div_4=sibling(node_7,2),node_8=child(div_4);Checkbox(node_8,{get checked(){return get$3(isEnabled)},onCheckedChange:()=>toolsStore.
|
|
|
|
|
toggleTool(get$3(toolName)),class:"h-4 w-4"}),reset(div_4);var div_5=sibling(div_4,2),node_9=child(div_5);Checkbox(node_9,{get checked(){return get$3(isAlwaysAllowed)},onCheckedChange:()=>{get$3(isAlwaysAllowed)?permissionsStore.revokeTool(get$3(permissionKey)):permissionsStore.allowTool(get$3(permissionKey))},class:"h-4 w-4"}),reset(div_5),reset(div_3),append($$anchor8,div_3)}),reset(div_2),append($$anchor7,div_2)},$$slots:{default:!0}})}),append($$anchor5,fragment_2)},$$slots:{default:!0}})}),
|
|
|
|
|
append($$anchor3,fragment_1)}),reset(div_1),append($$anchor2,div_1)};if_block(node2,$$render=>{get$3(groups).length===0?$$render(consequent):$$render(alternate_1,-1)})}append($$anchor,fragment),pop()}const summaryList=($$anchor,show=noop$3,verb=noop$3,items2=noop$3)=>{var fragment=comment$2(),node2=first_child(fragment);{var consequent_1=$$anchor2=>{var div=root_2$f(),h5=child(div),text_1=child(h5);reset(h5);var ul=sibling(h5,2),node_1=child(ul);each(node_1,17,()=>items2().slice(0,10),conv=>conv.
|
|
|
|
|
id,($$anchor3,conv)=>{var li2=root_3$a(),text_2=child(li2);reset(li2),template_effect(()=>set_text(text_2,`• ${(get$3(conv).name||"Untitled conversation")??""}`)),append($$anchor3,li2)});var node_2=sibling(node_1,2);{var consequent=$$anchor3=>{var li_1=root_4$7(),text_3=child(li_1);reset(li_1),template_effect(()=>set_text(text_3,`... and ${items2().length-10} more`)),append($$anchor3,li_1)};if_block(node_2,$$render=>{items2().length>10&&$$render(consequent)})}reset(ul),reset(div),template_effect(
|
|
|
|
|
()=>set_text(text_1,`${verb()??""}
|
|
|
|
|
${items2().length??""} conversation${items2().length===1?"":"s"}`)),append($$anchor2,div)};if_block(node2,$$render=>{show()&&items2().length>0&&$$render(consequent_1)})}append($$anchor,fragment)},section=($$anchor,title2=noop$3,description2=noop$3,IconComponent=noop$3,buttonText=noop$3,onclick=noop$3,opts=noop$3)=>{const buttonClass=user_derived(()=>opts()?.buttonClass??"justify-start justify-self-start md:w-auto"),buttonVariant=user_derived(()=>opts()?.buttonVariant??"outline");var div_1=root_5$6(),
|
|
|
|
|
h4=child(div_1),text_4=child(h4,!0);reset(h4);var p2=sibling(h4,2),text_5=child(p2,!0);reset(p2);var node_3=sibling(p2,2);Button(node_3,{get class(){return get$3(buttonClass)},get onclick(){return onclick()},get variant(){return get$3(buttonVariant)},children:($$anchor2,$$slotProps)=>{var fragment_1=root_6$7(),node_4=first_child(fragment_1);component(node_4,IconComponent,($$anchor3,IconComponent_1)=>{IconComponent_1($$anchor3,{class:"mr-2 h-4 w-4"})});var text_6=sibling(node_4);template_effect(()=>set_text(
|
|
|
|
|
text_6,` ${buttonText()??""}`)),append($$anchor2,fragment_1)},$$slots:{default:!0}});var node_5=sibling(node_3,2);{var consequent_2=$$anchor2=>{summaryList($$anchor2,()=>opts().summary.show,()=>opts().summary.verb,()=>opts().summary.items)};if_block(node_5,$$render=>{opts()?.summary&&$$render(consequent_2)})}reset(div_1),template_effect(()=>{set_class(div_1,1,`grid gap-1 ${opts()?.wrapperClass??""??""}`),set_class(h4,1,`mt-0 mb-2 text-sm font-medium ${opts()?.titleClass??""??""}`),set_text(text_4,
|
|
|
|
|
|