Showing 124 of 260 total issues
File jquery.validate.js
has 1258 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/*! * jQuery Validation Plugin v1.21.0 * * https://jqueryvalidation.org/ *
File additional-methods.js
has 858 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/*! * jQuery Validation Plugin v1.20.0 * * https://jqueryvalidation.org/ *
File content.php
has 655 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php defined( 'ABSPATH' ) || die; ?> <header class="mb-dashboard__header" data-utm="header"> <a class="mb-dashboard__logo" href="https://metabox.io" target="_blank"> <svg viewBox="0 0 196 46" fill="none" xmlns="http://www.w3.org/2000/svg">
File media.js
has 418 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
( function ( $, wp, _, rwmb, i18n ) { 'use strict'; var views = rwmb.views = rwmb.views || {}, models = rwmb.models = rwmb.models || {},
File field.php
has 330 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?phpuse MetaBox\Support\Arr; /** * The field base class.
Method html
has 85 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function html( $meta, $field ) { $meta = wp_parse_args( $meta, [ 'color' => '', 'image' => '', 'repeat' => '',
File file.php
has 305 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?phpdefined( 'ABSPATH' ) || die; /** * The file upload file which allows users to upload files via the default HTML <input type="file">.
Function rwmbModal
has 75 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.fn.rwmbModal = function ( options = {} ) { options = { ...defaultOptions, ...options };
RW_Meta_Box
has 26 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class RW_Meta_Box { /** * Meta box parameters. * * @var array
RWMB_Field
has 25 functions (exceeds 20 allowed). Consider refactoring. Open
Open
abstract class RWMB_Field { public static function add_actions() {} public static function admin_enqueue_scripts() {}
Function transform
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function transform() { var $this = $( this ), options = $this.data( 'options' ); $this.removeClass( 'select2-hidden-accessible' ).removeAttr( 'data-select2-id' );
Function html
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
Open
public static function html( array $meta, array $field ) : string { $field_html = ''; $count = count( $meta ); foreach ( $meta as $index => $sub_meta ) {
- Read upRead up
Function validate
has 64 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
validate: function( options ) { // If nothing is selected, return nothing; can't chain anyway if ( !this.length ) { if ( options && options.debug && window.console ) {
Function showLabel
has 62 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
showLabel: function( element, message ) { var place, group, errorID, v, error = this.errorsFor( element ), elementID = this.idOrName( element ), describedBy = $( element ).attr( "aria-describedby" );
Method html
has 60 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public static function html( $meta, $field ) { if ( ! is_array( $meta ) ) { $meta = [ $meta ]; }
Function sliderAccess
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
sliderAccess: function(options){ options = options || {}; options.touchonly = options.touchonly !== undefined? options.touchonly : true; // by default only show it if touch device if(options.touchonly === true && !("ontouchend" in document)){
Consider simplifying this complex logical expression. Open
Open
if ( value === "" || value === "00000000000" || value === "11111111111" || value === "22222222222" || value === "33333333333" ||
Function rules
has 58 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
rules: function( command, argument ) { var element = this[ 0 ], isContentEditable = typeof this.attr( "contenteditable" ) !== "undefined" && this.attr( "contenteditable" ) !== "false", settings, staticRules, existingRules, data, param, filtered;
Function initUploader
has 57 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
initUploader: function ( $this ) { var self = this, $input = $this.closest( '.rwmb-input' ), $process = $input.find( '.rwmb-media-view .rwmb-media-progress' ), extensions = this.getExtensions().join( ',' ),
Function normalizeRules
has 55 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
normalizeRules: function( rules, element ) { // Handle dependency check $.each( rules, function( prop, val ) {