m (Wtwt1997 moved page Team:USTC-Software/css/init to Team:USTC-Software/js/init) |
|||
(16 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
$(document).ready(function () { | $(document).ready(function () { | ||
− | $('.container').height($(window).height()-$('#menu').height()) | + | $('.container').height($(window).height()-$('#menu').height() - 12) |
− | $('.wide').height($(window).height()-$('#menu').height() - | + | $('.wide').height($(window).height()-$('#menu').height() - 30) |
$('#leftnav').height($(window).height() - $('#menu').height() - 100) | $('#leftnav').height($(window).height() - $('#menu').height() - 100) | ||
+ | $('.ui.menu .ui.dropdown').dropdown({ | ||
+ | on: 'hover' | ||
+ | }); | ||
+ | $('.ui.menu a.item') | ||
+ | .on('click', function() { | ||
+ | $(this) | ||
+ | .addClass('active') | ||
+ | .siblings() | ||
+ | .removeClass('active') | ||
+ | ; | ||
+ | }) | ||
+ | ; | ||
}) | }) |
Latest revision as of 07:25, 15 October 2018
$(document).ready(function () {
$('.container').height($(window).height()-$('#menu').height() - 12) $('.wide').height($(window).height()-$('#menu').height() - 30) $('#leftnav').height($(window).height() - $('#menu').height() - 100)
$('.ui.menu .ui.dropdown').dropdown({
on: 'hover' });
$('.ui.menu a.item')
.on('click', function() { $(this) .addClass('active') .siblings() .removeClass('active') ; }) ; })