Passed
Pull Request — master (#90)
by
unknown
13:09
created

Bootstrap386Asset   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 15
dl 0
loc 26
ccs 0
cts 4
cp 0
rs 10
c 1
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 10 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace RedCatGirl\YiiBootstrap386\Assets;
6
7
use Yiisoft\Assets\AssetBundle;
8
use Yiisoft\Files\PathMatcher\PathMatcher;
9
10
/**
11
 * Asset bundle for the Twitter bootstrap css files.
12
 *
13
 * BootstrapAsset.
14
 *
15
 * @package Bootstrap386
16
 */
17
final class Bootstrap386Asset extends AssetBundle
18
{
19
    public ?string $basePath = '@assets';
20
21
    public ?string $baseUrl = '@assetsUrl';
22
23
    public ?string $sourcePath = '@vendor/kristopolous/bootsrap.386';
24
25
    public array $css = [
26
        'css/bootstrap.css',
27
    ];
28
29
    public array $js = [
30
        'js/bootstrap.bundle.js',
31
    ];
32
33
    public function __construct()
34
    {
35
        $pathMatcher = new PathMatcher();
36
37
        $this->publishOptions = [
38
            'filter' => $pathMatcher->only(
39
                '**css/bootstrap.css',
40
                '**css/bootstrap.css.map',
41
                '**js/bootstrap.bundle.js',
42
                '**js/bootstrap.bundle.js.map',
43
            ),
44
        ];
45
    }
46
}
47