/**
* Environment Variables Editor Section
* Visual editor for profile environment variables
*/
import { ScrollArea } from '@/components/ui/scroll-area';
import { Input } from '@/components/ui/input';
import { Label } from '@/components/ui/label';
import { Badge } from '@/components/ui/badge';
import { Button } from '@/components/ui/button';
import { MaskedInput } from '@/components/ui/masked-input';
import { Plus } from 'lucide-react';
import { isSensitiveKey } from './utils';
import type { Settings } from './types';
import { useTranslation } from 'react-i18next';
interface EnvEditorSectionProps {
currentSettings: Settings | undefined;
newEnvKey: string;
newEnvValue: string;
onNewEnvKeyChange: (value: string) => void;
onNewEnvValueChange: (value: string) => void;
onEnvValueChange: (key: string, value: string) => void;
onAddEnvVar: () => void;
}
export function EnvEditorSection({
currentSettings,
newEnvKey,
newEnvValue,
onNewEnvKeyChange,
onNewEnvValueChange,
onEnvValueChange,
onAddEnvVar,
}: EnvEditorSectionProps) {
const { t } = useTranslation();
return (
<>
{/* Scrollable Environment Variables List */}
{t('envEditor.none')} {t('envEditor.noneHint')}