PropertyDefinition Class
The definition of a custom property registered by Css.RegisterProperty (https://drafts.css-houdini.org/css-properties-values-api/#dictdef-propertydefinition).
public sealed class PropertyDefinitionConstructors
| Name | Description |
|---|---|
| PropertyDefinition() |
PropertyDefinition()
PropertyDefinition.cs- Obsolete: Constructors of types with required members are not supported in this version of your compiler.
[Obsolete("Constructors of types with required members are not supported in this version of your compiler.", true)]
public PropertyDefinition()No documentation is available.
Properties
| Name | Description |
|---|---|
| Inherits | Gets a value indicating whether the custom property inherits its value from its parent. |
| InitialValue | The initial value, required unless the syntax is "*". It must be computationally independent (e.g. 10px, but not 1em or var(--x)). |
| Name | The name of the custom property (e.g. "--my-color"). |
| Syntax | The syntax of the values (e.g. "<color>" or "<length>+ | auto"), "*" for any value. |
Inherits
PropertyDefinition.csGets a value indicating whether the custom property inherits its value from its parent.
public bool Inherits { get; init; }InitialValue
PropertyDefinition.csThe initial value, required unless the syntax is "*". It must be computationally independent (e.g. 10px, but not 1em or var(--x)).
public string? InitialValue { get; init; }The name of the custom property (e.g. "--my-color").
public required string Name { get; init; }Syntax
PropertyDefinition.csThe syntax of the values (e.g. "<color>" or "<length>+ | auto"), "*" for any value.
public string Syntax { get; init; }