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

Add "Copy SGF" Button to Game Dock #2695

Closed
wants to merge 1 commit into from

Conversation

pavelwatson
Copy link

@pavelwatson pavelwatson commented May 27, 2024

Proposed Changes

This pull request adds a new "Copy SGF" button to the Game Dock (side panel of the game page), enhancing the user experience by allowing users to copy the SGF content of a game directly to the clipboard. Below are the key changes and features implemented:

New Functionality:

  1. Added a new button labeled "Copy SGF" to the side panel dock.
  2. Implemented functionality to fetch SGF content and copy it to the user's clipboard using the existing sgf_url.
  3. Utilized the existing notification system to alert users when the SGF content is successfully copied.

Component Update:

  1. Modified the GameDock.tsx component to include the new "Copy SGF" button.

Images:

new_button_image
notification-example

Copy link

github-actions bot commented May 27, 2024

Uffizzi Ephemeral Environment deployment-52308

☁️ https://app.uffizzi.com/github.com/online-go/online-go+com/pull/2695

📄 View Application Logs etc.

What is Uffizzi? Learn more!

@anoek
Copy link
Member

anoek commented Jun 1, 2024

I'm a little hesitant to merge this as is only because I question whether there is enough demand for this functionality to justify putting it on the already crowded dock. I'm wondering if putting this within the share dialog box or something would be more appropriate?

@pavelwatson
Copy link
Author

pavelwatson commented Jun 1, 2024

I'm a little hesitant to merge this as is only because I question whether there is enough demand for this functionality to justify putting it on the already crowded dock. I'm wondering if putting this within the share dialog box or something would be more appropriate?

I get your concern. Personally, I think the 'Copy SGF' button would prove it fairly useful. Most Go editors support copy-pasting SGF files directly (pressing Ctrl+V inside an editor). This feature would make it super convenient to just quickly copy the SGF and paste it into any editor without cluttering up your drive with downloaded SGF files.

As to your suggestion, having to dive into the share dialog after every single game would just add unnecessary clicks, making the whole addition a bit pointless.

Another possible approach could be implementing a CTRL+C hotkey on the end game page that copies the SGF content to clipboard. I can work on that if you like the idea.

@anoek
Copy link
Member

anoek commented Jun 1, 2024

This is probably worth some forum discussion on the matter. I'll mark this as draft for now, feel free to open up a thread on the forums and we can proceed based on the discussions had there.

@anoek anoek marked this pull request as draft June 1, 2024 16:54
@yuki2006
Copy link

yuki2006 commented Jul 1, 2024

I also suggested this on a forum a while ago.
https://forums.online-go.com/t/display-sgf-as-on-screen-text/51594/16

I would definitely like to use this.

Copy link

github-actions bot commented Aug 1, 2024

This pull request has been marked stale and will be closed soon without further activity. Please update the PR or respond to this comment if you're still interested in working on this.

@github-actions github-actions bot added the stale Issues or PRs that have been open for a long time with no activity label Aug 1, 2024
Copy link

This pull request has been automatically closed due to inactivity. Please feel free to re-open it if you still want to work on it.

@github-actions github-actions bot closed this Aug 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale Issues or PRs that have been open for a long time with no activity
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants