Skip to content
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

Implement custom save shortcut in SaveControl component #8407

Conversation

Abhi1992002
Copy link
Contributor

Enhance #8329

This update stops the browser from showing its usual save page pop-up when you press Ctrl/Cmd + S. Instead, it now saves your work in the application, making it easier and quicker to use.

Changes 🏗️

  1. Now,pressing Ctrl/Cmd + S saves changes directly in the app instead of triggering the browser’s save page dialog.

  2. A toast notification confirms successful saves,

@Abhi1992002 Abhi1992002 requested a review from a team as a code owner October 23, 2024 11:48
@Abhi1992002 Abhi1992002 requested review from Torantulino and aarushik93 and removed request for a team October 23, 2024 11:48
@github-actions github-actions bot added platform/frontend AutoGPT Platform - Front end platform/backend AutoGPT Platform - Back end size/m labels Oct 23, 2024
Copy link

PR-Agent was enabled for this repository. To continue using it, please link your git user with your CodiumAI identity here.

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

🎫 Ticket compliance analysis ✅

8329 - Fully compliant

Fully compliant requirements:

  • Bind Ctrl/Command S to save agent on builder
  • Stop browser from showing its usual save page pop-up when Ctrl/Cmd + S is pressed
⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 No relevant tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Possible Performance Issue
The handleSave function is recreated on every render due to its dependency on onSave and isTemplate. Consider memoizing these dependencies or moving the function outside the component if possible.

User Experience
The toast notification for successful save is shown every time Ctrl/Cmd + S is pressed, regardless of whether there were actual changes to save. Consider adding a check for unsaved changes before showing the notification.

Copy link

netlify bot commented Oct 23, 2024

Deploy Preview for auto-gpt-docs canceled.

Name Link
🔨 Latest commit dc28628
🔍 Latest deploy log https://app.netlify.com/sites/auto-gpt-docs/deploys/671965287556ef0008b8aad2

@ntindle ntindle enabled auto-merge (squash) October 23, 2024 21:05
@ntindle ntindle merged commit e908068 into Significant-Gravitas:master Oct 23, 2024
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform/backend AutoGPT Platform - Back end platform/frontend AutoGPT Platform - Front end Review effort [1-5]: 2 size/m
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants