- This topic is empty.
-
AuthorPosts
-
February 28, 2014 at 10:28 am #164373
rrs1964
ParticipantI found this menu (which works perfect on ipads etc.) on the internet and adjusted it to separate floating buttons. Now I would like to set a transition so my menu folds out slower.
You can see an example here: http://www.rs-design.nl/ontwerp/index.html
And on CodePen here: http://codepen.io/rrs1964/pen/crCGF
I tried it with the following on every hover line in the css but no luck:
-webkit-transition: height 0.3s ease-in;
-moz-transition: height 0.3s ease-in;
-o-transition: height 0.3s ease-in;
-ms-transition: height 0.3s ease-in;
transition: height 0.3s ease-in;Any help would be appreciated!
Thanks!
February 28, 2014 at 10:30 am #164374Paulie_D
MemberPlease don’t just do a code dump.
Make a working example in Codepen.
February 28, 2014 at 10:51 am #164379rrs1964
ParticipantSorry Paulie_D, didn’t know that was not done….
February 28, 2014 at 11:58 am #164387Atelierbram
ParticipantYou want the menu to fold out slower, then maybe look into
accordions
, but most of them are done with some added javascript, but there are some pretty lightweight ones out there.I know My first fork of your Codepen won’t help that much, for what I did here is change the
display
declaration to aopacity
on hover.In this second attempt I tried some
transform: translateY()
, with some overflow issues.March 1, 2014 at 2:48 am #164442rrs1964
ParticipantThanks for your input, atelierbram!
To be honest I like your first attempt better. And it certainly looks better then my first attempt.
I remember seeing on the internet effects in css where objects appear in a rhythm: tak, tak, tak and that’s the effect I would like to have.Guess you are Dutch too considering your name … ;-)
Rutger
March 1, 2014 at 4:16 am #164443Atelierbram
ParticipantTo be honest I like your first attempt better. And it certainly looks better then my first attempt.
First one is kind of easy to do really, trouble with the second
transform: translate(Y)
one, is the overlapping of the nested menu; can’t seem to have it come from under the menu-button. Triedz-index:-1
, pseudo-element, nothing seems to work, so I give up for now.I remember seeing on the internet effects in css where objects appear in a rhythm: tak, tak, tak and that’s the effect I would like to have.
Updated the Codepen’s with some slightly improved
CSS
, and added a tiny bit of delay on the transitions.One thing I would like to recommend, – trying not to preach -, ( which is always tricky because, yes, I am Dutch after all), is trying to get your head around bem-syntax , or a similar logic with
HTML
andCSS
. For having anul
, and childli
with this same name (.topmenu
), kind of defeats all logic.March 1, 2014 at 7:59 am #164464Atelierbram
ParticipantTried z-index:-1, pseudo-element, nothing seems to work, so I give up for now.
Did eventually work:
z-index
has to be in scope. -
AuthorPosts
- The forum ‘CSS’ is closed to new topics and replies.