client/src/Confirm.js
/**
     * Returns a component with the sequences of chosen steps and their inputs
     */
Returns a component with the sequences of chosen steps and their inputs
Returns a component with the sequences of chosen steps and their inputs
displaySteps() {
        let trans = new Transformations();
        let transformations = trans.getTransformations();
        let steps = this.props.steps;
        let counter = 0;
        return steps.map((i) => {
            counter++;
            let index = trans.getStepIndex(i.name);
            let stepName = transformations[index].name;
            let inputInfo;
            if(transformations[index].numOfInputs !== 0) {
                let inputNames = transformations[index].inputNames.slice();
                let inputs = i.inputs.slice();
                inputInfo = Util.range(0, transformations[index].numOfInputs - 1, 1).map((j) => (<React.Fragment>{inputNames[j]}={inputs[j]}&ensp;</React.Fragment>));
            }
            return (
                <React.Fragment>
                    {counter}: <b>{stepName}</b>&emsp;{inputInfo}<br />
                </React.Fragment>
            );
        });
    }
displaySteps ( ) { let trans = new Transformations ( ) ; let transformations = trans . getTransformations ( ) ; let steps = this . props . steps ; let counter = 0 ; return steps . map ( ( i ) => { counter ++ ; let index = trans . getStepIndex ( i . name ) ; let stepName = transformations [ index ] . name ; let inputInfo ; if ( transformations [ index ] . numOfInputs !== 0 ) { let inputNames = transformations [ index ] . inputNames . slice ( ) ; let inputs = i . inputs . slice ( ) ; inputInfo = Util . range ( 0 , transformations [ index ] . numOfInputs - 1 , 1 ) . map ( ( j ) => ( < React . Fragment > { inputNames [ j ] } = { inputs [ j ] } &ensp; < / React . Fragment > ) ) ; } return ( < React . Fragment > { counter } :  < b > { stepName } < / b > &emsp; { inputInfo } < br / > < / React . Fragment > ) ; } ) ; }
Returns a component with the sequences of chosen steps and their inputs
Returns a component with the sequences of chosen steps and their inputs
// find the index of this step // get the step name // get the input names and inputs