Repository navigation
fix: [Agent] User information on the debugging page is not clickable #7757
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The diff is valid and the intent is clear. No blocking issue from the shown code, but here are review points:
Import formatting
Should be formatted as:
Or use a separate
import type { ViewType } ...if your lint rules prefer that.Verify
useViewType()return typeThe existing computed:
compares
viewTypedirectly. IfuseViewType()returns aRef/ComputedRef, this is likely a bug and should useviewType.value.In the template, refs are auto-unwrapped, so:
probably works. But for consistency and testability, prefer:
and:
Adjust
.valueonly ifviewTypeis actually a ref.Rename
SHOW_PROFILEIt is not a boolean; it is a list of view types controlling the account menu. A clearer name:
Then:
v-ifdestroys/remountsAccountMenuIf
AccountMenuhas internal state or async initialization, switching view types will destroy and recreate it. Usev-showinstead if state preservation is needed, or keepv-ifif remounting is acceptable.Confirm product behavior
Hiding the account entry in all other view types may remove access to logout/settings. Make sure this is intentional.
Type/export checks
Ensure
ViewTypeis exported from../../view/index, and thatVIEW_TYPE.PORTALis actually part of theViewTypeunion/enum. Otherwise TypeScript will fail.Minor optimization
Array.prototype.includesis fine for two values. If the list grows, use aSet<ViewType>and.has(...). The array is also recreated per component instance in<script setup>; negligible here, but it can be moved to module scope if desired.Suggested small cleanup: