22// SPDX-License-Identifier: Apache-2.0
33
44import { ContextMenuModel } from "@/app/store/contextmenu" ;
5- import { useAtom , useAtomValue } from "jotai" ;
5+ import { useAtomValue } from "jotai" ;
66import { memo } from "react" ;
77import { WaveAIModel } from "./waveai-model" ;
88
@@ -14,18 +14,6 @@ interface AIPanelHeaderProps {
1414
1515export const AIPanelHeader = memo ( ( { onClose, model, onClearChat } : AIPanelHeaderProps ) => {
1616 const widgetAccess = useAtomValue ( model . widgetAccessAtom ) ;
17- const currentModel = useAtomValue ( model . modelAtom ) ;
18-
19- const modelOptions = [
20- { value : "gpt-5" , label : "GPT-5" } ,
21- { value : "gpt-5-mini" , label : "GPT-5 Mini" } ,
22- { value : "claude-sonnet-4-5" , label : "Claude Sonnet 4.5" } ,
23- ] ;
24-
25- const getModelLabel = ( modelValue : string ) : string => {
26- const option = modelOptions . find ( ( opt ) => opt . value === modelValue ) ;
27- return option ?. label ?? modelValue ;
28- } ;
2917
3018 const handleKebabClick = ( e : React . MouseEvent ) => {
3119 const menu : ContextMenuItem [ ] = [
@@ -36,18 +24,6 @@ export const AIPanelHeader = memo(({ onClose, model, onClearChat }: AIPanelHeade
3624 } ,
3725 } ,
3826 { type : "separator" } ,
39- {
40- label : `Model (${ getModelLabel ( currentModel ) } )` ,
41- submenu : modelOptions . map ( ( option ) => ( {
42- label : option . label ,
43- type : currentModel === option . value ? "checkbox" : undefined ,
44- checked : currentModel === option . value ,
45- click : ( ) => {
46- model . setModel ( option . value ) ;
47- } ,
48- } ) ) ,
49- } ,
50- { type : "separator" } ,
5127 {
5228 label : "Hide Wave AI" ,
5329 click : ( ) => {
0 commit comments