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

Position Action Sheet #81

Open
rmsint opened this issue Sep 21, 2016 · 3 comments
Open

Position Action Sheet #81

rmsint opened this issue Sep 21, 2016 · 3 comments

Comments

@rmsint
Copy link

rmsint commented Sep 21, 2016

What would you advise to position an Action Sheet?
For buttons that are on the edge of the screen the positioning should be changed ie. to the right to prevent the menu being cutoff.

For a project at my company we just upgraded to 2.x, thanks a lot for continuing this project!

Maybe something similar as md-position-mode of the angular material menu is possible for the Action Sheet?

@tolyo
Copy link
Contributor

tolyo commented Sep 21, 2016

@rmsint Used dropdown from foundation 5 for similar case.

@soumak77
Copy link
Contributor

soumak77 commented Sep 23, 2016

I'm actually quite surprised that position right and left are not supported for action sheets. I'll leave this issue open for anyone that wants to add support for that.

@rmsint In the meantime you can position action sheets with the following CSS:

.action-sheet {
  transform: translateX(-70px) translateY(20px); // position body
  &::before, &::after {
    left: 10%;  // position arrow
  }
}

I used this solution to position the menu dropdowns on https://parents.fiboart.com

@rmsint
Copy link
Author

rmsint commented Oct 6, 2016

Thanks a lot, the link is a nice example! Interesting to see in action how you solved it. Offtopic: also how you switch between a menu bar and offcanvas menu for mobile navigation is very nice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants