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

removed vue-clipboard2 from package.json #3593

Closed
wants to merge 1 commit into from

Conversation

Julian1998
Copy link
Contributor

Description

Removed vue-clipboard2 from the package.json file dependencies

Related Issue

Motivation and Context

We already got copy-to-clipboard so vue-clipboard would be redundant

How Has This Been Tested?

  • tested in chrome

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests

Checklist:

  • Code changes
  • Unit tests added
  • Acceptance tests added
  • Documentation ticket raised:

Open tasks:

  • ...

@Julian1998 Julian1998 added the Status:Needs-Review Needs review from a maintainer label Jun 11, 2020
@Julian1998 Julian1998 self-assigned this Jun 11, 2020
@update-docs
Copy link

update-docs bot commented Jun 11, 2020

Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes.

@Julian1998 Julian1998 force-pushed the remove-vue-clipboard2 branch from 67ae0bb to 7932de8 Compare June 11, 2020 16:08
@Julian1998
Copy link
Contributor Author

@LukasHirt I absolutely don't like my part where I create a custom event for not crashing the event handler method. Do you think we can delete the whole event handler as it just seems to prevent fast double clicks on the copy to clipboard icon/button.

@LukasHirt
Copy link
Collaborator

I absolutely don't like my part where I create a custom event for not crashing the event handler method. Do you think we can delete the whole event handler as it just seems to prevent fast double clicks on the copy to clipboard icon/button.

I think part of that is also responsible for giving feedback to the user that the link has been copied. At first glance, it might be enough to use local data object in the component. But there might be something that I have overlooked so you can try it and see if it'll work still fine 😉

@Julian1998
Copy link
Contributor Author

I absolutely don't like my part where I create a custom event for not crashing the event handler method. Do you think we can delete the whole event handler as it just seems to prevent fast double clicks on the copy to clipboard icon/button.

I think part of that is also responsible for giving feedback to the user that the link has been copied. At first glance, it might be enough to use local data object in the component. But there might be something that I have overlooked so you can try it and see if it'll work still fine

Yeah it is responsible for feedback... BUT we never implemented the visual feedback in the sidebar

@LukasHirt
Copy link
Collaborator

LukasHirt commented Jun 15, 2020

BUT we never implemented the visual feedback in the sidebar

We did.

image

Same for private link.

@Julian1998
Copy link
Contributor Author

Ah I was talking about something like a notification message

@Julian1998 Julian1998 force-pushed the remove-vue-clipboard2 branch from 7932de8 to 359a13c Compare July 12, 2020 13:36
@Julian1998 Julian1998 force-pushed the remove-vue-clipboard2 branch from 359a13c to 039d753 Compare July 12, 2020 14:00
@Julian1998
Copy link
Contributor Author

@LukasHirt well I slightly adapted my code but we can't get rid of these events. We need to emit an event so the success handler method gets triggered. I guess there are several ways to deal with that, but emitting an event seems to be the best in my opinion.

What do you think?

@Julian1998
Copy link
Contributor Author

@LukasHirt please re-review :)

@@ -63,8 +63,7 @@
>
<oc-icon
v-if="!linksCopied[link.url]"
v-clipboard:copy="link.url"
v-clipboard:success="$_clipboardSuccessHandler"
@click="$_copyPublicLinkToClipboard()"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Move the click pls to the wrapping button.

@LukasHirt
Copy link
Collaborator

I guess there are several ways to deal with that, but emitting an event seems to be the best in my opinion.

Is there something connected to the event outside the link item component? As far as I understood (haven't looked that close though so I might be missing something) we emit the event, then set the copied link globally and then read it again in the link item component. Is that correct? What about not emitting the event but instead using local data object in the component?

@Julian1998
Copy link
Contributor Author

Julian1998 commented Jul 13, 2020

Well.... the linkListItem triggers the onCopy event which gets processed in the fileLinkSidebar component. This way we can reuse the successHandler in the filesidebar component for the linkListItem as well as some code for the clipboard in the sidebar itself

@Julian1998 Julian1998 requested a review from LukasHirt July 18, 2020 11:39
@LukasHirt
Copy link
Collaborator

@Julian1998 Address pls this comment #3593 (comment)

@Julian1998
Copy link
Contributor Author

Julian1998 commented Jul 20, 2020

@Julian1998 Address pls this comment #3593 (comment)

My requested re-review was not on intended. I am sorry. Unluckily there was no way to undo this.

@LukasHirt
Copy link
Collaborator

My requested re-review was not on intended. I am sorry. Unluckily there was no way to undo this.

No worries 😉

@kulmann
Copy link
Contributor

kulmann commented Aug 13, 2020

@Julian1998 same here, do you know when you will be able to schedule time for this? or should someone else take over?

@pascalwengerter
Copy link
Contributor

@Julian1998 just stumbled across this when checking open issues, shall we finish your work or would you like to continue working on it? The project structure has changed a bit, happy to offer some guidance if applicable!

@Julian1998
Copy link
Contributor Author

@pascalwengerter I forgot to unassign. We could keep this PR open and someone else could build a new solution based on this branch. But I probably won't finish it. Best luck

@Julian1998 Julian1998 removed their assignment Mar 17, 2021
@pascalwengerter
Copy link
Contributor

Superseded by #5147

@pascalwengerter pascalwengerter deleted the remove-vue-clipboard2 branch June 2, 2021 09:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status:Needs-Review Needs review from a maintainer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove vue-clipboard2
4 participants