Test Setup Failed
Push — develop ( c37d0d...b03fe2 )
by Aristeides
02:17
created
modules/tooltips/class-kirki-modules-tooltips.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -76,11 +76,11 @@
 block discarded – undo
76 76
 
77 77
 		$fields = Kirki::$fields;
78 78
 		foreach ( $fields as $field ) {
79
-			if ( isset( $field['tooltip'] ) && ! empty( $field['tooltip'] ) ) {
80
-				$id = str_replace( '[', '-', str_replace( ']', '', $field['settings'] ) );
79
+			if ( isset( $field[ 'tooltip' ] ) && ! empty( $field[ 'tooltip' ] ) ) {
80
+				$id = str_replace( '[', '-', str_replace( ']', '', $field[ 'settings' ] ) );
81 81
 				$this->tooltips_content[ $id ] = array(
82 82
 					'id'      => $id,
83
-					'content' => wp_kses_post( $field['tooltip'] ),
83
+					'content' => wp_kses_post( $field[ 'tooltip' ] ),
84 84
 				);
85 85
 			}
86 86
 		}
Please login to merge, or discard this patch.
controls/php/class-kirki-control-color.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -53,8 +53,8 @@
 block discarded – undo
53 53
 	public function to_json() {
54 54
 		parent::to_json();
55 55
 
56
-		$this->json['palette'] = $this->palette;
57
-		$this->json['choices']['alpha'] = ( isset( $this->choices['alpha'] ) && $this->choices['alpha'] ) ? 'true' : 'false';
58
-		$this->json['mode'] = $this->mode;
56
+		$this->json[ 'palette' ] = $this->palette;
57
+		$this->json[ 'choices' ][ 'alpha' ] = ( isset( $this->choices[ 'alpha' ] ) && $this->choices[ 'alpha' ] ) ? 'true' : 'false';
58
+		$this->json[ 'mode' ] = $this->mode;
59 59
 	}
60 60
 }
Please login to merge, or discard this patch.
controls/php/class-kirki-control-dashicons.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
 	public function to_json() {
36 36
 		parent::to_json();
37 37
 
38
-		$this->json['icons'] = Kirki_Helper::get_dashicons();
38
+		$this->json[ 'icons' ] = Kirki_Helper::get_dashicons();
39 39
 	}
40 40
 
