insideout10/wordlift-plugin-js

View on GitHub

Showing 1,798 of 3,223 total issues

Function _create has 197 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    _create: function() {
        // Some browsers only repeat keydown events, not keypress events,
        // so we use the suppressKeyPress flag to determine if we've already
        // handled the keydown event. #7269
        // Unfortunately the code for & in keypress is the same as the up arrow,
Severity: Major
Found in app/lib/jquery-ui-1.10.3/ui/jquery-ui.js - About 7 hrs to fix

    Function _create has 197 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        _create: function() {
            // Some browsers only repeat keydown events, not keypress events,
            // so we use the suppressKeyPress flag to determine if we've already
            // handled the keydown event. #7269
            // Unfortunately the code for & in keypress is the same as the up arrow,
    Severity: Major
    Found in app/lib/jquery-ui-1.10.3/ui/jquery.ui.autocomplete.js - About 7 hrs to fix

      File wp-fullscreen.js has 491 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      /* global ajaxurl, deleteUserSetting, setUserSetting, switchEditors, tinymce, tinyMCEPreInit, wp_fullscreen_settings, wpActiveEditor:true, wpLink */
      /**
       * PubSub
       *
       * A lightweight publish/subscribe implementation.
      Severity: Minor
      Found in app/admin_files/wp-fullscreen.js - About 7 hrs to fix

        Function tb_show has 194 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function tb_show(caption, url, imageGroup) {//function called when the user clicks on a thickbox link
        
            try {
                if (typeof document.body.style.maxHeight === "undefined") {//if IE 6
                    jQuery("body","html").css({height: "100%", width: "100%"});
        Severity: Major
        Found in app/admin_files/thickbox.js - About 7 hrs to fix

          File jquery.ui.menu.js has 488 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          /*!
           * jQuery UI Menu 1.10.3
           * http://jqueryui.com
           *
           * Copyright 2013 jQuery Foundation and other contributors
          Severity: Minor
          Found in app/lib/jquery-ui-1.10.3/ui/jquery.ui.menu.js - About 7 hrs to fix

            File autosave.js has 488 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            /* global switchEditors, autosaveL10n, tinymce, ajaxurl, wpAjax, makeSlugeditClickable, wpCookies */
            var autosave, autosavePeriodical, fullscreen, doPreview,
                autosaveLast = '',
                autosaveDelayPreview = false,
                notSaved = true,
            Severity: Minor
            Found in app/admin_files/autosave.js - About 7 hrs to fix

              Function performCaretAction has 192 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                      function performCaretAction(type, name, vars) {
                          var caretContainerId = '_mce_caret', debug = ed.settings.caret_debug;
              
                          // Creates a caret container bogus element
                          function createCaretContainer(fill) {
              Severity: Major
              Found in app/lib/tinymce/jscripts/tiny_mce/tiny_mce_src.js - About 7 hrs to fix

                Function parse has 188 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        self.parse = function(html) {
                            var self = this, matches, index = 0, value, endRegExp, stack = [], attrList, i, text, name, isInternalElement, removeInternalElements,
                                shortEndedElements, fillAttrsMap, isShortEnded, validate, elementRule, isValidElement, attr, attribsValue, invalidPrefixRegExp,
                                validAttributesMap, validAttributePatterns, attributesRequired, attributesDefault, attributesForced, selfClosing,
                                tokenRegExp, attrRegExp, specialElements, attrValue, idCount = 0, decode = tinymce.html.Entities.decode, fixSelfClosing, isIE;
                Severity: Major
                Found in app/lib/tinymce/jscripts/tiny_mce/tiny_mce_src.js - About 7 hrs to fix

                  Function _nodeChanged has 188 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                          _nodeChanged : function(ed, cm, n, co, ob) {
                              var t = this, p, de = 0, v, c, s = t.settings, cl, fz, fn, fc, bc, formatNames, matches;
                  
                              tinymce.each(t.stateControls, function(c) {
                                  cm.setActive(c, ed.queryCommandState(t.controls[c][1]));

                    File edit-comments.js has 479 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    /* global adminCommentsL10n, thousandsSeparator, list_args, QTags, ajaxurl, wpAjax */
                    var setCommentsList, theList, theExtraList, commentReply,
                        toggleWithKeyboard = false;
                    
                    (function($) {
                    Severity: Minor
                    Found in app/admin_files/edit-comments.js - About 7 hrs to fix

                      Function jsDump has 187 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      QUnit.jsDump = (function() {
                          function quote( str ) {
                              return '"' + str.toString().replace( /"/g, '\\"' ) + '"';
                          }
                          function literal( o ) {
                      Severity: Major
                      Found in app/lib/jquery-ui-1.10.3/external/qunit.js - About 7 hrs to fix

                        Function suggest has 187 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            $.suggest = function(input, options) {
                                var $input, $results, timeout, prevLength, cache, cacheSize;
                        
                                $input = $(input).attr("autocomplete", "off");
                                $results = $("<ul/>");
                        Severity: Major
                        Found in app/admin_files/suggest.js - About 7 hrs to fix

                          Function insertTable has 186 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          function insertTable() {
                              var formObj = document.forms[0];
                              var inst = tinyMCEPopup.editor, dom = inst.dom;
                              var cols = 2, rows = 2, border = 0, cellpadding = -1, cellspacing = -1, align, width, height, className, caption, frame, rules;
                              var html = '', capEl, elm;
                          Severity: Major
                          Found in app/lib/tinymce/jscripts/tiny_mce/plugins/table/js/table.js - About 7 hrs to fix

                            Function $RouteProvider has 185 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            function $RouteProvider(){
                              function inherit(parent, extra) {
                                return angular.extend(new (angular.extend(function() {}, {prototype:parent}))(), extra);
                              }
                            
                            
                            Severity: Major
                            Found in app/lib/angular/angular-route.js - About 7 hrs to fix

                              File jquery.ui.autocomplete.js has 471 lines of code (exceeds 250 allowed). Consider refactoring.
                              Open

                              /*!
                               * jQuery UI Autocomplete 1.10.3
                               * http://jqueryui.com
                               *
                               * Copyright 2013 jQuery Foundation and other contributors
                              Severity: Minor
                              Found in app/lib/jquery-ui-1.10.3/ui/jquery.ui.autocomplete.js - About 7 hrs to fix

                                File quicktags.js has 470 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                /* global adminpage, wpActiveEditor, quicktagsL10n, wpLink, fullscreen, prompt */
                                /*
                                 * Quicktags
                                 *
                                 * This is the HTML editor in WordPress. It can be attached to any textarea and will
                                Severity: Minor
                                Found in app/admin_files/quicktags.js - About 7 hrs to fix

                                  Function Serializer has 180 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      tinymce.dom.Serializer = function(settings, dom, schema) {
                                          var onPreProcess, onPostProcess, isIE = tinymce.isIE, each = tinymce.each, htmlParser;
                                  
                                          // Support the old apply_source_formatting option
                                          if (!settings.apply_source_formatting)
                                  Severity: Major
                                  Found in app/lib/tinymce/jscripts/tiny_mce/tiny_mce_src.js - About 7 hrs to fix

                                    Function MediaType has a Cognitive Complexity of 46 (exceeds 5 allowed). Consider refactoring.
                                    Open

                                        VMM.MediaType = function(_d) {
                                            var d        = _d.replace(/^\s\s*/, '').replace(/\s\s*$/, ''),
                                                success    = false,
                                                media    = {
                                                    type:        "unknown",
                                    Severity: Minor
                                    Found in app/lib/TimelineJS.build/build/js/timeline.js - About 7 hrs to fix

                                    Cognitive Complexity

                                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                                    A method's cognitive complexity is based on a few simple rules:

                                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                                    • Code is considered more complex for each "break in the linear flow of the code"
                                    • Code is considered more complex when "flow breaking structures are nested"

                                    Further reading

                                    Function objectToImg has 173 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                            objectToImg : function(node) {
                                                var object, embed, video, iframe, img, name, id, width, height, style, i, html,
                                                    param, params, source, sources, data, type, lookup = this.lookup,
                                                    matches, attrs, urlConverter = this.editor.settings.url_converter,
                                                    urlConverterScope = this.editor.settings.url_converter_scope,
                                    Severity: Major
                                    Found in app/lib/tinymce/jscripts/tiny_mce/plugins/media/editor_plugin_src.js - About 6 hrs to fix

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

                                              init : function(ed, url) {
                                                  var t = this;
                                      
                                                  t.editor = ed;
                                                  t.url = url;
                                      Severity: Major
                                      Found in app/lib/tinymce/jscripts/tiny_mce/plugins/paste/editor_plugin_src.js - About 6 hrs to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language