import { v4 as uuidv4 } from 'uuid';
import { t } from 'i18next';
import { getUniqueName } from '../../../utils/get-unique-name';
import { getTransformConfig } from '../../../utils/get-transform-config';
import { addValue } from '..';
export const addActor = (destinationPath) => (dispatch, getState) => {
    const destination = getState(destinationPath);
    dispatch(addValue(destinationPath, {
        id: uuidv4(),
        name: getUniqueName(t('explorer.scenes.actionBar.actor.new.title'), destination),
        components: [getTransformConfig()],
        children: [],
    }));
};