41 41
 	/**
Please login to merge, or discard this patch.
controls/php/class-kirki-control-radio-image.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,10 +37,10 @@
 block discarded – undo
37 37
 
38 38
 		foreach ( $this->input_attrs as $attr => $value ) {
39 39
 			if ( 'style' !== $attr ) {
40
-				$this->json['inputAttrs'] .= $attr . '="' . esc_attr( $value ) . '" ';
40
+				$this->json[ 'inputAttrs' ] .= $attr . '="' . esc_attr( $value ) . '" ';
41 41
 				continue;
42 42
 			}
43
-			$this->json['labelStyle'] = 'style="' . esc_attr( $value ) . '" ';
43
+			$this->json[ 'labelStyle' ] = 'style="' . esc_attr( $value ) . '" ';
44 44
 		}
45 45
 
46 46
 	}
Please login to merge, or discard this patch.
controls/php/class-kirki-control-dimensions.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -39,14 +39,14 @@
 block discarded – undo
39 39
 		if ( is_array( $this->choices ) ) {
40 40
 			foreach ( $this->choices as $choice => $value ) {
41 41
 				if ( 'labels' !== $choice && true === $value ) {
42
-					$this->json['choices'][ $choice ] = true;
42
+					$this->json[ 'choices' ][ $choice ] = true;
43 43
 				}
44 44
 			}
45 45
 		}
46
-		if ( is_array( $this->json['default'] ) ) {
47
-			foreach ( $this->json['default'] as $key => $value ) {
48
-				if ( isset( $this->json['choices'][ $key ] ) && ! isset( $this->json['value'][ $key ] ) ) {
49
-					$this->json['value'][ $key ] = $value;
46
+		if ( is_array( $this->json[ 'default' ] ) ) {
47
+			foreach ( $this->json[ 'default' ] as $key => $value ) {
48
+				if ( isset( $this->json[ 'choices' ][ $key ] ) && ! isset( $this->json[ 'value' ][ $key ] ) ) {
49
+					$this->json[ 'value' ][ $key ] = $value;
50 50
 				}
51 51
 			}
52 52
 		}
Please login to merge, or discard this patch.
controls/php/class-kirki-control-select.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,6 +44,6 @@
 block discarded – undo
44 44
 	public function to_json() {
45 45
 		parent::to_json();
46 46
 
47
-		$this->json['multiple'] = $this->multiple;
47
+		$this->json[ 'multiple' ] = $this->multiple;
48 48
 	}
49 49
 }
Please login to merge, or discard this patch.
controls/php/class-kirki-control-base.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -128,30 +128,30 @@
 block discarded – undo
128 128
 		// Get the basics from the parent class.
129 129
 		parent::to_json();
130 130
 		// Default.
131
-		$this->json['default'] = $this->setting->default;
131
+		$this->json[ 'default' ] = $this->setting->default;
132 132
 		if ( isset( $this->default ) ) {
133
-			$this->json['default'] = $this->default;
133
+			$this->json[ 'default' ] = $this->default;
134 134
 		}
135 135
 		// Required.
136
-		$this->json['required'] = $this->required;
136
+		$this->json[ 'required' ] = $this->required;
137 137
 		// Output.
138
-		$this->json['output'] = $this->output;
138
+		$this->json[ 'output' ] = $this->output;
139 139
 		// Value.
140
-		$this->json['value'] = $this->value();
140
+		$this->json[ 'value' ] = $this->value();
141 141
 		// Choices.
142
-		$this->json['choices'] = $this->choices;
142
+		$this->json[ 'choices' ] = $this->choices;
143 143
 		// The link.
144
-		$this->json['link'] = $this->get_link();
144
+		$this->json[ 'link' ] = $this->get_link();
145 145
 		// The ID.
146
-		$this->json['id'] = $this->id;
146
+		$this->json[ 'id' ] = $this->id;
147 147
 		// Translation strings.
148
-		$this->json['l10n'] = $this->l10n();
148
+		$this->json[ 'l10n' ] = $this->l10n();
149 149
 		// The ajaxurl in case we need it.
150
-		$this->json['ajaxurl'] = admin_url( 'admin-ajax.php' );
150
+		$this->json[ 'ajaxurl' ] = admin_url( 'admin-ajax.php' );
151 151
 		// Input attributes.
152
-		$this->json['inputAttrs'] = '';
152
+		$this->json[ 'inputAttrs' ] = '';
153 153
 		foreach ( $this->input_attrs as $attr => $value ) {
154
-			$this->json['inputAttrs'] .= $attr . '="' . esc_attr( $value ) . '" ';
154
+			$this->json[ 'inputAttrs' ] .= $attr . '="' . esc_attr( $value ) . '" ';
155 155
 		}
156 156
 	}
157 157
 
Please login to merge, or discard this patch.
controls/php/class-kirki-control-multicolor.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
 	public function to_json() {
44 44
 		parent::to_json();
45 45
 
46
-		$this->json['alpha'] = (bool) $this->alpha;
46
+		$this->json[ 'alpha' ] = (bool) $this->alpha;
47 47
 	}
48 48
 
49 49
 	/**
Please login to merge, or discard this patch.
controls/php/class-kirki-control-slider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
 	public function to_json() {
38 38
 		parent::to_json();
39 39
 
40
-		$this->json['choices'] = wp_parse_args( $this->json['choices'], array(
40
+		$this->json[ 'choices' ] = wp_parse_args( $this->json[ 'choices' ], array(
41 41
 			'min'    => '0',
42 42
 			'max'    => '100',
43 43
 			'step'   => '1',
Please login to merge, or discard this patch.