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

[Proposal] Add Copy Button to Text styled in a specific language #15982

Closed
delvh opened this issue May 26, 2021 · 5 comments
Closed

[Proposal] Add Copy Button to Text styled in a specific language #15982

delvh opened this issue May 26, 2021 · 5 comments
Labels
topic/ui Change the appearance of the Gitea UI type/feature Completely new functionality. Can only be merged if feature freeze is not active.

Comments

@delvh
Copy link
Member

delvh commented May 26, 2021

Description

GitHub has added the feature to copy text styled in a specific language using

    ```<language>
    Some text
    ```

by clicking on a button that on the right-upper corner of the generated area that appears only when the user hovers over that area (see above on the right).
I find that useful as often times the reason why something has been styled in that specific language is to allow for copy and pasting code.

@silverwind
Copy link
Member

silverwind commented May 27, 2021

I plan to follow up with a few copy-related features after #15899.

As for this button, I think I'd prefer if it would copy plain text without fences but I see there may be a necessity to have both options, e.g. "Copy as Markdown" and "Copy as Plain Text". Same goes for the copy feature on lines when viewing a file.

@silverwind silverwind added the type/feature Completely new functionality. Can only be merged if feature freeze is not active. label May 27, 2021
@delvh
Copy link
Member Author

delvh commented May 27, 2021

Wait… When is there a necessity to copy text as markdown?

@silverwind
Copy link
Member

Ah, no there actually is no copying as markdown, I was just confused by copying above block because it in itself is markdown. We should always copy plain.

@zeripath zeripath added the topic/ui Change the appearance of the Gitea UI label Jun 26, 2021
@yardenshoham
Copy link
Member

I think this has been implemented and can be closed.

@delvh
Copy link
Member Author

delvh commented Oct 22, 2022

Yep, I think I remember that as well.

@delvh delvh closed this as completed Oct 22, 2022
@go-gitea go-gitea locked and limited conversation to collaborators May 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
topic/ui Change the appearance of the Gitea UI type/feature Completely new functionality. Can only be merged if feature freeze is not active.
Projects
None yet
Development

No branches or pull requests

4 participants