/*!
 * Copyright (c) Microsoft. All rights reserved.
 * Licensed under the MIT license. See LICENSE file in the project.
 */ import { jsx as _jsx } from "react/jsx-runtime";
import { memo, useMemo } from 'react';
import { FormInputType, VerbForm } from '../verbForm/VerbForm.js';
/**
 * Provides inputs for a Spread step.
 */ export const SpreadBase = /*#__PURE__*/ memo(function SpreadBase({ step , onChange  }) {
    const inputs = useMemo(()=>[
            {
                label: 'Keep source column',
                type: FormInputType.Checkbox,
                current: step.args.preserveSource,
                onChange: (s, val)=>s.args.preserveSource = val,
                advanced: true
            },
            {
                label: 'Split delimiter',
                type: FormInputType.Text,
                current: step.args.delimiter,
                onChange: (s, val)=>s.args.delimiter = val,
                advanced: true
            },
            {
                label: 'Onehot encode values',
                type: FormInputType.Checkbox,
                current: step.args.onehot,
                onChange: (s, val)=>s.args.onehot = val,
                styles: {
                    root: {
                        marginTop: 8
                    }
                },
                advanced: true
            }
        ], [
        step
    ]);
    return /*#__PURE__*/ _jsx(VerbForm, {
        inputs: inputs,
        step: step,
        onChange: onChange
    });
});
