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

CSS3-only menu #269

Closed
wolffe opened this issue Jan 7, 2014 · 13 comments
Closed

CSS3-only menu #269

wolffe opened this issue Jan 7, 2014 · 13 comments

Comments

@wolffe
Copy link

wolffe commented Jan 7, 2014

I don't see the need for an extra JS library for a dropdown menu, when it's possible to code it using CSS3 only.

Please consider this for the next version.

@wolffe
Copy link
Author

wolffe commented Jan 7, 2014

I'm using Pure library for a project manager application, http://pm.roo.ie/ (currently in Beta) and I need all the power of a CSS library, without the bloat of Bootstrap. So far, Pure is the cleanest and the lightest.

@stevenvachon
Copy link
Contributor

I agree. The click-based script should be unobtrusive and not a requirement. The components should work with :hover too.

@wolffe
Copy link
Author

wolffe commented Jan 7, 2014

It's really easy to add support for a basic dropdown, and if nothing happens, I'll do a pull request.

@stevenvachon
Copy link
Contributor

@wolffe another worth checking out is Cascade.

@wolffe
Copy link
Author

wolffe commented Jan 7, 2014

@stevenvachon very interesting, I might check it out for another project.

@narcis-radu
Copy link
Contributor

@wolffe - https://github.com/narcis-radu/pure-dropdown-menu - still needs some mobile love
@stevenvachon :hover and mobile .. not a love story :)

@wolffe
Copy link
Author

wolffe commented Jan 8, 2014

@narcis-radu Great job! I'll add it to my project. I'll go with media queries for the mobile.

Cheers!

@okuryu
Copy link

okuryu commented Jan 8, 2014

Seems to related to #142.

@ericf
Copy link
Collaborator

ericf commented Jan 8, 2014

The how-would-this-work-with-touch (mobile) point is key for this feature.

There's CSS-"only" tricks you can do with setting the URL fragment, but that causes a browser history entry. Another option here is to move the drop-down menu out of Pure's code, and allow it to be provided via a separate project that builds on Pure's core menu, like @narcis-radu's.

@narcis-radu
Copy link
Contributor

by using the :focus pseudo selector we can create a 'click' event for touch devices. I managed to adapt the dropdown menu for touch devices (tested on ipad and lumia 1020). It's ok-ish for the first submenu, but when going deeper .. well, you can give it a try: https://github.com/narcis-radu/pure-dropdown-menu/tree/mobile

@dtrillo
Copy link

dtrillo commented Mar 17, 2014

@narcis-radu great project the pure-dropdown-menu!

I am preparing an entrance for my blog, and I'm commenting your "extension" to the pureCSS project!

@bgarrant
Copy link

I am using meanmenu jquery for all our Pure sites. It is super light and work great.

@jamesalley
Copy link
Contributor

The New Menu PR has support for CSS-only dropdowns-- though not in pure-menu-responsive.

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

8 participants