Skip to content
This repository has been archived by the owner on Mar 23, 2023. It is now read-only.

fix: remove mouseup capabilities to trigger modal close. #1653

Merged
merged 5 commits into from
Feb 11, 2020

Conversation

dav1app
Copy link
Contributor

@dav1app dav1app commented Feb 7, 2020

Fix a bug that allow mouseup to behave as a click event on modals backdrop, since it is fired by mousedown inside a child component and mouseup inside a parent component, firing the click and closing the modal.

Summary

  • Changes the default trigger from click to mousedown.left.
  • Tests are working as expected, since click events are composed as both mousedown and mouseup events.
  • I was unable to test event modifiers on vue-test-utils. No documentation about that and options doesn't work on beta-29.

Checklist

  • Documentation (if necessary)
  • Tests (if necessary)
  • Ready to be merged

@ghost ghost added Complexity: Low Less than 64 lines changed. Type: Bugfix The pull request fixes an incorrect functionality or behaviour. Status: In Progress The issue or pull request is being worked on. labels Feb 7, 2020
@codecov
Copy link

codecov bot commented Feb 7, 2020

Codecov Report

Merging #1653 into develop will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff            @@
##           develop    #1653   +/-   ##
========================================
  Coverage    59.95%   59.95%           
========================================
  Files          128      128           
  Lines         3049     3049           
  Branches       624      624           
========================================
  Hits          1828     1828           
  Misses        1028     1028           
  Partials       193      193

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3384d72...a90b9f3. Read the comment docs.

@dav1app dav1app changed the title fix: change click to mousedown on modalwindow fix: remove mouseup capabilities to trigger modal close. Feb 7, 2020
@dav1app dav1app marked this pull request as ready for review February 9, 2020 14:39
@ghost ghost added Status: Needs Review The issue or pull request needs a review by a developer of the team. and removed Status: In Progress The issue or pull request is being worked on. labels Feb 9, 2020
@alexbarnsley alexbarnsley merged commit 538f0e1 into develop Feb 11, 2020
@ghost ghost deleted the fix/mouseup-count-as-click-on-modal branch February 11, 2020 23:48
@ghost ghost removed the Status: Needs Review The issue or pull request needs a review by a developer of the team. label Feb 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Complexity: Low Less than 64 lines changed. Type: Bugfix The pull request fixes an incorrect functionality or behaviour.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants