Property | Type | Description | |
---|---|---|---|
$_absoluteCacheCssDir | string | Parent directory of cached CSS file (absolute path) | |
$_absoluteCacheCssPath | string | Cached CSS file (absolute path) | |
$_absoluteCachePathBase | string | Base path for all cache files | |
$_absoluteCachePhpPath | string | Cached CSS file (absolute path) | |
$_absoluteCssPath | string | Requested CSS file (absolute path) | |
$_blocks | array | CSS Blocks | |
$_breakpointCatalog | array | Media Query condition catalog | |
$_breakpointIndex | array | Media Query condition index | |
$_breakpointTypes | array | Breakpoint types | |
$_importPatterns | array | Import at-rule patterns | |
$_lines | array | Line lengths | |
$_minifier | Tollwerk\Squeezr\Css\Minifier | Minification provider | |
$_relativeCssPath | string | Requested CSS file (relative path to document root) |
Method | Description | |
---|---|---|
instance ( string $css ) : |
Instanciate a CSS proxy | |
send ( boolean $cache = true ) : void | Parse, squeeze and send the CSS file to the client |
Method | Description | |
---|---|---|
__construct ( string $css ) | Constructor | |
_breakpointIndex ( integer $type, array $condition ) : integer | Determine / create and return a breakpoint index entry | |
_breakpoints ( string $mediaQuery ) : array | null | Extract the relevant breakpoints out of a @media query | |
_compileCacheClassCode ( ) : string | Compile a PHP cache class representing the loaded CSS stylesheet | |
_consumeDeclarationBlock ( string $css, integer $peek, integer $offset, integer &$declarationBlockStart ) : string | Detect and consume a declaration block within the given CSS text | |
_minify ( string $css ) : string | Minifiy a CSS block (in case a minification provider has been registered) | |
_parse ( ) | Parse and analyze the requested CSS file | |
_peekToLine ( integer $peek ) : integer | Find the line number corresponding with a peek position within the CSS file | |
_registerBlock ( string &$block, array $breakpoints = null ) | Register block data |
protected __construct ( string $css ) | ||
$css | string | Requested CSS file (relative to document root) |
protected _compileCacheClassCode ( ) : string | ||
return | string | PHP class code |
protected _consumeDeclarationBlock ( string $css, integer $peek, integer $offset, integer &$declarationBlockStart ) : string | ||
$css | string | CSS text |
$peek | integer | Current peek (for line number detection in case of an error) |
$offset | integer | Optional: Offset position |
$declarationBlockStart | integer | Set by reference: Declaration block start position within the CSS text |
return | string | Declaration block (starting at the beginning of the CSS text) |
protected _peekToLine ( integer $peek ) : integer | ||
$peek | integer | Peek position |
return | integer | Line number |
protected _registerBlock ( string &$block, array $breakpoints = null ) | ||
$block | string | Block data |
$breakpoints | array | Breakpoints |
protected string $_absoluteCacheCssDir | ||
return | string |
protected string $_absoluteCacheCssPath | ||
return | string |
protected string $_absoluteCachePathBase | ||
return | string |
protected string $_absoluteCachePhpPath | ||
return | string |
protected string $_absoluteCssPath | ||
return | string |
protected array $_breakpointCatalog | ||
return | array |
protected array $_breakpointIndex | ||
return | array |
protected static array $_breakpointTypes | ||
return | array |
protected static array $_importPatterns | ||
return | array |
protected Minifier,Tollwerk\Squeezr\Css $_minifier | ||
return | Tollwerk\Squeezr\Css\Minifier |
protected string $_relativeCssPath | ||
return | string |