Skip to content

Comments

fix(vscode): add back button to profile view header#599

Open
Olusammytee wants to merge 2 commits intoKilo-Org:devfrom
Olusammytee:fix/568-profile-back-button-v2
Open

fix(vscode): add back button to profile view header#599
Olusammytee wants to merge 2 commits intoKilo-Org:devfrom
Olusammytee:fix/568-profile-back-button-v2

Conversation

@Olusammytee
Copy link
Contributor

@Olusammytee Olusammytee commented Feb 22, 2026

Linked Issue\nCloses #568\n\n## Summary\n- add a back button to the Profile view header using the same UX pattern as Settings\n- wire Profile view back action to return users to the chat view\n- keep existing profile content unchanged\n\n## Testing\n- unable to run package checks in this environment (bun not installed)

@github-actions
Copy link
Contributor

Thanks for your contribution!

This PR doesn't have a linked issue. All PRs must reference an existing issue.

Please:

  1. Open an issue describing the bug/feature (if one doesn't exist)
  2. Add Fixes #<number> or Closes #<number> to this PR description

See CONTRIBUTING.md for details.

<h2 style={{ "font-size": "16px", "font-weight": "600", margin: 0 }}>{language.t("profile.title")}</h2>
</div>
<div style={{ padding: "16px" }}>
<Show
Copy link
Contributor

Choose a reason for hiding this comment

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

[SUGGESTION]: Indentation is off — <Show> (and its children through line 266) is now nested inside the <div style={{ padding: "16px" }}> wrapper on line 119, but it's not indented to reflect that. The closing </Show> on line 266 and </div> on line 267 have the same issue. This makes the JSX tree structure harder to follow.

Suggested change
<Show
<Show

@kiloconnect
Copy link
Contributor

kiloconnect bot commented Feb 22, 2026

Code Review Summary

Status: No New Issues Found | Recommendation: Merge (after addressing existing feedback)

Overview

This PR adds a back button to the Profile view header, following the same UX pattern already established in the Settings component. The implementation is clean and consistent:

  • The header layout, back button, tooltip, and icon usage in ProfileView.tsx exactly mirrors Settings.tsx
  • The onBack prop is correctly typed as optional (onBack?: () => void) and safely invoked with optional chaining (props.onBack?.())
  • The common.goBack i18n key is already defined across all locale files
  • The --border-weak-base CSS variable is widely used in the codebase

Existing feedback from other reviewers (indentation + overflow handling) should still be addressed before merge.

Files Reviewed (2 files)
  • packages/kilo-vscode/webview-ui/src/App.tsx - 0 new issues
  • packages/kilo-vscode/webview-ui/src/components/ProfileView.tsx - 0 new issues (existing reviewer feedback covers indentation and overflow concerns)

Copy link
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.

Pull request overview

This PR restores navigational parity between the Profile and Settings views in the VS Code webview UI by adding a header back button to Profile and wiring it to return users to the chat view.

Changes:

  • Add a Settings-like header (with back button) to ProfileView.
  • Extend ProfileView props with an optional onBack callback and invoke it from the new back button.
  • Wire Profile back navigation in AppContent to return to the "newTask" (chat) view.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
packages/kilo-vscode/webview-ui/src/components/ProfileView.tsx Adds a header with back button and wraps existing profile content under a new layout container.
packages/kilo-vscode/webview-ui/src/App.tsx Passes an onBack handler to ProfileView that navigates back to chat ("newTask").

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

</Tooltip>
<h2 style={{ "font-size": "16px", "font-weight": "600", margin: 0 }}>{language.t("profile.title")}</h2>
</div>
<div style={{ padding: "16px" }}>
Copy link

Copilot AI Feb 22, 2026

Choose a reason for hiding this comment

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

Because the root is a fixed-height flex column (height: "100%") and the webview .container uses overflow: hidden, the content wrapper needs to participate in flex layout (and typically scroll) or long profile content can be clipped with no way to scroll. Consider giving the content <div> flex: 1, min-height: 0, and overflow-y: auto (or similar), matching how other full-height views manage overflow.

Suggested change
<div style={{ padding: "16px" }}>
<div
style={{
padding: "16px",
display: "flex",
"flex-direction": "column",
flex: 1,
"min-height": 0,
"overflow-y": "auto",
}}
>

Copilot uses AI. Check for mistakes.
Comment on lines 119 to 121
<div style={{ padding: "16px" }}>
<Show
when={props.profileData}
Copy link

Copilot AI Feb 22, 2026

Choose a reason for hiding this comment

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

The <Show> block is not indented under the new padded content wrapper, which makes the JSX structure harder to read and can trip formatting checks. Running Prettier (or adjusting indentation) would keep this consistent with the rest of the codebase.

Copilot uses AI. Check for mistakes.
@Olusammytee
Copy link
Contributor Author

Updated the PR description to include an explicit linked issue reference: Closes #568.

@Olusammytee
Copy link
Contributor Author

Addressed the formatting suggestion by aligning indentation for the Show block inside the padded content wrapper (commit �d5b340).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant