Skip to content

Copy from Menu (png, json, SQL)#731

Open
MariaPaypoint wants to merge 6 commits intochartdb:mainfrom
MariaPaypoint:copy_png
Open

Copy from Menu (png, json, SQL)#731
MariaPaypoint wants to merge 6 commits intochartdb:mainfrom
MariaPaypoint:copy_png

Conversation

@MariaPaypoint
Copy link
Copy Markdown

@MariaPaypoint MariaPaypoint commented May 28, 2025

image

Add Copy to Menu Feature
This commit introduces a new "Copy" functionality to the application menu, allowing users to easily copy diagram content to the clipboard in various formats. The implementation includes:

New Features:

  • Added "Copy" submenu to the File menu with multiple export options
  • Implemented clipboard copy functionality for:
    • PNG image with transparent background
    • Generic SQL script
    • PostgreSQL script
    • JSON diagram representation

Technical Changes:

  • Enhanced useExportDiagram hook with copyImageToClipboard function
  • Updated export image context to support clipboard operations
  • Added new localization strings for copy functionality across all supported languages (24 locale files updated)
  • Implemented clipboard API integration for image and text content

UI Improvements:

  • Integrated new menu items with appropriate icons and keyboard shortcuts
  • Added proper error handling for clipboard operations
  • This feature improves user experience by providing quick access to diagram exports without requiring file downloads.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 28, 2025

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@MariaPaypoint MariaPaypoint changed the title Copy png Copy from Menu (png, json, SQL) May 28, 2025
@MariaPaypoint
Copy link
Copy Markdown
Author

I have read the CLA Document and I hereby sign the CLA

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.

1 participant