Skip to content

Conversation

roomote[bot]
Copy link

@roomote roomote bot commented Oct 14, 2025

Description

This PR attempts to address Issue #8646 where the restore button for the last/current checkpoint shows an empty floating window.

Problem

When clicking the restore button on a checkpoint marked as "current", the popover opens but displays no content, resulting in an empty floating window that confuses users.

Solution

  • Added a condition to display a message "This checkpoint is already current" when the checkpoint is the current one
  • Restructured the popover content to handle both current and non-current checkpoint states
  • Added the missing translation key to the English locale file

Changes

  • Modified CheckpointMenu.tsx to show appropriate content for current checkpoints
  • Added alreadyCurrent translation key to en/chat.json
  • Removed duplicate nested div wrapper found during code review

Testing

  • All existing tests pass
  • Linting and type checking pass

Fixes #8646

Feedback and guidance are welcome!


Important

Fixes empty popover issue for current checkpoint restore button by adding a message and restructuring content in CheckpointMenu.tsx.

  • Behavior:
    • In CheckpointMenu.tsx, added a message "This checkpoint is already current" for current checkpoints to prevent empty popover.
    • Restructured popover content to handle current and non-current checkpoint states.
  • Translations:
    • Added alreadyCurrent translation key to en/chat.json and 19 other locale files.
  • Misc:
    • Removed duplicate nested div wrapper in CheckpointMenu.tsx.
    • All existing tests pass, and linting and type checking pass.

This description was created by Ellipsis for 8ed8186. You can customize this summary. It will automatically update as commits are pushed.

…tore button

- Added message display when trying to restore the current checkpoint
- Fixed empty popover issue reported in #8646
- Added 'alreadyCurrent' translation key to English locale
"cannotUndo": "This action cannot be undone.",
"restoreFilesAndTaskDescription": "Restores your project's files back to a snapshot taken at this point and deletes all messages after this point."
"restoreFilesAndTaskDescription": "Restores your project's files back to a snapshot taken at this point and deletes all messages after this point.",
"alreadyCurrent": "This checkpoint is already current"
Copy link

Choose a reason for hiding this comment

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

The message for "alreadyCurrent" is missing a period at the end. For consistency with other messages in this file (e.g., "cannotUndo"), consider adding a full stop.

Suggested change
"alreadyCurrent": "This checkpoint is already current"
"alreadyCurrent": "This checkpoint is already current."

This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.

"cannotUndo": "Aksi ini tidak dapat dibatalkan.",
"restoreFilesAndTaskDescription": "Mengembalikan file proyek kamu ke snapshot yang diambil pada titik ini dan menghapus semua pesan setelah titik ini."
"restoreFilesAndTaskDescription": "Mengembalikan file proyek kamu ke snapshot yang diambil pada titik ini dan menghapus semua pesan setelah titik ini.",
"alreadyCurrent": "This checkpoint is already current"
Copy link

Choose a reason for hiding this comment

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

The new key "alreadyCurrent" is currently using English text in an Indonesian locale file. If this is unintended, please update it to an Indonesian translation for consistency. Otherwise, consider adding a comment clarifying the mixed language usage.

Suggested change
"alreadyCurrent": "This checkpoint is already current"
"alreadyCurrent": "Checkpoint ini sudah menjadi yang terbaru"

This comment was generated because it violated a code review rule: irule_C0ez7Rji6ANcGkkX.

@hannesrudolph hannesrudolph added the Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. label Oct 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working Issue/PR - Triage New issue. Needs quick review to confirm validity and assign labels. size:S This PR changes 10-29 lines, ignoring generated files.

Projects

Status: Triage

Development

Successfully merging this pull request may close these issues.

[BUG] The restore button of the last checkpoint does not work properly (!isCurrent condition causes incorrect node rendering.)

2 participants