Returns component that renders 'style' tag with css code.

@param string $cssCode
@param string|null $uniqueId specify unique id for inline code to avoid embedding it twice
@return DataView|TagWithText
326831
public function inlineCss($cssCode, $uniqueId = null)
    {
        if ($uniqueId !== null) {
            if ($this->included->isIncluded($uniqueId)) {
                return new DataView();
            } else {
                $this->included->markAsIncluded($uniqueId);
            }
        }
        return new TagWithText('style', $cssCode);
    }
1037261
public void injectUniqueCSS(String cssContent, String wrapperClass)
  {
    if(alreadyAddedCSS == null)
    {
      alreadyAddedCSS = new TreeSet<String>(); 
    }
    
    if(wrapperClass != null)
    {
      cssContent = wrapCSS(cssContent, wrapperClass);
    }
    
    String hashForCssContent = Hashing.md5().hashString(cssContent, Charsets.UTF_8).toString();
    if(!alreadyAddedCSS.contains(hashForCssContent))
    {
//      CSSInject cssInject = new CSSInject(UI.getCurrent());
//      cssInject.setStyles(cssContent);
      Page.getCurrent().getStyles().add(cssContent);
      alreadyAddedCSS.add(hashForCssContent);
    }
  }
590344
public function getStyleByPageId($pageId)
    {
        $style = "";

        $pageStyle  = $this->getServiceLocator()->get('MelisPageStyle');
        if($pageStyle){
            $dataStyle  = $pageStyle->getStyleByPageId($pageId);

            $style = $dataStyle;
        }

        return $style;
    }
896849
public static function mod_css_styles($source, $container_id, $allow_remote = false)
    {
        $last_pos     = 0;
        $replacements = new rcube_string_replacer;

        // ignore the whole block if evil styles are detected
        $source   = self::xss_entity_decode($source);
        $stripped = preg_replace('/[^a-z\(:;]/i', '', $source);
        $evilexpr = 'expression|behavior|javascript:|import[^a]' . (!$allow_remote ? '|url\((?!data:image)' : '');

        if (preg_match("/$evilexpr/i", $stripped)) {
            return '/* evil! */';
        }

        $strict_url_regexp = '!url\s*\([ "\'](https?:)//[a-z0-9/._+-]+["\' ]\)!Uims';

        // cut out all contents between { and }
        while (($pos = strpos($source, '{', $last_pos)) && ($pos2 = strpos($source, '}', $pos))) {
            $nested = strpos($source, '{', $pos+1);
            if ($nested && $nested < $pos2)  // when dealing with nested blocks (e.g. @media), take the inner one
                $pos = $nested;
            $length = $pos2 - $pos - 1;
            $styles = substr($source, $pos+1, $length);

            // Convert position:fixed to position:absolute (#5264)
            $styles = preg_replace('/position:[\s\r\n]*fixed/i', 'position: absolute', $styles);

            // check every line of a style block...
            if ($allow_remote) {
                $a_styles = preg_split('/;[\r\n]*/', $styles, -1, PREG_SPLIT_NO_EMPTY);

                for ($i=0, $len=count($a_styles); $i < $len; $i++) {
                    $line     = $a_styles[$i];
                    $stripped = preg_replace('/[^a-z\(:;]/i', '', $line);

                    // allow data:image uri, join with continuation
                    if (stripos($stripped, 'url(data:image')) {
                        $a_styles[$i] .= ';' . $a_styles[$i+1];
                        unset($a_styles[$i+1]);
                    }
                    // allow strict url() values only
                    else if (stripos($stripped, 'url(') && !preg_match($strict_url_regexp, $line)) {
                        $a_styles = array('/* evil! */');
                        break;
                    }
                }

                $styles = join(";\n", $a_styles);
            }

            $key      = $replacements->add($styles);
            $repl     = $replacements->get_replacement($key);
            $source   = substr_replace($source, $repl, $pos+1, $length);
            $last_pos = $pos2 - ($length - strlen($repl));
        }

        // remove html comments and add #container to each tag selector.
        // also replace body definition because we also stripped off the <body> tag
        $source = preg_replace(
            array(
                '/(^\s*<\!--)|(-->\s*$)/m',
                // (?!##str) below is to not match with ##str_replacement_0##
                // from rcube_string_replacer used above, this is needed for
                // cases like @media { body { position: fixed; } } (#5811)
                '/(^\s*|,\s*|\}\s*|\{\s*)((?!##str)[a-z0-9\._#\*][a-z0-9\.\-_]*)/im',
                '/'.preg_quote($container_id, '/').'\s+body/i',
            ),
            array(
                '',
                "\\1#$container_id \\2",
                $container_id,
            ),
            $source);

        // put block contents back in
        $source = $replacements->resolve($source);

        return $source;
    }
79407
public function getBody( $uid = '' )
	{
		$view = $this->getView();

		$html = '';
		foreach( $this->getSubClients() as $subclient ) {
			$html .= $subclient->setView( $view )->getBody( $uid );
		}

		return $html;
	}
