PHP Класс Pressbooks\Sass

Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
$errorsEmail array Email addresses to send log errors.

Открытые методы

Метод Описание
applyOverrides ( string $scss, string $overrides ) : string Prepend or append SCSS overrides depending on which version of the theme architecture is in use.
compile ( string $scss, array $includes = [] ) : string Returns the compiled CSS from SCSS input
debug ( string $css, $scss, string $filename ) Write CSS to a a debug dir
defaultIncludePaths ( string $type, $theme = null ) Get default include paths
getStringsToLocalize ( ) : array Fetch an array of strings in (S)CSS which need to be localized
isCurrentThemeCompatible ( integer $version = 1, $theme = null ) : boolean Are the current theme's stylesheets SCSS compatible?
parseVariables ( string $scss ) : array Parse an SCSS file into an array of variables.
pathToDebugDir ( ) : string Get path to a directory we can dump debug files into
pathToFonts ( ) : string Get the path to our PB Fonts
pathToGlobals ( ) : string Get the path to our PB Partials
pathToPartials ( ) : string Get the path to our PB Partials
pathToUserGeneratedCss ( ) : string Get path to a directory we can dump user transpiled CSS files into (create dir if it does not exist)
pathToUserGeneratedSass ( ) : string Get path to a directory we can dump user generated Sass files into (create dir if it does not exist)
prependLocalizedVars ( string $scss ) : string Prepend localized version of content string variables.
urlToUserGeneratedCss ( ) : string Get URI to user transpiled CSS files

Защищенные методы

Метод Описание
logException ( Exception $e ) Log Exceptions

Описание методов

applyOverrides() публичный Метод

Prepend or append SCSS overrides depending on which version of the theme architecture is in use.
public applyOverrides ( string $scss, string $overrides ) : string
$scss string The theme SCSS.
$overrides string The SCSS overrides.
Результат string

compile() публичный Метод

Returns the compiled CSS from SCSS input
public compile ( string $scss, array $includes = [] ) : string
$scss string
$includes array (optional)
Результат string

debug() публичный Метод

Write CSS to a a debug dir
public debug ( string $css, $scss, string $filename )
$css string
$filename string

defaultIncludePaths() публичный Метод

Get default include paths
public defaultIncludePaths ( string $type, $theme = null )
$type string

getStringsToLocalize() публичный Метод

Fetch an array of strings in (S)CSS which need to be localized
public getStringsToLocalize ( ) : array
Результат array

isCurrentThemeCompatible() публичный Метод

Are the current theme's stylesheets SCSS compatible?
public isCurrentThemeCompatible ( integer $version = 1, $theme = null ) : boolean
$version integer
Результат boolean

logException() защищенный Метод

Log Exceptions
protected logException ( Exception $e )
$e Exception

parseVariables() публичный Метод

Parse an SCSS file into an array of variables.
public parseVariables ( string $scss ) : array
$scss string
Результат array

pathToDebugDir() публичный Метод

Get path to a directory we can dump debug files into
public pathToDebugDir ( ) : string
Результат string

pathToFonts() публичный Метод

Get the path to our PB Fonts
public pathToFonts ( ) : string
Результат string

pathToGlobals() публичный Метод

Get the path to our PB Partials
public pathToGlobals ( ) : string
Результат string

pathToPartials() публичный Метод

Get the path to our PB Partials
public pathToPartials ( ) : string
Результат string

pathToUserGeneratedCss() публичный Метод

Get path to a directory we can dump user transpiled CSS files into (create dir if it does not exist)
public pathToUserGeneratedCss ( ) : string
Результат string

pathToUserGeneratedSass() публичный Метод

Get path to a directory we can dump user generated Sass files into (create dir if it does not exist)
public pathToUserGeneratedSass ( ) : string
Результат string

prependLocalizedVars() публичный Метод

Prepend localized version of content string variables.
public prependLocalizedVars ( string $scss ) : string
$scss string
Результат string

urlToUserGeneratedCss() публичный Метод

Get URI to user transpiled CSS files
public urlToUserGeneratedCss ( ) : string
Результат string

Описание свойств

$errorsEmail публичное свойство

Email addresses to send log errors.
public array $errorsEmail
Результат array