在下面的 fiddle 中,如果您单击左侧的按钮/选项卡,您可以看到选项卡右侧出现箭头类型的图形。
https://jsfiddle.net/5mf989jL/49/
对于您选择的每个选项卡,箭头都会放置在该选项卡上。
这是在我更新代码之前。现在,我的箭头仅在单击第一个选项卡时出现,并且比应有的高度高很多。
我改变了这个...
$('.panel_out input').on('click', function () {
var id_to_show = '#' + this.id.replace('_button', '');
$(id_to_show).show().siblings().hide();
}).first().trigger('click');
为此...
jQuery(document).ready(function () {
$('.panel_out input').on('click', function () {
var id_to_show = '#' + this.id.replace('_button', '');
$(id_to_show).show().siblings().hide();
$('#dashboard_welcome').siblings().hide();
箭头函数来源于此...
//For the arrow in panel
$("input.arrowBtn").click(function(){
$(this).siblings('.arrow-left').remove();
$("<div class='arrow-left'></div>").insertAfter($(this));
});
我怎样才能改变它,使其与 fiddle 中的一样?
最佳答案
关于javascript - 更新后点击功能不再有效,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32257609/