76090
function (onlyCSSDep) {
            var classes = this._cssClasses;
            if (!classes) {
                if (this._cfg.isRootTemplate) {
                    // PTR 05086835: load the global CSS here, and remember that it was loaded
                    var deps = ['aria.templates.GlobalStyle'];
                    if (aria.widgets && aria.widgets.AriaSkin) {
                        deps.push('aria.templates.LegacyGeneralStyle');
                    }
                    ariaTemplatesCSSMgr.loadWidgetDependencies('aria.templates.Template', deps);
                    this._globalCssDepsLoaded = true;
                }
                // Load the CSS dependencies, the style should be added before the html
                classes = ariaTemplatesCSSMgr.loadDependencies(this);
                this._cssClasses = classes; // save classes for later calls
            }
            if (onlyCSSDep) {
                return classes.join(" ");
            }
            var classNames = ["xTplContent"];
            // Add also the classes used by the CSS manager to scope a dependency
            if (classes.length) {
                classNames = classNames.concat(classes);
            }
            return ariaCoreTplClassLoader.addPrintOptions(classNames.join(" "), this._cfg.printOptions);
        }
332699
public function GetAuthentication($UniqueID, $Provider) {
      return $this->SQL->GetWhere('UserAuthentication',
         array('ForeignUserKey' => $UniqueID, 'ProviderKey' => $Provider))->FirstRow(DATASET_TYPE_ARRAY);
   }
936449
public function getCustomCSSAsString()
    {
        // Create CSS Array:
        
        $css = [];
        
        // Merge Custom CSS from Page Controller:
        
        if ($this->owner instanceof PageController) {
            $css = array_merge($css, $this->owner->getCustomCSS());
        }
        
        // Create CSS String:
        
        $css = implode("\n", $css);
        
        // Remove Empty Lines:
        
        $css = ViewTools::singleton()->removeEmptyLines($css);
        
        // Trim CSS String:
        
        $css = trim($css);
        
        // Minify CSS String:
        
        if (!Director::isDev()) {
            $css = ViewTools::singleton()->minifyCSS($css);
        }
        
        // Answer CSS String:
        
        return $css;
    }
548894
public String css(String identifier)
    {
        try {
            return new CSSIdentifierSerializer().serialize(identifier);
        } catch (IllegalArgumentException e) {
            LOGGER.warn("Failed to escape CSS identifier. {}", e.getMessage());
            return null;
        }
    }
515792
public function openOrchestraCss($themeId)
    {
        $tags = '';

        if (isset($this->themes[$themeId]) && isset($this->themes[$themeId]['stylesheets'])) {
            $stylesheets = $this->themes[$themeId]['stylesheets'];
            foreach ($stylesheets as $stylesheet) {
                $tags .= $this->getHtmlTag($stylesheet, self::FILETYPE_CSS);
            }
        }

        return $tags;
    }
944192
public static function getModuleByUniqueId($uniqueId)
    {
        $modules = Yii::$app->loadedModules;
        foreach ($modules as $module) {
            if ($module->uniqueId == $uniqueId) return $module;
        }
        return false;
    }
509491
protected static function formatCode($source, $line, $cssCodeCorrectLineClass, $cssCodeIncorrectLineClass)
    {
        $array = self::formatXhtmlHighlight($source);
        $all = \sizeof($array);
        $len = \strlen($all);
        $page = '';
        for ($i = 0; $i < $all; ++$i) {
            $next = (string)($i + 1);
            $l = \strlen($next);
            $page .= '<span class="' . \htmlspecialchars($line == $next ? $cssCodeIncorrectLineClass : $cssCodeCorrectLineClass) . '">' . ($l < $len ? \str_repeat('&#160;', $len - $l) : '') . $next . '</span> ' . $array[$i] . "\n";
        }

        return $page;
    }
1210112
public static function script($jscode, $url=null) {
        if ($jscode) {
            $attributes = array('type'=>'text/javascript');
            return self::tag('script', "\n//<![CDATA[\n$jscode\n//]]>\n", $attributes) . "\n";

        } else if ($url) {
            $attributes = array('type'=>'text/javascript', 'src'=>$url);
            return self::tag('script', '', $attributes) . "\n";

        } else {
            return '';
        }
    }
1346076
public function insertHeadTags($html, $uniquenessID = null)
    {
        if ($uniquenessID) {
            $this->customHeadTags[$uniquenessID] = $html;
        } else {
            $this->customHeadTags[] = $html;
        }
    }
662197
public function findElementtypeByUniqueId($uniqueId)
    {
        foreach ($this->elementtypeManager->findAll() as $elementtype) {
            if ($elementtype->getUniqueId() === $uniqueId) {
                return $elementtype;
            }
        }

        return null;
    }
1164137
public function setStyle3dId($style3dId)
    {
        $this->style3dId = (string)$style3dId;
        $this->style3d   = null;
        return $this;
    }
749550
public function find(Uid $uniqueId)
    {
        if (!array_key_exists((string) $uniqueId, $this->unitOfWorkStore)) {
            throw new UnitNotFoundException();
        }

        return $this->unitOfWorkStore[(string) $uniqueId];
    }