예제 #1
0
 /// <summary>
 /// Takes a string and transforms it into a CSS keyframe rule.
 /// </summary>
 internal CssKeyframeRule ParseKeyframeRule(String ruleText)
 {
     var tokenizer = CreateTokenizer(ruleText, _config);
     var token = tokenizer.Get();
     var state = new CssKeyframesState(tokenizer, this);
     var rule = state.CreateKeyframeRule(token);
     return tokenizer.Get().Type == CssTokenType.Eof ? rule : null;
 }
예제 #2
0
 /// <summary>
 /// Takes a string and transforms it into a keyframe selector object.
 /// </summary>
 public IKeyframeSelector ParseKeyframeSelector(String keyText)
 {
     var tokenizer = CreateTokenizer(keyText, _config);
     var token = tokenizer.Get();
     var state = new CssKeyframesState(tokenizer, this);
     var selector = state.CreateKeyframeSelector(ref token);
     return token.Type == CssTokenType.Eof ? selector : null;
 }