import{j as e}from"./vendor-react-Dp9pL_Wn.js";import{C as t,R as n}from"./c70a3d12b-KRRwGjFX.js";import{bU as o}from"./c6eedc03a-CsEFTfjy.js";import{C as r}from"./c5669b8e4-DFSq88jr.js";import{c as a,o as s}from"./vendor-ant-cds-bBedrtIN.js";import{aR as i,aS as l,aT as d,aU as c,aV as m,Y as u,W as p,Z as b,_ as f,E as x}from"./vendor-radix-Ch96tRrt.js";const g=n,h=t,y=s("\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 w({label:t,checked:n,description:o,checkboxStyle:r,textClassName:s,closeOnSelect:i,onSelect:l,size:d="md",...c}){return e.jsxs(x,{className:y({size:d}),onSelect:e=>{l(),i||e.preventDefault()},...c,role:"square"===r?"menuitemcheckbox":"menuitemradio","aria-checked":n,children:[e.jsxs("div",{className:"flex shrink grow basis-0 flex-col justify-start gap-1",children:[e.jsx("div",{className:a("font-normal",s),children:t}),o&&e.jsx("div",{className:a("text-text-300 text-xs",s),children:o})]}),r&&("square"===r?e.jsx(h,{checked:n}):e.jsx(g,{checked:n}))]})}const v=s("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=s("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 j({label:t,avoidCollisions:n,align:s="start",side:x="bottom",scroll:g=!0,sideOffset:h,children:y,className:w,menuContentClassName:j,scrollAreaViewPortClassName:_,disabled:F=!1,size:N="md",type:A="primary",testId:z,id:C,matchWidth:S,open:B,onOpenChange:E,footer:I}){const D=o(),q=g?e.jsxs(i,{className:"w-[100%] overflow-hidden",type:"auto",children:[e.jsx(l,{className:a("inline-flex max-h-[16rem] w-[100%] items-start justify-start gap-2 p-2",_),role:"menu",children:e.jsx("div",{className:"flex shrink grow basis-0 flex-col items-start justify-start",children:y})}),e.jsx(d,{className:"h-[100%] w-2",orientation:"vertical",children:e.jsx(c,{className:"bg-bg-200 rounded-full"})}),e.jsx(m,{className:"ScrollAreaCorner"})]}):e.jsx("div",{className:"flex shrink grow basis-0 flex-col items-start justify-start p-2",children:y});return e.jsxs(u,{open:B,onOpenChange:E,children:[e.jsx(p,{asChild:!0,disabled:F,children:e.jsxs("button",{id:C,className:v({size:N,type:A,className:w}),"data-testid":z,children:[t,e.jsx(r,{className:"text-text-500 translate-y-[0.5px]",size:"sm"===N?12:16})]})}),e.jsx(b,{children:e.jsx(f,{sideOffset:h??4,className:a(j,k({size:N,type:A,overflow:g&&!I?"scroll":"expand"})),style:{width:S?"var(--radix-dropdown-menu-trigger-width)":void 0,zIndex:D},avoidCollisions:n,align:s,side:x,asChild:!0,children:I?e.jsxs("div",{className:"flex flex-col overflow-hidden",children:[q,e.jsx("div",{className:"border-t border-border-300 p-2",children:I})]}):q})})]})}
/*!-----------------------------------------------------------------------------
 * 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
 *-----------------------------------------------------------------------------*/
/*!---------------------------------------------------------------------------------------------
 *  Copyright (C) David Owens II, owensd.io. All rights reserved.
 *--------------------------------------------------------------------------------------------*/
const _=Object.freeze(Object.defineProperty({__proto__:null,conf:{comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}]},language:{defaultToken:"",tokenPostfix:".swift",identifier:/[a-zA-Z_][\w$]*/,attributes:["@GKInspectable","@IBAction","@IBDesignable","@IBInspectable","@IBOutlet","@IBSegueAction","@NSApplicationMain","@NSCopying","@NSManaged","@Sendable","@UIApplicationMain","@autoclosure","@actorIndependent","@asyncHandler","@available","@convention","@derivative","@differentiable","@discardableResult","@dynamicCallable","@dynamicMemberLookup","@escaping","@frozen","@globalActor","@inlinable","@inline","@main","@noDerivative","@nonobjc","@noreturn","@objc","@objcMembers","@preconcurrency","@propertyWrapper","@requires_stored_property_inits","@resultBuilder","@testable","@unchecked","@unknown","@usableFromInline","@warn_unqualified_access"],accessmodifiers:["open","public","internal","fileprivate","private"],keywords:["#available","#colorLiteral","#column","#dsohandle","#else","#elseif","#endif","#error","#file","#fileID","#fileLiteral","#filePath","#function","#if","#imageLiteral","#keyPath","#line","#selector","#sourceLocation","#warning","Any","Protocol","Self","Type","actor","as","assignment","associatedtype","associativity","async","await","break","case","catch","class","continue","convenience","default","defer","deinit","didSet","do","dynamic","dynamicType","else","enum","extension","fallthrough","false","fileprivate","final","for","func","get","guard","higherThan","if","import","in","indirect","infix","init","inout","internal","is","isolated","lazy","left","let","lowerThan","mutating","nil","none","nonisolated","nonmutating","open","operator","optional","override","postfix","precedence","precedencegroup","prefix","private","protocol","public","repeat","required","rethrows","return","right","safe","self","set","some","static","struct","subscript","super","switch","throw","throws","true","try","typealias","unowned","unsafe","var","weak","where","while","willSet","__consuming","__owned"],symbols:/[=(){}\[\].,:;@#\_&\-<>`?!+*\\\/]/,operatorstart:/[\/=\-+!*%<>&|^~?\u00A1-\u00A7\u00A9\u00AB\u00AC\u00AE\u00B0-\u00B1\u00B6\u00BB\u00BF\u00D7\u00F7\u2016-\u2017\u2020-\u2027\u2030-\u203E\u2041-\u2053\u2055-\u205E\u2190-\u23FF\u2500-\u2775\u2794-\u2BFF\u2E00-\u2E7F\u3001-\u3003\u3008-\u3030]/,operatorend:/[\u0300-\u036F\u1DC0-\u1DFF\u20D0-\u20FF\uFE00-\uFE0F\uFE20-\uFE2F\uE0100-\uE01EF]/,operators:/(@operatorstart)((@operatorstart)|(@operatorend))*/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[{include:"@whitespace"},{include:"@comment"},{include:"@attribute"},{include:"@literal"},{include:"@keyword"},{include:"@invokedmethod"},{include:"@symbol"}],whitespace:[[/\s+/,"white"],[/"""/,"string.quote","@endDblDocString"]],endDblDocString:[[/[^"]+/,"string"],[/\\"/,"string"],[/"""/,"string.quote","@popall"],[/"/,"string"]],symbol:[[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/[.]/,"delimiter"],[/@operators/,"operator"],[/@symbols/,"operator"]],comment:[[/\/\/\/.*$/,"comment.doc"],[/\/\*\*/,"comment.doc","@commentdocbody"],[/\/\/.*$/,"comment"],[/\/\*/,"comment","@commentbody"]],commentdocbody:[[/\/\*/,"comment","@commentbody"],[/\*\//,"comment.doc","@pop"],[/\:[a-zA-Z]+\:/,"comment.doc.param"],[/./,"comment.doc"]],commentbody:[[/\/\*/,"comment","@commentbody"],[/\*\//,"comment","@pop"],[/./,"comment"]],attribute:[[/@@@identifier/,{cases:{"@attributes":"keyword.control","@default":""}}]],literal:[[/"/,{token:"string.quote",next:"@stringlit"}],[/0[b]([01]_?)+/,"number.binary"],[/0[o]([0-7]_?)+/,"number.octal"],[/0[x]([0-9a-fA-F]_?)+([pP][\-+](\d_?)+)?/,"number.hex"],[/(\d_?)*\.(\d_?)+([eE][\-+]?(\d_?)+)?/,"number.float"],[/(\d_?)+/,"number"]],stringlit:[[/\\\(/,{token:"operator",next:"@interpolatedexpression"}],[/@escapes/,"string"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",next:"@pop"}],[/./,"string"]],interpolatedexpression:[[/\(/,{token:"operator",next:"@interpolatedexpression"}],[/\)/,{token:"operator",next:"@pop"}],{include:"@literal"},{include:"@keyword"},{include:"@symbol"}],keyword:[[/`/,{token:"operator",next:"@escapedkeyword"}],[/@identifier/,{cases:{"@keywords":"keyword","[A-Z][a-zA-Z0-9$]*":"type.identifier","@default":"identifier"}}]],escapedkeyword:[[/`/,{token:"operator",next:"@pop"}],[/./,"identifier"]],invokedmethod:[[/([.])(@identifier)/,{cases:{$2:["delimeter","type.identifier"],"@default":""}}]]}}},Symbol.toStringTag,{value:"Module"}));export{w as I,j as R,_ as s};
