Completed
Push — 1.x ( 8c441f...0f5ece )
by Asao
02:43
created
src/Components/NavBar.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@
 block discarded – undo
64 64
      */
65 65
     public function is()
66 66
     {
67
-        foreach($this->items as $key => $item) {
67
+        foreach ($this->items as $key => $item) {
68 68
             if (!array_key_exists($key, $this->current) ||
69 69
                 $this->current[$key] !== $item) {
70 70
                 return false;
Please login to merge, or discard this patch.
src/Tags/InputList.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
         $this->list = $list;
27 27
         $this->setAttribute('type', $type);
28 28
         $this->setAttribute('name', $name);
29
-        $this->setAttribute('value', (array)$value);
29
+        $this->setAttribute('value', (array) $value);
30 30
         if ($type === 'checkbox') {
31 31
             $this->setMultiple();
32 32
         }
@@ -48,9 +48,9 @@  discard block
 block discarded – undo
48 48
         $html = '<ul>';
49 49
         foreach ($this->list as $key => $label) {
50 50
             $html .= "\n";
51
-            $html .= '  <li>' . $this->labelHtml($this->getInput($key) . ' ' . $label) . '</li>';
51
+            $html .= '  <li>'.$this->labelHtml($this->getInput($key).' '.$label).'</li>';
52 52
         }
53
-        return $html . "\n</ul>";
53
+        return $html."\n</ul>";
54 54
     }
55 55
 
56 56
     /**
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
         $input->fillAttributes($this->getAttribute());
84 84
         $input->setAttribute('value', $key);
85 85
         $selectedValue = $this->get('value');
86
-        if (in_array((string)$key, $selectedValue)) {
86
+        if (in_array((string) $key, $selectedValue)) {
87 87
             $input->setAttribute('checked', true);
88 88
         }
89 89
         return $input;
Please login to merge, or discard this patch.
src/Tags/Select.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         parent::__construct('select');
37 37
         $this->list = $list;
38 38
         $this->setAttribute('name', $name);
39
-        $this->setAttribute('value', (array)$value);
39
+        $this->setAttribute('value', (array) $value);
40 40
     }
41 41
 
42 42
     /**
@@ -73,11 +73,11 @@  discard block
 block discarded – undo
73 73
      */
74 74
     private function formSelect()
75 75
     {
76
-        $selectedValue = (array)$this->get('value');
76
+        $selectedValue = (array) $this->get('value');
77 77
         $this->setAttribute('value', false);
78 78
         $html = $this->formOptions($this->list, $selectedValue, $this->head);
79 79
         if ($html) {
80
-            $this->contents($html . "\n");
80
+            $this->contents($html."\n");
81 81
             $html = TagToString::format($this);
82 82
         }
83 83
         return $html;
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
             $html .= "\n  <option value=\"\">{$head}</option>";
97 97
         }
98 98
         foreach ($list as $value => $label) {
99
-            if (in_array((string)$value, $selectedValue)) {
99
+            if (in_array((string) $value, $selectedValue)) {
100 100
                 $html .= "\n  <option value=\"{$value}\" selected>{$label}</option>";
101 101
             } else {
102 102
                 $html .= "\n  <option value=\"{$value}\">{$label}</option>";
Please login to merge, or discard this patch.
src/Tags/Input.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
     {
43 43
         $html = TagToString::format($this);
44 44
         if ($this->label) {
45
-            $html = $this->labelHtml($html . ' ' . $this->label);
45
+            $html = $this->labelHtml($html.' '.$this->label);
46 46
         }
47 47
         return $html;
48 48
     }
Please login to merge, or discard this patch.
src/Tags/Tag.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -142,8 +142,8 @@
 block discarded – undo
142 142
         } elseif ($sep === false) {
143 143
             $this->attributes[$key] = $value;
144 144
         } else {
145
-            $sep = (string)$sep;
146
-            $this->attributes[$key] .= $sep . $value;
145
+            $sep = (string) $sep;
146
+            $this->attributes[$key] .= $sep.$value;
147 147
         }
148 148
         return $this;
149 149
     }
Please login to merge, or discard this patch.
src/Tags/TextArea.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
     {
36 36
         $html = TagToString::format($this);
37 37
         if ($this->label) {
38
-            $html = $this->labelHtml($html . ' ' . $this->label);
38
+            $html = $this->labelHtml($html.' '.$this->label);
39 39
         }
40 40
         return $html;
41 41
     }
Please login to merge, or discard this patch.
src/Tags/Form.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@
 block discarded – undo
85 85
     {
86 86
         $html = TagToString::format($this);
87 87
         if (!is_null($this->_method)) {
88
-            $html .= "\n<input type=\"hidden\" name=\"{$this->_token_name}\" value=\"" . $this->_method . "\" />";
88
+            $html .= "\n<input type=\"hidden\" name=\"{$this->_token_name}\" value=\"".$this->_method."\" />";
89 89
         }
90 90
         return $html;
91 91
     }
Please login to merge, or discard this patch.
src/Tags/TagToString.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -12,9 +12,9 @@  discard block
 block discarded – undo
12 12
         $prop = self::htmlProperty($element);
13 13
         $tag  = $element->getTagName();
14 14
         if ($element->isClosed() || $element->hasContents()) {
15
-            $html = '<' . $tag . $prop . ' >' . $element->getContents() . "</{$tag}>" . "\n";
15
+            $html = '<'.$tag.$prop.' >'.$element->getContents()."</{$tag}>"."\n";
16 16
         } else {
17
-            $html = '<' . $tag . $prop . ' >' . "\n";
17
+            $html = '<'.$tag.$prop.' >'."\n";
18 18
         }
19 19
         $html = rtrim($html);
20 20
         return $html;
@@ -38,10 +38,10 @@  discard block
 block discarded – undo
38 38
                     $property[] = $key;
39 39
                 } elseif ($val !== false) {
40 40
                     // ignore if $val is false.
41
-                    $property[] = $key . "=\"{$val}\"";
41
+                    $property[] = $key."=\"{$val}\"";
42 42
                 }
43 43
             }
44
-            return ' ' . implode(' ', $property);
44
+            return ' '.implode(' ', $property);
45 45
         }
46 46
         return '';
47 47
     }
Please login to merge, or discard this patch.
src/Tags/ElementTrait.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     {
28 28
         $this->multiple = $multiple;
29 29
         $name           = $this->get('name');
30
-        $this->setAttribute('name', $name . '[]');
30
+        $this->setAttribute('name', $name.'[]');
31 31
         return $this;
32 32
     }
33 33
 
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
             $id = $this->getName();
69 69
             $id = str_replace(['[', ']', '_'], '-', $id);
70 70
             if (in_array($this->get('type'), ['radio', 'checkbox'])) {
71
-                $id .= '-' . $this->get('value');
71
+                $id .= '-'.$this->get('value');
72 72
             }
73 73
         }
74 74
         $this->setAttribute('id', $id);
Please login to merge, or discard this patch.