Hidden Panel
How do I make an hidden panel?
A box with a hidden panel, the user can click a thingy to make the hidden panel slide into view.. What is a hidden panel? How do you make a hidden panel? This script and codes were developed by Josh Vogt on 18 November 2022, Friday.
Hidden Panel - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Hidden Panel</title> <link rel='stylesheet prefetch' href='https://s3-us-west-2.amazonaws.com/s.cdpn.io/139759/standard_2014_11.css'> <link rel="stylesheet" href="css/style.css">
</head>
<body> <div class="worko-box panel-box panel" id="first"> <h3 class="worko-heading">Hidden Panel Box</h3> <p>This is the default panel. It lives within the normal context of a worko-box.</p> <ul> <li>It might contain a list <li>with more than one item <li>this one seems to have three </ul> <p>The hidden panel may or may not be the tallest element. The plugin will equalize the height of the initial panel and the hidden panel. The pabel with the greatest height will determine the height of each panel.</p> <a class="follow-link link js--panel-trigger--show">Show the hidden panel »</a> <div class="panel-box-content off-canvas panel off-canvas--right"> <h5>Hidden Panel</h5> <p>This is the content of the hidden panel. By default, the hidden panel animates from the bottom, add one of theses classes to the hidden panel to change the direction of the animation: <ul> <li><span class="css-attribute">off-canvas--left</span> <li><span class="css-attribute">off-canvas--right</span> <li><span class="css-attribute">off-canvas--top</span> </ul> </p> <a class="follow-link link js--panel-trigger--hide">Hide the visible panel »</a> </div>
</div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script> <script src="js/index.js"></script>
</body>
</html>
Hidden Panel - Script Codes CSS Codes
.panel-box { background: #fff; width: auto; margin: 20px; overflow: hidden; position: relative; padding-bottom: 40px;
}
.panel-box-content { background: #fff; position: absolute; top: 0; -webkit-transition: -webkit-transform 0.3s cubic-bezier(0.87, 0.78, 0.88, 0.86); transition: -webkit-transform 0.3s cubic-bezier(0.87, 0.78, 0.88, 0.86); transition: transform 0.3s cubic-bezier(0.87, 0.78, 0.88, 0.86); transition: transform 0.3s cubic-bezier(0.87, 0.78, 0.88, 0.86), -webkit-transform 0.3s cubic-bezier(0.87, 0.78, 0.88, 0.86); margin-left: -20px; padding: 20px;
}
.panel-box-content.off-canvas { -webkit-transform: translateY(100%); transform: translateY(100%);
}
.panel-box-content.off-canvas.off-canvas--top { -webkit-transform: translateY(-100%); transform: translateY(-100%);
}
.panel-box-content.off-canvas.off-canvas--left { -webkit-transform: translateX(-100%); transform: translateX(-100%);
}
.panel-box-content.off-canvas.off-canvas--right { -webkit-transform: translateX(100%); transform: translateX(100%);
}
.follow-link { position: absolute; bottom: 20px; right: 20px;
}
.panel-box-content ul { padding: 0;
}
.panel-box-content ul * + * { margin-top: 10px;
}
.panel-box-content ul li { list-style-type: none;
}
Hidden Panel - Script Codes JS Codes
jQuery.fn.extend({ hiddenPanel: function () { $('.js--panel-trigger--show').on('click', function() { $(this).next('.panel-box-content').removeClass('off-canvas'); }); $('.js--panel-trigger--hide').on('click', function() { $(this).parent('.panel-box-content').addClass('off-canvas'); }); var maxHeight = Math.max.apply(null, $(".panel").map(function() { return $(this).outerHeight(); }).get()); // set panels to the same height $('.panel').css({ height: maxHeight + 'px' }); }
});
$('.panel-box').hiddenPanel();
Developer | Josh Vogt |
Username | josh_vogt |
Uploaded | November 18, 2022 |
Rating | 3 |
Size | 3,232 Kb |
Views | 14,168 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
SMPTE Test Pattern - Flexbox | 2,920 Kb |
CSS Grid Layout - Off Canvas Navigation | 2,830 Kb |
Toggle - just a dropdown | 1,542 Kb |
Header - search v3 | 4,093 Kb |
Password Reset | 3,172 Kb |
Repeating Content Module - Expanding | 2,475 Kb |
Workopolis SVG Logo - Animated | 4,093 Kb |
CSS modals and sheets animations | 2,294 Kb |
A Pen by Josh Vogt | 2,910 Kb |
Animating Flexbox Properties | 2,571 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
Beveled corners using CSS border attribute | DawsonMediaD | 2,136 Kb |
Multi column experiment. | Spylefkaditis | 2,805 Kb |
Slider css only | Armandobau | 2,161 Kb |
Fading text with CSS blend modes | Giana | 3,305 Kb |
Toggle menu | Seyedi | 2,279 Kb |
A Pen by Stan Williams | Stanssongs | 6,706 Kb |
Modal Dialog | Gigaleet | 2,251 Kb |
Vue Transition | Chenming142 | 4,561 Kb |
Background Images | Jooonebug | 2,100 Kb |
CSS Gem Badge | Orchard | 3,335 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!