Passed
Push — master ( aecd40...074997 )
by Sebastian
10:13 queued 07:17
created
src/StyleCollection/StyleBuilder/NumericContainer.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -8,17 +8,17 @@
 block discarded – undo
8 8
 
9 9
 abstract class NumericContainer extends StyleContainer
10 10
 {
11
-    public function px(int $px, bool $important=false) : StyleBuilder
11
+    public function px(int $px, bool $important = false) : StyleBuilder
12 12
     {
13 13
         return $this->setStylePX($px, $important);
14 14
     }
15 15
 
16
-    public function percent(float $percent, bool $important=false) : StyleBuilder
16
+    public function percent(float $percent, bool $important = false) : StyleBuilder
17 17
     {
18 18
         return $this->setStylePercent($percent, $important);
19 19
     }
20 20
 
21
-    public function em(float $percent, bool $important=false) : StyleBuilder
21
+    public function em(float $percent, bool $important = false) : StyleBuilder
22 22
     {
23 23
         return $this->setStyleEM($percent, $important);
24 24
     }
Please login to merge, or discard this patch.
src/StyleCollection/StyleBuilder.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -21,9 +21,9 @@  discard block
 block discarded – undo
21 21
      */
22 22
     private $collection;
23 23
 
24
-    private function __construct(?StyleCollection $collection=null)
24
+    private function __construct(?StyleCollection $collection = null)
25 25
     {
26
-        if($collection === null)
26
+        if ($collection === null)
27 27
         {
28 28
             $collection = StyleCollection::create();
29 29
         }
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
         $this->collection = $collection;
32 32
     }
33 33
 
34
-    public static function create(?StyleCollection $collection=null) : StyleBuilder
34
+    public static function create(?StyleCollection $collection = null) : StyleBuilder
35 35
     {
36 36
         return new StyleBuilder($collection);
37 37
     }
Please login to merge, or discard this patch.
src/RGBAColor/UnitsConverter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -98,7 +98,7 @@
 block discarded – undo
98 98
 
99 99
     public static function percent2Float(float $percent) : float
100 100
     {
101
-        return round($percent/100, self::$floatPrecision);
101
+        return round($percent / 100, self::$floatPrecision);
102 102
     }
103 103
 
104 104
     public static function float2percent(float $value) : float
Please login to merge, or discard this patch.
src/RGBAColor/ColorComparator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,9 +41,9 @@
 block discarded – undo
41 41
     {
42 42
         $parts = array(RGBAColor::CHANNEL_RED, RGBAColor::CHANNEL_GREEN, RGBAColor::CHANNEL_BLUE);
43 43
 
44
-        foreach($parts as $part)
44
+        foreach ($parts as $part)
45 45
         {
46
-            if($sourceColor->getColor($part)->get8Bit() !== $targetColor->getColor($part)->get8Bit())
46
+            if ($sourceColor->getColor($part)->get8Bit() !== $targetColor->getColor($part)->get8Bit())
47 47
             {
48 48
                 return false;
49 49
             }
Please login to merge, or discard this patch.
src/RGBAColor/FormatsConverter/HEXParser.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -21,18 +21,18 @@
 block discarded – undo
21 21
      * @throws ColorException
22 22
      * @see RGBAColor::ERROR_INVALID_HEX_LENGTH
23 23
      */
24
-    public function parse(string $hex, string $name='') : RGBAColor
24
+    public function parse(string $hex, string $name = '') : RGBAColor
25 25
     {
26 26
         $hex = ltrim($hex, '#'); // Remove the hash if present
27 27
         $hex = strtoupper($hex);
28 28
         $length = strlen($hex);
29 29
 
30
-        if($length === 3)
30
+        if ($length === 3)
31 31
         {
32 32
             return $this->parseHEX3($hex, $name);
33 33
         }
34 34
 
35
-        if($length === 6)
35
+        if ($length === 6)
36 36
         {
37 37
             return $this->parseHEX6($hex, $name);
38 38
         }
Please login to merge, or discard this patch.
examples/htdocs/prepend.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -9,9 +9,9 @@
 block discarded – undo
9 9
 
10 10
 declare(strict_types=1);
11 11
 
12
-$autoload = __DIR__ . '/../vendor/autoload.php';
12
+$autoload = __DIR__.'/../vendor/autoload.php';
13 13
 
14
-if(!file_exists($autoload))
14
+if (!file_exists($autoload))
15 15
 {
16 16
     die('<b>ERROR:</b> Autoloader not present. Please run composer install first.');
17 17
 }
Please login to merge, or discard this patch.
examples/htdocs/URLInfo/highlighting.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
 		<br>
43 43
         <?php
44 44
         
45
-            foreach($urls as $url)
45
+            foreach ($urls as $url)
46 46
             {
47 47
                 $info = parseURL($url);
48 48
                 
Please login to merge, or discard this patch.
src/RGBAColor/ColorChannel/EightBitChannel.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,6 +41,6 @@
 block discarded – undo
41 41
 
42 42
     public function invert() : EightBitChannel
43 43
     {
44
-        return ColorChannel::eightBit(255-$this->value);
44
+        return ColorChannel::eightBit(255 - $this->value);
45 45
     }
46 46
 }
Please login to merge, or discard this patch.
src/RGBAColor/ColorChannel/HexadecimalChannel.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
     {
37 37
         $this->validateValue($value);
38 38
 
39
-        if(strlen($value) === 1)
39
+        if (strlen($value) === 1)
40 40
         {
41 41
             $value = str_repeat($value, 2);
42 42
         }
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
     {
54 54
         $match = preg_match('/\A[0-9A-F]{1,2}\z/iU', $hex);
55 55
 
56
-        if($match !== false && $match > 0)
56
+        if ($match !== false && $match > 0)
57 57
         {
58 58
             return;
59 59
         }
Please login to merge, or discard this patch.