Example #1
0
            public override SyntaxNode VisitMarkupEphemeralTextLiteral(MarkupEphemeralTextLiteralSyntax node)
            {
                if (!_tryParseResult.IsBoundNonStringAttribute)
                {
                    return(base.VisitMarkupEphemeralTextLiteral(node));
                }

                // Since this is a non-string attribute we need to rewrite this as code.
                // Rewriting it to CSharpEphemeralTextLiteral so that it is not rendered to output.
                _rewriteAsMarkup = true;
                node             = (MarkupEphemeralTextLiteralSyntax)ConfigureNonStringAttribute(node);
                var tokens = new SyntaxList <SyntaxToken>(node.LiteralTokens);
                var value  = SyntaxFactory.CSharpEphemeralTextLiteral(tokens);

                return(value.WithSpanContext(node.GetSpanContext()));
            }
Example #2
0
 public override void VisitMarkupEphemeralTextLiteral(MarkupEphemeralTextLiteralSyntax node)
 {
     WriteSpan(node, FormattingSpanKind.Markup);
     base.VisitMarkupEphemeralTextLiteral(node);
 }
Example #3
0
 public override void VisitMarkupEphemeralTextLiteral(MarkupEphemeralTextLiteralSyntax node)
 {
     WriteNode(node, isHtml: true, base.VisitMarkupEphemeralTextLiteral);
 }
Example #4
0
 public override void VisitMarkupEphemeralTextLiteral(MarkupEphemeralTextLiteralSyntax node)
 {
     WriteSpan(node, SpanKindInternal.Markup);
     base.VisitMarkupEphemeralTextLiteral(node);
 }