import { useCreateEnvironment } from '../hooks/useCreateEnvironment'; import { useEnvironments } from '../hooks/useEnvironments'; import type { Environment } from '../lib/models'; import { Button } from './core/Button'; import classNames from 'classnames'; import { useActiveEnvironment } from '../hooks/useActiveEnvironment'; import { useAppRoutes } from '../hooks/useAppRoutes'; import { PairEditor } from './core/PairEditor'; import type { PairEditorProps } from './core/PairEditor'; import { useCallback, useMemo } from 'react'; import { useUpdateEnvironment } from '../hooks/useUpdateEnvironment'; import { HStack, VStack } from './core/Stacks'; import { IconButton } from './core/IconButton'; import { useDeleteEnvironment } from '../hooks/useDeleteEnvironment'; import type { GenericCompletionConfig } from './core/Editor/genericCompletion'; export const EnvironmentEditDialog = function () { const routes = useAppRoutes(); const environments = useEnvironments(); const createEnvironment = useCreateEnvironment(); const activeEnvironment = useActiveEnvironment(); return (