Skip to content

Improve Component Communication Logic#9730

Merged
chidozieononiwu merged 1 commit intoAzure:mainfrom
chidozieononiwu:bugFix/CodeLineSearch
Jan 29, 2025
Merged

Improve Component Communication Logic#9730
chidozieononiwu merged 1 commit intoAzure:mainfrom
chidozieononiwu:bugFix/CodeLineSearch

Conversation

@chidozieononiwu
Copy link
Copy Markdown
Member

  • Improve component communication logic for codeline search

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 5 out of 7 changed files in this pull request and generated 1 comment.

Files not reviewed (2)
  • src/dotnet/APIView/ClientSPA/src/app/_components/review-page-options/review-page-options.component.html: Language not supported
  • src/dotnet/APIView/ClientSPA/src/app/_components/review-page/review-page.component.html: Language not supported
Comments suppressed due to low confidence (4)

src/dotnet/APIView/ClientSPA/src/app/_components/review-page/review-page.component.ts:499

  • The use of setTimeout with a delay of 0 might be unnecessary and could introduce unexpected behavior. Ensure this is intentional and necessary.
setTimeout(() => { this.codeLineSearchInfo = (value) ? new CodeLineSearchInfo(value.currentMatch, value.totalMatchCount) : undefined; }, 0);

src/dotnet/APIView/ClientSPA/src/app/_components/review-page-options/review-page-options.component.ts:376

  • The term 'Naviation' is misspelled. It should be 'Navigation'.
this.codeLineSearchNaviationEmmiter.emit(navigationPosition!);

src/dotnet/APIView/ClientSPA/src/app/_components/review-page-options/review-page-options.component.ts:376

  • [nitpick] The parameter name 'number' is ambiguous. It should be renamed to 'direction'.
navigateSearch(number: 1 | -1)

src/dotnet/APIView/ClientSPA/src/app/_components/code-panel/code-panel.component.ts:853

  • The optional chaining operator ?. should be used consistently. The currentMatch property is already checked, so value should not use ?..
this.scrollToNode(this.codeLineSearchInfo?.currentMatch.value.nodeIdHashed, undefined, false, false);

@chidozieononiwu chidozieononiwu merged commit 88538f4 into Azure:main Jan 29, 2025
@chidozieononiwu chidozieononiwu deleted the bugFix/CodeLineSearch branch January 29, 2025 23:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants