diff --git a/webui/package-lock.json b/webui/package-lock.json index cd6b0ea..7e5610c 100644 --- a/webui/package-lock.json +++ b/webui/package-lock.json @@ -31,7 +31,6 @@ "@testing-library/jest-dom": "^6.9.1", "@testing-library/react": "^16.3.0", "@testing-library/user-event": "^14.6.1", - "@types/eslint__js": "^9.14.0", "@types/node": "^24.10.1", "@types/react": "^19.2.4", "@types/react-dom": "^19.2.3", @@ -2557,17 +2556,6 @@ "dev": true, "license": "MIT" }, - "node_modules/@types/eslint__js": { - "version": "9.14.0", - "resolved": "https://registry.npmjs.org/@types/eslint__js/-/eslint__js-9.14.0.tgz", - "integrity": "sha512-s0jepCjOJWB/GKcuba4jISaVpBudw3ClXJ3fUK4tugChUMQsp6kSwuA8Dcx6wFd/JsJqcY8n4rEpa5RTHs5ypA==", - "deprecated": "This is a stub types definition. @eslint/js provides its own type definitions, so you do not need this installed.", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint/js": "*" - } - }, "node_modules/@types/estree": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz", diff --git a/webui/package.json b/webui/package.json index a66e024..ca4fa6f 100644 --- a/webui/package.json +++ b/webui/package.json @@ -40,7 +40,6 @@ "@testing-library/jest-dom": "^6.9.1", "@testing-library/react": "^16.3.0", "@testing-library/user-event": "^14.6.1", - "@types/eslint__js": "^9.14.0", "@types/node": "^24.10.1", "@types/react": "^19.2.4", "@types/react-dom": "^19.2.3", diff --git a/webui/src/components/instance/AutoRestartConfiguration.tsx b/webui/src/components/instance/AutoRestartConfiguration.tsx index fe3a900..bb40b7d 100644 --- a/webui/src/components/instance/AutoRestartConfiguration.tsx +++ b/webui/src/components/instance/AutoRestartConfiguration.tsx @@ -5,7 +5,7 @@ import NumberInput from '@/components/form/NumberInput' interface AutoRestartConfigurationProps { formData: CreateInstanceOptions - onChange: (key: keyof CreateInstanceOptions, value: any) => void + onChange: (key: K, value: CreateInstanceOptions[K]) => void } const AutoRestartConfiguration: React.FC = ({ diff --git a/webui/src/components/instance/BackendConfiguration.tsx b/webui/src/components/instance/BackendConfiguration.tsx index 8f10e41..064bbcb 100644 --- a/webui/src/components/instance/BackendConfiguration.tsx +++ b/webui/src/components/instance/BackendConfiguration.tsx @@ -3,9 +3,11 @@ import type { CreateInstanceOptions } from '@/types/instance' import { getBasicBackendFields, getAdvancedBackendFields } from '@/lib/zodFormUtils' import BackendFormField from '@/components/BackendFormField' +type BackendFieldValue = string | number | boolean | string[] | Record | undefined + interface BackendConfigurationProps { formData: CreateInstanceOptions - onBackendFieldChange: (key: string, value: any) => void + onBackendFieldChange: (key: string, value: BackendFieldValue) => void showAdvanced?: boolean } @@ -26,7 +28,7 @@ const BackendConfiguration: React.FC = ({ | undefined)?.[fieldKey]} onChange={onBackendFieldChange} /> ))} @@ -41,7 +43,7 @@ const BackendConfiguration: React.FC = ({ | undefined)?.[fieldKey]} onChange={onBackendFieldChange} /> ))} @@ -53,7 +55,7 @@ const BackendConfiguration: React.FC = ({ | undefined)?.extra_args} onChange={onBackendFieldChange} /> diff --git a/webui/src/contexts/__tests__/InstancesContext.test.tsx b/webui/src/contexts/__tests__/InstancesContext.test.tsx index 1f99055..f35c49a 100644 --- a/webui/src/contexts/__tests__/InstancesContext.test.tsx +++ b/webui/src/contexts/__tests__/InstancesContext.test.tsx @@ -70,37 +70,37 @@ function TestComponent() { {/* Action buttons for testing with specific instances */}