提交修改

new-v20240713
dshclm 8 months ago
parent 7545137dcd
commit f34f7d0ce0

@ -559,6 +559,7 @@
var noticeInner = document.querySelector('.notice__inner');
var noticeItems = Array.from(document.querySelectorAll('.notice__item'));
var currentIndex = 0;
if (noticeItems.length > 1) {
function showCurrentNotice() {
var numToShow = Math.min(currentIndex + 1, noticeItems.length);
for (var i = 0; i < noticeItems.length; i++) {
@ -573,7 +574,7 @@
}
showCurrentNotice();
if (noticeItems.length > 1) {
setInterval(() => {
currentIndex = (currentIndex + 1) % noticeItems.length;
showCurrentNotice();

Loading…
Cancel
Save