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

How to hide the panels until hover or clicked? #45

Open
ollie007 opened this issue Nov 8, 2015 · 2 comments
Open

How to hide the panels until hover or clicked? #45

ollie007 opened this issue Nov 8, 2015 · 2 comments

Comments

@ollie007
Copy link

ollie007 commented Nov 8, 2015

How to hide the panels until hover or clicked?

would like an option to hide the panel unless its required

display:hidden

would it be revealed by this script?

i have a panel up top which loads on page load, but it would be better hidden until hover on activator

@seanhudson
Copy link

Did you ever get this fixed? It doesn't look like anyone has responded in a while.

@whatnickcodes
Copy link
Member

whatnickcodes commented Mar 8, 2017

Just use basic CSS and jQuery for this:

.my-panel-name {
    opacity: 0; /* or display: none; or visibility: hidden; */
}
.my-panel-name.show {
    opacity: 1; /* or "display: block;" or "visibility: visible;" */
}
// On hover
$('.on-hover-of-something').hover(function() {
     $('.my-panel-name').addClass('show');
});

// On DOM ready
$(function() {
     $('.my-panel-name').addClass('show');
});

// On Page Load
$(window).load(function() {
     $('.my-panel-name').addClass('show');
});

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

No branches or pull requests

3 participants