class SizeStyle extends Style (View source)

Properties

protected string $name

The name of this style.

from  Style
protected string $variable

The name of the associated CSS variable.

from  Style

Methods

render(Value|null|false $value = false)

No description

Value|null
getValueFromRequest(ParameterBag $request)

No description

Value|null
getValueFromList(ValueList $list)

Get the value of this style extracted from a list of values.

from  Style
static string
getTypeFromClass(Style|object $class, string $suffix = 'Style')

Get the type handle of a given Style instance.

from  Style
$this
setName(string $name)

Set the name of this style.

from  Style
string
getName()

Get the name of this style.

from  Style
string
getDisplayName(string $format = 'html')

Get the display name for this style (localized and escaped accordingly to $format).

from  Style
$this
setVariable(string $variable)

Set the name of the associated CSS variable.

from  Style
string
getVariable()

Get the name of the associated CSS variable.

from  Style
string
getFormElementPath()

Get a path to an elements directory for this Style. Might not be used by all styles.

from  Style
static Value[]
getValuesFromVariables(mixed $rules = [])

No description

static SizeValue|null
parse(Less_Tree_Dimension|mixed $value, string|null|false $variable = false)

Extract a size value from a Less node.

Details

render(Value|null|false $value = false)

No description

Parameters

Value|null|false $value

the current style value

See also

Style::render

Value|null getValueFromRequest(ParameterBag $request)

No description

Parameters

ParameterBag $request

the received data

Return Value

Value|null

See also

Style::getValueFromRequest

Value|null getValueFromList(ValueList $list)

Get the value of this style extracted from a list of values.

Parameters

ValueList $list

Return Value

Value|null

static protected string getTypeFromClass(Style|object $class, string $suffix = 'Style')

Get the type handle of a given Style instance.

Parameters

Style|object $class
string $suffix

Return Value

string

$this setName(string $name)

Set the name of this style.

Parameters

string $name

Return Value

$this

string getName()

Get the name of this style.

Return Value

string

string getDisplayName(string $format = 'html')

Get the display name for this style (localized and escaped accordingly to $format).

Parameters

string $format

= 'html' Escape the result in html format (if $format is 'html'). If $format is 'text' or any other value, the display name won't be escaped.

Return Value

string

$this setVariable(string $variable)

Set the name of the associated CSS variable.

Parameters

string $variable

Return Value

$this

string getVariable()

Get the name of the associated CSS variable.

Return Value

string

string getFormElementPath()

Get a path to an elements directory for this Style. Might not be used by all styles.

Return Value

string

static Value[] getValuesFromVariables(mixed $rules = [])

No description

Parameters

mixed $rules

Return Value

Value[]

See also

Style::getValuesFromVariables

static SizeValue|null parse(Less_Tree_Dimension|mixed $value, string|null|false $variable = false)

Extract a size value from a Less node.

Parameters

Less_Tree_Dimension|mixed $value
string|null|false $variable

The associated CSS variable

Return Value

SizeValue|null