import{j as e}from"./vendor-react-AXa6hZO5.js";import{C as t,R as s}from"./cac5c74b6-rVnpYxj6.js";import{aj as n}from"./index-C_tZnXTW.js";import{n as r,f as o}from"./cec18ad9a-DiLjrOUd.js";import{ad as a,ae as i,af as l,ag as d,ah as c,ai as m,aj as p,ak as f,al as u,O as x}from"./vendor-radix-glKlawmm.js";const b=s,_=t,g=o("\n  self-stretch\n  px-2\n  py-3\n  rounded\n  cursor-pointer\n  justify-start\n  overflow-hidden\n  text-ellipsis\n  text-text-100\n  grid\n  grid-cols-[minmax(0,_1fr)_auto]\n  inline-flex\n  gap-4\n  items-center\n  outline-none\n  select-none\n  hover:bg-bg-500\n  hover:text-text-000\n  can-focus\n  [&[data-disabled]]:opacity-50\n  [&[data-disabled]]:bg-bg-100\n  [&[data-disabled]]:cursor-default\n",{variants:{size:{sm:"text-xs",md:"text-sm",lg:""}},defaultVariants:{size:"md"}});function h({label:t,checked:s,description:n,checkboxStyle:o,textClassName:a,closeOnSelect:i,onSelect:l,size:d="md",...c}){return e.jsxs(x,{className:g({size:d}),onSelect:e=>{l(),i||e.preventDefault()},...c,role:"square"===o?"menuitemcheckbox":"menuitemradio","aria-checked":s,children:[e.jsxs("div",{className:"flex shrink grow basis-0 flex-col justify-start gap-1",children:[e.jsx("div",{className:r("font-normal",a),children:t}),n&&e.jsx("div",{className:r("text-text-300 text-xs",a),children:n})]}),o&&("square"===o?e.jsx(_,{checked:s}):e.jsx(b,{checked:s}))]})}const y=o("transition-colors\n  justify-between\n  items-center\n  inline-flex\n  text-left\n  text-text-100\n  hover:border-border-100\n  border\n  border-border-200\n  [&[data-disabled]]:opacity-50\n  [&[data-disabled]]:cursor-not-allowed\n  [&[data-disabled]]:!text-text-500\n  data-[state=open]:border-accent-100\n  can-focus",{variants:{size:{sm:"h-8 rounded-md pl-2 pr-1.5 text-xs gap-1",md:"h-9 pl-3 pr-2.5 py-2 rounded-lg text-sm gap-1",lg:"h-11 pl-3 pr-2.5 rounded-[0.6rem] gap-1.5"},type:{primary:"bg-bg-000 border-border-200",secondary:"bg-bg-500 border-border-300",ghost:"text-text-200 transition-all active:bg-bg-400 hover:bg-bg-300 hover:text-text-100"}},defaultVariants:{size:"md",type:"primary"}}),k=o("z-dropdown\n  flex\n  flex-col\n  border-0.5\n  border-border-300\n  rounded-lg\n  text-text-200\n  shadow-element",{variants:{size:{sm:"min-w-[13rem]",md:"min-w-[15rem]",lg:"min-w-[18rem]"},type:{primary:"bg-bg-000",secondary:"bg-bg-200",ghost:"bg-bg-200"},overflow:{scroll:"max-h-[16rem]",expand:""}},defaultVariants:{size:"md",type:"primary",overflow:"expand"}});function w({label:t,avoidCollisions:s,align:o="start",side:x="bottom",scroll:b=!0,sideOffset:_,children:g,className:h,menuContentClassName:w,scrollAreaViewPortClassName:S,disabled:v=!1,size:j="md",type:N="primary",testId:E,id:I,matchWidth:O,open:R,onOpenChange:z,footer:C}){const F=b?e.jsxs(a,{className:"w-[100%] overflow-hidden",type:"auto",children:[e.jsx(i,{className:r("inline-flex max-h-[16rem] w-[100%] items-start justify-start gap-2 p-2",S),role:"menu",children:e.jsx("div",{className:"flex shrink grow basis-0 flex-col items-start justify-start",children:g})}),e.jsx(l,{className:"h-[100%] w-2",orientation:"vertical",children:e.jsx(d,{className:"bg-bg-200 rounded-full"})}),e.jsx(c,{className:"ScrollAreaCorner"})]}):e.jsx("div",{className:"flex shrink grow basis-0 flex-col items-start justify-start p-2",children:g});return e.jsxs(m,{open:R,onOpenChange:z,children:[e.jsx(p,{asChild:!0,disabled:v,children:e.jsxs("button",{id:I,className:y({size:j,type:N,className:h}),"data-testid":E,children:[t,e.jsx(n,{className:"text-text-500 translate-y-[0.5px]",size:"sm"===j?12:16})]})}),e.jsx(f,{children:e.jsx(u,{sideOffset:_??4,className:r(w,k({size:j,type:N,overflow:b&&!C?"scroll":"expand"})),style:{width:O?"var(--radix-dropdown-menu-trigger-width)":void 0},avoidCollisions:s,align:o,side:x,asChild:!0,children:C?e.jsxs("div",{className:"flex flex-col overflow-hidden",children:[F,e.jsx("div",{className:"border-t border-border-300 p-2",children:C})]}):F})})]})}
/*!-----------------------------------------------------------------------------
 * Copyright (c) Microsoft Corporation. All rights reserved.
 * Version: 0.52.2(404545bded1df6ffa41ea0af4e8ddb219018c6c1)
 * Released under the MIT license
 * https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt
 *-----------------------------------------------------------------------------*/var S={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}};const v=Object.freeze(Object.defineProperty({__proto__:null,conf:S,language:{tokenPostfix:".rust",defaultToken:"invalid",keywords:["as","async","await","box","break","const","continue","crate","dyn","else","enum","extern","false","fn","for","if","impl","in","let","loop","match","mod","move","mut","pub","ref","return","self","static","struct","super","trait","true","try","type","unsafe","use","where","while","catch","default","union","static","abstract","alignof","become","do","final","macro","offsetof","override","priv","proc","pure","sizeof","typeof","unsized","virtual","yield"],typeKeywords:["Self","m32","m64","m128","f80","f16","f128","int","uint","float","char","bool","u8","u16","u32","u64","f32","f64","i8","i16","i32","i64","str","Option","Either","c_float","c_double","c_void","FILE","fpos_t","DIR","dirent","c_char","c_schar","c_uchar","c_short","c_ushort","c_int","c_uint","c_long","c_ulong","size_t","ptrdiff_t","clock_t","time_t","c_longlong","c_ulonglong","intptr_t","uintptr_t","off_t","dev_t","ino_t","pid_t","mode_t","ssize_t"],constants:["true","false","Some","None","Left","Right","Ok","Err"],supportConstants:["EXIT_FAILURE","EXIT_SUCCESS","RAND_MAX","EOF","SEEK_SET","SEEK_CUR","SEEK_END","_IOFBF","_IONBF","_IOLBF","BUFSIZ","FOPEN_MAX","FILENAME_MAX","L_tmpnam","TMP_MAX","O_RDONLY","O_WRONLY","O_RDWR","O_APPEND","O_CREAT","O_EXCL","O_TRUNC","S_IFIFO","S_IFCHR","S_IFBLK","S_IFDIR","S_IFREG","S_IFMT","S_IEXEC","S_IWRITE","S_IREAD","S_IRWXU","S_IXUSR","S_IWUSR","S_IRUSR","F_OK","R_OK","W_OK","X_OK","STDIN_FILENO","STDOUT_FILENO","STDERR_FILENO"],supportMacros:["format!","print!","println!","panic!","format_args!","unreachable!","write!","writeln!"],operators:["!","!=","%","%=","&","&=","&&","*","*=","+","+=","-","-=","->",".","..","...","/","/=",":",";","<<","<<=","<","<=","=","==","=>",">",">=",">>",">>=","@","^","^=","|","|=","||","_","?","#"],escapes:/\\([nrt0\"''\\]|x\h{2}|u\{\h{1,6}\})/,delimiters:/[,]/,symbols:/[\#\!\%\&\*\+\-\.\/\:\;\<\=\>\@\^\|_\?]+/,intSuffixes:/[iu](8|16|32|64|128|size)/,floatSuffixes:/f(32|64)/,tokenizer:{root:[[/r(#*)"/,{token:"string.quote",bracket:"@open",next:"@stringraw.$1"}],[/[a-zA-Z][a-zA-Z0-9_]*!?|_[a-zA-Z0-9_]+/,{cases:{"@typeKeywords":"keyword.type","@keywords":"keyword","@supportConstants":"keyword","@supportMacros":"keyword","@constants":"keyword","@default":"identifier"}}],[/\$/,"identifier"],[/'[a-zA-Z_][a-zA-Z0-9_]*(?=[^\'])/,"identifier"],[/'(\S|@escapes)'/,"string.byteliteral"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}],{include:"@numbers"},{include:"@whitespace"},[/@delimiters/,{cases:{"@keywords":"keyword","@default":"delimiter"}}],[/[{}()\[\]<>]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],stringraw:[[/[^"#]+/,{token:"string"}],[/"(#*)/,{cases:{"$1==$S2":{token:"string.quote",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["#]/,{token:"string"}]],numbers:[[/(0o[0-7_]+)(@intSuffixes)?/,{token:"number"}],[/(0b[0-1_]+)(@intSuffixes)?/,{token:"number"}],[/[\d][\d_]*(\.[\d][\d_]*)?[eE][+-][\d_]+(@floatSuffixes)?/,{token:"number"}],[/\b(\d\.?[\d_]*)(@floatSuffixes)?\b/,{token:"number"}],[/(0x[\da-fA-F]+)_?(@intSuffixes)?/,{token:"number"}],[/[\d][\d_]*(@intSuffixes?)?/,{token:"number"}]]}}},Symbol.toStringTag,{value:"Module"}));export{h as I,w as R,v as r};
