statement_block
{ "{"
lexical_declaration
const "const"
variable_declarator
object_pattern
{ "{"
shorthand_property_identifier_pattern "setErrorData"
} "}"
= "="
call_expression
identifier "useAlertStore"
arguments
( "("
) ")"
; ";"
lexical_declaration
const "const"
variable_declarator
identifier "refButton"
= "="
call_expression
identifier "useRef"
type_arguments
< "<"
type_identifier "HTMLButtonElement"
> ">"
arguments
( "("
null "null"
) ")"
; ";"
lexical_declaration
const "const"
variable_declarator
array_pattern
[ "["
identifier "open"
, ","
identifier "setOpen"
] "]"
= "="
call_expression
identifier "useState"
arguments
( "("
false "false"
) ")"
; ";"
lexical_declaration
const "const"
variable_declarator
array_pattern
[ "["
identifier "refreshOptions"
, ","
identifier "setRefreshOptions"
] "]"
= "="
call_expression
identifier "useState"
arguments
( "("
false "false"
) ")"
; ";"
lexical_declaration (+26 nodes collapsed)
lexical_declaration
const "const"
variable_declarator
array_pattern
[ "["
identifier "openManageProvidersDialog"
, ","
identifier "setOpenManageProvidersDialog"
] "]"
= "="
call_expression
identifier "useState"
arguments
( "("
false "false"
) ")"
; ";"
comment "// Ref to track if we've already processed the empty options"...
comment "// Prevents infinite loop when no models are available"
lexical_declaration
const "const"
variable_declarator
identifier "hasProcessedEmptyRef"
= "="
call_expression
identifier "useRef"
arguments
( "("
false "false"
) ")"
; ";"
lexical_declaration (+46 nodes collapsed)
lexical_declaration (+36 nodes collapsed)
lexical_declaration (+25 nodes collapsed)
comment "// Determines if we should show the model selector or the \"S"...
lexical_declaration (+47 nodes collapsed)
comment "// Groups models by their provider name for sectioned displa"...
comment "// Filters out models from disabled providers."
lexical_declaration (+117 nodes collapsed)
comment "// Flattened array of all enabled options for efficient look"...
lexical_declaration (+38 nodes collapsed)
comment "// Sync local selectedModel state with the external value pr"...
comment "// Handles three cases: no available models (clear selection"...
comment "// or current value is invalid/missing (select first availab"...
expression_statement (+356 nodes collapsed)
comment "/**\n * Handles model selection from the dropdown.\n * Con"...
lexical_declaration (+180 nodes collapsed)
comment "/**\n * Triggers a refresh of available model options from "...
lexical_declaration (+101 nodes collapsed)
lexical_declaration (+39 nodes collapsed)
lexical_declaration (+582 nodes collapsed)
lexical_declaration (+57 nodes collapsed)
lexical_declaration (+78 nodes collapsed)
comment "// Renders either a \"Setup Provider\" button (no providers) o"...
lexical_declaration (+401 nodes collapsed)
lexical_declaration
const "const"
variable_declarator
identifier "footerButtonClass"
= "="
string
" "\""
string_fragment "w-full flex cursor-pointer items-center justify-start gap-2 "...
" "\""
; ";"
lexical_declaration (+118 nodes collapsed)
lexical_declaration (+362 nodes collapsed)
lexical_declaration
const "const"
variable_declarator
identifier "renderManageProvidersButton"
= "="
arrow_function
formal_parameters
( "("
) ")"
=> "=>"
parenthesized_expression
( "("
jsx_element
jsx_opening_element
< "<"
identifier "div"
jsx_attribute
property_identifier "className"
= "="
string
" "\""
string_fragment "sticky bottom-0 bg-background"
" "\""
> ">"
jsx_expression (+25 nodes collapsed)
jsx_expression (+91 nodes collapsed)
jsx_expression (+35 nodes collapsed)
jsx_closing_element
</ "</"
identifier "div"
> ">"
) ")"
; ";"
lexical_declaration (+49 nodes collapsed)
lexical_declaration (+126 nodes collapsed)
comment "// Loading state"
if_statement (+50 nodes collapsed)
comment "// Main render"
return_statement (+108 nodes collapsed)
} "}"