protected function loadCss()
    {
        $oAsset = Factory::service('Asset');

        //  Module assets
        $oAsset->load('nails.admin.css', 'NAILS');
        $oAsset->load('admin.css', 'nails/module-admin');

        //  Component assets
        foreach (Components::available() as $oComponent) {
            if (!empty($oComponent->data->{'nails/module-admin'}->autoload)) {

                $oAutoLoad = $oComponent->data->{'nails/module-admin'}->autoload;

                if (!empty($oAutoLoad->assets->css)) {
                    foreach ($oAutoLoad->assets->css as $mAsset) {

                        if (is_string($mAsset)) {
                            $sAsset    = $mAsset;
                            $sLocation = $oComponent->slug;
                        } else {
                            $sAsset    = !empty($mAsset[0]) ? $mAsset[0] : null;
                            $sLocation = !empty($mAsset[1]) ? $mAsset[1] : null;
                        }

                        $oAsset->load($sAsset, $sLocation, 'CSS');
                    }
                }

                //  CSS Inline
                if (!empty($oAutoLoad->assets->cssInline)) {
                    foreach ($oAutoLoad->assets->cssInline as $sAsset) {
                        $oAsset->inline($sAsset, 'CSS');
                    }
                }
            }
        }

        //  Global CSS
        $sAdminCssPath = defined('APP_ADMIN_CSS_PATH') ? APP_ADMIN_CSS_PATH : NAILS_APP_PATH . 'assets/build/css/admin.min.css';
        $sAdminCssUrl  = defined('APP_ADMIN_CSS_URL') ? APP_ADMIN_CSS_URL : 'admin.min.css';
        if (file_exists($sAdminCssPath)) {
            $oAsset->load($sAdminCssUrl);
        }
    }
protected function loadCss()
    {
        $oAsset = Factory::service('Asset');

        //  Module assets
        $oAsset->load('nails.admin.css', 'NAILS');
        $oAsset->load('admin.css', 'nails/module-admin');

        //  Component assets
        foreach (Components::available() as $oComponent) {
            if (!empty($oComponent->data->{'nails/module-admin'}->autoload)) {

                $oAutoLoad = $oComponent->data->{'nails/module-admin'}->autoload;

                if (!empty($oAutoLoad->assets->css)) {
                    foreach ($oAutoLoad->assets->css as $mAsset) {

                        if (is_string($mAsset)) {
                            $sAsset    = $mAsset;
                            $sLocation = $oComponent->slug;
                        } else {
                            $sAsset    = !empty($mAsset[0]) ? $mAsset[0] : null;
                            $sLocation = !empty($mAsset[1]) ? $mAsset[1] : null;
                        }

                        $oAsset->load($sAsset, $sLocation, 'CSS');
                    }
                }

                //  CSS Inline
                if (!empty($oAutoLoad->assets->cssInline)) {
                    foreach ($oAutoLoad->assets->cssInline as $sAsset) {
                        $oAsset->inline($sAsset, 'CSS');
                    }
                }
            }
        }

        //  Global CSS
        $sAdminCssPath = defined('APP_ADMIN_CSS_PATH') ? APP_ADMIN_CSS_PATH : NAILS_APP_PATH . 'assets/build/css/admin.min.css';
        $sAdminCssUrl  = defined('APP_ADMIN_CSS_URL') ? APP_ADMIN_CSS_URL : 'admin.min.css';
        if (file_exists($sAdminCssPath)) {
            $oAsset->load($sAdminCssUrl);
        }
    }
protected function loadCss ( ) { $ oAsset = Factory :: service ( 'Asset' ) ; //  Module assets $ oAsset -> load ( 'nails.admin.css' , 'NAILS' ) ; $ oAsset -> load ( 'admin.css' , 'nails/module-admin' ) ; //  Component assets foreach ( Components :: available ( ) as $ oComponent ) { if ( ! empty ( $ oComponent -> data -> { 'nails/module-admin' } -> autoload ) ) { $ oAutoLoad = $ oComponent -> data -> { 'nails/module-admin' } -> autoload ; if ( ! empty ( $ oAutoLoad -> assets -> css ) ) { foreach ( $ oAutoLoad -> assets -> css as $ mAsset ) { if ( is_string ( $ mAsset ) ) { $ sAsset = $ mAsset ; $ sLocation = $ oComponent -> slug ; } else { $ sAsset = ! empty ( $ mAsset [ 0 ] ) ? $ mAsset [ 0 ] : null ; $ sLocation = ! empty ( $ mAsset [ 1 ] ) ? $ mAsset [ 1 ] : null ; } $ oAsset -> load ( $ sAsset , $ sLocation , 'CSS' ) ; } } //  CSS Inline if ( ! empty ( $ oAutoLoad -> assets -> cssInline ) ) { foreach ( $ oAutoLoad -> assets -> cssInline as $ sAsset ) { $ oAsset -> inline ( $ sAsset , 'CSS' ) ; } } } } //  Global CSS $ sAdminCssPath = defined ( 'APP_ADMIN_CSS_PATH' ) ? APP_ADMIN_CSS_PATH : NAILS_APP_PATH . 'assets/build/css/admin.min.css' ; $ sAdminCssUrl = defined ( 'APP_ADMIN_CSS_URL' ) ? APP_ADMIN_CSS_URL : 'admin.min.css' ; if ( file_exists ( $ sAdminCssPath ) ) { $ oAsset -> load ( $ sAdminCssUrl ) ; } }
Load all Admin orientated CSS

@throws \Nails\Common\Exception\FactoryException
Load all Admin orientated CSS