Sha256: 47008361fbea744861f424d91e936ad438bcfdcd10eeea41b6aa9852fa8fd2eb
Contents?: true
Size: 780 Bytes
Versions: 10
Compression:
Stored size: 780 Bytes
Contents
<?php namespace MtHaml\Filter; use MtHaml\NodeVisitor\RendererAbstract as Renderer; use MtHaml\Node\Filter; abstract class Less extends AbstractFilter { public function optimize(Renderer $renderer, Filter $node, $options) { $renderer->write($this->filter($this->getContent($node), array(), $options)); } public function filter($content, array $context, $options) { $css = $this->getCss($content, $context, $options); if (isset($options['cdata']) && $options['cdata'] === true) { return "<style type=\"text/css\">\n/*<![CDATA[*/\n".$css."\n/*]]>*/\n</style>"; } return "<style type=\"text/css\">\n".$css."\n</style>"; } abstract protected function getCss($content, array $context, $options); }
Version data entries
10 entries across 10 versions & 1 rubygems