1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-23 15:29:42 +02:00
portainer/app/react/docker/containers/CreateView/EnvVarsTab/EnvVarsTab.tsx

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

31 lines
694 B
TypeScript
Raw Normal View History

import {
EnvVarValues,
EnvironmentVariablesPanel,
} from '@@/form-components/EnvironmentVariablesFieldset';
import { ArrayError } from '@@/form-components/InputList/InputList';
export function EnvVarsTab({
values,
onChange,
errors,
}: {
values: EnvVarValues;
onChange(value: EnvVarValues): void;
errors?: ArrayError<EnvVarValues>;
}) {
return (
<div className="form-group">
<EnvironmentVariablesPanel
values={values}
explanation="These values will be applied to the container when deployed"
onChange={handleChange}
errors={errors}
/>
</div>
);
function handleChange(values: EnvVarValues) {
onChange(values);
}
}