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

Increases clickable area of the close btn on modals #23783

Merged
merged 4 commits into from
Oct 1, 2017

Conversation

andresgalante
Copy link
Collaborator

On alerts we increase the clickable area of the close btns to make them easier to click on devices where the pointer is coarse and improve accessibility.

This PR does 2 things:

1- Introduces the same concept for modals.
1- Changes the align-items to flex-start so the close btn always stays on the upper right corner when the modal-title text wraps.

I am not sure if this should be a global change on _close.scss

What do you think?

@andresgalante andresgalante changed the title Extends clickable area of the close btn on modals Increases clickable area of the close btn on modals Aug 31, 2017
@mdo
Copy link
Member

mdo commented Sep 1, 2017

Possible to see a quick demo of the before/after by chance?

@andresgalante
Copy link
Collaborator Author

@mdo sure! here is the bug:
https://codepen.io/andresgalante/pen/NvopBJ?editors=1100

  • close btn "X" centers instead of been top right
  • the x btn click are is smaller than a finger.

Here is the solution:
https://codepen.io/andresgalante/pen/MvLpZw?editors=1100

  • The close btn in the top right corner
  • the click area is larger

What do you you think?

@patrickhlauke
Copy link
Member

Seems fine to me. @mdo ?

@XhmikosR
Copy link
Member

LGTM too, but I too wonder if we should change close instead of this specific case. Close seems to be using float currently.

@XhmikosR XhmikosR merged commit 3624025 into twbs:v4-dev Oct 1, 2017
@mdo mdo mentioned this pull request Oct 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants