CssKeyframesRule Class

https://drafts.csswg.org/css-animations/#interface-csskeyframesrule

public sealed class CssKeyframesRule : CssRule
Inheritance
CssRule CssKeyframesRule

Properties

NameDescription
CssRulesGets the list of the keyframe rules.
LengthGets the number of keyframe rules.
NameGets or sets the name of the animation.
TypeGets the legacy numeric type of the rule: CssRule.KeyframesRule for @keyframes rules.

CssRules

CSSRules.cs

Gets the list of the keyframe rules.

public CssRuleList CssRules { get; }

Gets the number of keyframe rules.

public uint Length { get; }

Gets or sets the name of the animation.

public string Name { get; set; }

Gets the legacy numeric type of the rule: CssRule.KeyframesRule for @keyframes rules.

public override ushort Type { get; }

Property value

ushort

Indexers

NameDescription
this[uint]Gets the keyframe rule at the given index, or null when the index is out of range.

this[uint]

CSSRules.cs

Gets the keyframe rule at the given index, or null when the index is out of range.

public CssKeyframeRule? this[uint index] { get; }

Methods

NameDescription
AppendRule(string)Parses a keyframe rule and appends it to the keyframes.
DeleteRule(string)Removes the last keyframe rule whose key text matches the given selector.
FindRule(string)Returns the last keyframe rule whose key text matches the given selector, or null when there is none.

AppendRule(string)

CSSRules.cs

Parses a keyframe rule and appends it to the keyframes.

public void AppendRule(string rule)

DeleteRule(string)

CSSRules.cs

Removes the last keyframe rule whose key text matches the given selector.

public void DeleteRule(string select)

FindRule(string)

CSSRules.cs

Returns the last keyframe rule whose key text matches the given selector, or null when there is none.

public CssKeyframeRule? FindRule(string select)