src/Services/InputMaker.php
private function refineConfigs($inputConfig, $reformatted, $name, $config)
    {
        // If validation inputs are available lets prepopulate the fields!
        if (!empty($inputConfig['inputs']) && isset($inputConfig['inputs'][$name])) {
            $inputConfig['populated'] = true;
            $inputConfig['objectValue'] = $inputConfig['inputs'][$name];
        } elseif (isset($inputConfig['config']['default_value'])) {
            $inputConfig['objectValue'] = $inputConfig['config']['default_value'];
        }

        if ($reformatted) {
            $inputConfig['placeholder'] = $this->inputCalibrator->cleanString($this->inputCalibrator->placeholder($config, $name));
        }

        if (!isset($config['type'])) {
            if (is_array($config)) {
                $inputConfig['inputType'] = 'string';
            } else {
                $inputConfig['inputType'] = $config;
            }
        } else {
            $inputConfig['inputType'] = $config['type'];
        }

        return $inputConfig;
    }
private function refineConfigs($inputConfig, $reformatted, $name, $config)
    {
        // If validation inputs are available lets prepopulate the fields!
        if (!empty($inputConfig['inputs']) && isset($inputConfig['inputs'][$name])) {
            $inputConfig['populated'] = true;
            $inputConfig['objectValue'] = $inputConfig['inputs'][$name];
        } elseif (isset($inputConfig['config']['default_value'])) {
            $inputConfig['objectValue'] = $inputConfig['config']['default_value'];
        }

        if ($reformatted) {
            $inputConfig['placeholder'] = $this->inputCalibrator->cleanString($this->inputCalibrator->placeholder($config, $name));
        }

        if (!isset($config['type'])) {
            if (is_array($config)) {
                $inputConfig['inputType'] = 'string';
            } else {
                $inputConfig['inputType'] = $config;
            }
        } else {
            $inputConfig['inputType'] = $config['type'];
        }

        return $inputConfig;
    }
private function refineConfigs ( $ inputConfig , $ reformatted , $ name , $ config ) { // If validation inputs are available lets prepopulate the fields! if ( ! empty ( $ inputConfig [ 'inputs' ] ) && isset ( $ inputConfig [ 'inputs' ] [ $ name ] ) ) { $ inputConfig [ 'populated' ] = true ; $ inputConfig [ 'objectValue' ] = $ inputConfig [ 'inputs' ] [ $ name ] ; } elseif ( isset ( $ inputConfig [ 'config' ] [ 'default_value' ] ) ) { $ inputConfig [ 'objectValue' ] = $ inputConfig [ 'config' ] [ 'default_value' ] ; } if ( $ reformatted ) { $ inputConfig [ 'placeholder' ] = $ this -> inputCalibrator -> cleanString ( $ this -> inputCalibrator -> placeholder ( $ config , $ name ) ) ; } if ( ! isset ( $ config [ 'type' ] ) ) { if ( is_array ( $ config ) ) { $ inputConfig [ 'inputType' ] = 'string' ; } else { $ inputConfig [ 'inputType' ] = $ config ; } } else { $ inputConfig [ 'inputType' ] = $ config [ 'type' ] ; } return $ inputConfig ; }
Set the configs.

@param array  $config
@param bool   $reformatted
@param string $name
@param array  $config

@return array
Set the configs .