soderlind/plugin-customizer

View on GitHub

Showing 122 of 122 total issues

Function exports has 203 lines of code (exceeds 25 allowed). Consider refactoring.
Open

module.exports = function (grunt) {

    /**
     * Files added to WordPress SVN, don't include 'assets/**' here.
     * @type {Array}
Severity: Major
Found in Gruntfile.js - About 1 day to fix

    Plugin_Customizer has 22 functions (exceeds 20 allowed). Consider refactoring.
    Open

        abstract class Plugin_Customizer implements Plugin_Customizer_Interface {
    
            private  $customize_register_priority = 9; // Priority must be between 2 and 9
            private  $slug;
            private  $org_theme;
    Severity: Minor
    Found in src/Plugin_Customizer.php - About 2 hrs to fix

      Method init has 52 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              function init( $slug = '', $plugin_url, $plugin_root ) {
                  // self::$param_name = sanitize_title( get_called_class() , 'plugin_customizer' );
                  if ( '' == $slug ) {
                      wp_die( 'slug missing', $title = 'BlankSlate::init' );
                  }
      Severity: Major
      Found in src/Blank_Slate.php - About 2 hrs to fix

        Method init has 46 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                function init( $config = array() ) {
        
                    if ( ! count( $config ) ) {
                        wp_die( /*$message = '', $title = '', $args = array()*/ );
                    }
        Severity: Minor
        Found in src/Plugin_Customizer.php - About 1 hr to fix

          Function PluginCustomizer has 39 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          var PluginCustomizer = (function( api, $ ) {
              'use strict';
          
              var component = {
                  data: {
          Severity: Minor
          Found in src/assets/js/plugin-customizer-preview-templates.js - About 1 hr to fix

            Function PluginCustomizerBlankSlate has 38 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            var PluginCustomizerBlankSlate = (function( api, $ ) {
                'use strict';
            
                var component = {
                    data: {
            Severity: Minor
            Found in src/assets/js/plugin-customizer-blank-slate.js - About 1 hr to fix

              Function init has 31 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  component.init = function init( home, sections ) {
                      _.extend( component.data, home );
                      _.extend( {}, sections );
                      if ( ! home || ! home.url  ) {
                          throw new Error( 'Missing args' );
              Severity: Minor
              Found in src/assets/js/plugin-customizer-preview-templates.js - About 1 hr to fix

                Array double arrow not aligned correctly; expected 1 space(s) between "'description'" and double arrow, but found 3.
                Open

                                'description'    => __( 'Customize newsletter content', 'plugin-customizer' ),
                Severity: Minor
                Found in plugin-customizer-demo.php by phpcodesniffer

                Array double arrow not aligned correctly; expected 4 space(s) between "'default'" and double arrow, but found 7.
                Open

                                'default'        => 'This was to be an eventful day for the travelers.  They had hardly been walking an hour when they saw before them a great ditch that crossed the road and divided the forest as far as they could see on either side.  It was a very wide ditch, and when they crept up to the edge and looked into it they could see it was also very deep, and there were many big, jagged rocks at the bottom.  The sides were so steep that none of them could climb down, and for a moment it seemed that their journey must end. "What shall we do?" asked Dorothy despairingly. "I haven\'t the faintest idea," said the Tin Woodman, and the Lion shook his shaggy mane and looked thoughtful.', //esc_html( '<p> Nulla laoreet erat vitae aliquet tristique. Quisque quis suscipit enim, a elementum eros. Vestibulum quis lacus ligula. Mauris sit amet nibh tincidunt, gravida tortor ac, maximus nisi. Nunc turpis mauris, blandit vitae nibh non, blandit pharetra purus. Sed sed convallis diam. In ante nisi, pellentesque in laoreet at, fringilla ac neque. </p> <p> Cras consequat eros lectus, ac dignissim justo cursus ac. In mi tortor, ornare eu quam a, ultrices tincidunt magna. Fusce non purus quis ex convallis vehicula. Aenean purus diam, vulputate vel pellentesque ultrices, tincidunt ac lectus. Nullam est purus, lobortis ac aliquam eget, egestas a diam. Praesent eget sapien vitae orci faucibus tempus. Ut sit amet lorem elit. Curabitur et vestibulum nibh. </p> <p> Mauris vestibulum eget nisl sit amet gravida. Nullam in orci ut sem maximus dapibus blandit quis dolor. Sed pretium efficitur elit, eget vulputate sapien bibendum non. Proin congue posuere sagittis. Ut fermentum mauris ut gravida faucibus. Aenean a malesuada magna. Vestibulum nec viverra metus. Nunc aliquam eros orci, ut malesuada felis malesuada vitae. Phasellus vehicula non ex at scelerisque. </p>' ),
                Severity: Minor
                Found in plugin-customizer-demo.php by phpcodesniffer

                Found precision alignment of 1 spaces.
                Open

                          */
                Severity: Minor
                Found in plugin-customizer-demo.php by phpcodesniffer

                Equals sign not aligned with surrounding assignments; expected 6 spaces but found 1 space
                Open

                                $deps = array( 'customize-controls' );
                Severity: Minor
                Found in src/Blank_Slate.php by phpcodesniffer

                Spaces must be used for mid-line alignment; tabs are not allowed
                Open

                         * @param   string    $template plugin_root to the template
                Severity: Minor
                Found in src/Plugin_Customizer.php by phpcodesniffer

                Equals sign not aligned with surrounding assignments; expected 7 spaces but found 1 space
                Open

                            $src = $this->url . 'assets/js/plugin-customizer-preview-templates.js';
                Severity: Minor
                Found in src/Plugin_Customizer.php by phpcodesniffer

                Found precision alignment of 2 spaces.
                Open

                      height: 100%;
                Severity: Minor
                Found in templates/content.php by phpcodesniffer

                Found precision alignment of 2 spaces.
                Open

                      background-color: #333333;
                Severity: Minor
                Found in templates/newsletter.php by phpcodesniffer

                Spaces must be used for mid-line alignment; tabs are not allowed
                Open

                                'priority'        => 10,
                Severity: Minor
                Found in plugin-customizer-demo.php by phpcodesniffer

                Spaces must be used for mid-line alignment; tabs are not allowed
                Open

                                'type'            => 'option',
                Severity: Minor
                Found in plugin-customizer-demo.php by phpcodesniffer

                Equals sign not aligned with surrounding assignments; expected 2 spaces but found 1 space
                Open

                            $this->plugin_url = $plugin_url;
                Severity: Minor
                Found in src/Blank_Slate.php by phpcodesniffer

                Equals sign not aligned with surrounding assignments; expected 8 spaces but found 1 space
                Open

                            $this->slug = sanitize_title( $config['name'] , 'plugin-customizer' );
                Severity: Minor
                Found in src/Plugin_Customizer.php by phpcodesniffer

                Spaces must be used for mid-line alignment; tabs are not allowed
                Open

                         * @param   Array    $query_vars All defined query variables.
                Severity: Minor
                Found in src/Plugin_Customizer.php by phpcodesniffer
                Severity
                Category
                Status
                Source
                Language