I want to display a div with the following restrictions:
- automatically hide under 1024px width
- can be toggle by button under 1024px width, but if I click somwhere (not inside the div) the
activeDiv
class should be removed
I have a dummy example at codepen
So the following problems occured:
- In IE10 the toggle button just not work (not hide/show the div) I check with the developer tools, but no sign of the
display: initial
- In Chrome 29 the div appeard next the button not under it. (Firefox is the same)
I know that the defaultdisplay
for div isblock
, but this css is not only fordiv
tags that's why I try to useinitial
.