Passed
Push — master ( b8e171...9e4d7b )
by Gabriel
04:14 queued 12s
created

Nip_Form_Renderer_Bootstrap4   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
eloc 5
c 0
b 0
f 0
dl 0
loc 13
ccs 5
cts 5
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A getLabelClassesForElement() 0 7 1
1
<?php
2
3
/**
4
 * Class Bootstrap4
5
 */
6
class Nip_Form_Renderer_Bootstrap4 extends Nip_Form_Renderer_Bootstrap
7
{
8
9
    /**
10
     * @inheritDoc
11
     */
12 1
    protected function getLabelClassesForElement($element)
13
    {
14 1
        $classes = parent::getLabelClassesForElement($element);
15 1
        $key = array_search('control-label', $classes);
16 1
        $classes[$key] = 'col-form-label';
17
18 1
        return $classes;
19
    }
20
}
21