public Extend GetExtend(LessParser.ExtendContext context)
        {
            IEnumerable <Extender> GetExtenders()
            {
                foreach (var extender in context.extenderList().extender())
                {
                    var  elements         = extender.selector().selectorElement();
                    bool partialMatch     = elements.LastOrDefault()?.GetText() == "all";
                    var  selectorElements = partialMatch ? elements.Take(elements.Length - 1) : elements;

                    yield return(new Extender(GetSelector(selectorElements), partialMatch));
                }
            }

            if (context == null)
            {
                return(null);
            }

            return(new Extend(GetExtenders()));
        }
Exemplo n.º 2
0
 public LessNode VisitExtend(LessParser.ExtendContext context)
 {
     throw new System.NotImplementedException();
 }