48 references to SpanStart
Microsoft.AspNetCore.Razor.Language.UnitTests (10)
IntegrationTests\ComponentDiscoveryIntegrationTest.cs (2)
231Assert.Equal([directives[0].SpanStart, directives[1].SpanStart], contributions.Select(c => c.DirectiveSpanStart));
IntegrationTests\TagHelpersIntegrationTest.cs (1)
179Assert.Equal(addTagHelperDirective.SpanStart, contribution.DirectiveSpanStart);
RazorCodeDocumentExtensionsTest.cs (7)
73var contribution = new DirectiveTagHelperContribution(usingDirective.SpanStart, TagHelperCollection.Empty); 81Assert.Equal(usingDirective.SpanStart, stored.DirectiveSpanStart); 92new(directives[0].SpanStart, TagHelperCollection.Empty), 93new(directives[1].SpanStart, TagHelperCollection.Empty), 116new(directives[0].SpanStart, TagHelperCollection.Create([usedTagHelper])), 117new(directives[1].SpanStart, TagHelperCollection.Empty), 142codeDocument = codeDocument.WithDirectiveTagHelperContributions([new(directive.SpanStart, TagHelperCollection.Empty)]);
Microsoft.CodeAnalysis.Razor.Compiler (4)
Language\DefaultRazorTagHelperContextDiscoveryPhase.cs (1)
143_directiveContributions.Add(new(directive.SpanStart, contributedTagHelpers));
Language\RazorCodeDocumentExtensions.cs (1)
78if (contribution.DirectiveSpanStart == directive.SpanStart)
Language\Syntax\SyntaxNode.cs (1)
500if (foundToken.SpanStart < this.SpanStart)
Language\Syntax\SyntaxNodeOrToken.cs (1)
200return _nodeOrParent.SpanStart;
Microsoft.CodeAnalysis.Razor.Workspaces (32)
CodeActions\Razor\ComponentAccessibilityCodeActionProvider.cs (1)
50if (context.StartAbsoluteIndex < startTag.SpanStart)
CodeActions\Razor\ExtractToCodeBehindCodeActionProvider.cs (1)
89if (context.StartAbsoluteIndex > csharpCodeBlockNode.SpanStart)
CodeActions\Razor\PromoteUsingCodeActionProvider.cs (1)
50UsingStart = directive.SpanStart,
CodeActions\Razor\WrapAttributesCodeActionProvider.cs (1)
68newLinePositions.Add(attribute.SpanStart + startOffset);
Completion\AbstractRazorCompletionFactsService.cs (1)
83if (originalNode.SpanStart == requestIndex
Completion\DirectiveAttributeCompletionItemProviderBase.cs (4)
82var nameStart = directiveAttributeTransition?.SpanStart ?? attributeNameNode.SpanStart; 96var nameStart = directiveAttributeTransition?.SpanStart ?? attributeNameNode.SpanStart;
Completion\MarkupTransitionCompletionItemProvider.cs (1)
37if (owner is RazorMetaCodeSyntax { SpanStart: var spanStart, MetaCode: [var metaCodeToken, ..] } && spanStart == context.AbsoluteIndex)
Extensions\RazorSyntaxNodeExtensions.cs (2)
126while (node.SpanStart == owner.SpanStart)
Formatting\Passes\CSharpFormattingPass.CSharpDocumentGenerator.cs (5)
342var expressionStartsBlockLambda = IsBlockLambdaStart(node.SpanStart, _sourceText.Lines[nodeStartLine]); 353var skippedPreviousLineText = _sourceText.ToString(TextSpan.FromBounds(node.SpanStart, previousLine.End)); 355skippedPreviousLineOriginOffset = node.SpanStart - previousLine.Start; 1096originOffset: conditions.SpanStart - _currentToken.Position, 1108originOffset: attribute.SpanStart - _currentToken.Position,
Formatting\Passes\CSharpOnTypeFormattingPass.cs (4)
346owner.SpanStart == template.Span.End && 500template.SpanStart == owner.Span.End && 954mappingSpan.Start != owner.SpanStart) 971if (owner.SpanStart == mappingSpan.Start &&
Formatting\Passes\HtmlFormattingPass.cs (2)
285var endTagLine = sourceText.Lines.GetLineFromPosition(endTag.SpanStart); 287var end = firstNonWhitespace == endTag.SpanStart
Hover\HoverFactory.cs (4)
67var ownerStart = owner.SpanStart; 70var ancestors = owner.Ancestors().Where(n => n.SpanStart != ownerStart); 107var ancestors = containingTag.Ancestors().Where(n => n.SpanStart != containingTag.SpanStart);
RazorSyntaxFacts.cs (4)
59attributeNameAbsoluteIndex = attributeName.SpanStart + 5; 63attributeNameAbsoluteIndex = attributeName.SpanStart; 102var start = attributeName.SpanStart; 219GetFullAttributeNameSpan(node.Parent).Start == node.SpanStart)
SpellCheck\SpellCheckService.cs (1)
79ranges.Add(new((int)VSInternalSpellCheckableRangeKind.String, textLiteralSyntax.SpanStart, textLiteralSyntax.Span.Length));
Microsoft.CodeAnalysis.Remote.Razor (2)
DevTools\RemoteDevToolsService.cs (1)
195SpanStart = node.SpanStart,
InlayHints\RemoteInlayHintService.cs (1)
93if (node?.SpanStart == hostDocumentIndex &&