angular2-multiselect-dropdown icon indicating copy to clipboard operation
angular2-multiselect-dropdown copied to clipboard

change click event to pointer down to avoid unwanted multiselect closing

Open alkn87 opened this issue 4 years ago • 0 comments

Expected behavior:

Firefox has the right behavior:

  1. User opens the Multiselect
  2. Enters some string into the search filter field.
  3. User wants to copy the input string by marking it with the mouse pointer.
  4. User goes from right to the left while holding the left mouse button to mark the text.
  5. User accidentally leaves the Multiselect area and releases left mouse button.
  6. Multiselect is still opened after release of the left mouse button and the text of the search filter is marked and ready for copy&paste.

Wrong behavior

Chrome has the wrong behavior:

  1. User opens the Multiselect
  2. Enters some string into the search filter field.
  3. User wants to copy the input string by marking it with the mouse pointer.
  4. User goes from right to the left while holding the left mouse button to mark the text.
  5. User accidentally leaves the Multiselect area and releases left mouse button.
  6. Multiselect is closed because Chrome triggers the click event based on where the mouseUp event happens.

Fix

change click event to pointer down to avoid unwanted multiselect closing

alkn87 avatar Jun 01 '21 05:06 alkn87