src/console/DoController.php
public function genCss()
    {
        $sizes = [
            'xs' => 'height: 38px; width: 60px;',
            'sm' => 'height: 75px; width: 120px;',
            'md' => 'height: 240px; width: 150px;',
            'lg' => 'height: 480px; width: 300px;',
        ];

        $res = '.pi { display: inline-block;height: 38px;width: 60px; }' . PHP_EOL;

        foreach (array_keys($sizes) as $size) {
            $res .= ".pi.pi-$size { $sizes[$size] }" . PHP_EOL;
        }

        foreach (array_keys($sizes) as $size) {
            foreach ($this->getIconsList() as $name) {
                if ($size === 'xs') {
                    $res .= ".pi.pi-$size.pi-$name, .pi.pi-$name { background: url('../png/$size/$name.png') no-repeat right; }" . PHP_EOL;
                } else {
                    $res .= ".pi.pi-$size.pi-$name { background: url('../png/$size/$name.png') no-repeat right; }" . PHP_EOL;
                }
            }
            $res .= PHP_EOL;
        }

        return $res;
    }
public function genCss()
    {
        $sizes = [
            'xs' => 'height: 38px; width: 60px;',
            'sm' => 'height: 75px; width: 120px;',
            'md' => 'height: 240px; width: 150px;',
            'lg' => 'height: 480px; width: 300px;',
        ];

        $res = '.pi { display: inline-block;height: 38px;width: 60px; }' . PHP_EOL;

        foreach (array_keys($sizes) as $size) {
            $res .= ".pi.pi-$size { $sizes[$size] }" . PHP_EOL;
        }

        foreach (array_keys($sizes) as $size) {
            foreach ($this->getIconsList() as $name) {
                if ($size === 'xs') {
                    $res .= ".pi.pi-$size.pi-$name, .pi.pi-$name { background: url('../png/$size/$name.png') no-repeat right; }" . PHP_EOL;
                } else {
                    $res .= ".pi.pi-$size.pi-$name { background: url('../png/$size/$name.png') no-repeat right; }" . PHP_EOL;
                }
            }
            $res .= PHP_EOL;
        }

        return $res;
    }
public function genCss ( ) { $ sizes = [ 'xs' => 'height: 38px; width: 60px;' , 'sm' => 'height: 75px; width: 120px;' , 'md' => 'height: 240px; width: 150px;' , 'lg' => 'height: 480px; width: 300px;' , ] ; $ res = '.pi { display: inline-block;height: 38px;width: 60px; }' . PHP_EOL ; foreach ( array_keys ( $ sizes ) as $ size ) { $ res .= ".pi.pi-$size { $sizes[$size] }" . PHP_EOL ; } foreach ( array_keys ( $ sizes ) as $ size ) { foreach ( $ this -> getIconsList ( ) as $ name ) { if ( $ size === 'xs' ) { $ res .= ".pi.pi-$size.pi-$name, .pi.pi-$name { background: url('../png/$size/$name.png') no-repeat right; }" . PHP_EOL ; } else { $ res .= ".pi.pi-$size.pi-$name { background: url('../png/$size/$name.png') no-repeat right; }" . PHP_EOL ; } } $ res .= PHP_EOL ; } return $ res ; }
Generates CSS file.
@return string
Generates CSS file .