How to create popup menu with horizontal sub-menu in SEMANTIC -
i wanna create horizontal sub menu when click dropdown menu semantic css. want picture below. thank in advance!
actually not dropdown menu , you're looking popup , can create horizontal sub menu creating first menu button , linking popup content , following :
html
<div class="ui text menu"> <div class="item"> <img src="https://semantic-ui.com/images/new-school.jpg"> </div> <!-- menu button --> <a class="browse item"> browse courses <i class="dropdown icon"></i> </a> <!-- /your menu button --> </div> <!-- popup content --> <div class="ui flowing basic admission popup"> <div class="ui 3 column relaxed divided grid"> <div class="column"> <h4 class="ui header">business</h4> <div class="ui link list"> <a class="item">design & urban ecologies</a> <a class="item">fashion design</a> <a class="item">fine art</a> <a class="item">strategic design</a> </div> </div> <div class="column"> <h4 class="ui header">liberal arts</h4> <div class="ui link list"> <a class="item">anthropology</a> <a class="item">economics</a> <a class="item">media studies</a> <a class="item">philosophy</a> </div> </div> <div class="column"> <h4 class="ui header">social sciences</h4> <div class="ui link list"> <a class="item">food studies</a> <a class="item">journalism</a> <a class="item">non profit management</a> </div> </div> </div> </div> <!-- /your popup content -->
js(jquery)
$('a.browse.item') .popup({ popup : $('.ui.flowing.basic.admission.popup'),//popup content selector on : 'click', //event trigger position : 'bottom left', lastresort:true, }) ;
in popup settings can choose event trigger on:'click'
, can either like: focus,hover... , more settings see popup settings.
Comments
Post a Comment