Tag: 反转

jQuery删除元素并重新编号其余元素

有没有人在这里看到我的代码中的缺陷,因为这个让我难过! function removeMLRow(rowNo) { $(‘#ml_organize li:eq(‘ + (rowNo – 1) + ‘)’).remove(); $($(‘#ml_organize li:eq(‘ + (rowNo) + ‘)’).get().reverse()).each(function() { var newID = ‘li’ + ($(this).index() – 1); $(this).attr(‘id’,newID); }); }

如何使用jQuery在第二次单击时反转CSS动画

我做了以下菜单图标CSS动画,当我点击它时触发。 当我第二次使用jQuery点击它时,我想让它反向动画。 #path1 { stroke-dasharray: 33px; stroke-dashoffset: 33px; animation: line 1.5s linear forwards; animation-play-state: paused; } @keyframes line { 100% { stroke-dashoffset: -15.5; } } #halfLineLeft { transform-origin: 1% 50%; animation: shrinkleft 1s linear forwards; animation-play-state: paused; } #halfLineRight { transform-origin: 100% 1%; animation: shrinkleft 1s linear forwards; animation-play-state: paused; } @keyframes shrinkleft { 100% […]