32 lines
771 B
JavaScript
32 lines
771 B
JavaScript
|
|
(function($) {
|
||
|
|
|
||
|
|
$(document).ready(function() {
|
||
|
|
|
||
|
|
$(".d-menu li").each(function() {
|
||
|
|
var $this = $(this);
|
||
|
|
var dropdown = $this.find(".dropdown");
|
||
|
|
if (dropdown.size() == 1) {
|
||
|
|
$this.hover(function() {
|
||
|
|
$this.addClass("with-dropdown-hover");
|
||
|
|
dropdown.show();
|
||
|
|
}, function() {
|
||
|
|
$this.removeClass("with-dropdown-hover");
|
||
|
|
dropdown.hide();
|
||
|
|
});
|
||
|
|
}
|
||
|
|
});
|
||
|
|
|
||
|
|
$("input.inline-label").each(function() {
|
||
|
|
$(this).data("initial_value", $(this).val());
|
||
|
|
});
|
||
|
|
$("input.inline-label").focus(function() {
|
||
|
|
var el = $(this);
|
||
|
|
el.addClass("inline-label-focus");
|
||
|
|
if (el.val() == el.data("initial_value")) {
|
||
|
|
el.val("");
|
||
|
|
}
|
||
|
|
});
|
||
|
|
|
||
|
|
});
|
||
|
|
|
||
|
|
})(jQuery);
|